FIX Null Pointer Exception on dialog cancel

Null Pointer Exception occurs because mWebViewCore instance
is made to null while calling destroyJava(). When
1.webview hosting activity goest to background, without calling webview onPause().
2. If app is launched again (having launchmode:singletask ) and another activity (not  webview hosting) comes on top top.
3. It destorys the previous activity holding webview which internally tries to cancel the dialog, but webviewcore instance is null.
Null pointer exception is raised.

Change-Id: Idbcd30d0b0d4a35819444bbaa5c73cced8bb35a3
Signed-off-by: Amit Kumar <amitkecian@gmail.com>
FW: Ribbon - Toggles

Fix for some toggles not getting set properly
fix user toggle fc
fix some toggles hieght being HUGE

respect users click vib setting.

respect ribbon padding

sync custom toggle if in multiple places

fix theme issues.

Fixed Icon from Nitroz

Change-Id: Ia225e822485b715e6daddeb7b62e232e72db5e36
Merge "FIX Null Pointer Exception on dialog cancel" into jb-mr1
Fix NPE when pasting non-text from Clipboard

When copying a link from a bookmark and then pasting it into
a textfield a NullPointerException will occur.
A ClipData.Item is not guaranteed to always contain a text string
and therefore getText() can be set to null.

Using method coerceToText() instead of getText() makes sure that
a text string is always returned.

Change-Id: I81343c0371835a3a7a52045dcd1760e69e59a967
Can not mark the same content of browser page after copy

Marking a text on the web page and then press copy works,
but trying to mark the same text again does not work.
The reason for this is that the selection never gets
cleared in webkit.
The fix, calling cleaSelection in the onDestroyActionMode.
Also added clearSelection when getting an
onConfigurationChange.

Change-Id: I59b384cb5441b6a3a05007ea7e77f9699889a87c
Merge "FW: Ribbon - Toggles" into jb-mr1
SystemUI: WirelessADB Toggle

* Allow, when connected to WiFi, the utilization of the android debug bridge.
* When enabled, the label will show the current WiFi's IP address.

Change-Id: Ib87d4d70106bde14bf927f615edfb62af464be83
Signed-off-by: bmc08gt <bmc08gt.teamb00sted@gmail.com>
Revert "Can not mark the same content of browser page after copy"

This reverts commit 660f4ae57545f3fa1aef2867ca2050f118e72b93

Change-Id: I7d601db85ce74ed61d07265ac3ff461b2ca941e9
Merge "Revert "Can not mark the same content of browser page after copy"" into jb-mr1
Fix WirelessADB Toggle & build

Change-Id: I4d53a372e525fead4e34cb4c1405a710e22f2543
Signed-off-by: Gergely Szell (sethyx) <szell@hu.ibm.com>
Revert "Dark AOKP Toggle"

This reverts commit 494ab85a65f45e97f0ab9a2a31460859f1e44ce9.
Revert "Squash Dark UI commits from Slim"

This reverts commit a3ed0f2387e043bfbbb65998e0f3f42a923b2dbb.
Merge remote-tracking branch 'upstream/jb-mr1' into jb-mr1
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
Don't think -fno-strict-aliasing is needed here any longer.
Time will tell though...