networking features:

        - memory cache
        - request queue priority
        - event collection mechanism
      - merging new stathub interface changes

Change-Id: I0f4eceedfa5f164d3046c10e0c3e19a77ef07d69
Enable Webworkers and GC fix

Cherrypicked from Iad989ce9378c24e250827533cfc698f2e76c3be7 (#/c/157027)

Change-Id: I76264f4b608252f5ba7df0b335ac3fa811a992de
webkit: Support video frame capture for HTML5 canvas use cases

Includes several patches cherry-picked from jb branch.

Implement MediaPlayerPrivate::hasSingleSecurityOrigin

Allows drawing video to the canvas as long as the video is not a
playlist file which may contain references from different origins. The
MediaPlayer should be the source of this knowledge.

TODO: Have the MediaPlayer check the data sources and report back to
WebKit if the playlist files have the same security origin.

Change-Id: I184c173ad454c02649d0a9930e20e037846bbe33

HTML5 video should still play when not visible

The WebGL 1.0.1 texture-npot-video test expects to be able to play video
when the video element has display:none. According to the HTML5 video
specification this is allowed. The video frames won't be painted but the
media player will still generate the frames and they can be read once
the drawImage and texImage2D APIs gain support for video.

Change-Id: Ia265a3bc8394c097ffa917809c592b6cf1ef86ec

Conflicts:

	Source/WebKit/android/WebCoreSupport/MediaPlayerPrivateAndroid.cpp

Allow HTMLMediaElement to capture video frames

Allow HTMLMediaElement to capture video frames by implementing
MediaPlayer::paintCurrentFrameInContext.  Because the MediaPlayer and
video texture are created in the UI context, need to do signalling
between the webcore and UI threads to do the video frame capture.

Modified android media player to return accurate ready states so
that webkit can check for valid states to issue the media frame capture.
In MediaPlayerPrivateAndroid, delay ready state change to "HaveEnoughData"
only when the first video frame is available.

Changed HTMLVideoElement to create a renderer even if style specifies
display "none" so that a corresponding platform layer can be created for
the RenderVideo. This allows canvas or WebGL to access video frames even
when the video itself is not displayed.

Change-Id: I396681d8f2ec7030a380ac4ffccbd4c95892eed0

Conflicts:

	Source/WebCore/platform/graphics/android/layers/VideoLayerAndroid.cpp
	Source/WebCore/platform/graphics/android/layers/VideoLayerAndroid.h
	Source/WebCore/platform/graphics/android/layers/VideoLayerManager.cpp
	Source/WebCore/platform/graphics/android/layers/VideoLayerManager.h
	Source/WebCore/platform/graphics/android/rendering/ShaderProgram.h
	Source/WebKit/android/WebCoreSupport/MediaPlayerPrivateAndroid.cpp

Add callback for player state changes from HTML5 video java proxy

Keeps VideoLayerAndroid's player state in sync with the HTML5 video java
proxy's media player state. This is required so that
paintCurrentFrameInContext calls do not capture empty video frames.

CRs-Fixed: 426323

Conflicts:
	Source/WebCore/platform/graphics/android/layers/VideoLayerAndroid.cpp
	Source/WebKit/android/WebCoreSupport/MediaPlayerPrivateAndroid.cpp

Conflicts:
	Source/WebKit/android/jni/WebViewCore.cpp
webkit: fix crash when memcache resource is freed

Change-Id: Ie27947d1138d8aa4d39e48492ce80c396ada1beb
Fix for youtube not playing in browser

Update network state when video frame is available.
Rename to available video frame functions to be consistent.
Fix bug where player state is sometimes not updated.
CRs-fixed: 458557

Change-Id: I5de5990f5e3aa7059effba9cf1a746276e25a96c
Revert "Fix for youtube not playing in browser"
This reverts commit f2e17b7e812facde1f4b26f9c47f171cc16b79b7.

Change-Id: Icdb3e120d8ff779dbb7bf917d85bb584f1385bac
Revert "webkit: Support video frame capture for HTML5 canvas use cases"
This reverts commit adb15d6e73595ff53a79abadc4bffb4c0aa1917c.

Change-Id: I49509d8698dba936318f78e8177bd8043617d929
webkit: Adding missed WEBGL directive changes.

The websettings for webgl were not under compiler directive
added same.

Change-Id: Iac15c2084c746c1f7a65a7fab124357ea2a7ab6a

Conflicts:
	Source/WebKit/android/jni/WebSettings.cpp
webkit: remove JNI dependency for webgl

Change-Id: I535741b086abf2f58f4bb02883a3d5194b92cfd5
webkit: Fix for memory corruption in computing css value of MediaQuery

RenderStyle object is not owned in MediaQueryEvaluator,
which is latter used in CSSPrimitiveValue::computeLengthFloat.
RenderStyle object is released as it goes out of scope and a memory
corruption is noticed. This patch ensures RenderStyle object
is owned in MediaQueryEvaluator.

Change-Id: I6bceb76d096c950f81bee039b92fa241c66f0a49
CRs-Fixed: 488574
Webkit: Null check in CanvasTexture::uploadImageBuffer

This patch adds preventive null check for imageBuffers in
CanvasTexture::uploadImageBuffer.

This code flow can hit when we are not using Gpu Rendering.

Change-Id: I1c6e68fa83ec87b4d4a2850c959c546e20292e5b
CRs-Fixed: 523517
Webkit: add to detect China phone number

Webkit only can detect US phone number,no support for China
phone number.US phone number is 10-digit but China phone number
is 11-digit,US country code is "1",webkit will fetch last 10 digits
as a valid US phone number and ignore "1",So China phone number is
not detected.

In order to detect China 11-digit phone number,we add one function
in webkit.And add some codes to fix an original bug that it can not
detect a valid US phone number(e.g. email content contains two phone
numbers, the first one is 02123456789, the second is 3987654321,
and then the second valid US phone number will never be detected).

CRs-Fixed: 500805

Change-Id: Ibc3a3ad9ac1a4e820e896081d98a70b8f6201ed5
Webkit: Add support for WAPFORUM WML2.0 and OPENWAVE format.

Add WAPFORUM WML2.0 and OPENWAVE support in XMLDocumentParser.

CRs-Fixed: 530875

Change-Id: Iabe3b99073dfff7c60ef44d12d1acf1e032490ed
webkit : canvas bug fix. delay canvas paint till its context creation

some times HTMLCanvasElement::paint gets triggered before its
Context is created in JS. Due this GraphicsLayerAndroid assumes
that painting is done, whereas there is no buffer to paint since
the canvas context is not yet initialized.

This patch, don't allows canvas element paint until its context is
created. And once the context is created, we trigger style compute
to initiate paint on canvas element.

Change-Id: I4a985691f0e43f1dcba0c5de93720a5d9ec4e45f
CRs-fixed: 494847
Webkit: enable wml feature

Add wml feature in Android makefile.

CRs-Fixed: 530873

Change-Id: I98c58beb56ed9ba4d5307acc8d5180f9f93cb199

Conflicts:
	Source/WebCore/Android.mk