diff src/globals.h @ 20229:06a1dd50463e v8.2.0670

patch 8.2.0670: cannot change window when evaluating 'completefunc' Commit: https://github.com/vim/vim/commit/6adb9ea0a6ca01414f4b591f379b0f829a8273c0 Author: Bram Moolenaar <Bram@vim.org> Date: Thu Apr 30 22:31:18 2020 +0200 patch 8.2.0670: cannot change window when evaluating 'completefunc' Problem: Cannot change window when evaluating 'completefunc'. Solution: Make a difference between not changing text or buffers and also not changing window.
author Bram Moolenaar <Bram@vim.org>
date Thu, 30 Apr 2020 22:45:04 +0200
parents 8d9229c4781a
children 05b4efb062a7
line wrap: on
line diff
--- a/src/globals.h
+++ b/src/globals.h
@@ -798,9 +798,15 @@ EXTERN int	secure INIT(= FALSE);
 				// allowed, e.g. when sourcing .exrc or .vimrc
 				// in current directory
 
-EXTERN int	textlock INIT(= 0);
+EXTERN int	textwinlock INIT(= 0);
 				// non-zero when changing text and jumping to
-				// another window or buffer is not allowed
+				// another window or editing another buffer is
+				// not allowed
+
+EXTERN int	textlock INIT(= 0);
+				// non-zero when changing text is not allowed,
+				// jumping to another window is allowed,
+				// editing another buffer is not allowed.
 
 EXTERN int	curbuf_lock INIT(= 0);
 				// non-zero when the current buffer can't be
@@ -1681,7 +1687,8 @@ EXTERN char e_readerrf[]	INIT(= N_("E47:
 EXTERN char e_sandbox[]		INIT(= N_("E48: Not allowed in sandbox"));
 #endif
 EXTERN char e_secure[]		INIT(= N_("E523: Not allowed here"));
-EXTERN char e_textlock[]	INIT(= N_("E565: Not allowed to change text here"));
+EXTERN char e_textlock[]	INIT(= N_("E578: Not allowed to change text here"));
+EXTERN char e_textwinlock[]	INIT(= N_("E565: Not allowed to change text or change window"));
 #if defined(AMIGA) || defined(MACOS_X) || defined(MSWIN)  \
 	|| defined(UNIX) || defined(VMS)
 EXTERN char e_screenmode[]	INIT(= N_("E359: Screen mode setting not supported"));