libaudioeffect_jni: GREF leak fix for JB

- Excessive JNI global reference in AudioEffects.
- Global references created during native setup
  are not deleted.
- Global references are deleted in setup failure
  and during native release.

Change-Id: I302b7f8de7189f85fd07167b950f85795ffc5ef1
CRs-fixed: 413633
Bypass emulated storage for metadata extraction

b/6543148

Change-Id: Ic65957870199a2592ebe53b32517166f96e48ef2
Fix aliasing and C++11 issues.

frameworks/base: Fix various aliasing violations

Signed-off-by: Bernhard Rosenkraenzer <Bernhard.Rosenkranzer@linaro.org>

frameworks/base: Fix aliasing violations

Fix violations of strict aliasing rules

Change-Id: Ia83db6a0be18f52e8f274c581c3b42f031b39247
Signed-off-by: Bernhard Rosenkraenzer <Bernhard.Rosenkranzer@linaro.org>

frameworks/base: Fix build in ISO C++11 mode

Fix various incompatibilities with ISO C++11:
- Assumption that char16_t is defined to uint16_t
- constexpr usage
- macro constructs that could be interpreted as string literals
- enum typesafety

Signed-off-by: Bernhard Rosenkraenzer <Bernhard.Rosenkranzer@linaro.org>
Signed-off-by: Evan McClain <aeroevan@gmail.com>

Conflicts:
	cmds/stagefright/SineSource.h
	core/jni/android/graphics/TextLayoutCache.cpp
	core/jni/android_util_Binder.cpp
	core/jni/android_view_KeyCharacterMap.cpp
	libs/gui/SurfaceTexture.cpp
	media/libstagefright/OMXCodec.cpp
	services/audioflinger/AudioResampler.h
	core/jni/android_server_BluetoothEventLoop.cpp

Change-Id: I185b97f07e89bed93b92546bc0fdf895bd0cc92d
Revert "statusbar transparency"

This reverts commit 11ac14f60ffdfb533f8e4279ecea0236d6933f83.

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
Custom notification drawer Wallpaper and alpha

- gives the ability to choose alpha and background of notification drawer
- also code cleanup
- thanks a bunch to tarak which optimzed a lot
- and special thanks to Josh....he knows what he did lmao

cheers

Change-Id: I995a3763c7074a51a2351274773bc530c21a5001

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationWallpaper.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
Statusbar reWork based on work by kufikugl of the SB team
Provide haptic feedback on long pressing keys in lockscreen.

Change-Id: I01c759c0944939aded669ac474cea646e1f51408

Conflicts:
	policy/src/com/android/internal/policy/impl/LockScreen.java
Custom notification drawer Wallpaper and alpha

- gives the ability to choose alpha and background of notification drawer
- also code cleanup
- thanks a bunch to tarak which optimzed a lot
- and special thanks to Josh....he knows what he did lmao

cheers

Change-Id: I995a3763c7074a51a2351274773bc530c21a5001

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
Framework: Whitespace cleanup

Change-Id: I3dc933297c9e95c42d22de35d972dea850ae1ed7

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
Framework: Fix Profiles Insecure lock screen not working

This fixes Issue 6226: The insecure lockscreen setting is not being activated with
the use of profiles if the default is secure (PIN or Password)

Change-Id: I2fdb8b8eedd136abfeeb30d2f7397d4eec871cc9
Mms auto-retrieval (1/2): framework

- Settings: Add auto-retrieval and auto-retrieval-on-roaming strings
- GsmDataConnectionTracker: Gets settings and auto-connects APN_TYPE_MMS

Patch set 2   : Fix NPE when the preference was not yet set to a defaulted
                value
              : Add @hide's
              : Set proper defaults

Change-Id: I9c4ea47cd39cd017fba3d5b0649d0e84aaf78b4e
New Lockscreens BlackBerry and Optimus 4x 1/2

Multidpi lockscreens based on evilistos idea

