summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 9122920)
raw | patch | inline | side by side (parent: 9122920)
author | Max Kellermann <max@duempel.org> | |
Sun, 4 Oct 2009 15:51:46 +0000 (17:51 +0200) | ||
committer | Max Kellermann <max@duempel.org> | |
Sun, 4 Oct 2009 15:51:46 +0000 (17:51 +0200) |
src/screen.c | patch | blob | history |
diff --git a/src/screen.c b/src/screen.c
index 19441707f0329c6d958ef21af55075db9ef50ad3..c01c79232571d2de8c37ad2492ef5d810e6382cc 100644 (file)
--- a/src/screen.c
+++ b/src/screen.c
}
static void
-paint_progress_window(struct mpdclient *c)
+update_progress_window(struct mpdclient *c, bool repaint)
{
unsigned elapsed, duration;
? mpd_status_get_total_time(c->status)
: 0;
- if (progress_bar_set(&screen.progress_bar, elapsed, duration))
+ if (progress_bar_set(&screen.progress_bar, elapsed, duration) ||
+ repaint)
progress_bar_paint(&screen.progress_bar);
}
/* paint the bottom window */
- paint_progress_window(c);
+ update_progress_window(c, true);
status_bar_paint(&screen.status_bar, c->status, c->song);
/* paint the main window */
paint_top_window("", c);
/* update progress window */
- paint_progress_window(c);
+ update_progress_window(c, false);
/* update status window */
status_bar_paint(&screen.status_bar, c->status, c->song);