aboutsummaryrefslogtreecommitdiffstats
path: root/src/screen_search.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-09-25 21:35:06 +0200
committerMax Kellermann <max@duempel.org>2008-09-25 21:35:06 +0200
commit1198af221ec2d804d9ff840a9dcd5e770fb3d13a (patch)
treeb1be8456ca335ef6b0089e024ab26db6b8d70ba1 /src/screen_search.c
parent728309e4aeaac71555ce68ffcd3ff92952a270d3 (diff)
downloadmpd-1198af221ec2d804d9ff840a9dcd5e770fb3d13a.tar.gz
mpd-1198af221ec2d804d9ff840a9dcd5e770fb3d13a.tar.xz
mpd-1198af221ec2d804d9ff840a9dcd5e770fb3d13a.zip
screen_browser: added hotkey for adding song
CMD_ADD ('a') appends a song to the playlist, no matter if it is already there, i.e. unlike CMD_SELECT, it does not toggle the song.
Diffstat (limited to 'src/screen_search.c')
-rw-r--r--src/screen_search.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/screen_search.c b/src/screen_search.c
index b93aef01a..981c0a58b 100644
--- a/src/screen_search.c
+++ b/src/screen_search.c
@@ -445,6 +445,14 @@ search_cmd(screen_t *screen, mpdclient_t *c, command_t cmd)
/* call list_window_cmd to go to the next item */
break;
+ case CMD_ADD:
+ if (browser_handle_add(&browser, c) == 0)
+ /* continue and select next item... */
+ cmd = CMD_LIST_NEXT;
+
+ /* call list_window_cmd to go to the next item */
+ break;
+
case CMD_SELECT_ALL:
browser_handle_select_all(&browser, c);
search_repaint();