Repository navigation
input_method: send unavailable to the newcomer - #2198
Merged
Merged
Conversation
…ance The protocol allows one input method per seat and requires a second one to be the object that receives unavailable, leaving the first in place. add_instance did the reverse: it sent unavailable to the existing instance and dropped the newcomer untracked. destroyed also cleared the seat for any instance, so an inert newcomer exiting evicted the live one, and an inert newcomer's requests still drove the seat's text input.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi!
I'm the author of ewm, an emacs driven compositor which is based on smithay. Lately I was looking into adding generic support for external input methods (in addition to emacs which already works), so that e.g. ewm would start supporting fcitx5 etc. And while testing it I found a bug related to
input_method_v2protocol implementation in smithay.In ewm, emacs as input method is enabled by default, and its
zwp_input_method_v2object is the seat's tracked instance. When a user starts another program (e.g. fcitx5), it callsget_input_methodon the same seat. Currently inadd_instance, Smithay emitsunavailableon the original instance (emacs) and leaves fcitx5's new object untracked. This breaks the original input method while leaving fcitx5 with no follow up.Instead, per protocol the compositor should emit
unavailableon the new input method (fcitx5), and the original connected input method (emacs) instance stays and keeps receiving activate/deactivate.Here's an example of a correct behavior in Sway, keeping the existing instance and sending unavailable to the newcomer:
The protocol original description: here
Checklist