[1/2] Add battery level around unlock ring

PS2:
added missing change in KeyguardSelectorView.java

Change-Id: Ia4dbc2335657c096c34349ec67c4adfec0aeb91b

Conflicts:
	core/java/com/android/internal/widget/multiwaveview/GlowPadView.java
	packages/Keyguard/src/com/android/keyguard/KeyguardSelectorView.java

Conflicts:
	core/java/android/provider/Settings.java
	core/java/com/android/internal/widget/multiwaveview/GlowPadView.java

Conflicts:
	core/java/android/provider/Settings.java
LockScreen: allow long-press actions from hardware keys (1/2)

Allow following actions with button long-presses on lockscreen:
- toggle flashlight (if available)
- play/pause/next/previous track selection
- toggle silent mode

Allow customizing of back, menu, and home buttons. Search
button events are completely ignored on the lockscreen.

Auto-detect hardware keys, only show appropriate menu
options based on the actual hardware keys available on the
device (or completely hide if there are no hardware keys).

Based largely on Danny Baumann's work from gingerbread.

Ported from CM10
Change-Id: Iff32736d00ca5d4122f64a6a861bbb0a1de9cca9

Fix home/menu unlock with long press hardware key
- Forward port of commit 2a572ee
Change-Id: Ic2eb85542f8052fe1662244fe5e72ba12a98608b

Keyguard: Fix for home wake/unlock
sometimes device is waking and unlocking during the same keypress.
Change-Id: I72ea7611d39aac0cd03dfd5aa7036aeef7600140

Use sticky broadcast to convey torch state (1/2).
It doesn't really make sense to store the (non-persistent) state of the
torch in a (persistent) setting. As the torch is sending a broadcast
anyway, make that broadcast sticky and use it to convey the state.

Also unify the torch constants (actions, extras, activity names) at a
common place.
Change-Id: If845bef27cc79990794aa748dce18cfea3bac1f5

Fix Home/Menu/Back keys' unlock
Change-Id: Ibd3842b6ad8e037a2a9f8eb581e7c55900017b0f

LockScreen: allow hardware key longpress to put device to sleep
Change-Id: I54260e21c462bcabd9b6383e22f44d644630b4d3

Conflicts:
	packages/Keyguard/src/com/android/keyguard/KeyguardViewManager.java

Conflicts:
	core/java/android/provider/Settings.java

Conflicts:
	packages/Keyguard/src/com/android/keyguard/KeyguardViewManager.java

Conflicts:
	core/java/android/provider/Settings.java

Conflicts:
	packages/Keyguard/src/com/android/keyguard/KeyguardViewManager.java

Conflicts:
	packages/Keyguard/src/com/android/keyguard/KeyguardViewManager.java

Conflicts:
	core/java/android/provider/Settings.java
[SQUASHED] Lockscreen Notifications [1/2]

My try on making notifications easily accessable from lockscreen.
Credits to ChameleonOS, I got the notification listener permission and some small other stuff from their ActiveDisplay implementation.

Lockscreen Notifications allow you to manage all your notifications directly on the lockscreen.

Features:
- Pocket mode turn screen on when phone is pulled out of pocket and turn it off when phone gets back in pocket
- Hide low priority notifications
- Hide non-clearable notifications
- Allow dismissing even non-clearable notifications from lockscreen
- Just turn screen on when there's currently a notification pending
- Toggle between expanded and normal notification view by longpressing

This should still be considered as beta, even if it seems to work very well for me.

Conflicts:
	core/java/android/provider/Settings.java
	packages/Keyguard/src/com/android/keyguard/KeyguardViewManager.java

Lockscreen Notifications: Make "wake on notifications" user configurable

and some other small changes that hopefully will improve battery live

Conflicts:
	core/java/android/provider/Settings.java

Lockscreen notifications: make height user configurable [1/2]

Conflicts:
	core/java/android/provider/Settings.java

Lockscreen Notifications: fix possible NPE

Lockscreen Notifications: try on fixing notifications sometimes not responding

Lockscreen Notifications: always scroll to bottom so one sees the newest notification first

Lockscreen Notificaitons: Fix NPE while on setup wizard on clean flash

Lockscreen Notifications: several fixes

- fix notification not responding when removed and added in a short period of time (e.g. gravity screen start/stop)
- just unlock screen on notification click when there's an activity to start
- fix notification hide animation
- just wake screen on reposted notifications when it's not ongoing (wake on notification before made the device stay awake for ever when a download/countdown or something similiar was running)

