[2/2] Frameworks: HALO

Forward port from jb.
PS1: Initial port
     Fix conficts with notification LED
     Fix derp
     Major derp
     HALO Mods
     Rebase
     Fix blackist, code clean and added some TODOs
PS2: Fix build
PS3: Fix bubble sometimes doesn't respond on new notification
PS4: Align halo icon
PS5: Keep floating app in recents and disable transparent layer temporarily
PS6: Fix conflict after recent merges
PS7: Cosmetic fixes:
     Fix buttons layout in status bar.
     Status bar button holders show halo + qs switch on notification and qs edit mode + notification switch on qs.
     Update new margins size.
PS8: Rebase
     Clean white spaces
     Toggle on/off from notification shade icon (remove red X)
     Standardize behavior (remove option to reverse tap/double tap)
PS9: Remove references to LayerActivity
PS14: Rebase
PS15: update halo strings to prevent conflict with latest changes
PS16: Wrap all things!
      Modify halo behavior
PS17: Get the correct activity stack: this makes all windows in the same stack to get the floating mode

Change-Id: I3e79945433d61da090ca263f4e2989be9987f11d

Conflicts:
	packages/SystemUI/res/values/pa_strings.xml
[1/2] LED: Battery Light

==Requires==
in device tree's overlay/frameworks/base/core/res/res/values/config.xml:

    <!-- Is the battery LED intrusive? Used to decide if there should be a disable option -->
    <bool name="config_intrusiveBatteryLed">true</bool>

    <!-- Does the battery LED support multiple colors? Used to decide if the user can change the colors -->
    <bool name="config_multiColorBatteryLed">true</bool>

PS6: enable by default
PS7: rmv public.xml additions
PS8: incompatible types getInteger to getBoolean
PS9: Works

Signed-off-by: Andre Saddler <dresadd09691@gmail.com>
Change-Id: Iadaba42c1752e31cc77804e5b0d01788724c35c8
[2/2] Framework/base: Lockscreen maximized widgets

      Enable lockscreen widgets to be expanded by default.

      PA modifications to commit:
          Allow for long press unlock.
          Enable checkbox only if "Enable Widgets" is selected
          Remove preference is device is a tablet (already expanded)

Change-Id: I6a354d218fa5cc4603b92ba479d6aeba7f8f9c60
[WIP] Quicksettings 3.0

* Improve code (cleanup, indenting, redistribute resources, some comments updates).
* Fix: Restore stock aosp transition for quick settings on rotate (the rebuild animation
       executed when you are on quick settings panel and rotate the screen is not always showed).
