fix(mpd): Ignore timer updates if not playing
This commit is contained in:
parent
3319bd10c5
commit
7490841e55
1 changed files with 1 additions and 1 deletions
|
@ -131,7 +131,7 @@ bool MpdModule::has_event()
|
||||||
has_event = true;
|
has_event = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this->label_time || this->bar_progress) {
|
if ((this->label_time || this->bar_progress) && (this->status && this->status->state & mpd::State::PLAYING)) {
|
||||||
auto now = std::chrono::system_clock::now();
|
auto now = std::chrono::system_clock::now();
|
||||||
|
|
||||||
if (std::chrono::duration_cast<std::chrono::milliseconds>(now - this->synced_at).count() > this->sync_interval) {
|
if (std::chrono::duration_cast<std::chrono::milliseconds>(now - this->synced_at).count() > this->sync_interval) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue