Revert "Never load launcher on long press recents"

This reverts commit 000e6208807d4c426e2545546c5e7643f2fff0c7.

(cherry picked from commit 362b5c70b6b70321692142c4cea933340be0b79d)
Revert "Long press recents to switch to last app"

This reverts commit 2c9829ba9423d1955110b69ceeca54e253ec92ac.

(cherry picked from commit f221ffda3fe1b16fa6977be4834449fd01871368)
Custom actions on navbar recents long press (1/2)

For now 7 actions are possible
1 - none
2 - last app
3 - screenshot
4 - kill app
5 - notifications panel
6 - QS panel
7 - power menu

Thanks to @kufikugel for base and idea in SlimRoms navbar and navring customization

Change-Id: Ic96d8bb31025efd7260759709ddb8d9736c2619f
(cherry picked from commit a7b9de42ba5764c2ff7d53a77790eba18814fb8d)
Never load launcher on long press recents

Related: AOSPA-279

Change-Id: I7860d84c4eb36fe0f592dfc4d5b2769040abf182

Conflicts:
	packages/SystemUI/src/com/android/systemui/recent/RecentTasksLoader.java

(cherry picked from commit cc35335a35e62855f6d747468da74fdb3c2c97a4)
Add music tile from SlimRom (1/2)

Change-Id: I3e828afe9fcbabd7c93b54932cf9653bc9de20cd
(cherry picked from commit 2bcb9efa436b78a76a0d80a8b50d8a377f9697a5)
Fliptile animation - Music Tile

Change-Id: Ib7aef64433934f7cc286a7e9199b330218330ad1
(cherry picked from commit 1a36ae50a96cd1e7d58e4f31afae33441ae7e8cd)
Add music tile options (1/2)

disable artwork
disable track title optional

Credits to SlimRom

Change-Id: I442af9b4a3fffcb2f3e3388da4ed1aeadda4ff82
(cherry picked from commit 5f133b32a8c9a17fda03a122fc85487e4487e2a9)
QS: music tile update on Uri change

gives the user a bit better feeling when changing
the tile settings in Settings due it does react
immediately

Change-Id: I162477bb65eab7e0283aae135aeb013f99e38abc
(cherry picked from commit ebc992ec77d0eb0b3aa564a4f61977e262a714e2)
SystemUI: Pimp-up Media Tile

Allow double-click to start a sleep timer
	for the currently playing media.

PS:
- clearer button descriptions on different states
- if timer is in progress restore and show the time the
  user had set up and notify that he is in timer progress

modified to work with flip tile animation.

Change-Id: I7848523e7bc3d9577361ff55f010a9909d46e665
(cherry picked from commit c3be3bce69ef0242b3081678f4f4f39474686c83)
Last App Toggle from Omnirom (1/2)

Change-Id: I5c66e0cc2126a9ade755577dc58fb6f9e0a12763
(cherry picked from commit 28c9bd91903506e7b0439dce411494870a97a4e1)
fb: restore navbar compatibility with several xposed modules

I am tired of the complains....

Xposed use the emulator overwrite to enable/disable navbar...this results
into showing up navbar on reboot even if the user has set it to off in settings.

This fixes the issue and still keeps for emulator tests the basic overwrite functionallity
alive as long the provider value was not set.

We may should reflect that in settings as well.

Change-Id: Id60b45645d489c08539d56b8e05d135c36d38990

Conflicts:
	policy/src/com/android/internal/policy/impl/PhoneWindowManager.java

(cherry picked from commit 15c59531667cedb91a49d704598a82bc866d4e4d)
SystemUI: Add LongClick SwitchButton

User TJKV had the idea to set notification
	button to the notification station.
	Nothing else fits in my mind...so
	that's what I'll use there.

Change-Id: I2087de5c5ff2387d51b4c7685fc7aa3c0d26d72e
(cherry picked from commit bc4b2c5bcb1e59fcd9d86fab90268a73e8e91b22)
Framework: QuickRecord Tile (1/2)

