From: Jonathan Neuschäfer Date: Sat, 10 Sep 2011 22:02:27 +0000 (+0200) Subject: Revert "screen_queue: use list_window_move_cursor" X-Git-Tag: release-0.20~87^2~2 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=00a64b4fd61c626da6970beeb0fe440ac491ebde;p=ncmpc.git Revert "screen_queue: use list_window_move_cursor" I hadn't quite understood what list_window_move_cursor does, and didn't test the change. This reverts commit aba25b543d7a34ce46964a7f22e495cdc3b57852. --- diff --git a/src/screen_queue.c b/src/screen_queue.c index 863c3dd..37a6050 100644 --- a/src/screen_queue.c +++ b/src/screen_queue.c @@ -762,7 +762,8 @@ screen_queue_cmd(struct mpdclient *c, command_t cmd) if (!mpdclient_cmd_move(c, range.end - 1, range.start - 1)) return true; - list_window_move_cursor(lw, lw->selected - 1); + lw->selected--; + lw->range_base--; screen_queue_save_selection(); return true; @@ -775,7 +776,8 @@ screen_queue_cmd(struct mpdclient *c, command_t cmd) if (!mpdclient_cmd_move(c, range.start, range.end)) return true; - list_window_move_cursor(lw, lw->selected + 1); + lw->selected++; + lw->range_base++; screen_queue_save_selection(); return true;