Reflect current state of torch in navigation ring button.

JIRA: CYAN-574

Patch Set 1  -  Initial release
Patch Set 2  -  Show the current state

Change-Id: I82594726df1c0b4b34efdb6e58a0300f99cb1cde
ServiceState: add support for DCHSPAP

Change-Id: Ib0a328652c14580718400b00146b770481be5458
Swap volume buttons when the screen is rotated (1/2)

See: http://review.cyanogenmod.org/#/c/14530/

Patch Set 8: Invert the orientation interpretations on tablets

Change-Id: I201febc2827e6fbd347cb0e3f8d3347ad1bc487b

Conflicts:

	core/java/android/provider/Settings.java
Fix resource leak: When call MediaMetadataRetriever.setDataSource or getFrameAtTime should ensure call release in finally to avoid resource leak
                   Patch set 2: Remove unnecessary white spaces

Change-Id: I49a7f2fb99dc8b9560e7c17421125356e45a87ac
[HTML5] Implementation of WebSockets (framework).

Added binding to android port for Html5 WebSockets.
Added external API for enabling\disabling from browser.
SSL Web Sockets are not implemented in the current version.

Change-Id: I8b7a42780410cb9f043e1f16570ea50db68e00ea
Revert "makefile changes for gcm javadocs"

We don't build it, nor do we have these sources.

This reverts commit 5f9922d7c3bce158e4c7a58929d4075e7c91e32e.

Change-Id: I877e617f90de1b832e26c98adbafc6238b98882f
Lockscreen: Fix mdpi layout issues

Before: http://i.imgur.com/gXNUt97.png
After: http://i.imgur.com/ppevA6M.png

Signed-off-by: Michael Bestas <mikeioannina@gmail.com>

Change-Id: I5bc893f12096d288d04d7cfa442b471002178a3a
Prevent Sym key from showing the IME picker
am: Allow more hidden apps on devices with lots of RAM

 * If more than 1.5GB is present, allow up to 40 hidden apps.
 * Number is somewhat arbitrary, but was found to work well on D2.
 * Also look at the sys.mem.max_hidden_apps value if given.

Change-Id: I2d3cf6e0dad1bc0b482cc37bf9c61ed2f2b4be51
Fix Watchdog HeartbeatHandler to run on correct thread

The HeartbeatHandler for the System Server Watchdog has been running
on the wrong thread due to a race condition in initialization.  It's
designed to run on ServerThread, so that it can catch lockups in the
main looper of the System Server.  It has been running on
ActivityManagerThread instead, so it does not detect lockups on the
ServerThread as it should.

ActivityManagerService is calling Watchdog.getInstance() before
ServerThread calls Watchdog.getInstance().init(), so the handler is
being bound to the ActivityManagerThread instead of the ServerThread.

Explicitly bind HeartbeatHandler to ServerThread, so that the Watchdog
catches lockups on this critical thread.

Change-Id: Iccb184ac3adb817feb86ed4ee0e50e443bf74636
Remove the fixed-length buffer in DdmHandleNativeHeap.getLeakInfo.

It was possible to overrun this buffer, and even if you did fill
the buffer in a single read and exit the loop, the "string" still
wouldn't be terminated.

Bug: 8468088
Change-Id: Ia19f4d26dfd79e7b63807a7ec9540b932163d246
Two REMOVE_PROVIDER messages caused by race condition.

Fix a bug in unstable ContentProvider.
IllegalStateException: ref counts can't go to zero here: stable=0 unstable=0
IllegalStateException: unstable count < 0: -1

There is a race between main thread and background database thread. Main thread
is responsible for handling the REMOVE_PROVIDER message. Database thread starts
insert or query request again and again. acquireProvider in db thread will often
snatch provider from the jaws of death, sometime it fails to remove REMOVE_PROVIDER
which is already fired out from MessageQueue. But completeRemoveProvider in main
thread gets suspended when trying to execute the critical section. If db thread
released the provider before main thread resumes the execution, then two
REMOVE_PROVIDER messages will be executed.

Change-Id: I8588aa1d1a8bc444dcd2adf6f8bc3f055cebbdc4
Signed-off-by: Guobin Zhang <guobin.zhang@intel.com>
Clarify the documentation of SparseArray.indexOfValue.

Bug: https://code.google.com/p/android/issues/detail?id=53297
Change-Id: I28725a2d03d4c11948bfe4fb90d730c86bf41481
Added support for multiple navigation key bars

System UI was build with the assumption that there is only one
navigation bar at a time, and that this bar is managed by
Phone UI, Tablet UI or TV UI.

