WebKit-https.git
8 years agoRename window.internals.fastMallocStatistics to mallocStatistics
commit-queue@webkit.org [Wed, 15 Aug 2012 19:08:06 +0000 (19:08 +0000)]
Rename window.internals.fastMallocStatistics to mallocStatistics
https://bugs.webkit.org/show_bug.cgi?id=94033

Patch by Scott Graham <scottmg@chromium.org> on 2012-08-15
Reviewed by Adam Barth.

PerformanceTests:

* resources/runner.js:
(PerfTestRunner.storeHeapResults):
(PerfTestRunner.getUsedMallocHeap):
(PerfTestRunner.getAndPrintMemoryStatistics):
(PerfTestRunner.initAndStartLoop):

Source/WebCore:

Mechanical rename. In preparation for plumbing allocation information
from allocators that aren't "fastMalloc".

* CMakeLists.txt:
* DerivedSources.make:
* DerivedSources.pri:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.gyp/WebCore.gyp:
* WebCore.gypi:
* WebCore.vcproj/WebCoreTestSupport.vcproj:
* WebCore.xcodeproj/project.pbxproj:
* loader/DocumentLoader.h:
(WebCore::DocumentLoader::didTellClientAboutLoad):
* loader/cache/CachedResourceLoader.cpp:
(WebCore::CachedResourceLoader::loadResource):
* testing/FastMallocStatistics.h: Removed.
* testing/FastMallocStatistics.idl: Removed.
* testing/Internals.cpp:
(WebCore::Internals::mallocStatistics):
* testing/Internals.h:
(WebCore):
(Internals):
* testing/Internals.idl:
* testing/MallocStatistics.h: Added.
* testing/MallocStatistics.idl: Added.

Tools:

* GNUmakefile.am:
* Scripts/webkitpy/performance_tests/perftest.py:
(PerfTest):
* Scripts/webkitpy/performance_tests/perftestsrunner_unittest.py:
(test_run_memory_test):

LayoutTests:

* fast/harness/fastmallocstatistics-object.html:

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

8 years ago[BlackBerry] Upstream BlackBerry build fixes
commit-queue@webkit.org [Wed, 15 Aug 2012 18:54:33 +0000 (18:54 +0000)]
[BlackBerry] Upstream BlackBerry build fixes
https://bugs.webkit.org/show_bug.cgi?id=94121

Patch by Joshua Netterfield <jnetterfield@rim.com> on 2012-08-15
Reviewed by Rob Buis.

This includes several build fixes due to incorrect upstream patches.
These mistakes were never present downstream.

No new tests, because no new functionality is added.

Source/WebCore:

* platform/graphics/GraphicsContext3D.cpp:
(WebCore::GraphicsContext3D::computeFormatAndTypeParameters):
* platform/graphics/GraphicsContext3D.h:
(GraphicsContext3D):
(WebCore::GraphicsContext3D::ShaderSourceEntry::ShaderSourceEntry):
* platform/graphics/blackberry/LayerFilterRenderer.cpp:
(WebCore::LayerFilterRendererAction::LayerFilterRendererAction):
* platform/graphics/blackberry/LayerFilterRenderer.h:
(LayerFilterRendererAction):

Source/WebKit/blackberry:

* WebCoreSupport/AboutDataEnableFeatures.in:
* WebCoreSupport/AboutTemplate.html.cpp:
(writeHeader):

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

8 years agoUpdate expectations to match the bots. This test hasn't timed out in over 500 runs.
ojan@chromium.org [Wed, 15 Aug 2012 18:44:17 +0000 (18:44 +0000)]
Update expectations to match the bots. This test hasn't timed out in over 500 runs.
* platform/chromium/TestExpectations:

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

8 years agoJSDOMWrapper should ASSERT that it has an associated ScriptExecutionContext
abarth@webkit.org [Wed, 15 Aug 2012 18:44:02 +0000 (18:44 +0000)]
JSDOMWrapper should ASSERT that it has an associated ScriptExecutionContext
https://bugs.webkit.org/show_bug.cgi?id=94053

Reviewed by Sam Weinig.

Previously we were unable have this ASSERT because DOMWindow needed a
Frame to find Document. Now that we can find the Document without a
Frame, we can include the ASSERT and sanity will rein across the land.

* bindings/js/JSDOMWrapper.h:
(WebCore::JSDOMWrapper::globalObject):
(WebCore::JSDOMWrapper::scriptExecutionContext):
(WebCore::JSDOMWrapper::JSDOMWrapper):

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

8 years agoChange behavior of MasqueradesAsUndefined to better accommodate DFG changes
mhahnenberg@apple.com [Wed, 15 Aug 2012 18:32:41 +0000 (18:32 +0000)]
Change behavior of MasqueradesAsUndefined to better accommodate DFG changes
https://bugs.webkit.org/show_bug.cgi?id=93884

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

With some upcoming changes to the DFG to remove uses of ClassInfo, we will be changing the behavior of
MasqueradesAsUndefined. In order to make this change consistent across all of our execution engines,
we will make this change to MasqueradesAsUndefined as a separate patch. After this patch, MasqueradesAsUndefined
objects will only masquerade as undefined in their original context (i.e. their original JSGlobalObject).
For example, if an object that masquerades as undefined in frame A is passed to frame B, it will not
masquerade as undefined within frame B, but it will continue to masquerade in frame A.

There are two primary changes that are taking place here. One is to thread the ExecState* through
JSValue::toBoolean and JSCell::toBoolean so that JSCell::toBoolean can check the object's
JSGlobalObject to compare it to the lexical JSGlobalObject of the currently running code. If the two
are distinct, then the object cannot MasqueradeAsUndefined.

The other change is to perform this comparison of JSGlobalObjects everywhere where the MasqueradesAsUndefined
flag in the Structure is checked. For C++ code, this check has been factored into its own function in
Structure::masqueradesAsUndefined. We only perform this check in the DFG if the current JSGlobalObject has
had a MasqueradesAsUndefined object allocated within its context. This conditional compilation is managed
through the use of a WatchpointSet in each JSGlobalObject and alternate create() functions for JS DOM wrappers
that are MasqueradesAsUndefined.

* API/JSValueRef.cpp:
(JSValueToBoolean):
* JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.def:
* bytecode/Watchpoint.h:
(WatchpointSet):
* debugger/DebuggerCallFrame.h:
(JSC::DebuggerCallFrame::callFrame):
* dfg/DFGAbstractState.cpp:
(JSC::DFG::AbstractState::execute):
* dfg/DFGCFGSimplificationPhase.cpp:
(JSC::DFG::CFGSimplificationPhase::run):
* dfg/DFGOperations.cpp:
* dfg/DFGOperations.h:
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::nonSpeculativeNonPeepholeCompareNull):
(JSC::DFG::SpeculativeJIT::nonSpeculativePeepholeBranchNull):
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::nonSpeculativeNonPeepholeCompareNull):
(JSC::DFG::SpeculativeJIT::nonSpeculativePeepholeBranchNull):
(JSC::DFG::SpeculativeJIT::compile):
* interpreter/Interpreter.cpp:
(JSC::Interpreter::privateExecute):
* jit/JITOpcodes.cpp:
(JSC::JIT::emit_op_is_undefined):
(JSC::JIT::emit_op_jeq_null):
(JSC::JIT::emit_op_jneq_null):
(JSC::JIT::emit_op_eq_null):
(JSC::JIT::emit_op_neq_null):
* jit/JITOpcodes32_64.cpp:
(JSC::JIT::emit_op_is_undefined):
(JSC::JIT::emit_op_jeq_null):
(JSC::JIT::emit_op_jneq_null):
(JSC::JIT::emit_op_eq_null):
(JSC::JIT::emit_op_neq_null):
* jit/JITStubs.cpp:
(JSC::DEFINE_STUB_FUNCTION):
* llint/LLIntSlowPaths.cpp:
(JSC::LLInt::LLINT_SLOW_PATH_DECL):
* llint/LowLevelInterpreter32_64.asm:
* llint/LowLevelInterpreter64.asm:
* runtime/ArrayPrototype.cpp:
(JSC::arrayProtoFuncFilter):
(JSC::arrayProtoFuncEvery):
(JSC::arrayProtoFuncSome):
* runtime/BooleanConstructor.cpp:
(JSC::constructBoolean):
(JSC::callBooleanConstructor):
* runtime/JSCell.h:
(JSCell):
* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::JSGlobalObject):
* runtime/JSGlobalObject.h:
(JSGlobalObject):
(JSC::JSGlobalObject::masqueradesAsUndefinedWatchpoint):
* runtime/JSString.h:
(JSC::JSCell::toBoolean):
(JSC::JSValue::toBoolean):
* runtime/JSValue.h:
* runtime/ObjectConstructor.cpp:
(JSC::toPropertyDescriptor):
* runtime/Operations.cpp:
(JSC::jsTypeStringForValue):
(JSC::jsIsObjectType):
* runtime/Operations.h:
(JSC):
(JSC::JSValue::equalSlowCaseInline):
* runtime/RegExpConstructor.cpp:
(JSC::setRegExpConstructorMultiline):
* runtime/RegExpPrototype.cpp:
(JSC::regExpProtoFuncToString):
* runtime/Structure.h:
(Structure):
(JSC::Structure::globalObjectOffset):
(JSC::Structure::masqueradesAsUndefined):
(JSC):

Source/WebCore:

With some upcoming changes to the DFG to remove uses of ClassInfo, we will be changing the behavior of
MasqueradesAsUndefined. In order to make this change consistent across all of our execution engines,
we will make this change to MasqueradesAsUndefined as a separate patch. After this patch, MasqueradesAsUndefined
objects will only masquerade as undefined in their original context (i.e. their original JSGlobalObject).
For example, if an object that masquerades as undefined in frame A is passed to frame B, it will not
masquerade as undefined within frame B, but it will continue to masquerade in frame A.

Test: fast/js/document-all-between-frames.html

All of the changes in WebCore are simply passing the additional ExecState argument to JSValue::toBoolean.

* bindings/js/JSCustomSQLStatementErrorCallback.cpp:
(WebCore::JSSQLStatementErrorCallback::handleEvent):
* bindings/js/JSDOMWindowCustom.cpp:
(WebCore::JSDOMWindow::addEventListener):
(WebCore::JSDOMWindow::removeEventListener):
* bindings/js/JSDataViewCustom.cpp:
(WebCore::getDataViewMember):
* bindings/js/JSDeviceMotionEventCustom.cpp:
(WebCore::JSDeviceMotionEvent::initDeviceMotionEvent):
* bindings/js/JSDeviceOrientationEventCustom.cpp:
(WebCore::JSDeviceOrientationEvent::initDeviceOrientationEvent):
* bindings/js/JSDictionary.cpp:
(WebCore::JSDictionary::convertValue):
* bindings/js/JSDirectoryEntryCustom.cpp:
(WebCore::JSDirectoryEntry::getFile):
(WebCore::JSDirectoryEntry::getDirectory):
* bindings/js/JSDirectoryEntrySyncCustom.cpp:
(WebCore::getFlags):
* bindings/js/JSHTMLCanvasElementCustom.cpp:
(WebCore::JSHTMLCanvasElement::getContext):
* bindings/js/JSInspectorFrontendHostCustom.cpp:
(WebCore::populateContextMenuItems):
* bindings/js/JSMessageEventCustom.cpp:
(WebCore::handleInitMessageEvent):
* bindings/js/JSWebGLRenderingContextCustom.cpp:
(WebCore::dataFunctionMatrix):
* bindings/js/JSXMLHttpRequestCustom.cpp:
(WebCore::JSXMLHttpRequest::open):
* bindings/js/JavaScriptCallFrame.cpp:
(WebCore::JavaScriptCallFrame::exec):
(WebCore):
* bindings/js/JavaScriptCallFrame.h:
(JavaScriptCallFrame):
* bindings/js/ScriptDebugServer.cpp:
(WebCore::ScriptDebugServer::hasBreakpoint):
* bindings/scripts/CodeGeneratorJS.pm: Also add the custom create function for MasqueradesAsUndefined JS DOM wrappers.
(GenerateEventListenerCall):
(GenerateHeader):
(JSValueToNative):
* bindings/scripts/test/JS/JSTestEventTarget.cpp:
(WebCore::jsTestEventTargetPrototypeFunctionAddEventListener):
(WebCore::jsTestEventTargetPrototypeFunctionRemoveEventListener):
* bindings/scripts/test/JS/JSTestEventTarget.h:
(WebCore::JSTestEventTarget::create):
* bindings/scripts/test/JS/JSTestObj.cpp:
(WebCore::setJSTestObjCreate):
(WebCore::setJSTestObjReflectedBooleanAttr):
(WebCore::setJSTestObjReflectedCustomBooleanAttr):
(WebCore::jsTestObjPrototypeFunctionAddEventListener):
(WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
* bridge/c/c_utility.cpp:
(JSC::Bindings::convertValueToNPVariant):
* bridge/jni/jni_jsobject.mm:
(JavaJSObject::convertValueToJObject):
* bridge/qt/qt_runtime.cpp:
(JSC::Bindings::convertValueToQVariant):

Source/WebKit/mac:

With some upcoming changes to the DFG to remove uses of ClassInfo, we will be changing the behavior of
MasqueradesAsUndefined. In order to make this change consistent across all of our execution engines,
we will make this change to MasqueradesAsUndefined as a separate patch. After this patch, MasqueradesAsUndefined
objects will only masquerade as undefined in their original context (i.e. their original JSGlobalObject).
For example, if an object that masquerades as undefined in frame A is passed to frame B, it will not
masquerade as undefined within frame B, but it will continue to masquerade in frame A.

* Plugins/Hosted/NetscapePluginInstanceProxy.mm:
(WebKit::NetscapePluginInstanceProxy::addValueToArray): Passing ExecState to toBoolean call.

Source/WebKit2:

With some upcoming changes to the DFG to remove uses of ClassInfo, we will be changing the behavior of
MasqueradesAsUndefined. In order to make this change consistent across all of our execution engines,
we will make this change to MasqueradesAsUndefined as a separate patch. After this patch, MasqueradesAsUndefined
objects will only masquerade as undefined in their original context (i.e. their original JSGlobalObject).
For example, if an object that masquerades as undefined in frame A is passed to frame B, it will not
masquerade as undefined within frame B, but it will continue to masquerade in frame A.

* WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
(WebKit::NPRuntimeObjectMap::convertJSValueToNPVariant): Passing ExecState to toBoolean call.

LayoutTests:

Added a test that uses a variety of ways of checking whether something is correctly
masquerading as undefined (or not) in a subframe.

* fast/js/document-all-between-frames-expected.txt: Added.
* fast/js/document-all-between-frames.html: Added.
* fast/js/resources/document-all-between-frames-subframe.html: Added.
* platform/chromium/TestExpectations: Chromium treats document.all differently, so skip our new test.

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

8 years agoUpdate TestExpectations entry to refer to an actual bug.
abarth@webkit.org [Wed, 15 Aug 2012 18:31:03 +0000 (18:31 +0000)]
Update TestExpectations entry to refer to an actual bug.

* platform/chromium/TestExpectations:

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

8 years ago[Gtk] atk_text_get_text_at_offset() fails to provide the correct line for paragraphs...
commit-queue@webkit.org [Wed, 15 Aug 2012 18:13:46 +0000 (18:13 +0000)]
[Gtk] atk_text_get_text_at_offset() fails to provide the correct line for paragraphs in list items whose text wraps
https://bugs.webkit.org/show_bug.cgi?id=83435

Patch by Joanmarie Diggs <jdiggs@igalia.com> on 2012-08-15
Reviewed by Chris Fleizach.

Source/WebCore:

Fix a logic error when checking if an object is a list marker.

* accessibility/gtk/WebKitAccessibleInterfaceText.cpp:
(textForRenderer):

Source/WebKit/gtk:

Updated unit test to include a paragraph in a list item when testing atk_text_get_text_at_offset().

* tests/testatk.c:
(testWebkitAtkGetTextAtOffsetWithSpecialCharacters):

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

8 years agoThere is additional space not belonged to a table between the table cells
commit-queue@webkit.org [Wed, 15 Aug 2012 18:01:05 +0000 (18:01 +0000)]
There is additional space not belonged to a table between the table cells
https://bugs.webkit.org/show_bug.cgi?id=74864

Patch by Arpita Bahuguna <arpitabahuguna@gmail.com> on 2012-08-15
Reviewed by Julien Chaffraix.

Source/WebCore:

Hittest for a point on the edge, i.e. between two table columns, currently
does not return any matching underlying element.

A hittest on such a point (on the edge of two table columns) should return
the column that lies either on the logical right/bottom of the said point.

Tests: fast/table/hittest-tablecell-bottom-edge.html
       fast/table/hittest-tablecell-right-edge.html
       fast/table/hittest-tablecell-with-borders-bottom-edge.html
       fast/table/hittest-tablecell-with-borders-right-edge.html

* rendering/RenderTableSection.cpp:
(WebCore::RenderTableSection::spannedRows):
Removed the FIXME regarding the correctness of the usage of the upper_bound algorithm
since that is now verified by the testcases in this patch. Also, the comment
regarding the inconsistency between the algorithms used in spannedRows and spannedColumns
is no longer valid.

(WebCore::RenderTableSection::spannedColumns):
Changed lower_bound() algorithm to upper_bound() for obtaining the next column.
This is now similar to what is used for obtaining the next row in spannedRows().

LayoutTests:

* fast/table/hittest-tablecell-bottom-edge-expected.txt: Added.
* fast/table/hittest-tablecell-bottom-edge.html: Added.
* fast/table/hittest-tablecell-right-edge-expected.txt: Added.
* fast/table/hittest-tablecell-right-edge.html: Added.
Testcases added for verifying that the proper node is returned upon hit test
carried out at a point lying on the edge of two table cells.

* fast/table/hittest-tablecell-with-borders-bottom-edge-expected.txt: Added.
* fast/table/hittest-tablecell-with-borders-bottom-edge.html: Added.
* fast/table/hittest-tablecell-with-borders-right-edge-expected.txt: Added.
* fast/table/hittest-tablecell-with-borders-right-edge.html: Added.
These testcases verify the aforementioned behavior when the table cells
also have border specified for them.

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

8 years agoFix a warning in TestWebKitAPI's MediaTime test-suite
peter@chromium.org [Wed, 15 Aug 2012 17:59:08 +0000 (17:59 +0000)]
Fix a warning in TestWebKitAPI's MediaTime test-suite
https://bugs.webkit.org/show_bug.cgi?id=94096

Reviewed by Adam Barth.

This warning is visible when building the file with certain GCC versions,
including the one used by Chromium for Android. The warning is visible in
the cr-android build bot output:

MediaTime.cpp:152: warning: this decimal constant is unsigned only in ISO C90

* TestWebKitAPI/Tests/WTF/MediaTime.cpp:
(TestWebKitAPI::TEST):

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

8 years agoAdd the timestampOffset attribute to SourceBuffer.
annacc@chromium.org [Wed, 15 Aug 2012 16:58:02 +0000 (16:58 +0000)]
Add the timestampOffset attribute to SourceBuffer.
https://bugs.webkit.org/show_bug.cgi?id=93303

Reviewed by Dimitri Glazkov.

On the 30 July 2012 version of the Media Source Extensions spec, a timestampOffset
attribute was added to the SourceBuffer object:
http://dvcs.w3.org/hg/html-media/raw-file/tip/media-source/media-source.html#dom-timestampoffset

Source/WebCore:

Tests: additions to http/tests/media/media-source/video-media-source-objects.html

* Modules/mediasource/MediaSource.cpp:
(WebCore::MediaSource::setTimestampOffset): Set the timestampOffset on MediaPlayer.
(WebCore):
* Modules/mediasource/MediaSource.h:
(MediaSource):
* Modules/mediasource/SourceBuffer.cpp:
(WebCore::SourceBuffer::SourceBuffer): Let the timestampOffset be 0 initially
(WebCore::SourceBuffer::timestampOffset): Return the last value set.
(WebCore):
(WebCore::SourceBuffer::setTimestampOffset): Forward the call onto MediaSouce.
* Modules/mediasource/SourceBuffer.h:
(SourceBuffer):
* Modules/mediasource/SourceBuffer.idl: Create the new timestampOffset attr.
* platform/graphics/MediaPlayer.cpp:
(WebCore::NullMediaPlayerPrivate::sourceSetTimestampOffset): A null media player
    should just return false (nothing to set).
(WebCore):
(WebCore::MediaPlayer::sourceSetTimestampOffset):  Forward the call.
* platform/graphics/MediaPlayer.h:
* platform/graphics/MediaPlayerPrivate.h:
(WebCore::MediaPlayerPrivateInterface::sourceSetTimestampOffset):

Source/WebKit/chromium:

* public/WebMediaPlayer.h:
(WebKit::WebMediaPlayer::sourceSetTimestampOffset): Add the new method.
* src/WebMediaPlayerClientImpl.cpp:
(WebKit):
(WebKit::WebMediaPlayerClientImpl::sourceSetTimestampOffset): Forward the call.
* src/WebMediaPlayerClientImpl.h:
(WebMediaPlayerClientImpl):

LayoutTests:

* http/tests/media/media-source/video-media-source-objects-expected.txt:
* http/tests/media/media-source/video-media-source-objects.html:

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

8 years agoSource/WebCore: Web Inspector: Incorrect XHR responses when two async xhrs are sent...
vsevik@chromium.org [Wed, 15 Aug 2012 16:50:13 +0000 (16:50 +0000)]
Source/WebCore: Web Inspector: Incorrect XHR responses when two async xhrs are sent synchronously
https://bugs.webkit.org/show_bug.cgi?id=91630

Patch by Pavel Chadnov <chadnov@google.com> on 2012-08-15
Reviewed by Vsevolod Vlasov.

CachedResource object for XHR response is now taken from ResourceLoader (if it's possible).

Test: http/tests/inspector/network/network-xhr-async-double.html

* inspector/InspectorInstrumentation.cpp:
(WebCore):
(WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
(WebCore::InspectorInstrumentation::didReceiveResourceResponseButCanceledImpl):
* inspector/InspectorInstrumentation.h:
(InspectorInstrumentation):
(WebCore::InspectorInstrumentation::didReceiveResourceResponse):
* inspector/InspectorResourceAgent.cpp:
(WebCore::InspectorResourceAgent::willSendRequest):
(WebCore::InspectorResourceAgent::didReceiveResponse):
* inspector/InspectorResourceAgent.h:
(WebCore):
(InspectorResourceAgent):
* loader/DocumentThreadableLoader.cpp:
(WebCore::DocumentThreadableLoader::didReceiveResponse):
* loader/ResourceLoadNotifier.cpp:
(WebCore::ResourceLoadNotifier::didReceiveResponse):
(WebCore::ResourceLoadNotifier::dispatchDidReceiveResponse):
* loader/ResourceLoadNotifier.h:
(ResourceLoadNotifier):
* loader/ResourceLoader.cpp:
(WebCore::ResourceLoader::isSubresourceLoader):
(WebCore):
* loader/ResourceLoader.h:
(ResourceLoader):
* loader/SubresourceLoader.cpp:
(WebCore::SubresourceLoader::cachedResource):
(WebCore):
(WebCore::SubresourceLoader::isSubresourceLoader):
* loader/SubresourceLoader.h:
(SubresourceLoader):
* loader/appcache/ApplicationCacheGroup.cpp:
(WebCore::ApplicationCacheGroup::didReceiveResponse):

LayoutTests: Web Inspector: Incorrect XHR responses when two async xhrs are sent synchronously
https://bugs.webkit.org/show_bug.cgi?id=91630

Patch by Pavel Chadnov <chadnov@google.com> on 2012-08-15
Reviewed by Vsevolod Vlasov.

New test for two async XHRs sent synchronously.

* http/tests/inspector/network-test.js:
(doXHR):
(doXHRWithPayload.xhr.onreadystatechange):
(doXHRWithPayload):
* http/tests/inspector/network/network-xhr-async-double-expected.txt: Added.
* http/tests/inspector/network/network-xhr-async-double.html: Added.
* http/tests/inspector/network/resources/echo-payload.php: Added.
* platform/chromium/http/tests/inspector/console-xhr-logging-async-expected.txt:
* platform/chromium/http/tests/inspector/console-xhr-logging-expected.txt:

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

8 years ago[BlackBerry] Use nested layout when rotating
commit-queue@webkit.org [Wed, 15 Aug 2012 16:20:39 +0000 (16:20 +0000)]
[BlackBerry] Use nested layout when rotating
https://bugs.webkit.org/show_bug.cgi?id=94117

Partially patched by Arvid Nilsson.

Patch by Leo Yang <leoyang@rim.com> on 2012-08-15
Reviewed by George Staikos.
Reviewed internally by Arvid Nilsson.

When rotating the content width used for fixedLayoutSize is not
correct because we are changing the rotation and the content with
should be determined after layout. So we set the with to 0 if we
are rotating and beginning the nested layout. And in setViewportSize
we need a nested layout loop to trigger zoom-to-fit.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::fixedLayoutSize):
(BlackBerry::WebKit::WebPagePrivate::setViewportSize):

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

8 years ago[BlackBerry] Stop copying ScrollViewBase vector all over
tonikitoo@webkit.org [Wed, 15 Aug 2012 16:06:30 +0000 (16:06 +0000)]
[BlackBerry] Stop copying ScrollViewBase vector all over
https://bugs.webkit.org/show_bug.cgi?id=94021

Reviewed by Rob Buis.

It outlives long enough in WebKit that we can
just pass a const+ref of it.

Internally reviewed by Gen Mak.

* Api/WebPageClient.h:

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

8 years agoRobust-fy the LayerWebKitThread ownership with InRegionScroller
tonikitoo@webkit.org [Wed, 15 Aug 2012 16:05:56 +0000 (16:05 +0000)]
Robust-fy the LayerWebKitThread ownership with InRegionScroller
https://bugs.webkit.org/show_bug.cgi?id=93983
PR #191737

Reviewed by Yong Li.
Patch by Antonio Gomes <agomes@rim.com>

Patch changes the way we currently keep track of the active scrollable area
objects: before, we acquired the scrollable areas and just passed them in a vector up
to the client, copying it over and over again. Also, it was a client responsability to
delete stuff (BAD!).
Now, we keep track of vector within InRegionScroller, as a class member, which allows us to
avoid copies (in follow up patch), and control until when these objects outlive.

Patch also changes InRegionScrollableArea to "retptr" the composited layer
associated to it (if any). This ensure we have a non-null scrollable element always.

As mentioned, InRegionScroller is now responsible for deleting and vector of scrollable areas.

Internally reviewed by Arvid Nilsson.

* Api/InRegionScroller.cpp:
(WebKit):
(BlackBerry::WebKit::InRegionScrollerPrivate::reset): Method is now responsible for
deleting the tracked scrollable areas.
(BlackBerry::WebKit::InRegionScrollerPrivate::calculateInRegionScrollableAreasForPoint):
Renamed from 'inRegionScrollableAreasForPoint'. It was changed in order to store the
scrollable area objects instead of just pass a copy of them up to the client.
(BlackBerry::WebKit::InRegionScrollerPrivate::activeInRegionScrollableAreas): Getter.
(BlackBerry::WebKit::InRegionScrollerPrivate::pushBackInRegionScrollable): It was
promoted to a class method instead of a local helper.
* Api/InRegionScroller_p.h:
(WebKit):
(InRegionScrollerPrivate):
* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::setScrollOriginPoint): Adjustments needed due to the
above changed.
* WebKitSupport/InRegionScrollableArea.cpp:
(BlackBerry::WebKit::InRegionScrollableArea::~InRegionScrollableArea): Clear up the cached layer.
(WebKit):
(BlackBerry::WebKit::InRegionScrollableArea::InRegionScrollableArea):
* WebKitSupport/InRegionScrollableArea.h:
(InRegionScrollableArea):

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

8 years agoWeb Inspector: Use default parameter on reportResult in InspectorFileSystemAgent
commit-queue@webkit.org [Wed, 15 Aug 2012 15:56:28 +0000 (15:56 +0000)]
Web Inspector: Use default parameter on reportResult in InspectorFileSystemAgent
https://bugs.webkit.org/show_bug.cgi?id=93930

Patch by Taiju Tsuiki <tzik@chromium.org> on 2012-08-15
Reviewed by Vsevolod Vlasov.

No functional change.

* inspector/InspectorFileSystemAgent.cpp:
(WebCore):

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

8 years ago[BlackBerry] Check for valid field focus before processing a spellcheck request
commit-queue@webkit.org [Wed, 15 Aug 2012 15:50:04 +0000 (15:50 +0000)]
[BlackBerry] Check for valid field focus before processing a spellcheck request
https://bugs.webkit.org/show_bug.cgi?id=94115

Patch by Nima Ghanavatian <nghanavatian@rim.com> on 2012-08-15
Reviewed by Rob Buis.

PR192891
Checking for valid field focus before processing the spellcheck
request.

Internally reviewed by Mike Fenton.

* WebKitSupport/InputHandler.cpp:
(BlackBerry::WebKit::InputHandler::requestCheckingOfString):

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

8 years agoFix the 'git log' call in VCSUtils.pm for Windows
commit-queue@webkit.org [Wed, 15 Aug 2012 15:46:47 +0000 (15:46 +0000)]
Fix the 'git log' call in VCSUtils.pm for Windows
https://bugs.webkit.org/show_bug.cgi?id=94113

Patch by Kevin Funk <kevin.funk@kdab.com> on 2012-08-15
Reviewed by Kenneth Rohde Christiansen.

Failed because of invalid enquoting characters.

* Scripts/VCSUtils.pm:

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

8 years ago[jhbuild] move md5sum checking to update-webkit-libs-jhbuild
kov@webkit.org [Wed, 15 Aug 2012 14:17:44 +0000 (14:17 +0000)]
[jhbuild] move md5sum checking to update-webkit-libs-jhbuild
https://bugs.webkit.org/show_bug.cgi?id=93208

Reviewed by Martin Robinson.

This change makes the md5sum check and saving be done by the script
that performs the dependencies update. build-webkit no longer prefixes
calls to commands with jhbuild-wrapper if jhbuild has not been
bootstrapped by the developer and --update-gtk is not given.

* Scripts/update-webkit-libs-jhbuild:
(getMD5HashForFile): moved from webkitdirs.
(jhbuildConfigurationChanged): ditto.
(saveJhbuildMd5): ditto.
(cleanJhbuild): ditto, and changed to run jhbuild clean before removing
jhbuild.
* Scripts/webkitdirs.pm:
(runAutogenForAutotoolsProjectIfNecessary): use jhbuildWrapperPrefixIfNeeded.
(buildAutotoolsProject): ditto.
(jhbuildWrapperPrefixIfNeeded): add a code branch for GTK+.
(generateBuildSystemFromCMakeProject): call update-webkitefl-libs
unconditionally for EFL.
* jhbuild/jhbuild-wrapper:
(update_webkit_libs_jhbuild): removed, jhbuild-wrapper no longer runs the
update script itself
(ensure_jhbuild): remove update call.

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

8 years agoWeb Inspector: TabbedEditorContainer Doens't show '*' near modified file name sometimes.
vsevik@chromium.org [Wed, 15 Aug 2012 13:58:40 +0000 (13:58 +0000)]
Web Inspector: TabbedEditorContainer Doens't show '*' near modified file name sometimes.
https://bugs.webkit.org/show_bug.cgi?id=94095

Reviewed by Pavel Feldman.

TabbedEditorContainer now correctly updates event listeners on UISourceCodeReplaced event.

* inspector/front-end/TabbedEditorContainer.js:
(WebInspector.TabbedEditorContainer.prototype._appendFileTab):
(WebInspector.TabbedEditorContainer.prototype._tabClosed):
(WebInspector.TabbedEditorContainer.prototype._addUISourceCodeListeners):
(WebInspector.TabbedEditorContainer.prototype._removeUISourceCodeListeners):

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

8 years agoWeb Inspector: Scroll/selection are not saved in sources panel editors sometimes.
vsevik@chromium.org [Wed, 15 Aug 2012 13:53:53 +0000 (13:53 +0000)]
Web Inspector: Scroll/selection are not saved in sources panel editors sometimes.
https://bugs.webkit.org/show_bug.cgi?id=94098

Reviewed by Pavel Feldman.

SourceFrame listeners and _currentFile field are now cleared only when currently open tab is closed.

* inspector/front-end/TabbedEditorContainer.js:
(WebInspector.TabbedEditorContainer.prototype._tabClosed):

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

8 years ago[EFL][WK2] Refactoring: start using WKEinaSharedString in ewk_ classes
commit-queue@webkit.org [Wed, 15 Aug 2012 13:50:14 +0000 (13:50 +0000)]
[EFL][WK2] Refactoring: start using WKEinaSharedString in ewk_ classes
https://bugs.webkit.org/show_bug.cgi?id=93964

Patch by Mikhail Pozdnyakov <mikhail.pozdnyakov@intel.com> on 2012-08-15
Reviewed by Kenneth Rohde Christiansen.

Started using WKEinaSharedString where it is advisable.

* UIProcess/API/cpp/efl/WKEinaSharedString.cpp:
(WKEinaSharedString::operator==):
* UIProcess/API/cpp/efl/WKEinaSharedString.h:
* UIProcess/API/efl/ewk_download_job.cpp:
(_Ewk_Download_Job):
(_Ewk_Download_Job::_Ewk_Download_Job):
(_Ewk_Download_Job::~_Ewk_Download_Job):
(ewk_download_job_destination_set):
(ewk_download_job_suggested_filename_set):
* UIProcess/API/efl/ewk_intent.cpp:
(_Ewk_Intent):
(_Ewk_Intent::_Ewk_Intent):
(_Ewk_Intent::~_Ewk_Intent):
(ewk_intent_action_get):
(ewk_intent_type_get):
(ewk_intent_service_get):
* UIProcess/API/efl/ewk_intent_service.cpp:
(_Ewk_Intent_Service):
(_Ewk_Intent_Service::_Ewk_Intent_Service):
(_Ewk_Intent_Service::~_Ewk_Intent_Service):
(ewk_intent_service_action_get):
(ewk_intent_service_type_get):
(ewk_intent_service_href_get):
(ewk_intent_service_title_get):
(ewk_intent_service_disposition_get):
* UIProcess/API/efl/ewk_navigation_policy_decision.cpp:
(_Ewk_Navigation_Policy_Decision):
(_Ewk_Navigation_Policy_Decision::_Ewk_Navigation_Policy_Decision):
(_Ewk_Navigation_Policy_Decision::~_Ewk_Navigation_Policy_Decision):
* UIProcess/API/efl/ewk_url_request.cpp:
(_Ewk_Url_Request):
(_Ewk_Url_Request::_Ewk_Url_Request):
(_Ewk_Url_Request::~_Ewk_Url_Request):
(ewk_url_request_url_get):
(ewk_request_cookies_first_party_get):
(ewk_url_request_http_method_get):
* UIProcess/API/efl/ewk_url_response.cpp:
(_Ewk_Url_Response):
(_Ewk_Url_Response::_Ewk_Url_Response):
(_Ewk_Url_Response::~_Ewk_Url_Response):
(ewk_url_response_url_get):
(ewk_url_response_mime_type_get):
* UIProcess/API/efl/ewk_view.cpp:
(_Ewk_View_Private_Data):
(_Ewk_View_Private_Data::_Ewk_View_Private_Data):
(_Ewk_View_Private_Data::~_Ewk_View_Private_Data):
(ewk_view_uri_update):
(ewk_view_title_get):
(ewk_view_theme_set):
(ewk_view_setting_encoding_custom_get):
(ewk_view_setting_encoding_custom_set):
* UIProcess/API/efl/ewk_web_error.cpp:
(_Ewk_Web_Error):
(_Ewk_Web_Error::_Ewk_Web_Error):
(_Ewk_Web_Error::~_Ewk_Web_Error):
(ewk_web_error_url_get):
(ewk_web_error_description_get):
* UIProcess/API/efl/ewk_web_resource.cpp:
(_Ewk_Web_Resource):
(_Ewk_Web_Resource::_Ewk_Web_Resource):
(_Ewk_Web_Resource::~_Ewk_Web_Resource):

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

8 years ago[WK2] Add support for Web Intents MessagePorts
commit-queue@webkit.org [Wed, 15 Aug 2012 13:03:19 +0000 (13:03 +0000)]
[WK2] Add support for Web Intents MessagePorts
https://bugs.webkit.org/show_bug.cgi?id=89072

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-08-15
Reviewed by Kenneth Rohde Christiansen.

Source/WebKit2:

Add support for WebIntents MessagePorts in WebKit2.
MessagePorts can be passed with a Web Intent in
order to open a direct communication channel
between the Web application and the intent service.

This functionality is already supported by WebKit 1.

This patch introduces a new InjectedBundleIntent
class which wraps a WebCore::Intent. This way
information regarding the MessagePorts in a Web
Intent is kept when using an injected bundle.

For the UIProcess, WebIntentData now carries
identifiers for the MessagePorts which can go over
IPC. Those identifiers map to actual MessagePorts
stored in the Web process. This way, when the UI
delivers an intent to a frame, we can get back the
corresponding MessagePorts from the Web process
before delivering the intent to the DOMWindow.

This functionality is already tested by:

- webintents/web-intents-invoke-port.html
- webintents/web-intents-obj-constructor.html

* CMakeLists.txt:
* GNUmakefile.list.am:
* Shared/API/c/WKBase.h:
* Shared/APIObject.h:
* Shared/IntentData.cpp: Add MessagePort identifiers.
(WebKit::IntentData::IntentData):
(WebKit::IntentData::encode):
(WebKit::IntentData::decode):
* Shared/IntentData.h:
(IntentData):
* Target.pri:
* UIProcess/API/C/WKIntentData.cpp: Rename WKIntentDataCopyExtra() to
WKIntentDataCopyExtraValue() for clarity.
(WKIntentDataCopyExtraValue):
* UIProcess/API/C/WKIntentData.h: Remove WKIntentDataCreate() function now
that WTR uses WKBundleIntentCreate() instead.
* UIProcess/API/efl/ewk_intent.cpp:
(ewk_intent_extra_get): Use WKIntentDataCopyExtraValue() instead of
WKIntentDataCopyExtra() since it was renamed.
* UIProcess/WebIntentData.cpp:
(WebKit::WebIntentData::WebIntentData):
(WebKit::WebIntentData::~WebIntentData): Remove MessagePorts from WebProcess upon
WebIntentData destruction.
(WebKit):
(WebKit::WebIntentData::extras):
* UIProcess/WebIntentData.h:
(WebKit):
(WebKit::WebIntentData::create):
(WebIntentData):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::didReceiveIntentForFrame):
* UIProcess/WebProcessProxy.cpp:
(WebKit):
(WebKit::WebProcessProxy::removeMessagePortChannel):
* UIProcess/WebProcessProxy.h:
(WebProcessProxy):
* WebProcess/InjectedBundle/API/c/WKBundleAPICast.h:
(WebKit):
* WebProcess/InjectedBundle/API/c/WKBundleIntent.cpp: Copied from Source/WebKit2/UIProcess/API/C/WKIntentData.cpp.
(WKBundleIntentGetTypeID):
(WKBundleIntentCreate):
(WKBundleIntentCopyAction):
(WKBundleIntentCopyType):
(WKBundleIntentCopyService):
(WKBundleIntentCopySuggestions):
(WKBundleIntentCopyExtraValue):
(WKBundleIntentCopyExtras):
(WKBundleIntentMessagePortCount):
* WebProcess/InjectedBundle/API/c/WKBundleIntent.h: Copied from Source/WebKit2/UIProcess/API/C/WKIntentData.h.
* WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.cpp:
(WKBundleIntentRequestCopyIntent):
* WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.h:
* WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
(WKBundlePageDeliverIntentToFrame):
* WebProcess/InjectedBundle/API/c/WKBundlePage.h:
* WebProcess/InjectedBundle/InjectedBundleIntent.cpp: Copied from Source/WebKit2/UIProcess/WebIntentData.cpp.
(WebKit):
(WebKit::InjectedBundleIntent::create):
(WebKit::InjectedBundleIntent::InjectedBundleIntent):
(WebKit::InjectedBundleIntent::action):
(WebKit::InjectedBundleIntent::payloadType):
(WebKit::InjectedBundleIntent::service):
(WebKit::InjectedBundleIntent::data):
(WebKit::InjectedBundleIntent::extra):
(WebKit::InjectedBundleIntent::extras):
(WebKit::InjectedBundleIntent::suggestions):
* WebProcess/InjectedBundle/InjectedBundleIntent.h: Copied from Source/WebKit2/UIProcess/WebIntentData.h.
(WebKit):
(InjectedBundleIntent):
(WebKit::InjectedBundleIntent::coreIntent):
(WebKit::InjectedBundleIntent::type):
* WebProcess/InjectedBundle/InjectedBundleIntentRequest.cpp:
(WebKit::InjectedBundleIntentRequest::intent):
* WebProcess/InjectedBundle/InjectedBundleIntentRequest.h:
(WebKit):
(InjectedBundleIntentRequest):
* WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::deliverIntent):
(WebKit):
* WebProcess/WebPage/WebFrame.h:
(WebCore):
(WebFrame):
* WebProcess/WebPage/WebPage.cpp:
(WebKit):
(WebKit::WebPage::deliverCoreIntentToFrame):
* WebProcess/WebPage/WebPage.h:
(WebCore):
(WebPage):
* WebProcess/WebProcess.cpp: Store MessagePorts in WebProcess and keep mapping with
their identifiers.
(WebKit):
(WebKit::WebProcess::addMessagePortChannel):
(WebKit::WebProcess::messagePortChannel):
(WebKit::WebProcess::removeMessagePortChannel):
* WebProcess/WebProcess.h:
(WebCore):
(WebProcess):
* WebProcess/WebProcess.messages.in:

Tools:

Use WKBundleIntent instead of WebIntentData in
WebKitTestRunner. WTR now prints the number of
MessagePorts in received Web intents as
expected by the following layout tests:
webintents/web-intents-invoke-port.html
webintents/web-intents-obj-constructor.html

* WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
(WTR::InjectedBundlePage::didReceiveIntentForFrame):
* WebKitTestRunner/InjectedBundle/LayoutTestController.cpp:
(WTR::LayoutTestController::deliverWebIntent):

LayoutTests:

Unskip webintents/web-intents-invoke-port.html and
webintents/web-intents-obj-constructor.html for
WebKit2 EFL now that information about message ports
is correctly displayed by WebKitTestRunner.

* platform/efl-wk2/TestExpectations:

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

8 years ago[EFL] Remove image expectation added for a ref test
commit-queue@webkit.org [Wed, 15 Aug 2012 12:11:29 +0000 (12:11 +0000)]
[EFL] Remove image expectation added for a ref test
https://bugs.webkit.org/show_bug.cgi?id=94090

Unreviewed gardening.

Patch by Thiago Marcos P. Santos <thiago.santos@intel.com> on 2012-08-15

* platform/efl/TestExpectations:
* platform/efl/fast/css-generated-content/quotes-lang-expected.png: Removed.

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

8 years agoWeb Inspector: [REGRESSION] "save as" of edited source in developer mode fails to...
vsevik@chromium.org [Wed, 15 Aug 2012 12:06:45 +0000 (12:06 +0000)]
Web Inspector: [REGRESSION] "save as" of edited source in developer mode fails to update saved file
https://bugs.webkit.org/show_bug.cgi?id=94074

Reviewed by Pavel Feldman.

Added dirty flag check when saving uiSourceCode to save working copy in this case.

* inspector/front-end/HandlerRegistry.js:
(WebInspector.HandlerRegistry.prototype.appendApplicableItems.save):
(WebInspector.HandlerRegistry.prototype.appendApplicableItems):

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

8 years ago[Qt] Unreviewed gardening. Add platfrom specific expected results after r125593.
kkristof@inf.u-szeged.hu [Wed, 15 Aug 2012 11:55:51 +0000 (11:55 +0000)]
[Qt] Unreviewed gardening. Add platfrom specific expected results after r125593.

Patch by Ádám Kallai <kadam@inf.u-szeged.hu> on 2012-08-15

* platform/qt-5.0-wk2/http/tests/misc/window-dot-stop-expected.txt: Added.
* platform/qt-5.0-wk2/http/tests/security/XFrameOptions/x-frame-options-deny-meta-tag-expected.txt: Added.
* platform/qt-5.0-wk2/http/tests/security/XFrameOptions/x-frame-options-deny-meta-tag-in-body-expected.txt: Added.
* platform/qt-5.0-wk2/http/tests/security/XFrameOptions/x-frame-options-deny-meta-tag-parent-same-origin-deny-expected.txt: Added.
* platform/qt-5.0-wk2/http/tests/xmlhttprequest/abort-should-cancel-load-expected.txt: Added.

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

8 years ago[Chromium Mac] Unreviewed, rebaseline after r125659.
shinyak@chromium.org [Wed, 15 Aug 2012 11:17:51 +0000 (11:17 +0000)]
[Chromium Mac] Unreviewed, rebaseline after r125659.

* fast/dom/HTMLMeterElement/meter-writing-mode-expected.txt: Renamed from LayoutTests/platform/efl/fast/dom/HTMLMeterElement/meter-writing-mode-expected.txt.
* platform/chromium-mac/fast/dom/HTMLMeterElement/meter-styles-changing-pseudo-expected.txt:
* platform/chromium-mac/fast/dom/HTMLMeterElement/meter-writing-mode-expected.txt:
* platform/chromium-win-xp/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.txt:
* platform/gtk/fast/dom/HTMLMeterElement/meter-writing-mode-expected.txt: Removed.

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

8 years ago[Chromium] Roll WebKit Chromium DEPS to r151672
peter@chromium.org [Wed, 15 Aug 2012 11:02:00 +0000 (11:02 +0000)]
[Chromium] Roll WebKit Chromium DEPS to r151672
https://bugs.webkit.org/show_bug.cgi?id=94091

Unreviewed DEPS roll.

This also adds the new dependency on third_party/skia/gyp/, as was
introduced in Chromium's revision 151463.

* DEPS:

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

8 years ago[Qt] Unreviewed gardening after r125659.
ossy@webkit.org [Wed, 15 Aug 2012 10:45:51 +0000 (10:45 +0000)]
[Qt] Unreviewed gardening after r125659.

* platform/qt/Skipped: Skip new tests because of disabled SHADOW_DOM
* platform/qt/fast/dom/HTMLMeterElement/meter-boundary-values-expected.png:
* platform/qt/fast/dom/HTMLMeterElement/meter-boundary-values-expected.txt:
* platform/qt/fast/dom/HTMLMeterElement/meter-element-expected.txt: Added.
* platform/qt/fast/dom/HTMLMeterElement/meter-element-repaint-on-update-value-expected.txt: Added.
* platform/qt/fast/dom/HTMLMeterElement/meter-optimums-expected.png:
* platform/qt/fast/dom/HTMLMeterElement/meter-optimums-expected.txt:
* platform/qt/fast/dom/HTMLMeterElement/meter-styles-changing-pseudo-expected.png:
* platform/qt/fast/dom/HTMLMeterElement/meter-styles-changing-pseudo-expected.txt:
* platform/qt/fast/dom/HTMLMeterElement/meter-styles-expected.png:
* platform/qt/fast/dom/HTMLMeterElement/meter-styles-expected.txt:
* platform/qt/fast/dom/HTMLMeterElement/meter-writing-mode-expected.txt:

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

8 years agoRelative units are not set when the canvas has not parent
commit-queue@webkit.org [Wed, 15 Aug 2012 10:27:18 +0000 (10:27 +0000)]
Relative units are not set when the canvas has not parent
https://bugs.webkit.org/show_bug.cgi?id=93840

Patch by Thiago Marcos P. Santos <thiago.santos@intel.com> on 2012-08-15
Reviewed by Kenneth Rohde Christiansen.

Source/WebCore:

Set the default font when no parent style is set. It will make
possible to apply relative units when a parent is not set.

No new tests, unskipped the existing ones.

* css/StyleBuilder.cpp:
(WebCore::ApplyPropertyFontSize::applyValue):
Make it possible to apply relative units if a parent style exist but
not a parent node. It works like this for em and ex, but not for
percent units.
* html/canvas/CanvasRenderingContext2D.cpp:
(WebCore):
(WebCore::CanvasRenderingContext2D::setFont):

LayoutTests:

Unskipped tests that will now pass, removed wrong expectations
and updated test case which was fixed by the W3C.

* canvas/philip/tests/2d.text.font.parse.size.percentage.default.html:
This test case was fixed on W3C upstream:
https://www.w3.org/Bugs/Public/show_bug.cgi?id=18522
* fast/canvas/canvas-font-ex-units-crash-expected.txt:
* fast/canvas/script-tests/canvas-font-ex-units-crash.js:
* platform/chromium/TestExpectations:
* platform/chromium/canvas/philip/tests/2d.text.font.parse.size.percentage-expected.txt: Removed.
* platform/chromium/canvas/philip/tests/2d.text.font.parse.size.percentage.default-expected.txt: Removed.
* platform/efl/Skipped:
* platform/gtk/TestExpectations:
* platform/mac/TestExpectations:
* platform/mac/canvas/philip/tests/2d.text.font.parse.size.percentage-expected.txt: Removed.
* platform/mac/canvas/philip/tests/2d.text.font.parse.size.percentage.default-expected.txt: Removed.
* platform/qt/Skipped:

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

8 years ago[Qt] Unreviewd gardening. Readd removed expectations in r125658 with some modification.
ossy@webkit.org [Wed, 15 Aug 2012 10:15:57 +0000 (10:15 +0000)]
[Qt] Unreviewd gardening. Readd removed expectations in r125658 with some modification.

Patch by Zoltan Arvai <zarvai@inf.u-szeged.hu> on 2012-08-15

* platform/qt/http/tests/security/aboutBlank/xss-DENIED-navigate-opener-document-write-expected.txt: Added.
* platform/qt/http/tests/security/aboutBlank/xss-DENIED-set-opener-expected.txt: Added.

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

8 years agoWeb Inspector: split standalone test runner, test scanner and test stub.
pfeldman@chromium.org [Wed, 15 Aug 2012 10:10:11 +0000 (10:10 +0000)]
Web Inspector: split standalone test runner, test scanner and test stub.
https://bugs.webkit.org/show_bug.cgi?id=94001

Reviewed by Vsevolod Vlasov.

Source/WebCore:

This change starts sending loacCompleted message to the embedder.

* inspector/front-end/InspectorFrontendAPI.js:
(InspectorFrontendAPI.loadCompleted):
* inspector/front-end/test-runner.html: Added.

LayoutTests:

This change allows opening a) test runner, b) layout tests and c) inspector front-end off different
hosts. It is one more step towards extension-driven runner.

* http/tests/inspector/inspector-test.js:
* http/tests/inspector/resources/test-runner.html: Removed.
* http/tests/inspector/resources/test-scanner.html: Added.

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

8 years ago[Refactoring] The debug version and release version of toHTMLSelectElement can be...
shinyak@chromium.org [Wed, 15 Aug 2012 09:51:56 +0000 (09:51 +0000)]
[Refactoring] The debug version and release version of toHTMLSelectElement can be merged without any penalty
https://bugs.webkit.org/show_bug.cgi?id=94084

Reviewed by Kent Tamura.

We have two versions of toHTMLSelectElement. One has ASSERT() and the other one does not have ASSERT().
We can merge them without any penalty.

No new tests, no change in behavior.

* html/HTMLSelectElement.cpp:
* html/HTMLSelectElement.h:
(WebCore::isHTMLSelectElement):
(WebCore::toHTMLSelectElement):
(WebCore):

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

8 years agoAuthorShadowDOM for meter element
shinyak@chromium.org [Wed, 15 Aug 2012 09:37:32 +0000 (09:37 +0000)]
AuthorShadowDOM for meter element
https://bugs.webkit.org/show_bug.cgi?id=91970

Reviewed by Hajime Morita.

Source/WebCore:

We add support for AuthorShadowDOM for a meter element.

According to the Shadow DOM spec, a meter element should behave like having a UserAgentShadowRoot and
an element in UserAgentShadowRoot draws a real 'meter' bar. In this patch, we change the inner structure
of a meter element so that we can distribute an element having RenderMeter to AuthorShadowDOM.

Before this patch, a meter element has the following inner structure.

    <meter>--UserAgentShadowRoot -- -- -- -- -- -- -- -- -- -- AuthorShadowRoot
                       |
                       +-- MeterBarElement
                       |
                       +-- MeterValueElement

After this patch, a meter element will have the following inner structure.

    <meter>--UserAgentShadowRoot -- -- -- -- -- -- -- -- -- -- AuthorShadowRoot
                       |
                       +-- MeterInnerElement
                                   |
                                   +-- MeterBarElement
                                   |
                                   +-- MeterValueElement

However, if RenderTheme supports rendering meter, MeterInnerElement will not create a renderer
unless an AuthorShadowDOM is attached to it so that we can keep the current rendering style.

Tests: fast/dom/shadow/shadowdom-for-meter-dynamic.html
       fast/dom/shadow/shadowdom-for-meter-multiple.html
       fast/dom/shadow/shadowdom-for-meter-with-style.html
       fast/dom/shadow/shadowdom-for-meter-without-appearance.html
       fast/dom/shadow/shadowdom-for-meter-without-shadow-element.html
       fast/dom/shadow/shadowdom-for-meter.html

* css/html.css:
(meter): Changed the display type. inline-box is not supported WebKit. inline-block is true.
(meter::-webkit-meter-inner-element):
* html/HTMLMeterElement.cpp:
(WebCore::HTMLMeterElement::HTMLMeterElement):
(WebCore::HTMLMeterElement::createRenderer):
(WebCore):
(WebCore::HTMLMeterElement::attach): Added didElementStateChange.
(WebCore::HTMLMeterElement::didElementStateChange):
(WebCore::HTMLMeterElement::willAddAuthorShadowRoot):
(WebCore::HTMLMeterElement::renderMeter):
(WebCore::HTMLMeterElement::createShadowSubtree):
* html/HTMLMeterElement.h:
(WebCore):
(WebCore::HTMLMeterElement::hasAuthorShadowRoot):
(HTMLMeterElement):
(WebCore::isHTMLMeterElement):
(WebCore::toHTMLMeterElement):
* html/shadow/MeterShadowElement.cpp:
(WebCore::MeterShadowElement::meterElement):
(WebCore::MeterShadowElement::rendererIsNeeded):
(WebCore):
(WebCore::MeterInnerElement::MeterInnerElement): We introduce a new element having RenderMeter
so that we can distribute an element having RenderMeter to AuthorShadowDOM.
(WebCore::MeterInnerElement::rendererIsNeeded): Different from a progress element, meter element will not be
rendered using a theme. So we don't need to check the style appearance.
(WebCore::MeterInnerElement::createRenderer):
(WebCore::MeterInnerElement::shadowPseudoId):
* html/shadow/MeterShadowElement.h:
(WebCore):
(MeterInnerElement):
(WebCore::MeterInnerElement::create):
* rendering/RenderMeter.cpp:
(WebCore::RenderMeter::RenderMeter):
(WebCore::RenderMeter::meterElement):
(WebCore):
(WebCore::RenderMeter::valueRatio):
* rendering/RenderMeter.h:
(RenderMeter):
* rendering/RenderThemeMac.mm:
(WebCore::RenderThemeMac::levelIndicatorFor):

LayoutTests:

Contains the following tests:
  (1) meter element with AuthorShadowDOM
  (2) meter element with multiple AuthorShadowDOM with a shadow element
  (3) meter element with multiple AuthorShadowDOM without a shadow element
  (4) meter element with AuthorShadowDOM with dynamic value update
  (5) meter element with AuthorShadowDOM with style
  (6) meter element with AuthorShadowDOM with -webkit-appearance: none

* fast/dom/HTMLMeterElement/meter-clone-expected.txt:
* fast/dom/HTMLMeterElement/meter-clone.html:
* fast/dom/HTMLMeterElement/meter-element-markup-expected.txt:
* fast/dom/shadow/resources/replaced-element-styles.css:
(.meter-like):
(.meter-inner-element-like):
* fast/dom/shadow/shadowdom-for-meter-dynamic-expected.html: Added.
* fast/dom/shadow/shadowdom-for-meter-dynamic.html: Added.
* fast/dom/shadow/shadowdom-for-meter-expected.html: Added.
* fast/dom/shadow/shadowdom-for-meter-multiple-expected.html: Added.
* fast/dom/shadow/shadowdom-for-meter-multiple.html: Added.
* fast/dom/shadow/shadowdom-for-meter-with-style-expected.html: Added.
* fast/dom/shadow/shadowdom-for-meter-with-style.html: Added.
* fast/dom/shadow/shadowdom-for-meter-without-appearance-expected.html: Added.
* fast/dom/shadow/shadowdom-for-meter-without-appearance.html: Added.
* fast/dom/shadow/shadowdom-for-meter-without-shadow-element-expected.html: Added.
* fast/dom/shadow/shadowdom-for-meter-without-shadow-element.html: Added.
* fast/dom/shadow/shadowdom-for-meter.html: Added.
* platform/chromium-win/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.txt:
* platform/chromium-win/fast/dom/HTMLMeterElement/meter-appearances-rating-relevancy-expected.txt:
* platform/chromium-win/fast/dom/HTMLMeterElement/meter-boundary-values-expected.txt:
* platform/chromium-win/fast/dom/HTMLMeterElement/meter-element-expected.txt:
* platform/chromium-win/fast/dom/HTMLMeterElement/meter-element-repaint-on-update-value-expected.txt:
* platform/chromium-win/fast/dom/HTMLMeterElement/meter-optimums-expected.txt:
* platform/chromium-win/fast/dom/HTMLMeterElement/meter-styles-changing-pseudo-expected.txt:
* platform/chromium-win/fast/dom/HTMLMeterElement/meter-styles-expected.txt:
* platform/chromium-win/fast/dom/HTMLMeterElement/meter-writing-mode-expected.txt:
* platform/mac/TestExpectations:

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

8 years ago[Qt] Unreviwed gardening. Skip failing tests and remove obsolete test expectations.
kkristof@inf.u-szeged.hu [Wed, 15 Aug 2012 09:00:38 +0000 (09:00 +0000)]
[Qt] Unreviwed gardening. Skip failing tests and remove obsolete test expectations.
https://bugs.webkit.org/show_bug.cgi?id=94076

Patch by Zoltan Arvai <zarvai@inf.u-szeged.hu> on 2012-08-15

* platform/qt/Skipped: skip fast/events/autoscroll-in-textarea.html.
* platform/qt/http/tests/security/aboutBlank/xss-DENIED-navigate-opener-document-write-expected.txt: Removed after r125615.
* platform/qt/http/tests/security/aboutBlank/xss-DENIED-set-opener-expected.txt: Removed after r125615.

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

8 years agoUnreviewed GTK gardening.
zandobersek@gmail.com [Wed, 15 Aug 2012 08:41:30 +0000 (08:41 +0000)]
Unreviewed GTK gardening.

Adding image failure expectation for fast/overflow/line-clamp-and-columns.html,
the reftest is failing since it was introduced in r125635.

Skipping media/video-controls-fullscreen-volume.html for the moment after
it's been failing since introduced in r125590, the failure is probably expected
and will be marked as WONTFIX when confirmed.

Marking fast/js/random-array-gc-stress.html as a flaky crasher. The crashing
occurs due to parallel GC being enabled.

* platform/gtk/TestExpectations:

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

8 years ago[Chromium] fast/dom/Window/dom-access-from-closure-window.html is flaky on Linux
abarth@webkit.org [Wed, 15 Aug 2012 08:26:06 +0000 (08:26 +0000)]
[Chromium] fast/dom/Window/dom-access-from-closure-window.html is flaky on Linux
https://bugs.webkit.org/show_bug.cgi?id=94060

Reviewed by Kentaro Hara.

Source/WebCore:

Previously, the V8 garbage collector might have collected the Document
wrapper before the DOMWindow wrapper because we overwrite the
"document" property of the DOMWindow during navigation.

This patch adds a hidden document property on the global object to
ensure that the Document wrapper lives at least as long as the
DOMWindow wrapper, ensuring that DOMWindows that we obtain from V8
always have non-null Document objects.

The JavaScriptCore bindings already have this behavior.

Test: fast/dom/Window/dom-access-from-closure-window-with-gc.html

* bindings/v8/V8DOMWindowShell.cpp:
(WebCore::V8DOMWindowShell::updateDocumentWrapperCache):
* bindings/v8/V8HiddenPropertyName.h:
(WebCore):

LayoutTests:

Ensure that collecting garbage doesn't change the behavior of this test
(compared with dom-access-from-closure-window.html).

* fast/dom/Window/dom-access-from-closure-window-with-gc-expected.txt: Added.
* fast/dom/Window/dom-access-from-closure-window-with-gc.html: Added.

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

8 years ago[Chromium] Unreviewed. Add one more flaky test to test expectations.
yutak@chromium.org [Wed, 15 Aug 2012 08:17:24 +0000 (08:17 +0000)]
[Chromium] Unreviewed. Add one more flaky test to test expectations.

* platform/chromium/TestExpectations:

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

8 years agoWeb Inspector: Calling getEventListeners() on element with malformed javascript event...
caseq@chromium.org [Wed, 15 Aug 2012 08:10:30 +0000 (08:10 +0000)]
Web Inspector: Calling getEventListeners() on element with malformed javascript event listeners crashes
https://bugs.webkit.org/show_bug.cgi?id=93937

Reviewed by Pavel Feldman.

Source/WebCore:

- check listener function to be non-null (happens upon an exception while compiling attribute listeners)

* bindings/js/JSInjectedScriptHostCustom.cpp:
(WebCore::getJSListenerFunctions):
* bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
(WebCore::getJSListenerFunctions):

LayoutTests:

- added test for crash on invalid syntax in an attribute JS listener;
- added custom expectation for chrome due to JS error logged to console by JSC while compiling attribute listener;

* inspector/console/command-line-api-getEventListeners-expected.txt:
* inspector/console/command-line-api-getEventListeners.html:
* platform/chromium/inspector/console/command-line-api-getEventListeners-expected.txt: Copied from LayoutTests/inspector/console/command-line-api-getEventListeners-expected.txt.

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

8 years ago[EFL] Update expectations for canvas/philip tests that require space collapsing
commit-queue@webkit.org [Wed, 15 Aug 2012 07:14:09 +0000 (07:14 +0000)]
[EFL] Update expectations for canvas/philip tests that require space collapsing
https://bugs.webkit.org/show_bug.cgi?id=94072

Unreviewed EFL gardening.

Move canvas/philip tests that require space collapsing
from Skipped file to TestExpectations and indicate
that the tests are outdated with corresponding bug
number.

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-08-15

* platform/efl/Skipped:
* platform/efl/TestExpectations:

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

8 years ago[Chromium] Unreviewed test expectations update. Tests named dfg-*array.html are
yutak@chromium.org [Wed, 15 Aug 2012 07:06:13 +0000 (07:06 +0000)]
[Chromium] Unreviewed test expectations update. Tests named dfg-*array.html are
known to be slow on debug bots.

* platform/chromium/TestExpectations:

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

8 years agoBuild fix after r125516. Revert the erroneous rename since we need to keep exposing
rniwa@webkit.org [Wed, 15 Aug 2012 06:28:00 +0000 (06:28 +0000)]
Build fix after r125516. Revert the erroneous rename since we need to keep exposing
layoutTestController in Chromium port as explained r124785.

* DumpRenderTree/chromium/TestShell.cpp:
(TestShell::bindJSObjectsToWindow):

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

8 years agoWeb Inspector: CodeMirrorTextEditor doesn't clear execution line
commit-queue@webkit.org [Wed, 15 Aug 2012 06:25:36 +0000 (06:25 +0000)]
Web Inspector: CodeMirrorTextEditor doesn't clear execution line
https://bugs.webkit.org/show_bug.cgi?id=94069

Patch by Jan Keromnes <janx@linux.com> on 2012-08-14
Reviewed by Pavel Feldman.

Make CodeMirrorTextEditor use line handles instead of numbers, remove
typeof == "number" checks.

* inspector/front-end/CodeMirrorTextEditor.js:
(WebInspector.CodeMirrorTextEditor.prototype.clearExecutionLine):
(WebInspector.CodeMirrorTextEditor.prototype.highlightLine):
(WebInspector.CodeMirrorTextEditor.prototype.clearLineHighlight):

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

8 years agoUnreviewed. Fix Chromium-Android builds.
yutak@chromium.org [Wed, 15 Aug 2012 05:53:18 +0000 (05:53 +0000)]
Unreviewed. Fix Chromium-Android builds.

* html/TimeInputType.cpp:
(WebCore::TimeInputType::TimeInputType):
Declare the function as a constructor.

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

8 years agoText selection in text area in auto scroll mode goes wrong.
commit-queue@webkit.org [Wed, 15 Aug 2012 05:20:45 +0000 (05:20 +0000)]
Text selection in text area in auto scroll mode goes wrong.
https://bugs.webkit.org/show_bug.cgi?id=74346

Patch by Sukolsak Sakshuwong <sukolsak@google.com> on 2012-08-14
Reviewed by Ojan Vafai.

Source/WebCore:

WebKit triggers autoscroll in text area when the user drags the cursor from inside
the text area to the outside. When that happens, it gets the local cursor position
relative to the node under the cursor from hit-testing, converts it to
the absolute position, and then converts it to the local position relative to the
text area. However, the hit-testing method of text area did not take scrolling
offset into account. This caused it to give an incorrect value of the local cursor
position. Make the hit-testing take scrolling offset into account.

Test: fast/events/autoscroll-in-textarea.html

* html/shadow/TextControlInnerElements.cpp:
(WebCore::TextControlInnerTextElement::createRenderer):
* rendering/RenderTextControl.cpp:
(WebCore::RenderTextControl::hitInnerTextElement):
* rendering/RenderTextControlSingleLine.cpp:
(WebCore):
* rendering/RenderTextControlSingleLine.h:
(WebCore::RenderTextControlInnerBlock::RenderTextControlInnerBlock):
(WebCore::RenderTextControlInnerBlock::hasLineIfEmpty):

LayoutTests:

* fast/events/autoscroll-in-textarea-expected.txt: Added.
* fast/events/autoscroll-in-textarea.html: Added.

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

8 years ago[Chromium] Unreviewed. Remove obsolete test expectations, and mark
yutak@chromium.org [Wed, 15 Aug 2012 05:07:00 +0000 (05:07 +0000)]
[Chromium] Unreviewed. Remove obsolete test expectations, and mark
slow tests as such.

* platform/chromium/TestExpectations:

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

8 years ago[Refactoring] RenderMenuList and RenderListBox should have a method to return HTMLSel...
shinyak@chromium.org [Wed, 15 Aug 2012 04:02:17 +0000 (04:02 +0000)]
[Refactoring] RenderMenuList and RenderListBox should have a method to return HTMLSelectElement.
https://bugs.webkit.org/show_bug.cgi?id=94061

Reviewed by Kent Tamura.

This is a preparation patch for Bug 91487. Since RenderMenuList::node() and RenderListBox::node()
will not return HTMLSelectElement to fix Bug 91487, it would be good to have a method to HTMLSelectElement.

No new tests, no change in behavior.

* rendering/RenderListBox.cpp:
(WebCore::RenderListBox::selectElement):
(WebCore):
(WebCore::RenderListBox::updateFromElement):
(WebCore::RenderListBox::scrollToRevealSelection):
(WebCore::RenderListBox::size):
(WebCore::RenderListBox::numItems):
(WebCore::RenderListBox::addFocusRingRects):
(WebCore::RenderListBox::paintItemForeground):
(WebCore::RenderListBox::paintItemBackground):
(WebCore::RenderListBox::panScroll):
(WebCore::RenderListBox::autoscroll):
(WebCore::RenderListBox::stopAutoscroll):
(WebCore::RenderListBox::valueChanged):
(WebCore::RenderListBox::nodeAtPoint):
* rendering/RenderListBox.h:
(WebCore):
(RenderListBox):
* rendering/RenderMenuList.cpp:
(WebCore::RenderMenuList::selectElement):
(WebCore):
(WebCore::RenderMenuList::updateOptionsWidth):
(WebCore::RenderMenuList::updateFromElement):
(WebCore::RenderMenuList::setTextFromOption):
(WebCore::RenderMenuList::showPopup):
(WebCore::RenderMenuList::valueChanged):
(WebCore::RenderMenuList::listBoxSelectItem):
(WebCore::RenderMenuList::multiple):
(WebCore::RenderMenuList::didSetSelectedIndex):
(WebCore::RenderMenuList::didUpdateActiveOption):
(WebCore::RenderMenuList::itemText):
(WebCore::RenderMenuList::itemAccessibilityText):
(WebCore::RenderMenuList::itemToolTip):
(WebCore::RenderMenuList::itemIsEnabled):
(WebCore::RenderMenuList::itemStyle):
(WebCore::RenderMenuList::itemBackgroundColor):
(WebCore::RenderMenuList::listSize):
(WebCore::RenderMenuList::selectedIndex):
(WebCore::RenderMenuList::itemIsSeparator):
(WebCore::RenderMenuList::itemIsLabel):
(WebCore::RenderMenuList::itemIsSelected):
(WebCore::RenderMenuList::setTextFromItem):
* rendering/RenderMenuList.h:
(WebCore):
(RenderMenuList):

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

8 years agoFileWriter fails with assertion when trying to write empty Blob
kinuko@chromium.org [Wed, 15 Aug 2012 04:00:39 +0000 (04:00 +0000)]
FileWriter fails with assertion when trying to write empty Blob
https://bugs.webkit.org/show_bug.cgi?id=93694

Reviewed by Kent Tamura.

if the given data size is zero (i.e. m_bytesToWrite is zero) the assertion 'bytes + m_bytesWritten > 0' should not be tested.

Source/WebCore:

Tests: fast/filesystem/file-writer-empty-blob.html
       fast/filesystem/workers/file-writer-empty-blob.html

* Modules/filesystem/FileWriter.cpp:
(WebCore::FileWriter::didWrite):

LayoutTests:

* fast/filesystem/file-writer-empty-blob-expected.txt: Added.
* fast/filesystem/file-writer-empty-blob.html: Added.
* fast/filesystem/resources/file-writer-empty-blob.js: Added.
* fast/filesystem/workers/file-writer-empty-blob-expected.txt: Added.
* fast/filesystem/workers/file-writer-empty-blob.html: Added.

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

8 years ago[Chromium] Unreviewed, another gardening. Add one slow test.
yutak@chromium.org [Wed, 15 Aug 2012 03:45:05 +0000 (03:45 +0000)]
[Chromium] Unreviewed, another gardening. Add one slow test.

* platform/chromium/TestExpectations:

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

8 years agoShare common code between calendar picker and color suggestion picker
keishi@webkit.org [Wed, 15 Aug 2012 03:34:14 +0000 (03:34 +0000)]
Share common code between calendar picker and color suggestion picker
https://bugs.webkit.org/show_bug.cgi?id=93802

Reviewed by Kent Tamura.

.:

* ManualTests/forms/calendar-picker.html:
* ManualTests/forms/color-suggestion-picker.html:

Source/WebCore:

We want to share common code like utility functions between picker page popups.

No new tests because no behavior change. Covered by existing tests, color-suggestion-picker-appearance.html and calendar-picker-apeparance.html.

* Resources/pagepopups/calendarPicker.js:
(YearMonthController.prototype.attachTo):
(YearMonthController.prototype._showPopup):
* Resources/pagepopups/colorSuggestionPicker.js:
(handleMessage):
(handleArgumentsTimeout):
* Resources/pagepopups/pickerCommon.css: Added.
(body):
* Resources/pagepopups/pickerCommon.js: Added.
(createElement):
(resizeWindow):
(getScrollbarWidth):
* WebCore.gyp/WebCore.gyp: Add actions for pickerCommon.{css,js}
* html/shadow/CalendarPickerElement.cpp:
(WebCore::CalendarPickerElement::writeDocument):

Source/WebKit/chromium:

* src/ColorChooserUIController.cpp:
(WebKit::ColorChooserUIController::writeDocument):

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

8 years ago[Chromium] Unreviewed. Add new test expectation for nested-rounded-corners.html.
yutak@chromium.org [Wed, 15 Aug 2012 03:24:55 +0000 (03:24 +0000)]
[Chromium] Unreviewed. Add new test expectation for nested-rounded-corners.html.

* platform/chromium/TestExpectations:

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

8 years agoUnreviewed, build fix for !ENABLE(DFG_JIT)
fpizlo@apple.com [Wed, 15 Aug 2012 03:10:57 +0000 (03:10 +0000)]
Unreviewed, build fix for !ENABLE(DFG_JIT)

* jit/JITPropertyAccess.cpp:
(JSC::JIT::emit_op_get_by_val):
(JSC::JIT::emit_op_put_by_val):
(JSC::JIT::privateCompilePatchGetArrayLength):
* jit/JITPropertyAccess32_64.cpp:
(JSC::JIT::emit_op_get_by_val):
(JSC::JIT::emit_op_put_by_val):
(JSC::JIT::privateCompilePatchGetArrayLength):
* llint/LowLevelInterpreter32_64.asm:
* llint/LowLevelInterpreter64.asm:

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

8 years agofast/events/overflow-scroll-fake-mouse-move.html and fast/events/frame-scroll-fake...
mitz@apple.com [Wed, 15 Aug 2012 02:52:20 +0000 (02:52 +0000)]
fast/events/overflow-scroll-fake-mouse-move.html and fast/events/frame-scroll-fake-mouse-move.html are failing in WebKit1
https://bugs.webkit.org/show_bug.cgi?id=94045

Reviewed by Geoff Garen.

* DumpRenderTree/mac/DumpRenderTreeWindow.mm:
(-[DumpRenderTreeWindow _hasKeyAppearance]): Added. Returns [self isKeyWindow]. This is
needed now that WebView uses -_hasKeyAppearance instead of -isKeyWindow.

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

8 years agoArray checks should use the structure, not the class info
fpizlo@apple.com [Wed, 15 Aug 2012 02:48:35 +0000 (02:48 +0000)]
Array checks should use the structure, not the class info
https://bugs.webkit.org/show_bug.cgi?id=93150

Reviewed by Mark Hahnenberg.

This changes all array checks used in array accesses (get, put, get length,
push, pop) to use the structure, not the class info. Additionally, these
checks in the LLInt and baseline JIT record the structure in an ArrayProfile,
so that the DFG can know exactly what structure to check for.

* CMakeLists.txt:
* GNUmakefile.list.am:
* JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj:
* JavaScriptCore.xcodeproj/project.pbxproj:
* Target.pri:
* bytecode/ArrayProfile.cpp: Added.
(JSC):
(JSC::ArrayProfile::computeUpdatedPrediction):
* bytecode/ArrayProfile.h: Added.
(JSC):
(JSC::arrayModeFromStructure):
(ArrayProfile):
(JSC::ArrayProfile::ArrayProfile):
(JSC::ArrayProfile::bytecodeOffset):
(JSC::ArrayProfile::addressOfLastSeenStructure):
(JSC::ArrayProfile::observeStructure):
(JSC::ArrayProfile::expectedStructure):
(JSC::ArrayProfile::structureIsPolymorphic):
(JSC::ArrayProfile::hasDefiniteStructure):
(JSC::ArrayProfile::observedArrayModes):
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::dump):
(JSC::CodeBlock::getArrayProfile):
(JSC):
(JSC::CodeBlock::getOrAddArrayProfile):
(JSC::CodeBlock::updateAllPredictionsAndCountLiveness):
* bytecode/CodeBlock.h:
(JSC::CodeBlock::executionEntryCount):
(JSC::CodeBlock::numberOfArrayProfiles):
(JSC::CodeBlock::arrayProfiles):
(JSC::CodeBlock::addArrayProfile):
(CodeBlock):
* bytecode/Instruction.h:
(JSC):
(JSC::Instruction::Instruction):
* bytecode/Opcode.h:
(JSC):
(JSC::padOpcodeName):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::emitGetArgumentByVal):
(JSC::BytecodeGenerator::emitGetByVal):
(JSC::BytecodeGenerator::emitPutByVal):
* dfg/DFGAbstractState.cpp:
(JSC::DFG::AbstractState::initialize):
(JSC::DFG::AbstractState::execute):
* dfg/DFGAbstractValue.h:
(JSC::DFG::StructureAbstractValue::hasSingleton):
(StructureAbstractValue):
(JSC::DFG::StructureAbstractValue::singleton):
* dfg/DFGArgumentsSimplificationPhase.cpp:
(JSC::DFG::ArgumentsSimplificationPhase::run):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::parseBlock):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::speculateArray):
(DFG):
(JSC::DFG::SpeculativeJIT::compile):
(JSC::DFG::SpeculativeJIT::checkArgumentTypes):
(JSC::DFG::SpeculativeJIT::compileGetIndexedPropertyStorage):
* dfg/DFGSpeculativeJIT.h:
(SpeculativeJIT):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGStructureCheckHoistingPhase.cpp:
(JSC::DFG::StructureCheckHoistingPhase::run):
* jit/JITPropertyAccess.cpp:
(JSC::JIT::emit_op_get_by_val):
(JSC::JIT::emit_op_put_by_val):
(JSC::JIT::privateCompilePatchGetArrayLength):
* jit/JITPropertyAccess32_64.cpp:
(JSC::JIT::emit_op_get_by_val):
(JSC::JIT::emit_op_put_by_val):
(JSC::JIT::privateCompilePatchGetArrayLength):
* llint/LLIntOffsetsExtractor.cpp:
* llint/LowLevelInterpreter32_64.asm:
* llint/LowLevelInterpreter64.asm:
* runtime/Structure.h:
(Structure):
(JSC::Structure::classInfoOffset):

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

8 years ago[Chromium] Unreviewed test expectation update. Address new flakiness
yutak@chromium.org [Wed, 15 Aug 2012 02:33:41 +0000 (02:33 +0000)]
[Chromium] Unreviewed test expectation update. Address new flakiness
and slow tests.

* platform/chromium/TestExpectations:

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

8 years agoFix access to m_markupBox in WebCore::EllipsisBox::paint
ojan@chromium.org [Wed, 15 Aug 2012 02:14:23 +0000 (02:14 +0000)]
Fix access to m_markupBox in WebCore::EllipsisBox::paint
https://bugs.webkit.org/show_bug.cgi?id=91138

Reviewed by Abhishek Arya.

Source/WebCore:

EllipsisBox would hold on to m_markupBox, which would then get destroyed during
the followup layoutIfNeeded in layoutVerticalBox. Instead, have EllipsisBox
dynamically grab to pointer to the markup box during paint since there's no
straightforward way to notify the EllipsisBox that the markupBox has been destroyed
and/or point it at the new markupBox.

Test: fast/overflow/line-clamp-and-columns.html

* rendering/EllipsisBox.cpp:
(WebCore::EllipsisBox::paint):
(WebCore):
(WebCore::EllipsisBox::paintMarkupBox):
* rendering/EllipsisBox.h:
(WebCore::EllipsisBox::EllipsisBox):
Just store a boolean that we have a markup box that needs painting.
* rendering/RenderDeprecatedFlexibleBox.cpp:
(WebCore::RenderDeprecatedFlexibleBox::applyLineClamp):
Clearing the override size right after setting it was incorrect because
there are cases where we'll do a followup layout in layoutVerticalBox, at which
point we'll still need the override size.
(WebCore::RenderDeprecatedFlexibleBox::clearLineClamp):
Clear the override size here to handle cases where line clamp is removed since
we don't call applyLineClamp in those cases.

LayoutTests:

* fast/overflow/line-clamp-and-columns-expected.html: Added.
* fast/overflow/line-clamp-and-columns.html: Added.

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

8 years ago[Forms] Make input type "time" to use multiple field time input UI
yosin@chromium.org [Wed, 15 Aug 2012 02:08:02 +0000 (02:08 +0000)]
[Forms] Make input type "time" to use multiple field time input UI
https://bugs.webkit.org/show_bug.cgi?id=93929

Reviewed by Kent Tamura.

Source/WebCore:

This patch changes input type "time" UI to use multiple field time
input UI when build flag ENABLE_INPUT_TYPE_TIME_MULTIPLE_FIELDS
enabled.

No new tests. This patch doesn't change behavior for users, however,
this patch changes behavior on layout tests. Tests will be added
in another patch with runtime enabled feature flag is enabled.

Test expectations for following tests are updated:
 - fast/forms/time/time-input-visible-string.html
 - fast/forms/time/time-stepup-stepdown-from-renderer.html

* html/BaseDateAndTimeInputType.h:
(BaseDateAndTimeInputType): Exposed serialize() to derived classes.
* html/TimeInputType.cpp:
(WebCore::TimeInputType::DateTimeEditControlOwnerImpl::DateTimeEditControlOwnerImpl):
(WebCore::TimeInputType::DateTimeEditControlOwnerImpl::~DateTimeEditControlOwnerImpl):
(WebCore::TimeInputType::DateTimeEditControlOwnerImpl::editControlMouseFocus):
(WebCore::TimeInputType::DateTimeEditControlOwnerImpl::editControlValueChanged):
(WebCore::TimeInputType::DateTimeEditControlOwnerImpl::isEditControlOwnerDisabled):
(WebCore::TimeInputType::DateTimeEditControlOwnerImpl::isEditControlOwnerReadOnly):
(WebCore::TimeInputType::TimeInputType):
(WebCore::TimeInputType::~TimeInputType):
(WebCore::TimeInputType::createRenderer):
(WebCore::TimeInputType::createShadowSubtree):
(WebCore::TimeInputType::destroyShadowSubtree):
(WebCore::TimeInputType::forwardEvent):
(WebCore::TimeInputType::disabledAttributeChanged):
(WebCore::TimeInputType::handleKeydownEvent):
(WebCore::TimeInputType::handleDOMActivateEvent):
(WebCore::TimeInputType::isKeyboardFocusable):
(WebCore::TimeInputType::isMouseFocusable):
(WebCore::TimeInputType::minOrMaxAttributeChanged):
(WebCore::TimeInputType::readonlyAttributeChanged):
(WebCore::TimeInputType::isTextField):
(WebCore::TimeInputType::setValue):
(WebCore::TimeInputType::shouldUseInputMethod):
(WebCore::TimeInputType::stepAttributeChanged):
(WebCore::TimeInputType::updateEditElementLayout):
(WebCore::TimeInputType::updateInnerTextValue):
(WebCore::TimeInputType):
* html/TimeInputType.h:
(TimeInputType):
(DateTimeEditControlOwnerImpl):

LayoutTests:

This patch added test expectations for multiple fields time input UI
testing which are different behavior from single field time input UI
for Chromium which enables multiple fields time input UI.

* platform/chromium/fast/forms/time/time-input-visible-string-expected.txt: Select all in a field doesn't select text.
* platform/chromium/fast/forms/time/time-stepup-stepdown-from-renderer-expected.txt: Fields don't change value on Up/Down keyboard events when they don't have focus and Up/Down keyboard increment/decrement value on hour field rather than minute field.

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

8 years agoInitial call to webkitRequestAnimationFrame returns 0, Spec indicates the handle...
dino@apple.com [Wed, 15 Aug 2012 01:51:14 +0000 (01:51 +0000)]
Initial call to webkitRequestAnimationFrame returns 0, Spec indicates the handle should always be > 0
https://bugs.webkit.org/show_bug.cgi?id=85819

Reviewed by James Robinson.

Source/WebCore:

The callback id returned by requestAnimationFrame was beginning at zero, when the spec
says it should be above one. Use a pre-increment rather than a post-increment.

Test: fast/animation/request-animation-frame-callback-id.html

* dom/ScriptedAnimationController.cpp:
(WebCore::ScriptedAnimationController::registerCallback): Pre-increment rather than post-increment.

LayoutTests:

* fast/animation/request-animation-frame-callback-id-expected.txt: Added.
* fast/animation/request-animation-frame-callback-id.html: Added.

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

8 years agor125591 broke tests with SUBPIXEL_LAYOUT disabled
leviw@chromium.org [Wed, 15 Aug 2012 01:39:20 +0000 (01:39 +0000)]
r125591 broke tests with SUBPIXEL_LAYOUT disabled
https://bugs.webkit.org/show_bug.cgi?id=94027

Reviewed by Eric Seidel.

The previous patch to fix block preferred widths for subpixel layout broke ports
without the flag enabled. This patch adds a static inline function --
adjustFloatForSubPixelLayout -- that truncates with sub-pixel layout disabled, and
ceil's to the nearest FractionalLayoutUnit when sub-pixel layout is enabled.

A block's max preferred width should be enough to layout the entire line without
wrapping. r125591 addressed a bug whereby converting floats to LayoutUnits with sub-
pixel layout enabled lost precision in certain cases, and could result in a line
being layed out to slightly over the max preferred width of the block.

This patch reverts the behavior when sub-pixel layout is disabled to truncating
sub-pixel values (such as those that originate in Length) when assigning them to
LayoutUnits, and ceiling the length of the entire line to the next largest integer.

Covered by existing tests.

* rendering/RenderBlock.cpp:
(WebCore):
(WebCore::adjustFloatForSubPixelLayout):
(WebCore::RenderBlock::computeInlinePreferredLogicalWidths):

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

8 years agoHandle the XPath / (root) operator correctly for nodes that aren't attached to the...
cevans@google.com [Wed, 15 Aug 2012 01:28:54 +0000 (01:28 +0000)]
Handle the XPath / (root) operator correctly for nodes that aren't attached to the document.
https://bugs.webkit.org/show_bug.cgi?id=36427

Reviewed by Abhishek Arya.

Source/WebCore:

We now behave the same as Firefox 14.
The consensus seems to be that the XPath spec is ambiguous for the case of detached nodes, and that using the fragment root is more intuitive than the document root for the case of detached nodes.
For example, http://www.w3.org/TR/xpath/ section 2 "Location Paths" is only clear for attached nodes: "A / by itself selects the root node of the document containing the context node. If it is followed by a relative location path, then the location path selects the set of nodes that would be selected by the relative location path relative to the root node of the document containing the context node."

Test: fast/xpath/xpath-detached-nodes.html

* xml/XPathPath.cpp:
(WebCore::XPath::LocationPath::evaluate): Jump to the root of the detached subtree instead of the parent document if the node isn't attached to the document.

LayoutTests:

* fast/xpath/xpath-detached-nodes-expected.txt: Added.
* fast/xpath/xpath-detached-nodes.html: Added.

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

8 years ago[CSS Shaders][Chromium] Filters area applied twice when CustomFilterOperation is...
achicu@adobe.com [Wed, 15 Aug 2012 01:21:47 +0000 (01:21 +0000)]
[CSS Shaders][Chromium] Filters area applied twice when CustomFilterOperation is in the list
https://bugs.webkit.org/show_bug.cgi?id=93900

Reviewed by James Robinson.

Source/WebCore:

Whenever the platform cannot render a shader in hardware it will fallback to software.
In such cases, the platform should remove any old filters applied, so that the filters do not apply twice.

Test: css3/filters/custom/filter-fallback-to-software.html

* platform/graphics/chromium/GraphicsLayerChromium.cpp:
(WebCore::GraphicsLayerChromium::setFilters):

LayoutTests:

Added a test that first applies a blur and then switches to a CSS Shader plus a blur.
The test was failing on Chromium by not removing the old blur filter from the platform layer.

* css3/filters/custom/filter-fallback-to-software-expected.html: Added.
* css3/filters/custom/filter-fallback-to-software.html: Added.

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

8 years ago[WK2] Fix some typos in MiniBrowser
ap@apple.com [Wed, 15 Aug 2012 01:19:23 +0000 (01:19 +0000)]
[WK2] Fix some typos in MiniBrowser
https://bugs.webkit.org/show_bug.cgi?id=94047

Reviewed by Jon Honeycutt.

* MiniBrowser/mac/AppDelegate.m:
(didReceiveMessageFromInjectedBundle): (-[BrowserAppDelegate init]):
* MiniBrowser/mac/WebBundle/WebBundleMain.m:
(didReceiveMessage):
(WKBundleInitialize):

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

8 years agoIndexedDB: add tracing to IDBLevelDBBackingStore
commit-queue@webkit.org [Wed, 15 Aug 2012 01:18:25 +0000 (01:18 +0000)]
IndexedDB: add tracing to IDBLevelDBBackingStore
https://bugs.webkit.org/show_bug.cgi?id=93914

Patch by Alec Flett <alecflett@chromium.org> on 2012-08-14
Reviewed by Tony Chang.

Add a bunch of trace events to the lower level
database layer, to separate database slowness
from core IDB slowness.

Also moving findKeyInIndex into IDBLevelDBBackingStore to
eventually make it const.

No new tests, just adding debug logging.

* Modules/indexeddb/IDBLevelDBBackingStore.cpp:
(WebCore::IDBLevelDBBackingStore::open):
(WebCore::IDBLevelDBBackingStore::deleteDatabase):
(WebCore::IDBLevelDBBackingStore::getObjectStores):
(WebCore::IDBLevelDBBackingStore::createObjectStore):
(WebCore::IDBLevelDBBackingStore::deleteObjectStore):
(WebCore::IDBLevelDBBackingStore::getObjectStoreRecord):
(WebCore):
(WebCore::IDBLevelDBBackingStore::putObjectStoreRecord):
(WebCore::IDBLevelDBBackingStore::clearObjectStore):
(WebCore::IDBLevelDBBackingStore::deleteObjectStoreRecord):
(WebCore::IDBLevelDBBackingStore::keyExistsInObjectStore):
(WebCore::IDBLevelDBBackingStore::getIndexes):
(WebCore::IDBLevelDBBackingStore::createIndex):
(WebCore::IDBLevelDBBackingStore::deleteIndex):
(WebCore::IDBLevelDBBackingStore::putIndexDataForRecord):
(WebCore::IDBLevelDBBackingStore::findKeyInIndex):
(WebCore::IDBLevelDBBackingStore::getPrimaryKeyViaIndex):
(WebCore::IDBLevelDBBackingStore::keyExistsInIndex):
(WebCore::IDBLevelDBBackingStore::openObjectStoreCursor):
(WebCore::IDBLevelDBBackingStore::openIndexKeyCursor):
(WebCore::IDBLevelDBBackingStore::openIndexCursor):
(WebCore::IDBLevelDBBackingStore::Transaction::commit):
(WebCore::IDBLevelDBBackingStore::Transaction::rollback):
* Modules/indexeddb/IDBLevelDBBackingStore.h:
(IDBLevelDBBackingStore):
* Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
(WebCore):
* Modules/indexeddb/IDBTransaction.cpp:
(WebCore::IDBTransaction::onAbort):
(WebCore::IDBTransaction::onComplete):

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

8 years agoRefactor EventDispatcher, moving code to make actual changes easier to review later.
hayato@chromium.org [Wed, 15 Aug 2012 00:56:02 +0000 (00:56 +0000)]
Refactor EventDispatcher, moving code to make actual changes easier to review later.
https://bugs.webkit.org/show_bug.cgi?id=93959

Reviewed by Dimitri Glazkov.

No new tests - no new functionality.

* dom/EventDispatcher.cpp:
(WebCore::EventDispatcher::dispatchScopedEvent):
(WebCore):
(WebCore::EventDispatcher::dispatchSimulatedClick):

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

8 years ago[Chromium] Fix warnings on Windows build
commit-queue@webkit.org [Wed, 15 Aug 2012 00:33:21 +0000 (00:33 +0000)]
[Chromium] Fix warnings on Windows build
https://bugs.webkit.org/show_bug.cgi?id=93997

Patch by Scott Graham <scottmg@chromium.org> on 2012-08-14
Reviewed by Kentaro Hara.

Fixes truncation from 'double' to 'float' warnings on Chromium Windows
build.

* tests/CCRenderSurfaceFiltersTest.cpp:
(WebKit::TEST):
* tests/CCScrollbarAnimationControllerLinearFadeTest.cpp:
(WebCore::TEST_F):

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

8 years agoClear pattern to prevent timing problem between cancelVibration and vibrate
commit-queue@webkit.org [Wed, 15 Aug 2012 00:10:36 +0000 (00:10 +0000)]
Clear pattern to prevent timing problem between cancelVibration and vibrate
https://bugs.webkit.org/show_bug.cgi?id=93957

Patch by Kihong Kwon <kihong.kwon@samsung.com> on 2012-08-14
Reviewed by Kentaro Hara.

There is a timing issue in the cancelVibration.
Since vibrate works based on timer, cancelVibration might be called
eariler than vibrate when cancelVibration is called just after vibrate call.
It can be prevented from clearing m_pattern in the cancelVibration.

* Modules/vibration/Vibration.cpp:
(WebCore::Vibration::cancelVibration):

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

8 years ago/SAFESEH should not be a common linker option
commit-queue@webkit.org [Tue, 14 Aug 2012 23:40:17 +0000 (23:40 +0000)]
/SAFESEH should not be a common linker option
https://bugs.webkit.org/show_bug.cgi?id=89372

Patch by Alex Christensen <alex.christensen@flexsim.com> on 2012-08-14
Reviewed by Darin Adler.

* win/tools/vsprops/common.vsprops:
removed /SAFESEH as a default option for the linker (doesn't work for x64)

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

8 years ago[chromium] Add baselines for video-controls-layer-creation layout test
enne@google.com [Tue, 14 Aug 2012 23:21:57 +0000 (23:21 +0000)]
[chromium] Add baselines for video-controls-layer-creation layout test

Unreviewed expectation update.

* compositing/video/video-controls-layer-creation-expected.txt: Added.
* platform/chromium-linux/compositing/video/video-controls-layer-creation-expected.png: Added.
* platform/chromium-mac-snowleopard/compositing/video/video-controls-layer-creation-expected.png: Added.
* platform/chromium-mac/compositing/video/video-controls-layer-creation-expected.png: Added.
* platform/chromium-win/compositing/video/video-controls-layer-creation-expected.png: Added.
* platform/mac/TestExpectations:

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

8 years agoImplement new synchronized audio I/O render method in chromium
crogers@google.com [Tue, 14 Aug 2012 23:17:08 +0000 (23:17 +0000)]
Implement new synchronized audio I/O render method in chromium
https://bugs.webkit.org/show_bug.cgi?id=93510

Reviewed by Kenneth Russell.

The chromium implementation of AudioDestination is being upgraded to
support synchronized audio I/O.  Other changes on the chromium-side
can then be tested against something that works in WebKit.

* src/AudioDestinationChromium.cpp:
(WebCore::AudioDestinationChromium::AudioDestinationChromium):
(WebCore::AudioDestinationChromium::render):
(WebCore):
(WebCore::AudioDestinationChromium::provideInput):
* src/AudioDestinationChromium.h:
(WebCore):
(AudioDestinationChromium):

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

8 years agoLayout Test css3/filters/custom/custom-filter-animation.html is failing
achicu@adobe.com [Tue, 14 Aug 2012 23:16:35 +0000 (23:16 +0000)]
Layout Test css3/filters/custom/custom-filter-animation.html is failing
https://bugs.webkit.org/show_bug.cgi?id=91769

Reviewed by Dean Jackson.

Source/WebCore:

Mountain Lion added support for accelerated filter animations, but CSS Shaders are still
rendered in software mode. The setFilters method is using PlatformCALayer::filtersCanBeComposited to check
if the filters can be handled in hardwawre, so I've reused that in the createFilterAnimationsFromKeyframes
to check if the animations can also run in hardware.

Also the GraphicsContext3D doesn't update its own internal m_boundFBO when a framebuffer is deleted,
so I've added that to the FECustomFilter. Otherwise, if the next framebuffer is created using the same
identifier, bindFramebuffer will just return without calling the glBindFramebuffer because of this optimization.

The documentation for glDeleteFramebuffer says that the bound framebuffer is unbound before deleting it.
This is not reproduceable from WebGL, because WebGLRenderingContext::deleteFramebuffer
already knows to unbind the framebuffer when needed. However, I'm also adding that in GraphicsContext3DOpenGLCommon.cpp
and efl/GraphicsContext3DPrivate.cpp, to make sure that m_boundFBO is not used for other purposes.

No new tests, this patch fixes a failing test.

* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::GraphicsLayerCA::createFilterAnimationsFromKeyframes):
* platform/graphics/efl/GraphicsContext3DPrivate.cpp:
(WebCore::GraphicsContext3DPrivate::deleteFramebuffer):
* platform/graphics/filters/FECustomFilter.cpp:
(WebCore::FECustomFilter::deleteRenderBuffers):
* platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
(WebCore::GraphicsContext3D::deleteFramebuffer):

LayoutTests:

The test should be passing on Mountain Lion now, so I'm removing it from the list.

* platform/mac/TestExpectations:

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

8 years agoDelete Frame::domWindow() and Frame::existingDOMWindow()
abarth@webkit.org [Tue, 14 Aug 2012 22:34:01 +0000 (22:34 +0000)]
Delete Frame::domWindow() and Frame::existingDOMWindow()
https://bugs.webkit.org/show_bug.cgi?id=93990

Reviewed by Eric Seidel.

Source/WebCore:

These functions just call through to document()->domWindow(). This
patch updates the callers so it's clearer what's going on.

* bindings/js/JSDOMBinding.cpp:
(WebCore::shouldAllowAccessToFrame):
(WebCore::printErrorMessageForFrame):
* bindings/js/JSDocumentCustom.cpp:
(WebCore::JSDocument::location):
(WebCore::JSDocument::setLocation):
* bindings/js/JSEventListener.cpp:
(WebCore::JSEventListener::handleEvent):
* bindings/js/ScriptCachedFrameData.cpp:
(WebCore::ScriptCachedFrameData::restore):
* bindings/js/ScriptController.cpp:
(WebCore::ScriptController::createWindowShell):
* bindings/objc/DOMAbstractView.mm:
(core):
* bindings/v8/NPV8Object.cpp:
(WebCore::toV8Context):
* bindings/v8/ScriptController.cpp:
(WebCore::createScriptObject):
(WebCore::ScriptController::createScriptObjectForPluginElement):
* bindings/v8/V8DOMWindowShell.cpp:
(WebCore::V8DOMWindowShell::initContextIfNeeded):
* bindings/v8/V8IsolatedContext.cpp:
(WebCore::V8IsolatedContext::V8IsolatedContext):
* bindings/v8/V8Proxy.cpp:
(WebCore::V8Proxy::retrieveFrame):
* bindings/v8/custom/V8DOMWindowCustom.cpp:
(WebCore::V8DOMWindow::indexedPropertyGetter):
(WebCore::V8DOMWindow::namedPropertyGetter):
* bindings/v8/custom/V8DocumentLocationCustom.cpp:
(WebCore::V8Document::locationAccessorGetter):
(WebCore::V8Document::locationAccessorSetter):
* bindings/v8/custom/V8HTMLDocumentCustom.cpp:
(WebCore::V8HTMLDocument::GetNamedProperty):
* bindings/v8/custom/V8HTMLFrameSetElementCustom.cpp:
(WebCore::V8HTMLFrameSetElement::namedPropertyGetter):
* dom/Document.cpp:
(WebCore::printNavigationErrorMessage):
* dom/ViewportArguments.cpp:
(WebCore::reportViewportWarning):
* editing/AlternativeTextController.cpp:
(WebCore::AlternativeTextController::insertDictatedText):
* editing/Editor.cpp:
(WebCore::Editor::pasteAsPlainText):
(WebCore::Editor::pasteAsFragment):
(WebCore::Editor::setComposition):
* history/PageCache.cpp:
(WebCore::logCanCacheFrameDecision):
(WebCore::PageCache::canCachePageContainingThisFrame):
* html/HTMLFormElement.cpp:
(WebCore::HTMLFormElement::validateInteractively):
* html/HTMLFrameOwnerElement.cpp:
(WebCore::HTMLFrameOwnerElement::contentWindow):
* html/canvas/WebGLRenderingContext.cpp:
(WebCore):
(WebCore::WebGLRenderingContext::printWarningToConsole):
* inspector/InspectorDOMStorageAgent.cpp:
(WebCore::InspectorDOMStorageAgent::storageId):
* loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::checkLoadComplete):
* loader/DocumentWriter.cpp:
(WebCore::DocumentWriter::begin):
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::stopLoading):
(WebCore::FrameLoader::didOpenURL):
(WebCore::FrameLoader::checkIfDisplayInsecureContent):
(WebCore::FrameLoader::checkIfRunInsecureContent):
(WebCore::FrameLoader::reportLocalLoadFailed):
(WebCore::FrameLoader::prepareForCachedPageRestore):
(WebCore::FrameLoader::open):
(WebCore::FrameLoader::fireBeforeUnloadEvent):
* loader/MainResourceLoader.cpp:
(WebCore::MainResourceLoader::didReceiveResponse):
* loader/appcache/ApplicationCacheGroup.cpp:
(WebCore::ApplicationCacheGroup::abort):
(WebCore::ApplicationCacheGroup::didReceiveResponse):
(WebCore::ApplicationCacheGroup::didFinishLoading):
(WebCore::ApplicationCacheGroup::didFail):
(WebCore::ApplicationCacheGroup::didReceiveManifestResponse):
(WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
(WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
* loader/cache/CachedResourceLoader.cpp:
(WebCore::CachedResourceLoader::printAccessDeniedMessage):
* page/DOMWindow.cpp:
(WebCore::DOMWindow::isCurrentlyDisplayedInFrame):
(WebCore::DOMWindow::self):
(WebCore::DOMWindow::opener):
(WebCore::DOMWindow::parent):
(WebCore::DOMWindow::top):
(WebCore::DOMWindow::createWindow):
(WebCore::DOMWindow::open):
* page/DOMWindowProperty.cpp:
(WebCore::DOMWindowProperty::DOMWindowProperty):
(WebCore::DOMWindowProperty::reconnectFrameFromPageCache):
* page/DragController.cpp:
(WebCore::DragController::dispatchTextInputEventFor):
* page/EventHandler.cpp:
(WebCore::EventHandler::handleTextInputEvent):
* page/Frame.cpp:
* page/Frame.h:
(Frame):
* page/Location.cpp:
(WebCore::Location::replace):
(WebCore::Location::reload):
(WebCore::Location::setLocation):
* storage/StorageEventDispatcher.cpp:
(WebCore::StorageEventDispatcher::dispatch):
* svg/SVGDocumentExtensions.cpp:
(WebCore::reportMessage):
* xml/XSLStyleSheetLibxslt.cpp:
(WebCore::XSLStyleSheet::parseString):
* xml/XSLTProcessorLibxslt.cpp:
(WebCore::docLoaderFunc):
* xml/XSLTProcessorQt.cpp:
(WebCore::XSLTMessageHandler::handleMessage):

Source/WebKit/blackberry:

* WebCoreSupport/ChromeClientBlackBerry.cpp:
(WebCore::toOriginString):
(WebCore::ChromeClientBlackBerry::runJavaScriptAlert):
(WebCore::ChromeClientBlackBerry::runJavaScriptConfirm):
(WebCore::ChromeClientBlackBerry::runJavaScriptPrompt):
(WebCore::ChromeClientBlackBerry::runBeforeUnloadConfirmPanel):
(WebCore::ChromeClientBlackBerry::requestWebGLPermission):

Source/WebKit/chromium:

* src/StorageAreaProxy.cpp:
(WebCore::StorageAreaProxy::dispatchLocalStorageEvent):
(WebCore::StorageAreaProxy::dispatchSessionStorageEvent):
* src/WebDOMMessageEvent.cpp:
(WebKit::WebDOMMessageEvent::initMessageEvent):
* src/WebFrameImpl.cpp:
(WebKit::WebFrameImpl::performance):
(WebKit::WebFrameImpl::addMessageToConsole):
(WebKit::WebFrameImpl::unloadListenerCount):
(WebKit::WebFrameImpl::addEventListener):
(WebKit::WebFrameImpl::removeEventListener):
(WebKit::WebFrameImpl::dispatchEvent):
(WebKit::WebFrameImpl::dispatchMessageEventWithOriginCheck):
(WebKit::WebFrameImpl::deliverIntent):
* src/WebPagePopupImpl.cpp:
(WebKit::WebPagePopupImpl::initPage):

Source/WebKit/efl:

* WebCoreSupport/DumpRenderTreeSupportEfl.cpp:
(DumpRenderTreeSupportEfl::pendingUnloadEventCount):
* ewk/ewk_frame.cpp:
(ewk_frame_intent_deliver):

Source/WebKit/gtk:

* WebCoreSupport/DumpRenderTreeSupportGtk.cpp:
(DumpRenderTreeSupportGtk::getPendingUnloadEventCount):

Source/WebKit/mac:

* WebView/WebFrame.mm:
(-[WebFrame _pendingFrameUnloadEventCount]):
(-[WebFrame _cacheabilityDictionary]):

Source/WebKit/qt:

* WebCoreSupport/FrameLoaderClientQt.cpp:
(WebCore::FrameLoaderClientQt::dispatchDidFinishDocumentLoad):

Source/WebKit/win:

* WebFrame.cpp:
(WebFrame::DOMWindow):
(WebFrame::pendingFrameUnloadEventCount):

Source/WebKit2:

* WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::deliverIntent):
(WebKit::WebFrame::pendingUnloadCount):

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

8 years agoTighten up parsing the 'script-nonce' CSP directive value.
commit-queue@webkit.org [Tue, 14 Aug 2012 22:27:08 +0000 (22:27 +0000)]
Tighten up parsing the 'script-nonce' CSP directive value.
https://bugs.webkit.org/show_bug.cgi?id=93783

Patch by Mike West <mkwst@chromium.org> on 2012-08-14
Reviewed by Adam Barth.

Source/WebCore:

Currently we're accepting any non-whitespace character. This patch
limits the valid characters to VCHAR minus ',' and ';', and pulls the
validity check out into a named function for clarity.

Test: http/tests/security/contentSecurityPolicy/1.1/scriptnonce-separators-allowed.html

* page/ContentSecurityPolicy.cpp:
(WebCore::CSPDirectiveList::parseScriptNonce):

LayoutTests:

* http/tests/security/contentSecurityPolicy/1.1/scriptnonce-separators-allowed-expected.txt: Added.
* http/tests/security/contentSecurityPolicy/1.1/scriptnonce-separators-allowed.html: Added.

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

8 years agoDelete DOMWindow::m_url
abarth@webkit.org [Tue, 14 Aug 2012 22:14:47 +0000 (22:14 +0000)]
Delete DOMWindow::m_url
https://bugs.webkit.org/show_bug.cgi?id=93989

Reviewed by Eric Seidel.

Source/WebCore:

There's no reason for DOMWindow to keep a separate copy of the
Document's URL now that there is a predictable way to get a Document
from a DOMWindow.

* loader/DocumentWriter.cpp:
(WebCore::DocumentWriter::begin):
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::open):
* page/DOMWindow.cpp:
(WebCore::DOMWindow::crossDomainAccessErrorMessage):
* page/DOMWindow.h:
(DOMWindow):

LayoutTests:

The error messages for these tests now relect the document's updated
URL after document.write has changed the URL. Previously, we failed to
sync these changes to DOMWindow::m_url, which is why the error messages
showed the wrong URL.

* http/tests/security/aboutBlank/xss-DENIED-navigate-opener-document-write-expected.txt:
* http/tests/security/aboutBlank/xss-DENIED-set-opener-expected.txt:

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

8 years agoDe-inline stuff from RenderStyle.h
commit-queue@webkit.org [Tue, 14 Aug 2012 22:05:45 +0000 (22:05 +0000)]
De-inline stuff from RenderStyle.h
https://bugs.webkit.org/show_bug.cgi?id=94019

Patch by Nikhil Bhargava <nbhargava@google.com> on 2012-08-14
Reviewed by Eric Seidel.

De-inline things from RenderStyle.h in preparation of fixing a series of
errant includes.

No new tests. Doesn't change functionality

* WebCore.exp.in:
* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::listStyleImage):
(WebCore::RenderStyle::setListStyleImage):
(WebCore):
(WebCore::RenderStyle::color):
(WebCore::RenderStyle::visitedLinkColor):
(WebCore::RenderStyle::setColor):
(WebCore::RenderStyle::setVisitedLinkColor):
(WebCore::RenderStyle::horizontalBorderSpacing):
(WebCore::RenderStyle::verticalBorderSpacing):
(WebCore::RenderStyle::setHorizontalBorderSpacing):
(WebCore::RenderStyle::setVerticalBorderSpacing):
(WebCore::RenderStyle::font):
(WebCore::RenderStyle::fontMetrics):
(WebCore::RenderStyle::fontDescription):
(WebCore::RenderStyle::fontSize):
(WebCore::RenderStyle::wordSpacing):
(WebCore::RenderStyle::letterSpacing):
(WebCore::RenderStyle::setFontDescription):
(WebCore::RenderStyle::lineHeight):
(WebCore::RenderStyle::setLineHeight):
(WebCore::RenderStyle::computedLineHeight):
(WebCore::RenderStyle::setWordSpacing):
(WebCore::RenderStyle::setLetterSpacing):
* rendering/style/RenderStyle.h:

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

8 years ago[BlackBerry] Checkerboard flashes on Go Back
commit-queue@webkit.org [Tue, 14 Aug 2012 22:02:19 +0000 (22:02 +0000)]
[BlackBerry] Checkerboard flashes on Go Back
https://bugs.webkit.org/show_bug.cgi?id=94018

Patch by Leo Yang <leoyang@rim.com> on 2012-08-14
Reviewed by Yong Li.
Reviewed internally by Yong Li.

The backing store need to be suspended before the
WebPagePrivate::restoreHistoryViewState() is called to avoid UI thread
drawing checkerboard.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::restoreHistoryViewState):
* WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
(WebCore::FrameLoaderClientBlackBerry::restoreViewState):

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

8 years ago[CSSRegions]Region overset property is incorectly computed when content has negative...
commit-queue@webkit.org [Tue, 14 Aug 2012 21:36:08 +0000 (21:36 +0000)]
[CSSRegions]Region overset property is incorectly computed when content has negative letter spacing and is flowed near to the edge of a region
https://bugs.webkit.org/show_bug.cgi?id=92506

Patch by Andrei Onea <onea@adobe.com> on 2012-08-14
Reviewed by Eric Seidel.

Source/WebCore:

When the content which is flowed inside a region creates visual overflow in
the writing direction, the overflow rect is also extended in the other direction, and
that forces regionOverset to become "fit" for all regions.

Tests: fast/regions/element-region-overset-state-negative-letter-spacing.html
       fast/regions/element-region-overset-state-vertical-rl-negative-letter-spacing.html

* rendering/RenderFlowThread.cpp:
(WebCore::RenderFlowThread::computeOverflowStateForRegions):

LayoutTests:

Added tests for incorrect regionOverset computation when visual overflow in the writing direction creates
overset for all regions.

* fast/regions/element-region-overset-state-negative-letter-spacing-expected.txt: Added.
* fast/regions/element-region-overset-state-negative-letter-spacing.html: Added.
* fast/regions/element-region-overset-state-vertical-rl-negative-letter-spacing-expected.txt: Added.
* fast/regions/element-region-overset-state-vertical-rl-negative-letter-spacing.html: Added.

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

8 years ago[BlackBerry] Remove unnecessary \n's from InputHandler log messages.
mifenton@rim.com [Tue, 14 Aug 2012 21:35:06 +0000 (21:35 +0000)]
[BlackBerry] Remove unnecessary \n's from InputHandler log messages.
https://bugs.webkit.org/show_bug.cgi?id=94015

Reviewed by Rob Buis.

Remove many unnecessary \n's from the end of log messages.

Reviewed Internally by Nima Ghanavatian.

* WebKitSupport/InputHandler.cpp:
(BlackBerry::WebKit::convertStringToWcharVector):
(BlackBerry::WebKit::convertSpannableStringToString):
(BlackBerry::WebKit::InputHandler::spannableTextInRange):
(BlackBerry::WebKit::InputHandler::setText):
(BlackBerry::WebKit::InputHandler::setSpannableTextAndRelativeCursor):

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

8 years agobeginElement() does not observe updated animation attributes
fmalita@chromium.org [Tue, 14 Aug 2012 21:33:56 +0000 (21:33 +0000)]
beginElement() does not observe updated animation attributes
https://bugs.webkit.org/show_bug.cgi?id=93972

Reviewed by Dirk Schulze.

Source/WebCore:

The SVG animation attributes 'from', 'to' and 'by' should be registered as supported
SVGSMILElement attributes in order to trigger animationAttributeChanged() on dynamic
updates.

Test: svg/animations/updated-attributes.html

