WebKit-https.git
6 years agoRemove platform/graphic's Generator
benjamin@webkit.org [Tue, 14 May 2013 04:04:36 +0000 (04:04 +0000)]
Remove platform/graphic's Generator
https://bugs.webkit.org/show_bug.cgi?id=116084

Patch by Benjamin Poulain <bpoulain@apple.com> on 2013-05-13
Reviewed by Darin Adler.

The Generator no longer abstract anything useful, its only
implementation is Gradient.

* GNUmakefile.list.am:
* WebCore.exp.in:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
* platform/graphics/GeneratedImage.h:
* platform/graphics/Generator.h: Removed.
* platform/graphics/GeneratorGeneratedImage.cpp:
(WebCore::GeneratorGeneratedImage::draw):
(WebCore::GeneratorGeneratedImage::drawPattern):
* platform/graphics/GeneratorGeneratedImage.h:
(WebCore::GeneratorGeneratedImage::create):
(WebCore::GeneratorGeneratedImage::GeneratorGeneratedImage):
(GeneratorGeneratedImage):
* platform/graphics/Gradient.h:
(WebCore):
(Gradient):
* platform/graphics/GraphicsContext.cpp:
(WebCore::GraphicsContext::fillRect):
* platform/graphics/GraphicsContext.h:
(WebCore):
(GraphicsContext):

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

6 years agoUnreviewed EFL gardening.
ryuan.choi@samsung.com [Tue, 14 May 2013 03:36:33 +0000 (03:36 +0000)]
Unreviewed EFL gardening.

Unskip several tests which already passed and add png expected results.

* platform/efl/TestExpectations:
* platform/efl/editing/selection/doubleclick-crash-expected.png: Added.
* platform/efl/editing/selection/select-missing-image-expected.png: Added.

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

6 years agoNightly build's jsc doesn't work without DYLD_FRAMEWORK...
commit-queue@webkit.org [Tue, 14 May 2013 03:20:57 +0000 (03:20 +0000)]
Nightly build's jsc doesn't work without DYLD_FRAMEWORK...
https://bugs.webkit.org/show_bug.cgi?id=79065

Patch by Alvaro Lopez Ortega <alvaro@alobbs.com> on 2013-05-13
Reviewed by Darin Adler.

Fixes the build process so the depencencies of the jsc binary are
modified before its copied to its target directory. In this way
jsc should always use relative reference to the JavaScriptCore
libraries.

* JavaScriptCore.xcodeproj/project.pbxproj: Fixes the commands in
the "Copy Into Framework" target.

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

6 years agoObjective-C API: scanExternalObjectGraph should not create new JSVirtualMachine wrappers
mhahnenberg@apple.com [Tue, 14 May 2013 02:49:31 +0000 (02:49 +0000)]
Objective-C API: scanExternalObjectGraph should not create new JSVirtualMachine wrappers
https://bugs.webkit.org/show_bug.cgi?id=116074

If scanExternalObjectGraph creates a new JSVirtualMachine wrapper during collection, when the
scanExternalObjectGraph call finishes and the autorelease pool is drained we will dealloc the
JSVirtualMachine which will cause us to try to take the API lock for the corresponding VM.
If this happens on a GC thread other than the "main" thread, we will deadlock. The solution
is to just check the VM cache, and if there is no JSVirtualMachine wrapper, return early.

Reviewed by Darin Adler.

* API/JSVirtualMachine.mm:
(scanExternalObjectGraph):

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

6 years agoUpstream iOS Clipboard and Pasteboard changes
ddkilzer@apple.com [Tue, 14 May 2013 02:21:12 +0000 (02:21 +0000)]
Upstream iOS Clipboard and Pasteboard changes
<http://webkit.org/b/116062>

Reviewed by Darin Adler.

* WebCore.xcodeproj/project.pbxproj:
* dom/Clipboard.h:
* platform/Pasteboard.h:
* platform/ios/ClipboardIOS.h: Added.
* platform/ios/ClipboardIOS.mm: Added.
* platform/ios/PasteboardIOS.mm: Added.

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

6 years agocompositing/transitions/transform-on-large-layer.html is flaky
allan.jensen@digia.com [Tue, 14 May 2013 02:14:09 +0000 (02:14 +0000)]
compositing/transitions/transform-on-large-layer.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=110099

Reviewed by Darin Adler.

Only set the timeout for test end after the resize event has been
received. This helps slow test bots, and also makes it easier to
tell rendering failures from failures to send resize event.

* compositing/transitions/transform-on-large-layer.html:

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

6 years ago[Mac] Use pageScaleFactor * deviceScaleFactor in requiresTiledLayer() and computePixe...
commit-queue@webkit.org [Tue, 14 May 2013 02:11:16 +0000 (02:11 +0000)]
[Mac] Use pageScaleFactor * deviceScaleFactor in requiresTiledLayer() and computePixelAlignment() of GraphicsLayerCA.
https://bugs.webkit.org/show_bug.cgi?id=107359

Patch by Huang Dongsung <luxtella@company100.net> on 2013-05-13
Reviewed by Darin Adler.

Currently GraphicsLayerCA uses pageScaleFactor in requiresTiledLayer() and
computePixelAlignment(), but we must use pageScaleFactor * deviceScaleFactor in
them.
It is because:
1. requiresTiledLayer() uses the scale to compute an actual layer size in the device
pixel unit.
2. computePixelAlignment() uses the scale to compute an aligned layer position
in the device pixel unit.

No new tests. We can not test about requiresTiledLayer() because it depends on
gpu. computePixelAlignment() is correct now because fortunately Mac uses
only 2 (for retina display) as a deviceScaleFactor.

* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::GraphicsLayerCA::requiresTiledLayer):
(WebCore::GraphicsLayerCA::computePixelAlignment):

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

6 years agoAdded testRunner.setPrinting.
commit-queue@webkit.org [Tue, 14 May 2013 02:00:00 +0000 (02:00 +0000)]
Added testRunner.setPrinting.
https://bugs.webkit.org/show_bug.cgi?id=42693
rdar://problem/8213845

Patch by Alex Christensen <achristensen@apple.com> on 2013-05-13
Reviewed by Darin Adler.

Source/WebKit2:

* WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
(WKBundlePageCopyRenderTreeExternalRepresentationForPrinting): Added.
* WebProcess/InjectedBundle/API/c/WKBundlePagePrivate.h:
Added WKBundlePageCopyRenderTreeExternalRepresentationForPrinting declaration.
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::renderTreeExternalRepresentationForPrinting): Added.
* WebProcess/WebPage/WebPage.h:
Added renderTreeExternalRepresentationForPrinting declaration.

Tools:

* WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
Added setPrinting JavaScript function.
* WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
(WTR::InjectedBundlePage::dump):
Dump the external representation for printing if setPrinting has been called.
* WebKitTestRunner/InjectedBundle/TestRunner.h:
(WTR::TestRunner::isPrinting): Added.
(WTR::TestRunner::setPrinting): Added.
Added and initialized m_isPrinting member boolean.

LayoutTests:

* platform/wk2/TestExpectations:
Unskipped printing tests.

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

6 years agoRename BarInfo to BarProp and remove [NoInterfaceObject]
ch.dumez@sisa.samsung.com [Tue, 14 May 2013 00:59:48 +0000 (00:59 +0000)]
Rename BarInfo to BarProp and remove [NoInterfaceObject]
https://bugs.webkit.org/show_bug.cgi?id=116027

Reviewed by Andreas Kling.

Source/WebCore:

Rename BarInfo to BarProp and remove [NoInterfaceObject] extended attribute from
the IDL interface to match the specification:
http://www.w3.org/html/wg/drafts/html/master/browsers.html#barprop

The new behavior also matches Firefox and Blink.

No new tests, covered by LayoutTests/fast/js/global-constructors-attributes.html.

* CMakeLists.txt:
* DerivedSources.cpp:
* DerivedSources.make:
* DerivedSources.pri:
* GNUmakefile.list.am:
* Target.pri:
* WebCore.order:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
* bindings/gobject/GNUmakefile.am:
* page/BarProp.cpp: Renamed from Source/WebCore/page/BarInfo.cpp.
* page/BarProp.h: Renamed from Source/WebCore/page/BarInfo.h.
* page/BarProp.idl: Renamed from Source/WebCore/page/BarInfo.idl.
* page/DOMWindow.cpp:
* page/DOMWindow.h:
* page/DOMWindow.idl:

LayoutTests:

Rebaseline fast/js/global-constructors-attributes.html now that there is a new
'BarProp' global constructor.

Rebaseline a few other tests now that BarInfo was renamed to BarProp.

* fast/dom/Window/window-lookup-precedence-expected.txt:
* fast/js/global-constructors-attributes-expected.txt:
* fast/loader/window-properties-restored-from-page-cache-expected.txt:
* http/tests/security/cross-frame-access-put-expected.txt:
* platform/efl/fast/js/global-constructors-attributes-expected.txt:
* platform/gtk/fast/dom/Window/window-lookup-precedence-expected.txt:
* platform/gtk/fast/js/global-constructors-attributes-expected.txt:
* platform/mac-lion/fast/js/global-constructors-attributes-expected.txt:
* platform/mac/fast/dom/Window/window-lookup-precedence-expected.txt:
* platform/qt/fast/js/global-constructors-attributes-expected.txt:

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

6 years agoRemove ChromeClient::willPopupMenu
andersca@apple.com [Mon, 13 May 2013 23:17:59 +0000 (23:17 +0000)]
Remove ChromeClient::willPopupMenu
https://bugs.webkit.org/show_bug.cgi?id=116063

Reviewed by Andreas Kling.

Source/WebCore:

Remove ChromeClient::willPopupMenu.

* page/ChromeClient.h:

Source/WebKit/mac:

ChromeClient::willPopupMenu is only called in one place from WebKit, so just move the function to the call site.

* WebCoreSupport/PopupMenuMac.mm:
(PopupMenuMac::show):
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:

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

6 years agoHeaders and footers should be pinned to the left edge of the window when scrolling
bdakin@apple.com [Mon, 13 May 2013 23:16:01 +0000 (23:16 +0000)]
Headers and footers should be pinned to the left edge of the window when scrolling
horizontally
https://bugs.webkit.org/show_bug.cgi?id=116061
-and corresponding-
<rdar://problem/13599215>

Reviewed by Simon Fraser.

The scrolling thread will need to know about the header and footer layers in order
the implement this custom scrolling behavior.

These getters will fetch the header or footer layer from the FrameView as
appropriate.
* page/scrolling/ScrollingCoordinator.cpp:
(WebCore::ScrollingCoordinator::headerLayerForFrameView):
(WebCore::ScrollingCoordinator::footerLayerForFrameView):
* page/scrolling/ScrollingCoordinator.h:

When we’re scrolling on the main thread, adjust the position of the header and
footer layers here.
(WebCore::ScrollingCoordinator::updateMainFrameScrollPosition):

ScrollingStateScrollingNode now stores GraphicsLayers and PlatformLayers for the
header and footer, just like it already does for the counterScrollingLayer.
* page/scrolling/ScrollingStateScrollingNode.cpp:
(WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
* page/scrolling/ScrollingStateScrollingNode.h:
(ScrollingStateScrollingNode):
(WebCore::ScrollingStateScrollingNode::headerLayer):
(WebCore::ScrollingStateScrollingNode::footerLayer):

Setters for the new layers.
* page/scrolling/mac/ScrollingCoordinatorMac.h:
(ScrollingCoordinatorMac):
* page/scrolling/mac/ScrollingCoordinatorMac.mm:
(WebCore::ScrollingCoordinatorMac::frameViewRootLayerDidChange):
(WebCore::ScrollingCoordinatorMac::setHeaderLayerForNode):
(WebCore::ScrollingCoordinatorMac::setFooterLayerForNode):

These setters and getters mirror the existing one for counterScrollingLayer.
* page/scrolling/mac/ScrollingStateScrollingNodeMac.mm:
(WebCore::ScrollingStateScrollingNode::headerPlatformLayer):
(WebCore::ScrollingStateScrollingNode::setHeaderLayer):
(WebCore::ScrollingStateScrollingNode::footerPlatformLayer):
(WebCore::ScrollingStateScrollingNode::setFooterLayer):

And the ScrollingTree will store CALayers for the header and footer.
* page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
(ScrollingTreeScrollingNodeMac):
* page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
(WebCore::ScrollingTreeScrollingNodeMac::updateBeforeChildren):

This is where the magic happens when we are scrolling on the scrolling thread.
Adjust the horizontal position the behave like a fixed object, but keep the
vertical position what it was when layer was created.
(WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):

RenderLayerCompositor must now provide getters for the header and footer.
* rendering/RenderLayerCompositor.h:
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::headerLayer):
(WebCore::RenderLayerCompositor::footerLayer):

Set the anchor point for when we adjust the position later on. Also call
frameViewRootLayerDidChange() to get the new layers picked up and sent to the
scrolling tree.
(WebCore::RenderLayerCompositor::updateLayerForHeader):
(WebCore::RenderLayerCompositor::updateLayerForFooter):

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

6 years agoImprove stringProtoFuncLastIndexOf for the prefix case
benjamin@webkit.org [Mon, 13 May 2013 23:11:08 +0000 (23:11 +0000)]
Improve stringProtoFuncLastIndexOf for the prefix case
https://bugs.webkit.org/show_bug.cgi?id=115952

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

* runtime/StringPrototype.cpp:
(JSC::stringProtoFuncLastIndexOf):
Use the optimized string search when possible.

On Joseph Pecoraro's tests, this gives a ~30% speed improvement.

Source/WTF:

Add an optimized version of StringImpl::startsWith() for JavaScriptCore.

* wtf/text/StringImpl.cpp:
(WTF::StringImpl::startsWith):
* wtf/text/StringImpl.h:
(StringImpl):
(WTF::StringImpl::startsWith):
* wtf/text/WTFString.h:
(WTF::String::startsWith):

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

6 years agoAdd support for updating the Web Inspector toolbar height.
timothy@apple.com [Mon, 13 May 2013 21:53:43 +0000 (21:53 +0000)]
Add support for updating the Web Inspector toolbar height.

https://bugs.webkit.org/show_bug.cgi?id=115996

Reviewed by Joseph Pecoraro and Benjamin Poulain.

Source/WebCore:

* inspector/InspectorFrontendClient.h:
(InspectorFrontendClient):
* inspector/InspectorFrontendHost.cpp:
(WebCore::InspectorFrontendHost::setToolbarHeight):
* inspector/InspectorFrontendHost.h:
(InspectorFrontendHost):
* inspector/InspectorFrontendHost.idl:
* testing/Internals.cpp:

Source/WebKit/efl:

* WebCoreSupport/InspectorClientEfl.cpp:
(WebCore::InspectorFrontendClientEfl::setToolbarHeight):
* WebCoreSupport/InspectorClientEfl.h:

Source/WebKit/gtk:

* WebCoreSupport/InspectorClientGtk.cpp:
(WebKit::InspectorFrontendClient::setToolbarHeight):
* WebCoreSupport/InspectorClientGtk.h:

Source/WebKit/mac:

* WebCoreSupport/WebInspectorClient.h:
* WebCoreSupport/WebInspectorClient.mm:
(WebInspectorFrontendClient::setToolbarHeight):

Source/WebKit/qt:

