Make the "hidden battery" still appear in QS

While the hidden battery indicator mode implemented in the Settings
application should only hide the indicator in the status bar, it also
happens to hide it inside the QS tile for the battery which in turn
leaves an ugly UI. This commit provides a workaround by specifying
in which cases the indicator is being used for QS and providing a
special case for that.

Change-Id: Iede5dedfc90343d5b9f768aefc4a53b2aa56a1da
DialogFragement: Add null pointer check for mDialog for protection

DialogFragement can be dissmissed just after the Dialog is
established. This will cause NullPointerException.

Add null pointer check for mDialog for protection

CRs-fixed: 549689

Change-Id: If57f81d03a8ec2906598363b681ea38806fb2a90
Merge "Make the "hidden battery" still appear in QS" into kitkat
SystemUI: Make percentage appear for hidden batt

This commit makes the battery percentage appear in QS when the user
chooses the "hidden battery" option as the battery style. Prior to
this commit, the same battery style was used for the QS tile just
without the percentage indicator. This means no major changes are
being introduced but the usability is being improved as the user
can glance at the QS tile to see the exact percentage instead of
being forced to open the linked Settings page.

Fixes AOSPA-687.

Change-Id: I2131332f2639721f99e149d3add0eb2877b4debe
Merge "DialogFragement: Add null pointer check for mDialog for protection" into kitkat
Themes: Add helper methods for creating complete component maps

These methods can be used to apply a theme while replacing any
components not found in the theme with the defaults.

Default components come from the default theme for the system
with any missing components in that default theme coming from HOLO.

Change-Id: Idea55cc684ccc8304b01a991c36b6993f55b8880
Themes: Add STYLE_THUMBNAIL to PreviewColumns

Change-Id: Ie18264cbede92220335400428e67735866cd442d
HOVER: Fix status bar icon size

Thanks to Lo Huot

Signed-off-by: Carlo Savignano <stevewatersy@gmail.com>
Change-Id: I59d7a0d8712a5d0f7aa3dc12d9bc3e9884f69f98
Themes: Make notification list bg themeable (PS2)

Thanks Thomas Ekelschot :)

Screen of themed resource https://imgur.com/c8t1Zn0

PS2: Add Clark's proposed changes
PS3: Cleanup old color resource in main xml
PS4: Add informative screen

Signed-off-by: Carlo Savignano <stevewatersy@gmail.com>
Change-Id: I8eb4427747c3eb035b416860c3ca47122e45c16f
IconPackHelper: Don't respect an icons original size if too large.

  - Otherwise, if an application isn't following app icon guidelines,
  it can create an OOM situation when creating the new icon based
  on the original resource's height and width.

Change-Id: I9430445da5e393cdbf76ed9ebd9698bf30df6a95
Frameworks: Cleanup some CM dependencies

- Wrongly squashed into our xmls

Signed-off-by: Carlo Savignano <stevewatersy@gmail.com>
SystemUI: Correct settings observer usage

Settings observer was already created by a global variable, but
it was never used and instead a new one was created in start().

Corrected the code to utilize the already created settings observer.

Change-Id: I337ce12bf32f0355f6280f7b74767e5eb17438a6
Signed-off-by: Evan Anderson <evan@thelinuxman.us>
SystemUI: Allow theming of the "no recents" label

This commit defines the label of the "no recent apps" label as a
simple color which allows it to be modified in themes. This resource
matches what CM has been using in cm_colors.xml for a while.

Change-Id: I1346eb25dbcab519f3794d6601337ffa3b632e35
Merge "SystemUI: Allow theming of the "no recents" label" into kitkat
Merge "SystemUI: Correct settings observer usage" into kitkat
Merge "HOVER: Fix status bar icon size" into kitkat
Merge "IconPackHelper: Don't respect an icons original size if too large." into kitkat
Framework: Make the dialog divider color themeable

The holo blue color might not be suitable for some themes. This commit
swaps out the background of all titleDivider elements to use another
resource. This has no difference from the perspective of the user of a
"stock" build but this is huge for theme users.

Thanks to Arz Bhatia for the suggestion.

Change-Id: Icb917220accac3ad38770067120a7b1be894961a
SystemUI: Separate system bar BGs for themes

This commit separates the navigation bar background colors from the
status bar background colors which allows more modular theme-ability.
Backwards compatibility for the old system bar values is still
preserved, but the new values are to be prioritized.

Thanks to Arz Bhatia for the suggestion.

Change-Id: Ibe579d16ea35ca5bdcfe9f98143c3f91cd24900f
Merge "SystemUI: Separate system bar BGs for themes" into kitkat