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

Conflicts:

	core/jni/android/graphics/TextLayoutCache.cpp
	core/jni/android/graphics/TextLayoutCache.h
	core/jni/android_os_FileUtils.cpp
	core/jni/android_server_BluetoothEventLoop.cpp
	core/jni/android_view_Surface.cpp

Signed-off-by: Stevespear426 <stephen.k.spear@gmail.com>
Change-Id: If0a59e0bd6a89025dd7e0a0efaaf8d55a952ef34
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>

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

Change-Id: I185b97f07e89bed93b92546bc0fdf895bd0cc92d

Conflicts:
	core/jni/android_emoji_EmojiFactory.cpp
frameworks/base: Fix compile errors

Fix ISO C++11 incompatibility in TextLayoutCache and
aliasing violation in FontRenderer

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

Conflicts:
	core/jni/android/graphics/TextLayoutCache.cpp
base: Fix build after Parcel ABI fix in Binder

Adapt code to the fact that writeString16's first parameter
is now an uint16_t* to match the old ABI

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