Unreviewed attempting to make Qt's eccentric hardware work.

* assembler/MacroAssemblerARM.h:
(JSC::MacroAssemblerARM::compare8):
(MacroAssemblerARM):
* assembler/MacroAssemblerMIPS.h:
(JSC::MacroAssemblerMIPS::compare8):
(MacroAssemblerMIPS):
* assembler/MacroAssemblerSH4.h:
(JSC::MacroAssemblerSH4::compare8):
(MacroAssemblerSH4):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113934 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Invalid Union Reference in StructureStubInfo.{cpp.h}
https://bugs.webkit.org/show_bug.cgi?id=83735

Reviewed by Filip Pizlo.

Changed the references to u.getByIdProtoList and u.getByIdSelfList
to be consistent.

* bytecode/StructureStubInfo.cpp:
(JSC::StructureStubInfo::visitWeakReferences):
* bytecode/StructureStubInfo.h:
(JSC::StructureStubInfo::initGetByIdSelfList):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113935 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Fix Windows warnings in WebSocketDeflaterTest
https://bugs.webkit.org/show_bug.cgi?id=83731

Reviewed by Kent Tamura.

Use const char* instead of const char[] to suppress warnings on
Windows.

* tests/WebSocketDeflaterTest.cpp:
(WebCore::TEST):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113936 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] MMRPlayer will hang webkit thread when retrieving media metadata
https://bugs.webkit.org/show_bug.cgi?id=80978

Patch by Jonathan Dong <jonathan.dong@torchmobile.com.cn> on 2012-04-11
Reviewed by Rob Buis.

Source/WebCore:

RIM PR: 143471
Implemented the interface function onWaitMetadataNotified()
which starts a timer to wait for the metadata retrieving to
finish, and pops up a dialog to notify the user what to do
if there still is no metadata when the timer fires.

This patch also contributed by Max Feil <mfeil@rim.com>.
Internally reviewed by Max Feil.

Test: http/tests/media/video-throttled-load-metadata.html

* platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
(WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
(WebCore):
(WebCore::MediaPlayerPrivate::onWaitMetadataNotified):
(WebCore::MediaPlayerPrivate::waitMetadataTimerFired):
* platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.h:
(MediaPlayerPrivate):

LayoutTests:

RIM PR: 143471
Added a layout test which simulates a slow network, and starts a web worker
thread to write a log message when retrieving media metadata to see if the
webkit thread is blocked by media retrieving thread.

* http/tests/media/video-throttled-load-metadata-expected.txt: Added.
* http/tests/media/video-throttled-load-metadata-worker.js: Added.
* http/tests/media/video-throttled-load-metadata.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113937 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] There shouldn't be two or more Accept-Language in platformRequest's headerList.
https://bugs.webkit.org/show_bug.cgi?id=83670

FrameLoaderClientBlackBerry::dispatchWillSendRequest and NetworkManager::startJob will call
ResourceRequest::initializePlatformRequest. Accept-Language is added two times.
We should avoid the second adding to improve performance.

Patch by Jason Liu <jason.liu@torchmobile.com.cn> on 2012-04-11
Reviewed by Rob Buis.

No new tests. Refactor.

* platform/network/blackberry/ResourceRequestBlackBerry.cpp:
(WebCore::ResourceRequest::initializePlatformRequest):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113938 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Revert the changes that depend on Event changes, which is reverted already internally.
https://bugs.webkit.org/show_bug.cgi?id=83456

Reviewed by George Staikos.

No new tests, just to make BlackBerry-porting to build.

* plugins/blackberry/PluginViewBlackBerry.cpp:
(WebCore::PluginView::handleWheelEvent):
(WebCore::PluginView::handleTouchEvent):
(WebCore::PluginView::handleMouseEvent):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113939 268f45cc-cd09-0410-ab3c-d52691b4dbfc
AudioContext createChannelSplitter() method should have optional argument for number of outputs
https://bugs.webkit.org/show_bug.cgi?id=83648

Patch by Raymond Liu <raymond.liu@intel.com> on 2012-04-11
Reviewed by Chris Rogers.

Check https://dvcs.w3.org/hg/audio/raw-file/tip/webaudio/specification.html for the optional argument.

Source/WebCore:

Test: webaudio/audiochannelsplitter.html

* Modules/webaudio/AudioChannelSplitter.cpp:
(WebCore::AudioChannelSplitter::create):
(WebCore::AudioChannelSplitter::AudioChannelSplitter):
(WebCore::AudioChannelSplitter::process):
* Modules/webaudio/AudioChannelSplitter.h:
(AudioChannelSplitter):
* Modules/webaudio/AudioContext.cpp:
(WebCore::AudioContext::createChannelSplitter):
(WebCore):
* Modules/webaudio/AudioContext.h:
(AudioContext):
* Modules/webaudio/AudioContext.idl:

LayoutTests:

* webaudio/audiochannelsplitter-expected.txt: Added.
* webaudio/audiochannelsplitter.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113940 268f45cc-cd09-0410-ab3c-d52691b4dbfc
It is incorrect to short-circuit Branch(LogicalNot(@a)) if boolean speculations on @a may fail
https://bugs.webkit.org/show_bug.cgi?id=83744
<rdar://problem/11206946>

