winex11: Be more conservative when matching keys from built-in layout tables.

Ken Thomases ken at codeweavers.com
Thu May 31 15:33:23 CDT 2012


Example of a bug this fixes: a Lithuanian user's key map has key code 17
mapped to keysym 0x03fe (umacron) and key code 18 mapped to keysym 0x0afe
(doublelowquotemark).  XkbTranslateKeySym can't produce a 1-byte translation
for either keysym (locale uses UTF-8).  Wine was then using the LSB (0xfe) as
the character to look for, for both key codes.  Wine's main_key_LT_B table
actually has a match for that byte, in the VK_OEM_PLUS position.  This led to
key presses with key code 18 producing the characters corresponding to key
code 17.

Wine's fallback vkey assignment logic would have produced better results had
no match been found.
---
dlls/winex11.drv/keyboard.c |    2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-winex11-Be-more-conservative-when-matching-keys-from.patch
Type: text/x-patch
Size: 621 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-patches/attachments/20120531/46407f19/attachment.bin>


More information about the wine-patches mailing list