Commit fee6089b authored by David Fuhrmann's avatar David Fuhrmann

macosx: Allow toggling of bookmark window

This unifies behaviour with all the other HUD panels
parent 70816fa1
......@@ -44,6 +44,7 @@
@property (readwrite, weak) IBOutlet NSTextField *editTimeTextField;
- (void)updateCocoaWindowLevel:(NSInteger)i_level;
- (IBAction)toggleWindow:(id)sender;
- (IBAction)add:(id)sender;
- (IBAction)clear:(id)sender;
......@@ -54,6 +55,4 @@
- (IBAction)edit_cancel:(id)sender;
- (IBAction)edit_ok:(id)sender;
- (void)showBookmarks;
@end
......@@ -102,12 +102,14 @@
[self.window setLevel: i_level];
}
- (void)showBookmarks
- (IBAction)toggleWindow:(id)sender
{
/* show the window, called from intf.m */
[self.window displayIfNeeded];
[self.window setLevel: [[[VLCMain sharedInstance] voutController] currentStatusWindowLevel]];
[self.window makeKeyAndOrderFront:nil];
if ([self.window isVisible])
[self.window orderOut:sender];
else {
[self.window setLevel: [[[VLCMain sharedInstance] voutController] currentStatusWindowLevel]];
[self.window makeKeyAndOrderFront:sender];
}
}
-(void)inputChangedEvent:(NSNotification *)o_notification
......
......@@ -1216,7 +1216,7 @@
- (IBAction)showBookmarks:(id)sender
{
[[[VLCMain sharedInstance] bookmarks] showBookmarks];
[[[VLCMain sharedInstance] bookmarks] toggleWindow:sender];
}
- (IBAction)showPreferences:(id)sender
......
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