DetachedSong: use std::chrono::duration for start_ms and end_ms

This commit is contained in:
Max Kellermann
2014-08-28 06:54:19 +02:00
parent 854258f376
commit 6ad933982f
12 changed files with 57 additions and 51 deletions

View File

@@ -185,15 +185,15 @@ ToString(const DetachedSong &song)
result.push_back('|');
if (song.GetStartMS() > 0) {
sprintf(buffer, "%u", song.GetStartMS());
if (song.GetStartTime().IsPositive()) {
sprintf(buffer, "%u", song.GetStartTime().ToMS());
result.append(buffer);
}
result.push_back('-');
if (song.GetEndMS() > 0) {
sprintf(buffer, "%u", song.GetEndMS());
if (song.GetEndTime().IsPositive()) {
sprintf(buffer, "%u", song.GetEndTime().ToMS());
result.append(buffer);
}