xpra icon
Bug tracker and wiki

Opened 2 weeks ago

Closed 2 weeks ago

#2380 closed defect (fixed)

stuck keys on macOS when swap_keys=0

Reported by: William Horka Owned by: Antoine Martin
Priority: major Milestone: 3.0
Component: html5 Version: trunk
Keywords: mac macos keyboard stuck repeating Cc:

Description

Hi Antoine,

Thank you for all your work on the Xpra project. We are using it at my department in the university to provide our researchers with a VDI-like experience through Kubernetes.

While testing, I noticed a bug in the HTML5 client when connecting from macOS. A keypress modifed by the Command (⌘) key becomes "stuck" repeating if the "swap_keys" option is disabled.

I saw that you already had a workaround for this in the _keyb_process function in Client.js, but the workaround is bypassed if "swap_keys" is false.

I assume this was a shorthand way of detecting a Mac client, since elsewhere swap_keys defaults to true for Mac clients.

However swap_keys is not necessarily always true on Mac clients, and the workaround is needed on Mac clients regardless of the state of swap_keys, so I believe it should be checking Utilities.isMacOS() instead of swap_keys. That way it will always run on Mac clients (and only on Mac clients).

I have attached a patch for your consideration which works in my local tests.

Sincerely,

-Bill

Attachments (1)

xpra-html5-Client-swap-keys-stuck.patch (644 bytes) - added by William Horka 2 weeks ago.
HTML5 client - simulate release of key on macOS when meta modifier is pressed, regardless of the state of swap_keys

Download all attachments as: .zip

Change History (2)

Changed 2 weeks ago by William Horka

HTML5 client - simulate release of key on macOS when meta modifier is pressed, regardless of the state of swap_keys

comment:1 Changed 2 weeks ago by Antoine Martin

Resolution: fixed
Status: newclosed

Thanks!
Applied in r23461.

Note: See TracTickets for help on using tickets.