Commit bd4d1b69 authored by David Fuhrmann's avatar David Fuhrmann Committed by Felix Paul Kühne

macosx: leave fullscreen when last playlist item stops

Signed-off-by: default avatarFelix Paul Kühne <fkuehne@videolan.org>
parent f043aa0e
...@@ -1221,7 +1221,7 @@ static VLCMainWindow *_o_sharedInstance = nil; ...@@ -1221,7 +1221,7 @@ static VLCMainWindow *_o_sharedInstance = nil;
[self makeFirstResponder: nil]; [self makeFirstResponder: nil];
if (!b_videoPlayback && b_fullscreen && !b_nativeFullscreenMode) if (!b_videoPlayback && b_fullscreen && !b_nativeFullscreenMode)
[self leaveFullscreenAndFadeOut: YES]; [[VLCCoreInteraction sharedInstance] toggleFullscreen];
} }
- (void)resizeWindow - (void)resizeWindow
......
...@@ -1351,15 +1351,19 @@ unsigned int CocoaKeyToVLC( unichar i_key ) ...@@ -1351,15 +1351,19 @@ unsigned int CocoaKeyToVLC( unichar i_key )
} }
else else
{ {
input_thread_t * p_input = pl_CurrentInput( VLCIntf ); if( b_fullscreen )
if( p_input != NULL && [self activeVideoPlayback])
{ {
if(b_fullscreen) input_thread_t * p_input = pl_CurrentInput( VLCIntf );
if( p_input != NULL && [self activeVideoPlayback] )
{
[o_mainwindow performSelectorOnMainThread:@selector(enterFullscreen) withObject:nil waitUntilDone:NO]; [o_mainwindow performSelectorOnMainThread:@selector(enterFullscreen) withObject:nil waitUntilDone:NO];
else vlc_object_release( p_input );
[o_mainwindow performSelectorOnMainThread:@selector(leaveFullscreen) withObject:nil waitUntilDone:NO]; }
vlc_object_release( p_input ); }
else
{
// leaving fullscreen is always allowed
[o_mainwindow performSelectorOnMainThread:@selector(leaveFullscreen) withObject:nil waitUntilDone:NO];
} }
} }
} }
......
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