Merge "Remove IMMS#MSG_INITIALIZE_IME"
This commit is contained in:
@@ -309,8 +309,8 @@ final class InputMethodBindingController {
|
||||
if (DEBUG) Slog.v(TAG, "Initiating attach with token: " + mCurToken);
|
||||
final InputMethodInfo info = mMethodMap.get(mSelectedMethodId);
|
||||
mSupportsStylusHw = info.supportsStylusHandwriting();
|
||||
mService.executeOrSendInitializeIme(mCurMethod, mCurToken,
|
||||
info.getConfigChanges(), mSupportsStylusHw);
|
||||
mService.initializeImeLocked(mCurMethod, mCurToken, info.getConfigChanges(),
|
||||
mSupportsStylusHw);
|
||||
mService.scheduleNotifyImeUidToAudioService(mCurMethodUid);
|
||||
mService.reRequestCurrentClientSessionLocked();
|
||||
}
|
||||
|
||||
@@ -222,7 +222,6 @@ public class InputMethodManagerService extends IInputMethodManager.Stub
|
||||
private static final int MSG_SHOW_IM_CONFIG = 3;
|
||||
|
||||
private static final int MSG_HIDE_CURRENT_INPUT_METHOD = 1035;
|
||||
private static final int MSG_INITIALIZE_IME = 1040;
|
||||
private static final int MSG_CREATE_SESSION = 1050;
|
||||
private static final int MSG_REMOVE_IME_SURFACE = 1060;
|
||||
private static final int MSG_REMOVE_IME_SURFACE_FROM_WINDOW = 1061;
|
||||
@@ -2519,11 +2518,19 @@ public class InputMethodManagerService extends IInputMethodManager.Stub
|
||||
}
|
||||
}
|
||||
|
||||
@AnyThread
|
||||
void executeOrSendInitializeIme(@NonNull IInputMethod inputMethod, @NonNull IBinder token,
|
||||
@GuardedBy("ImfLock.class")
|
||||
void initializeImeLocked(@NonNull IInputMethod inputMethod, @NonNull IBinder token,
|
||||
@android.content.pm.ActivityInfo.Config int configChanges, boolean supportStylusHw) {
|
||||
executeOrSendMessage(inputMethod, mCaller.obtainMessageIOOO(MSG_INITIALIZE_IME,
|
||||
configChanges, inputMethod, token, supportStylusHw));
|
||||
if (DEBUG) {
|
||||
Slog.v(TAG, "Sending attach of token: " + token + " for display: "
|
||||
+ mCurTokenDisplayId);
|
||||
}
|
||||
try {
|
||||
inputMethod.initializeInternal(token,
|
||||
new InputMethodPrivilegedOperationsImpl(this, token), configChanges,
|
||||
supportStylusHw);
|
||||
} catch (RemoteException e) {
|
||||
}
|
||||
}
|
||||
|
||||
@AnyThread
|
||||
@@ -4248,23 +4255,6 @@ public class InputMethodManagerService extends IInputMethodManager.Stub
|
||||
|
||||
}
|
||||
return true;
|
||||
case MSG_INITIALIZE_IME:
|
||||
args = (SomeArgs)msg.obj;
|
||||
try {
|
||||
if (DEBUG) {
|
||||
synchronized (ImfLock.class) {
|
||||
Slog.v(TAG, "Sending attach of token: " + args.arg2 + " for display: "
|
||||
+ mCurTokenDisplayId);
|
||||
}
|
||||
}
|
||||
final IBinder token = (IBinder) args.arg2;
|
||||
((IInputMethod) args.arg1).initializeInternal(token,
|
||||
new InputMethodPrivilegedOperationsImpl(this, token),
|
||||
msg.arg1, (boolean) args.arg3);
|
||||
} catch (RemoteException e) {
|
||||
}
|
||||
args.recycle();
|
||||
return true;
|
||||
case MSG_CREATE_SESSION: {
|
||||
args = (SomeArgs)msg.obj;
|
||||
IInputMethod method = (IInputMethod)args.arg1;
|
||||
|
||||
Reference in New Issue
Block a user