From 934a2192dcc5f6f89565a9edc55194cf3eda176b Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <bensberg@telfort.nl>
Date: Thu, 13 Jul 2017 11:36:17 +0200
Subject: [PATCH] screen: retain the same help-line tags when the window is
 resized

This fixes https://savannah.gnu.org/bugs/?51457.
---
 src/global.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/global.c b/src/global.c
index d4a5c2b5..8a95bcc1 100644
--- a/src/global.c
+++ b/src/global.c
@@ -667,7 +667,7 @@ void shortcut_init(void)
     add_to_funcs(do_cancel, ((MMOST & ~MMAIN & ~MBROWSER) | MYESNO),
 	N_("Cancel"), IFSCHELP(nano_cancel_msg), BLANKAFTER, VIEW);
 
-    add_to_funcs(do_exit, MMAIN|MHELP,
+    add_to_funcs(do_exit, MMAIN,
 	exit_tag, IFSCHELP(nano_exit_msg), TOGETHER, VIEW);
     /* Remember the entry for Exit, to be able to replace it with Close. */
     exitfunc = tailfunc;
@@ -720,6 +720,7 @@ void shortcut_init(void)
 #ifdef ENABLE_HELP
     /* The description ("x") and blank_after (0) are irrelevant,
      * because the help viewer does not have a help text. */
+    add_to_funcs(do_exit, MHELP, close_tag, "x", 0, VIEW);
     add_to_funcs(total_refresh, MHELP, refresh_tag, "x", 0, VIEW);
 
     add_to_funcs(do_search, MHELP, whereis_tag, "x", 0, VIEW);
-- 
GitLab