Add InputMethodSubtype#isSuitableForPhysicalKeyboardLayoutMapping()
This is a preparation for implementing Subtype-keyed physical keyboard layout switching. This CL introduces an @hide method InputMethodSubtype#isSuitableForPhysicalKeyboardLayoutMapping() so that later CLs can be written on the same rule about what kind of InputMethodSubtype is valid for physical keyboard layout swithcing. Here is the current rule but it's subject to change. * hashCode() != 0 (SUBTYPE_ID_NONE) * getMode() must be "keyboard" * not isAuxiliary() * getCanonicalizedLanguageTag() returns a valid (non "und") value. See test cases to see how it works. Bug: 252816846 Test: atest FrameworksCoreTests:InputMethodSubtypeTest Change-Id: Ifc0247041a43ef64f8a76a23832da2ee058c6958
Loading
Please register or sign in to comment