nano

nano with my custom patches
git clone git://bsandro.tech/nano
Log | Files | Refs | README | LICENSE

commit bd4eed9cb10c1680f94b8642cd982eb59af5ef9d
parent 2b0bcc7ceed899dc228931c9d4d8619e4e0fb599
Author: Benno Schulenberg <bensberg@telfort.nl>
Date:   Wed, 17 Nov 2021 10:42:21 +0100

tweaks: reshuffle a fragment of code to a better place

Diffstat:
Msrc/nano.c | 15+++++++--------
1 file changed, 7 insertions(+), 8 deletions(-)

diff --git a/src/nano.c b/src/nano.c @@ -1076,6 +1076,13 @@ void toggle_this(int flag) window_init(); draw_all_subwindows(); break; + case CONSTANT_SHOW: + if (ISSET(ZERO) || LINES == 1) { + statusline(AHEM, _("Not possible in barless mode")); + TOGGLE(flag); + } else if (!ISSET(MINIBAR)) + wipe_statusbar(); + return; #ifdef ENABLE_MOUSE case USE_MOUSE: mouse_init(); @@ -1119,13 +1126,6 @@ void toggle_this(int flag) if ((ISSET(MINIBAR) || ISSET(ZERO)) && (flag == NO_HELP || flag == LINE_NUMBERS)) return; - if (flag == CONSTANT_SHOW) { - if (ISSET(ZERO) || LINES == 1) { - statusline(AHEM, _("Not possible in barless mode")); - TOGGLE(flag); - } else if (!ISSET(MINIBAR)) - wipe_statusbar(); - } else { bool enabled = ISSET(flag); if (flag == NO_HELP || flag == NO_SYNTAX) @@ -1133,7 +1133,6 @@ void toggle_this(int flag) statusline(REMARK, "%s %s", _(flagtostr(flag)), enabled ? _("enabled") : _("disabled")); - } } #endif /* !NANO_TINY */