* WebCoreSupport/InspectorClientQt.cpp:
(WebCore::InspectorFrontendClientQt::setToolbarHeight):
* WebCoreSupport/InspectorClientQt.h:

Source/WebKit/win:

* WebCoreSupport/WebInspectorClient.cpp:
(WebInspectorFrontendClient::setToolbarHeight):
* WebCoreSupport/WebInspectorClient.h:

Source/WebKit2:

* UIProcess/WebInspectorProxy.h:
(WebKit::WebInspectorProxy::setToolbarHeight):
(WebInspectorProxy):
* UIProcess/WebInspectorProxy.messages.in:
* UIProcess/efl/WebInspectorProxyEfl.cpp:
(WebKit::WebInspectorProxy::platformSetToolbarHeight):
* UIProcess/gtk/WebInspectorProxyGtk.cpp:
(WebKit::WebInspectorProxy::platformSetToolbarHeight):
(WebKit):
* UIProcess/mac/WebInspectorProxyMac.mm:
(WebKit::WebInspectorProxy::platformSetToolbarHeight):
* UIProcess/qt/WebInspectorProxyQt.cpp:
(WebKit::WebInspectorProxy::platformSetToolbarHeight):
* WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp:
(WebKit::WebInspectorFrontendClient::setToolbarHeight):
* WebProcess/WebCoreSupport/WebInspectorFrontendClient.h:
(WebInspectorFrontendClient):
* WebProcess/WebPage/WebInspector.cpp:
(WebKit::WebInspector::setToolbarHeight):
* WebProcess/WebPage/WebInspector.h:

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

6 years agotoDataURL can return an empty image in some cases
dino@apple.com [Mon, 13 May 2013 21:29:59 +0000 (21:29 +0000)]
toDataURL can return an empty image in some cases
https://bugs.webkit.org/show_bug.cgi?id=115981
<rdar://problem/13760256>

Reviewed by Darin Adler.

Source/WebCore:

In some accelerated rendering cases, calling toDataURL on
an off-screen canvas produced an empty image. The solution
was to force a CGContextFlush before extracting the data
for image generation.

While here, I collected the flushing code from other methods
into a single place. Also we were getting into a situation where
we called flush two times in a row.

Test: fast/canvas/toDataURL-not-empty.html

* platform/graphics/ImageBuffer.h:
(ImageBuffer): Define two new methods flushContext and flushContextIfNecessary.
* platform/graphics/cg/ImageBufferCG.cpp:
(WebCore::ImageBuffer::context): Call flushContextIfNecessary.
(WebCore::ImageBuffer::flushContextIfNecessary): Moved the 10.7 code in here.
(WebCore::ImageBuffer::flushContext): Calls CGContextFlush.
(WebCore::ImageBuffer::getUnmultipliedImageData): Call new helper.
(WebCore::ImageBuffer::getPremultipliedImageData): Call new helper.
(WebCore::ImageBuffer::toDataURL): Flush the CG context.

LayoutTests:

Make sure that a canvas with content is not the same as one
without content.

* fast/canvas/toDataURL-not-empty-expected.txt: Added.
* fast/canvas/toDataURL-not-empty.html: Added.

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

6 years agoUnreviewed EFL gardening.
ch.dumez@sisa.samsung.com [Mon, 13 May 2013 21:27:56 +0000 (21:27 +0000)]
Unreviewed EFL gardening.

Mark fast/table/crash-split-table-section-no-cell-recalc.html as crashing
on EFL port.

* platform/efl/TestExpectations:

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

6 years agoRegressions in flexbox layout caused by the flexing optimizations.
hyatt@apple.com [Mon, 13 May 2013 21:02:39 +0000 (21:02 +0000)]
Regressions in flexbox layout caused by the flexing optimizations.
https://bugs.webkit.org/show_bug.cgi?id=116058
<rdar://problem/13863647>

Reviewed by Beth Dakin.

Roll out the flex-related changes from r149597 so that the layout
algorithm goes back to the way it was. Leave the repainting optimizations
in place though.

* rendering/RenderDeprecatedFlexibleBox.cpp:
(WebCore::gatherFlexChildrenInfo):
(WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox):
(WebCore::RenderDeprecatedFlexibleBox::layoutVerticalBox):

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

6 years agoUnreviewed EFL gardening.
ch.dumez@sisa.samsung.com [Mon, 13 May 2013 20:43:11 +0000 (20:43 +0000)]
Unreviewed EFL gardening.

Unskip several tests that stopped crashing after r150030.

* platform/efl-wk2/TestExpectations:

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

6 years agoUnreviewed EFL gardening.
ch.dumez@sisa.samsung.com [Mon, 13 May 2013 20:39:55 +0000 (20:39 +0000)]
Unreviewed EFL gardening.

Mark fast/css/variables/var-inside-shape.html as failing on EFL after
r150025.

* platform/efl/TestExpectations:

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

6 years agoUnreviewed, rolling out r150014.
philn@webkit.org [Mon, 13 May 2013 20:29:52 +0000 (20:29 +0000)]
Unreviewed, rolling out r150014.
http://trac.webkit.org/changeset/150014
https://bugs.webkit.org/show_bug.cgi?id=86410

Broke video playback on WK2 and some webgl tests

* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::MediaPlayerPrivateGStreamerBase::MediaPlayerPrivateGStreamerBase):
(WebCore::MediaPlayerPrivateGStreamerBase::triggerRepaint):
(WebCore::MediaPlayerPrivateGStreamerBase::paint):
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
(MediaPlayerPrivateGStreamerBase):

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

6 years agoSometimes NSUndoManager can get into an inconsistent state
rniwa@webkit.org [Mon, 13 May 2013 20:07:20 +0000 (20:07 +0000)]
Sometimes NSUndoManager can get into an inconsistent state
https://bugs.webkit.org/show_bug.cgi?id=116050

Reviewed by Enrica Casucci.

Always group undo items to work around a bug in NSUndoManager that manifests
when we call removeAllActionsWithTarget.

Source/WebKit/mac:

* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::registerUndoOrRedoStep):

Source/WebKit2:

* UIProcess/API/mac/PageClientImpl.mm:
(WebKit::PageClientImpl::registerEditCommand):

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

6 years agoUnreviewed EFL gardening.
ch.dumez@sisa.samsung.com [Mon, 13 May 2013 20:06:15 +0000 (20:06 +0000)]
Unreviewed EFL gardening.

Mark fast/animation/request-animation-frame-too-rapid.html as failing on EFL WK2
due to r150015.

* platform/efl-wk2/TestExpectations:

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

6 years ago[CSS Exclusions] Simple shape-outside tests fail when subpixel layout is disabled
hmuller@adobe.com [Mon, 13 May 2013 19:37:06 +0000 (19:37 +0000)]
[CSS Exclusions] Simple shape-outside tests fail when subpixel layout is disabled
https://bugs.webkit.org/show_bug.cgi?id=115767

Reviewed by Dirk Schulze.

The overall goal of this change was to restore the (last) four excluded exclusions ref-tests
by making them work correctly when subpixel layout is disabled. All of the tests were
substantially simplified, as was the supporting javascript code. The original
shape-outside-floats-simple-rounded-rectangle test was replaced by three separate tests
because the original was bigger then then the 800x600 limit and because it unncessarily
combined three indepedent test cases.

* fast/exclusions/resources/rounded-rectangle.js:
(ellipseXIntercept): Return the 1st quadrant X intercept for an ellipse given a first quadrant Y intercept.
(scanConvertRoundedRectangleOutside): Return the line segment intervals that overlap a rounded rectangle.
(genLeftRightRoundedRectFloatShapeOutsideRefTest): Insert a stack of float divs that match the left or right edge of a rounded rectangle.
* fast/exclusions/shape-outside-floats/shape-outside-floats-non-zero-y-expected.html:
* fast/exclusions/shape-outside-floats/shape-outside-floats-non-zero-y.html:
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-circle-expected.html:
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-circle.html:
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-ellipse-expected.html:
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-ellipse.html:
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-rounded-rectangle-001-expected.html: Added.
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-rounded-rectangle-001.html: Added.
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-rounded-rectangle-002-expected.html: Added.
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-rounded-rectangle-002.html: Added.
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-rounded-rectangle-003-expected.html: Added.
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-rounded-rectangle-003.html: Added.
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-rounded-rectangle-expected.html: Removed.
* fast/exclusions/shape-outside-floats/shape-outside-floats-simple-rounded-rectangle.html: Removed.
* platform/mac/TestExpectations:

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

6 years agoUnreviewed, rolling out r150022.
ch.dumez@sisa.samsung.com [Mon, 13 May 2013 19:35:32 +0000 (19:35 +0000)]
Unreviewed, rolling out r150022.
http://trac.webkit.org/changeset/150022
https://bugs.webkit.org/show_bug.cgi?id=114044

Causes assertions in media tests

Source/WebCore:

* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
(WebCore::MediaPlayerPrivateGStreamer::playbackPosition):
(WebCore::MediaPlayerPrivateGStreamer::prepareToPlay):
(WebCore::MediaPlayerPrivateGStreamer::currentTime):
(WebCore::MediaPlayerPrivateGStreamer::seek):
(WebCore::MediaPlayerPrivateGStreamer::handleMessage):
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
(MediaPlayerPrivateGStreamer):

LayoutTests:

* media/video-seek-after-end-expected.txt: Removed.
* media/video-seek-after-end.html: Removed.

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

6 years ago[WK2] Crash in WebKit::StorageAreaMap::didSetItem()
andersca@apple.com [Mon, 13 May 2013 19:31:04 +0000 (19:31 +0000)]
[WK2] Crash in WebKit::StorageAreaMap::didSetItem()
https://bugs.webkit.org/show_bug.cgi?id=116026

Reviewed by Andreas Kling.

Make sure that we ignore any leftover messages from the UI process after we've reset
the storage map. Achieve this by keeping a seed count in the StorageAreaMap object that's incremented
everytime the map is reset. Associate every storage area change with the seed and ignore any incoming
notification messages from the UI process if the seeds are different.

* Platform/CoreIPC/HandleMessage.h:
(CoreIPC):
(CoreIPC::callMemberFunction):
* UIProcess/Storage/StorageManager.cpp:
(WebKit::StorageManager::getValues):
(WebKit::StorageManager::setItem):
(WebKit::StorageManager::removeItem):
(WebKit::StorageManager::clear):
* UIProcess/Storage/StorageManager.h:
(StorageManager):
* UIProcess/Storage/StorageManager.messages.in:
* WebProcess/Storage/StorageAreaMap.cpp:
(WebKit::StorageAreaMap::StorageAreaMap):
(WebKit::StorageAreaMap::setItem):
(WebKit::StorageAreaMap::removeItem):
(WebKit::StorageAreaMap::clear):
(WebKit::StorageAreaMap::resetValues):
(WebKit::StorageAreaMap::loadValuesIfNeeded):
(WebKit::StorageAreaMap::didGetValues):
(WebKit::StorageAreaMap::didSetItem):
(WebKit::StorageAreaMap::didRemoveItem):
(WebKit::StorageAreaMap::didClear):
(WebKit::StorageAreaMap::applyChange):
* WebProcess/Storage/StorageAreaMap.h:
(StorageAreaMap):
* WebProcess/Storage/StorageAreaMap.messages.in:

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

6 years agoSource/WebCore: Floats should not overhang from flex items
commit-queue@webkit.org [Mon, 13 May 2013 19:30:37 +0000 (19:30 +0000)]
Source/WebCore: Floats should not overhang from flex items
https://bugs.webkit.org/show_bug.cgi?id=115925

Patch by Bem Jones-Bey <bjonesbe@adobe.com> on 2013-05-13
Reviewed by David Hyatt.

Allowing floats to overhand from flex items is not only against the
spec, it causes bad bugs. Fix this by having flex items properly avoid
floats.

Test: fast/block/float/float-not-removed-crash2.html

* rendering/RenderBox.cpp:
(WebCore::RenderBox::avoidsFloats): Add flex items to avoid floats.
* rendering/RenderBox.h:
(WebCore::RenderBox::isFlexItemIncludingDeprecated): Determine if the current box is a
    flex item or deprecated flex item.

LayoutTests: Fix the float logic to not return an anonymous block ancestor
https://bugs.webkit.org/show_bug.cgi?id=115925

Patch by Bem Jones-Bey <bjonesbe@adobe.com> on 2013-05-13
Reviewed by David Hyatt.

Cleaned up fuzzer test. Note that this will only crash when run under
a memory checker like ASAN.

* fast/block/float/float-not-removed-crash2-expected.txt: Added.
* fast/block/float/float-not-removed-crash2.html: Added.

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

6 years ago[webkitpy] Make FileInfo.repository_name support SVN version > 1.6
ossy@webkit.org [Mon, 13 May 2013 19:23:16 +0000 (19:23 +0000)]
[webkitpy] Make FileInfo.repository_name support SVN version > 1.6
https://bugs.webkit.org/show_bug.cgi?id=116016

Reviewed by Dirk Pranke.

