]> git.sesse.net Git - vlc/commitdiff
macosx: add missing retains when exchanging views
authorDavid Fuhrmann <david.fuhrmann@googlemail.com>
Thu, 6 Jun 2013 19:04:18 +0000 (21:04 +0200)
committerDavid Fuhrmann <david.fuhrmann@googlemail.com>
Thu, 6 Jun 2013 19:10:11 +0000 (21:10 +0200)
modules/gui/macosx/Windows.m

index a9eb6b4758efe8e27f9bf25cd6b43f18abf5b1a5..2b50dad6e3f0906c52923cf74ef7bb948f9a7a96 100644 (file)
 
             [screen setFullscreenPresentationOptions];
 
+            [o_video_view retain];
             [[o_video_view superview] replaceSubview:o_video_view with:o_temp_view];
             [o_temp_view setFrame:[o_video_view frame]];
             [o_fullscreen_window setContentView:o_video_view];
+            [o_video_view release];
 
             [o_fullscreen_window makeKeyAndOrderFront:self];
             [o_fullscreen_window orderFront:self animate:YES];
 
         /* Make sure we don't see the o_video_view disappearing of the screen during this operation */
         NSDisableScreenUpdates();
+        [o_video_view retain];
         [[o_video_view superview] replaceSubview:o_video_view with:o_temp_view];
         [o_temp_view setFrame:[o_video_view frame]];
         [o_fullscreen_window setContentView:o_video_view];
+        [o_video_view release];
         [o_fullscreen_window makeKeyAndOrderFront:self];
         NSEnableScreenUpdates();
     }