WebKit.git
7 years agoAppease MSVC
oliver@apple.com [Tue, 12 Mar 2013 22:17:28 +0000 (22:17 +0000)]
Appease MSVC

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

7 years agoHarden JSStringJoiner
oliver@apple.com [Tue, 12 Mar 2013 22:15:54 +0000 (22:15 +0000)]
Harden JSStringJoiner
https://bugs.webkit.org/show_bug.cgi?id=112093

Reviewed by Filip Pizlo.

Harden JSStringJoiner, make it use our CheckedArithmetic
class to simplify everything.

* runtime/JSStringJoiner.cpp:
(JSC::JSStringJoiner::build):
* runtime/JSStringJoiner.h:
(JSStringJoiner):
(JSC::JSStringJoiner::JSStringJoiner):
(JSC::JSStringJoiner::append):

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

7 years agoAdd one more test expectation per bug 112176.
rniwa@webkit.org [Tue, 12 Mar 2013 22:04:22 +0000 (22:04 +0000)]
Add one more test expectation per bug 112176.

* platform/mac-wk2/TestExpectations:
* platform/mac/TestExpectations:

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

7 years agoMoved RunLoopTimer and SchedulePair to WTF
ggaren@apple.com [Tue, 12 Mar 2013 22:04:06 +0000 (22:04 +0000)]
Moved RunLoopTimer and SchedulePair to WTF
https://bugs.webkit.org/show_bug.cgi?id=112171

Reviewed by Oliver Hunt.

This will allow us to use timers in lower level primitives without
duplicating all the code.

../WebCore:

* WebCore.exp.in:
* WebCore.xcodeproj/project.pbxproj:
* loader/DocumentLoader.h:
(WTF):
(WebCore):
(DocumentLoader):
* loader/MainResourceLoader.h:
* page/Page.h:
* platform/AutodrainedPool.h: Removed.
* platform/cf/RunLoopTimerCF.cpp: Removed.
* platform/cf/SchedulePair.cpp: Removed.
* platform/cf/SchedulePair.h: Removed.
* platform/mac/AutodrainedPool.mm: Removed.
* platform/mac/SchedulePairMac.mm: Removed.
* platform/network/NetworkingContext.h:
* platform/network/ResourceHandle.h:
(WTF):
(WebCore):
(ResourceHandle):
* platform/network/cf/FormDataStreamCFNet.cpp:
* platform/network/mac/ResourceHandleMac.mm:

../WebKit/mac:

* WebCoreSupport/WebFrameNetworkingContext.h:
(WebFrameNetworkingContext):

../WebKit2:

* WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h:
(WebFrameNetworkingContext):

../WTF:

* WTF.xcodeproj/project.pbxproj:
* wtf/AutodrainedPool.h: Copied from Source/WebCore/platform/AutodrainedPool.h.
(AutodrainedPool):
* wtf/AutodrainedPoolMac.mm: Copied from Source/WebCore/platform/mac/AutodrainedPool.mm.
* wtf/RunLoopTimer.h: Copied from Source/WebCore/platform/RunLoopTimer.h.
* wtf/RunLoopTimerCF.cpp: Copied from Source/WebCore/platform/cf/RunLoopTimerCF.cpp.
* wtf/SchedulePair.cpp: Copied from Source/WebCore/platform/cf/SchedulePair.cpp.
* wtf/SchedulePair.h: Copied from Source/WebCore/platform/cf/SchedulePair.h.
(SchedulePair):
* wtf/SchedulePairMac.mm: Copied from Source/WebCore/platform/mac/SchedulePairMac.mm.

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

7 years agoRemove stray .gitmodules file
abarth@webkit.org [Tue, 12 Mar 2013 21:58:01 +0000 (21:58 +0000)]
Remove stray .gitmodules file
https://bugs.webkit.org/show_bug.cgi?id=112186

Reviewed by Tony Chang.

Apparently I imported this together with the jquery tests by mistake.

* jquery/resources/src/sizzle/.gitmodules: Removed.

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

7 years ago[Chromium] Remove WEBKIT_USING_V8 from the WebKit API
abarth@webkit.org [Tue, 12 Mar 2013 21:54:11 +0000 (21:54 +0000)]
[Chromium] Remove WEBKIT_USING_V8 from the WebKit API
https://bugs.webkit.org/show_bug.cgi?id=112120

Reviewed by Tony Chang.

Chromium always uses V8. This macro has outlived it's usefulness. It's
now just noise.

* README:
* public/WebArrayBuffer.h:
(WebArrayBuffer):
* public/WebArrayBufferView.h:
(WebArrayBufferView):
* public/WebBindings.h:
(WebBindings):
* public/WebBlob.h:
(WebBlob):
* public/WebFrame.h:
(WebFrame):
* public/WebFrameClient.h:
* public/WebSerializedScriptValue.h:
(WebSerializedScriptValue):
* src/WebArrayBuffer.cpp:
(WebKit::WebArrayBuffer::createFromV8Value):
* src/WebArrayBufferView.cpp:
(WebKit::WebArrayBufferView::createFromV8Value):
* src/WebBindings.cpp:
(WebKit::WebBindings::toV8Value):
* src/WebBlob.cpp:
(WebKit::WebBlob::toV8Value):
* src/WebFrameImpl.cpp:
(WebKit::WebFrame::frameForContext):
* src/WebFrameImpl.h:
(WebFrameImpl):
* src/WebSerializedScriptValue.cpp:
(WebKit::WebSerializedScriptValue::serialize):
(WebKit::WebSerializedScriptValue::deserialize):

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

7 years agoMac: Incorrect rendering of <audio> controls
commit-queue@webkit.org [Tue, 12 Mar 2013 21:53:19 +0000 (21:53 +0000)]
Mac: Incorrect rendering of <audio> controls
https://bugs.webkit.org/show_bug.cgi?id=110913

Patch by Christian Biesinger <cbiesinger@chromium.org> on 2013-03-12
Reviewed by Tony Chang.

Source/WebCore:

Covered by existing tests under media/.

* css/mediaControls.css:
(audio::-webkit-media-controls-timeline-container, video::-webkit-media-controls-timeline-container):
(audio::-webkit-media-controls-timeline, video::-webkit-media-controls-timeline):
The timeline container and the timeline need min-width: 0 so that they can shrink if needed.
* css/mediaControlsQuickTime.css:
(audio::-webkit-media-controls-timeline-container, video::-webkit-media-controls-timeline-container):
(audio::-webkit-media-controls-current-time-display, video::-webkit-media-controls-current-time-display):
(audio::-webkit-media-controls-time-remaining-display, video::-webkit-media-controls-time-remaining-display):
The timeline container also needs flex-start to ensure that it never overlaps
the play/rewind buttons. The current-time and remaining-time displays need min-width: 0 so that the hack
in RenderMediaControls.cpp works correctly - otherwise, RenderFlexibleBox tries to use the preferred width
of the time displays, which is wrong when they try to hide themselves.

LayoutTests:

* platform/mac/media/audio-controls-rendering-expected.txt:
* platform/mac/media/controls-after-reload-expected.txt:
* platform/mac/media/controls-strict-expected.txt:
* platform/mac/media/controls-styling-strict-expected.txt:
* platform/mac/media/controls-without-preload-expected.txt:
* platform/mac/media/video-controls-rendering-expected.txt:
* platform/mac/media/video-display-toggle-expected.txt:
* platform/mac/media/video-no-audio-expected.txt:
* platform/mac/media/video-playing-and-pause-expected.txt:

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

7 years agoAdd more Checked<> tests
oliver@apple.com [Tue, 12 Mar 2013 21:51:39 +0000 (21:51 +0000)]
Add more Checked<> tests
https://bugs.webkit.org/show_bug.cgi?id=112190

Reviewed by Geoffrey Garen.

Source/WTF:

Export the CheckedState enum type

* wtf/CheckedArithmetic.h:

Tools:

Tests!

* TestWebKitAPI/Tests/WTF/CheckedArithmeticOperations.cpp:
(TestWebKitAPI):

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

7 years agoCleanup: Move loading complete function into callback, rather than global.
jparent@chromium.org [Tue, 12 Mar 2013 21:47:23 +0000 (21:47 +0000)]
Cleanup: Move loading complete function into callback, rather than global.
https://bugs.webkit.org/show_bug.cgi?id=112167

Reviewed by Dirk Pranke.

Stop calling global functions, pass in proper handler to Loader
constructor. Note that the callback is optional, as tests, and
some potential dashboards, do not need one.

* TestResultServer/static-dashboards/dashboard_base.js:
* TestResultServer/static-dashboards/loader.js:
(.):
* TestResultServer/static-dashboards/loader_unittests.js:

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

7 years ago Improve logging in ResourceHandleMac.mm
ap@apple.com [Tue, 12 Mar 2013 21:10:45 +0000 (21:10 +0000)]
    Improve logging in ResourceHandleMac.mm
        https://bugs.webkit.org/show_bug.cgi?id=112185

        Reviewed by Brady Eidson.

        * platform/network/mac/ResourceHandleMac.mm:
        (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): Removed an obsolete #if.
        (WebCore::ResourceHandle::receivedCredential):
        (WebCore::ResourceHandle::receivedRequestToContinueWithoutCredential):
        (WebCore::ResourceHandle::receivedCancellation):
        (-[WebCoreResourceHandleAsDelegate connection:didCancelAuthenticationChallenge:]): Added a FIXME.
        (-[WebCoreResourceHandleAsDelegate connection:canAuthenticateAgainstProtectionSpace:]):

        * platform/network/mac/ResourceResponseMac.mm: Removed an unneeded include.

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

7 years agoMake CheckedArithmetic slightly more sane
oliver@apple.com [Tue, 12 Mar 2013 21:05:37 +0000 (21:05 +0000)]
Make CheckedArithmetic slightly more sane
https://bugs.webkit.org/show_bug.cgi?id=112178

Reviewed by Geoffrey Garen.

Add an enum type for safeGet rather than using a bool,
and correctly handle unsigned * unsigned, when one value
is 0.

* wtf/CheckedArithmetic.h:
(WTF::ENUM_CLASS):
(WTF):
(WTF::operator+):
(WTF::operator-):
(WTF::operator*):

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

7 years agoDFG generic array access cases should not be guarded by CheckStructure even of the...
fpizlo@apple.com [Tue, 12 Mar 2013 20:38:26 +0000 (20:38 +0000)]
DFG generic array access cases should not be guarded by CheckStructure even of the profiling tells us that it could be
https://bugs.webkit.org/show_bug.cgi?id=112183

Reviewed by Oliver Hunt.

Slight speed-up on string-unpack-code.

* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::findAndRemoveUnnecessaryStructureCheck):
(FixupPhase):
(JSC::DFG::FixupPhase::checkArray):
(JSC::DFG::FixupPhase::blessArrayOperation):

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

7 years agoSome canvas tests only fail on Mac EWS
rniwa@webkit.org [Tue, 12 Mar 2013 20:27:53 +0000 (20:27 +0000)]
Some canvas tests only fail on Mac EWS
https://bugs.webkit.org/show_bug.cgi?id=112176

Reviewed by Simon Fraser.

Add Failure / Pass test expectations on tests that only fail on Mac EWS bots.

Ideally, we can figure out the root cause of this failure and fix that problem but we haven't been able
to do so. We also don't have a way of adding test expectations only on EWS bots we're out of luck here.

* platform/mac/TestExpectations:

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

7 years agoUnreviewed, rolling out r145554.
commit-queue@webkit.org [Tue, 12 Mar 2013 20:11:58 +0000 (20:11 +0000)]
Unreviewed, rolling out r145554.
http://trac.webkit.org/changeset/145554
https://bugs.webkit.org/show_bug.cgi?id=112182

Breaks several extension browser tests (see bug for details)
(Requested by jamesr on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2013-03-12

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateHeader):
(GenerateDomainSafeFunctionGetter):
(GenerateImplementation):
(CreateCustomSignature):
* bindings/scripts/test/V8/V8Float64Array.cpp:
(WebCore::ConfigureV8Float64ArrayTemplate):
(WebCore::V8Float64Array::GetTemplate):
(WebCore::V8Float64Array::HasInstance):
* bindings/scripts/test/V8/V8Float64Array.h:
(V8Float64Array):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetter):
(WebCore::ConfigureV8TestActiveDOMObjectTemplate):
(WebCore::V8TestActiveDOMObject::GetTemplate):
(WebCore::V8TestActiveDOMObject::HasInstance):
* bindings/scripts/test/V8/V8TestActiveDOMObject.h:
(V8TestActiveDOMObject):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
(WebCore::V8TestCustomNamedGetter::GetTemplate):
(WebCore::V8TestCustomNamedGetter::HasInstance):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
(V8TestCustomNamedGetter):
* bindings/scripts/test/V8/V8TestEventConstructor.cpp:
(WebCore::V8TestEventConstructor::GetTemplate):
(WebCore::V8TestEventConstructor::HasInstance):
* bindings/scripts/test/V8/V8TestEventConstructor.h:
(V8TestEventConstructor):
* bindings/scripts/test/V8/V8TestEventTarget.cpp:
(WebCore::ConfigureV8TestEventTargetTemplate):
(WebCore::V8TestEventTarget::GetTemplate):
(WebCore::V8TestEventTarget::HasInstance):
* bindings/scripts/test/V8/V8TestEventTarget.h:
(V8TestEventTarget):
* bindings/scripts/test/V8/V8TestException.cpp:
(WebCore::V8TestException::GetTemplate):
(WebCore::V8TestException::HasInstance):
* bindings/scripts/test/V8/V8TestException.h:
(V8TestException):
* bindings/scripts/test/V8/V8TestInterface.cpp:
(WebCore::ConfigureV8TestInterfaceTemplate):
(WebCore::V8TestInterface::GetTemplate):
(WebCore::V8TestInterface::HasInstance):
* bindings/scripts/test/V8/V8TestInterface.h:
(V8TestInterface):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
(WebCore::V8TestMediaQueryListListener::GetTemplate):
(WebCore::V8TestMediaQueryListListener::HasInstance):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
(V8TestMediaQueryListListener):
* bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
(WebCore::V8TestNamedConstructor::GetTemplate):
(WebCore::V8TestNamedConstructor::HasInstance):
* bindings/scripts/test/V8/V8TestNamedConstructor.h:
(V8TestNamedConstructor):
* bindings/scripts/test/V8/V8TestNode.cpp:
(WebCore::V8TestNode::GetTemplate):
(WebCore::V8TestNode::HasInstance):
* bindings/scripts/test/V8/V8TestNode.h:
(V8TestNode):
* bindings/scripts/test/V8/V8TestObj.cpp:
(WebCore::ConfigureV8TestObjTemplate):
(WebCore::V8TestObj::GetTemplate):
(WebCore::V8TestObj::HasInstance):
* bindings/scripts/test/V8/V8TestObj.h:
(V8TestObj):
* bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
(WebCore::V8TestOverloadedConstructors::GetTemplate):
(WebCore::V8TestOverloadedConstructors::HasInstance):
* bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
(V8TestOverloadedConstructors):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
(WebCore::V8TestSerializedScriptValueInterface::GetTemplate):
(WebCore::V8TestSerializedScriptValueInterface::HasInstance):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
(V8TestSerializedScriptValueInterface):
* bindings/scripts/test/V8/V8TestTypedefs.cpp:
(WebCore::ConfigureV8TestTypedefsTemplate):
(WebCore::V8TestTypedefs::GetTemplate):
(WebCore::V8TestTypedefs::HasInstance):
* bindings/scripts/test/V8/V8TestTypedefs.h:
(V8TestTypedefs):
* bindings/v8/V8AdaptorFunction.cpp:
(WebCore::V8AdaptorFunction::getTemplate):
* bindings/v8/V8GCController.cpp:
* bindings/v8/V8PerIsolateData.cpp:
(WebCore::V8PerIsolateData::reportMemoryUsage):
(WebCore::V8PerIsolateData::privateTemplate):
(WebCore::V8PerIsolateData::rawTemplate):
(WebCore::V8PerIsolateData::hasInstance):
* bindings/v8/V8PerIsolateData.h:
(WebCore::V8PerIsolateData::rawTemplateMap):
(WebCore::V8PerIsolateData::templateMap):
(V8PerIsolateData):
* bindings/v8/WrapperTypeInfo.h:
* bindings/v8/custom/V8LocationCustom.cpp:
(WebCore::V8Location::reloadAttrGetterCustom):
(WebCore::V8Location::replaceAttrGetterCustom):
(WebCore::V8Location::assignAttrGetterCustom):
* bindings/v8/custom/V8NodeListCustom.cpp:
(WebCore::V8NodeList::opaqueRootForGC):

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

7 years ago[chromium] Use lipo(1) rather than file(1) to list library architectures.
gavinp@chromium.org [Tue, 12 Mar 2013 19:43:41 +0000 (19:43 +0000)]
[chromium] Use lipo(1) rather than file(1) to list library architectures.
https://bugs.webkit.org/show_bug.cgi?id=111147

Parsing file(1) output can be fragile; this patch replaces a use of file(1) to get
the architecture list of a library with an invocation of lipo(1), which should be more
stable.

