engine: a takeover keeps the text it took for the context it took it from
Two applications' focus events cross — ibus-daemon documents the case — so the first key of the new one can arrive before the old one says it lost focus. The engine dropped whatever that context was composing; it now keeps it and hands it back with the reset or release that follows, which every frontend already commits. Normal ordering is unchanged.
This commit is contained in:
@@ -284,7 +284,8 @@ server_connection_ownership(struct ct *t)
|
||||
req = nextrequest(t, &f.pump, Keyreset);
|
||||
CT_EQ_PTR(t, aowner, req.owner);
|
||||
allowrequest(&f.pump);
|
||||
CT_CHECK(t, readreply(t, &a, 1, "", preedit));
|
||||
/* The reset hands back what the takeover took from this client. */
|
||||
CT_CHECK(t, readreply(t, &a, 1, "か", preedit));
|
||||
CT_EQ_STR(t, "", preedit);
|
||||
CT_EQ_PTR(t, bowner, testengineowner());
|
||||
if(!sendkey(t, &b, 1, 0, 0))
|
||||
|
||||
Reference in New Issue
Block a user