-
Notifications
You must be signed in to change notification settings - Fork 172
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add
restore_focus
argument to PointerInnerHandle::unset_grab
Used in `ClickGrab` to prevent `motion` events from occurring with every `button` event. Otherwise, behavior should be unchanged. This matches the argument taken by `KeyboardInnerHandle::unset_grab`. This seems like the simplest solution. It would also be possible to add a method to the `PointerGrab` trait indicating if focus should be restored, but that's complicated since `unset_grab` can't access the grab when it's `Borrowed`, so it would have to add a bool to `GrabStatus::Borrowed`, etc. This still doesn't send a `frame`, but since this takes a serial and a time, it probably will be sent along with other pointer events, and hopefully part of a `frame`. The Wayland spec isn't all that specific about when things can/should be part of a `frame`... Calling `motion` is also incorrect with pointer constraints, but grabs other than `ClickGrab` generally shouldn't exist while a constraint is active. It would be good to enforce that some way. Fixes #1148.
- Loading branch information
Showing
6 changed files
with
34 additions
and
27 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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