Fix some deprecated functions
* src/nsterm.m (firstRectForCharacterRange): In OS X >10.6 replace convertBaseToScreen with convertRectToScreen. * src/nsmenu.m (ns_update_menubar): Remove attachedMenu, deprecated in OS X 10.2, and always seems to return nil.
This commit is contained in:
parent
42ac8f5723
commit
5508f06f32
2 changed files with 6 additions and 6 deletions
|
@ -136,12 +136,6 @@
|
|||
menu = [[EmacsMenu alloc] initWithTitle: ns_app_name];
|
||||
needsSet = YES;
|
||||
}
|
||||
else
|
||||
{ /* close up anything on there */
|
||||
id attMenu = [menu attachedMenu];
|
||||
if (attMenu != nil)
|
||||
[attMenu close];
|
||||
}
|
||||
|
||||
#if NSMENUPROFILE
|
||||
ftime (&tb);
|
||||
|
|
|
@ -6191,8 +6191,14 @@ - (NSRect)firstRectForCharacterRange: (NSRange)theRange
|
|||
+FRAME_LINE_HEIGHT (emacsframe));
|
||||
|
||||
pt = [self convertPoint: pt toView: nil];
|
||||
#if !defined (NS_IMPL_COCOA) || \
|
||||
MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_7
|
||||
pt = [[self window] convertBaseToScreen: pt];
|
||||
rect.origin = pt;
|
||||
#else
|
||||
rect.origin = pt;
|
||||
rect = [[self window] convertRectToScreen: rect];
|
||||
#endif
|
||||
return rect;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue