display 'U' in status flags while update is running if idle support is off

This commit is contained in:
Andrzej Rybczak
2010-01-04 00:22:22 +01:00
parent ca0a48b14c
commit 0d05a550c2

View File

@@ -529,7 +529,7 @@ void NcmpcppStatusChanged(Connection *, StatusChanges changed, void *)
{ {
// mpd-0.{14,15} doesn't support idle notification that dbupdate had // mpd-0.{14,15} doesn't support idle notification that dbupdate had
// finished and nothing changed, so we need to switch it off for them. // finished and nothing changed, so we need to switch it off for them.
if (Mpd.Version() < 14 || Mpd.Version() > 15) if (!Mpd.SupportsIdle() || Mpd.Version() > 15)
mpd_db_updating = Mpd.GetDBIsUpdating() ? 'U' : 0; mpd_db_updating = Mpd.GetDBIsUpdating() ? 'U' : 0;
ShowMessage(Mpd.GetDBIsUpdating() ? "Database update started!" : "Database update finished!"); ShowMessage(Mpd.GetDBIsUpdating() ? "Database update started!" : "Database update finished!");
if (changed.Database && myScreen == mySelectedItemsAdder) if (changed.Database && myScreen == mySelectedItemsAdder)