* svg/SVGAnimationElement.cpp:
(WebCore::SVGAnimationElement::updateAnimation):
Minor optimization - avoid recalculating animationMode().

* svg/animation/SVGSMILElement.cpp:
(WebCore::SVGSMILElement::isSupportedAttribute):
Register 'from', 'to' and 'by' as supported SVGSMILElement attributes.

LayoutTests:

* svg/animations/updated-attributes-expected.txt: Added.
* svg/animations/updated-attributes.html: Added.

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

8 years agoRebaseline fast/box-sizing/box-sizing.html and compositing/overflow/clip-descendents...
commit-queue@webkit.org [Tue, 14 Aug 2012 21:23:58 +0000 (21:23 +0000)]
Rebaseline fast/box-sizing/box-sizing.html and compositing/overflow/clip-descendents.html.
https://bugs.webkit.org/show_bug.cgi?id=93909

Patch by Roger Fong <roger_fong@apple.com> on 2012-08-14
Reviewed by Tim Horton.

As per https://bugs.webkit.org/show_bug.cgi?id=92904 rebaselining those tests.

* compositing/overflow/clip-descendents-expected.txt: Rebaselined.
* platform/mac/TestExpectations: Removed tests from expectations list.
* platform/mac/fast/box-sizing/box-sizing-expected.txt: Rebaselined.

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

8 years ago[BlackBerry] Don't crash on OOM in AC
commit-queue@webkit.org [Tue, 14 Aug 2012 21:20:01 +0000 (21:20 +0000)]
[BlackBerry] Don't crash on OOM in AC
https://bugs.webkit.org/show_bug.cgi?id=93999

Patch by Filip Spacek <fspacek@rim.com> on 2012-08-14
Reviewed by George Staikos.

Internally reviewed by George Staikos.

Fail gracefully in case we fail to allocate the bitmap
for the AC layer contents.

* platform/graphics/blackberry/InstrumentedPlatformCanvas.h:
(WebCore::InstrumentedPlatformCanvas::InstrumentedPlatformCanvas):
* platform/graphics/blackberry/LayerWebKitThread.cpp:
(WebCore::LayerWebKitThread::paintContents):

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

8 years agoold-run-webkit-tests should skip all file extensions for ref tests, not just .html.
commit-queue@webkit.org [Tue, 14 Aug 2012 21:16:08 +0000 (21:16 +0000)]
old-run-webkit-tests should skip all file extensions for ref tests, not just .html.
https://bugs.webkit.org/show_bug.cgi?id=93904

Patch by Roger Fong <roger_fong@apple.com> on 2012-08-14
Reviewed by Tim Horton.

old-run-webkit-tests ref test only skipped .html test.
They need to skip .html, .shtml, .xml, .xhtml, .pl, .htm, .php, .svg, .mht.

* Scripts/old-run-webkit-tests:
(isUsedInReftest): Skip all extensions for ref tests.

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

8 years agoConvert signals/slots to Q_* macros.
commit-queue@webkit.org [Tue, 14 Aug 2012 21:11:33 +0000 (21:11 +0000)]
Convert signals/slots to Q_* macros.

[Qt] Use Q_SLOTS and Q_SIGNALS instead of slots and signals
https://bugs.webkit.org/show_bug.cgi?id=93996

Patch by Lauro Neto <lauro.neto@openbossa.org> on 2012-08-14
Reviewed by Kenneth Rohde Christiansen.

Change usage of keyword-conflicting 'signals' and 'slots' for
Q_SIGNALS and Q_SLOTS macro.

Source/WebCore:

* bridge/testqtbindings.cpp:
(MyObject):
* platform/graphics/gstreamer/PlatformVideoWindowPrivate.h:
* platform/graphics/qt/MediaPlayerPrivateQt.h:
(MediaPlayerPrivateQt):
* platform/network/qt/DnsPrefetchHelper.h:
(DnsPrefetchHelper):
* platform/network/qt/NetworkStateNotifierPrivate.h:
(NetworkStateNotifierPrivate):
* platform/network/qt/QNetworkReplyHandler.h:
(QNetworkReplyHandler):
* platform/network/qt/QtMIMETypeSniffer.h:
(QtMIMETypeSniffer):
* platform/network/qt/SocketStreamHandlePrivate.h:
(SocketStreamHandlePrivate):
* platform/qt/GamepadsQt.cpp:
(GamepadDeviceLinuxQt):
(GamepadsQt):
* platform/qt/SharedTimerQt.cpp:
(SharedTimerQt):

Source/WebKit/qt:

* WebCoreSupport/FrameLoaderClientQt.h:
(FrameLoaderClientQt):
* WebCoreSupport/FullScreenVideoQt.h:
(FullScreenVideoQt):
* WebCoreSupport/FullScreenVideoWidget.h:
(FullScreenVideoWidget):
* WebCoreSupport/IconDatabaseClientQt.h:
(IconDatabaseClientQt):
* WebCoreSupport/InspectorClientQt.cpp:
(InspectorClientWebPage):
* WebCoreSupport/InspectorServerQt.h:
(InspectorServerQt):
(InspectorServerRequestHandlerQt):
* WebCoreSupport/PopupMenuQt.h:
(PopupMenuQt):
* WebCoreSupport/QtFallbackWebPopup.h:
(QtFallbackWebPopup):
* docs/webkitsnippets/qtwebkit_bridge_snippets.cpp:
(wrapInFunction):
* docs/webkitsnippets/webpage/main.cpp:
(Thumbnailer):
* examples/platformplugin/WebPlugin.h:
(Popup):
(WebPopup):
* tests/benchmarks/webgl/tst_webgl.cpp:
(tst_WebGlPerformance):
* tests/hybridPixmap/tst_hybridPixmap.cpp:
(tst_hybridPixmap):
* tests/hybridPixmap/widget.h:
(Widget):
* tests/qdeclarativewebview/tst_qdeclarativewebview.cpp:
(tst_QDeclarativeWebView):
* tests/qgraphicswebview/tst_qgraphicswebview.cpp:
(tst_QGraphicsWebView):
(WebPage):
(ResizeSpy):
* tests/qobjectbridge/tst_qobjectbridge.cpp:
(MyWebElementSlotOnlyObject):
(tst_QObjectBridge):
(TestPluginWidget):
* tests/qwebelement/tst_qwebelement.cpp:
(tst_QWebElement):
* tests/qwebframe/tst_qwebframe.cpp:
(tst_QWebFrame):
(FakeReply):
* tests/qwebhistory/tst_qwebhistory.cpp:
* tests/qwebhistoryinterface/tst_qwebhistoryinterface.cpp:
(tst_QWebHistoryInterface):
* tests/qwebinspector/tst_qwebinspector.cpp:
(tst_QWebInspector):
* tests/qwebpage/tst_qwebpage.cpp:
(tst_QWebPage):
(JSTestPage):
(RepaintRequestedRenderer):
(SpyForLoadSignalsOrder):
* tests/qwebplugindatabase/tst_qwebplugindatabase.cpp:
(tst_QWebPluginDatabase):
* tests/qwebview/tst_qwebview.cpp:
(tst_QWebView):
(WebViewCrashTest):

Source/WebKit2:

* UIProcess/API/qt/qwebkittest_p.h:
* UIProcess/API/qt/tests/inspectorserver/tst_inspectorserver.cpp:
(tst_InspectorServer):
* UIProcess/API/qt/tests/publicapi/tst_publicapi.cpp:
(tst_publicapi):
* UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp:
(tst_QQuickWebView):
* UIProcess/API/qt/tests/qrawwebview/tst_qrawwebview.cpp:
(WebView):
(tst_qrawwebview):
* UIProcess/API/qt/tests/util.cpp:
(LoadSpy):
* UIProcess/API/qt/tests/util.h:
(LoadStartedCatcher):
* UIProcess/InspectorServer/qt/WebSocketServerQt.h:
(QtTcpServerHandler):
* UIProcess/qt/QtDialogRunner.cpp:
(DialogContextBase):
(DialogContextObject):
(BaseAuthenticationContextObject):
(CertificateVerificationDialogContextObject):
(FilePickerContextObject):
(DatabaseQuotaDialogContextObject):
* UIProcess/qt/QtDialogRunner.h:
(QtDialogRunner):
* UIProcess/qt/QtWebPageEventHandler.h:
(QtWebPageEventHandler):
* WebProcess/Downloads/qt/QtFileDownloader.h:

Tools:

* DumpRenderTree/qt/DumpRenderTreeQt.h:
(NetworkAccessManager):
(WebPage):
* DumpRenderTree/qt/EventSenderQt.h:
(EventSender):
* DumpRenderTree/qt/GCControllerQt.h:
(GCController):
* DumpRenderTree/qt/TestRunnerQt.h:
(TestRunner):
* DumpRenderTree/qt/TextInputControllerQt.h:
(TextInputController):
* MiniBrowser/qt/BrowserWindow.h:
(BrowserWindow):
* MiniBrowser/qt/MiniBrowserApplication.h:
(WindowOptions):
* MiniBrowser/qt/UrlLoader.h:
(UrlLoader):
* QtTestBrowser/cookiejar.h:
(TestBrowserCookieJar):
* QtTestBrowser/fpstimer.h:
(FpsTimer):
* QtTestBrowser/launcherwindow.h:
(LauncherWindow):
* QtTestBrowser/locationedit.h:
(LocationEdit):
* QtTestBrowser/mainwindow.h:
(MainWindow):
* QtTestBrowser/urlloader.h:
(UrlLoader):
* QtTestBrowser/webinspector.h:
(WebInspector):
* QtTestBrowser/webpage.h:
(WebPage):
* QtTestBrowser/webview.h:
(WebViewGraphicsBased):
* WebKitTestRunner/InjectedBundle/qt/LayoutTestControllerQt.cpp:
(WatchdogTimerHelper):
* WebKitTestRunner/qt/PlatformWebViewQt.cpp:
(WrapperWindow):
* WebKitTestRunner/qt/main.cpp:
(Launcher):

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

8 years ago [WK2] Track multiple Web Processes per context
ap@apple.com [Tue, 14 Aug 2012 21:06:41 +0000 (21:06 +0000)]
    [WK2] Track multiple Web Processes per context
        https://bugs.webkit.org/show_bug.cgi?id=93915

        Reviewed by Sam Weinig.

        * UIProcess/Downloads/DownloadProxy.cpp:
        (WebKit::DownloadProxy::didReceiveAuthenticationChallenge): Downloads don't work
        yet, added a FIXME.

        * UIProcess/WebContext.cpp:
        (WebKit::WebContext::deprecatedSharedProcess): Renamed from process(), added an
        assertion that this is only used in single proces mode.
        (WebKit::WebContext::textCheckerStateChanged): Abstract out access to web processes.
        (WebKit::WebContext::ensureSharedWebProcess): Renamed ensureWebProcess() for clarity.
        (WebKit::WebContext::createNewWebProcess): Extracted code for creating a process
        from ensureWebProcess().
        (WebKit::WebContext::warmInitialProcess): Create the process more explicitly.
        (WebKit::WebContext::enableProcessTermination): Iterate over all processes.
        (WebKit::WebContext::shouldTerminate): Updated assertion.
        (WebKit::WebContext::processDidFinishLaunching): Changed to use process argument
        instead of m_process.
        (WebKit::WebContext::disconnectProcess): Updated code forto use m_processes.
        (WebKit::WebContext::createWebPage): Handle both process policies (initial support
        for multi-process).
        (WebKit::WebContext::relaunchProcessIfNecessary): Added cases for both policies.
        (WebKit::WebContext::download): Ditto.
        (WebKit::WebContext::postMessageToInjectedBundle): Ditto.
        (WebKit::WebContext::didReceiveSyncMessage): Fixed whitespace.
        (WebKit::WebContext::getWebCoreStatistics): Added cases for both policies.

        * UIProcess/WebContext.h:
        (WebKit::WebContext::sendToAllProcesses):
        (WebKit::WebContext::sendToAllProcessesRelaunchingThemIfNecessary):
        Send to all processes. Changed return type to void, since no caller checked it.

        * UIProcess/WebProcessProxy.cpp: (WebKit::WebProcessProxy::createWebPage): Removed
        an assertion that assumed one process per context.

        * UIProcess/WebTextChecker.cpp: (WebKit::updateStateForAllWebProcesses): Updated
        to use a WebContext method.

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

8 years agoREGRESSION r125500: 7 tests crashing on Mac bots
tsepez@chromium.org [Tue, 14 Aug 2012 21:02:24 +0000 (21:02 +0000)]
REGRESSION r125500: 7 tests crashing on Mac bots
https://bugs.webkit.org/show_bug.cgi?id=93970

Reviewed by Eric Seidel.

Make WebFrameLoaderClient::redirectDataToPlugin expect the now real possibility
of a NULL pluginWidget argument.

* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::redirectDataToPlugin)

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

8 years ago[CSSRegions]regionOverset is computed as "overset" even though the region is not...
commit-queue@webkit.org [Tue, 14 Aug 2012 20:53:09 +0000 (20:53 +0000)]
[CSSRegions]regionOverset is computed as "overset" even though the region is not the last in the chain
https://bugs.webkit.org/show_bug.cgi?id=93102

Patch by Andrei Onea <onea@adobe.com> on 2012-08-14
Reviewed by Eric Seidel.

Source/WebCore:

Making Element.webkitRegionOverset return "overset" only for the last region in a region chain,
if the content cannot fit inside it, to reflect current spec. http://www.w3.org/TR/css3-regions/#dom-region-regionoverset

* rendering/RenderFlowThread.cpp:
(WebCore::RenderFlowThread::computeOverflowStateForRegions):

LayoutTests:

Modified existing tests to reflect spec, where Element.webkitRegionOverset can be
"overset" only for the last region in a region chain, if the content cannot fit inside it.

* fast/regions/element-region-overset-state-expected.txt:
* fast/regions/element-region-overset-state-vertical-rl-expected.txt:
* fast/regions/element-region-overset-state-vertical-rl.html:
* fast/regions/element-region-overset-state.html:

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

8 years agoWeb Inspector: Render breakpoint gutter markers and execution line in CodeMirrorTextE...
commit-queue@webkit.org [Tue, 14 Aug 2012 20:47:37 +0000 (20:47 +0000)]
Web Inspector: Render breakpoint gutter markers and execution line in CodeMirrorTextEditor
https://bugs.webkit.org/show_bug.cgi?id=93686

Patch by Jan Keromnes <janx@linux.com> on 2012-08-14
Reviewed by Pavel Feldman.

Divided TextEditor.addDecoration into addBreakpoint, setExecutionLine
and addDecoration. Same for removeDecoration. Render breakpoint
markers and execution line in CodeMirrorTextEditor.

* inspector/front-end/CodeMirrorTextEditor.js:
(WebInspector.CodeMirrorTextEditor):
(WebInspector.CodeMirrorTextEditor.prototype._onGutterClick):
(WebInspector.CodeMirrorTextEditor.prototype.addBreakpoint):
(WebInspector.CodeMirrorTextEditor.prototype.removeBreakpoint):
(WebInspector.CodeMirrorTextEditor.prototype.setExecutionLine):
(WebInspector.CodeMirrorTextEditor.prototype.clearExecutionLine):
(WebInspector.CodeMirrorTextEditor.prototype.addDecoration):
(WebInspector.CodeMirrorTextEditor.prototype.removeDecoration):
(WebInspector.CodeMirrorTextEditor.prototype.highlightLine):
(WebInspector.CodeMirrorTextEditor.prototype.clearLineHighlight):
(WebInspector.CodeMirrorTextEditor.prototype.removeAttribute):
* inspector/front-end/DefaultTextEditor.js:
(WebInspector.DefaultTextEditor.prototype._onMouseDown):
(WebInspector.DefaultTextEditor.prototype.addBreakpoint):
(WebInspector.DefaultTextEditor.prototype.removeBreakpoint):
(WebInspector.DefaultTextEditor.prototype.setExecutionLine):
(WebInspector.DefaultTextEditor.prototype.clearExecutionLine):
(WebInspector.DefaultTextEditor.prototype.addDecoration):
(WebInspector.DefaultTextEditor.prototype.removeDecoration):
* inspector/front-end/JavaScriptSourceFrame.js:
(WebInspector.JavaScriptSourceFrame):
(WebInspector.JavaScriptSourceFrame.prototype._addBreakpointDecoration):
(WebInspector.JavaScriptSourceFrame.prototype._removeBreakpointDecoration):
(WebInspector.JavaScriptSourceFrame.prototype.setExecutionLine):
(WebInspector.JavaScriptSourceFrame.prototype.clearExecutionLine):
(WebInspector.JavaScriptSourceFrame.prototype._handleGutterClick):
* inspector/front-end/TextEditor.js:
(WebInspector.TextEditor.prototype.addBreakpoint):
(WebInspector.TextEditor.prototype.removeBreakpoint):
(WebInspector.TextEditor.prototype.setExecutionLine):
(WebInspector.TextEditor.prototype.clearExecutionLine):
(WebInspector.TextEditor.prototype.addDecoration):
(WebInspector.TextEditor.prototype.removeDecoration):
* inspector/front-end/cmdevtools.css:
(.CodeMirror):
(.cm-highlight):
(@-webkit-keyframes fadeout):
(to):
(.cm-breakpoint):
(.cm-breakpoint-disabled):
(.cm-breakpoint-conditional):
(.cm-execution-line):
(.webkit-html-message-bubble):
(.webkit-html-warning-message):
(.webkit-html-error-message):
(.webkit-html-message-line):
(.webkit-html-message-line-hover):

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

8 years ago[BlackBerry] Queue spellcheck requests with char-count limitations
commit-queue@webkit.org [Tue, 14 Aug 2012 20:45:10 +0000 (20:45 +0000)]
[BlackBerry] Queue spellcheck requests with char-count limitations
https://bugs.webkit.org/show_bug.cgi?id=93866

Patch by Nima Ghanavatian <nghanavatian@rim.com> on 2012-08-14
Reviewed by Rob Buis.

PR184196
Making spellcheck a little more granular so as to work around
the limitations of the inputservice.
Also, spellcheck the entire field on focus only if
spellcheck="on" is explicitly set.

Internally reviewed by Mike Fenton.

* WebKitSupport/InputHandler.cpp:
(BlackBerry::WebKit::InputHandler::requestCheckingOfString):
(BlackBerry::WebKit::InputHandler::spellCheckingRequestProcessed):

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

8 years agoREGRESSION (r109851): Video controls do not render
enne@google.com [Tue, 14 Aug 2012 20:44:35 +0000 (20:44 +0000)]
REGRESSION (r109851): Video controls do not render
https://bugs.webkit.org/show_bug.cgi?id=93859

Reviewed by Simon Fraser.

Source/WebCore:

Because video layers can't act as an ancestor composited layer whose
backing can be shared by child layers, any child layer of a video
layer needs to be put into its own composited layer. Because this is
technically overlap, the "overlap" indirect compositing reason is
reused for this case.

Test: compositing/video/video-controls-layer-creation.html

* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::computeCompositingRequirements):