Same fix as in the upstream style checker, but without hg support.
( http://google-styleguide.googlecode.com/svn/trunk/cpplint/cpplint.py )

* Scripts/webkitpy/style/checkers/cpp.py:
(FileInfo.repository_name):

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

6 years ago[CSS Regions][CSS Exclusions] Shape-inside on regions should respect region borders...
zoltan@webkit.org [Mon, 13 May 2013 19:11:33 +0000 (19:11 +0000)]
[CSS Regions][CSS Exclusions] Shape-inside on regions should respect region borders and paddings
https://bugs.webkit.org/show_bug.cgi?id=115456

Reviewed by David Hyatt.

I refactored the computation logic of shape-inside on regions by removing access to RenderFlowThread from ExclusionShapeInfo's logicalTopOffset
function, this means all the logic is now existing in RenderBlockLineLayout.cpp. By modifying the logicalTopOffset it turned out that the borders
and padding hadn't worked correctly, since borders and paddings were counted twice in the shape-inside's computation. This patch adds the necessary
modifications to let it respect the borders and padding in the correct way. I created 2 new helper functions to prevent increasing the code size of
the layoutRunsAndFloatsInRange function.

Source/WebCore:

I introduced 7 new tests to test for testing the correct behavior.

Tests: fast/regions/shape-inside/shape-inside-on-first-region-block-content.html
       fast/regions/shape-inside/shape-inside-on-first-region-inline-content.html
       fast/regions/shape-inside/shape-inside-on-second-region-block-content.html
       fast/regions/shape-inside/shape-inside-on-second-region-inline-content.html
       fast/regions/shape-inside/shape-inside-on-regions-inline-content.html
       fast/regions/shape-inside/shape-inside-with-region-borders.html
       fast/regions/shape-inside/shape-inside-with-region-padding.html

* rendering/ExclusionShapeInfo.cpp:
(WebCore): Remove FlowThread logic from logicalTopOffset move definition to header.
* rendering/ExclusionShapeInfo.h:
(WebCore::ExclusionShapeInfo::logicalTopOffset): Moved from cpp.
(WebCore::ExclusionShapeInfo::logicalLeftOffset): Add condition for RenderRegions.
* rendering/RenderBlock.h:
(RenderBlock): Add definition to the new helper members.
* rendering/RenderBlockLineLayout.cpp:
(WebCore::RenderBlock::layoutExclusionShapeInsideInfo): Modified the flow thread case to return the appropriate region.
(WebCore::RenderBlock::updateLineBoundariesForExclusions): Added new helper function. Modify the shape-inside on regions
line boundaries and position computation logic.
(WebCore::RenderBlock::adjustLogicalLineTopAndLogicalHeightIfNeeded): Added new helper function which handles the flow thread case also.
(WebCore::RenderBlock::layoutRunsAndFloatsInRange): Modified the code to use the helper functions.

LayoutTests:

* fast/regions/shape-inside/shape-inside-on-additional-regions-expected.html: Modify to not use shape-inside for testing.
* fast/regions/shape-inside/shape-inside-on-additional-regions.html: Fix the shape-inside's dimension.
* fast/regions/shape-inside/shape-inside-on-first-region-block-content-expected.html: Added.
* fast/regions/shape-inside/shape-inside-on-first-region-block-content.html: Added.
* fast/regions/shape-inside/shape-inside-on-first-region-inline-content-expected.html: Added.
* fast/regions/shape-inside/shape-inside-on-first-region-inline-content.html: Added.
* fast/regions/shape-inside/shape-inside-on-regions-expected.html: Match the shape-inside height to the container's height.
* fast/regions/shape-inside/shape-inside-on-regions-inline-content-expected.html: Added.
* fast/regions/shape-inside/shape-inside-on-regions.html: Match the shape-inside height to the container's height.
* fast/regions/shape-inside/shape-inside-on-second-region-block-content-expected.html: Added.
* fast/regions/shape-inside/shape-inside-on-second-region-block-content.html: Added.
* fast/regions/shape-inside/shape-inside-on-second-region-inline-content-expected.html: Added.
* fast/regions/shape-inside/shape-inside-on-second-region-inline-content.html: Added.
* fast/regions/shape-inside/shape-inside-with-region-borders-expected.html: Added.
* fast/regions/shape-inside/shape-inside-with-region-borders.html: Added.
* fast/regions/shape-inside/shape-inside-with-region-padding-expected.html: Added.
* fast/regions/shape-inside/shape-inside-with-region-padding.html: Added.

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

6 years agoUnreviewed. AppleWin VS2005 build fix.
roger_fong@apple.com [Mon, 13 May 2013 19:06:42 +0000 (19:06 +0000)]
Unreviewed. AppleWin VS2005 build fix.

* WebKit.vcproj/WebKitExports.def.in:

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

6 years ago[css exclusions] Enable CSS Exclusions by default when CSS_EXCLUSIONS is set
betravis@adobe.com [Mon, 13 May 2013 18:37:13 +0000 (18:37 +0000)]
[css exclusions] Enable CSS Exclusions by default when CSS_EXCLUSIONS is set
https://bugs.webkit.org/show_bug.cgi?id=115919

Reviewed by Dean Jackson.

Source/WebCore:

Change the RuntimeEnabledFeatures::isCSSExclusionsEnabled boolean to default
to true. CSS Exclusions can still be enabled / disabled in platforms by
setting the CSS_EXCLUSIONS compile flag in one of the FeatureDefine files.

Test: fast/exclusions/css-exclusions-enabled.html

* bindings/generic/RuntimeEnabledFeatures.cpp:
(WebCore):

LayoutTests:

Adding a test to make sure CSS Exclusions can be enabled, and are enabled by
default.

* fast/exclusions/css-exclusions-enabled-expected.txt: Added.
* fast/exclusions/css-exclusions-enabled.html: Added.

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

6 years ago[WK2][CoordinatedGraphics] Avoid dispensable calls to WebView::updateViewportSize()
commit-queue@webkit.org [Mon, 13 May 2013 18:24:14 +0000 (18:24 +0000)]
[WK2][CoordinatedGraphics] Avoid dispensable calls to WebView::updateViewportSize()
https://bugs.webkit.org/show_bug.cgi?id=116045

Patch by Jesus Sanchez-Palencia <jesus.palencia@openbossa.org> on 2013-05-13
Reviewed by Darin Adler.

* UIProcess/CoordinatedGraphics/WebView.cpp:
(WebKit::WebView::setSize):

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

6 years agoCell heights are disproportional when a row-spanning cell contains a block element...
commit-queue@webkit.org [Mon, 13 May 2013 18:16:51 +0000 (18:16 +0000)]
Cell heights are disproportional when a row-spanning cell contains a block element that determines the height of the rows
https://bugs.webkit.org/show_bug.cgi?id=52185

Patch by Suchit Agrawal <a.suchit@samsung.com> on 2013-05-13
Reviewed by David Hyatt.

Source/WebCore:

Cells heights are not proper when rowspan cell have its own height and rowspan height
is more than the height of the rows present in rowspan.

After calculating logical height of the rows in the table, we are recalculating the height
of the rows present in rowspan. Based on the ratio of row's logical height, we are
distributing rowspan cell height in rows.

Test: fast/table/table-rowspan-height-distribution-in-rows.html

* rendering/RenderTableSection.cpp:
(WebCore):

Update the logical height of the rows based on rowspan cell height.
(WebCore::RenderTableSection::distributeRowSpanHeightToRows):

It calculates logical height of the rows in the table.
(WebCore::RenderTableSection::calcRowLogicalHeight):

Added new private API to distribute rowSpan cell height in rows.
* rendering/RenderTableSection.h:
(RenderTableSection):

LayoutTests:

Test case updated.
* fast/css/vertical-align-baseline-rowspan-007.htm:

Reference Test cases updated.
* fast/css/vertical-align-baseline-rowspan-007-expected.html:
* fast/css/vertical-align-baseline-rowspan-008-expected.html:

Added test cases based on changes in the code and different scenarios for rowspan height
distribution in rows.
* fast/table/table-rowspan-height-distribution-in-rows.html: Added.
* platform/qt/fast/table/table-rowspan-height-distribution-in-rows-expected.png: Added.
* platform/qt/fast/table/table-rowspan-height-distribution-in-rows-expected.txt: Added.

Test cases need to rebaseline in qt, efl, gtk and mac platforms.
* platform/efl/TestExpectations:
* platform/gtk/TestExpectations:
* platform/mac/TestExpectations:
* platform/qt/TestExpectations:

Test case results are updated in qt platform.
* platform/qt/tables/mozilla/bugs/bug17548-expected.png:
* platform/qt/tables/mozilla/bugs/bug17548-expected.txt:
* platform/qt/tables/mozilla/bugs/bug220536-expected.png:
* platform/qt/tables/mozilla/bugs/bug220536-expected.txt:
* platform/qt/tables/mozilla/bugs/bug7714-expected.png:
* platform/qt/tables/mozilla/bugs/bug7714-expected.txt:
* platform/qt/tables/mozilla/core/bloomberg-expected.png:
* platform/qt/tables/mozilla/core/bloomberg-expected.txt:
* platform/qt/tables/mozilla/other/test6-expected.png:
* platform/qt/tables/mozilla/other/test6-expected.txt:
* platform/qt/tables/mozilla_expected_failures/bugs/bug1010-expected.png:
* platform/qt/tables/mozilla_expected_failures/bugs/bug1010-expected.txt:
* platform/qt/tables/mozilla_expected_failures/bugs/bug23847-expected.png:
* platform/qt/tables/mozilla_expected_failures/bugs/bug58402-2-expected.png:
* platform/qt/tables/mozilla_expected_failures/bugs/bug58402-2-expected.txt:
* platform/qt/tables/mozilla_expected_failures/bugs/bug6933-expected.png:
* platform/qt/tables/mozilla_expected_failures/bugs/bug6933-expected.txt:
* tables/mozilla/core/bloomberg-expected.txt:
* tables/mozilla_expected_failures/bugs/bug23847-expected.txt:

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

6 years ago[GStreamer] cannot seek after video finished
kbalazs@webkit.org [Mon, 13 May 2013 17:07:01 +0000 (17:07 +0000)]
[GStreamer] cannot seek after video finished
https://bugs.webkit.org/show_bug.cgi?id=114044

Patch by Balazs Kelemen <b.kelemen@sisa.samsung.com> on 2013-04-30
Reviewed by Philippe Normand.

Source/WebCore:

Test: media/video-seek-after-end.html

Rework the seeking logic to be able to seek after reseting the pipeline.
In addition to solve the actual problem this patch supposed to make seeking
more robust and correct.
The previous implementation tried to hide the complexity of asynchronous operations
on the pipeline. It did not handle the GST_MESSAGE_ASYNC_DONE message from the bus
but instead reported the seek as finished when it saw an asynchronous pending state
(GST_STATE_CHANGE_ASYNC) which could happen way before the seek is really done.
Now we pay attention to the GST_MESSAGE_ASYNC_DONE message to track the status of seeks.
Seeks are not the only operations executed asynchronously, changing the pipeling state is
similar. It means a seek can overlap with onother ongoing asynchronous operation.
This change address this by introducing an invariant for seeks, which is that we only request
a seek if there are no other ongoing asynchronous operations and the pipeline state is either
paused or playing (which is recommended anyway according to GStreamer's documentation).
This way we can be sure that the time when we get the next GST_MESSAGE_ASYNC_DONE message the
seek has been completed.

* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::toGstClockTime): Factored time conversation into a helper.
(WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):

(WebCore::MediaPlayerPrivateGStreamer::playbackPosition): The position might not be available
if the pipeline still has a pending state. As a workaround, if we are right after a seek we can
use the seek time. Avoiding this situation would be possible by not allowing any asynchronous
operation to overlap. I believe it would add a lot more complexity so I decided to rather introduce
this workaround. Otherwise those overlapping operations are handled fine by GStreamer.

(WebCore::MediaPlayerPrivateGStreamer::prepareToPlay): Do not reset internal state variables.
This function called when there is an intent to restart playback but it does not actually restart it.
(WebCore::MediaPlayerPrivateGStreamer::currentTime): Just removed a staling newline.
(WebCore::MediaPlayerPrivateGStreamer::seek): Take a look to the pipeline state and act upon that.
If there is an ongoing asynchronous operation make the seek pending, otherwise do it now.
Now we handle overlapping seeks as well because I saw that it can happen in some tests.
Added an early return for live streams as it doesn't makes sense to try seeking in them.

(WebCore::MediaPlayerPrivateGStreamer::handleMessage): Handle GST_MESSAGE_ASYNC_DONE and some refactoring.
(WebCore::MediaPlayerPrivateGStreamer::asyncStateChangeDone):
(WebCore::MediaPlayerPrivateGStreamer::updateStates): Only handle seeks in the pending case, the rest is
now handled in asyncStateChangeDone.
(WebCore::MediaPlayerPrivateGStreamer::cacheDuration): Do not reset the m_mediaDurationKnown if the pipeline
has an asynchronous pending state because it would fail. It does actually happen when we get a duration message
after restarting the pipeline and it would result in restarting playback from the start. It seems to be a bug
in GStreamer that it sends the duration message too early. Also sanitized this function by merging redundant branches.
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
(MediaPlayerPrivateGStreamer):

LayoutTests:

* media/video-seek-after-end-expected.txt: Added.
* media/video-seek-after-end.html: Added.

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

6 years ago[Qt] Fix a crash on startup in FrameLoaderClientQt::callPolicyFunction with MSVC
jocelyn.turcotte@digia.com [Mon, 13 May 2013 16:44:47 +0000 (16:44 +0000)]
[Qt] Fix a crash on startup in FrameLoaderClientQt::callPolicyFunction with MSVC

Reviewed by Allan Sandfeld Jensen.

It's not clear why it crashes, but here's my guess by looking at the generated
assembly code:
Since we're using a member function pointer to PolicyChecker, the representation
is not necessarily just a simple pointer and might be a bigger structure used
to handle virtual functions resolution.
For a function taking such a function "pointer" as parameter, the compiler doesn't
seem to have the caller and callee agree on which convention to use if the function
pointer's class is non-virtual and only one of the ends doesn't know about it.

Including the definition of the member function pointer's class fixes the crash.

* WebCoreSupport/FrameLoaderClientQt.cpp:

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

6 years ago[WK2] Notification manager removal should not be tied to termination of web processes
jonlee@apple.com [Mon, 13 May 2013 16:19:54 +0000 (16:19 +0000)]
[WK2] Notification manager removal should not be tied to termination of web processes
https://bugs.webkit.org/show_bug.cgi?id=116038
<rdar://problem/10968680>

Reviewed by Ryosuke Niwa.

WebNotificationManagerProxy incorrectly removes the manager when web processes close.
Since it is a supplemental on the web context, the manager should only be removed
when the context is destroyed.

* UIProcess/Notifications/WebNotificationManagerProxy.cpp:
* UIProcess/Notifications/WebNotificationManagerProxy.h: Remove implementation of
processDidClose().

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

6 years agoUnreviewed. Fix Qt Linux MIPS32R2 build after r149879.
carlosgc@webkit.org [Mon, 13 May 2013 16:19:48 +0000 (16:19 +0000)]
Unreviewed. Fix Qt Linux MIPS32R2 build after r149879.

Bring back GLIB_CHECK_VERSION for GBytes since Qt Linux MIPS32R2
depends on glib 2.24.2.

* wtf/gobject/GRefPtr.cpp:
(_GBytes):
(WTF::refGPtr):
(WTF::derefGPtr):

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

6 years ago[GTK] [WebKit2] Use a template file for generated GObject enum files
mrobinson@webkit.org [Mon, 13 May 2013 15:45:52 +0000 (15:45 +0000)]
[GTK] [WebKit2] Use a template file for generated GObject enum files
https://bugs.webkit.org/show_bug.cgi?id=115867

Reviewed by Carlos Garcia Campos.

* GNUmakefile.am: Use a template file instead of specifying portions of the file on the command-line.
* UIProcess/API/gtk/WebKitEnumTypes.cpp.template: Added.
* UIProcess/API/gtk/WebKitEnumTypes.h.template: Added.
* UIProcess/API/gtk/WebKitFindController.cpp: We can no longer rely on WebKitEnumTypes.h to pull in WebKitWebView.h.

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

6 years agoRemove accidental unrelated ChangeLog entry from r150016.
akling@apple.com [Mon, 13 May 2013 15:45:11 +0000 (15:45 +0000)]
Remove accidental unrelated ChangeLog entry from r150016.

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

6 years agoSource/WebCore: [Mac] Move writeRange/PlainText/URL from ClipboardMac to PasteboardMac
darin@apple.com [Mon, 13 May 2013 15:29:36 +0000 (15:29 +0000)]
Source/WebCore: [Mac] Move writeRange/PlainText/URL from ClipboardMac to PasteboardMac
https://bugs.webkit.org/show_bug.cgi?id=116009

Reviewed by Andreas Kling.

* dom/Clipboard.cpp:
(WebCore::Clipboard::writeRange): Added. Moved from ClipboardMac,
but added some FIXMEs.
(WebCore::Clipboard::writePlainText): Ditto.
(WebCore::Clipboard::writeURL): Ditto.

* dom/Clipboard.h: Made writeURL, writeRange, and writePlainText
non-virtual in non-legacy clipboard implementations.

* platform/mac/ClipboardMac.h: Removed writeRange, writeURL, and
writePlainText.
* platform/mac/ClipboardMac.mm: Ditto.

Source/WebKit/mac: [Mac] Layer-backed WebViews draw their background color even when setDrawsBackground:NO was called
https://bugs.webkit.org/show_bug.cgi?id=116014
<rdar://problem/12781227>

Reviewed by Andreas Kling.

* WebView/WebFrame.mm:
(-[WebFrame _updateBackgroundAndUpdatesWhileOffscreen]): Remove calls to setBackgroundColor: and
setDrawsBackground: on the document view. These were added to support a hypothetical document view
that wanted to draw its background like WebHTMLView does, but this was never communicated as a
document view protocol, formal or informal, and it's unlikely that it was ever used. The bug was
caused because there is an -[NSView setDrawsBackground:] method, probably an internal one, and we
were calling it unintentionally on a WebHTMLView.

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

6 years ago[CoordGfx] requestAnimationFrame performance issues
commit-queue@webkit.org [Mon, 13 May 2013 15:29:01 +0000 (15:29 +0000)]
[CoordGfx] requestAnimationFrame performance issues
https://bugs.webkit.org/show_bug.cgi?id=112345

Patch by Noam Rosenthal <noam@webkit.org> on 2013-05-13
Reviewed by Jocelyn Turcotte.

Source/WebCore:

Removed current requestAnimationFrame logic from CoordinatedGraphics. The new logic
is entirely in WebKit2 CoordinatedLayerTreeHost.

Covered by existing tests in fast/animations.

* platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
(WebCore::CoordinatedGraphicsScene::CoordinatedGraphicsScene):
(WebCore::CoordinatedGraphicsScene::paintToCurrentGLContext):
* platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
(CoordinatedGraphicsScene):

Source/WebKit2:

Changed the logic of requestAnimationFrame in Coordinated Graphics.
We don't send any IPC messages for requestAnimationFrame. Instead, we do one of two things:
- If there is already a frame pending in the UI process, do nothing, as the animations would
  be serviced when the frame is returned to the web process.
- If there is no frame pending, we schedule a flush, making sure that that flush occurs at
  least 1/60 seconds after the last animation service, so that we don't get an infinite loop
  of flushes.

* UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.cpp:
(WebKit::CoordinatedLayerTreeHostProxy::requestAnimationFrame):
* UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.h:
* WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
(WebKit::CoordinatedLayerTreeHost::CoordinatedLayerTreeHost):
(WebKit::CoordinatedLayerTreeHost::flushPendingLayerChanges):
(WebKit::CoordinatedLayerTreeHost::scheduleAnimation):
* WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
* WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.messages.in:

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

6 years ago[texmap][GStreamer] Composited Video support
commit-queue@webkit.org [Mon, 13 May 2013 15:14:46 +0000 (15:14 +0000)]
[texmap][GStreamer] Composited Video support
https://bugs.webkit.org/show_bug.cgi?id=86410

Patch by Víctor Manuel Jáquez Leal <vjaquez@igalia.com> on 2013-05-13
Reviewed by Philippe Normand.

Enable the video accelerated compositing using the WebKit's
TextureMapper.

This patch does not use hardware accelerated video decoding. It
provides a generic path for system memory buffers.

No new tests, already covered by existing tests.

* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::MediaPlayerPrivateGStreamerBase::MediaPlayerPrivateGStreamerBase):
(WebCore):
(WebCore::MediaPlayerPrivateGStreamerBase::updateTexture): update the
texture content with the new received video buffer.
(WebCore::MediaPlayerPrivateGStreamerBase::triggerRepaint): choose to
use the accelerated compositing or the normal code path
(WebCore::MediaPlayerPrivateGStreamerBase::paint): if accelerated
compositing is used this method is halted.
(WebCore::MediaPlayerPrivateGStreamerBase::paintToTextureMapper): get
a texture from the pool and draws it if it is already available.
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
(MediaPlayerPrivateGStreamerBase):
(WebCore::MediaPlayerPrivateGStreamerBase::platformLayer): returns itself
(WebCore::MediaPlayerPrivateGStreamerBase::supportsAcceleratedRendering):
returns true

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

