[vlc-devel] commit: Fix #1896 (Jean-Baptiste Kempf )

git version control git at videolan.org
Sat Aug 23 08:34:15 CEST 2008


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Fri Aug 22 23:36:43 2008 -0700| [2329f4afe2ee3c0599d2c61bb562045e51793abf] | committer: Jean-Baptiste Kempf 

Fix #1896

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

 modules/gui/qt4/components/extended_panels.cpp |   13 ++++++-------
 1 files changed, 6 insertions(+), 7 deletions(-)

diff --git a/modules/gui/qt4/components/extended_panels.cpp b/modules/gui/qt4/components/extended_panels.cpp
index 299fe15..3a79dae 100644
--- a/modules/gui/qt4/components/extended_panels.cpp
+++ b/modules/gui/qt4/components/extended_panels.cpp
@@ -1270,8 +1270,8 @@ SyncControls::SyncControls( intf_thread_t *_p_intf, QWidget *_parent ) :
     AVSpin = new QDoubleSpinBox;
     AVSpin->setAlignment( Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter );
     AVSpin->setDecimals( 3 );
-    AVSpin->setMinimum( -100 );
-    AVSpin->setMaximum( 100 );
+    AVSpin->setMinimum( -100.0 );
+    AVSpin->setMaximum( 100.0 );
     AVSpin->setSingleStep( 0.1 );
     AVSpin->setToolTip( qtr( "A positive value means that\n"
                              "the audio is ahead of the video" ) );
@@ -1303,8 +1303,8 @@ SyncControls::SyncControls( intf_thread_t *_p_intf, QWidget *_parent ) :
     subsSpin = new QDoubleSpinBox;
     subsSpin->setAlignment( Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter );
     subsSpin->setDecimals( 3 );
-    subsSpin->setMinimum( -100 );
-    subsSpin->setMaximum( 100 );
+    subsSpin->setMinimum( -100.0 );
+    subsSpin->setMaximum( 100.0 );
     subsSpin->setSingleStep( 0.1 );
     subsSpin->setToolTip( qtr( "A positive value means that\n"
                              "the subtitles are ahead of the video" ) );
@@ -1379,9 +1379,8 @@ void SyncControls::advanceAudio( double f_advance )
     if( THEMIM->getInput() )
     {
         int64_t i_delay = var_GetTime( THEMIM->getInput(), "audio-delay" );
-        i_delay += f_advance * 1000000;
+        i_delay = f_advance * 1000000;
         var_SetTime( THEMIM->getInput(), "audio-delay", i_delay );
-        msg_Dbg( p_intf, "I am advancing Audio %d", f_advance );
     }
 }
 
@@ -1390,7 +1389,7 @@ void SyncControls::advanceSubs( double f_advance )
     if( THEMIM->getInput() )
     {
         int64_t i_delay = var_GetTime( THEMIM->getInput(), "spu-delay" );
-        i_delay += f_advance * 1000000;
+        i_delay = f_advance * 1000000;
         var_SetTime( THEMIM->getInput(), "spu-delay", i_delay );
         msg_Dbg( p_intf, "I am advancing subtitles %d", f_advance );
     }




More information about the vlc-devel mailing list