We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 5507 - [PATCH] Window resizing fails when keyboard is grabbed on GNOME X11
Summary: [PATCH] Window resizing fails when keyboard is grabbed on GNOME X11
Status: RESOLVED FIXED
Alias: None
Product: SDL
Classification: Unclassified
Component: video (show other bugs)
Version: HG 2.0
Hardware: x86_64 Linux
: P2 normal
Assignee: Sam Lantinga
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-01-28 01:48 UTC by Cameron Gutman
Modified: 2021-01-28 02:44 UTC (History)
0 users

See Also:


Attachments
Patch (1.94 KB, patch)
2021-01-28 01:49 UTC, Cameron Gutman
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Cameron Gutman 2021-01-28 01:48:20 UTC
GNOME Mutter on X11 requires keyboard grab for certain important functionality like window resizing, interaction with the application context menu, and opening the Activites view. To allow Mutter to grab the keyboard as needed, we'll ungrab when the mouse leaves our window.

This problem has been there since initial support for keyboard grab in X11, but it wasn't reachable previously because mouse grab prevented those controls from actually being accessible (since the mouse couldn't move outside the window to reach them).

Some investigation done by the VirtualBox is here: https://www.virtualbox.org/ticket/10842#comment:3

The approach I'm taking here matches what VirtualBox ultimately decided to do: https://github.com/mdaniel/virtualbox-org-svn-vbox-trunk/blob/7661adb1ab02277f10f861bfbe03a81b78612aad/src/VBox/RDP/client-1.8.4/xwin.c#L2525
Comment 1 Cameron Gutman 2021-01-28 01:49:06 UTC
Created attachment 4723 [details]
Patch
Comment 2 Sam Lantinga 2021-01-28 02:44:50 UTC
Fixed, thanks!
https://hg.libsdl.org/SDL/rev/aa47564b5861