base: update link ring-notifications after read user settings

Change-Id: Ib424124dc20e38243e572333e323ba97aacb1111
JIRA: CYAN-3559
Issue: https://jira.cyanogenmod.org/browse/CYAN-3559
Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
msim: Add missing changes from New Theme Engine [1/6]

Change-Id: I52051a8cefd0d4632d2a2255a03689cc037e6995
SystemUI: Restore bounds when loading new gradient

This fixes an issue introduced with the reloading of the nav bar
transitions after a theme change in Change-Id: I256afc30fc018ea752769029c5246bc7310c23a6

Change-Id: I648039506b826583d554b2a0cf4f6ab9a9bb1de8
Add global setting for all stats control

Change-Id: Iaf244d9fafbf2c47c318a90665f39d5efaea3b1b

Conflicts:
	core/java/android/provider/Settings.java
Themes: Find wp asset when APK has dir entries

Some APKs are compiled with folders included as zip entries in the APK. This was causing
lockscreen wp to not correctly be set.

Change-Id: I9eca7878b29e3cfcb43abc4a9dab084d9c200b83
[AssetAtlas]: Fix AssetAtlas not consider all size of texture.

Symptom: Atlas service get exception because the result is null.
Root Cause: The original logic will miss the largest width in each thread.
Take two processors as an example, first thread will miss 2048, second thread will miss 1984.
With some condition, only 2048*2048 or 1984*2048 can exceed the mThreshold.
In this case, the mResults is empty and cause crash when trying to use the first result.
Solution: Adjust the boundary and the condition so that it can consider all size of texture.

Change-Id: Id54de57cd1501ed7355f2237f05726d2965aed6d
[HWUI]: fix residual line on FrameBuffer

Symptom: If app applies animation to enlarge a bitmap, there will be an residual
         line on the screen

Root Cause: On platform which has Tile Rendering implementation (ex. Qualcomm
            CPU), startTiling() call will restrict the framebuffer region which
            GPU can affect. So the expansion of clear region by 1 will not take
            effect if startTiling region is not expanded.

Solution: Expand the startTiling region by 1, too.

Reproduce steps: Apply animation to enlarge (and then shrink) a bitmap icon.

Change-Id: I7b4a59e180daa29dbe909d9e11f4093ae1d7396f
Add BlendComposite.java

The class is adapted from a demo tool for Blending Modes written by
Romain Guy (romainguy@android.com). The tool is available at
http://www.curious-creature.org/2006/09/20/new-blendings-modes-for-java2d/

Change-Id: I8f7c7ca08d3078106056764a4e2f1ce95d990137
Optimize Blend composites.

Removed redundant array allocations to improve performance for various
blending modes.

Change-Id: Iaba1d6ff3ad03eebdc859c599b610cc593370438
Add an internal API to get all asset locales.

This will allow us to not copy paste this code verbatim into
bundled apps.

bug: 10090157
Change-Id: I008dc683ecbef2ad8b7a26968cb3cbda7e5a8388
[ActivityManager] Move top task to top in window manager

Symptom:
In certain situations, application starts activity while
it is in background. When an existing background activity
starts a new activity which results to be kept in the same
background task, the new activity won't be resumed.
In that case, the background task (sourceTask) should not be
moved to top in window manager.

Solution:
Move top task of the target stack to top in window manager

Change-Id: Id7a37ea67ce1f80e0c2b5399865c51fd7113deb8
[ActivityManager] Do not finish root activity when reset task

Symptom:
The root activity not always located at index 0 of the task.
For example, the index 1 activity will become the new root
when the original root activity (at index 0) finished.
The new root activity might be finished unexpectedly before
the original root activity actually destroyed.

Solution:
Check frontOfTask to avoid finishing the root activity unexpectedly

Change-Id: I623ab97e9c95c83b3cfe7c9dfc151a291a391ea4
[ActivityManager]: Update home process when home activity resumed

Symptom:
  When switch between two home activities, the home process might not be updated to the correct one. In that case, the home activity might be killed easily.

Root Cause:
  The home process is updated only when a home activity is newly created or being restarted. ActivityManager did not update the home process when simply resume a home activity.

Solution:
  Update home process when home activity resumed

Reproduce Steps:
  1. Install a launcher application, such as Apex Launcher
  2. Press home key to change to Apex Launcher by "Just once" option
  3. Press home key to switch back to original home activity by "Just once" option.
     (The home process is still the Apex Launcher's process because ActivityManager does not update the home process when resuming the original home activity.)

Change-Id: I046279ca7ba851a283ee67ea19202890f7b3f343
Catch all exceptions when retrieving ComposedIconInfo

It is possible to receive a TransactionTooLargeException when
getting the composed icon info from the package manager service.
We should catch these exceptions to avoid unnecessary crashes.

For reference:
The Binder transaction buffer has a limited fixed size, currently 1Mb,
which is shared by all transactions in progress for the process.
Consequently this exception can be thrown when there are many transactions
in progress even when most of the individual transactions are of moderate size.

see http://developer.android.com/reference/android/os/TransactionTooLargeException.html
for more details.

Change-Id: I70d35dc4926125bfbef5d8c5fb8ed6d6fcdbf159
Add SET_WALLPAPER permission to SystemUI

If an exception is thrown in updateWallpaperLocked, a call to
WallpaperManager.clear() is made.  This requires the SET_WALLPAPER
permission and will throw a SecurityException if that permission
is not granted to SystemUI.

Change-Id: I61811b65dcfe8b15f0e9030f7aa6d1dc09cea351
AudioManager: Add Bluetooth A2DP profile trigger

    - Introduce a new profile trigger for Bluetooth A2DP
      connections.  We can't use the default ACTION_ACL_CONNECTED
      because it would apply the volume settings before routing
      has been established to the A2DP device.
    - Modify AudioService to send an intent after the audio
      route has changed to A2DP to ensure our volume change
      will apply to the correct device.
    - Allows the user to disable the A2DP profile and still
      trigger the profile change.

Fixes JIRA issue: BACON-47

Change-Id: Ib51dac6d79abbaf494b86af4480e293162814459
QS: Make CameraTile respect locale changes for the label.

Change-Id: Id4be230c443263b4185e5b4af6e8df6805a7aac5
QS: Make PerformanceProfile Tile respect locale change for label.

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

Conflicts:
	packages/SystemUI/AndroidManifest.xml

Change-Id: Ib693123d7a0ac19d7e1f3d2567a457de40b53fdc