6 years agoDocument: Use a DeferrableOneShotTimer to throw out StyleResolver when unused.
akling@apple.com [Mon, 13 May 2013 15:05:18 +0000 (15:05 +0000)]
Document: Use a DeferrableOneShotTimer to throw out StyleResolver when unused.
<http://webkit.org/b/115929>

Reviewed by Anders Carlsson.

Nothing exciting here, just replacing a rickety-looking punting mechanism with a proper
DeferrableOneShotTimer. Note that the timeout changes from 60 to 30 seconds because DOST
works by punting a full interval on next timeout.

* dom/Document.cpp:
(WebCore::Document::Document):
(WebCore::Document::didAccessStyleResolver):
(WebCore::Document::styleResolverThrowawayTimerFired):
* dom/Document.h:
(Document):

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

6 years ago[WK2][CoordinatedGraphics] WKView needs API for handling opacity
commit-queue@webkit.org [Mon, 13 May 2013 14:59:15 +0000 (14:59 +0000)]
[WK2][CoordinatedGraphics] WKView needs API for handling opacity
https://bugs.webkit.org/show_bug.cgi?id=116032

Patch by Jesus Sanchez-Palencia <jesus.palencia@openbossa.org> on 2013-05-13
Reviewed by Kenneth Rohde Christiansen.

Add WKViewSetOpacity and WKViewOpacity APIs and use them in
WebView.cpp.

* UIProcess/API/C/CoordinatedGraphics/WKView.cpp:
(WKViewSetOpacity):
(WKViewOpacity):
* UIProcess/API/C/CoordinatedGraphics/WKView.h:
* UIProcess/CoordinatedGraphics/WebView.cpp:
(WebKit::WebView::WebView):
(WebKit::WebView::paintToCurrentGLContext):
* UIProcess/CoordinatedGraphics/WebView.h:
(WebKit::WebView::setOpacity):
(WebKit::WebView::opacity):
(WebView):

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

6 years agoREGRESSION(r149287): FoldingText only shows me half of my text.
akling@apple.com [Mon, 13 May 2013 14:55:38 +0000 (14:55 +0000)]
REGRESSION(r149287): FoldingText only shows me half of my text.
<http://webkit.org/b/115956>
<rdar://problem/13831099>

Reviewed by Antti Koivisto.

Check if the FrameView geometry changed post-layout, and send a resize event if needed.
This brings us closer to the original resize event behavior, with the exception that
setFrameRect() still fires an event right away if possible. This means we are still
guarded from FOUC's but frames that layout via [WebHTMLView layoutToMinimumPageWidth]
also get resize events like they used to.

No new tests, because I don't know how to test this.

* page/FrameView.h:
* page/FrameView.cpp:
(WebCore::FrameView::setFrameRect):
(WebCore::FrameView::performPostLayoutTasks):
(WebCore::FrameView::sendResizeEventIfNeeded):

    Factor out the resize event logic from setFrameRect() so we can call it from both
    there and performPostLayoutTasks(). sendResizeEventIfNeeded() only sends an event
    if view geometry or zoom factor has changed since last time it was called.

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

6 years agoRemove unneeded counters from ScopeContentDistribution.
antti@apple.com [Mon, 13 May 2013 14:26:27 +0000 (14:26 +0000)]
Remove unneeded counters from ScopeContentDistribution.
https://bugs.webkit.org/show_bug.cgi?id=116028

Reviewed by Andreas Kling.

They don't do much.

* WebCore.exp.in:
* dom/ShadowRoot.cpp:
(WebCore::ShadowRoot::ShadowRoot):
* dom/ShadowRoot.h:

    No need for registration code anymore.

* html/shadow/ContentDistributor.cpp:
(WebCore::ScopeContentDistribution::ScopeContentDistribution):

    Default m_insertionPointListIsValid to true to avoid crawling when there are no InsertionPoints.

(WebCore::ScopeContentDistribution::ensureInsertionPointList):
(WebCore::ScopeContentDistribution::registerInsertionPoint):
(WebCore::ScopeContentDistribution::unregisterInsertionPoint):
* html/shadow/ContentDistributor.h:

    Remove distributeNodeChildrenTo, it was only used by the older/younger shadow root code.

* testing/Internals.cpp:
* testing/Internals.h:
* testing/Internals.idl:

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

6 years agoWeb Inspector: Get rid of native-memory-snapshot in performance test
commit-queue@webkit.org [Mon, 13 May 2013 14:03:57 +0000 (14:03 +0000)]
Web Inspector: Get rid of native-memory-snapshot in performance test
https://bugs.webkit.org/show_bug.cgi?id=116013

Patch by Seokju Kwon <seokju.kwon@gmail.com> on 2013-05-13
Reviewed by Andreas Kling.

Remove native-memory-snapshot.html from PerformanceTests.

* inspector/native-memory-snapshot.html: Removed.
* inspector/performance-test.js:
(initialize_TimeTracker.Timer):
(initialize_TimeTracker.Timer.prototype._dump):
(initialize_TimeTracker.InspectorTest.runPerformanceTest):

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

6 years ago[GTK] Use WebCore layer archives for TestWebCore, WebKitPluginProcess
zandobersek@gmail.com [Mon, 13 May 2013 13:55:31 +0000 (13:55 +0000)]
[GTK] Use WebCore layer archives for TestWebCore, WebKitPluginProcess
https://bugs.webkit.org/show_bug.cgi?id=115918

Reviewed by Gustavo Noronha Silva.

Source/WebKit2:

Due to layer violations and circular dependencies the WebKitPluginProcess requires for the
libraries containing the built code of the intertwining Platform and WebCore layers to be
specified multiple times when linking. This can be avoided by packing the two layers' archives
into one big archive, named after the WebCore layer due to no clear boundary between it and the
Platform layer. The big archive can then be specified only once when linking, simplifying the code
and suppressing all the layering violations so they do not cause build problems.

First the libtool libraries that the WebCore layer (as required by the WebKitPluginProcess) depends on
are specified. These are then used as dependencies for the archive creation rule as well as the list
from which the archive file paths are constructed and then used to dump the member files from these archives.
The member files are then added to the big archive. The latter is added to the list of libraries the
WebKitPluginProcess requires to successfully link.

* GNUmakefile.am:

Tools:

Due to layer violations and circular dependencies the TestWebCores requires for the libraries containing
the built code of the intertwining Platform and WebCore layers to be specified multiple times when linking.
This can be avoided by packing the two layers' archives into one big archive, named after the WebCore layer
due to no clear boundary between it and the Platform layer. The big archive can then be specified only once
when linking, simplifying the code and suppressing all the layering violations so they do not cause build
problems.

First the libtool libraries that the WebCore layer (as required by the TestWebCore) depends on are specified.
These are then used as dependencies for the archive creation rule as well as the list from which the archive
file paths are constructed and then used to dump the member files from these archives. The member files are
then added to the big archive. The latter is added to the list of libraries the TestWebCore requires to
successfully link.

* TestWebKitAPI/GNUmakefile.am:

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

6 years agoRemove UnusedParam.h
andersca@apple.com [Mon, 13 May 2013 13:52:38 +0000 (13:52 +0000)]
Remove UnusedParam.h
https://bugs.webkit.org/show_bug.cgi?id=116029

Reviewed by Andreas Kling.

Source/WTF:

Remove UnusedParam.h, it's empty now.

* GNUmakefile.list.am:
* WTF.pro:
* WTF.vcproj/WTF.vcproj:
* WTF.vcxproj/WTF.vcxproj:
* WTF.vcxproj/WTF.vcxproj.filters:
* WTF.xcodeproj/project.pbxproj:
* wtf/CMakeLists.txt:
* wtf/UnusedParam.h: Removed.

Tools:

Stop including UnusedParam.h.

* DumpRenderTree/blackberry/TestRunnerBlackBerry.cpp:
* WebKitTestRunner/qt/TestInvocationQt.cpp:

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

6 years agoUnreviewed EFL gardening.
ch.dumez@sisa.samsung.com [Mon, 13 May 2013 11:32:15 +0000 (11:32 +0000)]
Unreviewed EFL gardening.

Mark several test cases as crashing on EFL port.

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

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

6 years agoUnreviewed EFL gardening.
ch.dumez@sisa.samsung.com [Mon, 13 May 2013 11:08:13 +0000 (11:08 +0000)]
Unreviewed EFL gardening.

Mark 2 ref tests as failing on EFL port.

* platform/efl/TestExpectations:

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

6 years agoUnreviewed EFL gardening.
ch.dumez@sisa.samsung.com [Mon, 13 May 2013 11:00:21 +0000 (11:00 +0000)]
Unreviewed EFL gardening.

Skip 2 HTTP tests that time out of EFL port.

* platform/efl/TestExpectations:

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

6 years agoUnreviewed EFL gardening.
ch.dumez@sisa.samsung.com [Mon, 13 May 2013 10:53:03 +0000 (10:53 +0000)]
Unreviewed EFL gardening.

Provide EFL baselines for several compositing test cases.

* platform/efl/compositing/backing/no-backing-for-clip-overhang-expected.txt: Added.
* platform/efl/compositing/contents-opaque/hidden-with-visible-child-expected.txt: Added.
* platform/efl/compositing/contents-opaque/hidden-with-visible-text-expected.txt: Added.
* platform/efl/compositing/contents-opaque/overflow-hidden-child-layers-expected.txt: Added.

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

6 years agoWeb Inspector: Remove unused references from projects in Visual Studio
commit-queue@webkit.org [Mon, 13 May 2013 10:50:29 +0000 (10:50 +0000)]
Web Inspector: Remove unused references from projects in Visual Studio
https://bugs.webkit.org/show_bug.cgi?id=116002

Patch by Seokju Kwon <seokju.kwon@gmail.com> on 2013-05-13
Reviewed by Csaba Osztrogonác.

nativeMemoryProfiler.css and NativeMemorySnapshotView.js were removed in r149807.

No new tests, no behavior change.

* WebCore.vcproj/WebCore.vcproj:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:

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

6 years agoWebProcess consuming very high CPU on linkedin.com
commit-queue@webkit.org [Mon, 13 May 2013 08:53:48 +0000 (08:53 +0000)]
WebProcess consuming very high CPU on linkedin.com
https://bugs.webkit.org/show_bug.cgi?id=115601

Patch by Zalan Bujtas <zalan@apple.com> on 2013-05-13
Reviewed by Andreas Kling.

Disable WEB_TIMING_MINIMAL.
Turn off window.performance and performance.now(). Some JS frameworks expect
additional Web Timing APIs, when performance.now() is available.

Source/JavaScriptCore:

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

* Configurations/FeatureDefines.xcconfig:
* dom/EventTargetFactory.in:
* page/DOMWindow.cpp:
(WebCore::DOMWindow::~DOMWindow):
(WebCore::DOMWindow::resetDOMWindowProperties):
(WebCore):
* page/DOMWindow.h:
(DOMWindow):
* page/DOMWindow.idl:
* page/Performance.cpp:
(WebCore::Performance::timing):
* page/Performance.h:
(Performance):
* page/Performance.idl:

Source/WebKit/mac:

* Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

* Configurations/FeatureDefines.xcconfig:

Source/WTF:

* wtf/FeatureDefines.h:

LayoutTests:

* platform/mac/TestExpectations:
* fast/js/global-constructors-attributes-expected.txt:

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

