]> git.sesse.net Git - vlc/commitdiff
macosx: remove recursive lock from fullscreen animation
authorDavid Fuhrmann <david.fuhrmann@googlemail.com>
Wed, 5 Jun 2013 09:53:22 +0000 (11:53 +0200)
committerDavid Fuhrmann <david.fuhrmann@googlemail.com>
Thu, 6 Jun 2013 19:10:11 +0000 (21:10 +0200)
This code is needless and had no effect for the last five years, already.

modules/gui/macosx/Windows.h
modules/gui/macosx/Windows.m

index c8dbfea852abaae73f9700587878c747b61e5baa..5a9a053af6cee90b2f16c7cd46c3b9463eec76ca 100644 (file)
@@ -103,7 +103,6 @@ static const float f_min_video_height = 70.0;
     NSView          * o_temp_view;
 
     BOOL              b_window_is_invisible;
-    NSRecursiveLock * o_animation_lock;
     NSInteger i_originalLevel;
 
     NSTimer *t_hide_mouse_timer;
index af7e65b4d3afb4ee42b5ccb14db21dbf44fdd80f..a9eb6b4758efe8e27f9bf25cd6b43f18abf5b1a5 100644 (file)
 
     [NSCursor setHiddenUntilMouseMoves: NO];
     [[[VLCMainWindow sharedInstance] fsPanel] setNonActive: nil];
-    
+
     [[[VLCMain sharedInstance] voutController] updateWindowLevelForHelperWindows: i_originalLevel];
     [self setLevel:i_originalLevel];
 
     if (![o_video_view isHidden]) {
         [[o_controls_bar bottomBarView] setHidden: NO];
     }
-    
+
     [self setMovableByWindowBackground: YES];
 }
 
 #pragma mark -
 #pragma mark Fullscreen Logic
 
-- (void)lockFullscreenAnimation
-{
-    [o_animation_lock lock];
-}
-
-- (void)unlockFullscreenAnimation
-{
-    [o_animation_lock unlock];
-}
-
 - (void)enterFullscreen
 {
     NSMutableDictionary *dict1, *dict2;
     BOOL blackout_other_displays = var_InheritBool(VLCIntf, "macosx-black");
 
     screen = [NSScreen screenWithDisplayID:(CGDirectDisplayID)var_InheritInteger(VLCIntf, "macosx-vdev")];
-    [self lockFullscreenAnimation];
 
     if (!screen) {
         msg_Dbg(VLCIntf, "chosen screen isn't present, using current screen for fullscreen mode");
         /* Make sure we are hidden */
         [self orderOut: self];
 
-        [self unlockFullscreenAnimation];
         return;
     }
 
         [self orderOut: self];
 
     [self setFullscreen:YES];
-    [self unlockFullscreenAnimation];
 }
 
 - (void)leaveFullscreen
     NSRect frame;
     BOOL blackout_other_displays = var_InheritBool(VLCIntf, "macosx-black");
 
-    [self lockFullscreenAnimation];
-
     if (o_controls_bar)
         [o_controls_bar setFullscreenState:NO];
     [[[VLCMainWindow sharedInstance] controlsBar] setFullscreenState:NO];
 
     /* Don't do anything if o_fullscreen_window is already closed */
     if (!o_fullscreen_window) {
-        [self unlockFullscreenAnimation];
         return;
     }
 
 
     [o_fullscreen_window release];
     o_fullscreen_window = nil;
-    
+
     [[[VLCMain sharedInstance] voutController] updateWindowLevelForHelperWindows: i_originalLevel];
     [self setLevel:i_originalLevel];
     [self setAlphaValue: config_GetFloat(VLCIntf, "macosx-opaqueness")];
     // if we quit fullscreen because there is no video anymore, make sure non-embedded window is not visible
     if (![[VLCMain sharedInstance] activeVideoPlayback] && [self class] != [VLCMainWindow class])
         [self orderOut: self];
-
-    [self unlockFullscreenAnimation];
 }
 
 - (void)animationDidEnd:(NSAnimation*)animation