Reviewed by Nico Weber.

No new tests, since adjust_visibility.sh doesn't have a test.

* WebCore.gyp/mac/adjust_visibility.sh:

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

7 years ago[BlackBerry] Prevent text selection inside Colour and Date/Time input fields
mifenton@rim.com [Tue, 12 Mar 2013 18:38:33 +0000 (18:38 +0000)]
[BlackBerry] Prevent text selection inside Colour and Date/Time input fields
https://bugs.webkit.org/show_bug.cgi?id=111733

Reviewed by Rob Buis.

PR 305194.

Skip rendering of selection if it is in a popup driven
input field.  This covers situations where EditorClientBlackBerry::shouldChangeSelectedRange
is either not called or focus is not complete when called.

Informally reviewed by Gen Mak.

* WebKitSupport/SelectionHandler.cpp:
(BlackBerry::WebKit::SelectionHandler::selectionPositionChanged):
(WebKit):

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

7 years agoMac rebaseline.
rniwa@webkit.org [Tue, 12 Mar 2013 18:28:32 +0000 (18:28 +0000)]
Mac rebaseline.

Rubber-stamped by Simon Fraser.

* platform/mac/compositing/overflow/composited-scrolling-paint-phases-expected.txt:

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

7 years agoWebkit unable to show gifs with applcation extension string shorter than 11 bytes
commit-queue@webkit.org [Tue, 12 Mar 2013 18:27:07 +0000 (18:27 +0000)]
Webkit unable to show gifs with applcation extension string shorter than 11 bytes
https://bugs.webkit.org/show_bug.cgi?id=110620

Patch by Viatcheslav Ostapenko <sl.ostapenko@samsung.com> on 2013-03-12
Reviewed by Laszlo Gombos.

Source/WebCore:

Use actual block size for gifs application extension string even if it is below 11 bytes
to be able to decode this kind of gifs.

Test: fast/images/gif-short-app-extension-string.html

* platform/image-decoders/gif/GIFImageReader.cpp:
(GIFImageReader::decodeInternal):

LayoutTests:

Test that webkit is able to decode gifs with short application extension string.

* fast/images/gif-short-app-extension-string-expected.png: Added.
* fast/images/gif-short-app-extension-string-expected.txt: Added.
* fast/images/gif-short-app-extension-string.html: Added.
* fast/images/resources/short-app-extension-string.gif: Added.

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

7 years ago[chromium] Remove unused WebIOSurfaceLayer type
commit-queue@webkit.org [Tue, 12 Mar 2013 18:26:51 +0000 (18:26 +0000)]
[chromium] Remove unused WebIOSurfaceLayer type
https://bugs.webkit.org/show_bug.cgi?id=111796

Patch by James Robinson <jamesr@chromium.org> on 2013-03-12
Reviewed by Adrienne Walker.

This has been dead code since http://trac.webkit.org/changeset/138223

* Platform.gypi:
* chromium/public/WebCompositorSupport.h:
(WebKit):
* chromium/public/WebIOSurfaceLayer.h: Removed.

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

7 years agoUnreviewed, rolling out r145277.
commit-queue@webkit.org [Tue, 12 Mar 2013 18:20:02 +0000 (18:20 +0000)]
Unreviewed, rolling out r145277.
http://trac.webkit.org/changeset/145277
https://bugs.webkit.org/show_bug.cgi?id=112170

chromium-gpu and android testers are seeing failures/crashes
relating to this code (Requested by eseidel on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2013-03-12

* html/parser/BackgroundHTMLInputStream.cpp:
(WebCore::BackgroundHTMLInputStream::rewindTo):
* html/parser/BackgroundHTMLInputStream.h:
(BackgroundHTMLInputStream):
(Checkpoint):
* html/parser/BackgroundHTMLParser.cpp:
* html/parser/BackgroundHTMLParser.h:
(BackgroundHTMLParser):
* html/parser/HTMLDocumentParser.cpp:
(WebCore::HTMLDocumentParser::pumpPendingSpeculations):

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

7 years ago[EFL][WK2] Add popup menu support to MiniBrowser
ch.dumez@sisa.samsung.com [Tue, 12 Mar 2013 18:02:05 +0000 (18:02 +0000)]
[EFL][WK2] Add popup menu support to MiniBrowser
https://bugs.webkit.org/show_bug.cgi?id=108934

Reviewed by Kenneth Rohde Christiansen.

Implement popup menu support in MiniBrowser by handling popup_menu_show
and popup_menu_hide smart functions on the view and using the Ewk popup
menu API.

* MiniBrowser/efl/main.c:
(_Browser_Window):
(on_popup_menu_discarded):
(on_popup_menu_item_clicked):
(popup_menu_populate):
(on_popup_menu_show):
(on_popup_menu_hide):
(window_create): Use calloc() instead of malloc() to allocate memory for
Browser_Window. This makes sure all the structs members are initialized
to 0 (such as the new elm_popup_menu pointer).

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

7 years agoKeep track of the number of GraphicsLayers with tiled backing in RenderLayerCompositor
simon.fraser@apple.com [Tue, 12 Mar 2013 17:54:44 +0000 (17:54 +0000)]
Keep track of the number of GraphicsLayers with tiled backing in RenderLayerCompositor
https://bugs.webkit.org/show_bug.cgi?id=112083

Reviewed by Dean Jackson.

Have RenderLayerCompositor keep track of how many of its GraphicsLayers use TiledBacking.
This is useful for platforms to decide whether it's necessary to force GraphicsLayer flushes
to update the visibleRect of those TiledBackings.

GraphicsLayers are always created without TiledBacking. There are two
ways the count can change:
1. A GraphicsLayerCA toggles into or out of tiled mode. It notifies its
   client via a new tiledBackingUsageChanged() callback on GraphicsLayerClient.
2. A tiled GraphicsLayerCA is destroyed. Added a new bottleneck function to
   RenderLayerBacking::willDestroyLayer() that is called everywhere we destroy layers.

The main page TiledBacking is not counted as part of this.

Also renamed uses of "tiledLayer" to "tiledBacking" in GraphicsLayer[CA].

* platform/graphics/GraphicsLayer.cpp:
(WebCore::GraphicsLayer::GraphicsLayer):
(WebCore::GraphicsLayer::getDebugBorderInfo):
(WebCore::GraphicsLayer::dumpProperties):
* platform/graphics/GraphicsLayer.h:
(WebCore::GraphicsLayer::usingTiledBacking):
* platform/graphics/GraphicsLayerClient.h:
(WebCore::GraphicsLayerClient::tiledBackingUsageChanged):
* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::GraphicsLayerCA::recursiveCommitChanges):
(WebCore::GraphicsLayerCA::updateGeometry):
(WebCore::GraphicsLayerCA::updateLayerDrawsContent):
(WebCore::GraphicsLayerCA::updateContentsScale):
(WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::willDestroyLayer):
(WebCore::RenderLayerBacking::tiledBackingUsageChanged):
(WebCore::RenderLayerBacking::destroyGraphicsLayers):
(WebCore::RenderLayerBacking::updateClippingLayers):
(WebCore::RenderLayerBacking::updateOverflowControlsLayers):
(WebCore::RenderLayerBacking::updateForegroundLayer):
(WebCore::RenderLayerBacking::updateBackgroundLayer):
(WebCore::RenderLayerBacking::updateMaskLayer):
(WebCore::RenderLayerBacking::updateScrollingLayers):
(WebCore::RenderLayerBacking::compositingLayerType):
* rendering/RenderLayerBacking.h:
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::RenderLayerCompositor):
(WebCore::RenderLayerCompositor::layerTiledBackingUsageChanged):
* rendering/RenderLayerCompositor.h:
(WebCore::RenderLayerCompositor::haveNonMainLayersWithTiledBacking):

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

7 years agoReplace static_casts with to* functions.
inferno@chromium.org [Tue, 12 Mar 2013 17:44:37 +0000 (17:44 +0000)]
Replace static_casts with to* functions.
https://bugs.webkit.org/show_bug.cgi?id=112072

Reviewed by Philip Rogers.

to* functions are preferred over static_cast calls since they
help to catch bad casts easily on the testing infrastructure.

Source/WebCore:

* accessibility/AccessibilityMenuList.cpp:
(WebCore::AccessibilityMenuList::canSetFocusAttribute):
* bindings/objc/DOM.mm:
(kitClass):
* bindings/v8/V8LazyEventListener.cpp:
(WebCore::V8LazyEventListener::prepareListenerObject):
* css/SelectorChecker.cpp:
(WebCore::SelectorChecker::checkOne):
* editing/ApplyStyleCommand.cpp:
(WebCore::isLegacyAppleStyleSpan):
(WebCore::isEmptyFontTag):
(WebCore::ApplyStyleCommand::applyBlockStyle):
* editing/FormatBlockCommand.cpp:
(WebCore::isElementForFormatBlock):
* editing/ReplaceSelectionCommand.cpp:
(WebCore::isMailPasteAsQuotationNode):
(WebCore::haveSameTagName):
(WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline):
(WebCore::ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder):
* history/CachedPage.cpp:
(WebCore::CachedPage::restore):
* html/ColorInputType.cpp:
(WebCore::ColorInputType::suggestions):
* html/HTMLTableRowsCollection.cpp:
(WebCore::isInHead):
(WebCore::isInBody):
(WebCore::isInFoot):
* inspector/DOMPatchSupport.cpp:
(WebCore::DOMPatchSupport::innerPatchNode):
* page/PageSerializer.cpp:
(WebCore::SerializerMarkupAccumulator::appendCustomAttributes):
* plugins/PluginView.cpp:
(WebCore::PluginView::getValue):
* rendering/RenderEmbeddedObject.cpp:
(WebCore::RenderEmbeddedObject::paintContents):
(WebCore::RenderEmbeddedObject::handleUnavailablePluginIndicatorEvent):
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::name):
* rendering/RenderMedia.cpp:
(WebCore::RenderMedia::mediaElement):
* rendering/RenderSearchField.cpp:
(WebCore::RenderSearchField::autosaveName):
* rendering/RenderTextControl.cpp:
(WebCore::RenderTextControl::textFormControlElement):
(WebCore::updateUserModifyProperty):
* rendering/mathml/RenderMathMLFenced.cpp:
(WebCore::RenderMathMLFenced::updateFromElement):
* rendering/mathml/RenderMathMLFraction.cpp:
(WebCore::RenderMathMLFraction::updateFromElement):
* xml/parser/XMLDocumentParserLibxml2.cpp:
(WebCore::XMLDocumentParser::XMLDocumentParser):
(WebCore::XMLDocumentParser::endElementNs):

Source/WebKit/chromium:

* src/ChromeClientImpl.cpp:
(WebKit::ChromeClientImpl::focusedNodeChanged):
* src/ContextMenuClientImpl.cpp:
(WebKit::ContextMenuClientImpl::getCustomMenuFromDefaultItems):
* src/DOMUtilitiesPrivate.cpp:
(WebCore::toHTMLElement):
* src/WebSearchableFormData.cpp:
(HTMLNames::IsSelectInDefaultState):

Source/WebKit/mac:

* WebView/WebView.mm:
(-[WebView _enterFullscreenForNode:WebCore::]):

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

7 years ago[GTK] Remove HILDON_CPPFLAGS and HILDON_CFLAGS references from GNUmakefiles
zandobersek@gmail.com [Tue, 12 Mar 2013 17:42:28 +0000 (17:42 +0000)]
[GTK] Remove HILDON_CPPFLAGS and HILDON_CFLAGS references from GNUmakefiles
https://bugs.webkit.org/show_bug.cgi?id=112163

Reviewed by Martin Robinson.

Source/WebCore:

No new tests - no new functionality, merely a cleanup.

* GNUmakefile.am: The Hildon dependency doesn't exist anymore so there's no need for
references to HILDON_CPPFLAGS and HILDON_CFLAGS.

Source/WebKit2:

* GNUmakefile.am: The Hildon dependency doesn't exist anymore so there's no need for
references to HILDON_CPPFLAGS and HILDON_CFLAGS.

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

7 years ago[GTK] 'unrecognized command line option "-Wno-c++11-extensions"' warning reported...
zandobersek@gmail.com [Tue, 12 Mar 2013 17:40:40 +0000 (17:40 +0000)]
[GTK] 'unrecognized command line option "-Wno-c++11-extensions"' warning reported when using gcc
https://bugs.webkit.org/show_bug.cgi?id=111936

Reviewed by Martin Robinson.

* Source/autotools/SetupCompilerFlags.m4: Only use the -Wno-c++11-extensions warning when building
with Clang as GCC does not support the warning just yet. Also enhance the comment about using libstdc++
as the standard C++ library when compiling with Clang.

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

7 years agoNot reviewed: removing GtkVersioning from chromium targets.
pfeldman@chromium.org [Tue, 12 Mar 2013 17:26:13 +0000 (17:26 +0000)]
Not reviewed: removing GtkVersioning from chromium targets.

* WebCore.gypi:

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

7 years agoUnreviewed GTK gardening.
zandobersek@gmail.com [Tue, 12 Mar 2013 17:00:13 +0000 (17:00 +0000)]
Unreviewed GTK gardening.

* platform/gtk/TestExpectations: Adding failure expectations for two crashers and a flaky test.
* platform/gtk/fast/js/global-constructors-expected.txt: Rebaselining after r145526.
* platform/gtk/http/tests/security/xssAuditor: Added. Adding baselines for tests introduced in r145503.
* platform/gtk/http/tests/security/xssAuditor/xss-filter-bypass-big5-expected.txt: Added.
* platform/gtk/http/tests/security/xssAuditor/xss-filter-bypass-sjis-expected.txt: Added.

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

7 years ago[V8] Store main world and non-main world templates separately.
commit-queue@webkit.org [Tue, 12 Mar 2013 16:44:18 +0000 (16:44 +0000)]
[V8] Store main world and non-main world templates separately.
https://bugs.webkit.org/show_bug.cgi?id=111724

Patch by Marja Hölttä <marja@chromium.org> on 2013-03-12
Reviewed by Jochen Eisinger.

This is needed for generating specialized bindings for the main
world (bug 110874).

No new tests (updated existing bindings tests).

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateHeader):
(GenerateDomainSafeFunctionGetter):
(GenerateImplementation):
(CreateCustomSignature):
* bindings/scripts/test/V8/V8Float64Array.cpp:
(WebCore::ConfigureV8Float64ArrayTemplate):
(WebCore::V8Float64Array::GetTemplate):
(WebCore::V8Float64Array::HasInstance):
* bindings/scripts/test/V8/V8Float64Array.h:
(V8Float64Array):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetter):
(WebCore::ConfigureV8TestActiveDOMObjectTemplate):
(WebCore::V8TestActiveDOMObject::GetTemplate):
(WebCore::V8TestActiveDOMObject::HasInstance):
* bindings/scripts/test/V8/V8TestActiveDOMObject.h:
(V8TestActiveDOMObject):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
(WebCore::V8TestCustomNamedGetter::GetTemplate):
(WebCore::V8TestCustomNamedGetter::HasInstance):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
(V8TestCustomNamedGetter):
* bindings/scripts/test/V8/V8TestEventConstructor.cpp:
(WebCore::V8TestEventConstructor::GetTemplate):
(WebCore::V8TestEventConstructor::HasInstance):
* bindings/scripts/test/V8/V8TestEventConstructor.h:
(V8TestEventConstructor):
* bindings/scripts/test/V8/V8TestEventTarget.cpp:
(WebCore::ConfigureV8TestEventTargetTemplate):
(WebCore::V8TestEventTarget::GetTemplate):
(WebCore::V8TestEventTarget::HasInstance):
* bindings/scripts/test/V8/V8TestEventTarget.h:
(V8TestEventTarget):
* bindings/scripts/test/V8/V8TestException.cpp:
(WebCore::V8TestException::GetTemplate):
(WebCore::V8TestException::HasInstance):
* bindings/scripts/test/V8/V8TestException.h:
(V8TestException):
* bindings/scripts/test/V8/V8TestInterface.cpp:
(WebCore::ConfigureV8TestInterfaceTemplate):
(WebCore::V8TestInterface::GetTemplate):
(WebCore::V8TestInterface::HasInstance):
* bindings/scripts/test/V8/V8TestInterface.h:
(V8TestInterface):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
(WebCore::V8TestMediaQueryListListener::GetTemplate):
(WebCore::V8TestMediaQueryListListener::HasInstance):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
(V8TestMediaQueryListListener):
* bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
(WebCore::V8TestNamedConstructor::GetTemplate):
(WebCore::V8TestNamedConstructor::HasInstance):
* bindings/scripts/test/V8/V8TestNamedConstructor.h:
(V8TestNamedConstructor):
* bindings/scripts/test/V8/V8TestNode.cpp:
(WebCore::V8TestNode::GetTemplate):
(WebCore::V8TestNode::HasInstance):
* bindings/scripts/test/V8/V8TestNode.h:
(V8TestNode):
* bindings/scripts/test/V8/V8TestObj.cpp:
(WebCore::ConfigureV8TestObjTemplate):
(WebCore::V8TestObj::GetTemplate):
(WebCore::V8TestObj::HasInstance):
* bindings/scripts/test/V8/V8TestObj.h:
(V8TestObj):
* bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
(WebCore::V8TestOverloadedConstructors::GetTemplate):
(WebCore::V8TestOverloadedConstructors::HasInstance):
* bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
(V8TestOverloadedConstructors):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
(WebCore::V8TestSerializedScriptValueInterface::GetTemplate):
(WebCore::V8TestSerializedScriptValueInterface::HasInstance):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
(V8TestSerializedScriptValueInterface):
* bindings/scripts/test/V8/V8TestTypedefs.cpp:
(WebCore::ConfigureV8TestTypedefsTemplate):
(WebCore::V8TestTypedefs::GetTemplate):
(WebCore::V8TestTypedefs::HasInstance):
* bindings/scripts/test/V8/V8TestTypedefs.h:
(V8TestTypedefs):
* bindings/v8/V8AdaptorFunction.cpp:
(WebCore::V8AdaptorFunction::getTemplate):
* bindings/v8/V8GCController.cpp:
* bindings/v8/V8PerIsolateData.cpp:
(WebCore::V8PerIsolateData::reportMemoryUsage):
(WebCore::V8PerIsolateData::privateTemplate):
(WebCore::V8PerIsolateData::rawTemplate):
(WebCore::V8PerIsolateData::hasInstance):
* bindings/v8/V8PerIsolateData.h:
(WebCore::V8PerIsolateData::rawTemplateMap):
(V8PerIsolateData):
(WebCore::V8PerIsolateData::templateMap):
* bindings/v8/WrapperTypeInfo.h:
* bindings/v8/custom/V8LocationCustom.cpp:
(WebCore::V8Location::reloadAttrGetterCustom):
(WebCore::V8Location::replaceAttrGetterCustom):
(WebCore::V8Location::assignAttrGetterCustom):

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

7 years ago[BlackBerry] Notify client if the selection is in a subframe when started.
commit-queue@webkit.org [Tue, 12 Mar 2013 15:57:01 +0000 (15:57 +0000)]
[BlackBerry] Notify client if the selection is in a subframe when started.
https://bugs.webkit.org/show_bug.cgi?id=112065

Patch by Genevieve Mak <gmak@rim.com> on 2013-03-12
Reviewed by Rob Buis.

PR #278490
Internally Reviewed by Mike Fenton.

* Api/InRegionScroller.cpp:
(BlackBerry::WebKit::InRegionScrollerPrivate::updateSelectionScrollView):
(WebKit):
* Api/InRegionScroller_p.h:
(InRegionScrollerPrivate):
* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::updateSelectionScrollView):
(WebKit):
* Api/WebPageClient.h:
* Api/WebPage_p.h:
(WebPagePrivate):
* WebKitSupport/SelectionHandler.cpp:
(BlackBerry::WebKit::SelectionHandler::cancelSelection):
(BlackBerry::WebKit::SelectionHandler::setSelection):

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

7 years ago[GTK] Set up the libPlatformGtk.la library
zandobersek@gmail.com [Tue, 12 Mar 2013 15:54:34 +0000 (15:54 +0000)]
[GTK] Set up the libPlatformGtk.la library
https://bugs.webkit.org/show_bug.cgi?id=111738

Reviewed by Martin Robinson.

.:

* GNUmakefile.am: Define the two variables that will hold sources list and cppflags as required for the new library.
Include the new GNUmakefile.am that's now available under Source/Platform.

Source/Platform:

* GNUmakefile.am: Added. Set up the rules for building the new libPlatformGtk.la. For now it will be built in
the same way as libWebCoreGtk.la and in parallel with it while the sources are moved from Source/WebCore/platform
to Source/Platform/gtk and each migrated source file moves to be built in libPlatformGtk.la instead of libWebCoreGtk.la.
* GNUmakefile.list.am: Added. Lists the build targets for the libPlatformGtk.la.
* gtk/GtkVersioning.c: Renamed from Source/WebCore/platform/gtk/GtkVersioning.c. This file is independent of WebCore and can be moved
and changed to be built into libPlatformGtk.la right away.
* gtk/GtkVersioning.h: Renamed from Source/WebCore/platform/gtk/GtkVersioning.h. Ditto.

Source/WebCore:

No new tests - no new functionality.

* GNUmakefile.am: Reference platformgtk_cppflags, platformgtk_sources variables along with webcoregtk_cppflags, webcoregtk_sources variables.
* GNUmakefile.list.am: Removing GtkVersioning.c and GtkVersioning.h from the sources list, these files have been moved under Source/Platform.
* bindings/gobject/GNUmakefile.am: Ditto on the platformgtk_* variables.

Source/WebKit/gtk:

* GNUmakefile.am: Reference platformgtk_cppflags variable, libPlatformGtk.la along with webcoregtk_cppflags variable, libWebCoreGtk.la.
Adjust the path to GtkVersioning.c, the file has moved under Source/Platform.

Source/WebKit2:

* GNUmakefile.am: Reference platformgtk_cppflags variable, libPlatformGtk.la along with webcoregtk_cppflags variable, libWebCoreGtk.la.
Adjust the path to GtkVersioning.c, the file has moved under Source/Platform.

Tools:

* GNUmakefile.am: Reference platformgtk_cppflags variable along with webcoregtk_cppflags variable.
Adjust the path to GtkVersioning.c, the file has moved under Source/Platform.
* TestWebKitAPI/GNUmakefile.am: Reference platformgtk_cppflags variable along with webcoregtk_cppflags variable.

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

7 years agohttps://bugs.webkit.org/show_bug.cgi?id=112141
rgabor@webkit.org [Tue, 12 Mar 2013 15:28:10 +0000 (15:28 +0000)]
https://bugs.webkit.org/show_bug.cgi?id=112141
LLInt CLoop backend misses Double2Ints() on 32bit architectures

Reviewed by Filip Pizlo.

Implement Double2Ints() in CLoop backend of LLInt on 32bit architectures.

* llint/LowLevelInterpreter.cpp:
(LLInt):
(JSC::LLInt::Double2Ints):
* offlineasm/cloop.rb:

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

7 years ago[BlackBerry] Image,ImageBuffer: add missing parameters to methods
commit-queue@webkit.org [Tue, 12 Mar 2013 15:23:08 +0000 (15:23 +0000)]
[BlackBerry] Image,ImageBuffer: add missing parameters to methods
https://bugs.webkit.org/show_bug.cgi?id=112148

Patch by Alberto Garcia <agarcia@igalia.com> on 2013-03-12
Reviewed by Rob Buis.

BitmapImage::draw(), Image::drawPattern() and ImageBuffer::draw()
have a BlendMode parameter since r137011.

ImageBuffer::copyImage() has a ScaleBehavior parameter since r134100.

* platform/graphics/blackberry/ImageBlackBerry.cpp:
(WebCore::BitmapImage::draw):
(WebCore::Image::drawPattern):
* platform/graphics/blackberry/ImageBufferBlackBerry.cpp:
(WebCore::ImageBuffer::copyImage):
(WebCore::ImageBuffer::draw):

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

7 years ago[BlackBerry] MediaPlayerPrivate: fix call to MediaStreamDescriptor::label()
commit-queue@webkit.org [Tue, 12 Mar 2013 15:21:16 +0000 (15:21 +0000)]
[BlackBerry] MediaPlayerPrivate: fix call to MediaStreamDescriptor::label()
https://bugs.webkit.org/show_bug.cgi?id=112140

Patch by Alberto Garcia <agarcia@igalia.com> on 2013-03-12
Reviewed by Rob Buis.

MediaStreamDescriptor::id() was renamed to MediaStreamDescriptor::label() in r139352.

* platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
(WebCore::toWebMediaStreamDescriptor):

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

7 years agoWeb Inspector: [REGRESSION] StepInto (F11) and StepOut (Shift-F11) shortcuts toggle...
eustas@chromium.org [Tue, 12 Mar 2013 15:19:37 +0000 (15:19 +0000)]
Web Inspector: [REGRESSION] StepInto (F11) and StepOut (Shift-F11) shortcuts toggle Inspector window full-screen state
https://bugs.webkit.org/show_bug.cgi?id=112113

Reviewed by Alexander Pavlov.

Updated handlers missed in first patch. Added JSDocs to all handlers.

* inspector/front-end/Panel.js: Fixed JSDocs.
* inspector/front-end/CallStackSidebarPane.js:
Added return values. Added JSDocs.
* inspector/front-end/ScriptsPanel.js: Ditto.
* inspector/front-end/GoToLineDialog.js: Added JSDocs.
* inspector/front-end/TimelinePanel.js: Ditto.

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

7 years ago[BlackBerry] DisplayRefreshMonitor: rename m_timestamp back to m_monotonicAnimationSt...
commit-queue@webkit.org [Tue, 12 Mar 2013 15:17:58 +0000 (15:17 +0000)]
[BlackBerry] DisplayRefreshMonitor: rename m_timestamp back to m_monotonicAnimationStartTime
https://bugs.webkit.org/show_bug.cgi?id=112139

Patch by Alberto Garcia <agarcia@igalia.com> on 2013-03-12
Reviewed by Rob Buis.

This changed in r131131, but it was accidentally renamed back in r144465.

* platform/graphics/blackberry/DisplayRefreshMonitorBlackBerry.cpp:
(WebCore::DisplayRefreshMonitor::displayLinkFired):

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

7 years ago[BlackBerry] FontPlatformData: HarfBuzz renaming
commit-queue@webkit.org [Tue, 12 Mar 2013 15:16:03 +0000 (15:16 +0000)]
[BlackBerry] FontPlatformData: HarfBuzz renaming
https://bugs.webkit.org/show_bug.cgi?id=112142

Patch by Alberto Garcia <agarcia@igalia.com> on 2013-03-12
Reviewed by Rob Buis.

When the old HarfBuzz code was removed in r141291,
HarfBuzzNGFace.h was renamed to HarfBuzzFace.h and m_harfbuzzFace
was renamed to m_harfBuzzFace.

These changes need to be reflected in the BlackBerry port.

* platform/graphics/blackberry/FontPlatformDataBlackBerry.cpp:
(WebCore::FontPlatformData::FontPlatformData):
(WebCore::FontPlatformData::platformDataInit):
(WebCore::FontPlatformData::platformDataAssign):
(WebCore::FontPlatformData::harfBuzzFace):

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

7 years ago[Qt] Unreviewed gardening.
kadam@inf.u-szeged.hu [Tue, 12 Mar 2013 15:06:41 +0000 (15:06 +0000)]
[Qt] Unreviewed gardening.

* platform/qt-5.0-wk2/TestExpectations: Skipped two fullscreen tests after r144837 and r145214.
* platform/qt-5.0-wk2/compositing/layer-creation/fixed-position-change-out-of-view-in-view-expected.txt: Updated after r145422.
* platform/qt-5.0-wk2/compositing/rtl/rtl-iframe-absolute-overflow-expected.txt: Updated after r145422.
* platform/qt-5.0-wk2/compositing/rtl/rtl-iframe-absolute-overflow-scrolled-expected.txt: Updated after r145422.
* platform/qt-5.0-wk2/compositing/rtl/rtl-iframe-fixed-overflow-expected.txt: Updated after r145422.
* platform/qt-5.0-wk2/compositing/rtl/rtl-iframe-fixed-overflow-scrolled-expected.txt: Updated after r145422.
* platform/qt/compositing/overflow/composited-scrolling-paint-phases-expected.txt: Updated after r145422.

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

7 years ago[BlackBerry] FontCacheBlackBerry: return PassRefPtr<SimpleFontData>
commit-queue@webkit.org [Tue, 12 Mar 2013 15:00:04 +0000 (15:00 +0000)]
[BlackBerry] FontCacheBlackBerry: return PassRefPtr<SimpleFontData>
https://bugs.webkit.org/show_bug.cgi?id=112022

Patch by Alberto Garcia <agarcia@igalia.com> on 2013-03-12
Reviewed by Rob Buis.

FontData functions return PassRefPtr since r130160.

* platform/graphics/blackberry/FontCacheBlackBerry.cpp:
(WebCore::FontCache::getFontDataForCharacters):
(WebCore::FontCache::getSimilarFontPlatformData):
(WebCore::FontCache::getLastResortFallbackFont):
* platform/graphics/blackberry/SimpleFontDataBlackBerry.cpp:
(WebCore::SimpleFontData::createScaledFontData):

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

7 years agoWeb Inspector: Fix checkContentUpdated behavior in UISourceCode.
vsevik@chromium.org [Tue, 12 Mar 2013 14:53:30 +0000 (14:53 +0000)]
Web Inspector: Fix checkContentUpdated behavior in UISourceCode.
https://bugs.webkit.org/show_bug.cgi?id=112037

Reviewed by Alexander Pavlov.

UISourceCode.checkContentUpdated now saves last updated content that was loaded and rejected
by user on the per-file basis (only the last one was saved currently).

* inspector/front-end/FileSystemProjectDelegate.js:
(WebInspector.FileSystemProjectDelegate.prototype.innerCallback):
(WebInspector.FileSystemProjectDelegate.prototype.requestFileContent):
(WebInspector.FileSystemProjectDelegate.prototype.canSetFileContent):
(WebInspector.FileSystemWorkspaceProvider.prototype._fileSystemAdded):
* inspector/front-end/SimpleWorkspaceProvider.js:
(WebInspector.SimpleProjectDelegate.prototype.canSetFileContent):
* inspector/front-end/UISourceCode.js:
(WebInspector.UISourceCode.prototype.checkContentUpdated.contentLoaded):
(WebInspector.UISourceCode.prototype.checkContentUpdated):
(WebInspector.UISourceCode.prototype._commitContent):
(WebInspector.UISourceCode.prototype.addRevision):
(WebInspector.UISourceCode.prototype.commitWorkingCopy):
* inspector/front-end/Workspace.js:
(WebInspector.ProjectDelegate.prototype.canSetFileContent):
(WebInspector.Project.prototype.canSetFileContent):

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

7 years ago[Gtk] NBSP are not replaced when using X clipboard
commit-queue@webkit.org [Tue, 12 Mar 2013 14:51:19 +0000 (14:51 +0000)]
[Gtk] NBSP are not replaced when using X clipboard
https://bugs.webkit.org/show_bug.cgi?id=112118

Patch by Tomas Popela <tpopela@redhat.com> on 2013-03-12
Reviewed by Martin Robinson.

We're not replacing nbsp with spaces when using X clipboard
(Shift+Insert or middle mouse button).

* platform/gtk/DataObjectGtk.cpp:
(WebCore::DataObjectGtk::text):

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

7 years agoSVG Pattern pixelated on inline SVG with CSS transforms
fmalita@chromium.org [Tue, 12 Mar 2013 14:38:48 +0000 (14:38 +0000)]
SVG Pattern pixelated on inline SVG with CSS transforms
https://bugs.webkit.org/show_bug.cgi?id=111587

Reviewed by Dirk Schulze.

Source/WebCore:

When calculating the resolution for resource image buffers, we need to also consider CSS
transforms. This patch updates calculateTransformationToOutermostSVGCoordinateSystem()
(renamed to calculateTransformationToOutermostCoordinateSystem) to include the affine
component from CSS transforms by walking the parent layer tree.

Test: svg/custom/resources-css-scaled.html

* rendering/svg/RenderSVGResourceClipper.cpp:
(WebCore::RenderSVGResourceClipper::applyClippingToContext):
* rendering/svg/RenderSVGResourceFilter.cpp:
(WebCore::RenderSVGResourceFilter::applyResource):
* rendering/svg/RenderSVGResourceGradient.cpp:
(WebCore::createMaskAndSwapContextForTextGradient):
(WebCore::clipToTextMask):
* rendering/svg/RenderSVGResourceMasker.cpp:
(WebCore::RenderSVGResourceMasker::applyResource):
* rendering/svg/RenderSVGResourcePattern.cpp:
(WebCore::RenderSVGResourcePattern::buildPattern):
* rendering/svg/SVGRenderingContext.cpp:
(WebCore::SVGRenderingContext::calculateScreenFontSizeScalingFactor):
(WebCore::SVGRenderingContext::calculateTransformationToOutermostCoordinateSystem):
* rendering/svg/SVGRenderingContext.h:
(SVGRenderingContext):

LayoutTests:

* svg/custom/resources-css-scaled-expected.html: Added.
* svg/custom/resources-css-scaled.html: Added.

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

7 years agoWeb Inspector: add html canvas memory details to the native memory overview
yurys@chromium.org [Tue, 12 Mar 2013 14:35:33 +0000 (14:35 +0000)]
Web Inspector: add html canvas memory details to the native memory overview
https://bugs.webkit.org/show_bug.cgi?id=112123

Reviewed by Alexander Pavlov.

Show memory occupied vby HTMLCanvasElements under Image category
in the native memory overview.

* inspector/front-end/NativeHeapSnapshot.js:
(WebInspector.NativeHeapSnapshot.prototype.images.getImageName):
(WebInspector.NativeHeapSnapshot.prototype.images.getCanvasName):
(WebInspector.NativeHeapSnapshot.prototype.images):
(WebInspector.NativeHeapSnapshot.prototype._addNodes):

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

7 years agoWeb Inspector: ResourceScriptFile diverged state should be correctly reset after...
vsevik@chromium.org [Tue, 12 Mar 2013 13:10:40 +0000 (13:10 +0000)]
Web Inspector: ResourceScriptFile diverged state should be correctly reset after debugger reset.
https://bugs.webkit.org/show_bug.cgi?id=112036

Reviewed by Alexander Pavlov.

Source/WebCore:

* inspector/front-end/ResourceScriptMapping.js:
(WebInspector.ResourceScriptFile):
(WebInspector.ResourceScriptFile.prototype._workingCopyChanged):
(WebInspector.ResourceScriptFile.prototype._maybeDirtyChanged):

LayoutTests:

* inspector/debugger/file-system-project-mapping-expected.txt:
* inspector/debugger/file-system-project-mapping.html:

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

7 years ago[V8] Move the GetRawTemplate and HasInstance logic from generated bindings to V8PerIs...
commit-queue@webkit.org [Tue, 12 Mar 2013 13:02:05 +0000 (13:02 +0000)]
[V8] Move the GetRawTemplate and HasInstance logic from generated bindings to V8PerIsolateData
https://bugs.webkit.org/show_bug.cgi?id=112136

Patch by Marja Hölttä <marja@chromium.org> on 2013-03-12
Reviewed by Kentaro Hara.

When templates for main world and non-main worlds will be separated (bug
111724), HasInstance logic will be a bit ugly: We cannot determine the
world type on the fly, because during GC there is no entered context,
and HasInstance is called during GC. So we need to check against
templates from all the worlds. It's cleaner if that logic is in
V8PerIsolateData.

No new tests (Updated existing bindings tests).

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateHeader):
(GenerateDomainSafeFunctionGetter):
(GenerateImplementation):
(CreateCustomSignature):
* bindings/scripts/test/V8/V8Float64Array.cpp:
(WebCore::ConfigureV8Float64ArrayTemplate):
(WebCore::V8Float64Array::GetTemplate):
(WebCore::V8Float64Array::HasInstance):
* bindings/scripts/test/V8/V8Float64Array.h:
(V8Float64Array):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetter):
(WebCore::ConfigureV8TestActiveDOMObjectTemplate):
(WebCore::V8TestActiveDOMObject::GetTemplate):
(WebCore::V8TestActiveDOMObject::HasInstance):
* bindings/scripts/test/V8/V8TestActiveDOMObject.h:
(V8TestActiveDOMObject):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
(WebCore::V8TestCustomNamedGetter::GetTemplate):
(WebCore::V8TestCustomNamedGetter::HasInstance):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
(V8TestCustomNamedGetter):
* bindings/scripts/test/V8/V8TestEventConstructor.cpp:
(WebCore::V8TestEventConstructor::GetTemplate):
(WebCore::V8TestEventConstructor::HasInstance):
* bindings/scripts/test/V8/V8TestEventConstructor.h:
(V8TestEventConstructor):
* bindings/scripts/test/V8/V8TestEventTarget.cpp:
(WebCore::ConfigureV8TestEventTargetTemplate):
(WebCore::V8TestEventTarget::GetTemplate):
(WebCore::V8TestEventTarget::HasInstance):
* bindings/scripts/test/V8/V8TestEventTarget.h:
(V8TestEventTarget):
* bindings/scripts/test/V8/V8TestException.cpp:
(WebCore::V8TestException::GetTemplate):
(WebCore::V8TestException::HasInstance):
* bindings/scripts/test/V8/V8TestException.h:
(V8TestException):
* bindings/scripts/test/V8/V8TestInterface.cpp:
(WebCore::ConfigureV8TestInterfaceTemplate):
(WebCore::V8TestInterface::GetTemplate):
(WebCore::V8TestInterface::HasInstance):
* bindings/scripts/test/V8/V8TestInterface.h:
(V8TestInterface):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
(WebCore::V8TestMediaQueryListListener::GetTemplate):
(WebCore::V8TestMediaQueryListListener::HasInstance):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
(V8TestMediaQueryListListener):
* bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
(WebCore::V8TestNamedConstructor::GetTemplate):
(WebCore::V8TestNamedConstructor::HasInstance):
* bindings/scripts/test/V8/V8TestNamedConstructor.h:
(V8TestNamedConstructor):
* bindings/scripts/test/V8/V8TestNode.cpp:
(WebCore::V8TestNode::GetTemplate):
(WebCore::V8TestNode::HasInstance):
* bindings/scripts/test/V8/V8TestNode.h:
(V8TestNode):
* bindings/scripts/test/V8/V8TestObj.cpp:
(WebCore::ConfigureV8TestObjTemplate):
(WebCore::V8TestObj::GetTemplate):
(WebCore::V8TestObj::HasInstance):
* bindings/scripts/test/V8/V8TestObj.h:
(V8TestObj):
* bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
(WebCore::V8TestOverloadedConstructors::GetTemplate):
(WebCore::V8TestOverloadedConstructors::HasInstance):
* bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
(V8TestOverloadedConstructors):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
(WebCore::V8TestSerializedScriptValueInterface::GetTemplate):
(WebCore::V8TestSerializedScriptValueInterface::HasInstance):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
(V8TestSerializedScriptValueInterface):
* bindings/scripts/test/V8/V8TestTypedefs.cpp:
(WebCore::ConfigureV8TestTypedefsTemplate):
(WebCore::V8TestTypedefs::GetTemplate):
(WebCore::V8TestTypedefs::HasInstance):
* bindings/scripts/test/V8/V8TestTypedefs.h:
(V8TestTypedefs):
* bindings/v8/V8PerIsolateData.cpp:
(WebCore::V8PerIsolateData::rawTemplate):
(WebCore):
(WebCore::V8PerIsolateData::hasInstance):
* bindings/v8/V8PerIsolateData.h:
(V8PerIsolateData):
* bindings/v8/custom/V8LocationCustom.cpp:
(WebCore::V8Location::reloadAttrGetterCustom):
(WebCore::V8Location::replaceAttrGetterCustom):
(WebCore::V8Location::assignAttrGetterCustom):

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

7 years agoWeb Inspector: Fix JSDocs in TimelinePanel.js
eustas@chromium.org [Tue, 12 Mar 2013 12:45:30 +0000 (12:45 +0000)]
Web Inspector: Fix JSDocs in TimelinePanel.js
https://bugs.webkit.org/show_bug.cgi?id=112137

Reviewed by Vsevolod Vlasov.

Fix parameter type annotation of _loadFromFile.

* inspector/front-end/TimelinePanel.js: Fixed JSDoc.

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

7 years agoWeb Inspector: Add a test for Workspace add/removeMapping methods.
vsevik@chromium.org [Tue, 12 Mar 2013 12:42:14 +0000 (12:42 +0000)]
Web Inspector: Add a test for Workspace add/removeMapping methods.
https://bugs.webkit.org/show_bug.cgi?id=112035

Reviewed by Alexander Pavlov.

Source/WebCore:

Test: inspector/debugger/file-system-project-mapping.html

* inspector/front-end/ScriptsPanel.js:
(WebInspector.ScriptsPanel.prototype._mapFileSystemToNetwork.mapFileSystemToNetwork):
(WebInspector.ScriptsPanel.prototype._mapFileSystemToNetwork):
(WebInspector.ScriptsPanel.prototype._mapNetworkToFileSystem.mapNetworkToFileSystem):
(WebInspector.ScriptsPanel.prototype._mapNetworkToFileSystem):
* inspector/front-end/Workspace.js:
(WebInspector.Project.prototype._fileAdded):
(WebInspector.Workspace.prototype.addMapping):

LayoutTests:

* http/tests/inspector/isolated-filesystem-test.js: Added.
(initialize_IsolatedFileSystemTest.InspectorTest.createIsolatedFileSystemManager):
(initialize_IsolatedFileSystemTest.MockIsolatedFileSystem):
(initialize_IsolatedFileSystemTest.MockIsolatedFileSystem.prototype.path):
(initialize_IsolatedFileSystemTest.MockIsolatedFileSystem.prototype.requestFileContent):
(initialize_IsolatedFileSystemTest.MockIsolatedFileSystem.prototype.setFileContent):
(initialize_IsolatedFileSystemTest.MockIsolatedFileSystem.prototype.requestFilesRecursive):
(initialize_IsolatedFileSystemTest.MockIsolatedFileSystemManager):
(initialize_IsolatedFileSystemTest.MockIsolatedFileSystemManager.prototype.addMockFileSystem):
(initialize_IsolatedFileSystemTest.MockIsolatedFileSystemManager.prototype.removeMockFileSystem):
(initialize_IsolatedFileSystemTest):
* inspector/debugger/file-system-project-mapping-expected.txt: Added.
* inspector/debugger/file-system-project-mapping.html: Added.
* inspector/debugger/resource-script-mapping.html:
* inspector/file-system-project.html:

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

7 years ago[WK2][EFL] Fix EwkContext class API
mikhail.pozdnyakov@intel.com [Tue, 12 Mar 2013 12:32:37 +0000 (12:32 +0000)]
[WK2][EFL] Fix EwkContext class API
https://bugs.webkit.org/show_bug.cgi?id=111706

Reviewed by Alexey Proskuryakov.

* UIProcess/API/C/efl/WKView.cpp:
(createWKView):
* UIProcess/API/efl/ewk_context.cpp:
(EwkContext::findOrCreateWrapper):

    Renamed from create() as it returns the same instance of EwkContext
    for the given WKContextRef if present.

(EwkContext::create):
(EwkContext::defaultContext):

    Returns raw pointer rather than PassRefPtr<EwkContext> as ownership
    is not transferred.

(ewk_context_default_get):
* UIProcess/API/efl/ewk_context_private.h:
(EwkContext):
* UIProcess/efl/WebInspectorProxyEfl.cpp:
(WebKit::WebInspectorProxy::platformCreateInspectorPage):

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

7 years ago[BlackBerry] SelectionHandler: fix truncated line
commit-queue@webkit.org [Tue, 12 Mar 2013 12:29:32 +0000 (12:29 +0000)]
[BlackBerry] SelectionHandler: fix truncated line
https://bugs.webkit.org/show_bug.cgi?id=112133

Patch by Alberto Garcia <agarcia@igalia.com> on 2013-03-12
Reviewed by Carlos Garcia Campos.

One of the calls to fatFingersResult.nodeAsElementIfApplicable()
was somehow truncated when the selection start animation was
upstreamed in r144640.

* WebKitSupport/SelectionHandler.cpp:
(BlackBerry::WebKit::SelectionHandler::selectAtPoint):

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

7 years agoWeb Inspector: SourceFrames are leaking on reload.
vsevik@chromium.org [Tue, 12 Mar 2013 12:29:03 +0000 (12:29 +0000)]
Web Inspector: SourceFrames are leaking on reload.
https://bugs.webkit.org/show_bug.cgi?id=111961

Reviewed by Alexander Pavlov.

Source/WebCore:

Added dispose method on UISourceCodeFrame.
Scripts panel now calls dispose when SourceFrame is removed and JavaScriptSourceFrame
could remove breakpoint manager listeners in it.
TabbedEditorContainer does not call viewForFile other than in appendFileTab methods to
avoid recreating SourceFrame for uiSourceCode when it was already removed.

Test: inspector/debugger/breakpoint-manager-listeners-count.html

* inspector/front-end/JavaScriptSourceFrame.js:
(WebInspector.JavaScriptSourceFrame.prototype.dispose):
* inspector/front-end/ScriptsPanel.js:
* inspector/front-end/TabbedEditorContainer.js:
(WebInspector.TabbedEditorContainer.prototype._addScrollAndSelectionListeners):
(WebInspector.TabbedEditorContainer.prototype._removeScrollAndSelectionListeners):
(WebInspector.TabbedEditorContainer.prototype._tabClosed):
* inspector/front-end/UISourceCodeFrame.js:
(WebInspector.UISourceCodeFrame.prototype.dispose):

LayoutTests:

* inspector/debugger/breakpoint-manager-listeners-count-expected.txt: Added.
* inspector/debugger/breakpoint-manager-listeners-count.html: Added.

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

7 years agoWeb Inspector: [Elements] Unable to undo "Edit as HTML" changes in the editor
apavlov@chromium.org [Tue, 12 Mar 2013 12:23:41 +0000 (12:23 +0000)]
Web Inspector: [Elements] Unable to undo "Edit as HTML" changes in the editor
https://bugs.webkit.org/show_bug.cgi?id=112119

Reviewed by Vsevolod Vlasov.

No new tests, a UI change.

* inspector/front-end/ElementsPanel.js:
(WebInspector.ElementsPanel.prototype.handleShortcut): Do not undo/redo DOM/CSS changes if editing DOM text.
* inspector/front-end/ElementsTreeOutline.js:
(WebInspector.ElementsTreeOutline.prototype.editing): Added.

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

7 years agoWeb Inspector: [CodeMirror] there are bugs in TokenHighlight feature
commit-queue@webkit.org [Tue, 12 Mar 2013 12:15:21 +0000 (12:15 +0000)]
Web Inspector: [CodeMirror] there are bugs in TokenHighlight feature
https://bugs.webkit.org/show_bug.cgi?id=112039

Patch by Andrey Lushnikov <lushnikov@chromium.org> on 2013-03-12
Reviewed by Vsevolod Vlasov.

Fix token highlight in codeMirror experiment
- rewrite token highlight overlay mode to highlight words, not
substrings
- add workaround to avoid selection of already selected word

No new tests.

* inspector/front-end/CodeMirrorTextEditor.js:
(WebInspector.CodeMirrorTextEditor.TokenHighlighter.prototype._cursorChange):
(WebInspector.CodeMirrorTextEditor.TokenHighlighter.prototype._removeHighlight):
(WebInspector.CodeMirrorTextEditor.TokenHighlighter.prototype.nextToken):
(WebInspector.CodeMirrorTextEditor.TokenHighlighter.prototype._addHighlight):
* inspector/front-end/cm/cmdevtools.css:
(.line-with-selection .cm-column-with-selection):

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

7 years ago[BlackBerry] Fix visible_units.h includes
commit-queue@webkit.org [Tue, 12 Mar 2013 12:11:58 +0000 (12:11 +0000)]
[BlackBerry] Fix visible_units.h includes
https://bugs.webkit.org/show_bug.cgi?id=112131

Patch by Alberto Garcia <agarcia@igalia.com> on 2013-03-12
Reviewed by Carlos Garcia Campos.

This file was renamed to VisibleUnits.h in r144911.

* WebKitSupport/DOMSupport.cpp:
* WebKitSupport/InputHandler.cpp:
* WebKitSupport/SelectionHandler.cpp:
* WebKitSupport/SpellingHandler.cpp:

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

7 years ago[GTK] Enable Web Audio in development builds
zandobersek@gmail.com [Tue, 12 Mar 2013 11:56:13 +0000 (11:56 +0000)]
[GTK] Enable Web Audio in development builds
https://bugs.webkit.org/show_bug.cgi?id=111831

Reviewed by Philippe Normand.

Source/WebKit2:

* GNUmakefile.am: Link the plugin process against libWebCoreModules.la as well.

Tools:

Web Audio is already quite well supported on the GTK port but still has a few issues
that must be addressed before it is enabled by default. Despite that it should be enabled
in development builds just so we are up-to-date with future feature infrastructure changes.
The Web Audio-related layout tests are not run yet due to missing support in DRT/WKTR, but
that's an obvious goal before enabling the feature in release builds.

* Scripts/webkitperl/FeatureList.pm:

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

7 years agoUnreviewed, rolling out r145514.
falken@chromium.org [Tue, 12 Mar 2013 11:38:57 +0000 (11:38 +0000)]
Unreviewed, rolling out r145514.
http://trac.webkit.org/changeset/145514
https://bugs.webkit.org/show_bug.cgi?id=112134

