linter: allow using <Ctrl+Up> and <Ctrl+Down> to jump to other message

These are more "natural" keystrokes for jumping than <PgUp> and <PgDn>.
master
Benno Schulenberg 2018-09-29 09:40:53 +02:00
parent 0b63de335e
commit b4b9e9b012
2 changed files with 6 additions and 6 deletions

View File

@ -1198,15 +1198,15 @@ void shortcut_init(void)
if (using_utf8()) { if (using_utf8()) {
add_to_sclist(MMAIN|MHELP|MBROWSER, "\xE2\x96\xb2", KEY_UP, do_up, 0); add_to_sclist(MMAIN|MHELP|MBROWSER, "\xE2\x96\xb2", KEY_UP, do_up, 0);
add_to_sclist(MMAIN|MHELP|MBROWSER, "\xE2\x96\xbc", KEY_DOWN, do_down, 0); add_to_sclist(MMAIN|MHELP|MBROWSER, "\xE2\x96\xbc", KEY_DOWN, do_down, 0);
add_to_sclist(MMAIN|MBROWSER, "^\xE2\x96\xb2", CONTROL_UP, do_prev_block, 0); add_to_sclist(MMAIN|MBROWSER|MLINTER, "^\xE2\x96\xb2", CONTROL_UP, do_prev_block, 0);
add_to_sclist(MMAIN|MBROWSER, "^\xE2\x96\xbc", CONTROL_DOWN, do_next_block, 0); add_to_sclist(MMAIN|MBROWSER|MLINTER, "^\xE2\x96\xbc", CONTROL_DOWN, do_next_block, 0);
} else } else
#endif #endif
{ {
add_to_sclist(MMAIN|MHELP|MBROWSER, "Up", KEY_UP, do_up, 0); add_to_sclist(MMAIN|MHELP|MBROWSER, "Up", KEY_UP, do_up, 0);
add_to_sclist(MMAIN|MHELP|MBROWSER, "Down", KEY_DOWN, do_down, 0); add_to_sclist(MMAIN|MHELP|MBROWSER, "Down", KEY_DOWN, do_down, 0);
add_to_sclist(MMAIN|MBROWSER, "^Up", CONTROL_UP, do_prev_block, 0); add_to_sclist(MMAIN|MBROWSER|MLINTER, "^Up", CONTROL_UP, do_prev_block, 0);
add_to_sclist(MMAIN|MBROWSER, "^Down", CONTROL_DOWN, do_next_block, 0); add_to_sclist(MMAIN|MBROWSER|MLINTER, "^Down", CONTROL_DOWN, do_next_block, 0);
} }
add_to_sclist(MMAIN, "M-7", 0, do_prev_block, 0); add_to_sclist(MMAIN, "M-7", 0, do_prev_block, 0);
add_to_sclist(MMAIN, "M-8", 0, do_next_block, 0); add_to_sclist(MMAIN, "M-8", 0, do_next_block, 0);

View File

@ -3287,12 +3287,12 @@ void do_linter(void)
else if (func == do_help_void) { else if (func == do_help_void) {
tmplint = NULL; tmplint = NULL;
do_help_void(); do_help_void();
} else if (func == do_page_down) { } else if (func == do_page_down || func == do_next_block) {
if (curlint->next != NULL) if (curlint->next != NULL)
curlint = curlint->next; curlint = curlint->next;
else else
statusbar(_("At last message")); statusbar(_("At last message"));
} else if (func == do_page_up) { } else if (func == do_page_up || func == do_prev_block) {
if (curlint->prev != NULL) if (curlint->prev != NULL)
curlint = curlint->prev; curlint = curlint->prev;
else else