fix(wayland): text input enables once per focus; touches route by their finger's window
enable resets the input method's state, so sending it with every caret
move (an application keeps the cursor rectangle current while typing)
dropped the composition at each keystroke: enable now goes once per
focus and a moved caret sends its rectangle alone; disable only takes
back an enable. The compositor's leave ends both, and a window still
showing composing text hears onPreedit("") then. A finger's up and motion
go to the window it went down on, not the window of the latest down. The
seat creates its pointer and keyboard once, as it already did the touch:
capabilities come again when a device appears or goes, and a second
keyboard proxy delivered every key twice.
This commit is contained in:
parent
c8b5739e1a
commit
1498a5bf4b
3 changed files with 32 additions and 10 deletions
|
|
@ -234,6 +234,7 @@ export namespace Crafter {
|
|||
// mid-session (the hotspot only updates when set_cursor is recalled).
|
||||
std::uint32_t lastPointerSerial_ = 0;
|
||||
bool textInputActive_ = false;
|
||||
bool textInputEnabled_ = false; // enable sent and not taken back since
|
||||
std::int32_t textInputRect_[4] = { 0, 0, 0, 0 };
|
||||
TextInputPurpose textInputPurpose_ = TextInputPurpose::Normal;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue