Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 884ef9a1 authored by satok's avatar satok
Browse files

Return the enabled subtypes for the current InputMethod when the input value...

Return the enabled subtypes for the current InputMethod when the input value of getEnabledInputMethodSubtypeList was null

Change-Id: I6892064dbc2214946871a0ba4ad08e00a2eb6c7b
parent 7b71b3d9
Loading
Loading
Loading
Loading
+14 −9
Original line number Diff line number Diff line
@@ -557,6 +557,9 @@ public class InputMethodManagerService extends IInputMethodManager.Stub

    public List<InputMethodSubtype> getEnabledInputMethodSubtypeList(InputMethodInfo imi) {
        synchronized (mMethodMap) {
            if (imi == null && mCurMethodId != null) {
                imi = mMethodMap.get(mCurMethodId);
            }
            return mSettings.getEnabledInputMethodSubtypeListLocked(imi);
        }
    }
@@ -2043,6 +2046,7 @@ public class InputMethodManagerService extends IInputMethodManager.Stub
                    getEnabledInputMethodsAndSubtypeListLocked();
            ArrayList<InputMethodSubtype> enabledSubtypes =
                    new ArrayList<InputMethodSubtype>();
            if (imi != null) {
                for (Pair<String, ArrayList<String>> imsPair : imsList) {
                    InputMethodInfo info = mMethodMap.get(imsPair.first);
                    if (info != null && info.getId().equals(imi.getId())) {
@@ -2057,6 +2061,7 @@ public class InputMethodManagerService extends IInputMethodManager.Stub
                        break;
                    }
                }
            }
            return enabledSubtypes;
        }