Fix for ambiguous and broken disk formatting dialog

This patch ensures that the path-string from StorageNotification is converted
to the appropriate StorageVolume so that it can be correctly passed to the
formatting class. It also displays this path to the user so that it is clear
what will be deleted.

While trying to use a USB flash drive over OTG, the drive's FS somehow got
corrupted, so Android gave me a notification to re-format it. Okay, so then
a dialog pops up that doesn't specify what volume/device it will format, and
I incorrectly assumed it would be the USb drive. However this activity defaults
to the main internal memory for some reason, and wiped my data. Thank God for
them internets... (Dropbox)

Change-Id: I5621dff3cfd12a173b0d793398cf729333f97263
Little sweet suprise for everyone...
Alternate default app picker (1/2)
Android 4.4 brings ListView and no more GridView and with this some small changes was made to fit new style

- 99,9% based on @kufikugel 4.3 idea. Thanks!

Change-Id: Iabcecf140e4859c7cdff5ad50ec930007f4bc653

Conflicts:
	core/java/android/provider/Settings.java
ThemeUtils: Retain the original package name in themed UI context

In order for themes to reflect on system elements, we're changing
their context, including the package name.

This breaks anything that tries to identify system elements,
most notably any users of the uiautomator. Trying to do
'UiSelector().packageName("android")' to find, for example,
a force-close dialog will fail.

Fixes com.android.cts.uiautomatortest.CtsUiAutomatorTest#testUiWatcher

Change-Id: Ic05c3024b20ac3772ed5597846fbfa4a184ebb0d
Fix DataInputStream leaks

Fix fixes
-In viewstateserializer, try to close before throwing or returning, and throw early if inputstream is null
-other stuff

Change-Id: I7f3b16057582566b82a85841829ff6ed11cd570e

Conflicts:
	core/java/android/webkit/ViewStateSerializer.java
Grant qcom_oncrpc group to system_server

 * Needed for RPC-based QC GPS

Change-Id: Idebc5f6f8e7f8c136d931d7638338d3611895d8a

Conflicts:
	core/java/com/android/internal/os/ZygoteInit.java
gps: added 1021 gid for gpsone_daemon

Gives system_server gps gid to allow for
communication to gpsone_daemon

Change-Id: I59d7e99ec996891b19fa15a3ed66e055e6bccad8
(cherry picked from commit 059dd10116b75d60bc8bc5ee52030e28fcf740a5)
(cherry picked from commit 3dfcb80ede3707eb8dbe7c607b22393b66829ea1)
(cherry picked from commit ea7473eab71834c46e8f61d95bf269abb755f95d)
fb: remove WifiDisplayTile

due that google removed WifiDisplay completly on 4.4.1
and replaced it with a new screen cast method we remove it
for now till we program a new tile for screen cast

Change-Id: I7a78bc92114a62ca54bd30cbb1b55ad6c94a6953
DeviceUtils: filter out vibrator options for shorcutfeatures

if device does not support it

Change-Id: I738a1ddbbd05a3a1e4e519429e08b4a3344182fb
Frameworks: Lockscreen Colors and Lock Image [1/2]

PS2: Separate all color elements
	into separate prefs.
	Also colorize bouncer frame
	for secure lockscreens.
PS3: Whitespace

PS?: Add Lock Icon Picker =]
PS?: Add "Colorize Custom Icon" option.

Change-Id: I542dfa01bb1d3d0e401bbf8a5f58b32f08cbfc62
fb: fix and pimp custom lockscreen handle (1/2)

problem on current implementation is that it is not
multiDpi compatible. As well it looks a bit weird if
the user set a square image always. This commit does

- introduce central circleimage method to get circle image crops
- before it was assumed that the height of the handle image is
  108px (mdpi base) which is correct but the original handle
  has a lot unused space around to fit better into the view.
  Whatever after messurment of the real height 68px is correct
  of course calculated against the current density
- both above combined results into a always nice looking
  custom circle icon on the lockscreen dpi and device undependent
- saved file in settings calculates the needed image size
  base on the current density.

