Loading java/res/values/attrs.xml +1 −0 Original line number Diff line number Diff line Loading @@ -379,6 +379,7 @@ </declare-styleable> <declare-styleable name="Keyboard_Case"> <attr name="keyboardLayoutSet" format="string" /> <!-- This should be aligned with KeyboardLayoutSet_Element's elementName. --> <attr name="keyboardLayoutSetElement" format="enum|string"> <enum name="alphabet" value="0" /> Loading java/src/com/android/inputmethod/keyboard/internal/KeyboardBuilder.java +13 −7 Original line number Diff line number Diff line Loading @@ -625,6 +625,9 @@ public class KeyboardBuilder<KP extends KeyboardParams> { final AttributeSet attr = Xml.asAttributeSet(parser); final TypedArray caseAttr = mResources.obtainAttributes(attr, R.styleable.Keyboard_Case); try { final boolean keyboardLayoutSetMatched = matchString(caseAttr, R.styleable.Keyboard_Case_keyboardLayoutSet, SubtypeLocaleUtils.getKeyboardLayoutSetName(id.mSubtype)); final boolean keyboardLayoutSetElementMatched = matchTypedValue(caseAttr, R.styleable.Keyboard_Case_keyboardLayoutSetElement, id.mElementId, KeyboardId.elementIdToName(id.mElementId)); Loading Loading @@ -657,15 +660,18 @@ public class KeyboardBuilder<KP extends KeyboardParams> { R.styleable.Keyboard_Case_languageCode, id.mLocale.getLanguage()); final boolean countryCodeMatched = matchString(caseAttr, R.styleable.Keyboard_Case_countryCode, id.mLocale.getCountry()); final boolean selected = keyboardLayoutSetElementMatched && modeMatched && navigateNextMatched && navigatePreviousMatched && passwordInputMatched && clobberSettingsKeyMatched && shortcutKeyEnabledMatched && shortcutKeyOnSymbolsMatched && hasShortcutKeyMatched && languageSwitchKeyEnabledMatched && isMultiLineMatched && imeActionMatched && localeCodeMatched && languageCodeMatched && countryCodeMatched; final boolean selected = keyboardLayoutSetMatched && keyboardLayoutSetElementMatched && modeMatched && navigateNextMatched && navigatePreviousMatched && passwordInputMatched && clobberSettingsKeyMatched && shortcutKeyEnabledMatched && shortcutKeyOnSymbolsMatched && hasShortcutKeyMatched && languageSwitchKeyEnabledMatched && isMultiLineMatched && imeActionMatched && localeCodeMatched && languageCodeMatched && countryCodeMatched; if (DEBUG) { startTag("<%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s>%s", TAG_CASE, startTag("<%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s>%s", TAG_CASE, textAttr(caseAttr.getString( R.styleable.Keyboard_Case_keyboardLayoutSet), "keyboardLayoutSet"), textAttr(caseAttr.getString( R.styleable.Keyboard_Case_keyboardLayoutSetElement), "keyboardLayoutSetElement"), Loading Loading
java/res/values/attrs.xml +1 −0 Original line number Diff line number Diff line Loading @@ -379,6 +379,7 @@ </declare-styleable> <declare-styleable name="Keyboard_Case"> <attr name="keyboardLayoutSet" format="string" /> <!-- This should be aligned with KeyboardLayoutSet_Element's elementName. --> <attr name="keyboardLayoutSetElement" format="enum|string"> <enum name="alphabet" value="0" /> Loading
java/src/com/android/inputmethod/keyboard/internal/KeyboardBuilder.java +13 −7 Original line number Diff line number Diff line Loading @@ -625,6 +625,9 @@ public class KeyboardBuilder<KP extends KeyboardParams> { final AttributeSet attr = Xml.asAttributeSet(parser); final TypedArray caseAttr = mResources.obtainAttributes(attr, R.styleable.Keyboard_Case); try { final boolean keyboardLayoutSetMatched = matchString(caseAttr, R.styleable.Keyboard_Case_keyboardLayoutSet, SubtypeLocaleUtils.getKeyboardLayoutSetName(id.mSubtype)); final boolean keyboardLayoutSetElementMatched = matchTypedValue(caseAttr, R.styleable.Keyboard_Case_keyboardLayoutSetElement, id.mElementId, KeyboardId.elementIdToName(id.mElementId)); Loading Loading @@ -657,15 +660,18 @@ public class KeyboardBuilder<KP extends KeyboardParams> { R.styleable.Keyboard_Case_languageCode, id.mLocale.getLanguage()); final boolean countryCodeMatched = matchString(caseAttr, R.styleable.Keyboard_Case_countryCode, id.mLocale.getCountry()); final boolean selected = keyboardLayoutSetElementMatched && modeMatched && navigateNextMatched && navigatePreviousMatched && passwordInputMatched && clobberSettingsKeyMatched && shortcutKeyEnabledMatched && shortcutKeyOnSymbolsMatched && hasShortcutKeyMatched && languageSwitchKeyEnabledMatched && isMultiLineMatched && imeActionMatched && localeCodeMatched && languageCodeMatched && countryCodeMatched; final boolean selected = keyboardLayoutSetMatched && keyboardLayoutSetElementMatched && modeMatched && navigateNextMatched && navigatePreviousMatched && passwordInputMatched && clobberSettingsKeyMatched && shortcutKeyEnabledMatched && shortcutKeyOnSymbolsMatched && hasShortcutKeyMatched && languageSwitchKeyEnabledMatched && isMultiLineMatched && imeActionMatched && localeCodeMatched && languageCodeMatched && countryCodeMatched; if (DEBUG) { startTag("<%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s>%s", TAG_CASE, startTag("<%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s>%s", TAG_CASE, textAttr(caseAttr.getString( R.styleable.Keyboard_Case_keyboardLayoutSet), "keyboardLayoutSet"), textAttr(caseAttr.getString( R.styleable.Keyboard_Case_keyboardLayoutSetElement), "keyboardLayoutSetElement"), Loading