diff --git a/src/playlist/playlist.cpp b/src/playlist/playlist.cpp index df67a084d..c19d883a0 100644 --- a/src/playlist/playlist.cpp +++ b/src/playlist/playlist.cpp @@ -1524,7 +1524,7 @@ void Playlist::StopAfter(int row) { else stop_after_ = index(row, 0); - // stop_after_.isValid() == true when there there is a stop placed + // stop_after_.isValid() == true when there is a stop placed // somewhere on the playlist. Emit a StopAfterToggled signal that // reflects this. emit StopAfterToggled(stop_after_.isValid()); diff --git a/src/ui/mainwindow.cpp b/src/ui/mainwindow.cpp index 4f2b8a422..d3246d9d2 100644 --- a/src/ui/mainwindow.cpp +++ b/src/ui/mainwindow.cpp @@ -690,9 +690,7 @@ MainWindow::MainWindow(Application* app, app_->playlist_manager()->Init(app_->library_backend(), app_->playlist_backend(), ui_->playlist_sequence, ui_->playlist); - // Connect the playlist signal "StopAfterToggled with the - // StopAfterToggle OSD slot. This must be done after the playlist - // has been initialized. + // This connection must be done after the playlist has been initialized. connect(app_->playlist_manager()->current(), SIGNAL(StopAfterToggled(bool)), osd_, SLOT(StopAfterToggle(bool))); diff --git a/src/widgets/osd.cpp b/src/widgets/osd.cpp index b71e651f1..c2dfe8b81 100644 --- a/src/widgets/osd.cpp +++ b/src/widgets/osd.cpp @@ -167,13 +167,8 @@ void OSD::Stopped() { } void OSD::StopAfterToggle(bool stop) { - if (stop) { - ShowMessage(QCoreApplication::applicationName(), - tr("Stop playing after track: On")); - } else { - ShowMessage(QCoreApplication::applicationName(), - tr("Stop playing after track: Off")); - } + ShowMessage(QCoreApplication::applicationName(), + tr("Stop playing after track: %1").arg(stop ? tr("On") : tr("Off"))); } void OSD::PlaylistFinished() {