Code

increment version number to 0.28
[ncmpc.git] / src / command.c
index 857bf48555477f4dc6c173ed99317c1f85ebce64..f903165f57a113034df735373395a4a5a3d43a7f 100644 (file)
@@ -1,5 +1,5 @@
 /* ncmpc (Ncurses MPD Client)
- * (c) 2004-2010 The Music Player Daemon Project
+ * (c) 2004-2017 The Music Player Daemon Project
  * Project homepage: http://musicpd.org
  *
  * This program is free software; you can redistribute it and/or modify
  */
 
 #include "command.h"
-#include "config.h"
-#include "ncmpc.h"
 #include "i18n.h"
-#include "mpdclient.h"
-#include "screen.h"
+#include "ncmpc_curses.h"
 
+#include <assert.h>
 #include <ctype.h>
 #include <stdlib.h>
 #include <string.h>
@@ -89,9 +87,9 @@ static command_definition_t cmds[] = {
        { { 'v',  0, 0 }, 0, CMD_LIST_RANGE_SELECT, "range-select",
          N_("Range selection") },
        { { C('N'),  0, 0 }, 0, CMD_LIST_SCROLL_DOWN_LINE, "scroll-down-line",
-         N_("Scroll up one line") },
-       { { C('B'),  0, 0 }, 0, CMD_LIST_SCROLL_UP_LINE, "scroll-up-line",
          N_("Scroll down one line") },
+       { { C('B'),  0, 0 }, 0, CMD_LIST_SCROLL_UP_LINE, "scroll-up-line",
+         N_("Scroll up one line") },
        { { 'N',  0, 0 }, 0, CMD_LIST_SCROLL_DOWN_HALF, "scroll-down-half",
          N_("Scroll up half a screen") },
        { { 'B',  0, 0 }, 0, CMD_LIST_SCROLL_UP_HALF, "scroll-up-half",
@@ -438,21 +436,6 @@ get_key_command(int key)
        return find_key_command(key, cmds);
 }
 
-command_t
-get_keyboard_command(void)
-{
-       int key = wgetch(stdscr);
-       if (key == ERR || key == '\0')
-               return CMD_NONE;
-
-#ifdef HAVE_GETMOUSE
-       if (key == KEY_MOUSE)
-               return CMD_MOUSE_EVENT;
-#endif
-
-       return get_key_command(key);
-}
-
 bool
 assign_keys(command_t command, int keys[MAX_COMMAND_KEYS])
 {