aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/edit.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/edit.c')
-rw-r--r--src/nvim/edit.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/nvim/edit.c b/src/nvim/edit.c
index 3eb4ab9517..e223841326 100644
--- a/src/nvim/edit.c
+++ b/src/nvim/edit.c
@@ -387,7 +387,7 @@ static void insert_enter(InsertState *s)
State = INSERT;
}
- trigger_modechanged();
+ may_trigger_modechanged();
stop_insert_mode = false;
// need to position cursor again when on a TAB
@@ -2097,7 +2097,7 @@ static void ins_ctrl_x(void)
ctrl_x_mode = CTRL_X_CMDLINE_CTRL_X;
}
- trigger_modechanged();
+ may_trigger_modechanged();
}
// Whether other than default completion has been selected.
@@ -2710,7 +2710,7 @@ void set_completion(colnr_T startcol, list_T *list)
show_pum(save_w_wrow, save_w_leftcol);
}
- trigger_modechanged();
+ may_trigger_modechanged();
ui_flush();
}
@@ -3890,7 +3890,7 @@ static bool ins_compl_prep(int c)
ins_apply_autocmds(EVENT_COMPLETEDONE);
}
- trigger_modechanged();
+ may_trigger_modechanged();
/* reset continue_* if we left expansion-mode, if we stay they'll be
* (re)set properly in ins_complete() */
@@ -4641,7 +4641,7 @@ static int ins_compl_get_exp(pos_T *ini)
compl_curr_match = compl_old_match;
}
}
- trigger_modechanged();
+ may_trigger_modechanged();
return i;
}
@@ -8051,7 +8051,7 @@ static bool ins_esc(long *count, int cmdchar, bool nomove)
State = NORMAL;
- trigger_modechanged();
+ may_trigger_modechanged();
// need to position cursor again when on a TAB
if (gchar_cursor() == TAB) {
curwin->w_valid &= ~(VALID_WROW|VALID_WCOL|VALID_VIRTCOL);
@@ -8155,7 +8155,7 @@ static void ins_insert(int replaceState)
} else {
State = replaceState | (State & LANGMAP);
}
- trigger_modechanged();
+ may_trigger_modechanged();
AppendCharToRedobuff(K_INS);
showmode();
ui_cursor_shape(); // may show different cursor shape