breaks Mac build (Requested by falken on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2013-03-12

* dom/Element.cpp:
* dom/Element.h:
* dom/EventDispatcher.cpp:
(WebCore::EventDispatcher::dispatchSimulatedClick):
* dom/GestureEvent.cpp:
(WebCore::GestureEventDispatchMediator::dispatchEvent):
* dom/MouseEvent.cpp:
(WebCore::MouseEventDispatchMediator::dispatchEvent):
* dom/Node.cpp:
(WebCore):
(WebCore::Node::isInert):
(WebCore::Node::handleLocalEvents):
(WebCore::Node::disabled):
(WebCore::Node::willRespondToMouseMoveEvents):
(WebCore::Node::willRespondToMouseClickEvents):
(WebCore::Node::willRespondToTouchEvents):
* dom/Node.h:
(Node):

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

7 years agoUnreviewed EFL gardening.
commit-queue@webkit.org [Tue, 12 Mar 2013 11:26:44 +0000 (11:26 +0000)]
Unreviewed EFL gardening.
https://bugs.webkit.org/show_bug.cgi?id=112130

Gardening; assigning bug numbers to failure accessibility tests.

Patch by Krzysztof Czech <k.czech@samsung.com> on 2013-03-12

* platform/efl-wk1/TestExpectations:
* platform/efl-wk2/TestExpectations:

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

7 years agoWeb Inspector: [CodeMirror] highlight matching braces
commit-queue@webkit.org [Tue, 12 Mar 2013 11:18:54 +0000 (11:18 +0000)]
Web Inspector: [CodeMirror] highlight matching braces
https://bugs.webkit.org/show_bug.cgi?id=112041

Patch by Andrey Lushnikov <lushnikov@chromium.org> on 2013-03-12
Reviewed by Vsevolod Vlasov.

Add "matchbrackets" add-on to CodeMirror text editor add override
default styles for matched and unmatched braces.

No new tests.

* WebCore.gypi:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* inspector/front-end/CodeMirrorTextEditor.js:
(WebInspector.CodeMirrorTextEditor):
* inspector/front-end/WebKit.qrc:
* inspector/front-end/cm/cmdevtools.css:
(.CodeMirror-matchingbracket):
(.CodeMirror-nonmatchingbracket):
* inspector/front-end/cm/matchbrackets.js: Added.
(.):

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

7 years ago[Qt][WK2] Layer QtDownloadManager on the C API
jocelyn.turcotte@digia.com [Tue, 12 Mar 2013 11:18:29 +0000 (11:18 +0000)]
[Qt][WK2] Layer QtDownloadManager on the C API
https://bugs.webkit.org/show_bug.cgi?id=109562

Reviewed by Simon Hausmann.
Signed off for WebKit2 by Benjamin Poulain.

* UIProcess/API/cpp/qt/WKURLQt.cpp:
(WebKit::adoptToQString):
(WebKit):
(WebKit::adoptToQUrl):
* UIProcess/API/cpp/qt/WKURLQt.h:
(WebKit):
* UIProcess/API/qt/qquickwebview.cpp:
(QQuickWebViewPrivate::handleDownloadRequest):
* UIProcess/qt/QtDownloadManager.cpp:
(WebKit::toQtDownloadManager):
(WebKit):
(WebKit::QtDownloadManager::QtDownloadManager):
(WebKit::QtDownloadManager::addDownload):
(WebKit::QtDownloadManager::didReceiveResponse):
(WebKit::QtDownloadManager::didCreateDestination):
(WebKit::QtDownloadManager::didFinishDownload):
(WebKit::QtDownloadManager::didFailDownload):
(WebKit::QtDownloadManager::didReceiveDataForDownload):
* UIProcess/qt/QtDownloadManager.h:
(WebKit):
(QtDownloadManager):
* UIProcess/qt/QtWebContext.cpp:
(WebKit::QtWebContext::QtWebContext):
* UIProcess/qt/QtWebError.cpp:
(WebKit::QtWebError::url):
(WebKit::QtWebError::description):

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

7 years ago[Qt][WK2] Layer QtWebIconDatabaseClient on the C API
jocelyn.turcotte@digia.com [Tue, 12 Mar 2013 11:17:19 +0000 (11:17 +0000)]
[Qt][WK2] Layer QtWebIconDatabaseClient on the C API
https://bugs.webkit.org/show_bug.cgi?id=109564

Reviewed by Simon Hausmann.
Signed off for WebKit2 by Benjamin Poulain.

* Target.pri:
* UIProcess/API/C/qt/WKIconDatabaseQt.cpp: Added.
(WKIconDatabaseTryGetQImageForURL):
  - New API added to get a QImage from the IconDatabase.
    Based on WKIconDatabaseCG.h/cpp
* UIProcess/API/C/qt/WKIconDatabaseQt.h: Added.
* UIProcess/API/cpp/qt/WKURLQt.cpp:
(WKURLCreateWithQString):
(WKURLCopyQString):
(WKURLCreateWithQUrl):
(WKURLCopyQUrl):
  - The WKUrlRef behind the scene is a WTF::String and encoding it back and forth to
    a QUrl can slightly change its string representation. Allow converting a WKUrlRef
    to and from a QString to ensure this.
* UIProcess/API/cpp/qt/WKURLQt.h:
* UIProcess/API/qt/qwebiconimageprovider.cpp:
(QWebIconImageProvider::iconURLForPageURLInContext):
  - The icon URL isn't accessible form the C API and shouldn't need to be.
    Use an ID incremented on each update to trigger an update of the QML Image component.
(QWebIconImageProvider::requestImage):
  - The IconDatabase was previously assumed to resize the image to the requested size,
    but this parameter is ignored, as stated in a comment in WebIconDatabase::imageForPageURL.
    Explicitely do the resize after fetching the original icon to also be able to report
    the original size properly to QtQuick.
* UIProcess/API/qt/qwebiconimageprovider_p.h:
* UIProcess/API/qt/tests/qmltests/WebView/tst_favIconLoad.qml:
  - Set the image to load asynchronously to further test the possibility of threading issues
    in QtWebIconDatabaseClient::iconImageForPageURL
  - Add a few barriers to fix some issues where the load succeeded signal would be wrongly
    catched by init() before the next test.
* UIProcess/qt/QtWebContext.cpp:
(WebKit::QtWebContext::QtWebContext):
* UIProcess/qt/QtWebIconDatabaseClient.cpp:
(WebKit):
(WebKit::QtWebIconDatabaseClient::QtWebIconDatabaseClient):
(WebKit::QtWebIconDatabaseClient::~QtWebIconDatabaseClient):
(WebKit::QtWebIconDatabaseClient::updateID):
(WebKit::QtWebIconDatabaseClient::didChangeIconForPageURL):
(WebKit::QtWebIconDatabaseClient::iconImageForPageURL):
  - Remove the Mutex. This mutex was useless given that it would only
    be locked from a single thread. Since the IconDatabase runs in its own thread,
    it already is thread-safe to access.
(WebKit::QtWebIconDatabaseClient::retainIconForPageURL):
(WebKit::QtWebIconDatabaseClient::releaseIconForPageURL):
* UIProcess/qt/QtWebIconDatabaseClient.h:
(QtWebIconDatabaseClient):
* WebKit2.pri:

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

7 years ago[Qt][WK2] Specify storage paths through the C API
jocelyn.turcotte@digia.com [Tue, 12 Mar 2013 11:16:01 +0000 (11:16 +0000)]
[Qt][WK2] Specify storage paths through the C API
https://bugs.webkit.org/show_bug.cgi?id=111435

Reviewed by Simon Hausmann.
Signed off for WebKit2 by Benjamin Poulain.

The WKIconDatabase should be opened through a call to
WKContextSetIconDatabasePath. To avoid having some paths
returned through WebContext::platformDefault* and some others
through the C API, make sure that all those paths are set
through the C API.

* Shared/qt/QtDefaultDataLocation.cpp: Removed.
* Shared/qt/QtDefaultDataLocation.h: Removed.
* Target.pri:
* UIProcess/Plugins/qt/PluginProcessProxyQt.cpp:
(WebKit::cacheFile):
  - This part is left alone behind the C API.
    Since PluginProcessProxy have no knowledge of the WebContext
    it is rather difficult to fetch a configured directory that
    could be used for this purpose (like the disk cache storage).
    Hard-code a compatible logic to keep the current behavior.
(WebKit::removeCacheFile):
(WebKit):
(WebKit::readMetaDataFromCacheFile):
(WebKit::writeToCacheFile):
(WebKit::tryReadPluginMetaDataFromCacheFile):
  - Update the code to better handle an empty cache file path.
* UIProcess/qt/QtWebContext.cpp:
(WebKit::QtWebContext::defaultContext):
(WebKit::defaultLocation):
(WebKit):
(WebKit::QtWebContext::preparedStoragePath):
* UIProcess/qt/QtWebContext.h:
* UIProcess/qt/QtWebIconDatabaseClient.cpp:
(WebKit::QtWebIconDatabaseClient::QtWebIconDatabaseClient):
* UIProcess/qt/WebContextQt.cpp:
(WebKit::WebContext::applicationCacheDirectory):
(WebKit::WebContext::platformDefaultDatabaseDirectory):
(WebKit::WebContext::platformDefaultIconDatabasePath):
(WebKit::WebContext::platformDefaultLocalStorageDirectory):
(WebKit::WebContext::platformDefaultDiskCacheDirectory):
(WebKit::WebContext::platformDefaultCookieStorageDirectory):

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

7 years ago[Qt] Properly layer QtWebContext on top of the C API
jocelyn.turcotte@digia.com [Tue, 12 Mar 2013 11:14:42 +0000 (11:14 +0000)]
[Qt] Properly layer QtWebContext on top of the C API
https://bugs.webkit.org/show_bug.cgi?id=108475

Reviewed by Simon Hausmann.
Signed off for WebKit2 by Benjamin Poulain.

* UIProcess/API/qt/qquickwebview.cpp:
(QQuickWebViewPrivate::initialize):
* UIProcess/qt/QtWebContext.cpp:
(WebKit::initializeContextInjectedBundleClient):
(WebKit::QtWebContext::QtWebContext):
(WebKit::QtWebContext::create):
(WebKit::QtWebContext::defaultContext):
* UIProcess/qt/QtWebContext.h:
(WebKit):
(QtWebContext):
(WebKit::QtWebContext::context):

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

7 years ago[Qt][WK2] Allow QtWebContext to call directly to QQuickWebView with a WKPageRef
jocelyn.turcotte@digia.com [Tue, 12 Mar 2013 11:13:31 +0000 (11:13 +0000)]
[Qt][WK2] Allow QtWebContext to call directly to QQuickWebView with a WKPageRef
https://bugs.webkit.org/show_bug.cgi?id=109829

Reviewed by Allan Sandfeld Jensen.
Signed off for WebKit2 by Benjamin Poulain.

Instead of going through WebPageProxy and PageClient to forward
injected bundle messages received by the context, maintain a static map
of WKPageRef to QQuickWebViewPrivate.

* UIProcess/API/qt/qquickwebview.cpp:
(QQuickWebViewPrivate::get):
(QQuickWebViewPrivate::~QQuickWebViewPrivate):
(QQuickWebViewPrivate::initialize):
(QQuickWebViewPrivate::didReceiveMessageFromNavigatorQtObject):
* UIProcess/API/qt/qquickwebview_p_p.h:
(QQuickWebViewPrivate):
* UIProcess/API/qt/raw/qrawwebview.cpp:
* UIProcess/API/qt/raw/qrawwebview_p_p.h:
* UIProcess/PageClient.h:
(PageClient):
* UIProcess/WebPageProxy.h:
(WebPageProxy):
* UIProcess/qt/QtPageClient.cpp:
* UIProcess/qt/QtPageClient.h:
(QtPageClient):
* UIProcess/qt/QtWebContext.cpp:
(WebKit::didReceiveMessageFromInjectedBundle):
* UIProcess/qt/WebPageProxyQt.cpp:

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

7 years agoRefactoring: Pull Node::disabled() and Node::isInert() down to Element.
falken@chromium.org [Tue, 12 Mar 2013 11:13:02 +0000 (11:13 +0000)]
Refactoring: Pull Node::disabled() and Node::isInert() down to Element.
https://bugs.webkit.org/show_bug.cgi?id=112085

Reviewed by Hajime Morrita.

Node is too low a level for these methods.

No new tests, just refactoring.

* dom/Element.cpp:
(WebCore::Element::disabled):
(WebCore):
(WebCore::Element::isInert):
* dom/Element.h:
(Element):
* dom/EventDispatcher.cpp:
(WebCore::EventDispatcher::dispatchSimulatedClick):
* dom/GestureEvent.cpp:
(WebCore::GestureEventDispatchMediator::dispatchEvent):
* dom/MouseEvent.cpp:
(WebCore::MouseEventDispatchMediator::dispatchEvent):
* dom/Node.cpp:
(WebCore::Node::handleLocalEvents):
(WebCore::Node::willRespondToMouseMoveEvents):
(WebCore::Node::willRespondToMouseClickEvents):
(WebCore::Node::willRespondToTouchEvents):
* dom/Node.h:
(Node):

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

7 years ago[Qt][WK2] Keep the WebContext alive during the whole application's lifetime
jocelyn.turcotte@digia.com [Tue, 12 Mar 2013 11:12:28 +0000 (11:12 +0000)]
[Qt][WK2] Keep the WebContext alive during the whole application's lifetime
https://bugs.webkit.org/show_bug.cgi?id=109827

Reviewed by Simon Hausmann.
Signed off for WebKit2 by Benjamin Poulain.

The lifetime of the WebContext is difficult to manage because of a circular
reference kept with the WebProcessProxy until it shuts itself down, 60
seconds after the last page is closed. There was some notification
in place to handle this in the upper layer, but having to go through the
C API (done in a following patch) makes this quite awkward.

Keeping the WebContext alive also includes the icon database which is
quite heavy, in the future we should only enable it once the
QQuickWebView::icon property is read.

* UIProcess/API/qt/qquickwebview.cpp:
(QQuickWebViewPrivate::QQuickWebViewPrivate):
(QQuickWebViewPrivate::handleDownloadRequest):
(QQuickWebViewPrivate::updateIcon):
* UIProcess/API/qt/qquickwebview_p_p.h:
(QQuickWebViewPrivate):
* UIProcess/API/qt/qwebiconimageprovider.cpp:
(QWebIconImageProvider::requestImage):
* UIProcess/qt/QtWebContext.cpp:
(WebKit):
(WebKit::QtWebContext::QtWebContext):
(WebKit::QtWebContext::~QtWebContext):
(WebKit::QtWebContext::create):
(WebKit::QtWebContext::defaultContext):
* UIProcess/qt/QtWebContext.h:
(QtWebContext):
(WebKit::QtWebContext::downloadManager):
(WebKit::QtWebContext::iconDatabase):
* UIProcess/qt/WebContextQt.cpp:
(WebKit::WebContext::platformInvalidateContext):

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

7 years ago[Qt][WK2] Favor QUrl and QString over WTF::String in the Qt API layer
jocelyn.turcotte@digia.com [Tue, 12 Mar 2013 11:11:14 +0000 (11:11 +0000)]
[Qt][WK2] Favor QUrl and QString over WTF::String in the Qt API layer
https://bugs.webkit.org/show_bug.cgi?id=109468

Reviewed by Allan Sandfeld Jensen.
Signed off for WebKit2 by Benjamin Poulain.

In preparation for patches using the C API types in some areas, remove the
usage of WTF::String on the affected line.

Use a QUrl for icon URL to avoid unnecessary conversion.
Use a QString for the page URL to keep it compatible with WebPageProxy and
WebIconDatabase and avoid QUrl parsing.

* UIProcess/API/qt/qquickwebview.cpp:
(QQuickWebViewPrivate::_q_onIconChangedForPageURL):
(QQuickWebViewPrivate::updateIcon):
(QQuickWebView::emitUrlChangeIfNeeded):
(QQuickWebView::icon):
* UIProcess/API/qt/qquickwebview_p_p.h:
(QQuickWebViewPrivate):
* UIProcess/API/qt/qwebiconimageprovider.cpp:
(QWebIconImageProvider::iconURLForPageURLInContext):
* UIProcess/API/qt/qwebiconimageprovider_p.h:
* UIProcess/qt/QtWebIconDatabaseClient.cpp:
(WebKit::QtWebIconDatabaseClient::iconForPageURL):
(WebKit::QtWebIconDatabaseClient::iconImageForPageURL):
(WebKit::QtWebIconDatabaseClient::retainIconForPageURL):
(WebKit::QtWebIconDatabaseClient::releaseIconForPageURL):
* UIProcess/qt/QtWebIconDatabaseClient.h:
(QtWebIconDatabaseClient):

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

7 years ago[V8] Get rid of function-level static FunctionTemplates in generated bindings code
commit-queue@webkit.org [Tue, 12 Mar 2013 10:47:11 +0000 (10:47 +0000)]
[V8] Get rid of function-level static FunctionTemplates in generated bindings code
https://bugs.webkit.org/show_bug.cgi?id=111971

Patch by Marja Hölttä <marja@chromium.org> on 2013-03-12
Reviewed by Jochen Eisinger.

In the future we'll create and store function templates for main world
and non-main worlds separately (see bug 111724), having function
templates as static variables inside functions will break the
functionality.

No new tests (updated the bindings test expectations).

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateDomainSafeFunctionGetter):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetter):
* bindings/v8/V8PerIsolateData.cpp:
(WebCore::V8PerIsolateData::V8PerIsolateData):
(WebCore::V8PerIsolateData::privateTemplate):
(WebCore):
* bindings/v8/V8PerIsolateData.h:
(V8PerIsolateData):
* bindings/v8/custom/V8LocationCustom.cpp:
(WebCore::V8Location::reloadAttrGetterCustom):
(WebCore::V8Location::replaceAttrGetterCustom):
(WebCore::V8Location::assignAttrGetterCustom):

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

7 years ago[Refactoring] Implement RuleCollector
tasak@google.com [Tue, 12 Mar 2013 10:14:53 +0000 (10:14 +0000)]
[Refactoring] Implement RuleCollector
https://bugs.webkit.org/show_bug.cgi?id=109916

Reviewed by Antti Koivisto.

Implemented rule collector for an element and collector for a page.
Not all members in class State are required entire while resolving
a style.

