Frameworks: add a bunch of national roaming providers

Change-Id: I506bb2d50f8c0493e9f33ed45984627e60132399
Insufficient ProcessRecord cleanup when persistent process is killed

When persistent process with Service restarts, ActivityManagerService
does not reset ProcessRecord#hasClientActivites to false
(because ProcessRecord of persistent process is continued using
after killing).

It disturbs updating LRU list in ActivityManagerService, and then,
when new process calls ActivityManagerProxy#publishContentProviders,
SecurityException happens because of no entry in the list.

Bug: 13517358

Change-Id: I46b064f71a4f7025ade1bf117801352a7ab22e6a
Volumes in Settings/Sound is slow to start

There is a delay after pressing volume menu item
there is a delay until the Volume popup is shown.

The reason for this is that the initialization of
the different seekbars is slow and run in the main
thread. More specifically the call to get the
ringtone from the RingtoneManager is causing this
delay.

Moving the call to the ringtone manager to the
handler thread used to play ringtones to make
the launch of the volume dialog a bit snappier.

Change-Id: I76da0226592468debd542d67164b37b2b59897c7
Base: Check ProcessesReady before broadcast

Most of the time testIsSystemReady is used to know if we are allowed to broadcast intents.
But in broadcast intent method we check mProcessesReady flag (not mSystemReady).
If we broadcast after systemReady flag but before ProcessesReady flag, system will crash

Adding condition to check if system & processes are ready fix that race condition
Signed-off-by: Fabien DUVOUX <fabien.duvoux@gmail.com>

Change-Id: I2eec1c4f280daf29f4741919a7636b02da341e32
AudioService: Fix absolute volume for AVRCP

Avrcp.java uses max volume obtained by getStreamMaxVolume() when
converting to AVRCP levels and it returns non-scaled volume index.
For this reason volume index needs to be dispatched to Avrcp before
scaling as otherwise Avrcp will convert volume level incorrectly,
i.e. max volume index for music stream is 15 and any volume index
>1 (>10 after scaling) will result in setting *MAXIMUM* volume level
on headset which is not safe for listener.

Change-Id: Ia799eec578ed2326ec18b69f2ee4f2a60c664514
Audio: Fixed system/call stream volume can't adjust with HS connected.

Issue Description:
When headset connected, the system/voice call stream volume can't be
adjusted from Volume bar.

Root Cause:
Currently adjustStreamVolume is applied to stream type alias and the
device for the stream alias. So when headset connected and adjust
volume for SYSTEM_STREAM, the operation will be applied to RING_STREAM
(which is aliased by SYSTEM_STREAM) and speaker. As headset is returned
from getDeviceForStream(SYSTEM_STREAM), but speaker for RING_STREAM.

Solution:
Change the adjustStreamVolume to apply volume to the stream alias and
the device for the stream type exactly.

Change-Id: Icd226d9eb197017cd3c186a0096edaed755680ec
Signed-off-by: Guo Xie <gxie@marvell.com>
base: Fix screen on stats after a boot

Prior to this change, the following sequence:

  * Turn the display off
  * Issue a reboot via adb
  * Unlock the device (after rebooting) before the screen turns off

results in the screen being on but the battery stats not reflecting
this fact.

In general, the mismatch occurs when either there is no serialized
battery stats state or when it is serialized in a state where the
screen is off.

Change-Id: I17374553fae6a08a1be8fdf445967509474177a9
bless python versions newer than 2.6

Change-Id: Ic4bfb857586f1fd4aa9cfddf5984341a89b0cd4a
Signed-off-by: Li Li <lli5@nvidia.com>
Reviewed-on: http://git-master/r/347711
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Peter Zu <pzu@nvidia.com>
Fix keyboard layout notification missing issue

The device changed event was sent before input manager service
gets ready during boot-up, input manager handler has no chance
to deliver notification due to mNotificationManager=null

Change-Id: I5096b86b7b5879cd346b22411064f15d62bf73bb
Add null pointer check for ExifParser

Change-Id: I9a7eee8ebb571a186a57e5094e376e7a7d8ab4b8
ImagerReader: Return the buffer to queue if it fails to lock

Return the buffer to the queue when failing to lock it with the
error ACQUIRE_NO_BUFFERS, which acquireNextImage of
ImageReader will return null. Otherwise, there is no chance to return
the buffer back later since the caller can't get the new SurfaceImage
object.

Change-Id: I774e91d52f3e10c8d2dd88d835505da79086c5b2
TouchExplorer: print error message instead of cause fatal exception

In stead of throwing exception to cause system server dead, printing
out error message will be more reasonable.

Change-Id: I6e9cfdbfaaed6c03972c223c46ed78bfb0e00069
frameworks/base: Fix aliasing violations

Fix violations of strict aliasing rules

Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
Work around uint16_t vs. char16_t confusion

Change-Id: I188e5a82b2dba821710eaea85d6cbef2ae004ce9
Signed-off-by: Bernhard Rosenkränzer <Bernhard.Rosenkranzer@linaro.org>
framework-res: Remove gingerbread scrolls
Fix Aapt so that duplicate package ID errors are not incorrectly reported.

Aapt falsely reports package ID conflicts unless base packages are included
in strictly ascending order based on their package IDs. This fix addresses
that issue while still detecting and reporting conflicts correctly when they
actually exist.

Change-Id: Ic8059b87f919641d086df88d1556f5fa0063739f
Change 640 integer to DisplayMetrics.DENSITY_XXXHIGH in
getLauncherLargeIconDensity method.

Now DENSITY_XXXHIGH constant value is in DisplayMetrics.
DisplayMetrics.DENSITY_XXXHIGH is more clear than
DisplayMetrics.DENSITY_XHIGH x 2

Change-Id: Iebdc7634171d4caca7f57ed101205e80525e26ea
Fix ellipsizing of emoji symbols in StatisLayout.

Change-Id: Ia057053a7dd6e5a256499f6bded99872581de18e
Correct typo in doc comment

Changed "will" to "with"
(will null Options -> with null Options)

Change-Id: I3bbfb953d8e783ca6335247463007cbee722a28e
Signed-off-by: Shuhrat Dehkanov <k@efir.uz>