]> git.sesse.net Git - vlc/commitdiff
legacy OSX intf: correctly adapt vout window's size to video content
authorFelix Paul Kühne <fkuehne@videolan.org>
Sat, 13 Mar 2010 20:26:33 +0000 (21:26 +0100)
committerFelix Paul Kühne <fkuehne@videolan.org>
Sat, 13 Mar 2010 20:26:33 +0000 (21:26 +0100)
modules/gui/macosx/vout.m

index 554b90a2e99821c0511de637f3815972d4e442ba..e2ff868f97f65801881bca2a603b4d7f174f08c0 100644 (file)
@@ -284,7 +284,7 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
 
 - (void)updateTitle
 {
-    NSString * o_title = nil; 
+    NSString * o_title = nil;
     NSMutableString * o_mrl = nil;
     input_thread_t * p_input;
     char * psz_title;
@@ -804,7 +804,7 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
     i_time_mouse_last_moved = mdate();
     o_window = [[VLCVoutWindow alloc] initWithVout: p_arg_vout view: self
                                                     frame: s_arg_frame];
-    
+
     [self updateTitle];
     if([self isFullscreen])
         [o_window performSelectorOnMainThread: @selector(enterFullscreen) withObject: NULL waitUntilDone: YES];
@@ -947,7 +947,7 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
     /* o_window needs to point to our o_embeddedwindow, super might have set it
      * to the fullscreen window that o_embeddedwindow setups during fullscreen */
     o_window = o_embeddedwindow;
+
     if( b_return )
     {
         [o_window lockFullscreenAnimation];
@@ -962,8 +962,7 @@ int DeviceCallback( vlc_object_t *p_this, const char *psz_variable,
         if ([o_window isVisible] && (![o_window isFullscreen]))
             [o_window makeKeyAndOrderFront: self];
 
-        if ( [self window] != o_embeddedwindow )
-            [self scaleWindowWithFactor: 1.0 animate: [o_window isVisible] && (![o_window isFullscreen])];
+        [self scaleWindowWithFactor: 1.0 animate: [o_window isVisible] && (![o_window isFullscreen])];
 
         [o_embeddedwindow setVideoRatio:[self voutSizeForFactor:1.0]];