From 339207be6f184cc783076fc7e2cc12f92f57f2ba Mon Sep 17 00:00:00 2001 From: Jeremy Huddleston Date: Thu, 25 Mar 2010 22:15:58 -0700 Subject: [PATCH] XQuartz: Workaround weird key data reported on some layouts This should make 'Unicode Hex Input' work as an input layout. Signed-off-by: Jeremy Huddleston Acked-by: Adam Jackson --- hw/xquartz/quartzKeyboard.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/hw/xquartz/quartzKeyboard.c b/hw/xquartz/quartzKeyboard.c index c9ef7cc81..a4a0b08bd 100644 --- a/hw/xquartz/quartzKeyboard.c +++ b/hw/xquartz/quartzKeyboard.c @@ -735,7 +735,10 @@ Bool QuartzReadSystemKeymap(darwinKeyboardInfo *info) { if (err != noErr) continue; } - if (len > 0 && s[0] != 0x0010) { + /* Not sure why 0x0010 is there. + * 0x0000 - 'Unicode Hex Input' ... + */ + if (len > 0 && s[0] != 0x0010 && s[0] != 0x0000) { k[j] = ucs2keysym (s[0]); if (dead_key_state != 0) k[j] = make_dead_key (k[j]); }