From: Steinar H. Gunderson Date: Mon, 1 May 2023 10:32:33 +0000 (+0200) Subject: Minor STL quibbles. X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=96a8283e63e63c44cd7958f9549ce1dec65aae46;p=pkanalytics Minor STL quibbles. --- diff --git a/stats.cpp b/stats.cpp index b0ba4b3..5124ca3 100644 --- a/stats.cpp +++ b/stats.cpp @@ -4,6 +4,7 @@ #include #include #include +#include #include #include #include @@ -14,7 +15,7 @@ using namespace std; -std::string format_timestamp(uint64_t pos) +string format_timestamp(uint64_t pos) { int ms = pos % 1000; pos /= 1000; @@ -229,7 +230,7 @@ void MainWindow::setModel(QAbstractItemModel *model) void MainWindow::seek(int64_t delta_ms) { int64_t current_pos = buffered_seek ? *buffered_seek : player->position(); - uint64_t pos = std::max(current_pos + delta_ms, 0); + uint64_t pos = max(current_pos + delta_ms, 0); buffered_seek = pos; if (!playing) { player->setPlaybackRate(0.01);