diff --git a/src/core/mainwindow.cpp b/src/core/mainwindow.cpp index 516a2f68b..1c2109098 100644 --- a/src/core/mainwindow.cpp +++ b/src/core/mainwindow.cpp @@ -197,6 +197,7 @@ #include "smartplaylists/smartplaylistsviewcontainer.h" #include "smartplaylists/smartplaylistsview.h" +#include #ifdef Q_OS_WIN # include "windows7thumbbar.h" @@ -210,6 +211,8 @@ # endif #endif // HAVE_QTSPARKLE +using namespace std::chrono_literals; + const char *MainWindow::kSettingsGroup = "MainWindow"; const char *MainWindow::kAllFilesFilterSpec = QT_TR_NOOP("All Files (*)"); @@ -1441,7 +1444,7 @@ void MainWindow::LoadPlaybackStatus() { std::shared_ptr connection = std::make_shared(); *connection = QObject::connect(app_->playlist_manager(), &PlaylistManager::AllPlaylistsLoaded, this, [this, connection]() { QObject::disconnect(*connection); - QTimer::singleShot(400, this, &MainWindow::ResumePlayback); + QTimer::singleShot(400ms, this, &MainWindow::ResumePlayback); }); }