changeset 30144:17f72013adea v9.0.0408

patch 9.0.0408: GUI test sometimes fails on MS-Windows Commit: https://github.com/vim/vim/commit/fef38d86a1fc3790d2ca7fc4b3e45071c1d8c79c Author: K.Takata <kentkt@csc.jp> Date: Wed Sep 7 19:03:42 2022 +0100 patch 9.0.0408: GUI test sometimes fails on MS-Windows Problem: GUI test sometimes fails on MS-Windows. Solution: Make sure Vim is the foreground window. (Ken Takata, closes https://github.com/vim/vim/issues/11077)
author Bram Moolenaar <Bram@vim.org>
date Wed, 07 Sep 2022 20:15:04 +0200
parents fc3456fdd67e
children 7571004d6f37
files src/gui_w32.c src/version.c
diffstat 2 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/gui_w32.c
+++ b/src/gui_w32.c
@@ -8649,6 +8649,7 @@ test_gui_w32_sendevent(dict_T *args)
 	inputs[0].ki.wVk = vkCode;
 	if (STRICMP(event, "keyup") == 0)
 	    inputs[0].ki.dwFlags = KEYEVENTF_KEYUP;
+	(void)SetForegroundWindow(s_hwnd);
 	SendInput(ARRAYSIZE(inputs), inputs, sizeof(INPUT));
     }
     else
--- a/src/version.c
+++ b/src/version.c
@@ -704,6 +704,8 @@ static char *(features[]) =
 static int included_patches[] =
 {   /* Add new patch number below this line */
 /**/
+    408,
+/**/
     407,
 /**/
     406,