Commit e6de5c7a authored by David Fuhrmann's avatar David Fuhrmann

macosx: save idle main window frame as early as possible (refs #8826)

parent 370d8f5d
......@@ -130,6 +130,7 @@
- (void)showFullscreenController;
- (void)videoplayWillBeStarted;
- (void)setVideoplayEnabled;
@end
......
......@@ -737,14 +737,17 @@ static VLCMainWindow *_o_sharedInstance = nil;
#pragma mark -
#pragma mark Video Output handling
- (void)videoplayWillBeStarted
{
if (!b_fullscreen)
frameBeforePlayback = [self frame];
}
- (void)setVideoplayEnabled
{
BOOL b_videoPlayback = [[VLCMain sharedInstance] activeVideoPlayback];
if (b_videoPlayback) {
if (!b_fullscreen)
frameBeforePlayback = [self frame];
} else {
if (!b_videoPlayback) {
if (!b_nonembedded && (!b_nativeFullscreenMode || (b_nativeFullscreenMode && !b_fullscreen)) && frameBeforePlayback.size.width > 0 && frameBeforePlayback.size.height > 0)
[[self animator] setFrame:frameBeforePlayback display:YES];
......
......@@ -66,6 +66,9 @@
VLCVoutView *o_vout_view;
VLCVideoWindowCommon *o_new_video_window;
// should be called before any window resizing occurs
[[VLCMainWindow sharedInstance] videoplayWillBeStarted];
if (b_multiple_vout_windows && b_video_wallpaper)
b_video_wallpaper = false;
......
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