]> git.sesse.net Git - vlc/commitdiff
Qt4 - Fullscreen button should work now. hasVideo() does not work, so force the activ...
authorJean-Baptiste Kempf <jb@videolan.org>
Sat, 8 Sep 2007 13:53:58 +0000 (13:53 +0000)
committerJean-Baptiste Kempf <jb@videolan.org>
Sat, 8 Sep 2007 13:53:58 +0000 (13:53 +0000)
modules/gui/qt4/components/interface_widgets.cpp

index 43ae595bf3936123c249dc97db216264c9f6cc19..06699e3f977600ebe19eec7bf0186a43053916cc 100644 (file)
@@ -300,7 +300,7 @@ ControlsWidget::ControlsWidget( intf_thread_t *_p_i, bool b_advControls ) :
     //QSize size( 500, 200 );
     //resize( size );
     controlLayout = new QGridLayout( this );
-    
+
 #if DEBUG_COLOR
     QPalette palette2;
     palette2.setColor(this->backgroundRole(), Qt::magenta);
@@ -583,7 +583,8 @@ void ControlsWidget::updateOnTimer()
 
     /* Activate the interface buttons according to the presence of the input */
     enableInput( THEMIM->getIM()->hasInput() );
-    enableVideo( THEMIM->getIM()->hasVideo() );
+    enableVideo( true );
+    //enableVideo( THEMIM->getIM()->hasVideo() );
 }
 
 void ControlsWidget::setStatus( int status )
@@ -605,8 +606,11 @@ void ControlsWidget::fullscreen()
     vlc_object_t *p_vout = (vlc_object_t *)vlc_object_find( p_intf,
                 VLC_OBJECT_VOUT, FIND_CHILD );
     if( p_vout)
-        var_SetBool( p_vout, "fullscreen", VLC_TRUE );
-    //msg_Dbg( p_intf, "Not implemented yet" );
+    {
+        var_Get( p_vout, "fullscreen", &val );
+        val.b_bool = !val.b_bool;
+        var_Set( p_vout, "fullscreen", val );
+    }
 }
 
 void ControlsWidget::extSettings()
@@ -639,7 +643,7 @@ void ControlsWidget::enableInput( bool enable )
 }
 
 void ControlsWidget::enableVideo( bool enable )
-{  
+{
     // TODO Later make the fullscreenButton toggle Visualisation and so on.
     fullscreenButton->setEnabled( enable );