[vlc-commits] macosx: remove dead code, small reformatting

David Fuhrmann git at videolan.org
Fri Jan 2 21:58:35 CET 2015


vlc | branch: master | David Fuhrmann <dfuhrmann at videolan.org> | Thu Jan  1 17:53:00 2015 +0100| [bb80b4369b32e6e8c6b2ce1a9e41093eff221c54] | committer: David Fuhrmann

macosx: remove dead code, small reformatting

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=bb80b4369b32e6e8c6b2ce1a9e41093eff221c54
---

 modules/gui/macosx/CoreInteraction.m |   12 +++---------
 1 file changed, 3 insertions(+), 9 deletions(-)

diff --git a/modules/gui/macosx/CoreInteraction.m b/modules/gui/macosx/CoreInteraction.m
index 4f50497..5d13a5f 100644
--- a/modules/gui/macosx/CoreInteraction.m
+++ b/modules/gui/macosx/CoreInteraction.m
@@ -70,20 +70,14 @@ static VLCCoreInteraction *_o_sharedInstance = nil;
 
 - (void)playOrPause
 {
-    input_thread_t * p_input;
-    p_input = pl_CurrentInput(VLCIntf);
-    playlist_t * p_playlist = pl_Get(VLCIntf);
+    input_thread_t *p_input = pl_CurrentInput(VLCIntf);
+    playlist_t *p_playlist = pl_Get(VLCIntf);
 
     if (p_input) {
         playlist_TogglePause(p_playlist);
         vlc_object_release(p_input);
-    } else {
-        bool empty;
-
-        PL_LOCK;
-        empty = playlist_IsEmpty(p_playlist);
-        PL_UNLOCK;
 
+    } else {
         PLRootType root = [[[[VLCMain sharedInstance] playlist] model] currentRootType];
         if ([[[VLCMain sharedInstance] playlist] isSelectionEmpty] && (root == ROOT_TYPE_PLAYLIST || root == ROOT_TYPE_MEDIALIBRARY))
             [[[VLCMain sharedInstance] open] openFileGeneric];



More information about the vlc-commits mailing list