Add a new API IMM#dispatchKeyEventFromInputMethod().
This is a part of effort to reduce the number of dependencies on @hide
method in BaseInputConnection.
Currently BaseInputConnection#sendKeyEvent() cannot be implemented
without relying on @hide internal fields in InputMethodManager.
This is not ideal because app developers cannot implement their own
InputConnection without relying on BaseInputConnection. If this
functionality needs to be exposed to app developers anyway, then it
should be a public API.
Bug:
24688781
Change-Id: Ib5ea8131de5ba792b10e1a4e51b4d163cf3649e3