[Spice-devel] [spice-gtk 3/3] Send key release event for some keys in JP keyboard.
Fabiano FidĂȘncio
fidencio at redhat.com
Thu Mar 31 12:38:40 UTC 2016
From: Takao Fujiwara <tfujiwar at redhat.com>
Some of the keys in JP keyboard do no send WM_KEYUP and it causes
unlimited key events on Linux desktop. This sends the virtual
key release events to avoid the desktop hangup.
---
src/spice-widget.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/src/spice-widget.c b/src/spice-widget.c
index 5e71d1b..c5a4530 100644
--- a/src/spice-widget.c
+++ b/src/spice-widget.c
@@ -1493,6 +1493,15 @@ static gboolean key_event(GtkWidget *widget, GdkEventKey *key)
}
}
break;
+ case 0x412: /* KR keyboard */
+ if (key->hardware_keycode == VK_HANGUL && native_scancode == 0x38) {
+ /* Left Alt (VK_MENU) has the scancode 0x38 but Hangul (VK_HANGUL)
+ * has the scancode 0x138
+ */
+ scancode = native_scancode | 0x100;
+ goto got_scancode;
+ }
+ break;
default:;
}
--
2.7.3
More information about the Spice-devel
mailing list