6 years ago[Mac] Layer-backed WebViews draw their background color even when setDrawsBackground...
darin@apple.com [Mon, 13 May 2013 08:37:33 +0000 (08:37 +0000)]
[Mac] Layer-backed WebViews draw their background color even when setDrawsBackground:NO was called
https://bugs.webkit.org/show_bug.cgi?id=116014
<rdar://problem/12781227>

Reviewed by Dan Bernstein.

* WebView/WebFrame.mm:
(-[WebFrame _updateBackgroundAndUpdatesWhileOffscreen]): Remove calls to setBackgroundColor: and
setDrawsBackground: on the document view. These were added to support a hypothetical document view
that wanted to draw its background like WebHTMLView does, but this was never communicated as a
document view protocol, formal or informal, and it's unlikely that it was ever used. The bug was
caused because there is an -[NSView setDrawsBackground:] method, probably an internal one, and we
were calling it unintentionally on a WebHTMLView.

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

6 years ago[Qt] Unreviewed gardening. Added platform specific expected files.
kadam@inf.u-szeged.hu [Mon, 13 May 2013 07:33:50 +0000 (07:33 +0000)]
[Qt] Unreviewed gardening. Added platform specific expected files.

* platform/qt-5.0-wk1/compositing/backing/no-backing-for-clip-overhang-expected.txt: Added after r149969.
* platform/qt-5.0-wk2/compositing/contents-opaque/hidden-with-visible-child-expected.txt: Added after r149915.
* platform/qt-5.0-wk2/compositing/contents-opaque/hidden-with-visible-text-expected.txt: Added after r149915.
* platform/qt-5.0-wk2/compositing/contents-opaque/overflow-hidden-child-layers-expected.txt: Added after r149914.
* platform/qt/compositing/backing/no-backing-for-clip-overhang-expected.txt: Added after r149969.

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

6 years agoREGRESSION (r149749): Video becomes invisible when it starts playing at newyorkbygehr...
eric.carlson@apple.com [Mon, 13 May 2013 06:40:52 +0000 (06:40 +0000)]
REGRESSION (r149749): Video becomes invisible when it starts playing at newyorkbygehry.com
https://bugs.webkit.org/show_bug.cgi?id=115963

Reviewed by Dean Jackson.

Source/WebCore:

Test: media/video-remove-insert-repaints.html

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::insertedInto): Set m_inActiveDocument when inserted into a document.
(WebCore::HTMLMediaElement::removedFrom): Fix logging.

LayoutTests:

* media/video-remove-insert-repaints.html: Added.
* media/video-remove-insert-repaints-expected.txt: Added.
* platform/mac/media/video-remove-insert-repaints-expected.png: Added.

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

6 years ago[EFL] Unreviewed EFL gardening
commit-queue@webkit.org [Mon, 13 May 2013 06:39:19 +0000 (06:39 +0000)]
[EFL] Unreviewed EFL gardening
https://bugs.webkit.org/show_bug.cgi?id=116004

Unreviewed EFL gardening

Patch by Jinwoo Song <jinwoo7.song@samsung.com> on 2013-05-12

* platform/efl-wk2/TestExpectations:
* platform/efl/fast/block/lineboxcontain/block-with-ideographs-expected.txt: Added.
* platform/efl/fast/selectors/unqualified-hover-strict-expected.txt: Added.
* platform/efl/fast/text/text-combine-different-fonts-expected.txt: Added.
* platform/efl/ietestcenter/css3/bordersbackgrounds/background-repeat-space-padding-box-expected.txt: Added.
* platform/efl/tables/mozilla/bugs/bug113235-2-expected.txt: Added.
* platform/efl/tables/mozilla_expected_failures/bugs/bug45621-expected.txt: Added.

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

6 years agoMove sudden termination symbols to the Mac-only section
ddkilzer@apple.com [Mon, 13 May 2013 06:25:22 +0000 (06:25 +0000)]
Move sudden termination symbols to the Mac-only section

* WebCore.exp.in: Move the sudden termination symbols to the
!PLATFORM(IOS) section for reals this time.

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

6 years ago Fix Mac build.
darin@apple.com [Mon, 13 May 2013 06:24:07 +0000 (06:24 +0000)]
    Fix Mac build.

        * platform/mac/PasteboardMac.mm: Add back include of ClipboardMac.h
        that was removed by accident a couple of patches back.

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

6 years ago[Mac] Moved files function from ClipboardMac to PasteboardMac
darin@apple.com [Mon, 13 May 2013 05:35:20 +0000 (05:35 +0000)]
[Mac] Moved files function from ClipboardMac to PasteboardMac
https://bugs.webkit.org/show_bug.cgi?id=116008

Reviewed by Anders Carlsson.

* dom/Clipboard.cpp:
(WebCore::Clipboard::files): Added. Moved the DOM-depdendent and
platform-independent part of the files function in ClipboardMac here.

* dom/Clipboard.h: Made files function non-virtual in non-legacy case.

* platform/Pasteboard.h: Removed static member function
absoluteURLsFromPasteboardFilenames since it can now be private to
PasteboardMac. Added member function readFilenames.

* platform/mac/ClipboardMac.h: Removed function member files and also
now-unused data member m_clipboardContents.

* platform/mac/ClipboardMac.mm: Removed files function.
(WebCore::ClipboardMac::ClipboardMac): Removed code to initialize
m_clipboardContents.

* platform/mac/PasteboardMac.mm:
(WebCore::absoluteURLsFromPasteboardFilenames): Changed from a static
member function to a file-local function.
(WebCore::absoluteURLsFromPasteboard): Changed to call the function
above in its new location.
(WebCore::Pasteboard::readFilenames): Added. Code from ClipboardMac,
minus the DOM-specific parts. Added a FIXME about the peculiar round
trip through NSURL this code takes.

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

6 years agoFix WebKit2 build.
andersca@apple.com [Mon, 13 May 2013 05:32:57 +0000 (05:32 +0000)]
Fix WebKit2 build.

* WebCore.exp.in:
Put WebCore::disableSuddenTermination and WebCore::enableSuddenTermination symbols in the right section.

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

6 years ago[Mac] Move types function from ClipboardMac to PasteboardMac
darin@apple.com [Mon, 13 May 2013 05:26:39 +0000 (05:26 +0000)]
[Mac] Move types function from ClipboardMac to PasteboardMac
https://bugs.webkit.org/show_bug.cgi?id=116007

Reviewed by Anders Carlsson.

* dom/Clipboard.cpp:
(WebCore::Clipboard::types): Added. Calls through to Pasteboard
after doing checks needed at this level.

* dom/Clipboard.h: Made types function non-virtual in non-legacy case,
and removed non-helpful comment.

* platform/Pasteboard.h: Updated includes and comments at the top of
the file a bit. Removed static member function addHTMLClipboardTypesForCocoaType,
since it can now be private to PasteboardMac. Added member function types.

* platform/mac/ClipboardMac.h: Removed types function.
* platform/mac/ClipboardMac.mm: Ditto.

* platform/mac/PasteboardMac.mm:
(WebCore::addHTMLClipboardTypesForCocoaType): Made this a file-local
function instead of a static member function.
(WebCore::Pasteboard::types): Added. Moved from ClipboardMac.

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

6 years ago[Mac] Move setData from ClipboardMac to PasteboardMac
darin@apple.com [Mon, 13 May 2013 05:19:32 +0000 (05:19 +0000)]
[Mac] Move setData from ClipboardMac to PasteboardMac
https://bugs.webkit.org/show_bug.cgi?id=116006

Reviewed by Anders Carlsson.

* dom/Clipboard.cpp:
(WebCore::Clipboard::setData): Added. Calls through to Pasteboard
after doing checks needed at this level.

* dom/Clipboard.h: Made setData non-virtual in non-legacy case.

* platform/Pasteboard.h: Updated includes and forward declarations.
Removed static member function cocoaTypeFromHTMLClipboardType, since
it can now be private to PasteboardMac. Added static member function
addHTMLClipboardTypesForCocoaType, which is shared between the
ClipboardMac and PasteboardMac files for now. Added writeString.

* platform/mac/ClipboardMac.h: Removed setData.

* platform/mac/ClipboardMac.mm: Removed utiTypeFromCocoaType,
addHTMLClipboardTypesForCocoaType, and setData.
(WebCore::ClipboardMac::types): Call addHTMLClipboardTypesForCocoaType
as a Pasteboard static member function, for now.

