]> git.sesse.net Git - vlc/commitdiff
Qt: actually activate random action
authorJean-Baptiste Kempf <jb@videolan.org>
Sun, 29 Nov 2009 16:13:07 +0000 (17:13 +0100)
committerJean-Baptiste Kempf <jb@videolan.org>
Fri, 4 Dec 2009 06:21:39 +0000 (07:21 +0100)
modules/gui/qt4/actions_manager.cpp
modules/gui/qt4/input_manager.cpp
modules/gui/qt4/input_manager.hpp

index e4ac5a4a4f3b0e5658aa651fb9974fe232504c7b..fe8d6b4f1126785d83da3e3e7ba2a811927b6560 100644 (file)
@@ -90,8 +90,7 @@ void ActionsManager::doAction( int id_action )
         case QUIT_ACTION:
             THEDP->quit();  break;
         case RANDOM_ACTION:
-            // FIXME
-            break;
+            THEMIM->toggleRandom(); break;
         default:
             msg_Dbg( p_intf, "Action: %i", id_action );
             break;
index ee16a914d36f1c4ac2ded11c6636a8eeb20400ad..77d09fc36d0f02e18de9421d6afc1d808fea3d92 100644 (file)
@@ -1029,6 +1029,11 @@ void MainInputManager::togglePlayPause()
         getIM()->togglePlayPause();
 }
 
+void MainInputManager::toggleRandom()
+{
+    var_ToggleBool( THEPL, "random" );
+}
+
 void MainInputManager::activatePlayQuit( bool b_exit )
 {
     var_SetBool( THEPL, "play-and-exit", b_exit );
index 688eb6685dc7bb57ee56f7c89f783c95d233e189..31694944c1ac0a228344e6e4f4b669d648f8ffa8 100644 (file)
@@ -258,6 +258,7 @@ private:
 
 public slots:
     void togglePlayPause();
+    void toggleRandom();
     void stop();
     void next();
     void prev();