aboutsummaryrefslogtreecommitdiffhomepage
path: root/osdep
diff options
context:
space:
mode:
authorGravatar Akemi <der.richter@gmx.de>2016-12-11 23:35:48 +0100
committerGravatar wm4 <wm4@nowhere>2016-12-12 12:10:10 +0100
commited7e650d3a95a1d80d976ec4e2aa378e30c9db25 (patch)
treee19f8cabde8829039128e4913e8c78da8dc0441d /osdep
parent4399be5b624805ef70848ff010fb6ee6ad920e9f (diff)
osx: update the menu and remove conflicting item
Remove 'Quit mpv & remember playback position' from the menu because it conflicts with the global logout shortcut. add separator between 'Hide' and 'Quit' for consistency with other Apps. also rename the 'Movie' menu to 'Video'. it's a bit more generic. Fixes #3865
Diffstat (limited to 'osdep')
-rw-r--r--osdep/macosx_application.m12
1 files changed, 5 insertions, 7 deletions
diff --git a/osdep/macosx_application.m b/osdep/macosx_application.m
index bf415d9576..8808caa0a4 100644
--- a/osdep/macosx_application.m
+++ b/osdep/macosx_application.m
@@ -50,7 +50,7 @@ static pthread_t playback_thread_id;
child:(NSMenu *)child;
- (void)registerMenuItem:(NSMenuItem*)menuItem forKey:(MPMenuKey)key;
- (NSMenu *)appleMenuWithMainMenu:(NSMenu *)mainMenu;
-- (NSMenu *)movieMenu;
+- (NSMenu *)videoMenu;
- (NSMenu *)windowMenu;
@end
@@ -117,17 +117,15 @@ static void terminate_cocoa_application(void)
[self mainMenuItemWithParent:mainMenu child:menu];
[self menuItemWithParent:menu title:@"Hide mpv"
action:@selector(hide:) keyEquivalent: @"h"];
+ [menu addItem:[NSMenuItem separatorItem]];
[self menuItemWithParent:menu title:@"Quit mpv"
action:@selector(stopPlayback) keyEquivalent: @"q"];
- [self menuItemWithParent:menu title:@"Quit mpv & remember position"
- action:@selector(stopPlaybackAndRememberPosition)
- keyEquivalent: @"Q"];
return [menu autorelease];
}
-- (NSMenu *)movieMenu
+- (NSMenu *)videoMenu
{
- NSMenu *menu = [[NSMenu alloc] initWithTitle:@"Movie"];
+ NSMenu *menu = [[NSMenu alloc] initWithTitle:@"Video"];
_R(menu, @"Half Size", @"0", MPM_H_SIZE)
_R(menu, @"Normal Size", @"1", MPM_N_SIZE)
_R(menu, @"Double Size", @"2", MPM_D_SIZE)
@@ -148,7 +146,7 @@ static void terminate_cocoa_application(void)
[NSApp setMainMenu:main_menu];
[NSApp setAppleMenu:[self appleMenuWithMainMenu:main_menu]];
- [NSApp mainMenuItemWithParent:main_menu child:[self movieMenu]];
+ [NSApp mainMenuItemWithParent:main_menu child:[self videoMenu]];
[NSApp mainMenuItemWithParent:main_menu child:[self windowMenu]];
}