[vlc-devel] commit: Fix toggling of transparency on teletext pages. Keep in mind that the subpicture core seems to be broken. It doesn' t remove old subpictures with the ephemer setting as it used to do. ( Jean-Paul Saman )

git version control git at videolan.org
Fri Jun 20 16:37:54 CEST 2008


vlc | branch: master | Jean-Paul Saman <jpsaman at videolan.org> | Fri Jun 20 16:36:08 2008 +0200| [6ba2d51e5da45ca6a30709b902c6f4369e2b409a]

Fix toggling of transparency on teletext pages. Keep in mind that the subpicture core seems to be broken. It doesn't remove old subpictures with the ephemer setting as it used to do.

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

 modules/gui/qt4/components/interface_widgets.cpp |    2 +-
 modules/gui/qt4/input_manager.cpp                |    6 ++++--
 modules/gui/qt4/input_manager.hpp                |    3 ++-
 3 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/modules/gui/qt4/components/interface_widgets.cpp b/modules/gui/qt4/components/interface_widgets.cpp
index e01ea52..4ba788d 100644
--- a/modules/gui/qt4/components/interface_widgets.cpp
+++ b/modules/gui/qt4/components/interface_widgets.cpp
@@ -504,7 +504,7 @@ ControlsWidget::ControlsWidget( intf_thread_t *_p_i,
     BUTTON_SET_ACT_I( telexTransparent, "", tvtelx.png, qtr( "Teletext" ),
                       toggleTeletextTransparency() );
     CONNECT( telexTransparent, clicked( bool ),
-             THEMIM->getIM(), telexSetTransparency( bool ) );
+             THEMIM->getIM(), telexSetTransparency() );
     CONNECT( THEMIM->getIM(), teletextEnabled( bool ),
              telexFrame, setVisible( bool ) );
 
diff --git a/modules/gui/qt4/input_manager.cpp b/modules/gui/qt4/input_manager.cpp
index b7b510c..cb655df 100644
--- a/modules/gui/qt4/input_manager.cpp
+++ b/modules/gui/qt4/input_manager.cpp
@@ -63,6 +63,7 @@ InputManager::InputManager( QObject *parent, intf_thread_t *_p_intf) :
     p_input      = NULL;
     i_rate       = 0;
     i_input_id   = 0;
+    b_transparentTelextext = false;
 }
 
 InputManager::~InputManager()
@@ -440,7 +441,7 @@ void InputManager::telexToggle( bool b_enabled )
     telexGotoPage( i_page );
 }
 
-void InputManager::telexSetTransparency( bool b_transp )
+void InputManager::telexSetTransparency()
 {
     if( hasInput() )
     {
@@ -449,7 +450,8 @@ void InputManager::telexSetTransparency( bool b_transp )
                     "zvbi", FIND_ANYWHERE );
         if( p_vbi )
         {
-            var_SetBool( p_input->p_libvlc, "vbi-opaque", b_transp );
+            var_SetBool( p_vbi, "vbi-opaque", b_transparentTelextext );
+            b_transparentTelextext = !b_transparentTelextext;
             vlc_object_release( p_vbi );
         }
     }
diff --git a/modules/gui/qt4/input_manager.hpp b/modules/gui/qt4/input_manager.hpp
index 402dfe6..1cf835b 100644
--- a/modules/gui/qt4/input_manager.hpp
+++ b/modules/gui/qt4/input_manager.hpp
@@ -77,6 +77,7 @@ private:
     QString         old_name;
     QString         artUrl;
     int             i_rate;
+    bool            b_transparentTelextext;
 
     void customEvent( QEvent * );
     void addCallbacks();
@@ -102,7 +103,7 @@ public slots:
     void sectionMenu();
     void telexGotoPage( int ); ///< Goto teletext page
     void telexToggle( bool );  ///< Enable disable teletext buttons
-    void telexSetTransparency( bool ); ///< Set transparency on teletext background
+    void telexSetTransparency(); ///< Set transparency on teletext background
 
 signals:
     /// Send new position, new time and new length




More information about the vlc-devel mailing list