store layouts in the same way in selected, enabled and additional layouts

This commit is contained in:
Helium314 2025-02-16 10:44:11 +01:00
parent d005ffac06
commit a25ed6d5e0
16 changed files with 272 additions and 296 deletions

View file

@ -199,8 +199,8 @@ public final class AndroidSpellCheckerService extends SpellCheckerService
editorInfo.inputType = InputType.TYPE_CLASS_TEXT;
Settings.getInstance().loadSettings(this, locale, new InputAttributes(editorInfo, false, getPackageName()));
}
final String keyboardLayoutName = SubtypeSettingsKt.getMatchingLayoutSetNameForLocale(locale);
final InputMethodSubtype subtype = SubtypeUtilsAdditional.INSTANCE.createDummyAdditionalSubtype(locale, keyboardLayoutName);
final String mainLayoutName = SubtypeSettingsKt.getMatchingMainLayoutNameForLocale(locale);
final InputMethodSubtype subtype = SubtypeUtilsAdditional.INSTANCE.createDummyAdditionalSubtype(locale, mainLayoutName);
final KeyboardLayoutSet keyboardLayoutSet = createKeyboardSetForSpellChecker(subtype);
return keyboardLayoutSet.getKeyboard(KeyboardId.ELEMENT_ALPHABET);
}