* platform/mac/PasteboardMac.mm:
(WebCore::cocoaTypeFromHTMLClipboardType): Added. Moved from ClipboardMac.
(WebCore::Pasteboard::readString): Changed to call
cocoaTypeFromHTMLClipboardType as a file-local function, not a member
function (in fact, we didn't need to repeat the class name before, either,
so this is just removing something we didn't need).
(WebCore::utiTypeFromCocoaType): Added. Moved from ClipboardMac.
(WebCore::Pasteboard::addHTMLClipboardTypesForCocoaType): Ditto.
(WebCore::Pasteboard::writeString): Ditto.

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

6 years ago[Mac] Move getData from ClipboardMac to PasteboardMac
darin@apple.com [Mon, 13 May 2013 04:44:46 +0000 (04:44 +0000)]
[Mac] Move getData from ClipboardMac to PasteboardMac
https://bugs.webkit.org/show_bug.cgi?id=116005

Reviewed by Anders Carlsson.

* dom/Clipboard.cpp:
(WebCore::Clipboard::Clipboard): Added a new boolean argument, forFileDrag,
to the constructor. Maybe we can find a better way to do this once we move
all the platforms over, but this boolean seems a good way to do it for now.
(WebCore::Clipboard::getData): Added. Calls through to Pasteboard after
doing the canReadData check, which is part of DOM rules, not the platform.
Also checks for the file drag case like the old ClipboardMac code did.

* dom/Clipboard.h: Made getData non-virtual in non-legacy case.

* platform/Pasteboard.h: Added a static member function named
absoluteURLsFromPasteboardFilenames, temporary so it can be shared between
ClipboardMac and PasteboardMac. Added a readString public function member,
and a m_changeCount data member. The type of m_changeCount is long since
that can always hold an NSInteger but yet is a type we can compile without
including the header file that defines NSInteger.

* platform/mac/ClipboardMac.h: Removed getData.
* platform/mac/ClipboardMac.mm: Removed getData.
(WebCore::ClipboardMac::ClipboardMac): Added code to pass in the new
forFileDrag boolean.
(WebCore::ClipboardMac::files): Call absoluteURLsFromPasteboardFilenames
as a static member function in Pasteboard since we moved it there.

* platform/mac/PasteboardMac.mm:
(WebCore::Pasteboard::Pasteboard): Initialize the change count, so later
pasteboard operations can check it.
(WebCore::Pasteboard::absoluteURLsFromPasteboardFilenames): Added. Moved
here from ClipboardMac.
(WebCore::absoluteURLsFromPasteboard): Ditto.
(WebCore::Pasteboard::readString): Added. Moved here from ClipboardMac.

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

6 years agoStop including UnusedParam.h
andersca@apple.com [Mon, 13 May 2013 04:24:20 +0000 (04:24 +0000)]
Stop including UnusedParam.h
https://bugs.webkit.org/show_bug.cgi?id=116003

Reviewed by Sam Weinig.

UnusedParam.h is empty now so there's no need to include it anymore.

Source/JavaScriptCore:

* API/APICast.h:
* API/tests/JSNode.c:
* API/tests/JSNodeList.c:
* API/tests/minidom.c:
* API/tests/testapi.c:
* assembler/AbstractMacroAssembler.h:
* assembler/MacroAssemblerCodeRef.h:
* bytecode/CodeBlock.cpp:
* heap/HandleStack.h:
* interpreter/JSStackInlines.h:
* jit/CompactJITCodeMap.h:
* jit/ExecutableAllocator.h:
* parser/SourceProvider.h:
* runtime/DatePrototype.cpp:
* runtime/JSNotAnObject.cpp:
* runtime/JSSegmentedVariableObject.h:
* runtime/JSVariableObject.h:
* runtime/Options.cpp:
* runtime/PropertyOffset.h:

Source/WebCore:

* Modules/encryptedmedia/CDMPrivateAVFoundation.mm:
* Modules/indexeddb/IDBFactoryBackendImpl.cpp:
* Modules/indexeddb/IDBObjectStore.cpp:
* Modules/webdatabase/DatabaseServer.cpp:
* Modules/webdatabase/DatabaseThread.cpp:
* bindings/js/JSDOMWindowBase.cpp:
* bindings/objc/DOMObject.mm:
* css/CSSCursorImageValue.cpp:
* css/DeprecatedStyleBuilder.cpp:
* dom/EventDispatcher.cpp:
* dom/Node.cpp:
* editing/AlternativeTextController.h:
* editing/Editor.cpp:
* html/HTMLPlugInElement.cpp:
* html/canvas/CanvasRenderingContext2D.cpp:
* html/canvas/OESVertexArrayObject.h:
* html/parser/HTMLConstructionSite.cpp:
* html/parser/HTMLTokenizer.cpp:
* html/track/InbandTextTrack.cpp:
* inspector/InspectorCanvasInstrumentation.h:
* inspector/InspectorConsoleInstrumentation.h:
* inspector/InspectorController.cpp:
* inspector/InspectorCounters.h:
* inspector/InspectorDatabaseInstrumentation.h:
* inspector/InspectorInstrumentation.h:
* loader/DocumentThreadableLoader.cpp:
* loader/PingLoader.cpp:
* loader/appcache/ApplicationCacheGroup.cpp:
* loader/cache/CachedResourceLoader.cpp:
* loader/mac/DocumentLoaderMac.cpp:
* page/ChromeClient.h:
* page/Console.cpp:
* page/FrameView.cpp:
* page/PageConsole.cpp:
* page/animation/AnimationController.cpp:
* page/animation/ImplicitAnimation.cpp:
* page/animation/KeyframeAnimation.cpp:
* platform/LocalizedStrings.cpp:
* platform/ScrollAnimator.h:
* platform/ThreadGlobalData.cpp:
* platform/blackberry/AsyncFileSystemBlackBerry.cpp:
* platform/graphics/Font.cpp:
* platform/graphics/GlyphBuffer.h:
* platform/graphics/Gradient.cpp:
* platform/graphics/ShadowBlur.cpp:
* platform/graphics/SimpleFontData.cpp:
* platform/graphics/SimpleFontData.h:
* platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
* platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
* platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
* platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm:
* platform/graphics/avfoundation/objc/InbandTextTrackPrivateLegacyAVFObjC.mm:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
* platform/graphics/blackberry/GradientBlackBerry.cpp:
* platform/graphics/blackberry/GraphicsContextBlackBerry.cpp:
* platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
* platform/graphics/ca/mac/PlatformCALayerMac.mm:
* platform/graphics/ca/mac/WebTileLayer.mm:
* platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
* platform/graphics/cg/GraphicsContextCG.cpp:
* platform/graphics/cg/ImageBufferCG.cpp:
* platform/graphics/cg/ImageSourceCG.cpp:
* platform/graphics/clutter/PlatformClutterAnimation.cpp:
* platform/graphics/filters/ValidatedCustomFilterOperation.cpp:
* platform/graphics/gstreamer/GStreamerVersioning.cpp:
* platform/graphics/mac/GraphicsContext3DMac.mm:
* platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
* platform/graphics/mac/SimpleFontDataMac.mm:
* platform/graphics/mac/WebGLLayer.mm:
* platform/graphics/mac/WebLayer.mm:
* platform/graphics/mac/WebTiledLayer.mm:
* platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
* platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
* platform/graphics/qt/GraphicsContext3DQt.cpp:
* platform/graphics/texmap/TextureMapper.h:
* platform/graphics/wince/ImageBufferWinCE.cpp:
* platform/mac/PasteboardMac.mm:
* platform/mac/ScrollAnimatorMac.mm:
* platform/mac/ScrollViewMac.mm:
* platform/mac/ScrollbarThemeMac.mm:
* platform/mac/SharedTimerMac.mm:
* platform/mac/WebCoreFullScreenPlaceholderView.mm:
* platform/mac/WebCoreObjCExtras.mm:
* platform/mac/WebFontCache.mm:
* platform/mac/WebVideoFullscreenController.mm:
* platform/mac/WebVideoFullscreenHUDWindowController.mm:
* platform/mac/WebWindowAnimation.mm:
* platform/network/blackberry/CredentialStorageBlackBerry.cpp:
* platform/network/cf/ResourceErrorCF.cpp:
* platform/network/mac/CookieStorageMac.mm:
* platform/network/mac/ResourceHandleMac.mm:
* platform/network/win/ResourceHandleWin.cpp:
* platform/text/TextEncodingDetectorICU.cpp:
* rendering/RenderFlowThread.h:
* rendering/RenderImage.cpp:
* rendering/RenderLayer.cpp:
* rendering/RenderObject.cpp:
* rendering/RenderTreeAsText.cpp:
* rendering/svg/RenderSVGResourceClipper.cpp:
* rendering/svg/RenderSVGResourceFilter.cpp:
* rendering/svg/RenderSVGResourceGradient.cpp:
* rendering/svg/RenderSVGResourceMasker.cpp:
* rendering/svg/SVGRenderSupport.cpp:
* rendering/svg/SVGTextLayoutEngineSpacing.cpp:
* workers/WorkerContext.cpp:
* workers/WorkerScriptLoader.cpp:
* xml/XMLHttpRequest.cpp:
* xml/parser/XMLDocumentParserLibxml2.cpp:

Source/WebKit/efl:

* WebCoreSupport/DumpRenderTreeSupportEfl.cpp:
* ewk/ewk_js.cpp:
* ewk/ewk_security_origin.cpp:
* ewk/ewk_view.cpp:
* ewk/ewk_web_database.cpp:

Source/WebKit/gtk:

* webkit/webkitapplicationcache.cpp:

Source/WebKit/mac:

* Plugins/WebNetscapePluginEventHandlerCocoa.mm:
* WebView/WebDashboardRegion.mm:
* WebView/WebFullScreenController.mm:

Source/WebKit/win:

* WebSecurityOrigin.cpp:

Source/WebKit2:

* UIProcess/API/C/WKContext.cpp:
* UIProcess/API/C/WKInspector.cpp:
* UIProcess/API/C/WKPage.cpp:
* UIProcess/API/efl/ewk_text_checker.cpp:
* UIProcess/API/efl/ewk_view.cpp:
* UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestBase.cpp:
* UIProcess/API/efl/tests/test_ewk2_view.cpp:
* UIProcess/mac/WKFullScreenWindowController.mm:
* WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
* WebProcess/ResourceCache/WebResourceCacheManager.cpp:

Source/WTF:

* wtf/Atomics.h:
* wtf/BoundsCheckedPointer.h:
* wtf/DateMath.h:
* wtf/FastMalloc.cpp:
* wtf/NumberOfCores.cpp:
* wtf/OSAllocator.h:
* wtf/OSAllocatorPosix.cpp:
* wtf/PageAllocation.h:
* wtf/RefCounted.h:
* wtf/TCSystemAlloc.cpp:
* wtf/ThreadingPthreads.cpp:
* wtf/Vector.h:
* wtf/dtoa/cached-powers.cc:
* wtf/dtoa/fixed-dtoa.cc:

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

6 years ago[Mac] Move clearAllData from ClipboardMac to PasteboardMac
darin@apple.com [Mon, 13 May 2013 03:51:12 +0000 (03:51 +0000)]
[Mac] Move clearAllData from ClipboardMac to PasteboardMac
https://bugs.webkit.org/show_bug.cgi?id=116001

Reviewed by Andreas Kling.

* dom/Clipboard.cpp:
(WebCore::Clipboard::clearAllData): Added. Calls through to Pasteboard after
doing the canWriteData check, which is part of DOM rules, not the platform.

* dom/Clipboard.h: Made clearAllData non-virtual in non-legacy case.

* platform/mac/ClipboardMac.h: Removed clearAllData.
* platform/mac/ClipboardMac.mm: Ditto.

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

6 years agoMove UNUSED_PARAM and UNUSED_LABEL macros to Compiler.h
andersca@apple.com [Mon, 13 May 2013 02:56:24 +0000 (02:56 +0000)]
Move UNUSED_PARAM and UNUSED_LABEL macros to Compiler.h
https://bugs.webkit.org/show_bug.cgi?id=115997

Reviewed by Benjamin Poulain.

UnusedParam.h predates Compiler.h and the macros defined there should just go into Compiler.h

* wtf/Compiler.h:
(unusedParam):
* wtf/UnusedParam.h:

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

6 years ago[Mac] Move clearData from ClipboardMac to PasteboardMac
darin@apple.com [Mon, 13 May 2013 02:41:35 +0000 (02:41 +0000)]
[Mac] Move clearData from ClipboardMac to PasteboardMac
https://bugs.webkit.org/show_bug.cgi?id=116000

Reviewed by Andreas Kling.

* dom/Clipboard.cpp:
(WebCore::Clipboard::clearData): Added. Calls through to Pasteboard after
doing the canWriteData check, which is part of DOM rules, not the platform.

* dom/Clipboard.h: Made clearData non-virtual in non-legacy case.

* platform/Pasteboard.h: Added an overload of the clear function that takes
a single type and clears only that type. Also temporarily exported the
cocoaTypeFromHTMLClipboardType function as a static member so it can be used
in both ClipboardMac and PasteboardMac during the transition.

* platform/mac/ClipboardMac.h: Removed clearData.
* platform/mac/ClipboardMac.mm: Removed clearData.
(WebCore::ClipboardMac::getData): Changed to call cocoaTypeFromHTMLClipboardType
as a Pasteboard class static member function.
(WebCore::ClipboardMac::setData): Ditto.

* platform/mac/PasteboardMac.mm:
(WebCore::Pasteboard::cocoaTypeFromHTMLClipboardType): Moved here from
ClipboardMac.
(WebCore::Pasteboard::clear): Added. Moved here from ClipboardMac.

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

6 years ago[Mac] Move hasData from ClipboardMac to PasteboardMac
darin@apple.com [Mon, 13 May 2013 02:28:16 +0000 (02:28 +0000)]
[Mac] Move hasData from ClipboardMac to PasteboardMac
https://bugs.webkit.org/show_bug.cgi?id=115999

Reviewed by Andreas Kling.

* dom/Clipboard.cpp:
(WebCore::Clipboard::hasData): Added. Calls through to Pasteboard.

* dom/Clipboard.h: Added LEGACY_VIRTUAL and LEGACY_PURE macros,
only for within this header file. These help us keep many functions
as pure virtual in the legacy style Clipboard class, but have them
be non-virtual in the normal/future style. Use LEGACY_VIRTUAL and
LEGACY_PURE to make the hasData member non-virtual.

* platform/Pasteboard.h: Added hasData, and added some blank lines and a FIXME.

* platform/mac/ClipboardMac.h: Removed hasData override.
* platform/mac/ClipboardMac.mm: Ditto.

* platform/mac/PasteboardMac.mm:
(WebCore::Pasteboard::hasData): Added. Moved code here from ClipboardMac.

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

6 years agoBUILD FIX (r149971): sudden termination is a Mac-only concept
ddkilzer@apple.com [Mon, 13 May 2013 02:14:42 +0000 (02:14 +0000)]
BUILD FIX (r149971): sudden termination is a Mac-only concept

* WebCore.exp.in: Move sudden termination symbols to Mac-only
section.

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

6 years agoNode: Use FINAL instead of the non-virtual shadowing hack.
akling@apple.com [Mon, 13 May 2013 02:00:28 +0000 (02:00 +0000)]
Node: Use FINAL instead of the non-virtual shadowing hack.
<http://webkit.org/b/115995>

Reviewed by Anders Carlsson.

Decorate Element/Attr implementations of prefix/localName/namespaceURI getters with FINAL
so that call sites with a more specific pointer type than Node* can avoid the virtual dispatch.

* dom/Attr.h:
* dom/Element.h:
* dom/Node.cpp:
* dom/Node.h:

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

6 years agoREGRESSION (r149668): 4 reftest failures under fast/regions on GTK
ryuan.choi@samsung.com [Mon, 13 May 2013 01:31:50 +0000 (01:31 +0000)]
REGRESSION (r149668): 4 reftest failures under fast/regions on GTK
https://bugs.webkit.org/show_bug.cgi?id=115783

Unreviewed rebaseline. They were fixed after r149802.

* platform/efl/TestExpectations:
* platform/gtk/TestExpectations:

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

6 years ago[Mac] Give every Clipboard an underlying Pasteboard
darin@apple.com [Mon, 13 May 2013 01:25:46 +0000 (01:25 +0000)]
[Mac] Give every Clipboard an underlying Pasteboard
https://bugs.webkit.org/show_bug.cgi?id=115979

Reviewed by Andreas Kling.

This is the first step in Clipboard and Pasteboard refactoring
to fix the overlap and many layering violations.

* dom/Clipboard.cpp:
(WebCore::Clipboard::Clipboard): Add an m_pasteboard data member,
Mac-only for now, but eventually for all platforms.
(WebCore::Clipboard::~Clipboard): No longer inline the destructor.

* dom/Clipboard.h: Add WTF_USE_LEGACY_STYLE_ABSTRACT_CLIPBOARD_CLASS
flag, currently true for all non-Mac platforms. Make the constructor
no longer inline. Added a PassOwnPtr<Pasteboard> argument to the
constructor and an OwnPtr<Pasteboard> data member.

* platform/Pasteboard.h: Added a create function to make it easy
to create a pasteboard given a pasteboard name.

* platform/mac/ClipboardMac.mm:
(WebCore::ClipboardMac::ClipboardMac): Create a pasteboard and pass
it to the Clipboard constructor.

* platform/mac/PasteboardMac.mm:
(WebCore::Pasteboard::create): Added.

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

6 years agoUnload event listeners should prevent Safari from insta-killing the web process on...
akling@apple.com [Sun, 12 May 2013 23:16:30 +0000 (23:16 +0000)]
Unload event listeners should prevent Safari from insta-killing the web process on last tab close.
<http://webkit.org/b/115988>
<rdar://problem/13870943>

Reviewed by Anders Carlsson.

Source/WebCore:

Add two methods to Chrome (and ChromeClient):

    - enableSuddenTermination()
    - disableSuddenTermination()

..and call these from DOMWindow instead of the free global functions.

For WebKit1, it just calls the NSProcessInfo methods to keep behavior the same.
For WebKit2, the new methods plumb through the information to the UI process.

Also updated the DOMWindow logic to think in terms of per-DOMWindow sudden termination counters
instead of a process-global one, since that gets confusing in a WK2 world.
When a DOMWindow transitions between having/not having unload/beforeunload event listeners,
we send a notification to the Chrome.

* WebCore.exp.in:
* WebCore.xcodeproj/project.pbxproj:
* page/Chrome.h:
(WebCore::Chrome::enableSuddenTermination):
(WebCore::Chrome::disableSuddenTermination):
* page/ChromeClient.h:
(WebCore::ChromeClient::enableSuddenTermination):
(WebCore::ChromeClient::disableSuddenTermination):
* page/DOMWindow.cpp:
(WebCore::addUnloadEventListener):
(WebCore::removeUnloadEventListener):
(WebCore::removeAllUnloadEventListeners):
(WebCore::addBeforeUnloadEventListener):
(WebCore::removeBeforeUnloadEventListener):
(WebCore::removeAllBeforeUnloadEventListeners):
(WebCore::DOMWindow::dispatchAllPendingBeforeUnloadEvents):
(WebCore::DOMWindow::dispatchAllPendingUnloadEvents):
(WebCore::DOMWindow::enableSuddenTermination):
(WebCore::DOMWindow::disableSuddenTermination):
* page/DOMWindow.h:
(DOMWindow):

Source/WebKit/mac:

* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::enableSuddenTermination):
(WebChromeClient::disableSuddenTermination):

Source/WebKit2:

Let WebCore control the UI process's suppression of the sudden termination mechanism.
This is implemented by having WebChromeClient push Enable/DisableSuddenTermination messages
over to the UI process where the appropriate NSProcessInfo calls are made.

We also use this information when deciding whether to insta-kill a web process when its last
page is closed. This mechanism is re-usable in WebCore to protect against sudden termination
by the UI process.

* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::WebProcessProxy):
(WebKit::WebProcessProxy::removeWebPage):
(WebKit::WebProcessProxy::enableSuddenTermination):
(WebKit::WebProcessProxy::disableSuddenTermination):
* UIProcess/WebProcessProxy.h:
(WebProcessProxy):
* UIProcess/WebProcessProxy.messages.in:
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::enableSuddenTermination):
(WebKit::WebChromeClient::disableSuddenTermination):
* WebProcess/WebCoreSupport/WebChromeClient.h:
(WebChromeClient):

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

6 years agoRemove Complex.h from WTF
andersca@apple.com [Sun, 12 May 2013 21:27:43 +0000 (21:27 +0000)]
Remove Complex.h from WTF
https://bugs.webkit.org/show_bug.cgi?id=115989

Reviewed by Beth Dakin.

Source/WebCore:

Replace Complex declarations with std::complex<double>. Pass by value since the struct
is small enough to go into two registers on X86-64.

* Modules/webaudio/RealtimeAnalyser.cpp:
(WebCore::RealtimeAnalyser::doFFTAnalysis):
(WebCore::RealtimeAnalyser::getFloatFrequencyData):
(WebCore::RealtimeAnalyser::getByteFrequencyData):
(WebCore::RealtimeAnalyser::getByteTimeDomainData):
* platform/audio/Biquad.cpp:
(WebCore::Biquad::setZeroPolePairs):
(WebCore::Biquad::setAllpassPole):
(WebCore::Biquad::getFrequencyResponse):
* platform/audio/Biquad.h:
* platform/audio/FFTFrame.cpp:
(WebCore::FFTFrame::interpolateFrequencyComponents):
(WebCore::FFTFrame::extractAverageGroupDelay):
(WebCore::FFTFrame::addConstantGroupDelay):

Source/WTF:

Complex.h contains a typedef and a single function (that already has an equivalent in the STL).
The header is used by three files in WebCore, so just use std::complex<double> and std::polar directly.

* GNUmakefile.list.am:
* WTF.vcproj/WTF.vcproj:
* WTF.vcxproj/WTF.vcxproj:
* WTF.vcxproj/WTF.vcxproj.filters:
* WTF.xcodeproj/project.pbxproj:
* wtf/CMakeLists.txt:
* wtf/Complex.h: Removed.

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

