diff options
author | Björn Linse <bjorn.linse@gmail.com> | 2021-07-25 19:35:23 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-25 19:35:23 +0200 |
commit | 192adfe99f33778a85e11fbfdceb37f347a3d235 (patch) | |
tree | 529e922ff73a8907df3538ac25f0efb685348f6b /src/nvim/normal.c | |
parent | f15c74550252a553eaecb3f55af60d7f7ae27540 (diff) | |
parent | 8ce092941862a18a6591f62f398ed9e8bd9202be (diff) | |
download | rneovim-192adfe99f33778a85e11fbfdceb37f347a3d235.tar.gz rneovim-192adfe99f33778a85e11fbfdceb37f347a3d235.tar.bz2 rneovim-192adfe99f33778a85e11fbfdceb37f347a3d235.zip |
Merge pull request #14311 from matveyt/nomode_ce
refactor(state): Remove EXMODE_NORMAL
Diffstat (limited to 'src/nvim/normal.c')
-rw-r--r-- | src/nvim/normal.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/nvim/normal.c b/src/nvim/normal.c index 74a3d74860..cba7b7a10b 100644 --- a/src/nvim/normal.c +++ b/src/nvim/normal.c @@ -1188,7 +1188,7 @@ static void normal_check_interrupt(NormalState *s) && s->previous_got_int) { // Typed two CTRL-C in a row: go back to ex mode as if "Q" was // used and keep "got_int" set, so that it aborts ":g". - exmode_active = EXMODE_NORMAL; + exmode_active = true; State = NORMAL; } else if (!global_busy || !exmode_active) { if (!quit_more) { @@ -1398,7 +1398,7 @@ static int normal_check(VimState *state) if (s->noexmode) { return 0; } - do_exmode(exmode_active == EXMODE_VIM); + do_exmode(); return -1; } @@ -4652,7 +4652,7 @@ static void nv_exmode(cmdarg_T *cap) if (VIsual_active) { vim_beep(BO_EX); } else if (!checkclearop(cap->oap)) { - do_exmode(false); + do_exmode(); } } @@ -7101,8 +7101,9 @@ static void nv_g_cmd(cmdarg_T *cap) break; } - if (!checkclearopq(oap)) - do_exmode(true); + if (!checkclearopq(oap)) { + do_exmode(); + } break; case ',': |