summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--services/core/java/com/android/server/inputmethod/InputMethodManagerService.java8
-rw-r--r--services/core/java/com/android/server/inputmethod/InputMethodUtils.java5
2 files changed, 5 insertions, 8 deletions
diff --git a/services/core/java/com/android/server/inputmethod/InputMethodManagerService.java b/services/core/java/com/android/server/inputmethod/InputMethodManagerService.java
index 2d145c2d9b15..30e9f5bd2a14 100644
--- a/services/core/java/com/android/server/inputmethod/InputMethodManagerService.java
+++ b/services/core/java/com/android/server/inputmethod/InputMethodManagerService.java
@@ -5275,7 +5275,7 @@ public final class InputMethodManagerService extends IInputMethodManager.Stub
return true;
}
}
- mSettings.appendAndPutEnabledInputMethodLocked(id, false);
+ mSettings.appendAndPutEnabledInputMethodLocked(id);
// Previous state was disabled.
return false;
} else {
@@ -5612,7 +5612,7 @@ public final class InputMethodManagerService extends IInputMethodManager.Stub
if (enabled) {
if (!settings.getEnabledInputMethodListLocked().contains(
methodMap.get(imeId))) {
- settings.appendAndPutEnabledInputMethodLocked(imeId, false);
+ settings.appendAndPutEnabledInputMethodLocked(imeId);
}
} else {
settings.buildAndPutEnabledInputMethodsStrRemovingIdLocked(
@@ -6357,7 +6357,7 @@ public final class InputMethodManagerService extends IInputMethodManager.Stub
}
}
if (!previouslyEnabled) {
- settings.appendAndPutEnabledInputMethodLocked(imeId, false);
+ settings.appendAndPutEnabledInputMethodLocked(imeId);
}
}
} else {
@@ -6501,7 +6501,7 @@ public final class InputMethodManagerService extends IInputMethodManager.Stub
settings.putEnabledInputMethodsStr("");
nextEnabledImes.forEach(
imi -> settings.appendAndPutEnabledInputMethodLocked(
- imi.getId(), false));
+ imi.getId()));
// Reset selected IME.
settings.putSelectedInputMethod(nextIme);
diff --git a/services/core/java/com/android/server/inputmethod/InputMethodUtils.java b/services/core/java/com/android/server/inputmethod/InputMethodUtils.java
index acf9a7f9ae63..2128356e69c6 100644
--- a/services/core/java/com/android/server/inputmethod/InputMethodUtils.java
+++ b/services/core/java/com/android/server/inputmethod/InputMethodUtils.java
@@ -362,10 +362,7 @@ final class InputMethodUtils {
return result;
}
- void appendAndPutEnabledInputMethodLocked(String id, boolean reloadInputMethodStr) {
- if (reloadInputMethodStr) {
- getEnabledInputMethodsStr();
- }
+ void appendAndPutEnabledInputMethodLocked(String id) {
if (TextUtils.isEmpty(mEnabledInputMethodsStrCache)) {
// Add in the newly enabled input method.
putEnabledInputMethodsStr(id);