6 years agoDropdowns on http://www.exploratorium.edu don't show anything
simon.fraser@apple.com [Sun, 12 May 2013 18:46:37 +0000 (18:46 +0000)]
Dropdowns on exploratorium.edu don't show anything
https://bugs.webkit.org/show_bug.cgi?id=115991

Source/WebCore:

Reviewed by Dan Bernstein.

We can't optimize away the backing store of a layer by saying that
it paints into a composited ancestor if its composited bounds are not contained
by that ancestor.

Test: compositing/backing/no-backing-for-clip-overhang.html

* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::updateGraphicsLayerGeometry): Pass in our
previously computed composited bounds relative to our composited ancestor,
and its composited bounds.
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::requiresOwnBackingStore): If the ancestor's
composited bounds don't contain the layer's composited bounds, the layer
needs its own backing store.
* rendering/RenderLayerCompositor.h:

LayoutTests:

Reviewed by Dan Bernstein.

Layer tree dump test with an overflow:hidden that projects outside its
ancestor, and is forced to composite by a composited child.

* compositing/backing/no-backing-for-clip-overhang-expected.txt: Added.
* compositing/backing/no-backing-for-clip-overhang.html: Added.

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

6 years ago[GTK] Add a basic cmake build for WTF and JavaScriptCore
mrobinson@webkit.org [Sun, 12 May 2013 18:22:11 +0000 (18:22 +0000)]
[GTK] Add a basic cmake build for WTF and JavaScriptCore
https://bugs.webkit.org/show_bug.cgi?id=115967

Reviewed by Laszlo Gombos.

.:

* CMakeLists.txt: Add GTK+ to the list of ports.
* Source/CMakeLists.txt: We do not try to build WebCoreTestSupport when WebCore is disabled.
* Source/cmake/FindGAIL3.cmake: Added.
* Source/cmake/FindGDK3.cmake: Added.
* Source/cmake/FindGStreamer.cmake: Use the passed in minimum version.
* Source/cmake/FindGTK3.cmake: Added.
* Source/cmake/FindXt.cmake: Added.
* Source/cmake/OptionsEfl.cmake: Pass in the minimum version.
* Source/cmake/OptionsGTK.cmake: Added.

Source/JavaScriptCore:

* PlatformGTK.cmake: Added.
* shell/PlatformGTK.cmake: Added.

Source/WTF:

* wtf/PlatformGTK.cmake: Added.

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

6 years agoUnreviewed, rolling out r149955.
commit-queue@webkit.org [Sun, 12 May 2013 18:12:29 +0000 (18:12 +0000)]
Unreviewed, rolling out r149955.
http://trac.webkit.org/changeset/149955
https://bugs.webkit.org/show_bug.cgi?id=115990

Broke lots of tests (Requested by smfr on #webkit).

Source/WebCore:

* WebCore.exp.in:
* rendering/InlineFlowBox.h:
* rendering/InlineTextBox.h:
(InlineTextBox):
* rendering/RenderApplet.h:
* rendering/RenderBR.h:
* rendering/RenderBlock.h:
(RenderBlock):
(WebCore::RenderBlock::virtualContinuation):
(WebCore::RenderBlock::virtualChildren):
(WebCore::RenderBlock::isRenderBlock):
(WebCore::RenderBlock::isBlockFlow):
(WebCore::RenderBlock::isInlineBlockOrInlineTable):
(WebCore::RenderBlock::dirtyLinesFromChangedChild):
(WebCore::RenderBlock::collapsedMarginBefore):
(WebCore::RenderBlock::collapsedMarginAfter):
* rendering/RenderBox.h:
(WebCore::RenderBox::borderBoundingBox):
(RenderBox):
(WebCore::RenderBox::marginLogicalLeft):
(WebCore::RenderBox::marginLogicalRight):
* rendering/RenderBoxModelObject.h:
(WebCore::RenderBoxModelObject::isBoxModelObject):
* rendering/RenderButton.h:
* rendering/RenderCombineText.h:
* rendering/RenderCounter.h:
* rendering/RenderDeprecatedFlexibleBox.h:
* rendering/RenderDetailsMarker.h:
* rendering/RenderEmbeddedObject.h:
(RenderEmbeddedObject):
(WebCore::RenderEmbeddedObject::isEmbeddedObject):
(WebCore::RenderEmbeddedObject::virtualChildren):
* rendering/RenderFieldset.h:
* rendering/RenderFileUploadControl.h:
* rendering/RenderFlexibleBox.h:
* rendering/RenderFlowThread.h:
* rendering/RenderFrame.h:
* rendering/RenderFrameSet.h:
* rendering/RenderFullScreen.cpp:
* rendering/RenderFullScreen.h:
* rendering/RenderGrid.h:
* rendering/RenderHTMLCanvas.h:
* rendering/RenderIFrame.h:
* rendering/RenderImage.h:
(RenderImage):
(WebCore::RenderImage::isRenderImage):
* rendering/RenderInline.h:
(RenderInline):
(WebCore::RenderInline::virtualContinuation):
(WebCore::RenderInline::virtualChildren):
(WebCore::RenderInline::isRenderInline):
(WebCore::RenderInline::layout):
(WebCore::RenderInline::requiresLayer):
(WebCore::RenderInline::offsetWidth):
(WebCore::RenderInline::offsetHeight):
(WebCore::RenderInline::borderBoundingBox):
(WebCore::RenderInline::dirtyLinesFromChangedChild):
* rendering/RenderLayerModelObject.h:
* rendering/RenderListBox.h:
* rendering/RenderListItem.h:
* rendering/RenderListMarker.h:
* rendering/RenderMedia.h:
(WebCore::RenderMedia::virtualChildren):
(WebCore::RenderMedia::canHaveChildren):
(WebCore::RenderMedia::isMedia):
(WebCore::RenderMedia::isImage):
(WebCore::RenderMedia::requiresForcedStyleRecalcPropagation):
* rendering/RenderMediaControlElements.h:
* rendering/RenderMenuList.h:
* rendering/RenderMeter.h:
* rendering/RenderMultiColumnBlock.h:
* rendering/RenderMultiColumnFlowThread.h:
* rendering/RenderMultiColumnSet.h:
* rendering/RenderNamedFlowThread.h:
* rendering/RenderPart.h:
(RenderPart):
(WebCore::RenderPart::isRenderPart):
(WebCore::RenderPart::renderName):
* rendering/RenderProgress.h:
* rendering/RenderRegion.h:
(WebCore::RenderRegion::isRenderRegion):
* rendering/RenderRegionSet.h:
* rendering/RenderReplaced.h:
(RenderReplaced):
(WebCore::RenderReplaced::renderName):
* rendering/RenderReplica.h:
* rendering/RenderRuby.h:
* rendering/RenderRubyBase.h:
* rendering/RenderRubyRun.h:
* rendering/RenderRubyText.h:
* rendering/RenderScrollbarPart.h:
* rendering/RenderSearchField.h:
* rendering/RenderSlider.h:
* rendering/RenderSnapshottedPlugIn.h:
(RenderSnapshottedPlugIn):
* rendering/RenderTable.h:
(RenderTable):
(WebCore::RenderTable::renderName):
(WebCore::RenderTable::isTable):
(WebCore::RenderTable::avoidsFloats):
* rendering/RenderTableCaption.h:
* rendering/RenderTableCell.h:
* rendering/RenderTableCol.h:
* rendering/RenderTableRow.h:
* rendering/RenderTableSection.h:
* rendering/RenderText.h:
(RenderText):
(WebCore::RenderText::marginLeft):
(WebCore::RenderText::marginRight):
(WebCore::RenderText::styleWillChange):
(WebCore::RenderText::length):
(WebCore::RenderText::paint):
(WebCore::RenderText::layout):
* rendering/RenderTextControl.h:
(RenderTextControl):
(WebCore::RenderTextControl::renderName):
(WebCore::RenderTextControl::isTextControl):
(WebCore::RenderTextControl::avoidsFloats):
* rendering/RenderTextControlMultiLine.h:
* rendering/RenderTextControlSingleLine.h:
(RenderTextControlSingleLine):
(WebCore::RenderTextControlSingleLine::isTextField):
* rendering/RenderTextFragment.h:
* rendering/RenderTextTrackCue.h:
* rendering/RenderVideo.h:
* rendering/RenderView.h:
* rendering/RenderWidget.h:
(RenderWidget):
(WebCore::RenderWidget::isWidget):
* rendering/RenderWordBreak.h:
* rendering/RootInlineBox.h:
(RootInlineBox):
* rendering/mathml/RenderMathMLBlock.h:
* rendering/svg/RenderSVGBlock.h:
(RenderSVGBlock):
* rendering/svg/RenderSVGContainer.h:
(WebCore::RenderSVGContainer::setNeedsBoundariesUpdate):
(WebCore::RenderSVGContainer::virtualChildren):
(WebCore::RenderSVGContainer::isSVGContainer):
(WebCore::RenderSVGContainer::renderName):
(RenderSVGContainer):
(WebCore::RenderSVGContainer::objectBoundingBox):
(WebCore::RenderSVGContainer::strokeBoundingBox):
(WebCore::RenderSVGContainer::repaintRectInLocalCoordinates):
* rendering/svg/RenderSVGEllipse.h:
* rendering/svg/RenderSVGForeignObject.h:
* rendering/svg/RenderSVGGradientStop.h:
* rendering/svg/RenderSVGHiddenContainer.h:
(WebCore::RenderSVGHiddenContainer::renderName):
(RenderSVGHiddenContainer):
(WebCore::RenderSVGHiddenContainer::isSVGHiddenContainer):
* rendering/svg/RenderSVGImage.h:
* rendering/svg/RenderSVGInline.h:
(WebCore::RenderSVGInline::renderName):
(WebCore::RenderSVGInline::requiresLayer):
(WebCore::RenderSVGInline::isSVGInline):
(RenderSVGInline):
* rendering/svg/RenderSVGInlineText.h:
* rendering/svg/RenderSVGModelObject.h:
(WebCore::RenderSVGModelObject::requiresLayer):
(RenderSVGModelObject):
* rendering/svg/RenderSVGPath.h:
* rendering/svg/RenderSVGRect.h:
* rendering/svg/RenderSVGResourceClipper.h:
* rendering/svg/RenderSVGResourceContainer.h:
(RenderSVGResourceContainer):
(WebCore::RenderSVGResourceContainer::isSVGResourceContainer):
(WebCore::RenderSVGResourceContainer::toRenderSVGResourceContainer):
* rendering/svg/RenderSVGResourceFilter.h:
* rendering/svg/RenderSVGResourceFilterPrimitive.h:
* rendering/svg/RenderSVGResourceGradient.h:
(RenderSVGResourceGradient):
(WebCore::RenderSVGResourceGradient::resourceBoundingBox):
* rendering/svg/RenderSVGResourceLinearGradient.h:
* rendering/svg/RenderSVGResourceMarker.h:
* rendering/svg/RenderSVGResourceMasker.h:
* rendering/svg/RenderSVGResourcePattern.h:
* rendering/svg/RenderSVGResourceRadialGradient.h:
* rendering/svg/RenderSVGRoot.h:
* rendering/svg/RenderSVGShape.h:
(WebCore::RenderSVGShape::setNeedsBoundariesUpdate):
(WebCore::RenderSVGShape::setNeedsTransformUpdate):
(WebCore::RenderSVGShape::repaintRectInLocalCoordinates):
(WebCore::RenderSVGShape::localToParentTransform):
(WebCore::RenderSVGShape::localTransform):
(WebCore::RenderSVGShape::isSVGShape):
(RenderSVGShape):
(WebCore::RenderSVGShape::objectBoundingBox):
(WebCore::RenderSVGShape::strokeBoundingBox):
* rendering/svg/RenderSVGTSpan.h:
* rendering/svg/RenderSVGText.h:
* rendering/svg/RenderSVGTextPath.h:
* rendering/svg/RenderSVGTransformableContainer.h:
* rendering/svg/RenderSVGViewportContainer.h:

Tools:

* Scripts/webkitpy/port/mac.py:

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

6 years agoMove defines to platform
mrobinson@webkit.org [Sun, 12 May 2013 17:58:47 +0000 (17:58 +0000)]
Move defines to platform

[GTK] Move defines that will never be configured to Platform.h
https://bugs.webkit.org/show_bug.cgi?id=115965

Reviewed by Andreas Kling.

.:

* Source/autotools/SetupAutoconfHeader.m4: Move some unchanging defines to Platform.h.

Source/WTF:

* wtf/Platform.h: Add new defines that were previously in the autoconf header.

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

6 years agoSimplify AutodrainedPool
andersca@apple.com [Sun, 12 May 2013 17:50:58 +0000 (17:50 +0000)]
Simplify AutodrainedPool
https://bugs.webkit.org/show_bug.cgi?id=115986

Reviewed by Andreas Kling.

Source/WebCore:

Remove calls to AutodrainedPool::cycle as well as the iteration counter passed to the constructor.
Instead, just declare RAII pools where it seems necessary.

* Modules/webdatabase/DatabaseThread.cpp:
(WebCore::DatabaseThread::databaseThread):
* fileapi/FileThread.cpp:
(WebCore::FileThread::runLoop):
* loader/icon/IconDatabase.cpp:
(WebCore::IconDatabase::setIconDataForIconURL):
(WebCore::IconDatabase::performURLImport):
(WebCore::IconDatabase::readFromDatabase):

Source/WTF:

Remove the ability to cycle an AutodrainedPool, as well as the iteration count.
Creating and draining pools is fast enough now that we don't need to try to be clever about it.

* wtf/AutodrainedPool.h:
(AutodrainedPool):
(WTF::AutodrainedPool::AutodrainedPool):
* wtf/AutodrainedPoolMac.mm:
(WTF::AutodrainedPool::AutodrainedPool):

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

6 years ago <rdar://problem/13402976> Sandbox violations in com.nvidia.OpenGL on Lion.
ap@apple.com [Sun, 12 May 2013 17:47:29 +0000 (17:47 +0000)]
    <rdar://problem/13402976> Sandbox violations in com.nvidia.OpenGL on Lion.

        Reviewed by Dan Bernstein.

        * WebProcess/com.apple.WebProcess.sb.in: Silence the violations (on Lion only).

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

6 years agoMove RemoteMemoryReader into FastMalloc.cpp
andersca@apple.com [Sun, 12 May 2013 16:45:26 +0000 (16:45 +0000)]
Move RemoteMemoryReader into FastMalloc.cpp
https://bugs.webkit.org/show_bug.cgi?id=115985

Reviewed by Andreas Kling.

RemoteMemoryReader is only used in FastMalloc.cpp, and even had one of its member functions
implemented there, so move the entire class template there and remove MallocZoneSupport.h.

* GNUmakefile.list.am:
* WTF.pro:
* WTF.vcproj/WTF.vcproj:
* WTF.vcxproj/WTF.vcxproj:
* WTF.vcxproj/WTF.vcxproj.filters:
* WTF.xcodeproj/project.pbxproj:
* wtf/CMakeLists.txt:
* wtf/FastMalloc.cpp:
(WTF):
(PageHeapAllocator):
(WTF::TCMalloc_ThreadCache::CreateCacheIfNecessary):
* wtf/MallocZoneSupport.h: Removed.

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

6 years agoApply FINAL to the Node hierarchy.
akling@apple.com [Sun, 12 May 2013 15:12:51 +0000 (15:12 +0000)]
Apply FINAL to the Node hierarchy.
<http://webkit.org/b/115984>

Mostly from Blink r149454 by <cevans@chromium.org>
<http://src.chromium.org/viewvc/blink?view=revision&revision=149454>

A couple of the stable DOM/ microbenchmarks are perf positive on Linux clang:

    - CloneNodes time reduced from 162.4 to 156.5 ms.
    - CreateNodes time reduced from 113.9 to 104.9 ms.

* dom/: Beat things with the FINAL stick.
* html/: Ditto.
* svg/: Ditto.

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

6 years agoDevirtualize some things on Document.
akling@apple.com [Sun, 12 May 2013 14:23:09 +0000 (14:23 +0000)]
Devirtualize some things on Document.

From Blink r149967 by <esprehn@chromium.org>
<http://src.chromium.org/viewvc/blink?view=revision&revision=149967>

Several methods on Document are virtual but don't override a super class method
and don't need to be virtual. This patch devirtualizes:

    - createElementNS()
    - finishedParsing()
    - suspendScriptedAnimationControllerCallbacks()
    - resumeScriptedAnimationControllerCallbacks()

It also removes the suspend and resume callbacks from ScriptExecutionContext
since they didn't need to be there.

* dom/Document.h:
* dom/ScriptExecutionContext.h:

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

6 years agoRemove redundant call to removeAllEventListeners() in Document::open().
akling@apple.com [Sun, 12 May 2013 14:05:37 +0000 (14:05 +0000)]
Remove redundant call to removeAllEventListeners() in Document::open().

From Blink r150175 by <dcheng@chromium.org>
<http://src.chromium.org/viewvc/blink?view=revision&revision=150175>

Document::open() already calls Document::removeAllEventListeners(), which
removes the event listeners from the DOMWindow it's attached to, so
there's no need to do it manually here as well.

* dom/Document.cpp:
(WebCore::Document::open):

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

6 years agoRebaseline fast/js/global-constructors-attributes.html for mac-lion after r149920.
akling@apple.com [Sun, 12 May 2013 13:57:27 +0000 (13:57 +0000)]
Rebaseline fast/js/global-constructors-attributes.html for mac-lion after r149920.

* platform/mac-lion/fast/js/global-constructors-attributes-expected.txt:

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

6 years agoApply FINAL to the RenderObject hierarchy.
akling@apple.com [Sun, 12 May 2013 13:38:33 +0000 (13:38 +0000)]
Apply FINAL to the RenderObject hierarchy.
<http://webkit.org/b/115977>

Mostly from Blink r148795 by <cevans@chromium.org>
<http://src.chromium.org/viewvc/blink?view=revision&revision=148795>

* rendering/: Beat things with the FINAL stick.
* WebCore.exp.in: Export a now-needed symbol.

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

6 years ago[GTK] Remove unnecessary GTK_CHECK_VERSION #ifdefs
carlosgc@webkit.org [Sun, 12 May 2013 09:05:54 +0000 (09:05 +0000)]
[GTK] Remove unnecessary GTK_CHECK_VERSION #ifdefs
https://bugs.webkit.org/show_bug.cgi?id=115914

Reviewed by Martin Robinson.

Source/WebCore:

* platform/graphics/gtk/FullscreenVideoControllerGtk.cpp:
(WebCore::FullscreenVideoControllerGtk::hideHud):
(WebCore::FullscreenVideoControllerGtk::initializeWindow):
* platform/gtk/GtkVersioning.c:
* platform/gtk/GtkVersioning.h:
* platform/gtk/WidgetRenderingContext.cpp:
(WebCore::WidgetRenderingContext::WidgetRenderingContext):
* plugins/gtk/gtk2xtbin.c:
(gtk_xtbin_realize):

Source/WebKit/gtk:

* WebCoreSupport/ChromeClientGtk.cpp:
(WebKit::ChromeClient::contentsSizeChanged):
* WebCoreSupport/FrameLoaderClientGtk.cpp:
(WebKit::FrameLoaderClient::transitionToCommittedForNewPage):
* tests/testapplicationcache.c:
* tests/testatk.c:
* tests/testatkroles.c:
(main):
* tests/testcontextmenu.c:
* tests/testcopyandpaste.c:
(main):
* tests/testdomdocument.c:
* tests/testdomdomwindow.c:
* tests/testdomnode.c:
* tests/testdownload.c:
(main):
* tests/testfavicondatabase.c:
(main):
* tests/testglobals.c:
* tests/testhittestresult.c:
* tests/testhttpbackend.c:
(main):
* tests/testkeyevents.c:
(main):
* tests/testloading.c:
* tests/testmimehandling.c:
(main):
* tests/testnetworkrequest.c:
(main):
* tests/testnetworkresponse.c:
(main):
* tests/testwebbackforwardlist.c:
(main):
* tests/testwebdatasource.c:
(main):
* tests/testwebframe.c:
(main):
* tests/testwebhistoryitem.c:
(main):
* tests/testwebinspector.c:
(main):
* tests/testwebplugindatabase.c:
(main):
* tests/testwebresource.c:
(main):
* tests/testwebsettings.c:
(main):
* tests/testwebview.c:
* tests/testwindow.c:
(main):
* webkit/webkitwebview.cpp:
(webkit_web_view_realize):
(webkit_web_view_show_help):
(webkit_web_view_class_init):
(webkit_web_view_set_tooltip_text):

Source/WebKit2:

* UIProcess/API/gtk/WebKitWebViewBase.cpp:
(webkitWebViewBaseRealize):

Tools:

* GtkLauncher/main.c:
(createToolbar):
* MiniBrowser/gtk/BrowserWindow.c:
(_BrowserWindow):
(browserWindowSetStatusText):
(fullScreenMessageTimeoutCallback):
(webViewEnterFullScreen):
(webViewLeaveFullScreen):
(browserWindowFinalize):
(browserWindowConstructed):
* WebKitTestRunner/gtk/EventSenderProxyGtk.cpp:
(WTR::EventSenderProxy::mouseScrollBy):
(WTR::EventSenderProxy::continuousMouseScrollBy):

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

6 years ago[Windows] Unreviewed build fix after r149932
bfulgham@apple.com [Sun, 12 May 2013 06:15:52 +0000 (06:15 +0000)]
[Windows] Unreviewed build fix after r149932

Patch by Brent Fulgham <bfulgham@apple.com> on 2013-05-11

* make-export-file-generator: Don't attempt to import
(or use) non-existent cxxabi functions on Windows.

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

6 years agoAdd more info to compositing log channel output
simon.fraser@apple.com [Sun, 12 May 2013 05:39:14 +0000 (05:39 +0000)]
Add more info to compositing log channel output
https://bugs.webkit.org/show_bug.cgi?id=115978

Reviewed by Dean Jackson.

Add to compositing log channel output whether a layer paints
into its compositing ancestor.

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

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

6 years agoREGRESSION: Fixed background on ColterReed.com scrolls
simon.fraser@apple.com [Sun, 12 May 2013 04:54:04 +0000 (04:54 +0000)]
REGRESSION: Fixed background on ColterReed.com scrolls
https://bugs.webkit.org/show_bug.cgi?id=115951

Source/WebCore:

Reviewed by Beth Dakin.

The logic for painting the fixed root background into its own layer was
broken when the document element's layer was composited. This could be caused
by a negative z-index child of the body, or by an explicit compositing-causing
style on the <html>.

There were two issues. First, when painting the layer for the fixed root
background, we would simply short-circuit the fixed background paint in
RenderLayer::paintLayer(), when checking for a composited layer. We have
to continue to paint through the composited <html> layer to get the root
background in this case.

Secondly, RenderLayerBacking::paintIntoLayer() would only set the PaintLayerPaintingSkipRootBackground
flag if this RenderLayerBacking had a m_backgroundLayer. However, when the <html> is
composited, we need to skip painting the root layer for both the RenderView's backing,
and for the <html>'s backing. Checking whether there is *any* layer that paints
the fixed root background (i.e. checking compositor()->fixedRootBackgroundLayer())
is a simple way to fix this test.

Tests: platform/mac-wk2/tiled-drawing/fixed-background/fixed-background-composited-html.html
       platform/mac-wk2/tiled-drawing/fixed-background/fixed-background-negative-z-index-fixed.html

* rendering/RenderLayer.cpp:
(WebCore::paintForFixedRootBackground):
(WebCore::RenderLayer::paintLayer):
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::paintIntoLayer):

