[vlc-commits] macosx: use vlc_tick_t with the input "length"

Steve Lhomme git at videolan.org
Fri Jul 6 12:42:17 CEST 2018


vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Sat May  5 17:57:38 2018 +0200| [9ae4f878d50d7a9ef5816bc02b68b42451433b6a] | committer: Steve Lhomme

macosx: use vlc_tick_t with the input "length"

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

 modules/gui/macosx/VLCMainMenu.m | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules/gui/macosx/VLCMainMenu.m b/modules/gui/macosx/VLCMainMenu.m
index 93bf7f1455..f10b88d07a 100644
--- a/modules/gui/macosx/VLCMainMenu.m
+++ b/modules/gui/macosx/VLCMainMenu.m
@@ -835,8 +835,8 @@
     input_thread_t *p_input = pl_CurrentInput(getIntf());
     if (p_input) {
         /* we can obviously only do that if an input is available */
-        int64_t length = var_GetInteger(p_input, "length");
-        [_timeSelectionPanel setMaxValue:(int)(length / CLOCK_FREQ)];
+        vlc_tick_t length = var_GetInteger(p_input, "length");
+        [_timeSelectionPanel setMaxValue:(int)SEC_FROM_VLC_TICK(length)];
         vlc_tick_t pos = var_GetInteger(p_input, "time");
         [_timeSelectionPanel setJumpTimeValue: (int)SEC_FROM_VLC_TICK(pos)];
         [_timeSelectionPanel runModalForWindow:[NSApp mainWindow]



More information about the vlc-commits mailing list