From dca2d926f7f2323939aceef982333d12abe4e82b Mon Sep 17 00:00:00 2001 From: Clara Bayarri Date: Mon, 13 Jun 2016 14:14:12 +0100 Subject: [PATCH] Cleanup usage of toUpperCase in Keyboard Shortcuts Helper The current approach may lead to some cases being dropped, it is easier to just apply it to the view's properties. Change-Id: I7c9c171858f7fc1844d0c4250df583d93a3443ba --- packages/SystemUI/res/layout/keyboard_shortcuts_key_view.xml | 3 ++- .../src/com/android/systemui/statusbar/KeyboardShortcuts.java | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/SystemUI/res/layout/keyboard_shortcuts_key_view.xml b/packages/SystemUI/res/layout/keyboard_shortcuts_key_view.xml index 31a87730a445e..9b5e0c893b2e1 100644 --- a/packages/SystemUI/res/layout/keyboard_shortcuts_key_view.xml +++ b/packages/SystemUI/res/layout/keyboard_shortcuts_key_view.xml @@ -23,4 +23,5 @@ android:textColor="@color/ksh_key_item_color" android:singleLine="true" android:gravity="center" - android:textSize="@dimen/ksh_item_text_size"/> + android:textSize="@dimen/ksh_item_text_size" + android:textAllCaps="true" /> diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/KeyboardShortcuts.java b/packages/SystemUI/src/com/android/systemui/statusbar/KeyboardShortcuts.java index d845121c6e991..461a03b67a2ea 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/KeyboardShortcuts.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/KeyboardShortcuts.java @@ -697,7 +697,7 @@ public final class KeyboardShortcuts { if (displayLabelDrawable != null) { shortcutKeys.add(new StringOrDrawable(displayLabelDrawable)); } else if (displayLabelString != null) { - shortcutKeys.add(new StringOrDrawable(displayLabelString.toUpperCase())); + shortcutKeys.add(new StringOrDrawable(displayLabelString)); } return shortcutKeys; } @@ -716,7 +716,7 @@ public final class KeyboardShortcuts { mModifierDrawables.get(supportedModifier))); } else { shortcutKeys.add(new StringOrDrawable( - mModifierNames.get(supportedModifier).toUpperCase())); + mModifierNames.get(supportedModifier))); } modifiers &= ~supportedModifier; }