No new tests, because just refactoring.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.gypi:
* WebCore.xcodeproj/project.pbxproj:
* css/CSSAllInOne.cpp:
Added ElementRuleCollector and PageRuleCollector.
* css/DocumentRuleSets.cpp:
(WebCore::ShadowDistributedRules::collectMatchRequests):
Since behaviorAtBoundary is a state owned by ElementRuleCollector,
removed from here.
* css/DocumentRuleSets.h:
(WebCore::ShadowDistributedRules::isEmpty):
Added to quickly check whether there exist any ShadowDistributedRules
or not.
* css/ElementRuleCollector.cpp: Copied from Source/WebCore/css/StyleResolver.cpp.
(WebCore):
(WebCore::ElementRuleCollector::matchedResult):
(WebCore::ElementRuleCollector::matchedRuleList):
(WebCore::ElementRuleCollector::addMatchedRule):
(WebCore::ElementRuleCollector::clearMatchedRules):
(WebCore::ElementRuleCollector::ensureRuleList):
(WebCore::ElementRuleCollector::addElementStyleProperties):
(WebCore::ElementRuleCollector::collectMatchingRules):
(WebCore::ElementRuleCollector::collectMatchingRulesForRegion):
(WebCore::ElementRuleCollector::sortAndTransferMatchedRules):
(WebCore::ElementRuleCollector::matchScopedAuthorRules):
(WebCore::ElementRuleCollector::matchHostRules):
(WebCore::ElementRuleCollector::matchShadowDistributedRules):
(WebCore::ElementRuleCollector::matchAuthorRules):
(WebCore::ElementRuleCollector::matchUserRules):
(WebCore::ElementRuleCollector::matchUARules):
(WebCore::ElementRuleCollector::ruleMatches):
(WebCore::ElementRuleCollector::collectMatchingRulesForList):
(WebCore::ElementRuleCollector::sortMatchedRules):
(WebCore::ElementRuleCollector::matchAllRules):
Moved these methods from StyleResolver to this class.
(WebCore::ElementRuleCollector::hasAnyMatchingRules):
This method is used for checking whether a given element can share
a cache.
* css/ElementRuleCollector.h: Copied from Source/WebCore/css/StyleResolver.h.
(WebCore):
(WebCore::ElementRuleCollector::ElementRuleCollector):
Use styleResolver instance to initialize its member variables, i.e.
SelectorFilter, RuleSets, InspectorCSSOMWrappers, and
StyleScopedResolver.
(ElementRuleCollector):
(WebCore::ElementRuleCollector::setMode):
(WebCore::ElementRuleCollector::setPseudoStyleRequest):
(WebCore::ElementRuleCollector::setSameOriginOnly):
(WebCore::ElementRuleCollector::setRegionForStyling):
Mode, SameOriginOnly, RegionForStyling are only used while collecting
matched rules.
(WebCore::ElementRuleCollector::setMedium):
Need to know which default stylesheet should be looked up.
(WebCore::ElementRuleCollector::document):
* css/PageRuleCollector.cpp: Copied from Source/WebCore/css/StyleResolver.cpp.
(WebCore::comparePageRules):
(WebCore::PageRuleCollector::isLeftPage):
(WebCore::PageRuleCollector::isFirstPage):
(WebCore::PageRuleCollector::pageName):
(WebCore::PageRuleCollector::matchAllPageRules):
(WebCore::PageRuleCollector::matchPageRules):
(WebCore::checkPageSelectorComponents):
(WebCore::PageRuleCollector::matchPageRulesForList):
Moved from StyleResolver.
* css/PageRuleCollector.h: Copied from Source/WebCore/css/StyleResolver.h.
(WebCore):
(WebCore::PageRuleCollector::PageRuleCollector):
(PageRuleCollector):
(WebCore::PageRuleCollector::matchedResult):
* css/StyleResolver.cpp:
(WebCore):
(WebCore::StyleResolver::State::clear):
(WebCore::StyleResolver::MatchResult::addMatchedProperties):
(WebCore::StyleResolver::State::initForStyleResolve):
(WebCore::StyleResolver::styleSharingCandidateMatchesRuleSet):
(WebCore::StyleResolver::styleForElement):
(WebCore::StyleResolver::styleForKeyframe):
(WebCore::StyleResolver::pseudoStyleForElement):
(WebCore::StyleResolver::styleForPage):
(WebCore::StyleResolver::pseudoStyleRulesForElement):
(WebCore::StyleResolver::applyMatchedProperties):
* css/StyleResolver.h:
(WebCore::MatchRequest::MatchRequest):
Removed behaviorAtBoundary. Instead, ElementRuleCollector have the
state.
(MatchRequest):
(WebCore::StyleResolver::selectorFilter):
Added to obtain SelectorFilter in ElementRuleCollector's constructor.
(StyleResolver):
(MatchResult):
(WebCore::StyleResolver::State::State):
To pass ASSERT in StyleResolver::applyProperties, need to keep
m_regionForStyling.
(State):
(WebCore::StyleResolver::State::regionForStyling):
(WebCore::StyleResolver::State::useSVGZoomRules):
(WebCore::StyleResolver::hasSelectorForId):
(WebCore):
(WebCore::checkRegionSelector):
* inspector/InspectorCSSAgent.cpp:
(WebCore::InspectorCSSAgent::willMatchRule):
Removed StyleResolver from its parameter list. Instead, added
InspectorCSSOMWrappers and DocumentStyleSheetCollection.
* inspector/InspectorCSSAgent.h:
(WebCore):
(InspectorCSSAgent):
* inspector/InspectorInstrumentation.cpp:
(WebCore):
(WebCore::InspectorInstrumentation::willMatchRuleImpl):
* inspector/InspectorInstrumentation.h:
(WebCore):
(InspectorInstrumentation):
(WebCore::InspectorInstrumentation::willMatchRule):

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

7 years ago[GTK][WK2] REGRESSION(r145081): Unit tests not working if locale is not English
commit-queue@webkit.org [Tue, 12 Mar 2013 10:07:32 +0000 (10:07 +0000)]
[GTK][WK2] REGRESSION(r145081): Unit tests not working if locale is not English
https://bugs.webkit.org/show_bug.cgi?id=111973

Patch by Manuel Rego Casasnovas <rego@igalia.com> on 2013-03-12
Reviewed by Carlos Garcia Campos.

The problem is that the UIProcess locale is reseted to C in
gtk_test_init, however the WebProcess does not inherit the locale set in
the UIProcess and it uses the system one (that could be different to
English). So, there were problems in some tests that are comparing
strings from both processes like WebKit2APITests/TestPrinting and
WebKit2APITests/TestWebKitWebContext. The solution is to set the locale
environment variable LC_ALL to C in order to reset WebProcess locale
too.

* UIProcess/API/gtk/tests/TestMain.cpp:
(main): Set environment variable LC_ALL to C.

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

7 years agoNot reviewed: chromium gardening.
pfeldman@chromium.org [Tue, 12 Mar 2013 09:52:03 +0000 (09:52 +0000)]
Not reviewed: chromium gardening.

* platform/chromium/TestExpectations:

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

7 years ago[Qt] WebKit fails to compile if EGL headers are not in default INCLUDEPATH
commit-queue@webkit.org [Tue, 12 Mar 2013 09:41:46 +0000 (09:41 +0000)]
[Qt] WebKit fails to compile if EGL headers are not in default INCLUDEPATH
https://bugs.webkit.org/show_bug.cgi?id=111859

Patch by Floris Bos <bos@je-eigen-domein.nl> on 2013-03-12
Reviewed by Jocelyn Turcotte.

The 3D graphics code wants to include EGL header files.
But on some platforms such as the Raspberry Pi those are not in /usr/include
but in another folder.
Fix adds "egl" to CONFIG when OpenGL ES2 is used, so the right include
paths are added.

* WebCore.pri:

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

7 years agoMaking more sophisticated cache flush on ARM Linux platform
rgabor@webkit.org [Tue, 12 Mar 2013 09:41:37 +0000 (09:41 +0000)]
Making more sophisticated cache flush on ARM Linux platform
https://bugs.webkit.org/show_bug.cgi?id=111854

Reviewed by Zoltan Herczeg.

The cache flush on ARM Linux invalidates whole pages
instead of just the required area.

* assembler/ARMAssembler.h:
(ARMAssembler):
(JSC::ARMAssembler::linuxPageFlush):
(JSC::ARMAssembler::cacheFlush):
* assembler/ARMv7Assembler.h:
(ARMv7Assembler):
(JSC::ARMv7Assembler::linuxPageFlush):
(JSC::ARMv7Assembler::cacheFlush):

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

7 years agoRenaming the armv7.rb LLINT backend to arm.rb
rgabor@webkit.org [Tue, 12 Mar 2013 09:30:33 +0000 (09:30 +0000)]
Renaming the armv7.rb LLINT backend to arm.rb
https://bugs.webkit.org/show_bug.cgi?id=110565

Reviewed by Zoltan Herczeg.

This is the first step of a unified ARM backend for
all ARM 32 bit architectures in LLInt.

* CMakeLists.txt:
* GNUmakefile.list.am:
* JavaScriptCore.gypi:
* LLIntOffsetsExtractor.pro:
* offlineasm/arm.rb: Copied from Source/JavaScriptCore/offlineasm/armv7.rb.
* offlineasm/armv7.rb: Removed.
* offlineasm/backends.rb:
* offlineasm/risc.rb:

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

7 years agoXSSAuditor should send only one console error when blocking a page.
mkwst@chromium.org [Tue, 12 Mar 2013 09:28:12 +0000 (09:28 +0000)]
XSSAuditor should send only one console error when blocking a page.
https://bugs.webkit.org/show_bug.cgi?id=110733

Reviewed by Daniel Bates.

Source/WebCore:

Currently, we send two console errors when XSSAuditor blocks a page:
"Refused to execute a JavaScript script. Source code of script found
within request.\n", and "Entire page will be blocked.".

We should only send one message, tuning it properly for the context, and
including the URL of the page effected by the XSSAuditor's work.

Covered by rebaselines of all the XSSAuditor and 'reflected-xss' tests.

* html/parser/XSSAuditor.cpp:
* html/parser/XSSAuditor.h:
(WebCore::XSSAuditor::XSSAuditor):
    Add two booleans to track the headers used to set the XSSAuditor state.
(WebCore::XSSAuditor::init):
(WebCore::XSSAuditor::filterToken):
    Add detail about the header status to the constructed XSSInfo object.
* html/parser/XSSAuditorDelegate.cpp:
(WebCore::buildConsoleError):
    Move message construction out into a separate inlined function, as
    it's becoming complex.
(WebCore::XSSAuditorDelegate::didBlockScript):
    Fold the "Entire page will be blocked" message into the main console
    error.
* html/parser/XSSAuditorDelegate.h:
(WebCore::XSSInfo::create):
(WebCore::XSSInfo::XSSInfo):
    Add detail about header status to XSSInfo in order to correctly
    construct the console error.

LayoutTests:

