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

Commit 4335047e authored by Satoshi Kataoka's avatar Satoshi Kataoka Committed by Android Git Automerger
Browse files

am b97e102c: am 1b570b57: am 5fd5aa3d: Fix compatibility issue on InputMethodSubtype

* commit 'b97e102c':
  Fix compatibility issue on InputMethodSubtype
parents 20e4995a b97e102c
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -534,6 +534,13 @@ public final class InputMethodSubtype implements Parcelable {
    private static int hashCodeInternal(String locale, String mode, String extraValue,
            boolean isAuxiliary, boolean overridesImplicitlyEnabledSubtype,
            boolean isAsciiCapable) {
        // CAVEAT: Must revisit how to compute needsToCalculateCompatibleHashCode when a new
        // attribute is added in order to avoid enabled subtypes being unexpectedly disabled.
        final boolean needsToCalculateCompatibleHashCode = !isAsciiCapable;
        if (needsToCalculateCompatibleHashCode) {
            return Arrays.hashCode(new Object[] {locale, mode, extraValue, isAuxiliary,
                    overridesImplicitlyEnabledSubtype});
        }
        return Arrays.hashCode(new Object[] {locale, mode, extraValue, isAuxiliary,
                overridesImplicitlyEnabledSubtype, isAsciiCapable});
    }