DescriptionImplement input.ime.sendKeyEvents API.
This cl implements input.ime.senKeyEvents API on Linux & Windows platform. The API calls the method InputMethodEngineBase::SendKeyEvents(), which contains the common code for ChromeOS/NonChromeOS. And the platform-specific codes are written in InputMethodEngine::SendKeyEvent().
On ChromeOS, the key event is dispatched from directly calling EventProcessor::OnEventFromSource(). While, On Linux & Windows, the key event is dispatched through ImeInputContextHandlerInterface::SendKeyEvent(), which will be implemented by InputMethodXxx.
This implementation is similar to input.ime.setComposition and input.ime.commitText APIs.
Add browser test in c/t/d/e/api_test/input_ime_nonchromeos/*.
BUG=517773
TEST=BrowserTest --gtest_filter=InputImeApiTest.*
Committed: https://crrev.com/b293444e8dbe567102fb82ab8831b4e7ac23a59a
Cr-Commit-Position: refs/heads/master@{#381175}
Patch Set 1 #Patch Set 2 : Update test. #
Total comments: 2
Patch Set 3 : Addressed Shu's comment and update implementation on Windows. #
Total comments: 3
Patch Set 4 : Dispatch key event with InputContextHandler. #Patch Set 5 : Added Windows-specific implementation. #
Total comments: 1
Patch Set 6 : #Patch Set 7 : Fix patch conflict. #
Total comments: 12
Patch Set 8 : Not dispatch key event to extension if it's faked event from extension. #Patch Set 9 : #Patch Set 10 : Added DCHECK. #Patch Set 11 : Updated the json file. #
Total comments: 4
Patch Set 12 : #Patch Set 13 : Update gyp/gn file. #Patch Set 14 : Fix test failure. #Messages
Total messages: 41 (18 generated)
|