Commit 4ff670a8 authored by David Reitter's avatar David Reitter
Browse files

nsmenu.m (EmacsMenu-clear): Recognize application menu

	on Mac OS X 10.6+ (bug#4513).
parent f146e75f
2009-09-25 David Reitter <david.reitter@gmail.com>
* nsmenu.m (EmacsMenu-clear): Recognize application menu
on Mac OS X 10.6+ (bug#4513).
2009-09-24 Juanma Barranquero <lekktu@gmail.com>
 
* frame.c (xrdb_get_resource): Return nil for empty string resources;
......
......@@ -668,7 +668,7 @@ - (NSMenuItem *)addItemWithWidgetValue: (void *)wvptr
/* convenience */
-(void) clear
-(void)clear
{
int n;
......@@ -676,7 +676,9 @@ -(void) clear
{
NSMenuItem *item = [self itemAtIndex: n];
NSString *title = [item title];
if (([title length] == 0 || [@"Apple" isEqualToString: title])
if (([title length] == 0 /* OSX 10.5 */
|| [@"Emacs" isEqualToString: title] /* from 10.6 on */
|| [@"Apple" isEqualToString: title]) /* older */
&& ![item isSeparatorItem])
continue;
[self removeItemAtIndex: n];
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment