[vlc-devel] commit: Show stylesCombo only on Linux and Win32-debug ( Jean-Baptiste Kempf )

git version control git at videolan.org
Wed Aug 12 00:13:31 CEST 2009


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Wed Aug 12 00:12:53 2009 +0200| [e3fad8c3bdf9faa935c420104ea019a10ae12612] | committer: Jean-Baptiste Kempf 

Show stylesCombo only on Linux and Win32-debug

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

 modules/gui/qt4/components/simple_preferences.cpp |   23 +++++++++++----------
 1 files changed, 12 insertions(+), 11 deletions(-)

diff --git a/modules/gui/qt4/components/simple_preferences.cpp b/modules/gui/qt4/components/simple_preferences.cpp
index d905ac8..e167796 100644
--- a/modules/gui/qt4/components/simple_preferences.cpp
+++ b/modules/gui/qt4/components/simple_preferences.cpp
@@ -44,12 +44,10 @@
 #include <QSettings>
 #include <QtAlgorithms>
 
-#include <string>
-
 #define ICON_HEIGHT 64
 
 #ifdef WIN32
-#include "vistaassoc.h"
+# include "vistaassoc.h"
 #endif
 
 /*********************************************************************
@@ -497,14 +495,6 @@ SPrefsPanel::SPrefsPanel( intf_thread_t *_p_intf, QWidget *_parent,
             ui.languageBox->hide();
             ui.assoBox->hide();
 #endif
-            ui.stylesCombo->addItems( QStyleFactory::keys() );
-            ui.stylesCombo->setCurrentIndex( ui.stylesCombo->findText(
-                        getSettings()->value( "MainWindow/QtStyle", "" ).toString() ) );
-            ui.stylesCombo->insertSeparator( 1 );
-
-            CONNECT( ui.stylesCombo, currentIndexChanged( QString ), this, changeStyle( QString ) );
-
-
             /* interface */
             char *psz_intf = config_GetPsz( p_intf, "intf" );
             if( psz_intf )
@@ -519,7 +509,17 @@ SPrefsPanel::SPrefsPanel( intf_thread_t *_p_intf, QWidget *_parent,
 
             optionWidgets.append( ui.skins );
             optionWidgets.append( ui.qt4 );
+#if !defined(NDEBUG) || !defined( WIN32)
+            ui.stylesCombo->addItems( QStyleFactory::keys() );
+            ui.stylesCombo->setCurrentIndex( ui.stylesCombo->findText(
+                        getSettings()->value( "MainWindow/QtStyle", "" ).toString() ) );
+            ui.stylesCombo->insertSeparator( 1 );
+
+            CONNECT( ui.stylesCombo, currentIndexChanged( QString ), this, changeStyle( QString ) );
             optionWidgets.append( ui.stylesCombo );
+#else
+            ui.styleCombo->hide();
+#endif
 
             ui.skins_zone->setEnabled( ui.skins->isChecked() );
             CONNECT( ui.skins, toggled( bool ), ui.skins_zone, setEnabled( bool ) );
@@ -817,6 +817,7 @@ void SPrefsPanel::changeStyle( QString s_style )
 #include <QDialogButtonBox>
 #include <QHeaderView>
 #include "util/registry.hpp"
+#include <string>
 
 bool SPrefsPanel::addType( const char * psz_ext, QTreeWidgetItem* current,
                            QTreeWidgetItem* parent, QVLCRegistry *qvReg )




More information about the vlc-devel mailing list