From 026d885cf7478eb87f5bccabd42a03bd342dd044 Mon Sep 17 00:00:00 2001 From: Yohei Yukawa Date: Wed, 15 Jun 2022 16:46:28 -0700 Subject: [PATCH] Rename InputMethodSessionWrapper to IInputMethodSessionInvoker This CL renames InputMethodSessionWrapper to IInputMethodSessionInvoker for better consistency with other wrapper classes. Other than that, there should be no change in this CL. Bug: 234882948 Test: presubmit Change-Id: I19dd92a538cd07ad506f3f27dcffdbe86799950f --- ...rapper.java => IInputMethodSessionInvoker.java} | 14 +++++++------- .../view/inputmethod/InputMethodManager.java | 6 +++--- 2 files changed, 10 insertions(+), 10 deletions(-) rename core/java/android/view/inputmethod/{InputMethodSessionWrapper.java => IInputMethodSessionInvoker.java} (89%) diff --git a/core/java/android/view/inputmethod/InputMethodSessionWrapper.java b/core/java/android/view/inputmethod/IInputMethodSessionInvoker.java similarity index 89% rename from core/java/android/view/inputmethod/InputMethodSessionWrapper.java rename to core/java/android/view/inputmethod/IInputMethodSessionInvoker.java index 6e9323d6ee62b..1fbe2d4a0a3a0 100644 --- a/core/java/android/view/inputmethod/InputMethodSessionWrapper.java +++ b/core/java/android/view/inputmethod/IInputMethodSessionInvoker.java @@ -32,7 +32,7 @@ import com.android.internal.inputmethod.IRemoteInputConnection; * Using current {@link IInputMethodSession} object to communicate with * {@link android.inputmethodservice.InputMethodService}. */ -final class InputMethodSessionWrapper { +final class IInputMethodSessionInvoker { private static final String TAG = "InputMethodSessionWrapper"; @@ -42,21 +42,21 @@ final class InputMethodSessionWrapper { @NonNull private final IInputMethodSession mSession; - private InputMethodSessionWrapper(@NonNull IInputMethodSession inputMethodSession) { + private IInputMethodSessionInvoker(@NonNull IInputMethodSession inputMethodSession) { mSession = inputMethodSession; } /** - * Create a {@link InputMethodSessionWrapper} instance if applicability. + * Create a {@link IInputMethodSessionInvoker} instance if applicability. * * @param inputMethodSession {@link IInputMethodSession} object to be wrapped. - * @return an instance of {@link InputMethodSessionWrapper} if {@code inputMethodSession} is not - * {@code null}. {@code null} otherwise. + * @return an instance of {@link IInputMethodSessionInvoker} if {@code inputMethodSession} is + * not {@code null}. {@code null} otherwise. */ @Nullable - public static InputMethodSessionWrapper createOrNull( + public static IInputMethodSessionInvoker createOrNull( @NonNull IInputMethodSession inputMethodSession) { - return inputMethodSession != null ? new InputMethodSessionWrapper(inputMethodSession) + return inputMethodSession != null ? new IInputMethodSessionInvoker(inputMethodSession) : null; } diff --git a/core/java/android/view/inputmethod/InputMethodManager.java b/core/java/android/view/inputmethod/InputMethodManager.java index ee4d9d594ea52..73d6241c21d1e 100644 --- a/core/java/android/view/inputmethod/InputMethodManager.java +++ b/core/java/android/view/inputmethod/InputMethodManager.java @@ -525,7 +525,7 @@ public final class InputMethodManager { */ @Nullable @GuardedBy("mH") - private InputMethodSessionWrapper mCurrentInputMethodSession = null; + private IInputMethodSessionInvoker mCurrentInputMethodSession = null; /** * Encapsulates IPCs to the currently connected AccessibilityServices. */ @@ -932,7 +932,7 @@ public final class InputMethodManager { setInputChannelLocked(res.channel); mCurMethod = res.method; // for @UnsupportedAppUsage mCurrentInputMethodSession = - InputMethodSessionWrapper.createOrNull(res.method); + IInputMethodSessionInvoker.createOrNull(res.method); mCurId = res.id; mBindSequence = res.sequence; mVirtualDisplayToScreenMatrix = res.getVirtualDisplayToScreenMatrix(); @@ -2419,7 +2419,7 @@ public final class InputMethodManager { setInputChannelLocked(res.channel); mBindSequence = res.sequence; mCurMethod = res.method; // for @UnsupportedAppUsage - mCurrentInputMethodSession = InputMethodSessionWrapper.createOrNull(res.method); + mCurrentInputMethodSession = IInputMethodSessionInvoker.createOrNull(res.method); mAccessibilityInputMethodSession.clear(); if (res.accessibilitySessions != null) { for (int i = 0; i < res.accessibilitySessions.size(); i++) {