2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

Support new plural keys format.

All the old plural phrases were changed to work with the new format.
This commit is contained in:
John Preston
2017-06-02 14:46:02 +03:00
parent b6046d829f
commit 85e6f55536
27 changed files with 593 additions and 298 deletions

View File

@@ -130,8 +130,10 @@ QString formatDurationText(qint64 duration) {
QString formatDurationWords(qint64 duration) {
if (duration > 59) {
auto minutes = (duration / 60);
auto minutesCount = lng_duration_minsec_minutes(lt_count, minutes);
auto seconds = (duration % 60);
return lng_duration_minutes_seconds(lt_count_minutes, minutes, lt_count_seconds, seconds);
auto secondsCount = lng_duration_minsec_seconds(lt_count, seconds);
return lng_duration_minutes_seconds(lt_minutes_count, minutesCount, lt_seconds_count, secondsCount);
}
return lng_duration_seconds(lt_count, duration);
}