Images by kroz (thanks!)
Change-Id: I22f9de88d401a777e987ec2c1bbbf599dc840d5d

(cherry picked from commit 52f08bd1cdad4e63a0f95c3dfcb79c8425bfe2ac)
Fix soft reboot using power menu through tile, navring and recent long press

- Using slim roms idea of this commit: https://github.com/SlimRoms/frameworks_base/commit/2d7b1afb903858bf26ac98dc9de64924a5ce9a05 and calling all power menu actions from the same thread

Change-Id: Ie4768a1722a41164474ef300f4a1b67c535349f6

Conflicts:

	core/java/android/view/IWindowManager.aidl
	core/java/com/android/internal/statusbar/IStatusBar.aidl
	core/java/com/android/internal/util/cm/QSConstants.java
	packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
	packages/SystemUI/src/com/android/systemui/statusbar/CommandQueue.java

(cherry picked from commit 2b6f5b91a3ab44d3e04751c69c9f922a15a40fd6)
[WIP] SlimPIE (1/2)

Port to CM11.0 sources by @cristianomatos

Change-Id: I2c3f5f23909f746e1a325be81ec4c3ec83e26568
(cherry picked from commit 900d251187944faea5ea4f1ab2f97481fa810d80)
fb: Handle navbar heights correct on dpi changes + more (1/2)
Till now we set the height in px in the settings. Which is a problem
especially on multiDPI roms like we are when the user afterwards changes
the dpi due that it isn't calculated correct anymore on the new dpi.

This commit does
- save the dp value in provider and calculate the real px in fb
- clean up the settings stuff for it + do it a bit nicer (only settings part
  where we do not set the value for the listview)
- add Converter class for common methods we always use....till now only px->dp
  and dp->px method

Change-Id: I413634fc433e0501eba69db2a463fac231e22f72
(cherry picked from commit 71fac12e1823fc58d854ac65585fafbdc29c5c40)
fb: restore navbar compatibility with several xposed modules
I am tired of the complains....

Xposed use the emulator overwrite to enable/disable navbar...this results
into showing up navbar on reboot even if the user has set it to off in settings.

This fixes the issue and still keeps for emulator tests the basic overwrite functionallity
alive as long the provider value was not set.

We may should reflect that in settings as well.

Change-Id: I99f04da8110bbcfcdba62604610d1f4330aea4d0

Conflicts:
	policy/src/com/android/internal/policy/impl/PhoneWindowManager.java

(cherry picked from commit 9058d93fecdc8b5741fc8618a3aeb4d2f82dcfbd)
Frameworks: fix qs and notification shade toggle on expanded desktop
If expanded desktop is enabled and statusbar hidden the toggle does not force
the statusbar to show before it pulls down the shade

fix it with just requesting the the statusbar to show up before we actually
peform the action

Change-Id: I3cfae445f02d7911048dcb5199a5492c0f05acc5
(cherry picked from commit d965f5e086901a3f0ac7774e2d2196e26790d4fa)
Frameworks: Imagehelper...do a nicer resize with better quality

Change-Id: Ibec4658d46a2c6ef1b6bacf505227949c3bcbfdc
(cherry picked from commit 89f56b623e39500338561fd236914bbfe95be2af)
Frameworks: fix navbar and pie icons for tablets and RTL

well due that we use a completly other attempt then googles navbar we do not
need to rely on different sized icons for portrait and landscape. So just a square
icon fits our needs perfect (which is so or so everwhere in AOSP default to use square ones).

Whatever recents pie feature showed us that we still forgot to size the pictures for our tablets
and as well for RTL user.

So let us do it now to fix any resizing issues on navbar and or SlimPie

Change-Id: I5257b789a5450754a296141b0af63d2eacaa87c9
(cherry picked from commit 2a388b7a7e750a4cac6338898947bdd7ff2d8a4d)