Update System UI to use theme colors.
Instead of using hardcoded values, use colorPrimary, colorAccent, etc
to style system UI. Required setting a theme on several views to
get the proper accent color in the right place.
Deletes a lot of hard-coded colors from the app.
Deletes an unused view: StatusBarHeaderView
BUG: 28625050
BUG: 29003410
BUG: 28625105
Change-Id: I46cd8eba7cf5afdab53c7882aa4aac5af46772a9
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/KeyboardShortcuts.java b/packages/SystemUI/src/com/android/systemui/statusbar/KeyboardShortcuts.java
index 9211562..adb0e9f 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/KeyboardShortcuts.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/KeyboardShortcuts.java
@@ -54,6 +54,7 @@
import android.widget.TextView;
import com.android.internal.app.AssistUtils;
+import com.android.settingslib.Utils;
import com.android.systemui.R;
import com.android.systemui.recents.Recents;
@@ -112,7 +113,7 @@
private KeyCharacterMap mKeyCharacterMap;
private KeyboardShortcuts(Context context) {
- this.mContext = new ContextThemeWrapper(context, android.R.style.Theme_Material_Light);
+ this.mContext = new ContextThemeWrapper(context, android.R.style.Theme_DeviceDefault_Light);
this.mPackageManager = AppGlobals.getPackageManager();
loadResources(context);
}
@@ -582,7 +583,7 @@
R.layout.keyboard_shortcuts_category_title, keyboardShortcutsLayout, false);
categoryTitle.setText(group.getLabel());
categoryTitle.setTextColor(group.isSystemGroup()
- ? mContext.getColor(R.color.ksh_system_group_color)
+ ? Utils.getColorAccent(mContext)
: mContext.getColor(R.color.ksh_application_group_color));
keyboardShortcutsLayout.addView(categoryTitle);