feat(buffer_updates): allow ignoring when previewing

Also adds a test that we actually subscribe to buffer events when in
CMDPREVIEW.
This commit is contained in:
Thomas Vigouroux
2020-12-15 22:18:35 +01:00
parent d0112693a3
commit 25e20da550
5 changed files with 33 additions and 7 deletions

View File

@@ -491,9 +491,10 @@ typedef struct {
LuaRef on_changedtick;
LuaRef on_detach;
bool utf_sizes;
bool preview;
} BufUpdateCallbacks;
#define BUF_UPDATE_CALLBACKS_INIT { LUA_NOREF, LUA_NOREF, LUA_NOREF, \
LUA_NOREF, false }
LUA_NOREF, false, false }
EXTERN int curbuf_splice_pending INIT(= 0);