Commit 5428d0e1 authored by David Fuhrmann's avatar David Fuhrmann

macosx: improve logic to toggle effect windows

The window is now ordered in front every time with a single click / shortcut
like in iTunes.
parent 5516edca
...@@ -223,7 +223,7 @@ static VLCAudioEffects *_o_sharedInstance = nil; ...@@ -223,7 +223,7 @@ static VLCAudioEffects *_o_sharedInstance = nil;
- (IBAction)toggleWindow:(id)sender - (IBAction)toggleWindow:(id)sender
{ {
if ([o_window isVisible]) if ([o_window isKeyWindow])
[o_window orderOut:sender]; [o_window orderOut:sender];
else { else {
[o_window setLevel: [[[VLCMain sharedInstance] voutController] currentWindowLevel]]; [o_window setLevel: [[[VLCMain sharedInstance] voutController] currentWindowLevel]];
......
...@@ -771,7 +771,7 @@ static VLCVideoEffects *_o_sharedInstance = nil; ...@@ -771,7 +771,7 @@ static VLCVideoEffects *_o_sharedInstance = nil;
- (IBAction)toggleWindow:(id)sender - (IBAction)toggleWindow:(id)sender
{ {
if ([o_window isVisible]) if ([o_window isKeyWindow])
[o_window orderOut:sender]; [o_window orderOut:sender];
else { else {
[o_window setLevel: [[[VLCMain sharedInstance] voutController] currentWindowLevel]]; [o_window setLevel: [[[VLCMain sharedInstance] voutController] currentWindowLevel]];
......
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