PowerManager : Make proximity check opt-in

Change-Id: I7cf64a82530da2e655018e43683ba7a5584d54f8
Make sure ThemeConfig is non-null when loading resources

When the device boots into safemode, the theme config will end up
being null and we need to check that prior to using it to retrieve
resources for the StatusBarIconView

This fixes CYAN-5009

Change-Id: I1a90bc9f9c65cb41a6e58947bbd1b6d7728a952b
Themes: Add ability to apply color filters to composed icons

Themes can include one or more of the following filter tags in
assets/icons/res/xml/appfilter.xml

    <!-- HUE filter
         Integer value between -180 and 180 representing the degree.
         0 = no change
    -->
    <filter name="hue">0</filter>

    <!-- SATURATION filter.
         0 = grayscale, 100 = no change, 200 = over saturated
    -->
    <filter name="saturation">0</filter>

    <!-- BRIGHTNESS filter.
         0 = pitch black, 100 = no change, 200 = 200% brightness
    -->
    <filter name="brightness">100</filter>

    <!-- CONTRAST filter.
         -100 = minimal contrast, 0 = no change, 100 = maximum contrast
    -->
    <filter name="contrast">100</filter>

    <!-- ALPHA filter.
         0 = transparent, 100 = opaque
    -->
    <filter name="alpha">75</filter>

    <!-- INVERT filter.
         Valid values are true or false
         true = invert colors
    -->
    <filter name="invert">false</filter>

    <!-- TINT filter.
         A hexadecimal value representing ARGB
    -->
    <filter name="tint">#ff0000ff</filter>

Change-Id: I2431237dd2766176be16c730020557ce87d623e4
Revert "Prevent MediaScanner infinite loop with invalid path"

This reverts commit 912efb47689b71c90ee53ddf49508f986efe934b.
Hover: Sync with crDroid
FB: Slimrecents background color && transparency [2/2]
PS: now setting sticks through reboots and TRDS state
        changes. also, add reset to default color option.

PS: when resetting to default, use TRDS (png) resources
        instead of custom color

PS: remove LSN dependency

PS: make default background setting cognizant of
        recent panel gravity setting to display
        correct background resource

Change-Id: I159a757cc8bf39692dd3ff43f5e2e5ea41de4b55
Revert "QuickSettings : Register/unregister cast tile one time"

This causes a CTS failure: android.security.cts.ListeningPortsTest
  testNoRemotelyAccessibleListeningUdp6Ports

This reverts commit e037c1fe6dbdcd077719f7fc7b1902a887b56c23.

Change-Id: Idc145b6fb17490664fb5614d44e1ae92c98df844
advanced reboot: add soft reboot option

Adds a "Soft reboot" option which restarts zygote, as requested in JIRA
CYAN-3998

Change-Id: Ia6e5ed9b053e1c5ebd1fc55e5692858b97f7e0fc
Signed-off-by: Roman Birg <roman@cyngn.com>
Themes: Fix icon filters clamping to wrong values

Change-Id: Iab3cce465f8bdfd7c30a020fda254728349c5ebe
Themes: Make sure composed icon info is meaningful

We don't want to try and create a composed icon if the parts that
make up a composed icon are not valid or set.

Change-Id: I3d9e7432e4b351de9c0a4e662e028932ee7f08e2
Add animation when using navbar recent long press toggle last app

- Fix a little derp in PhoneStatusBar / private View.OnClickListener mRecentsClickListener leading to double click recent button need to preload recents panel work after every use of toggle last app feature
- There's no need to check this -> private boolean mRecentsLongClicked = true or false;
- Also cancelPreloadingRecentTasksList() everytime we call TaskUtils.toggleLastAppImpl(mContext);

Based on cm commit: https://github.com/CyanogenMod/android_frameworks_base/commit/2578c4748bf44c726957f94ffc7c4d265da2637b

Change-Id: Ie459f4be510e0eda7fa39270e863f011edc9a8d0
ShutdownThread: set soft reboot trigger accordingly

Change-Id: I72bd52aa1492d356e368e8c60897002c1f110172
Merge branch 'cm-11.0' of https://github.com/temasek/android_frameworks_base into HEAD

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonView.java

Change-Id: I2538303f9b32a45355198a8982f523986421cb14