]> git.sesse.net Git - vlc/commitdiff
Qt: set TimeLabel to --:--/--:-- when input is stopped.
authorJean-Baptiste Kempf <jb@videolan.org>
Sat, 17 Jan 2009 16:37:07 +0000 (17:37 +0100)
committerJean-Baptiste Kempf <jb@videolan.org>
Sat, 17 Jan 2009 18:14:10 +0000 (19:14 +0100)
modules/gui/qt4/components/interface_widgets.cpp

index 365c879b6e00182301f5a474016c23a9d92503e0..401047221e2dc6b18be56641c8156fcd86a24e00 100644 (file)
@@ -463,7 +463,11 @@ TimeLabel::TimeLabel( intf_thread_t *_p_intf  ) :QLabel(), p_intf( _p_intf )
 
 void TimeLabel::setDisplayPosition( float pos, int time, int length )
 {
-    VLC_UNUSED( pos );
+    if( pos == -1 )
+    {
+        setText( " --:--/--:-- " );
+        return;
+    }
 
     char psz_length[MSTRTIME_MAX_SIZE], psz_time[MSTRTIME_MAX_SIZE];
     secstotimestr( psz_length, length );