From 99680cca7fe0249091fc20c5583cfd02cdbf0ef4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Wei=C3=9F?= Date: Tue, 4 May 2021 14:03:31 +0200 Subject: [PATCH] =?UTF-8?q?Don=E2=80=99t=20enforce=20leading=20double-digi?= =?UTF-8?q?ts=20in=20position=20time=20display.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Window/TimeField.m | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Window/TimeField.m b/Window/TimeField.m index 594401dd7..2c3e28184 100644 --- a/Window/TimeField.m +++ b/Window/TimeField.m @@ -25,7 +25,7 @@ NSString * timeStringForTimeInterval(NSTimeInterval timeInterval, BOOL enforceMi if (days > 0) { timeString = - [NSString localizedStringWithFormat:@"%s" "%02" PRIi64 ":" "%02" PRIi64 ":" "%02" PRIi64 ":" "%02" PRIi64, + [NSString localizedStringWithFormat:@"%s" "%" PRIi64 ":" "%02" PRIi64 ":" "%02" PRIi64 ":" "%02" PRIi64, need_minus_sign ? "-" : "", days, hours, @@ -34,7 +34,7 @@ NSString * timeStringForTimeInterval(NSTimeInterval timeInterval, BOOL enforceMi } else if (hours > 0) { timeString = - [NSString localizedStringWithFormat:@"%s" "%02" PRIi64 ":" "%02" PRIi64 ":" "%02" PRIi64, + [NSString localizedStringWithFormat:@"%s" "%" PRIi64 ":" "%02" PRIi64 ":" "%02" PRIi64, need_minus_sign ? "-" : "", hours, minutes, @@ -42,14 +42,14 @@ NSString * timeStringForTimeInterval(NSTimeInterval timeInterval, BOOL enforceMi } else if (minutes > 0) { timeString = - [NSString localizedStringWithFormat:@"%s" "%02" PRIi64 ":" "%02" PRIi64, + [NSString localizedStringWithFormat:@"%s" "%" PRIi64 ":" "%02" PRIi64, need_minus_sign ? "-" : "", minutes, seconds]; } else { timeString = - [NSString localizedStringWithFormat:@"%s" "00" ":" "%02" PRIi64, + [NSString localizedStringWithFormat:@"%s" "0" ":" "%02" PRIi64, need_minus_sign ? "-" : "", seconds]; }