From: Pierre Habouzit Date: Sat, 10 Nov 2007 16:28:06 +0000 (+0100) Subject: WHAT_KEY has better equivalents in other tools. X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=commitdiff_plain;h=83170cc0ea7b56b7ffe3b311b6b7d831393e7524 WHAT_KEY has better equivalents in other tools. Signed-off-by: Pierre Habouzit --- diff --git a/OPS b/OPS index 1f0883e..17c04a0 100644 --- a/OPS +++ b/OPS @@ -174,7 +174,6 @@ OP_UNDELETE_SUBTHREAD "undelete all messages in subthread" OP_VERSION "show the Mutt version number and date" OP_VIEW_ATTACH "view attachment using mailcap entry if necessary" OP_VIEW_ATTACHMENTS "show MIME attachments" -OP_WHAT_KEY "display the keycode for a key press" OP_MAIN_SHOW_LIMIT "show currently active limit pattern" OP_MAIN_COLLAPSE_THREAD "collapse/uncollapse current thread" OP_MAIN_COLLAPSE_ALL "collapse/uncollapse all threads" diff --git a/functions.def b/functions.def index 7b5f3f5..f95bc49 100644 --- a/functions.def +++ b/functions.def @@ -81,7 +81,6 @@ LIST(OpGeneric) ITEM("current-top", OP_CURRENT_TOP, NULL) ITEM("current-middle", OP_CURRENT_MIDDLE, NULL) ITEM("current-bottom", OP_CURRENT_BOTTOM, NULL) - ITEM("what-key", OP_WHAT_KEY, NULL) ENDLIST LIST(OpMain) diff --git a/lib-ui/curs_lib.c b/lib-ui/curs_lib.c index a2b88c8..5ac5dcb 100644 --- a/lib-ui/curs_lib.c +++ b/lib-ui/curs_lib.c @@ -324,27 +324,6 @@ void curses_initialize(void) ESCDELAY = 50; } -/* - * prompts the user to enter a keystroke, and displays the octal value back - * to the user. - */ -void mutt_what_key (void) -{ - int ch; - - mvwprintw(stdscr, LINES - 1, 0, _("Enter keys (^G to abort): ")); - do { - ch = getch(); - if (ch != ERR && ch != ctrl ('G')) { - mutt_message (_("Char = %s, Octal = %o, Decimal = %d"), - km_keyname (ch), ch, ch); - } - } - while (ch != ERR && ch != ctrl ('G')); - - mutt_flushinp (); -} - int mutt_any_key_to_continue (const char *s) { struct termios t; diff --git a/lib-ui/curs_main.c b/lib-ui/curs_main.c index 8d0611f..26bb962 100644 --- a/lib-ui/curs_main.c +++ b/lib-ui/curs_main.c @@ -1951,10 +1951,6 @@ int mutt_index_menu (void) case OP_END_COND: break; - case OP_WHAT_KEY: - mutt_what_key (); - break; - case OP_SIDEBAR_SCROLL_UP: case OP_SIDEBAR_SCROLL_DOWN: case OP_SIDEBAR_NEXT: diff --git a/lib-ui/curses.h b/lib-ui/curses.h index b2f4d0b..c059336 100644 --- a/lib-ui/curses.h +++ b/lib-ui/curses.h @@ -117,7 +117,6 @@ void mutt_show_error (void); ssize_t mutt_pretty_size(char *s, ssize_t len, ssize_t n); int mutt_any_key_to_continue (const char *); -void mutt_what_key (void); int mutt_complete (char *, ssize_t); #define mutt_enter_fname(A,B,C,D,E) _mutt_enter_fname(A,B,C,D,E,0,NULL,NULL) int _mutt_enter_fname (const char *, char *, ssize_t, int *, int, int, diff --git a/lib-ui/menu.c b/lib-ui/menu.c index 0aac994..d0b8c54 100644 --- a/lib-ui/menu.c +++ b/lib-ui/menu.c @@ -837,10 +837,6 @@ int mutt_menuLoop (MUTTMENU * menu) MAYBE_REDRAW (menu->redraw); break; - case OP_WHAT_KEY: - mutt_what_key (); - break; - case OP_REDRAW: clearok (main_w, TRUE); menu->redraw = REDRAW_FULL;