Rebase against 7db5431699037d03f26c065a58c400991210c7f7.

This commit is contained in:
Alistair Leslie-Hughes 2023-03-15 15:06:52 +11:00
parent e3a3dcd0ce
commit 2ac5cdbf37
3 changed files with 29 additions and 29 deletions

View File

@ -1,4 +1,4 @@
From be7001f58850fb46ee07e9b4fba310c64157ee0f Mon Sep 17 00:00:00 2001
From 2a1229098b39f923ff6e9a13bde05e161c797b0a Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Tue, 9 Jul 2019 14:13:28 +1000
Subject: [PATCH] user32: Do not enumerate the registry in
@ -13,10 +13,10 @@ not the complete list from the registry.
3 files changed, 36 insertions(+), 33 deletions(-)
diff --git a/dlls/user32/input.c b/dlls/user32/input.c
index 2f4dc06f6ce..7345b78eaeb 100644
index 8f3cd8acae7..072f1fab23a 100644
--- a/dlls/user32/input.c
+++ b/dlls/user32/input.c
@@ -494,7 +494,6 @@ BOOL WINAPI UnloadKeyboardLayout( HKL layout )
@@ -499,7 +499,6 @@ BOOL WINAPI UnloadKeyboardLayout( HKL layout )
return FALSE;
}
@ -25,10 +25,10 @@ index 2f4dc06f6ce..7345b78eaeb 100644
{
SendMessageTimeoutW(handle, WM_DEVICECHANGE, flags, (LPARAM)header, SMTO_ABORTIFHUNG, 2000, NULL);
diff --git a/dlls/user32/tests/input.c b/dlls/user32/tests/input.c
index ee39b11fc12..35670ca7538 100644
index 8f3d5750c2f..3bdfd042e85 100644
--- a/dlls/user32/tests/input.c
+++ b/dlls/user32/tests/input.c
@@ -4899,6 +4899,40 @@ static void test_EnableMouseInPointer( char **argv, BOOL enable )
@@ -5091,6 +5091,40 @@ static void test_EnableMouseInPointer( char **argv, BOOL enable )
CloseHandle( info.hProcess );
}
@ -69,7 +69,7 @@ index ee39b11fc12..35670ca7538 100644
START_TEST(input)
{
char **argv;
@@ -4949,6 +4983,7 @@ START_TEST(input)
@@ -5142,6 +5176,7 @@ START_TEST(input)
test_GetRawInputBuffer();
test_RegisterRawInputDevices();
test_rawinput(argv[0]);
@ -78,10 +78,10 @@ index ee39b11fc12..35670ca7538 100644
if(pGetMouseMovePointsEx)
diff --git a/dlls/win32u/input.c b/dlls/win32u/input.c
index 36f2a45f4ef..bf4e871d107 100644
index 11bb129134c..9864d80ceff 100644
--- a/dlls/win32u/input.c
+++ b/dlls/win32u/input.c
@@ -1187,11 +1187,7 @@ HKL WINAPI NtUserActivateKeyboardLayout( HKL layout, UINT flags )
@@ -1250,11 +1250,7 @@ HKL WINAPI NtUserActivateKeyboardLayout( HKL layout, UINT flags )
*/
UINT WINAPI NtUserGetKeyboardLayoutList( INT size, HKL *layouts )
{
@ -94,7 +94,7 @@ index 36f2a45f4ef..bf4e871d107 100644
HKL layout;
TRACE_(keyboard)( "size %d, layouts %p.\n", size, layouts );
@@ -1205,33 +1201,6 @@ UINT WINAPI NtUserGetKeyboardLayoutList( INT size, HKL *layouts )
@@ -1268,33 +1264,6 @@ UINT WINAPI NtUserGetKeyboardLayoutList( INT size, HKL *layouts )
if (size && layouts)
{
layouts[count - 1] = layout;
@ -111,10 +111,10 @@ index 36f2a45f4ef..bf4e871d107 100644
- tmp = wcstoul( key_info->Name, NULL, 16 );
- if (query_reg_ascii_value( subkey, "Layout Id", value_info, sizeof(buffer) ) &&
- value_info->Type == REG_SZ)
- tmp = MAKELONG( LOWORD( tmp ),
- 0xf000 | (wcstoul( (const WCHAR *)value_info->Data, NULL, 16 ) & 0xfff) );
- tmp = 0xf000 | (wcstoul( (const WCHAR *)value_info->Data, NULL, 16 ) & 0xfff);
- NtClose( subkey );
-
- tmp = MAKELONG( LOWORD( layout ), LOWORD( tmp ) );
- if (layout == UlongToHandle( tmp )) continue;
-
- count++;

View File

@ -1,7 +1,7 @@
From 95f66fcd054ff2bae4e35e25a632b88a63aa4bb1 Mon Sep 17 00:00:00 2001
From 7701298b62301e551fd7514f79f19eabacc66cac Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
Date: Fri, 6 Jan 2023 08:09:11 +0100
Subject: [PATCH 5/9] winex11: Use the user configured keyboard layout if any.
Subject: [PATCH] winex11: Use the user configured keyboard layout if any.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=30984
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=45605
@ -12,10 +12,10 @@ Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=45605
3 files changed, 33 insertions(+), 6 deletions(-)
diff --git a/dlls/winex11.drv/keyboard.c b/dlls/winex11.drv/keyboard.c
index 187979c4494..26548c9256e 100644
index 7406aabdf40..4fc502cfe5d 100644
--- a/dlls/winex11.drv/keyboard.c
+++ b/dlls/winex11.drv/keyboard.c
@@ -934,7 +934,6 @@ static const struct {
@@ -931,7 +931,6 @@ static const struct {
{0, NULL, NULL, NULL, NULL} /* sentinel */
};
@ -23,7 +23,7 @@ index 187979c4494..26548c9256e 100644
/* maybe more of these scancodes should be extended? */
/* extended must be set for ALT_R, CTRL_R,
@@ -1089,6 +1088,26 @@ static const WORD xfree86_vendor_key_vkey[256] =
@@ -1086,6 +1085,26 @@ static const WORD xfree86_vendor_key_vkey[256] =
0, 0, 0, 0, 0, 0, 0, 0 /* 1008FFF8 */
};
@ -50,7 +50,7 @@ index 187979c4494..26548c9256e 100644
WCHAR *x11drv_get_keyboard_layout_list( DWORD *length )
{
WCHAR *tmp, *layouts = calloc( 1, sizeof(WCHAR) );
@@ -1442,11 +1461,11 @@ BOOL X11DRV_KeyEvent( HWND hwnd, XEvent *xev )
@@ -1432,11 +1451,11 @@ BOOL X11DRV_KeyEvent( HWND hwnd, XEvent *xev )
* whichever matches most closely.
* kbd_section must be held.
*/
@ -64,15 +64,15 @@ index 187979c4494..26548c9256e 100644
KeySym keysym = 0;
const char (*lkey)[MAIN_LEN][4];
unsigned max_seq = 0;
@@ -1546,6 +1565,7 @@ X11DRV_KEYBOARD_DetectLayout( Display *display )
@@ -1534,6 +1553,7 @@ X11DRV_KEYBOARD_DetectLayout( Display *display )
main_key_tab[kbd_layout].comment);
TRACE("detected layout is \"%s\"\n", main_key_tab[kbd_layout].comment);
+ return kbd_layout;
}
static HKL get_locale_kbd_layout(void)
@@ -1614,7 +1634,7 @@ void X11DRV_InitKeyboard( Display *display )
@@ -1569,7 +1589,7 @@ void X11DRV_InitKeyboard( Display *display )
{ 0x41, 0x5a }, /* VK_A - VK_Z */
{ 0, 0 }
};
@ -81,7 +81,7 @@ index 187979c4494..26548c9256e 100644
pthread_mutex_lock( &kbd_mutex );
XDisplayKeycodes(display, &min_keycode, &max_keycode);
@@ -1648,8 +1668,9 @@ void X11DRV_InitKeyboard( Display *display )
@@ -1601,8 +1621,9 @@ void X11DRV_InitKeyboard( Display *display )
}
XFreeModifiermap(mmp);
@ -94,10 +94,10 @@ index 187979c4494..26548c9256e 100644
syms = (keysyms_per_keycode > 4) ? 4 : keysyms_per_keycode;
diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h
index 7d96ec648d1..c02a6c67111 100644
index 12be88a31c5..653d2fe80e3 100644
--- a/dlls/winex11.drv/x11drv.h
+++ b/dlls/winex11.drv/x11drv.h
@@ -443,6 +443,7 @@ extern BOOL use_system_cursors DECLSPEC_HIDDEN;
@@ -455,6 +455,7 @@ extern BOOL use_system_cursors DECLSPEC_HIDDEN;
extern BOOL show_systray DECLSPEC_HIDDEN;
extern BOOL grab_pointer DECLSPEC_HIDDEN;
extern BOOL grab_fullscreen DECLSPEC_HIDDEN;
@ -105,7 +105,7 @@ index 7d96ec648d1..c02a6c67111 100644
extern BOOL usexcomposite DECLSPEC_HIDDEN;
extern BOOL managed_mode DECLSPEC_HIDDEN;
extern BOOL decorated_mode DECLSPEC_HIDDEN;
@@ -711,6 +712,7 @@ extern void init_recursive_mutex( pthread_mutex_t *mutex ) DECLSPEC_HIDDEN;
@@ -723,6 +724,7 @@ extern void init_recursive_mutex( pthread_mutex_t *mutex ) DECLSPEC_HIDDEN;
/* keyboard.c */
@ -114,10 +114,10 @@ index 7d96ec648d1..c02a6c67111 100644
#define DEPTH_COUNT 3
diff --git a/dlls/winex11.drv/x11drv_main.c b/dlls/winex11.drv/x11drv_main.c
index 66dbc3c8270..dc2eb716d0b 100644
index 751bf2b4449..7056cf6643d 100644
--- a/dlls/winex11.drv/x11drv_main.c
+++ b/dlls/winex11.drv/x11drv_main.c
@@ -79,6 +79,7 @@ BOOL use_system_cursors = TRUE;
@@ -76,6 +76,7 @@ BOOL use_system_cursors = TRUE;
BOOL show_systray = TRUE;
BOOL grab_pointer = TRUE;
BOOL grab_fullscreen = FALSE;
@ -125,7 +125,7 @@ index 66dbc3c8270..dc2eb716d0b 100644
BOOL managed_mode = TRUE;
BOOL decorated_mode = TRUE;
BOOL private_color_map = FALSE;
@@ -580,6 +581,9 @@ static void setup_options(void)
@@ -578,6 +579,9 @@ static void setup_options(void)
if (!get_config_key( hkey, appkey, "GrabFullscreen", buffer, sizeof(buffer) ))
grab_fullscreen = IS_OPTION_TRUE( buffer[0] );
@ -136,5 +136,5 @@ index 66dbc3c8270..dc2eb716d0b 100644
if (p) set_reg_string_value( hkey, "KeyboardLayoutList", p, len * sizeof(WCHAR) );
free( p );
--
2.39.1
2.39.2

View File

@ -1 +1 @@
a8fa80cfb4a1819be12ece459753bc07d4ea8be6
7db5431699037d03f26c065a58c400991210c7f7