Avoid adding FORWARD_LOCK flag to an updated system app

Consider the following case:
1. An app exists in /system/app or /vendor/app. (i.e, it's a system app)
2. If the app would be updated as a forward-lock app by downloading from
   market(google play), then it would be installed in /data/app-private.
3. Moreover, if it would be updated by the whole system image (i.e, FOTA
   or something like that), then the app would be applied a FORWARD_LOCK
   flag.

The app SHOULD NOT have a FORWARD_LCOK flag. Because the resource path
of such app does not refer to the proper resources to access.

Change-Id: I0750f69a93a3115f4201029796b598507de3555f
Subclassing AudioTrack considered harmful

This class was not really designed for subclassing to be meaningful,
and some uses could be downright dangerous, for example setState().

Change-Id: I36029e94546c53a47926918e7f667d9e83bd02fe
merge in master-release history after reset to master
fix NPE in updateClientUids

Bug: 8009908
Change-Id: I54d97c587a3fa9d003f654f98fdfdbe21af791d6
merge in master-release history after reset to master
Fixing missing internal link in document.

Change-Id: I80b8712815ac05acfa753cbb40875b869d2e942d
Set foreground priority for shutdown receivers.

The broadcast of ACTION_SHUTDOWN has a timeout of 10 seconds. To
reduce the risk of hitting the timeout and speeding up the
shutdown sequence in ShutdownThread we set the priority of the
BroadcastReceivers to FLAG_RECEIVER_FOREGROUND.

We have seen that this change reduces the shutdown time when
the system is under heavy load.

Change-Id: I22cbf6af8cf6fc4bdefaa1c3da8a7eed7e7b7674
Fix typo in AlertController.java

If whichButtons is BIT_BUTTON_NEGATIVE, the negative button should be centered.

Change-Id: Ia34daf8c80704204a4f1cf71c642114005559d5d
Signed-off-by: Sangkyu Lee <sk82.lee@lge.com>
Add default handlers for brightness keys

Change-Id: Ic57ba8cb159f08e0cde32350cb2d5eb34f68f830
Prevent repeated cursor movements from escaping a TextView

Bug: 4156002
Change-Id: If66a69c404509c75016039156389b6a7b2852154
Added the KeySetManager.

Bug: 7554291
Change-Id: Ic693a544f1e2cab20f6540b3fc4ff673e35bd2c6
Fix sample code error in battery documentation.

The code in the battery documentation uses inconsistent naming for one
of the variables: the intent is first called "batteryStatus" but then
used a just "battery," which causes the sample code to not actually work
if cut-and-pasted into a real project.

Change-Id: I3d8a06ba7e8448061ae162f786fe5c8770f65085
merge in master-release history after reset to master
merge in master-release history after reset to master
Small documentation fix for AudioManager.java

Correct typo + copy-paste description issue.

Change-Id: Idce7cfeb7255d96aef91efc40d19f077dde3e9a5
Refactor resetTaskIfNeededLocked for tasks.

Change-Id: I1ad8b7ffe1f17490ebcb98ea48d57f0b15f888c9
Conversion from mHistory to mTaskHistory.

Change-Id: I7c43a923ce248edb4ca7d5fc6d1e0c492522f5a0
Add a comment for secondary user handling in IMMS

This is a follow up change for I438daf996ba48cdb34f0a6

Bug: 8205725

Change-Id: Iae87580b7d56ed8badf548ac1830ddb12a051148
merge in master-release history after reset to master
Import translations. DO NOT MERGE

Change-Id: Icdfc932c8898e3c716e012d384afa2521d3ac11c
Auto-generated-cl: translation import