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.
diff --git a/src/window.c b/src/window.c
index 7c18c06..532d314 100644
--- a/src/window.c
+++ b/src/window.c
@@ -4370,7 +4370,7 @@
 	return;
     }
 #endif
-    if (text_locked())
+    if (text_and_win_locked())
     {
 	beep_flush();
 	text_locked_msg();