[vlc-commits] commit: Qt: simple_prefs audio: Use defined values Fixes #3351 ( Francois Cartegnie )

git at videolan.org git at videolan.org
Wed Jul 28 20:06:38 CEST 2010


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Sat Jul 10 19:13:40 2010 +0200| [af3aef780e449b296b86625fb65d74832d2a4daa] | committer: Francois Cartegnie 

Qt: simple_prefs audio: Use defined values Fixes #3351

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

 modules/gui/qt4/components/simple_preferences.cpp |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/modules/gui/qt4/components/simple_preferences.cpp b/modules/gui/qt4/components/simple_preferences.cpp
index ee7aedc..2613adc 100644
--- a/modules/gui/qt4/components/simple_preferences.cpp
+++ b/modules/gui/qt4/components/simple_preferences.cpp
@@ -310,6 +310,7 @@ SPrefsPanel::SPrefsPanel( intf_thread_t *_p_intf, QWidget *_parent,
 #undef audioCommon
 
             /* Audio Options */
+            ui.volumeValue->setMaximum( QT_VOLUME_MAX / QT_VOLUME_DEFAULT * 100 );
             CONFIG_GENERIC_NO_BOOL( "qt-startvolume" , IntegerRangeSlider, NULL,
                                      defaultVolume );
             CONNECT( ui.defaultVolume, valueChanged( int ),
@@ -729,7 +730,7 @@ SPrefsPanel::~SPrefsPanel()
 void SPrefsPanel::updateAudioVolume( int volume )
 {
     qobject_cast<QSpinBox *>(optionWidgets[volLW])
-        ->setValue( volume * 100 / 256 );
+        ->setValue( volume * 100 / QT_VOLUME_DEFAULT );
 }
 
 



More information about the vlc-commits mailing list