OSDN Git Service

Use input transport for communications between app and IME.
authorJeff Brown <jeffbrown@google.com>
Tue, 26 Mar 2013 22:42:39 +0000 (15:42 -0700)
committerJeff Brown <jeffbrown@google.com>
Tue, 26 Mar 2013 22:42:39 +0000 (15:42 -0700)
commitc28867a1d67121ce5963de135e3ae2b1dbd9a33d
tree95da9070093882f0b95ee197f45f5b4a5e348d96
parent37f180b4a52e4c1d0b6a7b400b6579b7ff25f307
Use input transport for communications between app and IME.

The input method manager service now supplies an input channel for
communication while creating an IME session on behalf of the
application.

This change significanly reduces the overhead of IME event dispatch
by using a standard input channel to send input events rather than
using binder.  This results in fewer thread context switches
and fewer object allocations.

What's more, the IME may perform additional batching of the motion
events that it receives which may help it catch up if it is
getting behind while processing them.

Bug: 7984576
Bug: 8473020
Change-Id: Ibe26311edd0060cdcae80194f1753482e635786f
18 files changed:
Android.mk
CleanSpec.mk
core/java/android/app/NativeActivity.java
core/java/android/inputmethodservice/AbstractInputMethodService.java
core/java/android/inputmethodservice/IInputMethodSessionWrapper.java
core/java/android/inputmethodservice/IInputMethodWrapper.java
core/java/android/view/InputChannel.java
core/java/android/view/InputEventSender.java [new file with mode: 0644]
core/java/android/view/ViewRootImpl.java
core/java/android/view/inputmethod/InputMethodManager.java
core/java/com/android/internal/view/IInputMethod.aidl
core/java/com/android/internal/view/IInputMethodCallback.aidl [deleted file]
core/java/com/android/internal/view/IInputMethodSession.aidl
core/java/com/android/internal/view/InputBindResult.java
core/jni/Android.mk
core/jni/AndroidRuntime.cpp
core/jni/android_view_InputEventSender.cpp [new file with mode: 0644]
services/java/com/android/server/InputMethodManagerService.java