Patchset:
- use for custom bitmap our colorize methods due that
  the result looks way nicer then the usual colorfilter

Patchset:
- use AntiAlias

Change-Id: Id0321e0e9176f8f765980f69b412658dbb929ef3

Conflicts:
	core/java/com/android/internal/util/liquid/ImageHelper.java
QS: make dynamic tiles configurable (1/2)

instead of using a bunch of provider settings var
like it was on 4.3 and almost all other roms are doing
use one and split like we do for the normal tiles. This
is more consistent and saves us to observe a bunch of values
As well this is integrated into the one layout screen we have. So
all QS related is easy and logical usable for the user on one
screen

Change-Id: Ic1b8d021f4bf418257df268262b7eff9474d4819

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/phone/QuickSettingsController.java
Frameworks: cleanup unused imports and whitespace
wifi: Set the mode at native layer

 * Set normal/AP mode so that the HAL can specify correct module
   arguments when loading the driver.

Change-Id: I6eee2cc53b5f1e70306e252e52c909833f220515

Conflicts:
	core/jni/android_net_wifi_Wifi.cpp
	wifi/java/android/net/wifi/WifiNative.java
	wifi/java/android/net/wifi/WifiStateMachine.java
frameworks/base: media: add support for DIVX files

Change-Id: I6e922c5d6e17ee590606268af97b7894f35d19ae
(cherry picked from commit 47fea00316203aebba194644f95ca58ef4ff4400)
(cherry picked from commit 1f3ab64cf5bb19ec2e8a996750f44389d4d07187)
(cherry picked from commit 066dff510ec44ee06c3a375e32133e21fbedf9fb)
audio: add support for MSM audio formats

- Add support for EVRC, QCELP, and WMA formats
- Add definition for 5.1 channel recording
- Reference change If3676b88fa287b484ef8616c0a6b67177b61a720

Change-Id: I6b6e5ca98921adeadd2a3d76580fe85fb28eeaf0
(cherry picked from commit 10c4f204bb5ac78b9cf3854b536663ccd3d50333)
(cherry picked from commit 3f99cc5f134b0f00a52218ae1c0273cc11ae7702)
(cherry picked from commit 1d35b52c7c9cf1cfd3a3de372391a7a57f593af9)
audio: audio enhancements for playback and recording.

- Add playback and record support for EVRC, QCELP,
  WMA, AMRWBPLUS, WAV, ACE, and EC3.
- Add support for 5.1 channel recording.
- Add support for in call music.
- Add constants for call_state and vsid.
- Add definition for FM and proxy audio devices.
- Remove unnecessary format checks in frameworks.

Change-Id: If3676b88fa287b484ef8616c0a6b67177b61a720
(cherry picked from commit 6ca6cc15af88992ea485a458e67a8546b156672e)
(cherry picked from commit f65028d1752969bf43c853c1bb12ecd12055d5e8)
(cherry picked from commit b1952442db41188b74f331bd2397a579424821ab)

Conflicts:
	media/java/android/media/AudioService.java
  audio: Support for MSM audio formats

  -Add audio format support for Voip.

Change-Id: Ie045ba926b3e1266afd3fb6fba09af3a55daaeef
(cherry picked from commit d1810964ecd2d50064a1fed51049ddc354b9a788)
(cherry picked from commit cd9c6dc56bedcabca77c2a01c6fb15f4d2e8edd5)
(cherry picked from commit 01c09aeae38716860ef1a806985cc946dca93f60)
audio: Add ifdefs for QCOM_HARDWARE audio features

Change-Id: I0ea423f9a28934dc1fee73bbb53c0d9d867877ff
Add support for QC's time_daemon

Enabled by BOARD_USES_QC_TIME_SERVICES=true, it requires the device
to provide its own time_daemon executable and libtime_genoff.so
proprietaries. The library should be copied by the device's setup
config to $OUT/obj/lib for linkage (and pushed to the final build,
obviously)

Change-Id: Ie6964dbe2692dc33fc04093a5b89b6922d8443c8