]> git.sesse.net Git - vlc/blobdiff - modules/gui/qt4/main_interface.cpp
Cosmetic alignment.
[vlc] / modules / gui / qt4 / main_interface.cpp
index fda96ff3f18e5fb372a8cb929702853c7cf11e4a..8199129f435f614d342a79694b7980b5af16a01f 100644 (file)
@@ -81,13 +81,13 @@ MainInterface::MainInterface( intf_thread_t *_p_intf ) : QVLCMW( _p_intf )
 {
     /* Variables initialisation */
     // need_components_update = false;
-    bgWidget = NULL;
-    videoWidget = NULL;
-    playlistWidget = NULL;
-    sysTray = NULL;
-    videoIsActive = false;
-    playlistVisible = false;
-    input_name = "";
+    bgWidget         = NULL;
+    videoWidget      = NULL;
+    playlistWidget   = NULL;
+    sysTray          = NULL;
+    videoIsActive    = false;
+    playlistVisible  = false;
+    input_name       = "";
 
     /* Ask for privacy */
     askForPrivacy();
@@ -228,10 +228,6 @@ MainInterface::MainInterface( intf_thread_t *_p_intf ) : QVLCMW( _p_intf )
     CONNECT( fullscreenControls, advancedControlsToggled( bool ),
              this, doComponentsUpdate() );
 
-    CONNECT( THEMIM->getIM(), inputUnset(),
-            fullscreenControls, unregFullscreenCallback() );
-
-
     /* Size and placement of interface */
     QVLCTools::restoreWidgetPosition(settings,this,QSize(350,60));
 
@@ -387,16 +383,16 @@ void MainInterface::handleMainUi( QSettings *settings )
     mainLayout->setMargin( 0 );
 
     /* Create the CONTROLS Widget */
-    /* bool b_shiny = config_GetInt( p_intf, "qt-blingbling" ); */
+    bool b_shiny = config_GetInt( p_intf, "qt-blingbling" );
     controls = new ControlsWidget( p_intf, this,
                    settings->value( "adv-controls", false ).toBool(),
-                   config_GetInt( p_intf, "qt-blingbling" ) );
+                   b_shiny );
 
     /* Create the FULLSCREEN CONTROLS Widget */
     /* bool b_shiny = config_GetInt( p_intf, "qt-blingbling" ); */
     fullscreenControls = new FullscreenControllerWidget( p_intf, this,
                    settings->value( "adv-controls", false ).toBool(),
-                   config_GetInt( p_intf, "qt-blingbling" ) );
+                   b_shiny );
 
     /* Add the controls Widget to the main Widget */
     mainLayout->insertWidget( 0, controls, 0, Qt::AlignBottom );
@@ -467,7 +463,7 @@ int MainInterface::privacyDialog( QList<ConfigControl *> controls )
 {
     QDialog *privacy = new QDialog();
 
-    privacy->setWindowTitle( qtr( "Privacy and Network policies" ) );
+    privacy->setWindowTitle( qtr( "Privacy and Network Policies" ) );
 
     QGridLayout *gLayout = new QGridLayout( privacy );
 
@@ -477,7 +473,7 @@ int MainInterface::privacyDialog( QList<ConfigControl *> controls )
         "<p>The <i>VideoLAN Team</i> doesn't like when an application goes "
         "online without authorization.</p>\n "
         "<p><i>VLC media player</i> can request limited information on "
-        "the Internet, especially to get CD covers and songs metadata or to know "
+        "the Internet, especially to get CD covers or to know "
         "if updates are available.</p>\n"
         "<p><i>VLC media player</i> <b>DOES NOT</b> send or collect <b>ANY</b> "
         "information, even anonymously, about your usage.</p>\n"
@@ -516,13 +512,12 @@ int MainInterface::privacyDialog( QList<ConfigControl *> controls )
     }
 
     CONFIG_GENERIC( "album-art", IntegerList ); line++;
-    CONFIG_GENERIC_NOBOOL( "fetch-meta", Bool ); line++;
 #ifdef UPDATE_CHECK
     CONFIG_GENERIC_NOBOOL( "qt-updates-notif", Bool ); line++;
     CONFIG_GENERIC_NOBOOL( "qt-updates-days", Integer ); line++;
 #endif
 
-    QPushButton *ok = new QPushButton( qtr( "Ok" ) );
+    QPushButton *ok = new QPushButton( qtr( "OK" ) );
 
     gLayout->addWidget( ok, 2, 2 );
 
@@ -684,18 +679,14 @@ void *MainInterface::requestVideo( vout_thread_t *p_nvout, int *pi_x,
 //        emit askVideoToResize( *pi_width, *pi_height );
         emit askUpdate();
 
-        fullscreenControls->regFullscreenCallback( p_nvout );
+        fullscreenControls->attachVout( p_nvout );
     }
     return ret;
 }
 
-void MainInterface::requestNotEmbeddedVideo( vout_thread_t *p_nvout )
-{
-    fullscreenControls->regFullscreenCallback( p_nvout );
-}
-
-void MainInterface::releaseVideo( void *p_win )
+void MainInterface::releaseVideo( vout_thread_t *p_vout, void *p_win )
 {
+    fullscreenControls->detachVout( p_vout );
     emit askReleaseVideo( p_win );
 }
 
@@ -805,6 +796,8 @@ void MainInterface::undockPlaylist()
 
 void MainInterface::toggleMinimalView()
 {
+    /* HACK for minimalView, see menus.cpp */
+    if( !menuBar()->isVisible() ) QVLCMenu::minimalViewAction->toggle();
     TOGGLEV( menuBar() );
     TOGGLEV( controls );
     TOGGLEV( statusBar() );