Source/JavaScriptCore: 

Reviewed by Andy Estes.
        
This does the conservative thing: it only short-circuits Branch(LogicalNot(@a)) if @a is a node
that is statically known to return boolean results.

* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):

LayoutTests: 

Rubber stamped by Andy Estes.

* fast/js/dfg-branch-not-fail-expected.txt: Added.
* fast/js/dfg-branch-not-fail.html: Added.
* fast/js/script-tests/dfg-branch-not-fail.js: Added.
(foo):
(bar):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113941 268f45cc-cd09-0410-ab3c-d52691b4dbfc
fast/text/international/font-fallback-to-common-script.html fails on Mac
https://bugs.webkit.org/show_bug.cgi?id=83743

Patch by Matt Falkenhagen <falken@chromium.org> on 2012-04-11
Reviewed by Kent Tamura.

Change test not assume that there is no font setting for Simplified Chinese.

* fast/text/international/font-fallback-to-common-script.html:
* platform/mac/Skipped:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113942 268f45cc-cd09-0410-ab3c-d52691b4dbfc
IndexedDB: Stub out WebKit interface for get(IndexedKeyRange)
https://bugs.webkit.org/show_bug.cgi?id=83637

Patch by Alec Flett <alecflett@chromium.org> on 2012-04-11
Reviewed by Kent Tamura.

This is just a stub-out of IDBObjectStore.get(IDBKeyRange) to coordinate
a landing in chromium

* public/WebIDBObjectStore.h:
(WebKit::WebIDBObjectStore::get):
(WebIDBObjectStore):
* src/IDBObjectStoreBackendProxy.cpp:
(WebKit::IDBObjectStoreBackendProxy::get):
(WebKit):
* src/IDBObjectStoreBackendProxy.h:
(IDBObjectStoreBackendProxy):
* src/WebIDBObjectStoreImpl.cpp:
(WebKit::WebIDBObjectStoreImpl::get):
(WebKit):
* src/WebIDBObjectStoreImpl.h:
(WebIDBObjectStoreImpl):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113943 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed rebaseline.

Patch by Antonio Gomes <agomes@rim.com> on 2012-04-11

* media/nodesFromRect-shadowContent-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113944 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Implement Location.ancestorOrigins
https://bugs.webkit.org/show_bug.cgi?id=83493

Reviewed by David Levin.

Source/WebCore:

Test: fast/dom/Window/Location/ancestor-origins.html

This patch implements Location.ancestorOrigins(), which returns a list
of the origins of the enclosing frames.  This API has been discussed
both on webkit-dev (see discussion following
https://lists.webkit.org/pipermail/webkit-dev/2012-March/020090.html)
and on the whatwg list (see discussion following
http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2012-March/035188.html).

* page/Location.cpp:
(WebCore::Location::ancestorOrigins):
(WebCore):
* page/Location.h:
(Location):
* page/Location.idl:

LayoutTests:

* fast/dom/Window/Location/ancestor-origins-expected.txt: Added.
* fast/dom/Window/Location/ancestor-origins.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113945 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed, GTK rebaseline after r113945.

* platform/gtk/fast/dom/Window/window-properties-expected.txt:
* platform/gtk/fast/dom/prototype-inheritance-2-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113946 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Fix Windows compiler warnings in webkit_unit_test target
https://bugs.webkit.org/show_bug.cgi?id=83732

Reviewed by Kent Tamura.

* tests/CCDamageTrackerTest.cpp:
(WebKitTests::TEST_F):
* tests/CCLayerImplTest.cpp:
(WebCore::TEST):
* tests/CCLayerTreeHostCommonTest.cpp:
(WebKitTests::TEST):
* tests/CCLayerTreeHostImplTest.cpp:
(WebKitTests::TEST_F):
* tests/CCQuadCullerTest.cpp:
(WebCore::TEST):
* tests/FloatQuadTest.cpp:
(WebCore::TEST):
* tests/ScrollAnimatorNoneTest.cpp:
(TEST_F):
* tests/TreeSynchronizerTest.cpp:
(WebKitTests::TEST):
* tests/WebLayerTest.cpp:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113947 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Chromium] Move some code of WebViewImpl and WebFrameImpl to PageWidgetDelegate
https://bugs.webkit.org/show_bug.cgi?id=83750

Reviewed by Adam Barth.

In order to share code in WebViewImpl and the incoming WebPagePopupImpl,
we move some code of WebViewImpl and WebFrameImpl to PageWidgetDelegate.
PageWidgetDelegate is a set of static functions because we can't use
virtual inheritance in this case and we don't want to move WebView's
data members to another class.

No new tests. Just refactoring.

