From 02756c38c8c6da1a7edd63233820c494eb000c4c Mon Sep 17 00:00:00 2001
From: Hannes Domani <ssbssa@yahoo.de>
Date: Tue, 21 Oct 2008 19:11:41 +0200
Subject: [PATCH] qt4: don't change volume at startup

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

diff --git a/modules/gui/qt4/components/interface_widgets.cpp b/modules/gui/qt4/components/interface_widgets.cpp
index 6fca0ca..c03bf99 100644
--- a/modules/gui/qt4/components/interface_widgets.cpp
+++ b/modules/gui/qt4/components/interface_widgets.cpp
@@ -504,6 +504,7 @@ void AdvControlsWidget::record()
 void AdvControlsWidget::frame(){}
 #endif
 
+static bool b_my_volume;
 /*****************************
  * DA Control Widget !
  *****************************/
@@ -738,7 +739,9 @@ ControlsWidget::ControlsWidget( intf_thread_t *_p_i,
                               VOLUME_MAX / (AOUT_VOLUME_MAX/2) );
 
     /* Force the update at build time in order to have a muted icon if needed */
+    b_my_volume = true;
     updateVolume( volumeSlider->value() );
+    b_my_volume = false;
 
     /* Volume control connection */
     CONNECT( volumeSlider, valueChanged( int ), this, updateVolume( int ) );
@@ -888,7 +891,6 @@ void ControlsWidget::setNavigation( int navigation )
     }
 }
 
-static bool b_my_volume;
 void ControlsWidget::updateVolume( int i_sliderVolume )
 {
     if( !b_my_volume )
-- 
1.5.6.1.1071.g76fb

