[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Nano-devel] [PATCH 2/2] bindings: add easier keystrokes for the lin
From: |
Brand Huntsman |
Subject: |
Re: [Nano-devel] [PATCH 2/2] bindings: add easier keystrokes for the linenumber and softwrap toggles |
Date: |
Fri, 5 Apr 2019 18:36:31 -0600 |
On Fri, 5 Apr 2019 12:11:36 +0200
Benno Schulenberg <address@hidden> wrote:
> For most people, M-N and M-S are simpler to type than M-# and M-$,
> and more mnemonic.
> ---
> diff --git a/src/global.c b/src/global.c
> index d4de51df..7265b86a 100644
> --- a/src/global.c
> +++ b/src/global.c
> @@ -397,7 +397,6 @@ void add_to_sclist(int menus, const char
> *scstring, const int keycode, sclist = s;
> else
> tailsc->next = s;
> - tailsc = s;
> s->next = NULL;
>
> /* Fill in the data. */
> @@ -405,11 +404,13 @@ void add_to_sclist(int menus, const char
> *scstring, const int keycode, s->func = func;
> #ifndef NANO_TINY
> s->toggle = toggle;
> - if (toggle)
> + if (toggle && tailsc->toggle != toggle)
> s->ordinal = ++counter;
> #endif
> assign_keyinfo(s, scstring, keycode);
>
> + tailsc = s;
> +
Is this a fix for something else that accidentally became part of this patch?