This commit adds simple call back facilities at BaseStatusBar
for both, navigation key hints and menu key visibility change
events. These call backs are wired up in Phone UI, Tablet UI
and the TV UI stub.

This allows us to have more than on navigation key bar
in the UI and define those navigation bars directly
in BaseStatusBar, where it is available for all UIs.

Patch Set 2:
* CyanogenMod Code Style
* Added documentation.
* One interface for all
* Added setDisabledFlags() to the list

Change-Id: Id4de440e21c2f5c78b5e185030f9c5e0f7e6bef7
Bringing basic pie controls to CyanogenMod. (1/2)

Based on the multiple navigation key bar patch, this commit adds
basic pie controls to CyanogenMod. The implementation is inspired
by Paranoid Android but is completely rewritten.
The aim was to get as little intersection with existing code as
possible and provide a farily easy interface to extent these
controls by new slices (inherited from PieSlice).

The pie controls are only active when expanded screen is turned on.

Based on this commit there is another one that adds more optimizations
for Phone UI to pie controls. And there is a seperate commit for
the settings app, too.

Patch Set 2:
* Cyanogen Code Style.
* Some simplifications in PieSysInfo.java

Patch Set 3:
* Fixed NPE when pie controls are completely deactivated
* Preserve state of menu button

Patch Set 4:
* Fix display of Wifi SSID
* Some cleanup and coding style changes

Patch Set 5:
* Fix NPE when not connected to Wifi
* Remove AM/PM from time display (overlayed the other info)
* Fix menu button handling

Patch Set 6:
* Remove trailing whitespace in 12 hour time format

Patch Set 7:
* Tune colors
* Improve battery level and operator printout
* Remove some unused imports

Patch Set 8:
* Some refactoring on pie trigger management
* Copyright fix
* Make debug on PieLayout less noisy

Patch Set 9:
* Fix NPE one devices with no GSM/CDMA/LTE
* New color proposal
* Haptic feedback now respects system setting

Patch Set 10:
* Factor out haptic feedback into separate method

Patch Set 11:
* Prepare for "always on"
* David's color scheme

Change-Id: I90de7252d8301282d396c29bc9e9943acf7f2766

Conflicts:

	core/java/android/provider/Settings.java
	packages/SystemUI/res/values/dimens.xml
Add pie control optimizations for Phone UI.

This commit brings some pie control tweaks to the Phone UI. These
tweaks make the pie controls react to several conditions that are
are special to the Phone UI. That means that this piece of code
is more deeply embedded within the SystemUI code.

This mostly adds the foloowing behaviour, that is Phone UI
dependent:
* Disable BOTTOM trigger when notification area is expanded
* Disable LEFT and RIGHT trigger when a keyguard is active
* Enable search light feature

Patch Set 3:
* CyanogenMod Code Style.
* setDisabledFlags now belongs to navigation bar callbacks

Patch Set 5:
* Removed duplicated .observe()

Patch Set 10:
* Fixed unintended trigger activation

Patch Set 13:
* Searchlight opens directly on the bottom (on the lock screen)

Patch Set 15:
* Fix conflict/rebase

Change-Id: I551745b69791adca75190c54282be19d85db75a9
Navring: Fix shortcut for uninstalled app

Fix NPE when the user uninstalls an app that was assigned to a navring
shortcut before.

Change-Id: I3f02fca73cb30e2edbb35d089ad127b35d8233c0
FlingTracker can divide by zero and hang StatusBar in an infinite loop

if 2 events have the same timestamp then FlingTracker in PanelView will divide
by zero causing NaNs. the bug is usually triggered by rapid StatusBar up/down
dragging activity and updateCarrierLabelVisibility can then loop indefinitely
looking at NaNs. the user visible symptom is that StatusBar refuses to pull
down and is burning cpu time.

Signed-off-by: Michael Bestas <mikeioannina@gmail.com>

Change-Id: I0791c6bea953bf03346185fc6aaf44aaea79aace
IME : Fix sym key regression

http://review.cyanogenmod.org/#/c/25787/2 caused the "dismiss" arrow
for ime's to execute back action as well. Reproducible via :

Open sms app->Open message thread->Tap message field->Tap downward arrow on navbar

Expected behaviour : Keyboard should be dismissed
Actual behaviour : Keyboard is dismissed and user is taken to previous screen.

Change-Id: I6ab65b00464fb6e00849d7fd6c8bd438b23ee76b
Power Menu: Update the Expanded Desktop drawable

Also add a proper "off" state.

Patch Set 2-4: Add to symbols.xml
Patch Set 5: Remove the useless extra sw600dp-xhdpi drawable

Change-Id: I111982a4985bba19353dd4f3872e5b21e73dd5f9