diff options
| author | 2016-03-11 01:08:52 -0800 | |
|---|---|---|
| committer | 2016-03-11 01:08:52 -0800 | |
| commit | 80861ff1c0b3ca2c6cdf6fb4a224f3a015bd44bd (patch) | |
| tree | d7f6613a06a6140d42b7954aa5fdf6619702f19c /libs/hwui/FrameInfoVisualizer.cpp | |
| parent | a871c3104b6ae77eeee2b8d8bdb3371a0788c9a8 (diff) | |
Make sure to compare subtype language with system language.
This CL addresses a regression introduced by a recent CL [1] that
non-keyboard subtypes are no longer implicitly enabled based on the
system language (a.k.a. "use system language" in the subtype enabler)
due to a type mismatch in comparison.
Here is the original logic:
if (language.equals(systemLanguage) && systemLocale.startsWith(locale))
And here is the logic replaced by [1]:
if (locale != null && locale.equals(systemLanguage)) {
The new logic is simply broken, because locale is a Locale object while
systemLanguage is a String object. It never matches.
With this CL we will compare the system language with the locale
language again, with several test cases that should have been included
in [1], as a temporary solution until we start relying on
LocaleUtils#filterByLanguage() for non-keyboard subtypes.
[1]: Iaf179d60c12b9a98b4f097e2449471c4184e049b
e985c240e3feb62ea38d5b4e386be083ca0f215b
Bug: 27560993
Change-Id: If2d1710174853180465832e6ecbbb91235b76210
Diffstat (limited to 'libs/hwui/FrameInfoVisualizer.cpp')
0 files changed, 0 insertions, 0 deletions