* Animated Dual Tiles
  Animation: Use flip animator classes by xplodwild (OmniRom).
  Use aosp quick settings classes and methods to build dual tiles.
  Make dedicated classes for rssi/network tile.
  Change the original flippable tiles concept making them dual tiles for real.
  Integrate dual tiles into edit mode (WIP).
  Tiles added:
      -Wifi AP Tile (Dual): Made the aosp way. Created receiver for the main intent sent to change
       wifi ap state (also toggling with apps will refresh it). Integrated with Wifi Tile. Thanks
       CyanogenMod for the drawables.
      -Screen Timeout Tile (Dual): Integrate it in the sleep tile. Cleaner implement. Thanks Yanuar Harry
       for improving the behaviour :)
      -Bluetooth Extra Tile (Dual): Original from OmniRom. Rewrote it. Build and update it with android’s
       stock classes and methods (aosp basic tile's). Toggles discoverability. Thanks Lo Huot for the drawables.
  Tiles cleaned/updated:
      -Immersive Tile: Cleanup and store its resources to QuickSettingsModel with their own methods. Setup a post delay runnable/handler
       to let we postpone the activating animation and let quicksettings panel finish the collapse.
      -Brightness Tile: Long click toggles auto-mode.
      -RSSI Tile (Dual): Simplify the code. Show off indicator when data is disabled. Merge in Mobile Networks
       Tile.
      -Cleaned Wifi one and general cleanup for the others.
* TODO: Change dual animation/structure. Actually dual tiles drag listener doesn't work in edit mode,
        btw if you drag another one (normal) over it they got exchanged.

PS2: Fix rssi front tile construction.
PS3: Clean up wrongly added file.
     Fix and update rssi tile.
     Solve recent merge conflicts.
PS4: Rebase:
     Fix traces of not solved conflicts after recent merges rebase.
     Improve the dual tile logic, reduce code in QuickSettings class.
     Improve screen timeout (sleep sub-tile) code, thanks Yanuar Harry.
     Don't return dual (flip) animator touch event on edit mode. (Need test)
     Nitpicks cleanup.
     Update main commit message.
PS5: Continue rebasing:
     General code cleanup.
     Improve strings and drawables labels.
     Fix wifi ap tile construction and NPEs.
     Remove unused imports.
     Cleaned dual sleep tile implement (more polish methods names).
     Cleaned paired device bluetooth extra tile traces (added some todo).
     Update edit mode integration.
     Added a refresh callback sub-class for network tile (now contructed with
         new Basic Network Tile class Not yet used).
     Update commit message (added a TODO for rssi tile and for edit mode).
PS6: Finish bluetooth extra tile. Add drawables, refresh resources.
     Improve immersive tile.
     Traces of previous rebase.
PS7: Fix missing icon and signal activity state for rssi tile.
     Restore rssi refresh method to aosp state.
     Try to restore wifi signal activity (it doesn't show up and don't know why, yet).

Change-Id: Iceccd6a489c23286d8bc4e285fbb87b77509cd29
Signed-off-by: Carlo Savignano <stevewatersy@gmail.com>

Conflicts:
	packages/SystemUI/res/values/pa_strings.xml
QS Lightbulb: Remove Panel Collapse

Remove collapsable qs drawer behaviour when lightbulb tile is deactivated

PS2: remove whitespace
PS3: derp removed one extra collapsePanels(); by mistake
PS4: derp

Signed-off-by: Andre Saddler <dresadd09691@gmail.com>
Change-Id: Ic42670b42455b683808d1f6b637b8a1085e7ed1a
Quicksettings: Volume tile

Original Author: cristianomatos
Original Commit: https://github.com/cristianomatos/android_frameworks_base/commit/22a45a3166d4e37fad2caf912a7e00fc9fd9e897

Change-Id: I73c6459c602b16204c9bdbd226b2973200cbe8aa
Conflicts:
	packages/SystemUI/res/values/pa_strings.xml

Conflicts:
	packages/SystemUI/res/values/pa_strings.xml
[1/2] Base: NavigationBar Customization

- Allows user to customize navigation bar.
  Features :
   * Choose from 1-6 # of buttons
   * Re-arrange / assign buttons

- Navbar : Rework logic for determining orientation

PS2: Add DeviceUtils helper class from slimroms
PS3: fix NavigationBarView && add lockCurrentOrientation function to DeviceUtils
(related to NavBar.java in settings)
PS6: PhoneStatusBar.java fixes: mRecentsClickListener
PS7: Discard some lines from DeviceUtils.java
PS8: remove DeviceUtils.java

Change-Id: Ifea7efdfe1374e71e617a113624c265938a524aa

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

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

Conflicts:
	packages/SystemUI/res/values/pa_strings.xml
Framework: Forward port Long press back to kill app

Change-Id: I51aa5735ab7196ccdc18c3da3b6f6b5710c34224
Base: [1/2] Customizable lockscreen & navring targets

This is a squashed commit, ported from CM:

Add GlowPadView extensions needed for lockscreen targets and nav ring
Author: Danny Baumann <dannybaumann@web.de>
Change-Id: I4f82fd3fe04ac16c6737d38b2473f2a533c5d326

Framework : Lockscreen - Customizable shortcuts
Author: Danesh M <daneshm90@gmail.com>
Change-Id: Ic3b935df5c0da35f31373d96943e442dc39cf11b

Add back navigation ring customization
Author: Danny Baumann <dannybaumann@web.de>
Change-Id: Iebe4ec7c2519b85cfd5189d060444764a50f3cf6
Quicksettings: Power menu tile

Change-Id: I8ac70617cb75a45a76fb9272d62b74db70cd632e

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

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

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

Conflicts:
	packages/SystemUI/res/values/pa_strings.xml
Using Lightbulb in navring

Change-Id: If26de34652ed13b9112006357854d0b0edcabab0
Fix: Network tiles for CDMA devices

Change-Id: I2e526c8d94cc561c48c2a9198311e03b4f18328d
Configurable volume panel style (1/2)

- Using volume panel through tile we can set:
1 - Single
2 - Expandable
3 - Expanded
4 - None

Original commit: d628aa068e0530070767b42f7c63c98c8f0fc446
Thanks to @StevenHarperUK

Change-Id: Ib69100346f5c9bc93204fc4b585798d0b5a18f93
Keyguard: don't refresh ui when screen off KeyguardStatusView is doing refresh all the time, which cause high power when screen off.

Original commit: https://android-review.googlesource.com/#/c/78853/

Change-Id: Iaca0c01947bb372f1c5a18c78a50ff788f89a53d