LayoutTests:

Reviewed by Beth Dakin.

Tests with a fixed background and two different ways of making the <html> composited.

* platform/mac-wk2/tiled-drawing/fixed-background/fixed-background-composited-html-expected.html: Added.
* platform/mac-wk2/tiled-drawing/fixed-background/fixed-background-composited-html.html: Added.
* platform/mac-wk2/tiled-drawing/fixed-background/fixed-background-negative-z-index-fixed-expected.html: Added.
* platform/mac-wk2/tiled-drawing/fixed-background/fixed-background-negative-z-index-fixed.html: Added.

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

6 years agoPossible crash when going Back while loading PDF
simon.fraser@apple.com [Sun, 12 May 2013 04:28:15 +0000 (04:28 +0000)]
Possible crash when going Back while loading PDF
https://bugs.webkit.org/show_bug.cgi?id=115972

Reviewed by Dan Bernstein.

It's possible for m_frame to be null when Document::findUnsafeParentScrollPropagationBoundary()
is called, so null-check currentFrame.

* dom/Document.cpp:
(WebCore::Document::findUnsafeParentScrollPropagationBoundary):

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

6 years ago <rdar://problem/13823864> TextCodecICU complains about ambiguous codec names...
ap@apple.com [Sun, 12 May 2013 00:53:25 +0000 (00:53 +0000)]
    <rdar://problem/13823864> TextCodecICU complains about ambiguous codec names with current ICU release
        https://bugs.webkit.org/show_bug.cgi?id=115953

        Reviewed by Darin Adler.

        Store and use canonical converter name to create converters.

        As a side effect, we now actually reuse cached converters - previously we would compare
        a standard encoding name to internal canonical one, which rarely match.

        * platform/text/TextCodecICU.h:
        * platform/text/TextCodecICU.cpp:
        (WebCore::TextCodecICU::create): Pass canonical ICU converter name to constructor.
        (WebCore::TextCodecICU::registerEncodingNames):
            - Updated terminology.
            - Added a comment that special cases should be kept in sync between registerEncodingNames
            and registerCodecs.
            - Moved maccyrillic alias to a correct section. It's not present in ICU even today.
            - Changed a few aliases to actually map to standard name, not to an overridden one
            (this doesn't change behavior since addToTextEncodingNameMap looks up canonical
            name, but is clearer).
        (WebCore::TextCodecICU::registerCodecs): Store a converter name to use with each
        canonical encoding name.
        (WebCore::TextCodecICU::TextCodecICU): Ditto.
        (WebCore::TextCodecICU::releaseICUConverter): Reset the converter to remove any
        leftover data.
        (WebCore::TextCodecICU::createICUConverter):
            - Compare converter name to converter name, not to another alias name.
            - Use proper string comparison instead of pointer comparison.
            - When creating a converter, assert that the name is not ambigous - canonical
            converter names should never be, otherwise there would be no way to create
            the converter without ambiguity.

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

6 years agoUnreviewed build fix after r149944.
rakuco@webkit.org [Sat, 11 May 2013 23:42:36 +0000 (23:42 +0000)]
Unreviewed build fix after r149944.

* Platform/CoreIPC/ArgumentEncoder.cpp: Include <sys/mman.h> for mmap(2).

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

6 years agoDon't pass malloced pointers as out-of-line data when sending Mach messages
andersca@apple.com [Sat, 11 May 2013 23:28:26 +0000 (23:28 +0000)]
Don't pass malloced pointers as out-of-line data when sending Mach messages
https://bugs.webkit.org/show_bug.cgi?id=115970
<rdar://problem/13144680>

Reviewed by Sam Weinig.

Give ArgumentEncoder an inline buffer of 512 bytes. If we need more than that, use mmap to allocate data
since that gives us fresh zero-filled memory that we can safely share.

* Platform/CoreIPC/ArgumentEncoder.cpp:
(CoreIPC::ArgumentEncoder::ArgumentEncoder):
Set up the buffer pointers to point to the inline buffer.

(CoreIPC::ArgumentEncoder::~ArgumentEncoder):
Unmap the buffer if necessary.

(CoreIPC::ArgumentEncoder::grow):
Grow the allocation exponentially, rounded up to the nearest page. This is a simplification from the
current strategy, but most messages are either tiny in which case they will fit inside the inline buffer,
or big in which case we'll end up doing less allocations + memory copying.

* Platform/CoreIPC/ArgumentEncoder.h:
(ArgumentEncoder):

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

6 years ago[Mac] The captions menu should not use a canned max-width and max-height
graouts@apple.com [Sat, 11 May 2013 21:42:44 +0000 (21:42 +0000)]
[Mac] The captions menu should not use a canned max-width and max-height
https://bugs.webkit.org/show_bug.cgi?id=115968

Reviewed by Eric Carlson.

Use more real estate to display the captions menu should the caption names
be long.

* css/mediaControlsQuickTime.css:
(video::-webkit-media-controls-closed-captions-container):
(video::-webkit-media-controls-closed-captions-track-list):
Make the captions menu scale to a max-width and max-height to allow 4px
above and below the menu, except on the right where it always aligns with
the captions icon in the media controller.
* html/shadow/MediaControlsApple.cpp:
(WebCore::MediaControlsApple::createControls):
Move the captions menu element to be a child of the controls instead of
the panel such that it may scale relative to the controls when using %
CSS values.

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

6 years agoUnreviewed GTK build fix after r149904.
zandobersek@gmail.com [Sat, 11 May 2013 20:57:29 +0000 (20:57 +0000)]
Unreviewed GTK build fix after r149904.

* GNUmakefile.list.am: Adding missing build targets.

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

6 years agoBogus -webkit-columns value in fast/text/international/spaces-combined-in-vertical...
commit-queue@webkit.org [Sat, 11 May 2013 20:08:29 +0000 (20:08 +0000)]
Bogus -webkit-columns value in fast/text/international/spaces-combined-in-vertical-text.html
https://bugs.webkit.org/show_bug.cgi?id=115164

Patch by Xan Lopez <xlopez@igalia.com> on 2013-05-11
Reviewed by Rob Buis.

Remove bogus -webkit-columns property.

* fast/text/international/spaces-combined-in-vertical-text.html:

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

6 years agoUnreviewed, Fix WK2 EFL build after r149904.
ch.dumez@sisa.samsung.com [Sat, 11 May 2013 20:07:22 +0000 (20:07 +0000)]
Unreviewed, Fix WK2 EFL build after r149904.

Add new PluginInformation.cpp file to CMake.

* CMakeLists.txt:

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

6 years agoUnreviewed, fix WK2 EFL build after r149904.
ch.dumez@sisa.samsung.com [Sat, 11 May 2013 19:47:25 +0000 (19:47 +0000)]
Unreviewed, fix WK2 EFL build after r149904.

Add new WKPluginInformation.cpp file to CMake.

* CMakeLists.txt:

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