LayoutTests:

Convert jernoble's test into a layout test.

* compositing/video/video-controls-layer-creation.html: Added.
* platform/chromium/TestExpectations:
* platform/mac/TestExpectations:

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

8 years agoUpdate Test Expectations to consolidate bug refs for new tests added
robert@webkit.org [Tue, 14 Aug 2012 20:30:52 +0000 (20:30 +0000)]
Update Test Expectations to consolidate bug refs for new tests added
with r125578.

Unreviewed gardening.

* platform/chromium/TestExpectations:
* platform/efl/TestExpectations:
* platform/gtk/TestExpectations:
* platform/mac/TestExpectations:

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

8 years ago[chromium] Mark css2.1/20110323/c541-word-sp-000.htm as failing on Windows Chromium
enne@google.com [Tue, 14 Aug 2012 20:06:48 +0000 (20:06 +0000)]
[chromium] Mark css2.1/20110323/c541-word-sp-000.htm as failing on Windows Chromium
https://bugs.webkit.org/show_bug.cgi?id=94017

Unreviewed gardening. Expectation update.

* platform/chromium/TestExpectations:

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

8 years agoUpdate Test Expectations after r125578
robert@webkit.org [Tue, 14 Aug 2012 20:02:05 +0000 (20:02 +0000)]
Update Test Expectations after r125578

       Unreviewed gardening.

       * platform/mac/TestExpectations:
       * platform/qt/TestExpectations:
       * platform/efl/TestExpectations:
       * platform/gtk/TestExpectations:

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

8 years agoWebKitTestRunner needs layoutTestController.dumpResourceLoadCallbacks
commit-queue@webkit.org [Tue, 14 Aug 2012 19:49:40 +0000 (19:49 +0000)]
WebKitTestRunner needs layoutTestController.dumpResourceLoadCallbacks
https://bugs.webkit.org/show_bug.cgi?id=42332

Patch by Mikhail Pozdnyakov <mikhail.pozdnyakov@intel.com> on 2012-08-14
Reviewed by Kenneth Rohde Christiansen.

Source/WebCore:

Provide build for mac.

* WebCore.exp.in: Added __ZNK7WebCore19ResourceRequestBase20firstPartyForCookiesEv.

Source/WebKit2:

Added new getters to WKURL, WKURLRequest, WKURLResponse so that it is possible
to dump information necessary for the tests passing.

* Shared/API/c/WKURL.cpp:
(WKURLCopyPath):
* Shared/API/c/WKURL.h:
* Shared/API/c/WKURLRequest.cpp:
(WKURLRequestCopyFirstPartyForCookies):
(WKURLRequestCopyHTTPMethod):
* Shared/API/c/WKURLRequest.h:
* Shared/API/c/WKURLResponse.cpp:
(WKURLResponseHTTPStatusCode):
* Shared/API/c/WKURLResponse.h:
* Shared/WebURL.h:
(WebKit::WebURL::path):
(WebURL):

Tools:

Added Resource Callbacks logging. Several aux dumping functions are added.

* WebKitTestRunner/InjectedBundle/Bindings/LayoutTestController.idl:
* WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
(WTR::isFileScheme):
(WTR):
(WTR::pathSuitableForTestResult):
(WTR::urlSuitableForTestResult):
(WTR::InjectedBundlePage::resetAfterTest):
(WTR::dumpRequestDescriptionSuitableForTestResult):
(WTR::dumpResponseDescriptionSuitableForTestResult):
(WTR::dumpErrorDescriptionSuitableForTestResult):
(WTR::InjectedBundlePage::didInitiateLoadForResource):
(WTR::InjectedBundlePage::willSendRequestForFrame):
(WTR::InjectedBundlePage::didReceiveResponseForResource):
(WTR::InjectedBundlePage::didFinishLoadForResource):
(WTR::InjectedBundlePage::didFailLoadForResource):
* WebKitTestRunner/InjectedBundle/LayoutTestController.cpp:
(WTR::LayoutTestController::LayoutTestController):
* WebKitTestRunner/InjectedBundle/LayoutTestController.h:
(WTR::LayoutTestController::dumpResourceLoadCallbacks):
(WTR::LayoutTestController::shouldDumpResourceLoadCallbacks):
(LayoutTestController):

LayoutTests:

Unskipped correspondong test cases.

* platform/wk2/Skipped:

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

8 years agoDOMWindow::document() should not reach through Frame
abarth@webkit.org [Tue, 14 Aug 2012 19:47:59 +0000 (19:47 +0000)]
DOMWindow::document() should not reach through Frame
https://bugs.webkit.org/show_bug.cgi?id=27640

Reviewed by Eric Seidel.

Source/WebCore:

Originally, the lifetime of DOMWindow was similar to that of Frame in
that it was reused for each document that was displayed in the Frame.
To fix some tricky security issues, all modern browsers use a "split
window" architecture whereby the DOMWindow is not reused by each
Document in a Frame. Instead a JavaScript "window shell" object
redirects JavaScript references to the active Document's DOMWindow.

When we implemented split windows, we left DOMWindow attached to the
Frame and attempted to keep it in sync with the Document via a lot of
delicate code. One of the main problems with this approach is that
finding the DOMWindow associated with a Document or the Document
associated with a DOMWindow required traversing through the Frame.
Because there is a many-to-one relationship between both Documents and
Frames (as well as DOMWindows and Frames), this traversal is error
prone and not always available (e.g., for inactive documents).

This patch moves the "owning" reference for DOMWindow to Document so
that we can directly traverse from Document to DOMWindow. For
traversing from DOMWindow to Document, each DOMWindow keeps a Document
pointer via a ContextDestructionObserver base class.

The main sublties in this patch are related to situations in which
there isn't precisely a one-to-one relationship between Documents and
DOMWindows. Previously, these situations were handled implicitly by the
"flex and slop" of having separate Document and DOMWindow pointers in
Frame. In this patch, these sublties are made explicit via
Document::takeDOMWindowFrom, which explicitly transfers the DOMWindow
(as well as ASSERTs that all the relevant objects exist in a sensible
constellation).

* WebCore.exp.in:
    - These functions are no longer exported because they're inline.
* bindings/js/ScriptController.cpp:
(WebCore::ScriptController::clearWindowShell):
* bindings/js/ScriptController.h:
(ScriptController):
    - clearWindowShell now explicitly takes the new DOMWindow that will
      be pointed to by the WindowShell. Previously, clearWindowShell
      would implicitly create the new DOMWindow by accessing
      Frame::domWindow (which used to lazily create the DOMWindow).
* bindings/v8/BindingState.cpp:
(WebCore::currentDocument):
* bindings/v8/BindingState.h:
(WebCore):
    - currentDocument provides a directly path from the current
      v8::Context to the Document (by way of DOMWindow). Previously,
      code transited via the Frame using currentFrame.
* bindings/v8/ScriptController.cpp:
(WebCore::ScriptController::clearWindowShell):
* bindings/v8/ScriptController.h:
(ScriptController):
    - Mirror JSC changes to clearWindowShell.
* bindings/v8/V8Utilities.cpp:
(WebCore::getScriptExecutionContext):
    - Update getScriptExecutionContext to transit directly from the
      DOMWindow to the Document rather than detouring via the Frame.
* dom/ContextDestructionObserver.cpp:
(WebCore::ContextDestructionObserver::ContextDestructionObserver):
(WebCore::ContextDestructionObserver::~ContextDestructionObserver):
(WebCore):
(WebCore::ContextDestructionObserver::observeContext):
* dom/ContextDestructionObserver.h:
(ContextDestructionObserver):
    - When we transfer a DOMWindow from one Document to another, we
      need to update the Document pointer in the DOMWindow to point to
      the new Document. The DOMWindow holds the Document pointer via
      ContextDestructionObserver, so this patch teaches
      ContextDestructionObserver how to change which
      ScriptExecutionContext it is observing. This code mirrors similar
      code in FrameDestructionObserver.
* dom/Document.cpp:
(WebCore::Document::~Document):
(WebCore::Document::detach):
(WebCore::Document::createDOMWindow):
    - createDOMWindow now explicitly creates the DOMWindow. Previously,
      we created the DOMWindow implicitly in Frame::domWindow when it
      was first accessed.
(WebCore::Document::takeDOMWindowFrom):
    - takeDOMWindowFrom explicitly transfers the DOMWindow from one
      Document to another. The main benefit of this function is the
      ASSERTs that ensure that the Document, DOMWindow, and Frame all
      point to each other the correct configuration.
(WebCore::Document::didUpdateSecurityOrigin):
    - We no longer need to keep the SecurityOrigin pointer in DOMWindow
      in sync with the Document because DOMWindow no longer has a
      SecurityOrigin object.
* dom/Document.h:
(Document):
(WebCore::Document::domWindow):
* history/CachedFrame.cpp:
(WebCore::CachedFrame::CachedFrame):
(WebCore::CachedFrame::destroy):
* history/CachedFrame.h:
(CachedFrameBase):
    - Previously, CachedFrame held the Document and the DOMWindow with
      separate pointers. Now, the CachedFrame holds the DOMWnidow via
      the Document, which makes adding and removing Documents from the
      PageCache simpler because we don't need to keep the Frame's
      DOMWindow pointer synchronized.
* loader/DocumentWriter.cpp:
(WebCore::DocumentWriter::begin):
    - begin now explicitly creates the DOMWindow and transfers
      DOMWindow when performing a "secure transition." Previously, both
      of these processes were handled implicitly: the DOMWindow was
      created implicitly by Frame::domWindow, and the DOMWindow was
      reused during navigation by not clearing Frame::m_domWindow.
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::cancelAndClear):
(WebCore::FrameLoader::clear):
    - These functions now pass the new Document so that we have access
      to the new DOMWindow in clearDOMWindowShell.
(WebCore::FrameLoader::setOpener):
    - We no longer need to keep the DOMWindow's SecurityOrigin in sync
      with the Document's SecurityOrigin because DOMWindow no longer
      has a duplicate SecurityOrigin pointer.
(WebCore::FrameLoader::open):
    - We no longer need to keep the Frame::m_domWindow in sync with the
      Document because the Document carries its own DOMWindow.
* loader/FrameLoader.h:
(FrameLoader):
* page/DOMWindow.cpp:
(WebCore::DOMWindow::DOMWindow):
    - DOMWindow now uses Document as its primary context object. In a
      future patch, we should remove the FrameDestructionObserver base
      class and instead access the frame via DOMWindow::document().
(WebCore::DOMWindow::didSecureTransitionTo):
    - Notify the DOMWindow that it is now associated with a new
      Document.
(WebCore::DOMWindow::scriptExecutionContext):
(WebCore::DOMWindow::document):
(WebCore::DOMWindow::securityOrigin):
    - These functions now retrieve the Document directly rather than
      transiting via the Frame.
* page/DOMWindow.h:
(WebCore::DOMWindow::create):
(DOMWindow):
* page/Frame.cpp:
(WebCore::Frame::setDocument):
    - Add more ASSERTs that the Document and its DOMWindow are properly
      wired up to this Frame.
(WebCore::Frame::domWindow):
    - Rather than lazily creating the DOMWindow, this function now just
      accesses the already-created DOMWindow on Document. Eventually,
      all callers should retreive the DOMWindow from the Document
      directly.
* page/Frame.h:
(WebCore::Frame::existingDOMWindow):
    - The DOMWindow always exists, so there is no distinction between
      domWindow() and existingDOMWindow().
* xml/XMLHttpRequest.cpp:
(WebCore::XMLHttpRequest::open):
    - Previously, open would exit early if it was unable to find its
      ScriptExecutionContext (e.g., if the ScriptExecutionContext was
      inactive). Now we can always locate the ScriptExecutionContext
      and so we need to test whether the ScriptExecutionContext is
      still attached to the Page before accessing Settings. Tests
      verify that the platform-visible behaviors of XMLHttpRequest are
      unchanged, even for XMLHttpRequest constructors associated with
      inactive Documents.
* xml/XSLTProcessor.cpp:
(WebCore::XSLTProcessor::createDocumentFromSource):
    - Make it explicit that XSLT re-uses the DOMWindow from the source
      Document in the transformed Document.

LayoutTests:

* fast/dom/Window/timer-null-script-execution-context.html:
    - This test was assuming that we'd throw an exception when we
      failed to find the script execution context. Now that we are
      always able to find the script execution context, we never throw
      that exception, even after GC. As far as I can tell, the original
      intent of the test was to make sure we don't crash in that case,
      which of course we don't.
* fast/dom/xmlhttprequest-constructor-in-detached-document-expected.txt:
    - Remove warning message about not being able to find the script
      execution context. We can now always find the script execution
      context.
* http/tests/security/MessagePort/event-listener-context-expected.txt:
* http/tests/security/MessagePort/event-listener-context.html:
    - This test is attempting to check that MessagePorts behave in a
      reasonable way when created in inactive documents. The test
      relies on us throwing an exception in the inactive case because
      we're unable to find the script execution context. We are now
      able to find the script execution context (as above), so we no
      longer throw the exception. It's not clear whether this test is
      valuable any more, but I've converted it to be a test that we
      don't crash in this situation.
* platform/chromium/fast/dom/xmlhttprequest-constructor-in-detached-document-expected.txt: Removed.
    - Remove platform-specific result as it now matches the cross-platform result.

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

8 years agoAccumulating LayoutUnits with floats for determining block preferred width can lead...
leviw@chromium.org [Tue, 14 Aug 2012 19:45:49 +0000 (19:45 +0000)]
Accumulating LayoutUnits with floats for determining block preferred width can lead to wrapping
https://bugs.webkit.org/show_bug.cgi?id=93513

Reviewed by Eric Seidel.

Source/WebCore:

Sub-pixel values from floats are subject to small losses in precision when accumulated with
floating point values, as we do in RenderBlock. This patch adds a new method to FractionalLayoutUnit --
ceilToFloat -- which guarantees us a floating point value at least as big as our original LayoutUnit
value, and uses it along with ceiledLayoutUnit to avoid underprovisioning RenderBlock's preferred
widths due to lost precision.

Test: fast/sub-pixel/block-preferred-widths-with-sub-pixel-floats.html

* platform/FractionalLayoutUnit.h:
(WebCore::FractionalLayoutUnit::ceilToFloat): Returns a float value the same or larger than the
FractionalLayoutUnit value.
(FractionalLayoutUnit):
(WebCore::FractionalLayoutUnit::epsilon): Now returns 0 when sub-pixel is disabled.
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::computeLogicalLocationForFloat): Adding a LayoutUnit::epsilon fudge factor
for fitting floats. This is probably necessary due to precision being lost elsewhere.
(WebCore::RenderBlock::computeInlinePreferredLogicalWidths): Ensure no precision is lost due to conversion
when accumulating our min/max width with floats.

LayoutTests:

Ensuring floats with sub-pixel values don't unnecessarily wrap.

* fast/sub-pixel/block-preferred-widths-with-sub-pixel-floats-expected.txt: Added.
* fast/sub-pixel/block-preferred-widths-with-sub-pixel-floats.html: Added.

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

8 years agoFullscreen/normal volume sliders don't stay in sync
jer.noble@apple.com [Tue, 14 Aug 2012 19:38:04 +0000 (19:38 +0000)]
Fullscreen/normal volume sliders don't stay in sync
https://bugs.webkit.org/show_bug.cgi?id=93867

Reviewed by Eric Carlson.

Source/WebCore:

Change the full screen volume slider, if present, when the media element's volume
changes.

Test: media/video-controls-fullscreen-volume.html

* html/shadow/MediaControlRootElement.cpp:
(WebCore::MediaControlRootElement::changedVolume):

LayoutTests:

New test checking that volume changes in the media element are reflected in the full
screen volume slider.

* media/video-controls-fullscreen-volume-expected.txt: Added.
* media/video-controls-fullscreen-volume.html: Added.
* platform/chromium/TestExpectations: Skip this test on chromium.

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

8 years agoRemove unused yyparse method in CSSParser
commit-queue@webkit.org [Tue, 14 Aug 2012 19:17:39 +0000 (19:17 +0000)]
Remove unused yyparse method in CSSParser
https://bugs.webkit.org/show_bug.cgi?id=93986

Patch by Olivier Blin <olivier.blin@softathome.com> on 2012-08-14
Reviewed by Darin Adler.

This method is unused and not even declared.

No new tests, it just removes unused code.

* css/CSSParser.h:

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

8 years ago[BlackBerry] Use Form helper functions to determine state in DOMSupport::isTextBasedC...
mifenton@rim.com [Tue, 14 Aug 2012 19:02:31 +0000 (19:02 +0000)]
[BlackBerry] Use Form helper functions to determine state in DOMSupport::isTextBasedContentEditableElement
https://bugs.webkit.org/show_bug.cgi?id=93992

Reviewed by Antonio Gomes.

Use form control helper functions to determine the editable state
of the input field.

* WebKitSupport/DOMSupport.cpp:
(BlackBerry::WebKit::DOMSupport::isTextBasedContentEditableElement):

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

8 years ago[chromium] Mark fast/regex/unicodeCaseInsensitive.html expectation as crashing
enne@google.com [Tue, 14 Aug 2012 18:54:32 +0000 (18:54 +0000)]
[chromium] Mark fast/regex/unicodeCaseInsensitive.html expectation as crashing
https://bugs.webkit.org/show_bug.cgi?id=94010

Unreviewed gardening. Update expectations.

* platform/chromium/TestExpectations:

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

8 years agoUpdate Test Expectations after r125578
robert@webkit.org [Tue, 14 Aug 2012 18:53:23 +0000 (18:53 +0000)]
Update Test Expectations after r125578

Unreviewed gardening.

* platform/chromium/TestExpectations:
* platform/efl/TestExpectations:
* platform/gtk/TestExpectations:
* platform/qt/Skipped:
* platform/qt/TestExpectations:

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

8 years ago[BlackBerry] Use constructor to initialize rect in TouchEventHandler::drawTapHighlight()
mifenton@rim.com [Tue, 14 Aug 2012 18:28:03 +0000 (18:28 +0000)]
[BlackBerry] Use constructor to initialize rect in TouchEventHandler::drawTapHighlight()
https://bugs.webkit.org/show_bug.cgi?id=93988

Reviewed by Antonio Gomes.

Use constructor to initialize rect in TouchEventHandler::drawTapHighlight()

* WebKitSupport/TouchEventHandler.cpp:
(BlackBerry::WebKit::TouchEventHandler::drawTapHighlight):

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

8 years ago[BlackBerry] Fix use of endsWith to use string instead of char.
mifenton@rim.com [Tue, 14 Aug 2012 18:23:55 +0000 (18:23 +0000)]
[BlackBerry] Fix use of endsWith to use string instead of char.
https://bugs.webkit.org/show_bug.cgi?id=93994

Reviewed by Antonio Gomes.

Regex comparison should use string instead of char comparison.

* WebKitSupport/DOMSupport.cpp:
(BlackBerry::WebKit::DOMSupport::elementPatternMatches):

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