summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f54c588)
raw | patch | inline | side by side (parent: f54c588)
author | Max Kellermann <max@duempel.org> | |
Wed, 30 Sep 2009 18:28:38 +0000 (20:28 +0200) | ||
committer | Max Kellermann <max@duempel.org> | |
Wed, 30 Sep 2009 18:28:38 +0000 (20:28 +0200) |
src/screen.c | patch | blob | history |
diff --git a/src/screen.c b/src/screen.c
index 9850f397351ecd958d9380a0f1644b2a24e6edc2..7295c47098c9975c4cdb4c0b9474a4265908f4dc 100644 (file)
--- a/src/screen.c
+++ b/src/screen.c
static bool single;
static bool consume;
static unsigned crossfade;
- static unsigned dbupdate;
/* print a message if mpd status has changed */
- if (c->status != NULL) {
+ if ((c->events & MPD_IDLE_OPTIONS) && c->status != NULL) {
if (!initialized) {
repeat = mpd_status_get_repeat(c->status);
random_enabled = mpd_status_get_random(c->status);
single = mpd_status_get_single(c->status);
consume = mpd_status_get_consume(c->status);
crossfade = mpd_status_get_crossfade(c->status);
- dbupdate = mpd_status_get_update_id(c->status);
initialized = true;
}
screen_status_printf(_("Crossfade %d seconds"),
mpd_status_get_crossfade(c->status));
- if (dbupdate != 0 &&
- dbupdate != mpd_status_get_update_id(c->status)) {
- screen_status_printf(_("Database updated"));
- }
-
repeat = mpd_status_get_repeat(c->status);
random_enabled = mpd_status_get_random(c->status);
single = mpd_status_get_single(c->status);
consume = mpd_status_get_consume(c->status);
crossfade = mpd_status_get_crossfade(c->status);
- dbupdate = mpd_status_get_update_id(c->status);
}
+ if (c->events & MPD_IDLE_DATABASE)
+ screen_status_printf(_("Database updated"));
+
/* update title/header window */
if (welcome && options.welcome_screen_list &&
time(NULL)-screen.start_timestamp <= SCREEN_WELCOME_TIME)