- add ability to use BlackBerry styled lockscreen
- add ability to use Optimus 4x styled lockscreen
- ass settings shows on choosen lockscreen customized Lockscreensettings
- add ability to set transparent lockscreen
- code cleanup
- and a lot other small stuff

Change-Id: Ib14828f72da51e9915d6b90f5fccd318ed3a0adc
Changes optimus 4x clock....

style to bold

cheers

Change-Id: I67fe2c39b09ad03c031f822df59723b17b81350b
Gives ability to set security.....

lockscreen settings to ass

and fix for non sticking aligment/color on different
lockscreens then stock

Change-Id: I4f297b5aa3d2704bd76d081732db7cb7c143e337
Add notification rows transparency (frameworks/base part)

Change-Id: I50ec743ea8084ae4c590fcca8f66835d22aff794

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
Set notification row transparency for recent notifications

Change-Id: If297176d4aa9b19a861175e754d8bf829717e2b2
Fixes and feature notification drawer 1/2 Frameworksbase

- fix custom background image landscape (scales now)
- fix stock background...now not transparent any more on 0%
- moved whole style options in style category @settings
- add support for custom landscape background
- add support for background color fill
- reset of background image not any longer over menu
- changed code to easy port it to 4.2
- code clean up

PatchSet 2

- clean up all files from tabs etc

Change-Id: I3d2f1b7edcc5022b134a7ad2eded2058ba0562cc

Conflicts:
	core/java/android/provider/Settings.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
[Frameworkbase] Fix different standard value

on fresh install for status bar transparency

PatchSet2

- clean up tabs

Change-Id: I7c606921079301dac63809e7ccf6062602b5d294

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
DevicePolicy: Fix lockNow() failing to turn off screen

Pawit Pornkitprasan's patch from ICS.  This issue affects JB as it did ICS.
Original patch: http://review.cyanogenmod.com/#/c/14845/

---
A fix introduced in 93c518e4f8abd98f87cda1712b30a5a86cfa60dd
causes lockNow() to sometimes (most of the time) fail to turn
off the screen. The screen will turn off, but then immediately turn
on showing the lock screen.

This is caused by getWindowManager().lockNow() call which calls the
method to lock the screen, which the PowerManager service also
call in parallel, leading to a race condition.

The fix is to only call getWindowManager().lockNow() if the screen
is not on.

Change-Id: Ic90d41bd9f52e3ad0924d3a096162e5083c4d4c7
Lockscreen fixes and features Part 1/2 frameworkbase

- change to using integrated instances now
- several fixes for music transport controlls
- BB tablet support
- better peformance optimus lockscreen on hdpi devices
- lockscreen background transparency moved to background customization and works on the fly now
- lockscreen background 0-100% alpha can be activated on colorfill and custom background
- clock moved in settings to widget behaviour. Style could be customized now + hidden feature
- if clock is hidden status1 and owner info will be centered automatically
- owner info can be shown on lockscreen
- optimus and BB lockscreen can now be colored and alpha as you like
- optimus background settings deleted cause of stock background customization ability
- ability to choose one of the custom lockscreen before secure lockscreens
- vibration support for optimus and BB
- whole lockscreen settings are working dynamically now and show just what is possible to customize
- code clean up
- png clean up
- a lot small stuff

PatchSet 2 + 3

- cleanup whitespace errors

PatchSet 4

- commit message update

PatchSet 5

- small clean up + set dateview, alarmstatus and ownerinfo also to new font if activated

PatchSet 6

- fix softreboot on background selector

PatchSet 7

- fix merge conflicts

Change-Id: I5cd33bbe5edf1737687e540bebcb2e1de4f2e587

Conflicts:

	core/res/res/layout/keyguard_screen_info_circles.xml

Conflicts:
	core/res/res/layout/keyguard_screen_password_portrait.xml
	core/res/res/layout/keyguard_screen_unlock_portrait.xml