* fast/frames/xss-auditor-handles-file-urls-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-allow-block-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-allow-filter-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-allow-invalid-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-block-allow-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-block-block-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-block-filter-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-block-invalid-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-block-unset-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-filter-allow-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-filter-block-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-filter-filter-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-filter-invalid-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-filter-unset-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-invalid-allow-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-invalid-block-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-invalid-filter-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-invalid-invalid-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-invalid-unset-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-unset-block-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-unset-filter-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-unset-invalid-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-unset-unset-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-block-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-empty-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-filter-expected.txt:
* http/tests/security/contentSecurityPolicy/1.1/reflected-xss-invalid-expected.txt:
* http/tests/security/xssAuditor/anchor-url-dom-write-location-expected.txt:
* http/tests/security/xssAuditor/anchor-url-dom-write-location-inline-event-expected.txt:
* http/tests/security/xssAuditor/anchor-url-dom-write-location-inline-event-null-char-expected.txt:
* http/tests/security/xssAuditor/anchor-url-dom-write-location-javascript-URL-expected.txt:
* http/tests/security/xssAuditor/anchor-url-dom-write-location2-expected.txt:
* http/tests/security/xssAuditor/base-href-control-char-expected.txt:
* http/tests/security/xssAuditor/base-href-expected.txt:
* http/tests/security/xssAuditor/base-href-null-char-expected.txt:
* http/tests/security/xssAuditor/base-href-scheme-relative-expected.txt:
* http/tests/security/xssAuditor/block-does-not-leak-location-expected.txt:
* http/tests/security/xssAuditor/block-does-not-leak-referrer-expected.txt:
* http/tests/security/xssAuditor/cached-frame-expected.txt:
* http/tests/security/xssAuditor/cookie-injection-expected.txt:
* http/tests/security/xssAuditor/dom-write-URL-expected.txt:
* http/tests/security/xssAuditor/dom-write-location-expected.txt:
* http/tests/security/xssAuditor/dom-write-location-inline-event-expected.txt:
* http/tests/security/xssAuditor/dom-write-location-javascript-URL-expected.txt:
* http/tests/security/xssAuditor/embed-tag-code-attribute-2-expected.txt:
* http/tests/security/xssAuditor/embed-tag-code-attribute-expected.txt:
* http/tests/security/xssAuditor/embed-tag-control-char-expected.txt:
* http/tests/security/xssAuditor/embed-tag-expected.txt:
* http/tests/security/xssAuditor/embed-tag-javascript-url-expected.txt:
* http/tests/security/xssAuditor/embed-tag-null-char-expected.txt:
* http/tests/security/xssAuditor/formaction-on-button-expected.txt:
* http/tests/security/xssAuditor/formaction-on-input-expected.txt:
* http/tests/security/xssAuditor/form-action-expected.txt:
* http/tests/security/xssAuditor/full-block-base-href-expected.txt:
* http/tests/security/xssAuditor/full-block-get-from-iframe-expected.txt:
* http/tests/security/xssAuditor/full-block-iframe-javascript-url-expected.txt:
* http/tests/security/xssAuditor/full-block-iframe-no-inherit-expected.txt:
* http/tests/security/xssAuditor/full-block-javascript-link-expected.txt:
* http/tests/security/xssAuditor/full-block-link-onclick-expected.txt:
* http/tests/security/xssAuditor/full-block-object-tag-expected.txt:
* http/tests/security/xssAuditor/full-block-post-from-iframe-expected.txt:
* http/tests/security/xssAuditor/full-block-script-tag-cross-domain-expected.txt:
* http/tests/security/xssAuditor/full-block-script-tag-expected.txt:
* http/tests/security/xssAuditor/full-block-script-tag-with-source-expected.txt:
* http/tests/security/xssAuditor/get-from-iframe-expected.txt:
* http/tests/security/xssAuditor/iframe-injection-expected.txt:
* http/tests/security/xssAuditor/iframe-javascript-url-expected.txt:
* http/tests/security/xssAuditor/iframe-javascript-url-more-encoding-expected.txt:
* http/tests/security/xssAuditor/iframe-javascript-url-twice-url-encode-expected.txt:
* http/tests/security/xssAuditor/iframe-javascript-url-twice-url-encode2-expected.txt:
* http/tests/security/xssAuditor/iframe-javascript-url-twice-url-encode3-expected.txt:
* http/tests/security/xssAuditor/iframe-javascript-url-url-encoded-expected.txt:
* http/tests/security/xssAuditor/iframe-onload-GBK-char-expected.txt:
* http/tests/security/xssAuditor/iframe-onload-in-svg-tag-expected.txt:
* http/tests/security/xssAuditor/iframe-srcdoc-expected.txt:
* http/tests/security/xssAuditor/img-onerror-GBK-char-expected.txt:
* http/tests/security/xssAuditor/img-onerror-accented-char-expected.txt:
* http/tests/security/xssAuditor/img-onerror-non-ASCII-char-default-encoding-expected.txt:
* http/tests/security/xssAuditor/img-onerror-non-ASCII-char-expected.txt:
* http/tests/security/xssAuditor/img-onerror-non-ASCII-char2-default-encoding-expected.txt:
* http/tests/security/xssAuditor/img-onerror-non-ASCII-char2-expected.txt:
* http/tests/security/xssAuditor/inline-event-HTML-entities-expected.txt:
* http/tests/security/xssAuditor/javascript-link-HTML-entities-control-char-expected.txt:
* http/tests/security/xssAuditor/javascript-link-HTML-entities-expected.txt:
* http/tests/security/xssAuditor/javascript-link-HTML-entities-named-expected.txt:
* http/tests/security/xssAuditor/javascript-link-HTML-entities-null-char-expected.txt:
* http/tests/security/xssAuditor/javascript-link-ampersand-expected.txt:
* http/tests/security/xssAuditor/javascript-link-control-char-expected.txt:
* http/tests/security/xssAuditor/javascript-link-expected.txt:
* http/tests/security/xssAuditor/javascript-link-null-char-expected.txt:
* http/tests/security/xssAuditor/javascript-link-one-plus-one-expected.txt:
* http/tests/security/xssAuditor/javascript-link-url-encoded-expected.txt:
* http/tests/security/xssAuditor/link-onclick-ampersand-expected.txt:
* http/tests/security/xssAuditor/link-onclick-control-char-expected.txt:
* http/tests/security/xssAuditor/link-onclick-entities-expected.txt:
* http/tests/security/xssAuditor/link-onclick-expected.txt:
* http/tests/security/xssAuditor/link-onclick-null-char-expected.txt:
* http/tests/security/xssAuditor/link-opens-new-window-expected.txt:
* http/tests/security/xssAuditor/malformed-HTML-expected.txt:
* http/tests/security/xssAuditor/malformed-xss-protection-header-1-expected.txt:
* http/tests/security/xssAuditor/malformed-xss-protection-header-2-expected.txt:
* http/tests/security/xssAuditor/malformed-xss-protection-header-3-expected.txt:
* http/tests/security/xssAuditor/malformed-xss-protection-header-4-expected.txt:
* http/tests/security/xssAuditor/malformed-xss-protection-header-5-expected.txt:
* http/tests/security/xssAuditor/malformed-xss-protection-header-6-expected.txt:
* http/tests/security/xssAuditor/malformed-xss-protection-header-7-expected.txt:
* http/tests/security/xssAuditor/malformed-xss-protection-header-8-expected.txt:
* http/tests/security/xssAuditor/malformed-xss-protection-header-9-expected.txt:
* http/tests/security/xssAuditor/meta-tag-http-refresh-javascript-url-expected.txt:
* http/tests/security/xssAuditor/object-embed-tag-control-char-expected.txt:
* http/tests/security/xssAuditor/object-embed-tag-expected.txt:
* http/tests/security/xssAuditor/object-embed-tag-null-char-expected.txt:
* http/tests/security/xssAuditor/object-tag-expected.txt:
* http/tests/security/xssAuditor/object-tag-javascript-url-expected.txt:
* http/tests/security/xssAuditor/open-attribute-body-expected.txt:
* http/tests/security/xssAuditor/open-event-handler-iframe-expected.txt:
* http/tests/security/xssAuditor/open-iframe-src-01-expected.txt:
* http/tests/security/xssAuditor/open-iframe-src-02-expected.txt:
* http/tests/security/xssAuditor/open-script-src-01-expected.txt:
* http/tests/security/xssAuditor/open-script-src-02-expected.txt:
* http/tests/security/xssAuditor/open-script-src-03-expected.txt:
* http/tests/security/xssAuditor/open-script-src-04-expected.txt:
* http/tests/security/xssAuditor/post-from-iframe-expected.txt:
* http/tests/security/xssAuditor/property-escape-comment-01-expected.txt:
* http/tests/security/xssAuditor/property-escape-comment-02-expected.txt:
* http/tests/security/xssAuditor/property-escape-comment-03-expected.txt:
* http/tests/security/xssAuditor/property-escape-entity-01-expected.txt:
* http/tests/security/xssAuditor/property-escape-entity-02-expected.txt:
* http/tests/security/xssAuditor/property-escape-entity-03-expected.txt:
* http/tests/security/xssAuditor/property-escape-expected.txt:
* http/tests/security/xssAuditor/property-escape-long-expected.txt:
* http/tests/security/xssAuditor/property-escape-quote-01-expected.txt:
* http/tests/security/xssAuditor/property-escape-quote-02-expected.txt:
* http/tests/security/xssAuditor/property-escape-quote-03-expected.txt:
* http/tests/security/xssAuditor/report-script-tag-expected.txt:
* http/tests/security/xssAuditor/report-script-tag-full-block-expected.txt:
* http/tests/security/xssAuditor/script-tag-Big5-char-expected.txt:
* http/tests/security/xssAuditor/script-tag-Big5-char-twice-url-encode-16bit-unicode-expected.txt:
* http/tests/security/xssAuditor/script-tag-Big5-char-twice-url-encode-expected.txt:
* http/tests/security/xssAuditor/script-tag-Big5-char2-expected.txt:
* http/tests/security/xssAuditor/script-tag-addslashes-backslash-expected.txt:
* http/tests/security/xssAuditor/script-tag-addslashes-double-quote-expected.txt:
* http/tests/security/xssAuditor/script-tag-addslashes-null-char-expected.txt:
* http/tests/security/xssAuditor/script-tag-addslashes-single-quote-expected.txt:
* http/tests/security/xssAuditor/script-tag-control-char-expected.txt:
* http/tests/security/xssAuditor/script-tag-convoluted-expected.txt:
* http/tests/security/xssAuditor/script-tag-entities-expected.txt:
* http/tests/security/xssAuditor/script-tag-expected.txt:
* http/tests/security/xssAuditor/script-tag-inside-svg-tag-expected.txt:
* http/tests/security/xssAuditor/script-tag-inside-svg-tag2-expected.txt:
* http/tests/security/xssAuditor/script-tag-inside-svg-tag3-expected.txt:
* http/tests/security/xssAuditor/script-tag-null-char-expected.txt:
* http/tests/security/xssAuditor/script-tag-open-redirect-expected.txt:
* http/tests/security/xssAuditor/script-tag-post-control-char-expected.txt:
* http/tests/security/xssAuditor/script-tag-post-expected.txt:
* http/tests/security/xssAuditor/script-tag-post-null-char-expected.txt:
* http/tests/security/xssAuditor/script-tag-redirect-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-16bit-unicode-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-16bit-unicode-surrogate-pair-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-16bit-unicode2-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-16bit-unicode3-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-16bit-unicode4-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-16bit-unicode5-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-actual-comma-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-callbacks-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-comma-01-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-comma-02-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-fancy-unicode-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-invalid-closing-tag-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-invalid-url-encoding-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-control-char-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-data-url-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-data-url2-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-data-url3-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-double-quote-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-entities-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-no-quote-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-null-char-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-relative-scheme-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-same-host-with-query-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-unterminated-01-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-unterminated-02-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-source-unterminated-03-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-three-times-url-encoded-16bit-unicode-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-trailing-comment-U2028-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-trailing-comment-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-trailing-comment2-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-trailing-comment3-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-trailing-comment4-expected.txt:
* http/tests/security/xssAuditor/script-tag-with-trailing-comment5-expected.txt:
* http/tests/security/xssAuditor/svg-script-tag-expected.txt:
* http/tests/security/xssAuditor/xss-filter-bypass-big5-expected.txt:
* http/tests/security/xssAuditor/xss-filter-bypass-long-string-expected.txt:
* http/tests/security/xssAuditor/xss-filter-bypass-sjis-expected.txt:
* http/tests/security/xssAuditor/xss-protection-parsing-01-expected.txt:
* http/tests/security/xssAuditor/xss-protection-parsing-02-expected.txt:
* http/tests/security/xssAuditor/xss-protection-parsing-03-expected.txt:
* http/tests/security/xssAuditor/xss-protection-parsing-04-expected.txt:
* platform/chromium/http/tests/security/xssAuditor/javascript-link-control-char2-expected.txt:

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

7 years agoUnreviewed, rolling out r145494.
commit-queue@webkit.org [Tue, 12 Mar 2013 09:11:24 +0000 (09:11 +0000)]
Unreviewed, rolling out r145494.
http://trac.webkit.org/changeset/145494
https://bugs.webkit.org/show_bug.cgi?id=112117

Breaks Chromium Mac (Requested by pfeldman on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2013-03-12

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateDomainSafeFunctionGetter):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetter):
* bindings/v8/V8PerIsolateData.cpp:
(WebCore::V8PerIsolateData::V8PerIsolateData):
* bindings/v8/V8PerIsolateData.h:
(V8PerIsolateData):
* bindings/v8/custom/V8LocationCustom.cpp:
(WebCore::V8Location::reloadAttrGetterCustom):
(WebCore::V8Location::replaceAttrGetterCustom):
(WebCore::V8Location::assignAttrGetterCustom):

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

7 years agoWeb Inspector: add memory instrumentation for ImageLoader
yurys@chromium.org [Tue, 12 Mar 2013 09:00:25 +0000 (09:00 +0000)]
Web Inspector: add memory instrumentation for ImageLoader
https://bugs.webkit.org/show_bug.cgi?id=112115

Reviewed by Alexander Pavlov.

Added memory instrumentation to ImageLoader. CachedImage referenced
by the loader is reported as having retaining reference. This allows
to see in the native memory graph CachedImages that are not reachable
from MemoryCache but referenced by HTMLImageElement.

* loader/ImageLoader.cpp:
(WebCore::ImageLoader::reportMemoryUsage):
(WebCore):
* loader/ImageLoader.h:
(ImageLoader):

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

7 years agoREGRESSION(r145482): It broke 33 jsc tests and zillion layout tests on all platform
ossy@webkit.org [Tue, 12 Mar 2013 08:53:41 +0000 (08:53 +0000)]
REGRESSION(r145482): It broke 33 jsc tests and zillion layout tests on all platform
https://bugs.webkit.org/show_bug.cgi?id=112112

Reviewed by Oliver Hunt.

Rolling out https://trac.webkit.org/changeset/145482 to unbreak the bots.

* runtime/JSStringJoiner.cpp:
(JSC::JSStringJoiner::build):
* runtime/JSStringJoiner.h:
(JSStringJoiner):
(JSC::JSStringJoiner::JSStringJoiner):
(JSC::JSStringJoiner::append):

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

7 years agoWeb Inspector: Broken shortcuts in Snippets SourceFrame
vsevik@chromium.org [Tue, 12 Mar 2013 08:43:05 +0000 (08:43 +0000)]
Web Inspector: Broken shortcuts in Snippets SourceFrame
https://bugs.webkit.org/show_bug.cgi?id=112038

Reviewed by Pavel Feldman.

* inspector/front-end/SnippetJavaScriptSourceFrame.js:
(WebInspector.SnippetJavaScriptSourceFrame):
(WebInspector.SnippetJavaScriptSourceFrame.prototype._onKeyDown):

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

7 years agoWeb Inspector: Several inspector tests are flaky beacuse of beforeonload event handler.
vsevik@chromium.org [Tue, 12 Mar 2013 08:25:21 +0000 (08:25 +0000)]
Web Inspector: Several inspector tests are flaky beacuse of beforeonload event handler.
https://bugs.webkit.org/show_bug.cgi?id=112111

Reviewed by Alexander Pavlov.

Added removeEventListener call.
Beforeunload message was updated so that it is possible to find it's source from it.

* inspector-protocol/page/javascriptDialogEvents-expected.txt:
* inspector-protocol/page/javascriptDialogEvents.html:

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

7 years agoUnreviewed GTK gardening.
zandobersek@gmail.com [Tue, 12 Mar 2013 08:07:32 +0000 (08:07 +0000)]
Unreviewed GTK gardening.

* platform/gtk/TestExpectations: Adding failure expectations for tests introduced in r145397 and r145474.
* platform/gtk/fast/js/global-constructors-expected.txt: Rebaselining after r145400.

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

7 years agoWeb Inspector: [Timeline] File selector control becomes visible on "tab" navigation.
eustas@chromium.org [Tue, 12 Mar 2013 07:59:18 +0000 (07:59 +0000)]
Web Inspector: [Timeline] File selector control becomes visible on "tab" navigation.
https://bugs.webkit.org/show_bug.cgi?id=111710

Reviewed by Pavel Feldman.

Solution: Exclude file selector control from tab-navigation flow.

* inspector/front-end/FileUtils.js: Set tab-index to control.
* inspector/front-end/TimelinePanel.js: Remove duplicating code.
* inspector/front-end/inspector.css:
(.status-bar-item): Make scroll height equal to offset height.

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

7 years ago[V8] Get rid of function-level static FunctionTemplates in generated bindings code
commit-queue@webkit.org [Tue, 12 Mar 2013 07:52:32 +0000 (07:52 +0000)]
[V8] Get rid of function-level static FunctionTemplates in generated bindings code
https://bugs.webkit.org/show_bug.cgi?id=111971

Patch by Marja Hölttä <marja@chromium.org> on 2013-03-12
Reviewed by Kentaro Hara.

In the future we'll create and store function templates for main world
and non-main worlds separately (see bug 111724), having function
templates as static variables inside functions will break the
functionality.

No new tests (updated the bindings test expectations).

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateDomainSafeFunctionGetter):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetter):
* bindings/v8/V8PerIsolateData.cpp:
(WebCore::V8PerIsolateData::V8PerIsolateData):
(WebCore::V8PerIsolateData::privateTemplate):
(WebCore):
* bindings/v8/V8PerIsolateData.h:
(V8PerIsolateData):
* bindings/v8/custom/V8LocationCustom.cpp:
(WebCore::V8Location::reloadAttrGetterCustom):
(WebCore::V8Location::replaceAttrGetterCustom):
(WebCore::V8Location::assignAttrGetterCustom):

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

7 years agoNeed to notify ScrollingCoordinator when frame scrollbars are destroyed
commit-queue@webkit.org [Tue, 12 Mar 2013 07:46:42 +0000 (07:46 +0000)]
Need to notify ScrollingCoordinator when frame scrollbars are destroyed
https://bugs.webkit.org/show_bug.cgi?id=112104

Patch by Tien-Ren Chen <trchen@chromium.org> on 2013-03-12
Reviewed by James Robinson.

Need to notify ScrollingCoordinatorChromium whenever m_layerForHorizontalScrollbar /
m_layerForVerticalScrollbar changes, for correct lifetime management.

No new tests. Difficult to test lifetime management internal to ScrollingCoordinatorChromium.

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

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

7 years agoUnreviewed test flakiness fix.
vsevik@chromium.org [Tue, 12 Mar 2013 07:34:29 +0000 (07:34 +0000)]
Unreviewed test flakiness fix.

* inspector/debugger/event-listener-breakpoints.html:

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

7 years agoDFG prediction propagation phase should not rerun forward propagation if double votin...
fpizlo@apple.com [Tue, 12 Mar 2013 07:02:51 +0000 (07:02 +0000)]
DFG prediction propagation phase should not rerun forward propagation if double voting has already converged
https://bugs.webkit.org/show_bug.cgi?id=111920

Reviewed by Oliver Hunt.

I don't know why we weren't exiting early after double voting if !m_changed.

This change also removes backwards propagation from the voting fixpoint, since at that
point short-circuiting loops is probably not particularly profitable. Profiling shows
that this reduces the time spent in prediction propagation even further.

This change appears to be a 1% SunSpider speed-up.

* dfg/DFGPredictionPropagationPhase.cpp:
(JSC::DFG::PredictionPropagationPhase::run):

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

7 years agoUnreviewed test flakiness fix.
vsevik@chromium.org [Tue, 12 Mar 2013 06:52:47 +0000 (06:52 +0000)]
Unreviewed test flakiness fix.

* inspector/debugger/xhr-breakpoints.html:
* platform/chromium/TestExpectations:

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

7 years agoDFG overflow check elimination is too smart for its own good
fpizlo@apple.com [Tue, 12 Mar 2013 06:43:54 +0000 (06:43 +0000)]
DFG overflow check elimination is too smart for its own good
https://bugs.webkit.org/show_bug.cgi?id=111832

Source/JavaScriptCore:

Reviewed by Oliver Hunt and Gavin Barraclough.

Rolling this back in after fixing accidental misuse of JSValue. The code was doing value < someInt
rather than value.asInt32() < someInt. This "worked" when isWithinPowerOfTwo wasn't templatized.
It worked by always being false and always disabling the relvant optimization.

This improves overflow check elimination in three ways:

1) It reduces the amount of time the compiler will spend doing it.

2) It fixes bugs where overflow check elimination was overzealous. Precisely, for a binary operation
   over @a and @b where both @a and @b will type check that their inputs (@a->children, @b->children)
   are int32's and then perform a possibly-overflowing operation, we must be careful not to assume
   that @a's non-int32 parts don't matter if at the point that @a runs we have as yet not proved that
   @b->children are int32's and that hence @b might produce a large enough result that doubles would
   start chopping low bits. The specific implication of this is that for a binary operation to not
   propagate that it cares about non-int32 parts (NodeUsedAsNumber), we must prove that at least one
   of the inputs is guaranteed to produce a result within 2^32 and that there won't be a tower of such
   operations large enough to ultimately produce a double greater than 2^52 (roughly). We achieve the
   latter by disabling this optimization for very large basic blocks. It's noteworthy that blocks that
   large won't even make it into the DFG currently.

3) It makes the overflow check elimination more precise for cases where the inputs to an Add or Sub
   are the outputs of a bit-op. For example in (@a + (@b | 0)) | 0, we don't need to propagate
   NodeUsedAsNumber to either @a or @b.

This is neutral on V8v7 and a slight speed-up on compile time benchmarks.

