We currently have code in -[WKView resignFirstResponder] that cancels the current composition. There are some problems with it:
1. It's a sync IPC call, which I want to eliminate.
2. It doesn't actually work most of the time, because editorState tracking is broken, and we often think that there is no composition even when there is one.
3. Modern AppKit behavior appears to be that it confirms a composition when switching between text views within a window. Or maybe it's flaky too, but one way or another, confirming seems like a reasonable behavior.
Created attachment 227962 [details]
The same probably makes sense for old code path too, but I don't want to touch it unless absolutely necessary.
Comment on attachment 227962 [details]
Clearing flags on attachment: 227962
Committed r166388: <http://trac.webkit.org/changeset/166388>
All reviewed patches have been landed. Closing bug.