mirror of
https://github.com/gnif/LookingGlass.git
synced 2024-12-22 13:52:57 +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
1 changed files with 1 additions and 1 deletions
|
@ -1563,7 +1563,7 @@ static void setGrabQuiet(bool enable)
|
||||||
{
|
{
|
||||||
if (params.grabKeyboard)
|
if (params.grabKeyboard)
|
||||||
{
|
{
|
||||||
if (!g_state.focused || params.captureInputOnly)
|
if (!params.grabKeyboardOnFocus || !g_state.focused || params.captureInputOnly)
|
||||||
g_state.ds->ungrabKeyboard();
|
g_state.ds->ungrabKeyboard();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue