Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
GSoC
GSoC2018
macOS
vlc
Commits
62dfbc38
Commit
62dfbc38
authored
Jun 21, 2016
by
Felix Paul Kühne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
macosx: fix time format overflow if playlist duration is > 24h
parent
933b6875
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
modules/gui/macosx/MainWindow.m
modules/gui/macosx/MainWindow.m
+5
-1
No files found.
modules/gui/macosx/MainWindow.m
View file @
62dfbc38
...
...
@@ -977,7 +977,11 @@ static const float f_min_window_height = 307.;
NSDate
*
date
=
[
NSDate
dateWithTimeIntervalSince1970
:
mt_duration
];
NSDateFormatter
*
formatter
=
[[
NSDateFormatter
alloc
]
init
];
[
formatter
setDateFormat
:
@"HH:mm:ss"
];
if
(
mt_duration
>=
86400
)
{
[
formatter
setDateFormat
:
@"dd:HH:mm:ss"
];
}
else
{
[
formatter
setDateFormat
:
@"HH:mm:ss"
];
}
[
formatter
setTimeZone
:[
NSTimeZone
timeZoneForSecondsFromGMT
:
0
]];
return
[
NSString
stringWithFormat
:
@" — %@"
,[
formatter
stringFromDate
:
date
]];
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment