Loading services/core/java/com/android/server/inputmethod/InputMethodManagerService.java +9 −30 Original line number Diff line number Diff line Loading @@ -1826,14 +1826,8 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl. @NonNull UserData userData) { final int userId = userData.mUserId; if (userData.mCurClient == client) { if (Flags.refactorInsetsController()) { final var statsToken = createStatsTokenForFocusedClient(false /* show */, SoftInputShowHideReason.HIDE_REMOVE_CLIENT, userId); setImeVisibilityOnFocusedWindowClient(false, userData, statsToken); } else { hideCurrentInputLocked(userData.mImeBindingState.mFocusedWindow, 0 /* flags */, SoftInputShowHideReason.HIDE_REMOVE_CLIENT, userId); } if (userData.mBoundToMethod) { userData.mBoundToMethod = false; final var userBindingController = userData.mBindingController; Loading Loading @@ -2103,14 +2097,8 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl. } if (visibilityStateComputer.getImePolicy().isImeHiddenByDisplayPolicy()) { if (Flags.refactorInsetsController()) { final var statsToken = createStatsTokenForFocusedClient(false /* show */, SoftInputShowHideReason.HIDE_DISPLAY_IME_POLICY_HIDE, userId); setImeVisibilityOnFocusedWindowClient(false, userData, statsToken); } else { hideCurrentInputLocked(userData.mImeBindingState.mFocusedWindow, 0 /* flags */, SoftInputShowHideReason.HIDE_DISPLAY_IME_POLICY_HIDE, userId); } return InputBindResult.NO_IME; } Loading Loading @@ -3867,17 +3855,8 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl. Slog.w(TAG, "If you need to impersonate a foreground user/profile from" + " a background user, use EditorInfo.targetInputMethodUser with" + " INTERACT_ACROSS_USERS_FULL permission."); if (Flags.refactorInsetsController()) { final var statsToken = createStatsTokenForFocusedClient( false /* show */, SoftInputShowHideReason.HIDE_INVALID_USER, userId); setImeVisibilityOnFocusedWindowClient(false, userData, statsToken); } else { hideCurrentInputLocked(userData.mImeBindingState.mFocusedWindow, 0 /* flags */, SoftInputShowHideReason.HIDE_INVALID_USER, userId); } 0 /* flags */, SoftInputShowHideReason.HIDE_INVALID_USER, userId); return InputBindResult.INVALID_USER; } Loading Loading @@ -5014,6 +4993,7 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl. setImeVisibilityOnFocusedWindowClient(false, userData, null /* TODO(b/353463205) check statsToken */); } else { hideCurrentInputLocked(userData.mImeBindingState.mFocusedWindow, 0 /* flags */, reason, userId); } Loading Loading @@ -6709,9 +6689,8 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl. final InputMethodSettings settings = InputMethodSettingsRepository.get(userId); final var userData = getUserData(userId); if (Flags.refactorInsetsController()) { final var statsToken = createStatsTokenForFocusedClient(false /* show */, SoftInputShowHideReason.HIDE_RESET_SHELL_COMMAND, userId); setImeVisibilityOnFocusedWindowClient(false, userData, statsToken); setImeVisibilityOnFocusedWindowClient(false, userData, null /* TODO(b329229469) initialize statsToken here? */); } else { hideCurrentInputLocked(userData.mImeBindingState.mFocusedWindow, 0 /* flags */, Loading Loading
services/core/java/com/android/server/inputmethod/InputMethodManagerService.java +9 −30 Original line number Diff line number Diff line Loading @@ -1826,14 +1826,8 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl. @NonNull UserData userData) { final int userId = userData.mUserId; if (userData.mCurClient == client) { if (Flags.refactorInsetsController()) { final var statsToken = createStatsTokenForFocusedClient(false /* show */, SoftInputShowHideReason.HIDE_REMOVE_CLIENT, userId); setImeVisibilityOnFocusedWindowClient(false, userData, statsToken); } else { hideCurrentInputLocked(userData.mImeBindingState.mFocusedWindow, 0 /* flags */, SoftInputShowHideReason.HIDE_REMOVE_CLIENT, userId); } if (userData.mBoundToMethod) { userData.mBoundToMethod = false; final var userBindingController = userData.mBindingController; Loading Loading @@ -2103,14 +2097,8 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl. } if (visibilityStateComputer.getImePolicy().isImeHiddenByDisplayPolicy()) { if (Flags.refactorInsetsController()) { final var statsToken = createStatsTokenForFocusedClient(false /* show */, SoftInputShowHideReason.HIDE_DISPLAY_IME_POLICY_HIDE, userId); setImeVisibilityOnFocusedWindowClient(false, userData, statsToken); } else { hideCurrentInputLocked(userData.mImeBindingState.mFocusedWindow, 0 /* flags */, SoftInputShowHideReason.HIDE_DISPLAY_IME_POLICY_HIDE, userId); } return InputBindResult.NO_IME; } Loading Loading @@ -3867,17 +3855,8 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl. Slog.w(TAG, "If you need to impersonate a foreground user/profile from" + " a background user, use EditorInfo.targetInputMethodUser with" + " INTERACT_ACROSS_USERS_FULL permission."); if (Flags.refactorInsetsController()) { final var statsToken = createStatsTokenForFocusedClient( false /* show */, SoftInputShowHideReason.HIDE_INVALID_USER, userId); setImeVisibilityOnFocusedWindowClient(false, userData, statsToken); } else { hideCurrentInputLocked(userData.mImeBindingState.mFocusedWindow, 0 /* flags */, SoftInputShowHideReason.HIDE_INVALID_USER, userId); } 0 /* flags */, SoftInputShowHideReason.HIDE_INVALID_USER, userId); return InputBindResult.INVALID_USER; } Loading Loading @@ -5014,6 +4993,7 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl. setImeVisibilityOnFocusedWindowClient(false, userData, null /* TODO(b/353463205) check statsToken */); } else { hideCurrentInputLocked(userData.mImeBindingState.mFocusedWindow, 0 /* flags */, reason, userId); } Loading Loading @@ -6709,9 +6689,8 @@ public final class InputMethodManagerService implements IInputMethodManagerImpl. final InputMethodSettings settings = InputMethodSettingsRepository.get(userId); final var userData = getUserData(userId); if (Flags.refactorInsetsController()) { final var statsToken = createStatsTokenForFocusedClient(false /* show */, SoftInputShowHideReason.HIDE_RESET_SHELL_COMMAND, userId); setImeVisibilityOnFocusedWindowClient(false, userData, statsToken); setImeVisibilityOnFocusedWindowClient(false, userData, null /* TODO(b329229469) initialize statsToken here? */); } else { hideCurrentInputLocked(userData.mImeBindingState.mFocusedWindow, 0 /* flags */, Loading