[Spice-devel] [PATCH] Send key release event for some keys in JP keyboard.

Takao Fujiwara tfujiwar at redhat.com
Thu Mar 31 12:41:50 UTC 2016


Sorry, the subject and description is not correct.
I will send this patch again with the correct subject.

On 03/31/16 19:43, Takao Fujiwara-san wrote:
> 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:;
>       }
>   
> 



More information about the Spice-devel mailing list