[vlc-commits] macosx: do not display double negative time when duration is unknown (0)

David Fuhrmann git at videolan.org
Sun Apr 29 23:49:12 CEST 2012


vlc/vlc-2.0 | branch: master | David Fuhrmann <david.fuhrmann at googlemail.com> | Sun Apr 29 21:20:31 2012 +0200| [a703f24583c188ac153b7e5617ddb309323d8548] | committer: Jean-Baptiste Kempf

macosx: do not display double negative time when duration is unknown (0)
(cherry picked from commit 29442477ade3b0f18c2c0ae2a0da6c112beed4c0)

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

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

 modules/gui/macosx/MainWindow.m |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/modules/gui/macosx/MainWindow.m b/modules/gui/macosx/MainWindow.m
index 9ccd256..7107d36 100644
--- a/modules/gui/macosx/MainWindow.m
+++ b/modules/gui/macosx/MainWindow.m
@@ -1222,7 +1222,7 @@ static VLCMainWindow *_o_sharedInstance = nil;
         var_Get( p_input, "time", &time );
 
         mtime_t dur = input_item_GetDuration( input_GetItem( p_input ) );
-        if( [o_time_fld timeRemaining] && dur != -1 )
+        if( [o_time_fld timeRemaining] && dur > 0 )
         {
             o_time = [NSString stringWithFormat: @"-%s", secstotimestr( psz_time, ((dur - time.i_time) / 1000000))];
         }



More information about the vlc-commits mailing list