* WebKit.gyp: Add PageWidgetDelegate.{cpp,h} and WebPagePopupImpl.h.
* src/PageWidgetDelegate.cpp: Added.
(WebKit::mainFrameView):
(WebKit::PageWidgetDelegate::animate):
Moved from a part of WebViewImpl::animatie()
(WebKit::PageWidgetDelegate::layout):
Moved from WebViewImpl::layout() and WebFrameImpl::layout().
(WebKit::PageWidgetDelegate::paint):
Moved from WebFrameImpl::paint() and paintWithContext().
(WebKit::PageWidgetDelegate::handleInputEvent):
Moved from a part of WebViewImpl::handleInputEvent().
(WebKit::PageWidgetEventHandler::handleMouseMove):
Common implementation of an event handling.
(WebKit::PageWidgetEventHandler::handleMouseLeave): ditto.
(WebKit::PageWidgetEventHandler::handleMouseDown): ditto.
(WebKit::PageWidgetEventHandler::handleMouseUp): ditto.
(WebKit::PageWidgetEventHandler::handleMouseWheel): ditto.
(WebKit::PageWidgetEventHandler::handleTouchEvent): ditto.
* src/PageWidgetDelegate.h: Added.
* src/WebFrameImpl.cpp:
Remove layout(), paintWithContext(), and paint(). They are moved to
PageWidgetDelegate.
* src/WebFrameImpl.h:
(WebFrameImpl): Remove layout(), paintWithContext(), and paint().
* src/WebViewImpl.cpp:
(WebKit::WebViewImpl::handleMouseLeave):
Renamed from mouseLeave(), use PageWidgetDelegate::handleMouseLeave().
(WebKit::WebViewImpl::handleMouseDown):
Renamed from mouseDown(), use PageWidgetDelegate::handleMouseDown().
(WebKit::WebViewImpl::handleMouseUp):
Renamed from mouseUp(), use PageWidgetDelegate::handleMouseUp().
(WebKit::WebViewImpl::scrollBy): Calls renamed handleMouseWheel().
(WebKit::WebViewImpl::handleGestureEvent): Renamed from gestureEvent().
(WebKit::WebViewImpl::handleKeyEvent): Renamed from keyEvent().
(WebKit::WebViewImpl::handleCharEvent): Renamed from charEvent().
(WebKit::WebViewImpl::updateAnimations): Uses PageWidgetDelegate::animate().
(WebKit::WebViewImpl::layout): Uses PageWidgetDelegate::layout().
(WebKit::WebViewImpl::paint): Uses PageWidgetDelegate::paint().
(WebKit::WebViewImpl::handleInputEvent): Uses PageWidgetDelegate::handleInputEvent().
* src/WebViewImpl.h:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113948 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Qt] ImageBuffer: Canonical mimeType for encoding implies startsWith('image/')
https://bugs.webkit.org/show_bug.cgi?id=83746

Reviewed by Simon Hausmann.

Canonical image mimeTypes begin with "image/", and this is tested by an ASSERT
guard in toDataURL(): that checks the WebCore mimeType registry for image-for-
encoding mimeType. There is no need to also test mimeType.startsWith("image/")
since that is a given.

No new tests. Covered by existing fast/canvas/*toDataURL* tests.

* platform/graphics/qt/ImageBufferQt.cpp:
(WebCore::ImageBuffer::toDataURL):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113949 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] We shouldn't set empty Content-Length & Content-Type to a request's headers.
https://bugs.webkit.org/show_bug.cgi?id=83349

When there is a redirection for a POST request, we change POST to GET and set
Content-Length/Content-Type to empty strings.
We should remove these headers instead of adding empty strings.

Patch by Jason Liu <jason.liu@torchmobile.com.cn> on 2012-04-12
Reviewed by George Staikos.

No new tests. Refactor.

* platform/network/blackberry/NetworkJob.cpp:
(WebCore::NetworkJob::handleRedirect):
* platform/network/blackberry/ResourceRequest.h:
(ResourceRequest):
* platform/network/blackberry/ResourceRequestBlackBerry.cpp:
(WebCore::ResourceRequest::clearHTTPContentLength):
(WebCore):
(WebCore::ResourceRequest::clearHTTPContentType):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113950 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Chromium] The size of glyphStorage should be passed to substituteWithVerticalGlyphs()
https://bugs.webkit.org/show_bug.cgi?id=83751

Reviewed by Kent Tamura.

The last argument of substituteWithVerticalGlyphs() should be
the size of |glyphStorage|.

No new tests because we can't test the fix by layout tests.
I confirmed the fix with ASAN.

* platform/graphics/skia/GlyphPageTreeNodeSkia.cpp:
(WebCore::GlyphPage::fill):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113951 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Qt] Unreveiwed gardening. Skip the failing reftest.

* platform/qt/Skipped: skip fast/workers/worker-multi-startup.html

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113952 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Upstreaming BlackBerry-specific changes to PluginView -- remove unused functions
https://bugs.webkit.org/show_bug.cgi?id=83756

Reviewed by George Staikos.

PluginView::halt(), PluginView::restart() have been removed from
upstreaming code, should remove them from BlackBerry porting also.

* plugins/blackberry/PluginViewBlackBerry.cpp:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113953 268f45cc-cd09-0410-ab3c-d52691b4dbfc