mirror of
https://github.com/gnif/LookingGlass.git
synced 2024-11-21 21:17:19 +00:00
[client] spice: correctly ungrab keyboard when grabKeyboardOnFocus=no
When input:grabKeyboardOnFocus=no, exiting capture mode should ungrab the keyboard. Otherwise, focusing the window doesn't grab the keyboard, but toggling capture mode would leave the keyboard stuck in a grabbed state until defocused.
This commit is contained in:
parent
637a7625d2
commit
ec921d7f39
@ -1563,7 +1563,7 @@ static void setGrabQuiet(bool enable)
|
||||
{
|
||||
if (params.grabKeyboard)
|
||||
{
|
||||
if (!g_state.focused || params.captureInputOnly)
|
||||
if (!params.grabKeyboardOnFocus || !g_state.focused || params.captureInputOnly)
|
||||
g_state.ds->ungrabKeyboard();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user