imwayland: Avoid TOGGLE_INPUT_PANEL requests if there's no focus
authorCarlos Garnacho <carlosg@gnome.org>
Tue, 20 Mar 2018 14:17:31 +0000 (15:17 +0100)
committerSimon McVittie <smcv@debian.org>
Thu, 22 Mar 2018 10:15:24 +0000 (10:15 +0000)
commit6692d6d34f9565483a162cb8cc26a94812b53fbd
treebd904e535e9c62bd183b30f1d7d05a70f806321c
parent50ffc6c0ce93674f83c032a617a7e01f39651df7
imwayland: Avoid TOGGLE_INPUT_PANEL requests if there's no focus

Fixes two things: 1) As GTK+ can be coerced into using the wayland IM
module despite the compositor not implementing the interface, all paths
not checking for global state before sending requests are prone to
crashes, this one fell hit this pitfall.

And 2) ensures the tap gesture only triggers TOGGLE_INPUT_PANEL if the
widget IM is focused. This is a possibility on eg. WebKit pages, where
its IM is only focused as long as a form element in the page is focused.
Tapping elsewhere shouldn't toggle the OSK.

Origin: upstream, 3.22.30, commit:4f78abddfc8a815a7e02f5347d5326412190f66f
Bug: https://gitlab.gnome.org/GNOME/gtk/issues/114
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=893696

Gbp-Pq: Name 0010-imwayland-Avoid-TOGGLE_INPUT_PANEL-requests-if-there.patch
modules/input/imwayland.c