Lockscreen Notifications: just scroll down in "showAllNotifications"

Lockscreen Notifications: Copyright

Lockscreen Notifications: make offset top user configurable & add privacy mode [1/2]

Conflicts:
	core/java/android/provider/Settings.java

Lockscreen Notifications: Fix possible NPE

Lockscreen Notifications: make width dynamic (WRAP_CONTENT)

Lockscreen Notifications: make animations a bit faster

Lockscreen Notifications: fix notifications disappearing on orientation change

Lockscreen Notifications: disable dynamic width for devices <= xhdpi

Lockscreen Notification: fix default settings derp

Lockscreen Notifications: fix phone turning on in pocket

[1/2] Base: Lockscreen notifications: Allow apps to be excluded from being displayed

&& respect quiet hours

Credits to 0xD34D / ChameleonOS for the original implementation for Active Display

Change-Id: Ie0df1faedb275b1cf131d75d69d9d9cafc828dd9

Conflicts:
	core/java/android/provider/Settings.java
	packages/Keyguard/src/com/android/keyguard/NotificationViewManager.java

Conflicts:
	packages/Keyguard/src/com/android/keyguard/NotificationViewManager.java

Lockscreen Notifications: make dynamic width a device overlay setting

dynamic width is disabled by default, to enable it for a specific device, add
<bool name="config_lnDynamicWidth">true</bool>
to yourdevicetree/overlay/frameworks/base/packages/Keyguard/res/values/config.xml

Lockscreen Notifications: rewrite add notification logic

There were some problems with notifications getting replaced while the user was currently dragging them.
This commit should fix that by always waiting until animations and user input are finished before replacing a notification view.

Conflicts:
	packages/Keyguard/src/com/android/keyguard/NotificationViewManager.java

Lockscreen Notifications: dismiss all button, improve animations, cleanup

Conflicts:
	core/java/com/android/internal/statusbar/IStatusBar.aidl
	packages/Keyguard/src/com/android/keyguard/KeyguardViewManager.java
	packages/Keyguard/src/com/android/keyguard/NotificationHostView.java
	packages/SystemUI/res/layout/navigation_bar.xml
	packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
	packages/SystemUI/src/com/android/systemui/statusbar/CommandQueue.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardTouchDelegate.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java

Lockscreen Notifications: fix show/hide of show all button

& fix endless SystemUI FC when SystemUI is killed

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java

Lockscreen Notifications: fix NPE

Lockscreen Notifications: Custom background color [1/2]

Conflicts:
	core/java/android/provider/Settings.java

Lockscreen Notifications: try to fix occasionally SystemUI FC on boot

Lockscreen Notifications: fix FC when an expanded notification gets reposted without bigContentView

Lockscreen notifications: Add "show all notifications" navbar button

Change-Id: I0cd5b13e5644de36d24d4d693838bd7080f55412

Conflicts:
	packages/Keyguard/src/com/android/keyguard/KeyguardViewManager.java
	packages/Keyguard/src/com/android/keyguard/KeyguardViewMediator.java
	packages/SystemUI/res/layout/navigation_bar.xml
	packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardTouchDelegate.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarTransitions.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java

Lockscreen Notifications: dismiss all button, improve animations, cleanup

Change-Id: I77665e37d823c619680312b73d5ebb1e6e437ffd

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java

Conflicts:
	core/java/com/android/internal/statusbar/IStatusBar.aidl
	core/java/com/android/internal/statusbar/IStatusBarService.aidl
	packages/Keyguard/src/com/android/keyguard/NotificationViewManager.java
	packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
	packages/SystemUI/src/com/android/systemui/statusbar/CommandQueue.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
	services/java/com/android/server/StatusBarManagerService.java

Conflicts:
	core/java/android/provider/Settings.java

Conflicts:
	core/java/android/provider/Settings.java

Conflicts:
	core/java/android/provider/Settings.java

Lockscreen Notifications: some fixes

Conflicts:
	core/java/android/provider/Settings.java

Keyguard: LN: fix and harden against null pointer exceptions

Change-Id: Iff66791bb35b911e837b0a1747a72effdce507e3

Conflicts:
	packages/Keyguard/src/com/android/keyguard/KeyguardViewManager.java

Conflicts:
	packages/Keyguard/src/com/android/keyguard/KeyguardViewManager.java

