]> git.sesse.net Git - vlc/commitdiff
macosx: Use var_GetBool.
authorPierre d'Herbemont <pdherbemont@videolan.org>
Sun, 15 Jun 2008 20:02:57 +0000 (22:02 +0200)
committerPierre d'Herbemont <pdherbemont@videolan.org>
Sun, 15 Jun 2008 20:03:34 +0000 (22:03 +0200)
modules/gui/macosx/playlist.m

index cbae24b6b431a59ba30a0e9074280e8623c57416..7450e9b712cd3c789af65272457f07f951fa0d5a 100644 (file)
@@ -92,7 +92,6 @@
 
 @end
 
-
 /*****************************************************************************
  * VLCPlaylistCommon implementation
  *
 - (void)playModeUpdated
 {
     playlist_t *p_playlist = pl_Yield( VLCIntf );
-    vlc_value_t val, val2;
 
-    var_Get( p_playlist, "loop", &val2 );
-    var_Get( p_playlist, "repeat", &val );
-    if( val.b_bool == true )
-    {
+    bool loop = var_GetBool( p_playlist, "loop" );
+    bool repeat = var_GetBool( p_playlist, "repeat" );
+    if( repeat )
         [[[VLCMain sharedInstance] getControls] repeatOne];
-   }
-    else if( val2.b_bool == true )
-    {
+    else if( loop )
         [[[VLCMain sharedInstance] getControls] repeatAll];
-    }
     else
-    {
         [[[VLCMain sharedInstance] getControls] repeatOff];
-    }
 
     [[[VLCMain sharedInstance] getControls] shuffle];