Qt: reverse Button.
authorJean-Baptiste Kempf <jb@videolan.org>
Sat, 21 Feb 2009 09:45:38 +0000 (10:45 +0100)
committerJean-Baptiste Kempf <jb@videolan.org>
Sat, 21 Feb 2009 09:52:03 +0000 (10:52 +0100)
Make it checkable, change the text for the toolbar editor and show it only on input.

modules/gui/qt4/components/controller.cpp
modules/gui/qt4/components/controller.hpp

index b9e60d1..3cb2d23 100644 (file)
@@ -380,7 +380,11 @@ QWidget *AbstractController::createWidget( buttonType_e button, int options )
         setupButton( reverseButton );
         CONNECT_MAP_SET( reverseButton, REVERSE_ACTION );
         BUTTON_SET_BAR(  reverseButton );
-        ENABLE_ON_INPUT( reverseButton );
+        reverseButton->setCheckable( true );
+        /* You should, of COURSE change this to the correct event,
+           when/if we have one, that tells us if trickplay is possible . */
+        CONNECT( this, inputExists( bool ), reverseButton, setVisible( bool ) );
+        reverseButton->setVisible( false );
         widget = reverseButton;
         }
         break;
index 43e8f7c..43ae9be 100644 (file)
@@ -101,7 +101,7 @@ typedef enum buttonType_e
 static const QString nameL[BUTTON_MAX] = { "Play", "Stop", "Open",
     "Previous", "Next", "Slower", "Faster", "Fullscreen", "De-Fullscreen",
     "Extended panel", "Playlist", "Snapshot", "Record", "A->B Loop",
-    "Frame By Frame", "Reverse", "Skip backward" , "Skip forward",
+    "Frame By Frame", "Trickplay Reverse", "Skip backward" , "Skip forward",
     "Quit" };
 static const QString tooltipL[BUTTON_MAX] = { I_PLAY_TOOLTIP,
     _("Stop playback"), _("Open a media"),