From: Max Kellermann Date: Wed, 30 Sep 2009 15:40:25 +0000 (+0200) Subject: mpdclient: renamed "updatingdb" to "update_id" X-Git-Tag: release-0.16~276 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=6e166433ef87e8c1e7778d1c497729d92206b04c;p=ncmpc.git mpdclient: renamed "updatingdb" to "update_id" Adopt libmpdclient's name. --- diff --git a/src/mpdclient.c b/src/mpdclient.c index b8d9c6f..e331544 100644 --- a/src/mpdclient.c +++ b/src/mpdclient.c @@ -230,11 +230,11 @@ mpdclient_update(struct mpdclient *c) if (c->status == NULL) return mpdclient_handle_error(c) == 0; - if (c->updatingdb && - c->updatingdb != mpd_status_get_update_id(c->status)) + if (c->update_id > 0 && + c->update_id != mpd_status_get_update_id(c->status)) mpdclient_browse_callback(c, BROWSE_DB_UPDATED, NULL); - c->updatingdb = mpd_status_get_update_id(c->status); + c->update_id = mpd_status_get_update_id(c->status); c->volume = mpd_status_get_volume(c->status); /* check if the playlist needs an update */ diff --git a/src/mpdclient.h b/src/mpdclient.h index 2679a62..39575b8 100644 --- a/src/mpdclient.h +++ b/src/mpdclient.h @@ -21,7 +21,7 @@ struct mpdclient { const struct mpd_song *song; int volume; - unsigned updatingdb; + unsigned update_id; }; /** functions ***************************************************************/ diff --git a/src/screen_client.c b/src/screen_client.c index 3916304..f94ada1 100644 --- a/src/screen_client.c +++ b/src/screen_client.c @@ -75,9 +75,9 @@ screen_database_update(struct mpdclient *c, const char *path) return; } - /* set updatingDb to make sure the browse callback gets called + /* set update_id to make sure the browse callback gets called even if the update has finished before status is updated */ - c->updatingdb = id; + c->update_id = id; if (path != NULL && *path != 0) { char *path_locale = utf8_to_locale(path);