From b7b38bd0b3cf3b2c8ad949cb4834fc22c5cb3ded Mon Sep 17 00:00:00 2001 From: Yohei Yukawa Date: Thu, 13 Oct 2022 21:52:48 -0700 Subject: [PATCH] Inline IMM.DelegateImpl#startInput() This CL inlines InputMethodManager.DelegateImpl#startInput(). There must be no observable behavior change except for we no longer log IME tracing event "InputMethodManager.DelegateImpl#startInput". If that event is turned out to be useful, we can add a similar tag later, but for now it doesn't look to be critically useful. Bug: 234882948 Test: presubmit Change-Id: I15919fba14c3c78d64796c3e600cfd8f62e73133 --- .../view/inputmethod/InputMethodManager.java | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/core/java/android/view/inputmethod/InputMethodManager.java b/core/java/android/view/inputmethod/InputMethodManager.java index 2e8ee77f43f28..4d9f6f5fb5c85 100644 --- a/core/java/android/view/inputmethod/InputMethodManager.java +++ b/core/java/android/view/inputmethod/InputMethodManager.java @@ -738,16 +738,6 @@ public final class InputMethodManager { private final class DelegateImpl implements ImeFocusController.InputMethodManagerDelegate { - private boolean startInput(@StartInputReason int startInputReason, View focusedView, - @StartInputFlags int startInputFlags, @SoftInputModeFlags int softInputMode, - int windowFlags) { - ImeTracing.getInstance().triggerClientDump( - "InputMethodManager.DelegateImpl#startInput", InputMethodManager.this, - null /* icProto */); - return startInputOnWindowFocusGainInternal(startInputReason, focusedView, - startInputFlags, softInputMode, windowFlags); - } - private void finishInput() { ImeTracing.getInstance().triggerClientDump( "InputMethodManager.DelegateImpl#finishInput", InputMethodManager.this, @@ -920,7 +910,8 @@ public final class InputMethodManager { } if (startInput) { - startInput(StartInputReason.CHECK_FOCUS, null /* focusedView */, + startInputOnWindowFocusGainInternal(StartInputReason.CHECK_FOCUS, + null /* focusedView */, 0 /* startInputFlags */, 0 /* softInputMode */, 0 /* windowFlags */); } return true; @@ -2410,7 +2401,7 @@ public final class InputMethodManager { } /** - * Called when {@link DelegateImpl#startInput}, {@link #restartInput(View)}, + * Called when {@link DelegateImpl#checkFocus}, {@link #restartInput(View)}, * {@link #MSG_BIND} or {@link #MSG_UNBIND}. * Note that this method should *NOT* be called inside of {@code mH} lock to prevent start input * background thread may blocked by other methods which already inside {@code mH} lock.