summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: c5343d5)
raw | patch | inline | side by side (parent: c5343d5)
author | Jeffrey Middleton <jefromi@gmail.com> | |
Thu, 23 Apr 2009 22:04:12 +0000 (17:04 -0500) | ||
committer | Jeffrey Middleton <jefromi@gmail.com> | |
Fri, 24 Apr 2009 05:09:50 +0000 (00:09 -0500) |
This command immediately selects (but doesn't center) the currently
playing song. It is mapped by default to 'l' - there aren't many single
characters left, and this one is at least similar to ctrl-l, which
centers the currently playing song.
playing song. It is mapped by default to 'l' - there aren't many single
characters left, and this one is at least similar to ctrl-l, which
centers the currently playing song.
src/command.c | patch | blob | history | |
src/command.h | patch | blob | history | |
src/screen_help.c | patch | blob | history | |
src/screen_play.c | patch | blob | history |
diff --git a/src/command.c b/src/command.c
index 3fb491ca42f3a88d6815c79af81f7831ea0a72d8..3fe825c39fc6be6b0d79f2b4b6c55863949573b3 100644 (file)
--- a/src/command.c
+++ b/src/command.c
N_("Scroll up half a screen") },
{ { 'B', 0, 0 }, 0, CMD_LIST_SCROLL_UP_HALF, "scroll-up-half",
N_("Scroll down half a screen") },
+ { { 'l', 0, 0 }, 0, CMD_SELECT_PLAYING, "select-playing",
+ N_("Select currently playing song") },
/* basic screens */
diff --git a/src/command.h b/src/command.h
index 7d6fb1ae0f48dbb095d2179bff7daa717e917200..b3222c5bfc7c86c0092e1d65da0db263a68a09fc 100644 (file)
--- a/src/command.h
+++ b/src/command.h
CMD_SAVE_PLAYLIST,
CMD_TOGGLE_FIND_WRAP,
CMD_TOGGLE_AUTOCENTER,
+ CMD_SELECT_PLAYING,
CMD_SEARCH_MODE,
CMD_LIST_PREVIOUS,
CMD_LIST_NEXT,
diff --git a/src/screen_help.c b/src/screen_help.c
index f687d31046ade9ee5a42ec2d60f0b7d796de33f1..467b7b789add6b7465109345a10015d9f376f2e7 100644 (file)
--- a/src/screen_help.c
+++ b/src/screen_help.c
{ 0, CMD_ADD, NULL },
{ 0, CMD_SAVE_PLAYLIST, NULL },
{ 0, CMD_SCREEN_UPDATE, N_("Center") },
+ { 0, CMD_SELECT_PLAYING, NULL },
{ 0, CMD_TOGGLE_AUTOCENTER, NULL },
{ 0, CMD_NONE, NULL },
diff --git a/src/screen_play.c b/src/screen_play.c
index 28d39134625f8a32dbcec75a2926f1223a23e555..4b03c5d3f55637ac88858d4ff63bef8ff9f6be1a 100644 (file)
--- a/src/screen_play.c
+++ b/src/screen_play.c
center_playing_item(c, prev_cmd == CMD_SCREEN_UPDATE);
playlist_repaint();
return false;
+ case CMD_SELECT_PLAYING:
+ list_window_set_selected(lw, playlist_get_index(c, c->song));
+ return true;
case CMD_SHUFFLE:
{
if(!lw->range_selection)