From: Max Kellermann Date: Wed, 30 Sep 2009 19:17:19 +0000 (+0200) Subject: screen_outputs: implemented the SCREEN_UPDATE command X-Git-Tag: release-0.16~253 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=5c21e19c666db5d66f09482efb3dbd505ddc233b;p=ncmpc.git screen_outputs: implemented the SCREEN_UPDATE command This reloads the output list from MPD. --- diff --git a/src/screen_outputs.c b/src/screen_outputs.c index 7f19ce2..c40f470 100644 --- a/src/screen_outputs.c +++ b/src/screen_outputs.c @@ -204,9 +204,19 @@ outputs_cmd(struct mpdclient *c, command_t cmd) return true; } - if (cmd == CMD_PLAY) { + switch (cmd) { + case CMD_PLAY: toggle_output(c, lw->selected); return true; + + case CMD_SCREEN_UPDATE: + clear_outputs_list(); + fill_outputs_list(c); + outputs_repaint(); + return true; + + default: + break; } return false;