nano-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Nano-devel] [PATCH 1/2] menus: remove the ^Y and ^V shortcuts from the


From: Benno Schulenberg
Subject: [Nano-devel] [PATCH 1/2] menus: remove the ^Y and ^V shortcuts from the Search menus
Date: Tue, 12 Feb 2019 19:52:52 +0100

Jumping to the first or last line of the buffer doesn't have anything
to do with searching, so these functions shouldn't present be in the
search menus.  They make perfect sense in the Goto-Line menu, though.
---
 src/global.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/global.c b/src/global.c
index 4b717805..8812c821 100644
--- a/src/global.c
+++ b/src/global.c
@@ -896,9 +896,9 @@ void shortcut_init(void)
        add_to_funcs(do_page_down, MMAIN|MHELP,
                N_("Next Page"), WITHORSANS(nextpage_gist), TOGETHER, VIEW);
 
-       add_to_funcs(to_first_line, 
MMAIN|MHELP|MWHEREIS|MREPLACE|MREPLACEWITH|MGOTOLINE,
+       add_to_funcs(to_first_line, MMAIN|MHELP|MGOTOLINE,
                N_("First Line"), WITHORSANS(firstline_gist), TOGETHER, VIEW);
-       add_to_funcs(to_last_line, 
MMAIN|MHELP|MWHEREIS|MREPLACE|MREPLACEWITH|MGOTOLINE,
+       add_to_funcs(to_last_line, MMAIN|MHELP|MGOTOLINE,
                N_("Last Line"), WITHORSANS(lastline_gist), BLANKAFTER, VIEW);
 
 #ifdef ENABLE_MULTIBUFFER
@@ -1273,8 +1273,6 @@ void shortcut_init(void)
        add_to_sclist(MWHEREIS|MREPLACE, "M-R", 0, regexp_void, 0);
        add_to_sclist(MWHEREIS|MREPLACE, "M-B", 0, backwards_void, 0);
        add_to_sclist(MWHEREIS|MREPLACE, "^R", 0, flip_replace, 0);
-       add_to_sclist(MWHEREIS|MREPLACE|MREPLACEWITH|MGOTOLINE|MFINDINHELP, 
"^Y", 0, to_first_line, 0);
-       add_to_sclist(MWHEREIS|MREPLACE|MREPLACEWITH|MGOTOLINE|MFINDINHELP, 
"^V", 0, to_last_line, 0);
 #ifdef ENABLE_JUSTIFY
        add_to_sclist(MWHEREIS|MREPLACE|MREPLACEWITH, "^W", 0, 
do_para_begin_void, 0);
        add_to_sclist(MWHEREIS|MREPLACE|MREPLACEWITH, "^O", 0, 
do_para_end_void, 0);
@@ -1294,6 +1292,8 @@ void shortcut_init(void)
                
add_to_sclist(MWHEREIS|MREPLACE|MREPLACEWITH|MWHEREISFILE|MFINDINHELP|MEXTCMD, 
"Down", KEY_DOWN, get_history_newer_void, 0);
        }
 #endif
+       add_to_sclist(MGOTOLINE, "^Y", 0, to_first_line, 0);
+       add_to_sclist(MGOTOLINE, "^V", 0, to_last_line, 0);
 #ifdef ENABLE_BROWSER
        add_to_sclist(MWHEREISFILE, "^Y", 0, to_first_file, 0);
        add_to_sclist(MWHEREISFILE, "^V", 0, to_last_file, 0);
-- 
2.20.1




reply via email to

[Prev in Thread] Current Thread [Next in Thread]