[vlc-devel] commit: Qt: reverse Button. (Jean-Baptiste Kempf )

git version control git at videolan.org
Sat Feb 21 10:53:21 CET 2009


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Sat Feb 21 10:45:38 2009 +0100| [a04b972d1ee9bfd55f063ff1b3e415ab24163a2f] | committer: Jean-Baptiste Kempf 

Qt: reverse Button.

Make it checkable, change the text for the toolbar editor and show it only on input.

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

 modules/gui/qt4/components/controller.cpp |    6 +++++-
 modules/gui/qt4/components/controller.hpp |    2 +-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/modules/gui/qt4/components/controller.cpp b/modules/gui/qt4/components/controller.cpp
index b9e60d1..3cb2d23 100644
--- a/modules/gui/qt4/components/controller.cpp
+++ b/modules/gui/qt4/components/controller.cpp
@@ -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;
diff --git a/modules/gui/qt4/components/controller.hpp b/modules/gui/qt4/components/controller.hpp
index 43e8f7c..43ae9be 100644
--- a/modules/gui/qt4/components/controller.hpp
+++ b/modules/gui/qt4/components/controller.hpp
@@ -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"),




More information about the vlc-devel mailing list