* CMakeLists.txt:
* GNUmakefile.list.am:
* JavaScriptCore.xcodeproj/project.pbxproj:
* Target.pri:
* dfg/DFGArrayMode.cpp:
(JSC::DFG::ArrayMode::refine):
* dfg/DFGBackwardsPropagationPhase.cpp: Added.
(DFG):
(BackwardsPropagationPhase):
(JSC::DFG::BackwardsPropagationPhase::BackwardsPropagationPhase):
(JSC::DFG::BackwardsPropagationPhase::run):
(JSC::DFG::BackwardsPropagationPhase::isNotNegZero):
(JSC::DFG::BackwardsPropagationPhase::isNotZero):
(JSC::DFG::BackwardsPropagationPhase::isWithinPowerOfTwoForConstant):
(JSC::DFG::BackwardsPropagationPhase::isWithinPowerOfTwoNonRecursive):
(JSC::DFG::BackwardsPropagationPhase::isWithinPowerOfTwo):
(JSC::DFG::BackwardsPropagationPhase::mergeDefaultFlags):
(JSC::DFG::BackwardsPropagationPhase::propagate):
(JSC::DFG::performBackwardsPropagation):
* dfg/DFGBackwardsPropagationPhase.h: Added.
(DFG):
* dfg/DFGCPSRethreadingPhase.cpp:
(JSC::DFG::CPSRethreadingPhase::run):
(JSC::DFG::CPSRethreadingPhase::clearIsLoadedFrom):
(CPSRethreadingPhase):
(JSC::DFG::CPSRethreadingPhase::canonicalizeGetLocalFor):
(JSC::DFG::CPSRethreadingPhase::canonicalizeFlushOrPhantomLocalFor):
* dfg/DFGDriver.cpp:
(JSC::DFG::compile):
* dfg/DFGGraph.cpp:
(JSC::DFG::Graph::dump):
* dfg/DFGNodeFlags.cpp:
(JSC::DFG::dumpNodeFlags):
(DFG):
* dfg/DFGNodeFlags.h:
(DFG):
* dfg/DFGPredictionPropagationPhase.cpp:
(PredictionPropagationPhase):
(JSC::DFG::PredictionPropagationPhase::propagate):
* dfg/DFGUnificationPhase.cpp:
(JSC::DFG::UnificationPhase::run):
* dfg/DFGVariableAccessData.h:
(JSC::DFG::VariableAccessData::VariableAccessData):
(JSC::DFG::VariableAccessData::mergeIsLoadedFrom):
(VariableAccessData):
(JSC::DFG::VariableAccessData::setIsLoadedFrom):
(JSC::DFG::VariableAccessData::isLoadedFrom):

LayoutTests:

Reviewed by Oliver Hunt and Gavin Barraclough.

* fast/js/dfg-arith-add-overflow-check-elimination-predicted-but-not-proven-int-expected.txt: Added.
* fast/js/dfg-arith-add-overflow-check-elimination-predicted-but-not-proven-int.html: Added.
* fast/js/dfg-arith-add-overflow-check-elimination-tower-of-large-numbers-expected.txt: Added.
* fast/js/dfg-arith-add-overflow-check-elimination-tower-of-large-numbers.html: Added.
* fast/js/jsc-test-list:
* fast/js/script-tests/dfg-arith-add-overflow-check-elimination-predicted-but-not-proven-int.js: Added.
(foo):
(bar):
* fast/js/script-tests/dfg-arith-add-overflow-check-elimination-tower-of-large-numbers.js: Added.
(foo):
(bar):

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

7 years agoNot reviewed: Chromium expectations updated.
pfeldman@chromium.org [Tue, 12 Mar 2013 06:26:22 +0000 (06:26 +0000)]
Not reviewed: Chromium expectations updated.

* platform/chromium-linux/media/track/track-cue-rendering-horizontal-expected.txt: Removed.
* platform/chromium-linux/media/track/track-cue-rendering-vertical-expected.txt: Removed.
* platform/chromium-win/media/track/track-cue-rendering-horizontal-expected.txt:
* platform/chromium-win/media/track/track-cue-rendering-vertical-expected.txt:

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

7 years agoNot reviewed: Chromium expectations updated.
pfeldman@chromium.org [Tue, 12 Mar 2013 06:20:46 +0000 (06:20 +0000)]
Not reviewed: Chromium expectations updated.

* platform/chromium-mac/fast/borders/border-radius-with-box-shadow-expected.png:
* platform/chromium-win/fast/borders/border-radius-with-box-shadow-expected.png:

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

7 years agoWe'll get there eventually.
simon.fraser@apple.com [Tue, 12 Mar 2013 06:20:19 +0000 (06:20 +0000)]
We'll get there eventually.

* platform/graphics/ca/win/PlatformCAFiltersWin.cpp:

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

7 years agoLoads are never canceled in the NetworkProcess
beidson@apple.com [Tue, 12 Mar 2013 06:12:25 +0000 (06:12 +0000)]
Loads are never canceled in the NetworkProcess
<rdar://problem/12890500> and https://bugs.webkit.org/show_bug.cgi?id=112103

Reviewed by Alexey Proskuryakov.

If a connection to a WebProcess is closed (gracefully or by crashing) then:
- All scheduled loads for that connection should be forgotten.
- All in-progress loads for that connection should be aborted asap.

* NetworkProcess/NetworkResourceLoader.cpp:
(WebKit::requestsToCleanupMutex): The "request to stop" mechanism is now called "request to cleanup"
(WebKit::requestsToCleanup):
(WebKit::NetworkResourceLoader::scheduleCleanupOnMainThread):
(WebKit::NetworkResourceLoader::performCleanups):
(WebKit::NetworkResourceLoader::cleanup):
(WebKit::NetworkResourceLoader::didFinishLoading):
(WebKit::NetworkResourceLoader::didFail):

(WebKit::NetworkResourceLoader::connectionToWebProcessDidClose): If there is a resource handle, let
  the loading thread notice the connection is invalid. Otherwise request to cleanup the loader.
(WebKit::NetworkResourceLoader::sendAbortingOnFailure):
(WebKit::NetworkResourceLoader::sendSyncAbortingOnFailure):
(WebKit::NetworkResourceLoader::abortInProgressLoad): Cancel the resource handle and schedule main thread cleanup.
(WebKit::NetworkResourceLoader::didReceiveResponse): Use sendAbortingOnFailure instead of send.
(WebKit::NetworkResourceLoader::didReceiveData): Ditto.

(WebKit::NetworkResourceLoader::willSendRequest): Call abortInProgressLoad if the sync message failed.
(WebKit::NetworkResourceLoader::canAuthenticateAgainstProtectionSpace): Ditto.
* NetworkProcess/NetworkResourceLoader.h:

Make connectionToWebProcessDidClose() pure virtual, moving its implementation to the subclasses:
* NetworkProcess/SchedulableLoader.cpp:
* NetworkProcess/SchedulableLoader.h:

* NetworkProcess/SyncNetworkResourceLoader.cpp:
(WebKit::SyncNetworkResourceLoader::start): Call cleanup().
(WebKit::SyncNetworkResourceLoader::connectionToWebProcessDidClose): Call cleanup().
(WebKit::SyncNetworkResourceLoader::cleanup): Factor out the sync loader cleanup code.
* NetworkProcess/SyncNetworkResourceLoader.h:

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

7 years agoFumbled adding new files to the vcproj. Fixing.
simon.fraser@apple.com [Tue, 12 Mar 2013 06:10:21 +0000 (06:10 +0000)]
Fumbled adding new files to the vcproj. Fixing.

* WebCore.vcproj/WebCore.vcproj:

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

7 years agoFix the Windows build by providing implementations of PlatformCAFilters::setFiltersOn...
simon.fraser@apple.com [Tue, 12 Mar 2013 05:51:46 +0000 (05:51 +0000)]
Fix the Windows build by providing implementations of PlatformCAFilters::setFiltersOnLayer(),
PlatformCAFilters::numAnimatedFilterProperties() and PlatformCAFilters::animatedFilterPropertyName(),
adding PlatformCAFiltersWin.cpp to the vcproj.

* WebCore.vcproj/WebCore.vcproj:
* platform/graphics/ca/PlatformCAFilters.h:
(PlatformCAFilters):
* platform/graphics/ca/win/PlatformCAFiltersWin.cpp: Copied from Source/WebCore/platform/graphics/ca/PlatformCAFilters.h.
(PlatformCAFilters::setFiltersOnLayer):
(PlatformCAFilters::numAnimatedFilterProperties):
(PlatformCAFilters::animatedFilterPropertyName):

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

7 years agoHarden JSStringJoiner
oliver@apple.com [Tue, 12 Mar 2013 05:51:05 +0000 (05:51 +0000)]
Harden JSStringJoiner
https://bugs.webkit.org/show_bug.cgi?id=112093

Reviewed by Filip Pizlo.

Harden JSStringJoiner, make it use our CheckedArithmetic
class to simplify everything.

* runtime/JSStringJoiner.cpp:
(JSC::JSStringJoiner::build):
* runtime/JSStringJoiner.h:
(JSStringJoiner):
(JSC::JSStringJoiner::JSStringJoiner):
(JSC::JSStringJoiner::append):

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

7 years agoDon't create multiple user gesture indicators when forwarding events to sub frames
jochen@chromium.org [Tue, 12 Mar 2013 05:45:19 +0000 (05:45 +0000)]
Don't create multiple user gesture indicators when forwarding events to sub frames
https://bugs.webkit.org/show_bug.cgi?id=111923

Reviewed by Adam Barth.

Ports that implement consumable user gestures depend on a single user
gesture indicator being created in response to a single user gesture.

Source/WebCore:

Test: platform/chromium/fast/events/popup-allowed-from-gesture-only-once-iframes.html

* dom/UserGestureIndicator.cpp:
(WebCore::isDefinite):
(WebCore::UserGestureIndicator::UserGestureIndicator):
(WebCore::UserGestureIndicator::processingUserGesture):
* dom/UserGestureIndicator.h:
* page/EventHandler.cpp:
(WebCore::EventHandler::handleMousePressEvent):
(WebCore::EventHandler::handleMouseDoubleClickEvent):
(WebCore::EventHandler::handleMouseReleaseEvent):
(WebCore::EventHandler::keyEvent):
(WebCore::EventHandler::handleTouchEvent):

LayoutTests:

* platform/chromium/fast/events/popup-allowed-from-gesture-only-once-iframes-expected.txt: Added.
* platform/chromium/fast/events/popup-allowed-from-gesture-only-once-iframes.html: Added.

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

7 years agoFix Windows build.
simon.fraser@apple.com [Tue, 12 Mar 2013 05:37:50 +0000 (05:37 +0000)]
Fix Windows build.

* platform/graphics/ca/win/PlatformCAAnimationWin.cpp:

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

7 years agoNot reviewed: Chromium expectations updated.
pfeldman@chromium.org [Tue, 12 Mar 2013 05:23:08 +0000 (05:23 +0000)]
Not reviewed: Chromium expectations updated.

* platform/chromium/TestExpectations:

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

7 years agoNot reviewed: Chromium rebaselines.
pfeldman@chromium.org [Tue, 12 Mar 2013 05:10:33 +0000 (05:10 +0000)]
Not reviewed: Chromium rebaselines.

* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-scaled-expected.txt: Removed.
* platform/chromium-linux/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-scaled-scroll-expected.txt: Removed.
* platform/chromium-mac-lion/compositing/layer-creation/fixed-position-out-of-view-scaled-expected.txt: Removed.
* platform/chromium-mac-lion/compositing/layer-creation/fixed-position-out-of-view-scaled-scroll-expected.txt: Removed.
* platform/chromium-mac-snowleopard/compositing/layer-creation/fixed-position-out-of-view-scaled-expected.txt: Removed.
* platform/chromium-mac-snowleopard/compositing/layer-creation/fixed-position-out-of-view-scaled-scroll-expected.txt: Removed.
* platform/chromium-mac/compositing/layer-creation/fixed-position-out-of-view-scaled-expected.txt: Removed.
* platform/chromium-mac/compositing/layer-creation/fixed-position-out-of-view-scaled-scroll-expected.txt: Removed.
* platform/chromium-win/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-scaled-expected.txt: Removed.
* platform/chromium-win/platform/chromium/virtual/softwarecompositing/layer-creation/fixed-position-out-of-view-scaled-scroll-expected.txt: Removed.
* platform/chromium/compositing/layer-creation/fixed-position-out-of-view-scaled-expected.txt: Renamed from LayoutTests/platform/chromium-linux/compositing/layer-creation/fixed-position-out-of-view-scaled-expected.txt.
* platform/chromium/compositing/layer-creation/fixed-position-out-of-view-scaled-scroll-expected.txt: Renamed from LayoutTests/platform/chromium-linux/compositing/layer-creation/fixed-position-out-of-view-scaled-scroll-expected.txt.

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

7 years agoPDFPlugin: Return PDFKit's data instead of the original resource data for save/etc.
timothy_horton@apple.com [Tue, 12 Mar 2013 05:10:03 +0000 (05:10 +0000)]
PDFPlugin: Return PDFKit's data instead of the original resource data for save/etc.
https://bugs.webkit.org/show_bug.cgi?id=111956
<rdar://problem/13352282>

Reviewed by Alexey Proskuryakov.

If we return the original resource data, we lose changes made to annotations.

* WebProcess/Plugins/PDF/PDFPlugin.mm:
(WebKit::PDFPlugin::pdfDocumentDidLoad): Adopt the renamed rawData().
(WebKit::PDFPlugin::saveToPDF): Use liveData so that "Save to PDF" persists changes to annotations.
(WebKit::PDFPlugin::openWithNativeApplication): Use liveData so that "Open With [native application]" persists changes to annotations.

* WebProcess/Plugins/PDF/PDFPluginAnnotation.h:
* WebProcess/Plugins/PDF/PDFPluginAnnotation.mm:
(WebKit::PDFPluginAnnotation::commit): Added, inform PDFPlugin that we're mutating the document.
* WebProcess/Plugins/PDF/PDFPluginChoiceAnnotation.mm:
(WebKit::PDFPluginChoiceAnnotation::commit): Let PDFPluginAnnotation do what it needs to inform PDFPlugin that we're going to mutate the document.
* WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm:
(WebKit::PDFPluginTextAnnotation::commit): Let PDFPluginAnnotation do what it needs to inform PDFPlugin that we're going to mutate the document.

* WebProcess/Plugins/PDF/SimplePDFPlugin.h:
(WebKit::SimplePDFPlugin::didMutatePDFDocument): Added.
(WebKit::SimplePDFPlugin::liveData): Added.
(WebKit::SimplePDFPlugin::rawData): Renamed from data(). Return NSData for consistency.
(WebKit::SimplePDFPlugin::pdfDocumentWasMutated): Added.
* WebProcess/Plugins/PDF/SimplePDFPlugin.mm:
(WebKit::SimplePDFPlugin::liveData): Return PDFKit's data if the user has mutated the
document, otherwise the raw data. This way, PDFs that PDFKit can't process will still
be downloadable as long as the user doesn't interact with annotations.
(WebKit::SimplePDFPlugin::liveResourceData): Return a SharedData wrapping the PDFDocument's data.

* WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
* WebProcess/Plugins/Netscape/NetscapePlugin.h:
* WebProcess/Plugins/PDF/SimplePDFPlugin.h:
* WebProcess/Plugins/Plugin.h:
* WebProcess/Plugins/PluginProxy.h:
* WebProcess/Plugins/PluginView.cpp:
* WebProcess/Plugins/PluginView.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::getMainResourceDataOfFrame):
Use a SharedData instead of raw data for getResourceData, and rename it liveResourceData().

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

7 years agoNot reviewed: Chromium rebaselines.
pfeldman@chromium.org [Tue, 12 Mar 2013 05:00:00 +0000 (05:00 +0000)]
Not reviewed: Chromium rebaselines.

* platform/chromium/compositing/overflow/composited-scrolling-paint-phases-expected.txt:
* platform/chromium/platform/chromium/virtual/gpu/compositedscrolling/overflow/composited-scrolling-paint-phases-expected.txt:
* platform/chromium/platform/chromium/virtual/softwarecompositing/overflow/composited-scrolling-paint-phases-expected.txt:

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

7 years agoUnreviewed build fix after http://trac.webkit.org/changeset/145472.
timothy_horton@apple.com [Tue, 12 Mar 2013 04:58:55 +0000 (04:58 +0000)]
Unreviewed build fix after trac.webkit.org/changeset/145472.

* platform/graphics/ca/mac/PlatformCAFiltersMac.mm:
(PlatformCAFilters::colorMatrixValueForFilter):

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

7 years ago[CSS] shadow from radius has wrong render in webkit
tasak@google.com [Tue, 12 Mar 2013 04:55:16 +0000 (04:55 +0000)]
[CSS] shadow from radius has wrong render in webkit
https://bugs.webkit.org/show_bug.cgi?id=99928

Reviewed by Simon Fraser.

Source/WebCore:

No rounded cornder should be expanded in the mixed case, i.e. some
corners are rounded, but others are not rounded.
Need to look at each corner independently,
i.e. top-left, top-right, bottom-left and bottom-right, and
to expand corners whose width and height are larger than 0.

Test: fast/box-shadow/box-shadow-with-zero-radius.html

* platform/graphics/RoundedRect.cpp:
(WebCore::RoundedRect::Radii::expand):

LayoutTests:

* fast/box-shadow/box-shadow-with-zero-radius-expected.html: Added.
* fast/box-shadow/box-shadow-with-zero-radius.html: Added.
* platform/chromium-linux/fast/borders/border-radius-with-box-shadow-expected.png:
Rebaselined. Comparing the old one with the new one, both ones look almost
the same.

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