Conflicts:
	packages/Keyguard/src/com/android/keyguard/KeyguardViewManager.java
Enable and disable device hardware keys
Change glowpad torch from double tap to longpress
Add double tap sleep feature to secure lockscreens.

In its current state double tap works on the status bar on unsecure
lockscreens this adds the feature to pin, password, and pattern
lockscreens.

 - pin and password: double tap the text entry view.
 - pattern: double tap anywhere on the pattern view.

Patch Set 3:
 - add to slide lockscreen(glowpad): double tap glow pad to sleep
 - update commit message

Change-Id: I70eeae4acaa61b44feab661082bcfdbac7b9dfc3
Signed-off-by: baked <travp624@gmail.com>

Conflicts:
	packages/Keyguard/src/com/android/keyguard/KeyguardAbsKeyInputView.java
	packages/Keyguard/src/com/android/keyguard/KeyguardSelectorView.java

Conflicts:
	packages/Keyguard/src/com/android/keyguard/KeyguardSelectorView.java
[1/2] Keyguard: Add unlock icons for Gmail and Snapchat

Change-Id: I3e3df643eec4d02a20855a53b6fd4f8b59fb0ede
googlebackuptransport: fix for google backup and restore

This fixes restore issues with properly done 4.4 gapps

Change-Id: Ib0cec129d138a195e64f5bba36602ac5fdeda42d
Allow installation of non market apps by default
Gesture Anywhere: Add gesture anywhere feature into the ChaOS Lab [1/2]

When enabled a user can activate the gesture anywhere view by touching
the designated trigger area.  If a gesture is recognized as one the user
has created and assigned to an action, that action will be performed.
Since this is part of the system UI and implemented as an overlay, it
will be available and usable system wide, with the exception of the
keyguard for obvious reasons.

Change-Id: Icc2822e1de276bfb2850e885a84edab1ca84cf0d

Gesture Anywhere: Adjust position on orientation change.

Also added hiding home, recent and search from navbar when
showing the GestureAnywhere view.

Change-Id: I1dd13f38af265d6966441f2cd99b78ea9b3d4d90

Gesture anywhere: Collapse if expanded when screen turns off.

Change-Id: I85c749182dab9e478d7337b3556c362eaa7dd74d

ChaosLab: Add annotation to be used when adding new features to the lab.

This should be used when adding completely new features to ChameleonOS,
and not for simple things that expand upon a current feature.

Change-Id: I37d7250424967d41ecfb885120627f5397b2f804

Gesture Anywhere: Adjust position on orientation change.

Also added hiding home, recent and search from navbar when
showing the GestureAnywhere view.

Change-Id: I1dd13f38af265d6966441f2cd99b78ea9b3d4d90

Conflicts:
	core/java/android/provider/Settings.java
[1/2] Base: implement App circle sidebar

add whitelist app to include into circle view
rebased
make standalone patch

PS.15 : rebased
PS.16 : cleanup

Change-Id: I08d2a3a7e0f8df20e801e585d4cac8547a740a3e

Conflicts:
	core/java/android/provider/Settings.java
	packages/SystemUI/res/values/custom_strings.xml
	packages/SystemUI/res/values/custom_styles.xml
	packages/SystemUI/res/values/liquid_dimens.xml
	packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java

Conflicts:
	core/java/android/provider/Settings.java
	packages/SystemUI/res/values/liquid_strings.xml
	packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java

Conflicts:
	core/java/android/provider/Settings.java
	packages/SystemUI/res/values/liquid_strings.xml

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
Base: App Circle sidebar (add support floating window)

PS.8 : rebased
PS.9 : add support minimize/maximize window

Change-Id: Ied388a0a4054dfaf1d3e6fcdc33dd5aab28565a9

Conflicts:
	packages/SystemUI/res/values/custom_strings.xml

Conflicts:
	packages/SystemUI/res/values/liquid_strings.xml

Conflicts:
	packages/SystemUI/res/values/liquid_strings.xml

Conflicts:
	packages/SystemUI/res/values/liquid_strings.xml
"Clear all" button on recent apps

Port forward from cm-10.2

Change-Id: I9ebcf22f85957f61caefb14e0efd4cf2978d92cd
Add touch feedback to the clear all recents button

5 minutes of Photoshop™.

Change-Id: Idf8c97cf08a192605208cbee6f2ae41e0798e8d1