WebKit-https.git
9 years agoAdd a crashing test expectation for the test added by r138755 on Mac.
rniwa@webkit.org [Fri, 4 Jan 2013 03:20:30 +0000 (03:20 +0000)]
Add a crashing test expectation for the test added by r138755 on Mac.
The test failure is tracked by the bug 138755.

* platform/mac/TestExpectations:

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

9 years agoUnreviewed. Gardening Apple Windows port.
roger_fong@apple.com [Fri, 4 Jan 2013 02:11:19 +0000 (02:11 +0000)]
Unreviewed. Gardening Apple Windows port.

* platform/win/fast/css/image-set-value-not-removed-crash-expected.txt: Added.

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

9 years agoincorrect flexbox relayout with overflow, padding and absolute positioning
tony@chromium.org [Fri, 4 Jan 2013 01:21:07 +0000 (01:21 +0000)]
incorrect flexbox relayout with overflow, padding and absolute positioning
https://bugs.webkit.org/show_bug.cgi?id=106022

Reviewed by Ojan Vafai.

Source/WebCore:

The problem was we were entering simplified layout, which doesn't apply the stretch
behavior for flex children. That should be fine if we had kept the override size from
the previous layout. So clear the override size during layout rather than after layout.

Not clearing the override size re-triggers bug 98611. Fix this by always forcing a
layout of an image if it has an override size set. The presence of an override size means
we did some special layout that may not be covered by re-computing the logical width and
height.

Test: css3/flexbox/stretch-simplified-layout.html

* rendering/RenderFlexibleBox.cpp:
(WebCore::RenderFlexibleBox::layoutBlock): Don't clear the override size after layout.
(WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes): Clear the override size right before layout.
* rendering/RenderFlexibleBox.h:
(RenderFlexibleBox): Remove clearChildOverrideSizes() since it's not called anymore.
* rendering/RenderImage.cpp:
(WebCore::RenderImage::imageDimensionsChanged): If an override size is present, force a relayout.
Also cleaned up the code a bit to avoid computing the width and height unless we need to.

LayoutTests:

* css3/flexbox/stretch-simplified-layout-expected.txt: Added.
* css3/flexbox/stretch-simplified-layout.html: Added.

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

9 years agoUnreviewed rebaseline of binding tests after r138754
adamk@chromium.org [Fri, 4 Jan 2013 01:18:03 +0000 (01:18 +0000)]
Unreviewed rebaseline of binding tests after r138754

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateCallbackHeader): Remove unnecessary whitespace
* bindings/scripts/test/JS/JSTestCallback.h:
(WebCore::JSTestCallback::scriptExecutionContext):
(JSTestCallback):
* bindings/scripts/test/V8/V8TestCallback.h:
(WebCore::V8TestCallback::scriptExecutionContext):
(V8TestCallback):

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

9 years agoAvoid mixed content when expanding context in code review tool
commit-queue@webkit.org [Fri, 4 Jan 2013 01:06:19 +0000 (01:06 +0000)]
Avoid mixed content when expanding context in code review tool
https://bugs.webkit.org/show_bug.cgi?id=106060

Patch by James Robinson <jamesr@chromium.org> on 2013-01-03
Reviewed by Tony Chang.

Example failure: "The page at https://bugs.webkit.org/attachment.cgi?id=181222&action=review displayed insecure
content from http://svn.webkit.org/repository/webkit/trunk/Source/WebCore/page/EventHandler.cpp?p=138617." This
loads from "//svn.webkit.org/..." so the protocol matches.

* code-review.js:

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

9 years agoUnreviewed gardening. Marking fast/events/5056619.html as flaky
tdanderson@chromium.org [Fri, 4 Jan 2013 00:46:57 +0000 (00:46 +0000)]
Unreviewed gardening. Marking fast/events/5056619.html as flaky
on XP and Win7.

* platform/chromium/TestExpectations:

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

9 years agoonload callback for <track> element attached to <video> does not fire
rniwa@webkit.org [Fri, 4 Jan 2013 00:33:32 +0000 (00:33 +0000)]
onload callback for <track> element attached to <video> does not fire
https://bugs.webkit.org/show_bug.cgi?id=103258

Patch by Antoine Quint <graouts@apple.com> on 2013-01-03
Reviewed by Eric Carlson.

Source/WebCore:

We now correctly implement the track processing model per the latest spec at
http://www.whatwg.org/specs/web-apps/current-work/multipage/the-video-element.html#start-the-track-processing-model.

For a <track> to load, three conditions must be met:

1. it must have a non-empty src
2. it must have a mode other than "disabled" (the default)
3. it must have a parent media element

We used to only check if we were able to load upon setting the track's src,
whereas a change of any of those conditions should have done this, which this
patch now correctly implements.

We also correctly implement the load model asynchronously after step 4, per
the spec, hence the split of the code previously entirely contained in
HTMLTrackElement::scheduleLoad() in another method fired on a timer.

Test: media/track/track-element-load-event.html

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::textTrackModeChanged):
* html/HTMLTrackElement.cpp:
(WebCore::HTMLTrackElement::HTMLTrackElement):
(WebCore::HTMLTrackElement::insertedInto):
(WebCore::HTMLTrackElement::parseAttribute):
(WebCore::HTMLTrackElement::scheduleLoad):
(WebCore):
(WebCore::HTMLTrackElement::loadTimerFired):
(WebCore::HTMLTrackElement::textTrackModeChanged):
* html/HTMLTrackElement.h:
* html/track/TextTrack.cpp:
(WebCore::TextTrack::removeAllCues):
(WebCore):
* html/track/TextTrack.h:
(TextTrack):

LayoutTests:

As a result of fixing this bug, a few new failures were uncovered and TestExpectations
needed to be updated to take this into account. Additionally, some existing tests were
incorrect or outdated and were fixed as well. Finally, a new test was added to thoroughly
test the various conditions required for a <track> element to successfully load.

* fast/events/constructors/track-event-constructor.html: Update the test to correctly set
a non-disabled mode on the text track such that it may load per the rules enforced with this patch.
* http/tests/security/text-track-crossorigin.html: Update the test to correctly set a non-disabled
mode on the text track such that it may load per the rules enforced with this patch.
* media/track/track-add-track-expected.txt: Update the output to match changes made to test.
* media/track/track-add-track.html: Update the test to correctly set a non-disabled mode on
the text track such that it may load per the rules enforced with this patch. Also, ensure
the .readyState of the text track is correctly assumed to be NONE vs. LOADING as it would
have to wait until the next run loop to be changed to anything but NONE.
* media/track/track-element-load-event-expected.txt: Added.
* media/track/track-element-load-event.html: Added.
* media/track/track-load-from-src-readyState.html: Update the test to correctly set a
non-disabled mode on the text track such that it may load per the rules enforced with
this patch.
* platform/chromium/TestExpectations: Skip tests that now fail instead of timing out.
* platform/efl/TestExpectations: Skip tests that now fail instead of timing out.
* platform/gtk/TestExpectations: Skip tests that now fail instead of timing out.
* platform/mac/TestExpectations: Skip tests that now fail instead of timing out.
* platform/qt/TestExpectations: Skip tests that now fail instead of timing out.
* platform/win/TestExpectations: Skip tests that now fail instead of timing out.

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

9 years ago[chromium] Rename low latency rendering mode setting to vsync notification
commit-queue@webkit.org [Fri, 4 Jan 2013 00:32:02 +0000 (00:32 +0000)]
[chromium] Rename low latency rendering mode setting to vsync notification
https://bugs.webkit.org/show_bug.cgi?id=106020

Patch by Sami Kyostila <skyostil@chromium.org> on 2013-01-03
Reviewed by James Robinson.

Source/Platform:

Rename low latency rendering mode setting to vsync notification because
the old name was ambiguous and bad. This setting is meant to control
whether the renderer uses a vsync signal provided by the browser to
schedule rendering.

Source/WebKit/chromium:

Rename low latency rendering mode setting to vsync notification because
the old name was ambiguous and bad. This setting is meant to control
whether the renderer uses a vsync signal provided by the browser to
schedule rendering.

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

9 years agoREGRESSION(r138729): crash and assertion failures in WebKit::WebProcess::plugInDidRec...
jonlee@apple.com [Fri, 4 Jan 2013 00:31:47 +0000 (00:31 +0000)]
REGRESSION(r138729): crash and assertion failures in WebKit::WebProcess::plugInDidReceiveUserInteraction
https://bugs.webkit.org/show_bug.cgi?id=106042
<rdar://problem/12953469>

Reviewed by Brady Eidson.

Source/WebKit2:

The assertion is hit if plugin snapshotting is disabled, and the user interacts with a plug-in that
comes from an origin not found in the cached dictionary. The proper fix is to check for whether the
setting is enabled. Otherwise, that origin should be in the dictionary since the plugin is running.

* WebProcess/Plugins/PluginView.cpp:
(WebKit::PluginView::pluginDidReceiveUserInteraction): Check for the setting, and avoid the whole code
path if snapshotting is disabled.

LayoutTests:

* platform/mac-wk2/TestExpectations: Unskip the crashing tests.

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

9 years agoDFG::ByteCodeCache serves little or no purpose ever since we decided to keep bytecode...
fpizlo@apple.com [Fri, 4 Jan 2013 00:28:23 +0000 (00:28 +0000)]
DFG::ByteCodeCache serves little or no purpose ever since we decided to keep bytecode around permanently
https://bugs.webkit.org/show_bug.cgi?id=106058

Reviewed by Michael Saboff.

All baseline code blocks now always have bytecode, so the bytecode cache's ability to minimize the
number of times that the DFG produces bytecode sequences for code blocks is superfluous.

* GNUmakefile.list.am:
* JavaScriptCore.xcodeproj/project.pbxproj:
* dfg/DFGByteCodeCache.h: Removed.
* dfg/DFGByteCodeParser.cpp:
(ByteCodeParser):
(JSC::DFG::ByteCodeParser::handleInlining):
* runtime/Executable.cpp:
(JSC):
* runtime/Executable.h:
(FunctionExecutable):

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

9 years agoDashboard cleanup: remove usage of global g_defaultBuilderName
jparent@chromium.org [Fri, 4 Jan 2013 00:26:26 +0000 (00:26 +0000)]
Dashboard cleanup: remove usage of global g_defaultBuilderName
https://bugs.webkit.org/show_bug.cgi?id=106043

Use now public defaultBuilder() from the BuilderGroup, rather
than global variable.

Also eliminates the setup() and initBuilders() functions since we
no longer need to track the global.

Reviewed by Adam Barth.

* TestResultServer/static-dashboards/builders.js:
(BuilderGroup.prototype.defaultBuilder):
(BuilderGroup.prototype.master):
* TestResultServer/static-dashboards/dashboard_base.js:
(parseParameters):
* TestResultServer/static-dashboards/flakiness_dashboard.js:
(updateDefaultBuilderState):
* TestResultServer/static-dashboards/loader.js:
(.):
* TestResultServer/static-dashboards/loader_unittests.js:

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

9 years agoAdd a failing test expectation for fast/inline/continuation-outlines-with-layers...
rniwa@webkit.org [Fri, 4 Jan 2013 00:17:18 +0000 (00:17 +0000)]
Add a failing test expectation for fast/inline/continuation-outlines-with-layers.html on Mac
and associate it with the bug 106064.

Also update Chromium test expectations to associate the failure with the bug 106064.
They were erroneously associated with resolved bugs.

* platform/chromium/TestExpectations:
* platform/mac/TestExpectations:

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

9 years agoUnreviewed gardening. Adding cr-linux image baseline for
tdanderson@chromium.org [Fri, 4 Jan 2013 00:07:01 +0000 (00:07 +0000)]
Unreviewed gardening. Adding cr-linux image baseline for
http://trac.webkit.org/changeset/138755

* platform/chromium-linux/fast/regions/full-screen-video-from-region-expected.png: Added.

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

9 years agoRemove all traces of Windows from WebKit2 folder.
roger_fong@apple.com [Thu, 3 Jan 2013 23:59:13 +0000 (23:59 +0000)]
Remove all traces of Windows from WebKit2 folder.
https://bugs.webkit.org/show_bug.cgi?id=105585.

Reviewed by Sam Weinig.

WebKitExportGenerator project needs to be moved out of the WebKit2/win folder and into WebKit/win.

* WebKit.vcproj/WebKit.def.in: Added.
* WebKit.vcproj/WebKit.sln:
* WebKit.vcproj/WebKit.vcproj:
* WebKit.vcproj/WebKitCFLite.vsprops: Added.
* WebKit.vcproj/WebKitExportGenerator.vcproj: Added.
* WebKit.vcproj/WebKitExportGeneratorBuildCmd.cmd: Added.
* WebKit.vcproj/WebKitExportGeneratorCommon.vsprops: Added.
* WebKit.vcproj/WebKitExportGeneratorDebug.vsprops: Added.
* WebKit.vcproj/WebKitExportGeneratorDebugAll.vsprops: Added.
* WebKit.vcproj/WebKitExportGeneratorDebugCairoCFLite.vsprops: Added.
* WebKit.vcproj/WebKitExportGeneratorPostBuild.cmd: Added.
* WebKit.vcproj/WebKitExportGeneratorPreBuild.cmd: Added.
* WebKit.vcproj/WebKitExportGeneratorProduction.vsprops: Added.
* WebKit.vcproj/WebKitExportGeneratorRelease.vsprops: Added.
* WebKit.vcproj/WebKitExportGeneratorReleaseCairoCFLite.vsprops: Added.
* WebKit.vcproj/WebKitLibCommon.vsprops:
* win: Removed.
* win/MainWin.cpp: Removed.
* win/WebKit2.def.in: Removed.
* win/WebKit2.make: Removed.
* win/WebKit2.rc: Removed.
* win/WebKit2.submit.sln: Removed.
* win/WebKit2.vcproj: Removed.
* win/WebKit2Apple.vsprops: Removed.
* win/WebKit2CFLite.vsprops: Removed.
* win/WebKit2Common.vsprops: Removed.
* win/WebKit2Debug.vsprops: Removed.
* win/WebKit2DebugAll.vsprops: Removed.
* win/WebKit2DebugCairoCFLite.vsprops: Removed.
* win/WebKit2DirectX.vsprops: Removed.
* win/WebKit2ExportGenerator.vcproj: Removed.
* win/WebKit2ExportGeneratorBuildCmd.cmd: Removed.
* win/WebKit2ExportGeneratorCommon.vsprops: Removed.
* win/WebKit2ExportGeneratorDebug.vsprops: Removed.
* win/WebKit2ExportGeneratorDebugAll.vsprops: Removed.
* win/WebKit2ExportGeneratorDebugCairoCFLite.vsprops: Removed.
* win/WebKit2ExportGeneratorPostBuild.cmd: Removed.
* win/WebKit2ExportGeneratorPreBuild.cmd: Removed.
* win/WebKit2ExportGeneratorProduction.vsprops: Removed.
* win/WebKit2ExportGeneratorRelease.vsprops: Removed.
* win/WebKit2ExportGeneratorReleaseCairoCFLite.vsprops: Removed.
* win/WebKit2Generated.make: Removed.
* win/WebKit2Generated.vcproj: Removed.
* win/WebKit2GeneratedCommon.vsprops: Removed.
* win/WebKit2Production.vsprops: Removed.
* win/WebKit2Release.vsprops: Removed.
* win/WebKit2ReleaseCairoCFLite.vsprops: Removed.
* win/WebKit2WebProcess.resources: Removed.
* win/WebKit2WebProcess.resources/Info.plist: Removed.
* win/WebKit2WebProcess.vcproj: Removed.
* win/WebKit2WebProcessCommon.vsprops: Removed.
* win/WebKit2WebProcessDebug.vsprops: Removed.
* win/WebKit2WebProcessDebugAll.vsprops: Removed.
* win/WebKit2WebProcessDebugCairoCFLite.vsprops: Removed.
* win/WebKit2WebProcessPostBuild.cmd: Removed.
* win/WebKit2WebProcessPreBuild.cmd: Removed.
* win/WebKit2WebProcessProduction.vsprops: Removed.
* win/WebKit2WebProcessRelease.vsprops: Removed.
* win/WebKit2WebProcessReleaseCairoCFLite.vsprops: Removed.
* win/WebKitPostBuild.cmd: Removed.
* win/WebKitPreBuild.cmd: Removed.
* win/WebKitPreLink.cmd: Removed.
* win/build-generated-files.sh: Removed.
* win/deleteButton.png: Removed.
* win/deleteButtonPressed.png: Removed.
* win/fsVideoAudioVolumeHigh.png: Removed.
* win/fsVideoAudioVolumeLow.png: Removed.
* win/fsVideoExitFullscreen.png: Removed.
* win/fsVideoPause.png: Removed.
* win/fsVideoPlay.png: Removed.
* win/missingImage.png: Removed.
* win/nullplugin.png: Removed.
* win/panEastCursor.png: Removed.
* win/panIcon.png: Removed.
* win/panNorthCursor.png: Removed.
* win/panNorthEastCursor.png: Removed.
* win/panNorthWestCursor.png: Removed.
* win/panSouthCursor.png: Removed.
* win/panSouthEastCursor.png: Removed.
* win/panSouthWestCursor.png: Removed.
* win/panWestCursor.png: Removed.
* win/resource.h: Removed.
* win/searchCancel.png: Removed.
* win/searchCancelPressed.png: Removed.
* win/searchMagnifier.png: Removed.
* win/searchMagnifierResults.png: Removed.
* win/textAreaResizeCorner.png: Removed.
* win/verticalTextCursor.png: Removed.
* win/xcopy.excludes: Removed.
* win/zoomInCursor.png: Removed.
* win/zoomOutCursor.png: Removed.

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

9 years agohttps://bugs.webkit.org/show_bug.cgi?id=105475
bdakin@apple.com [Thu, 3 Jan 2013 23:55:45 +0000 (23:55 +0000)]
https://bugs.webkit.org/show_bug.cgi?id=105475
Nested fixed position elements incorrectly repositioned on scrolling

Reviewed by Simon Fraser.

Source/WebCore:

The fix here is to ensure that the ScrollingTree reflects the same hierarchy as
the GraphicsLayer tree. And from there, we can correctly calculate the offset for
nested objects by keeping track of a cumulative delta that parents have been moved
by.

We already had to fix this same bug in ScrollingStateNode::removeChild(). The
index can be notFound when you are removing a grandchild.
* page/scrolling/ScrollingTreeNode.cpp:
(WebCore::ScrollingTreeNode::removeChild):

parentScrollPositionDidChange() now takes a second parameter that represents the
delta that parent graphicsLayers have been moved by.
* page/scrolling/ScrollingTreeNode.h:
(ScrollingTreeNode):
* page/scrolling/ScrollingTreeScrollingNode.h:
* page/scrolling/mac/ScrollingTreeFixedNode.h:
(ScrollingTreeFixedNode):

attachToStateTree() now handles re-parenting.
* page/scrolling/mac/ScrollingCoordinatorMac.mm:
(WebCore::ScrollingCoordinatorMac::attachToStateTree):

Properly adjust by and compute the new parameter cumulativeDelta. Adjusting by
this will prevent fixed children of fixed objects from moving when they are not
supposed to.
* page/scrolling/mac/ScrollingTreeFixedNode.mm:
(WebCore::ScrollingTreeFixedNode::parentScrollPositionDidChange):

Give parentScrollPositionDidChange() an initial delta of (0,0).
* page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
(WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):

Properly adjust by and compute the new parameter cumulativeDelta. This math is
actually not quite right for sticky yet as the FIXME indicates.
* page/scrolling/mac/ScrollingTreeStickyNode.h:
(ScrollingTreeStickyNode):
* page/scrolling/mac/ScrollingTreeStickyNode.mm:
(WebCore::ScrollingTreeStickyNode::parentScrollPositionDidChange):

Re-named attachToScrollingCoordinator() to attachToScrollingCoordinatorWithParent
to make it clear that the node may already be attached, but it may need to be re-
parented.
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::attachToScrollingCoordinatorWithParent):
* rendering/RenderLayerBacking.h:
(RenderLayerBacking):
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::updateBacking):

Always call attachToScrollingCoordinatorWithParent() in case the fixed node has
been re-parented.
(WebCore::RenderLayerCompositor::registerOrUpdateViewportConstrainedLayer):

LayoutTests:

Unfortunately, the children were not really accurate before, and they are not
really accurate now. It seems like the state tree is not fully up-to-date when the
test is printing it.
* platform/mac/tiled-drawing/fixed/nested-fixed-expected.txt:

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

9 years agoBody background with background-attachment:fixed stays in place during rubber-banding
simon.fraser@apple.com [Thu, 3 Jan 2013 23:46:01 +0000 (23:46 +0000)]
Body background with background-attachment:fixed stays in place during rubber-banding
https://bugs.webkit.org/show_bug.cgi?id=67894

Reviewed by Beth Dakin.

Use FrameView::scrollOffsetForFixedPosition() to compute the location of the rect
used to position fixed backgrounds, since it takes rubber-banding into account.

No test because rubber-banding isn't testtable in layout tests.

* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):

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

9 years ago[HTMLTemplateElement] When adopting a template element, also adopt its content into...
adamk@chromium.org [Thu, 3 Jan 2013 23:41:16 +0000 (23:41 +0000)]
[HTMLTemplateElement] When adopting a template element, also adopt its content into the appropriate document
https://bugs.webkit.org/show_bug.cgi?id=106039

Reviewed by Eric Seidel.

Source/WebCore:

Implements the approach discussed in the spec bug:
https://www.w3.org/Bugs/Public/show_bug.cgi?id=20129

Test: fast/dom/HTMLTemplateElement/ownerDocument-adoptNode.html

* html/HTMLTemplateElement.cpp:
(WebCore::HTMLTemplateElement::didMoveToNewDocument):
* html/HTMLTemplateElement.h:
(HTMLTemplateElement):

LayoutTests:

* fast/dom/HTMLTemplateElement/ownerDocument-adoptNode-expected.txt: Added.
* fast/dom/HTMLTemplateElement/ownerDocument-adoptNode.html: Added.

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

9 years ago[CSS Regions] Don't apply region flow to fullscreen video playing
zoltan@webkit.org [Thu, 3 Jan 2013 23:28:48 +0000 (23:28 +0000)]
[CSS Regions] Don't apply region flow to fullscreen video playing
https://bugs.webkit.org/show_bug.cgi?id=102388

Reviewed by David Hyatt.

In case of full screen video playing we want to watch the video full screen without applying the region flow.

Source/WebCore:

Test: fast/regions/full-screen-video-from-region.html

* dom/NodeRenderingContext.cpp:
(WebCore::NodeRenderingContext::moveToFlowThreadIfNeeded): Don't move full screen video playing to FlowThread.

LayoutTests:

* fast/regions/full-screen-video-from-region-expected.txt: Added.
* fast/regions/full-screen-video-from-region.html: Added.
* platform/chromium-mac/fast/regions/full-screen-video-from-region-expected.png: Added.

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

9 years ago[Mutation Observers] prevent delivery while recipient context is suspended
rafaelw@chromium.org [Thu, 3 Jan 2013 23:22:44 +0000 (23:22 +0000)]
[Mutation Observers] prevent delivery while recipient context is suspended
https://bugs.webkit.org/show_bug.cgi?id=105810

Reviewed by Adam Barth.

Source/WebCore:

Test: inspector/debugger/mutation-observer-suspend-while-paused.html

* dom/MutationObserver.cpp:
(WebCore::suspendedMutationObservers):
(WebCore):
(WebCore::MutationObserver::canDeliver):
(WebCore::MutationObserver::deliver):
(WebCore::MutationObserver::deliverAllMutations):
* dom/MutationObserver.h:

LayoutTests:

* inspector/debugger/mutation-observer-suspend-while-paused-expected.txt: Added.
* inspector/debugger/mutation-observer-suspend-while-paused.html: Added.

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

9 years agoDisable an intermittently failing unit test for now.
rniwa@webkit.org [Thu, 3 Jan 2013 23:22:12 +0000 (23:22 +0000)]
Disable an intermittently failing unit test for now.
The failure is tracked by the bug 106051.

* TestWebKitAPI/Tests/mac/MemoryCachePruneWithinResourceLoadDelegate.mm:
(TestWebKitAPI::TEST):

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

9 years agoEnsure autorelease pool exists when calling WKNSProcessInfoProcessAssertionWithTypes...
commit-queue@webkit.org [Thu, 3 Jan 2013 23:19:41 +0000 (23:19 +0000)]
Ensure autorelease pool exists when calling WKNSProcessInfoProcessAssertionWithTypes on Mac
https://bugs.webkit.org/show_bug.cgi?id=105674

Patch by Kiran Muppala <cmuppala@apple.com> on 2013-01-03
Reviewed by Sam Weinig.

The function WKNSProcessInfoProcessAssertionWithTypes returns a autoreleased object and since,
it is called during process initialization prior to the runloop being started in PluginProcess
and SharedWorkerProcess, an autorelease pool must be explictly created.

* PluginProcess/mac/PluginProcessMainMac.mm:
(WebKit::PluginProcessMain): Enclose process initialization code in an @autoreleasepool block.
* SharedWorkerProcess/mac/SharedWorkerProcessMainMac.mm:
(WebKit::SharedWorkerProcessMain): Ditto.

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

9 years ago[Qt][WK2] Unreviewed gardening, skip a new crashing test to paint the bots green.
ossy@webkit.org [Thu, 3 Jan 2013 23:17:52 +0000 (23:17 +0000)]
[Qt][WK2] Unreviewed gardening, skip a new crashing test to paint the bots green.

* platform/qt-5.0-wk2/TestExpectations:

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

9 years agoUnreviewed gardening. Setting webaudio/automatic-pull-node.html to
tdanderson@chromium.org [Thu, 3 Jan 2013 23:15:43 +0000 (23:15 +0000)]
Unreviewed gardening. Setting webaudio/automatic-pull-node.html to
[ Timeout Pass ] for XP.

* platform/chromium/TestExpectations:

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

9 years ago[Qt] Unreviewed debug buildfix after r138723.
ossy@webkit.org [Thu, 3 Jan 2013 23:04:09 +0000 (23:04 +0000)]
[Qt] Unreviewed debug buildfix after r138723.

* WebProcess/qt/QtBuiltinBundle.cpp:

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

9 years agocss3/filters/effect-invert.html is flaky/has incorrect image output on Win
tdanderson@chromium.org [Thu, 3 Jan 2013 23:02:50 +0000 (23:02 +0000)]
css3/filters/effect-invert.html is flaky/has incorrect image output on Win

Unreviewed gardening. Marked this as [ Failure Pass ] for Win7 and
as [ Failure ] for XP.

* platform/chromium/TestExpectations:

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

9 years agoNo way to obtain a DOMNode given a JS wrapper for a Node
mitz@apple.com [Thu, 3 Jan 2013 23:01:23 +0000 (23:01 +0000)]
No way to obtain a DOMNode given a JS wrapper for a Node
https://bugs.webkit.org/show_bug.cgi?id=106033

Source/WebCore:

Reviewed by Sam Weinig.

Test: TestWebKitAPI/Tests/mac/DOMNodeFromJSObject.mm.

* bindings/objc/DOM.mm:
(+[DOMNode _nodeFromJSWrapper:]): Added. If the given JSObjectRef is a wrapper for a Node,
returns the Objective-C wrapper for that node. Note that Objective-C wrappers are always
for the main world, regardless of which world the given JS wrapper comes from.
* bindings/objc/DOMPrivate.h: Added declaration of the above.

Tools:

Added a test for +[DOMNode _nodeFromJSWrapper:].

Reviewed by Sam Weinig.

* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/mac/DOMNodeFromJSObject.mm: Added.
(TestWebKitAPI):
(TestWebKitAPI::TEST):

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

9 years agowebkit fails IETC column-width-negative-001.htm
commit-queue@webkit.org [Thu, 3 Jan 2013 22:44:11 +0000 (22:44 +0000)]
webkit fails IETC column-width-negative-001.htm
https://bugs.webkit.org/show_bug.cgi?id=84778

Patch by Uday Kiran <udaykiran@motorola.com> on 2013-01-03
Reviewed by Tony Chang.

Source/WebCore:

CSS3 multicolumn 'column-width' property value must be greater than zero.
http://dev.w3.org/csswg/css3-multicol/#column-width

Test: fast/multicol/column-width-zero.html
Negative value test covered by ietestcenter/css3/multicolumn/column-width-negative-001.htm

* css/CSSParser.cpp:
(WebCore::CSSParser::parseValue): Check for value greater than zero while parsing.

LayoutTests:

New test for multicolumn 'column-width' property with zero value.
Enable IETC column-width-negative test.

* fast/multicol/column-width-zero-expected.txt: Added.
* fast/multicol/column-width-zero.html: Added.
* platform/chromium/TestExpectations:
* platform/efl/TestExpectations:
* platform/gtk/TestExpectations:
* platform/mac/TestExpectations:
* platform/qt/TestExpectations:

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

9 years agoAdd crash test expectations for tests regressed by r138729
rniwa@webkit.org [Thu, 3 Jan 2013 22:29:16 +0000 (22:29 +0000)]
Add crash test expectations for tests regressed by r138729
The failure is tracked by the bug 106042.

* platform/mac-wk2/TestExpectations:

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

9 years ago[Chromium] Remove all references to sharedWorkerRepository()
pilgrim@chromium.org [Thu, 3 Jan 2013 22:26:02 +0000 (22:26 +0000)]
[Chromium] Remove all references to sharedWorkerRepository()
https://bugs.webkit.org/show_bug.cgi?id=104704

Reviewed by Adam Barth.

Now that Chromium calls setSharedWorkerRepository upon
initializing WebKit (
https://codereview.chromium.org/10990121/ and
https://codereview.chromium.org/11576028/ ) and no longer
tries to override sharedWorkerRepository, it is safe to remove
all references to this function.

* public/platform/WebKitPlatformSupport.h:
(WebKit):
(WebKit::WebKitPlatformSupport::idbFactory):
* src/SharedWorkerRepository.cpp:
(WebKit::sharedWorkerRepository):
(WebCore::SharedWorkerRepository::isAvailable):

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

9 years agoUnreviewed, fix build for DFG JIT disabled.
fpizlo@apple.com [Thu, 3 Jan 2013 22:23:40 +0000 (22:23 +0000)]
Unreviewed, fix build for DFG JIT disabled.

* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::dumpValueProfiling):
(JSC::CodeBlock::dumpArrayProfiling):
* runtime/Executable.cpp:
(JSC):
(JSC::ExecutableBase::intrinsic):

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

9 years agoUnreviewed. Add Windows specific result for passing test.
roger_fong@apple.com [Thu, 3 Jan 2013 22:08:21 +0000 (22:08 +0000)]
Unreviewed. Add Windows specific result for passing test.

* platform/win/loader: Added.
* platform/win/loader/image-loader-adoptNode-assert-expected.txt: Added.

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

9 years agoMediaStream API: Add a missing state to RTCPeerConnection
tommyw@google.com [Thu, 3 Jan 2013 22:05:35 +0000 (22:05 +0000)]
MediaStream API: Add a missing state to RTCPeerConnection
https://bugs.webkit.org/show_bug.cgi?id=106017

Reviewed by Adam Barth.

Adding the missing ReadyStateHaveRemoteOffer which will show up in the spec soon.

Source/Platform:

* chromium/public/WebRTCPeerConnectionHandlerClient.h:

Source/WebCore:

Not testable, just another state.

* Modules/mediastream/RTCPeerConnection.cpp:
(WebCore::RTCPeerConnection::readyState):
* platform/mediastream/RTCPeerConnectionHandlerClient.h:

Source/WebKit/chromium:

* src/AssertMatchingEnums.cpp:

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

9 years agoCallLinkStatus should be aware of closure calls, and the DFG bytecode parser should...
fpizlo@apple.com [Thu, 3 Jan 2013 22:04:39 +0000 (22:04 +0000)]
CallLinkStatus should be aware of closure calls, and the DFG bytecode parser should use that as its sole internal notion of how to optimize calls
https://bugs.webkit.org/show_bug.cgi?id=106027

Source/JavaScriptCore:

Reviewed by Mark Hahnenberg.

Previously, the DFG bytecode parser had its own internal notion of exactly what CallLinkStatus was
meant to do, in the form of a CallType, expectedFunction, intrinsic, etc. This change makes CallLinkStatus
smart enough to do all of that, and also gives it the ability to understand closure calls.

* bytecode/CallLinkStatus.cpp:
(JSC::CallLinkStatus::CallLinkStatus):
(JSC):
(JSC::CallLinkStatus::function):
(JSC::CallLinkStatus::internalFunction):
(JSC::CallLinkStatus::intrinsicFor):
(JSC::CallLinkStatus::setIsProved):
(JSC::CallLinkStatus::computeFromLLInt):
(JSC::CallLinkStatus::computeFor):
(JSC::CallLinkStatus::dump):
* bytecode/CallLinkStatus.h:
(JSC):
(JSC::CallLinkStatus::CallLinkStatus):
(CallLinkStatus):
(JSC::CallLinkStatus::takesSlowPath):
(JSC::CallLinkStatus::isSet):
(JSC::CallLinkStatus::isClosureCall):
(JSC::CallLinkStatus::callTarget):
(JSC::CallLinkStatus::executable):
(JSC::CallLinkStatus::structure):
(JSC::CallLinkStatus::isProved):
(JSC::CallLinkStatus::canOptimize):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::handleCall):
* dfg/DFGGraph.h:
(JSC::DFG::Graph::valueOfFunctionConstant):

Source/WTF:

Reviewed by Mark Hahnenberg.

I got tired of the various idioms for printing a list of things with comma in between, so I wrote a helper.

* WTF.xcodeproj/project.pbxproj:
* wtf/CommaPrinter.h: Added.
(WTF):
(CommaPrinter):
(WTF::CommaPrinter::CommaPrinter):
(WTF::CommaPrinter::dump):

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

9 years agoFix overflow in LayoutUnit::ceil and floor for SATURATED_LAYOUT_ARITHMETIC
eae@chromium.org [Thu, 3 Jan 2013 21:51:08 +0000 (21:51 +0000)]
Fix overflow in LayoutUnit::ceil and floor for SATURATED_LAYOUT_ARITHMETIC
https://bugs.webkit.org/show_bug.cgi?id=105961

Source/WebCore:

Reviewed by Levi Weintraub.

The LayoutUnit::ceil and floor methods overflows if given the
intMaxForLayoutUnit and intMinForLayoutUnit values respectively.
Check for the max/min value to avoid this.

Test: TestWebKitAPI/Tests/WebCore/LayoutUnit.cpp

* platform/LayoutUnit.h:
(WebCore::LayoutUnit::ceil):
(WebCore::LayoutUnit::floor):
Check for the max/min value and return early to avoid overflow.
Use the UNLIKELY macro to avoid the cost of branch misprediction
for the common case.

Tools:

Reviewed by Levi Weintraub.

Add tests for LayoutUnit::ceil and floor.

* TestWebKitAPI/Tests/WebCore/LayoutUnit.cpp:
(TestWebKitAPI::TEST):
(TestWebKitAPI):

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

9 years ago[Refactoring] Replace Node's Document pointer with a TreeScope pointer
commit-queue@webkit.org [Thu, 3 Jan 2013 21:39:11 +0000 (21:39 +0000)]
[Refactoring] Replace Node's Document pointer with a TreeScope pointer
https://bugs.webkit.org/show_bug.cgi?id=59816

Patch by Elliott Sprehn <esprehn@gmail.com> on 2013-01-03
Reviewed by Ryosuke Niwa.

Instead of giving every node in a shadow a rare data, which can be quite
large, we replace the Document pointer in Node with a TreeScope pointer
and we give TreeScope a pointer to it's document scope.

This introduces no branches in document() because in the common
case document() becomes equivalent to m_treeScope->m_documentScope where
the documentScope is actually m_treeScope so this shouldn't introduce a
perf regression.

Note also that TreeScope can never be null after r136328, and the document
pointer is only null for DocumentType nodes so we can use a special
no-document TreeScope for this case that always returns null from
documentScope().

My original patch in r137524 for this did not correctly handle the case
where the Document is being destroyed and we would then call guardDeref on
ourself in the middle of the Document destructor causing asserts. To fix
this we need to go back to the original model where Document passes
null to it's super constructor for the Document pointer and assigns
it's tree scope later, and we also need to clear the tree scope pointer
in Document's destructor.

No new tests, no change in behavior.

* dom/Document.cpp:
(WebCore::Document::Document):
(WebCore::Document::~Document):
(WebCore::Document::suggestedMIMEType):
* dom/Document.h:
(WebCore::Node::isDocumentNode):
(WebCore::Node::Node):
* dom/Element.cpp:
(WebCore::Element::createRareData):
* dom/ElementRareData.h:
(ElementRareData):
(WebCore::ElementRareData::ElementRareData):
* dom/Node.cpp:
(WebCore::Node::~Node):
(WebCore::Node::createRareData):
(WebCore::Node::attach):
(WebCore::Node::reportMemoryUsage):
* dom/Node.h:
(WebCore::NodeRareDataBase::NodeRareDataBase):
(NodeRareDataBase):
(WebCore::Node::treeScope):
(WebCore::Node::inDocument):
(WebCore::Node::documentInternal):
(WebCore::Node::setTreeScope):
(Node):
* dom/NodeRareData.cpp:
(SameSizeAsNodeRareData):
(WebCore::NodeRareData::reportMemoryUsage):
* dom/NodeRareData.h:
(WebCore::NodeRareData::NodeRareData):
* dom/ShadowRoot.cpp:
(WebCore::ShadowRoot::ShadowRoot):
* dom/TreeScope.cpp:
(SameSizeAsTreeScope):
(WebCore::TreeScope::TreeScope):
(WebCore::TreeScope::clearDocumentScope):
    Needed to clear the document scope during Document destruction
    so the Node destructor does not guardDeref the document that is
    already being destroyed.
(WebCore::TreeScope::setParentTreeScope):
* dom/TreeScope.h:
(TreeScope):
(WebCore::TreeScope::documentScope):
(WebCore::TreeScope::noDocumentInstance):
    Special shared tree scope that has a document scope that is always
    null. This is needed for DocType nodes, and also for Documents
    during construction.
(WebCore::TreeScope::setDocumentScope):
* dom/TreeScopeAdopter.cpp:
(WebCore::TreeScopeAdopter::moveTreeToNewScope):
(WebCore::TreeScopeAdopter::moveNodeToNewDocument):

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

9 years agoRemove failing or flaky test expectations from tests that have been passing on Mac.
rniwa@webkit.org [Thu, 3 Jan 2013 21:32:04 +0000 (21:32 +0000)]
Remove failing or flaky test expectations from tests that have been passing on Mac.

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

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

9 years agoAdd unit test for default builder for the dashboards.
jparent@chromium.org [Thu, 3 Jan 2013 21:30:32 +0000 (21:30 +0000)]
Add unit test for default builder for the dashboards.
https://bugs.webkit.org/show_bug.cgi?id=105972

Reviewed by Dirk Pranke.

* TestResultServer/static-dashboards/loader_unittests.js:

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

9 years agoUnreviewed gardening of Apple Windows port.
roger_fong@apple.com [Thu, 3 Jan 2013 21:26:44 +0000 (21:26 +0000)]
Unreviewed gardening of Apple Windows port.

* platform/win/TestExpectations:
* platform/win/fast/inline/justify-emphasis-inline-box-expected.txt: Added.

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

9 years agoUnreviewed build fix.
adamk@chromium.org [Thu, 3 Jan 2013 21:22:10 +0000 (21:22 +0000)]
Unreviewed build fix.

* dom/ContainerNode.cpp:
(WebCore::isInTemplateContent): s/UNUSED/UNUSED_PARAM/

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

9 years ago[HTMLTemplateElement] Disallow cycles within template content
adamk@chromium.org [Thu, 3 Jan 2013 21:16:59 +0000 (21:16 +0000)]
[HTMLTemplateElement] Disallow cycles within template content
https://bugs.webkit.org/show_bug.cgi?id=105066

Reviewed by Ojan Vafai.

Source/WebCore:

Cycles in <template> content aren't quite as bad as cycles in normal
DOM trees, but they can easily cause crashes, e.g. in cloneNode and
innerHTML.

Shadow DOM has an analagous issue, and this patch tackles that problem
at the same time by creating a new method, Node::containsIncludingHostElements.

In order to disallow cycles, the HTMLTemplateElement.content
DocumentFragment needs a pointer to its host. The approach here
creates a new subclass with a host pointer and a new virtual method
to DocumentFragment to identify the subclass.

To avoid unnecessary virtual function calls, also changed how
Document::templateContentsOwnerDocument works to allow fast inlined
access and avoid lazy creation when not needed.

Tests: fast/dom/HTMLTemplateElement/cycles-in-shadow.html
       fast/dom/HTMLTemplateElement/cycles.html
       fast/dom/shadow/shadow-hierarchy-exception.html

* GNUmakefile.list.am:
* Target.pri:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.xcodeproj/project.pbxproj:
* dom/ContainerNode.cpp:
(WebCore::isInTemplateContent):
(WebCore::containsConsideringHostElements):
(WebCore::checkAcceptChild):
* dom/Document.cpp:
(WebCore::Document::ensureTemplateContentsOwnerDocument): Renamed to make clear that it lazily creates the Document. Updated all existing callers to call this method.
* dom/Document.h:
(Document):
(WebCore::Document::templateContentsOwnerDocument): Fast, inlined accessor for use in checkAcceptChild().
* dom/DocumentFragment.h:
(WebCore::DocumentFragment::isTemplateContent):
* dom/Node.cpp:
(WebCore::Node::containsIncludingShadowDOM): made const, simplified
(WebCore::Node::containsIncludingHostElements): Specialized version of Node::contains that knows how to jump over template content boundaries.
* dom/Node.h:
(Node):
* dom/TemplateContentDocumentFragment.h: Added.
(TemplateContentDocumentFragment): Subclass of DocumentFragment which stores its host template element.
(WebCore::TemplateContentDocumentFragment::create):
(WebCore::TemplateContentDocumentFragment::host):
(WebCore::TemplateContentDocumentFragment::TemplateContentDocumentFragment):
* editing/markup.cpp:
(WebCore::createFragmentForInnerOuterHTML):
* html/HTMLTemplateElement.cpp:
(WebCore::HTMLTemplateElement::content): Construct the new subclass.

LayoutTests:

* fast/dom/HTMLTemplateElement/cycles-expected.txt: Added.
* fast/dom/HTMLTemplateElement/cycles-in-shadow-expected.txt: Added.
* fast/dom/HTMLTemplateElement/cycles-in-shadow.html: Added.
* fast/dom/HTMLTemplateElement/cycles.html: Added.
* fast/dom/shadow/shadow-hierarchy-exception-expected.txt: Added.
* fast/dom/shadow/shadow-hierarchy-exception.html: Added.

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

9 years agoRevert auto-start plugins to snapshotted plugins after a period of inactivity
jonlee@apple.com [Thu, 3 Jan 2013 21:00:37 +0000 (21:00 +0000)]
Revert auto-start plugins to snapshotted plugins after a period of inactivity
https://bugs.webkit.org/show_bug.cgi?id=105973
<rdar://problem/12947865>

Reviewed by Brady Eidson.

Source/WebCore:

* html/HTMLPlugInElement.h:
(WebCore::HTMLPlugInElement::plugInOriginHash): Expose publicly for WebKit2.
Reorganize the protected members of the class.
* html/HTMLPlugInImageElement.h: Move the member to HTMLPlugInElement.

Source/WebKit2:

Change the set of origin hashes maintained by the web process to a hash map that associates
a timestamp for each hash. If the plug-in's origin is marked for auto-start, we also check
it against the timestamp. If the time is later, then we consider the entry stale, and snapshot
the plug-in instead.

But, if the user interacts with the plug-in, we delay that expiration timestamp out, so that
it expires a month from first interaction. To avoid too much chatter between the web processes
and UI process, we only update the timestamp if a day a passed since the last change to the
timestamp.

* WebProcess/Plugins/PluginView.h:
(PluginView): Add a member variable to flag whether the user had interacted with the plug-in.
* WebProcess/Plugins/PluginView.cpp:
(WebKit::PluginView::PluginView): Initialize the flag to false.
(WebKit::PluginView::handleEvent): We consider mouse down, up, wheel, context menu, and keyboard
events as user interaction. Do not consider mouse enter, leave, and move events as user
interaction. Also, remove unneeded comments.
(WebKit::PluginView::pluginDidReceiveUserInteraction): If this is the first time the function is
called, tell the web process, so that the expiration timestamp can be updated.

* WebProcess/WebProcess.messages.in: Update the messages to include the expiration time.
* WebProcess/WebProcess.h:
(WebProcess): Update the cached copy of the auto-start origins to include their expiration
timestamps. Update the message signatures. Add a function to update the expiration timestamp
for a specific origin. Rename plugInAutoStartOriginsChanged to resetPlugInAutoStartOrigins.
* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::initializeWebProcess): Instead of individually adding the origins in the
provided vector, just call resetPlugInAutoStartOrigins().
(WebKit::WebProcess::isPlugInAutoStartOrigin): Check to see if the origin is in the table, and if
so, check the current time against the expiration time.
(WebKit::WebProcess::didAddPlugInAutoStartOrigin): Update the cached table.
(WebKit::WebProcess::resetPlugInAutoStartOrigins): Swap the tables between the provided parameter
and the member variable. We can safely do this because the function is called in two cases where
the parameter is afterwards thrown away: when a new web process is created, and when it is called
through an IPC message.
(WebKit::WebProcess::plugInDidReceiveUserInteraction): When invoked, we tell the UI process to
update the expiration time for the given origin if the time difference between the expiration
time and the current time is less than the threshold plugInAutoStartExpirationTimeUpdateThreshold.

* UIProcess/WebContext.messages.in: Add message that is called when the web process wants to
update the expiration timestamp for the plug-in origin.
* UIProcess/WebContext.cpp:
(WebKit::WebContext::plugInDidReceiveUserInteraction): Forward to the provider.
* UIProcess/WebContext.h:

* UIProcess/Plugins/PlugInAutoStartProvider.cpp:
(WebKit::expirationTimeFromNow): Returns a new time based on the current time + 1 month.
(WebKit::PlugInAutoStartProvider::addAutoStartOrigin): Refactor. Set the expiration time for the
added origin.
(WebKit::PlugInAutoStartProvider::autoStartOriginsCopy): Refactor.
(WebKit::PlugInAutoStartProvider::autoStartOriginsTableCopy): Refactor to include the expiration
times. Also, check the current time against the expiration time. If we are past the time, remove
the entry from the copy.
(WebKit::PlugInAutoStartProvider::setAutoStartOriginsTable): Refactor to extract and duplicate
the provided map of origins and expiration timestamps.
(WebKit::PlugInAutoStartProvider::didReceiveUserInteraction): Look for the origin hash. If found,
update the expiration time. Update all existing web processes with the new expiration time, and
tell the context client that the hashes have changed.
* UIProcess/Plugins/PlugInAutoStartProvider.h:
(PlugInAutoStartProvider): Change the m_autoStartHashes variable to a map of a hash to its domain
entry in the auto-start table. It is used to cross-reference the auto-start table and update
the origin's expiration time.

* Shared/WebProcessCreationParameters.h:
(WebProcessCreationParameters): Switch the creation parameter to seed the origin table to a map.

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

9 years agoQuerying transition-timing-function value on the computed style does not return keywo...
alexis@webkit.org [Thu, 3 Jan 2013 20:22:47 +0000 (20:22 +0000)]
Querying transition-timing-function value on the computed style does not return keywords when it should.
https://bugs.webkit.org/show_bug.cgi?id=105442

Reviewed by Simon Fraser.

Source/WebCore:

http://www.w3.org/TR/css3-transitions/#transition-timing-function-property
contains a set of predefined timing functions which under the hood are
implemented using cubic-bezier but it's an implementation detail that
should not be exposed. It seems to be more clear to return a CSS
keyword rather than the cubic-bezier form when querying the value of
the property on the computed style. In fact the spec even say that for
example the initial value is "ease" and not cubic-bezier(0.25, 0.1,
0.25, 1.0). We could also imagine that in the future these predefined
values could contain other values not represented by a cubic-bezier
form. This behavior also align with the "linear" keyword which return
"linear" rather than cubic-bezier(0.0, 0.0, 1.0, 1.0).

Test: transitions/transitions-parsing.html has been updated to cover
the new behavior as well as making sure that an explicitly set value of
cubic-bezier(0.25, 0.1, 0.25, 1.0) does not return "ease" but the
cubic-bezier() form.

* css/CSSComputedStyleDeclaration.cpp:
(WebCore::createAnimationValue):
(WebCore):
(WebCore::getTimingFunctionValue):
* css/CSSToStyleMap.cpp:
(WebCore::CSSToStyleMap::mapAnimationTimingFunction):
* platform/animation/TimingFunction.h:
(WebCore::CubicBezierTimingFunction::create):
(CubicBezierTimingFunction):
(WebCore::CubicBezierTimingFunction::operator==):
(WebCore::CubicBezierTimingFunction::timingFunctionPreset): Store the
preset value of the timing function if it is one when creating it
so we can use it later from the computed style.
(WebCore::CubicBezierTimingFunction::CubicBezierTimingFunction):

Source/WebKit2:

Update the code to pass the animations from one process to another as
the constructor of TimingFunction changed to take an extra parameter
holding the type of the cubic-bezier form.

* Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
(CoreIPC::encodeTimingFunction):
(CoreIPC::decodeTimingFunction):

LayoutTests:

Update the tests to match the correct behavior of returning a keyword
rather than a cubic-bezier() form when using predefined values for the
transition-timing-function property.

* animations/animation-shorthand-name-order-expected.txt:
* animations/animation-shorthand-name-order.html:
* animations/animation-shorthand-removed.html:
* animations/animation-shorthand.html:
* animations/computed-style-expected.txt:
* animations/computed-style.html:
* fast/css/getComputedStyle/computed-style-expected.txt:
* fast/css/getComputedStyle/computed-style-without-renderer-expected.txt:
* svg/css/getComputedStyle-basic-expected.txt:
* transitions/inherit-other-props-expected.txt:
* transitions/inherit-other-props.html:
* transitions/transitions-parsing-expected.txt:
* transitions/transitions-parsing.html:

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

9 years agoGenerate internal.settings from Settings.in
tony@chromium.org [Thu, 3 Jan 2013 20:07:09 +0000 (20:07 +0000)]
Generate internal.settings from Settings.in
https://bugs.webkit.org/show_bug.cgi?id=104740

Reviewed by Adam Barth.

.:

* Source/cmake/WebKitMacros.cmake: Specify additional output files from make_settings.pl.

Source/WebCore:

If the setting is declared in Settings.in and is a basic type, generate a
setter function at internals.settings.

InternalSettingsGenerated.idl is created by make_settings.pl. InternalSettings.idl
inherits from InternalSettingsGenerated.idl so we can override generated functions if
needed or add additional custom setters.

This patch removes 2 password echo methods from InternalSettings.idl since they are
auto generated. There are other methods we could remove, but I'll do that in a followup.

No new tests, existing tests should pass. Specifically, editing/input/password* tests should pass.

* CMakeLists.txt: Add generated cpp file to the testing lib.
* DerivedSources.make: Add generated idl file and specify all the outputs of make_settings.pl
* DerivedSources.pri: Generate idl file before generating bindings and include generated idl
for bindings generation.
* GNUmakefile.am: Specify all the generated files of make_settings.pl. Add generated idl to
list of files to be processed and resulting output to be compiled.
* UseJSC.cmake: Add generated idl file to list of idl files to process.
* UseV8.cmake: Same as UseJSC.cmake.
* WebCore.gyp/WebCore.gyp: Run make_settings.pl earlier so we can run the output through the
bindings generator.
* WebCore.gypi: Add new files.
* WebCore.vcproj/WebCoreTestSupport.vcproj: Add new files.
* WebCore.xcodeproj/project.pbxproj: Add new files.
* bindings/scripts/CodeGenerator.pm:
(IDLFileForInterface): Add current directory to the include path so DerivedSources.make can
find the generated idl file.
* page/make_settings.pl:
(generateCode): Generate InternalSettingsGenerated.{idl,h,cpp}.
(generateSettingsMacrosHeader): Rename since we're generating 2 headers now.
(setterFunctionName): Helper function for naming a setter.
(printGetterAndSetter): Use setterFunctionName.
(enumerateParsedItems): Helper function that visits each parsed item.
(generateInternalSettingsIdlFile): Generate idl file.
(generateInternalSettingsHeaderFile): Generate header file.
(generateInternalSettingsCppFile): Generate C++ file.
* testing/InternalSettings.cpp:
(WebCore::InternalSettings::Backup::Backup): Remove password echo members.
(WebCore::InternalSettings::Backup::restoreTo): Remove password echo members.
(InternalSettingsWrapper): We can't use RefCountedSupplemental because we're we're already
RefCounted. Create a wrapper class to wrap the RefCounted InternalSettings for Supplement<>::provideTo,
which uses an OwnPtr.
(WebCore::InternalSettingsWrapper::InternalSettingsWrapper): Wraps an InternalSettings that the Page can own.
(WebCore::InternalSettingsWrapper::~InternalSettingsWrapper): Clear's m_page when the Page goes away.
(WebCore::InternalSettingsWrapper::internalSettings): Unwrap InternalSettings.
(WebCore::InternalSettings::from): Update to use InternalSettingsWrapper.
(WebCore::InternalSettings::InternalSettings): Call base class constructor.
(WebCore::InternalSettings::resetToConsistentState): Renamed from reset() and pass through to base class.
Also remove unnecessary pageScaleFactor reset (done in Internals::resetToConsistentState).
* testing/InternalSettings.h:
(Backup): Remove password echo members.
(WebCore::InternalSettings::create): Create an instance instead of using new.
(WebCore::InternalSettings::hostDestroyed): Clear the page. This is similar to the code that
RefCountedSupplemental has.
* testing/InternalSettings.idl: Extends InternalSettingsGenerated.
* testing/js/WebCoreTestSupport.cpp:
(WebCoreTestSupport::resetInternalsObject): Rename to resetToConsistentState to be like other code.
* testing/v8/WebCoreTestSupport.cpp:
(WebCoreTestSupport::resetInternalsObject): Rename to resetToConsistentState to be like other code.
Remove an unused header.

Tools:

* GNUmakefile.am: Compile new generated files on GTK+.
* qmake/mkspecs/features/default_post.prf: Qt: Make it so an action
with both extra_sources and add_output_to_sources=false will still
compile the files in extra_sources. This makes it possible to compile
InternalSettingsGenerated.cpp and not be confused by
InternalSettingsGenerated.idl.

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

9 years agoCanvas blending tests fail on Mac WK2
commit-queue@webkit.org [Thu, 3 Jan 2013 20:04:47 +0000 (20:04 +0000)]
Canvas blending tests fail on Mac WK2
https://bugs.webkit.org/show_bug.cgi?id=105943

Patch by Rik Cabanier <cabanier@adobe.com> on 2013-01-03
Reviewed by Simon Fraser.

Source/WebCore:

Tests that now pass:
    LayoutTests/fast/canvas/canvas-blend-solid.html
    LayoutTests/fast/canvas/canvas-blend-image.html

* testing/InternalSettings.cpp:
(WebCore::InternalSettings::Backup::Backup):
(WebCore::InternalSettings::Backup::restoreTo):
* testing/InternalSettings.h:
(Backup):

Source/WebKit2:

CanvasUsesAcceleratedDrawing preference was not passed to the WebProcess.

* WebProcess/InjectedBundle/InjectedBundle.cpp: Adds support for CanvasUsesAcceleratedDrawing to WK2
(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):

LayoutTests:

* platform/mac-wk2/TestExpectations: updated expectations as the test now passes

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

9 years agoMicrodata: Fix build failure after r137003
arko@motorola.com [Thu, 3 Jan 2013 19:59:02 +0000 (19:59 +0000)]
Microdata: Fix build failure after r137003
https://bugs.webkit.org/show_bug.cgi?id=106023

Reviewed by Ryosuke Niwa.

Set HTMLCollection::namedPropertyGetter as named property getter for
HTMLPropertiesCollection in GenerateImplementationNamedPropertyGetter.

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateImplementationNamedPropertyGetter):
* bindings/v8/custom/V8HTMLCollectionCustom.cpp:
(WebCore::V8HTMLCollection::namedPropertyGetter):

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

9 years agoClear failed image loads when an <img> is adopted into a different document
adamk@chromium.org [Thu, 3 Jan 2013 19:52:26 +0000 (19:52 +0000)]
Clear failed image loads when an <img> is adopted into a different document
https://bugs.webkit.org/show_bug.cgi?id=104409

Reviewed by Nate Chapin.

Source/WebCore:

This avoids an assertion failure setImageWithoutConsideringPendingLoadEvent().

Test: loader/image-loader-adoptNode-assert.html

* loader/ImageLoader.cpp:
(WebCore::ImageLoader::updateFromElement): Use new helper.
(WebCore::ImageLoader::updateFromElementIgnoringPreviousError): ditto
(WebCore::ImageLoader::elementDidMoveToNewDocument): ditto
(WebCore::ImageLoader::clearFailedLoadURL): Added a helper method to self-document the code.
(WebCore):
* loader/ImageLoader.h:
(ImageLoader):

LayoutTests:

* loader/image-loader-adoptNode-assert-expected.txt: Added.
* loader/image-loader-adoptNode-assert.html: Added.

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

9 years ago[Qt] Use WebPageProxy::postMessageToInjectedBundle when passing messages to a specifi...
caio.oliveira@openbossa.org [Thu, 3 Jan 2013 19:24:27 +0000 (19:24 +0000)]
[Qt] Use WebPageProxy::postMessageToInjectedBundle when passing messages to a specific page in the builtin bundle
https://bugs.webkit.org/show_bug.cgi?id=105928

Reviewed by Simon Hausmann.

Simplify the code since we now can send the contents as is, instead of packaging it inside
an array that also contained the reference for the page. This was made possible after
r126311.

* UIProcess/API/qt/qquickwebview.cpp:
(QQuickWebViewPrivate::setNavigatorQtObjectEnabled):
(QQuickWebViewExperimental::postMessage):
Built the messages and used WebPageProxy::postMessageToInjectedBundle() directly.

* UIProcess/qt/QtWebContext.cpp: Removed functions that now are simpler and were inlined in
qquickwebview.cpp.
* UIProcess/qt/QtWebContext.h: Ditto.
* WebProcess/qt/QtBuiltinBundle.cpp:
(WebKit::QtBuiltinBundle::initialize): Used the callback that gets messages for specific
pages. Also changed the way we create the bundle client: now we fill the struct with zeros,
and then set the fields we care about. This way if another field is added to that client,
this code doesn't need to be changed.
(WebKit::QtBuiltinBundle::didReceiveMessageToPage):
(WebKit::QtBuiltinBundle::handleMessageToNavigatorQtObject): Changed to not read the page
reference from the message, since we get it in the callback already.
(WebKit::QtBuiltinBundle::handleSetNavigatorQtObjectEnabled): Ditto.
* WebProcess/qt/QtBuiltinBundle.h:
(QtBuiltinBundle):

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

9 years agoSandbox-blocked pointer lock should log to the console.
scheib@chromium.org [Thu, 3 Jan 2013 19:07:17 +0000 (19:07 +0000)]
Sandbox-blocked pointer lock should log to the console.
https://bugs.webkit.org/show_bug.cgi?id=105794

Reviewed by Adrienne Walker.

Source/WebCore:

When pointer lock is requested and is denied due to sandbox restrictions
a helpful message to web developers is sent to the developer console.

Existing test expectations updated.

* page/PointerLockController.cpp:
(WebCore::PointerLockController::requestPointerLock):

LayoutTests:

* http/tests/pointer-lock/iframe-sandboxed-expected.txt:
* http/tests/pointer-lock/iframe-sandboxed-nested-disallow-then-allow-pointer-lock-expected.txt:

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

9 years agoAdd tests to cover what transition-timing-function accepts for cubic-bezier values.
alexis@webkit.org [Thu, 3 Jan 2013 19:05:44 +0000 (19:05 +0000)]
Add tests to cover what transition-timing-function accepts for cubic-bezier values.
https://bugs.webkit.org/show_bug.cgi?id=105426

Reviewed by Simon Fraser.

http://www.w3.org/TR/css3-transitions/#transition-timing-function-property
has not yet been updated following the discussions
http://lists.w3.org/Archives/Public/www-style/2010Apr/0489.html and
http://lists.w3.org/Archives/Public/www-style/2010Jun/0254.html where
the range restriction of Y values for cubic-bezier type has been
removed. This patch add tests to cover that behavior to avoid breakage
in the future and test also various other different cubic-bezier use
cases.

* transitions/transitions-parsing-expected.txt:
* transitions/transitions-parsing.html:

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

9 years agoPingLoader.h missing virtual and OVERRIDE keywords on its inherited methods.
tsepez@chromium.org [Thu, 3 Jan 2013 18:48:41 +0000 (18:48 +0000)]
PingLoader.h missing virtual and OVERRIDE keywords on its inherited methods.
https://bugs.webkit.org/show_bug.cgi?id=105975

Reviewed by Nate Chapin.

Change adds compile-time checks only, so no new tests.

* loader/PingLoader.h:
(PingLoader):
(WebCore::PingLoader::timeout):

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

9 years ago[style] WebIDL-reflecting uppercase enums reported as style violation
zandobersek@gmail.com [Thu, 3 Jan 2013 18:42:20 +0000 (18:42 +0000)]
[style] WebIDL-reflecting uppercase enums reported as style violation
https://bugs.webkit.org/show_bug.cgi?id=105832

Reviewed by Tony Chang.

Recognize the enum as WebIDL-reflecting one if there's a comment present that
indicates this. In enums spanning over multiple lines, the comment is expected
on the first line. In enums placed in one line, the comment is expected at the
end of that line.

WebIDL-reflecting enum values are required to be written in uppercase and as such
violate the common rule of these values being written in InterCaps. Annotating
enums this way makes it possible to avoid false style violation reports.

The comment is of form '// Web(?:Kit)?IDL enum'.

* Scripts/webkitpy/style/checkers/cpp.py:
(_EnumState.__init__):
(_EnumState.process_clean_line):
(check_enum_casing):
* Scripts/webkitpy/style/checkers/cpp_unittest.py:
(NoNonVirtualDestructorsTest.test_enum_casing):

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

9 years agoUpdate Mac test expectations after merging the bug 105987 into the bug 105986.
rniwa@webkit.org [Thu, 3 Jan 2013 18:38:44 +0000 (18:38 +0000)]
Update Mac test expectations after merging the bug 105987 into the bug 105986.

Also add one more test expectation for the bug.

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

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

9 years agoFix incorrect assumption about in-flow descendants of inlines in touch event rect...
leviw@chromium.org [Thu, 3 Jan 2013 18:32:01 +0000 (18:32 +0000)]
Fix incorrect assumption about in-flow descendants of inlines in touch event rect tracking
https://bugs.webkit.org/show_bug.cgi?id=105970

Reviewed by Simon Fraser.

Source/WebCore:

Correcting the touch event target rect accumulation code to no longer incorrectly assume that
non-block renderers held only normal-flow children. The updated code will always walk the
complete renderer sub-tree, but only do the work of calculating the absolute rect when the
child won't necessarily fall inside its parent (floating, positioned, or transformed).

Tests: platform/chromium/fast/events/touch/compositor-touch-hit-rects.html updated to catch bug.

* page/scrolling/ScrollingCoordinator.cpp:
(WebCore::accumulateRendererTouchEventTargetRects): Walk all renderer sub-trees. Also keeping
track of the last added parent container rect to avoid adding redundant rectangles.
(WebCore::accumulateDocumentEventTargetRects): Avoiding adding empty rects.

LayoutTests:

* platform/chromium-linux/platform/chromium/fast/events/touch/compositor-touch-hit-rects-expected.txt: Updating expectations
* platform/chromium/fast/events/touch/compositor-touch-hit-rects.html: Updating test to check previously failing case where
an inline with a touch handler contains a non-normal-flow child. Also, fixing the test since it was incorrectly duplicated.
* platform/chromium/TestExpectations:

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

9 years agoIndexedDB: Simplify IDBTransactionBackendImpl::scheduleTask usage
jsbell@chromium.org [Thu, 3 Jan 2013 18:23:56 +0000 (18:23 +0000)]
IndexedDB: Simplify IDBTransactionBackendImpl::scheduleTask usage
https://bugs.webkit.org/show_bug.cgi?id=103536

Reviewed by Tony Chang.

Source/WebCore:

Move responsibility for firing abort errors from requests that arrive on the
back-end after an asynchronous transaction abort out of WebCore, since the
front-end takes care of this as far as script is concerned.

No new tests -  no behavior changes.

* Modules/indexeddb/IDBCursorBackendImpl.cpp:
(WebCore::IDBCursorBackendImpl::continueFunction):
(WebCore::IDBCursorBackendImpl::advance):
(WebCore::IDBCursorBackendImpl::prefetchContinue):
* Modules/indexeddb/IDBIndexBackendImpl.cpp:
(WebCore::IDBIndexBackendImpl::openCursor):
(WebCore::IDBIndexBackendImpl::openKeyCursor):
(WebCore::IDBIndexBackendImpl::count):
(WebCore::IDBIndexBackendImpl::get):
(WebCore::IDBIndexBackendImpl::getKey):
* Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
(WebCore::IDBObjectStoreBackendImpl::get):
(WebCore::IDBObjectStoreBackendImpl::put):
(WebCore::IDBObjectStoreBackendImpl::deleteFunction):
(WebCore::IDBObjectStoreBackendImpl::clear):
(WebCore::IDBObjectStoreBackendImpl::openCursor):
(WebCore::IDBObjectStoreBackendImpl::count):

Source/WebKit/chromium:

Track whether IDBCallbacks has fired before being destructed. If not it probably
came in after a transaction had asynchronously aborted; fire an abort error which
will be ignored on the front-end but will clean up lingering IPC tracking.

* public/WebIDBDatabaseException.h:
* src/AssertMatchingEnums.cpp:
* src/IDBCallbacksProxy.cpp:
(WebKit::IDBCallbacksProxy::IDBCallbacksProxy):
(WebKit::IDBCallbacksProxy::~IDBCallbacksProxy):
(WebKit::IDBCallbacksProxy::onError):
(WebKit::IDBCallbacksProxy::onSuccess):
* src/IDBCallbacksProxy.h:
(IDBCallbacksProxy):

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

9 years ago[Qt] Fix a crash when the QQuickWebPage is destroyed between the scene graph sync...
jocelyn.turcotte@digia.com [Thu, 3 Jan 2013 18:17:21 +0000 (18:17 +0000)]
[Qt] Fix a crash when the QQuickWebPage is destroyed between the scene graph sync and render.
https://bugs.webkit.org/show_bug.cgi?id=106018

Reviewed by Simon Hausmann.

The main and rendering threads are only guaranteed to be synchronised in
the updatePaintNode call. In every other cases, QQuickItems cannot be
safely accessed from the rendering thread.

Do as the first patch version in
https://bugs.webkit.org/show_bug.cgi?id=104574 was doing and copy the
ratio value directly to fix the issue.

Also add a note about the threading issue in QQuickWebPage::updatePaintNode.

* UIProcess/API/qt/qquickwebpage.cpp:
(QQuickWebPage::updatePaintNode):
* UIProcess/qt/QtWebPageSGNode.cpp:
(WebKit::QtWebPageSGNode::QtWebPageSGNode):
* UIProcess/qt/QtWebPageSGNode.h:
(QtWebPageSGNode):
(WebKit::QtWebPageSGNode::devicePixelRatio):
(WebKit::QtWebPageSGNode::setDevicePixelRatio):

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

9 years agoUnreviewed gardening. Marking webaudio/automatic-pull-node.html as
tdanderson@chromium.org [Thu, 3 Jan 2013 18:17:17 +0000 (18:17 +0000)]
Unreviewed gardening. Marking webaudio/automatic-pull-node.html as
[ Pass Slow ] instead of [ Pass Timeout ] for XP.

* platform/chromium/TestExpectations:

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

9 years agoAdding favicon.ico to the garden-o-matic.
commit-queue@webkit.org [Thu, 3 Jan 2013 18:05:39 +0000 (18:05 +0000)]
Adding favicon.ico to the garden-o-matic.
https://bugs.webkit.org/show_bug.cgi?id=105982

Patch by Tim 'mithro' Ansell <mithro@mithis.com> on 2013-01-03
Reviewed by Adam Barth.

* Scripts/webkitpy/tool/servers/gardeningserver.py:
* BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/favicon.ico:

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

9 years agoUpdate BB10 media render theme.
commit-queue@webkit.org [Thu, 3 Jan 2013 17:32:28 +0000 (17:32 +0000)]
Update BB10 media render theme.
https://bugs.webkit.org/show_bug.cgi?id=105728

Patch by Tiancheng Jiang <tijiang@rim.com> on 2013-01-03
Reviewed by Yong Li.

Internally Reviewed by John Griggs.

Update GL friendly render method for audio volume.
Change the background color for embedded media player to semi-transparent.
Change remaining time font color to grey to match full screen video.
Change media slider thumb color to blue when pressed.

* css/mediaControlsBlackBerry.css:
(audio):
(audio::-webkit-media-controls-embedded-panel, video::-webkit-media-controls-embedded-panel):
(video::-webkit-media-controls-time-display-container, audio::-webkit-media-controls-time-display-container):
(video::-webkit-media-controls-timeline-container, audio::-webkit-media-controls-timeline-container):
(audio::-webkit-media-controls-current-time-display, video::-webkit-media-controls-current-time-display):
(video::-webkit-media-controls-time-remaining-display, audio::-webkit-media-controls-time-remaining-display):
(audio::-webkit-media-controls-volume-slider-container):
* platform/blackberry/RenderThemeBlackBerry.cpp:
(WebCore::RenderThemeBlackBerry::paintMediaSliderThumb):
(WebCore::RenderThemeBlackBerry::paintMediaVolumeSliderTrack):

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

9 years agoUnreviewed, rolling out r138640.
commit-queue@webkit.org [Thu, 3 Jan 2013 17:05:08 +0000 (17:05 +0000)]
Unreviewed, rolling out r138640.
http://trac.webkit.org/changeset/138640
https://bugs.webkit.org/show_bug.cgi?id=106019

Causing crashes in multiply() (Requested by danakj on
#webkit).

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

* platform/graphics/transforms/TransformationMatrix.cpp:
(WebCore):
(WebCore::TransformationMatrix::multiply):
* platform/graphics/transforms/TransformationMatrix.h:
(TransformationMatrix):

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

9 years ago[Qt] Unreviewed gardening, skip a new failing test.
ossy@webkit.org [Thu, 3 Jan 2013 14:37:25 +0000 (14:37 +0000)]
[Qt] Unreviewed gardening, skip a new failing test.

* platform/qt/TestExpectations:

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

9 years agoThe 'body' of seamless IFrames should default to 'margin: 0'
mkwst@chromium.org [Thu, 3 Jan 2013 14:30:22 +0000 (14:30 +0000)]
The 'body' of seamless IFrames should default to 'margin: 0'
https://bugs.webkit.org/show_bug.cgi?id=90834

Reviewed by Antti Koivisto.

Source/WebCore:

Documents displayed in seamless iframes should override the 'body'
element's normal 8px default margins with 0px, in order to ensure that
contents are displayed flush with the boundries of the seamless box.[1]

This patch does so by adding a new pseudoclass to allow the user agent
stylesheet to specify a different margin for seamless documents.

[1]: http://lists.w3.org/Archives/Public/public-whatwg-archive/2012Jul/0039.html

Test: fast/frames/seamless/seamless-body-margin.html

* css/CSSSelector.cpp:
(WebCore::CSSSelector::pseudoId):
(WebCore::nameToPseudoTypeMap):
(WebCore::CSSSelector::extractPseudoType):
* css/CSSSelector.h:
* css/SelectorChecker.cpp:
(WebCore::SelectorChecker::checkOneSelector):
* css/html.css:
(body:-webkit-seamless-document):
* rendering/style/RenderStyleConstants.h:
    Define a new pseudoclass: '-webkit-seamless-document', which
    matches for any element in a document that's rendered in a
    seamless IFrame.

LayoutTests:

* fast/frames/seamless/seamless-body-margin-expected.txt: Added.
* fast/frames/seamless/seamless-body-margin.html: Added.
    New test to explicitly check 'body' margins.
* fast/frames/seamless/resources/nested-seamless.html:
* fast/frames/seamless/resources/quirks-square.html:
* fast/frames/seamless/resources/two-inline-blocks.html:
* fast/frames/seamless/seamless-inherited-origin-expected.txt:
* fast/frames/seamless/seamless-inherited-origin.html:
    Updated these tests to remove the assumption that the body had an
    8px margin.

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

9 years ago[Qt] Unreviewed gardening.
ossy@webkit.org [Thu, 3 Jan 2013 14:28:01 +0000 (14:28 +0000)]
[Qt] Unreviewed gardening.

* platform/qt/TestExpectations: Skip new failing tests.
* platform/qt/editing/deleting/delete-to-select-table-expected.txt: Updated after r138654.
* platform/qt/editing/execCommand/print-expected.txt: Updated after r138654.
* platform/qt/editing/execCommand/selectAll-expected.txt: Updated after r138654.
* platform/qt/editing/inserting/editable-html-element-expected.txt: Updated after r138654.

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

9 years ago[Qt] Fix library linking order
commit-queue@webkit.org [Thu, 3 Jan 2013 14:13:44 +0000 (14:13 +0000)]
[Qt] Fix library linking order
https://bugs.webkit.org/show_bug.cgi?id=105818

Some Qt libraries are linked before the private static libraries
that depend on them which results in QtWebKit failing to link.

Copy Qt module dependencies from QT to QT_PRIVATE when creating
module to ensure the Qt libraries are linked after the private
static libraries that depend on them.

Patch by Jonathan Liu <net147@gmail.com> on 2013-01-03
Reviewed by Tor Arne Vestbø.

* qmake/mkspecs/features/default_post.prf:

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

9 years agoUnreviewed fix after r138656 to make GIT-SVN repositories happy.
ossy@webkit.org [Thu, 3 Jan 2013 13:43:22 +0000 (13:43 +0000)]
Unreviewed fix after r138656 to make GIT-SVN repositories happy.

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

9 years ago[MinGW-w64] Centralize workaround for pow() implementation
hausmann@webkit.org [Thu, 3 Jan 2013 09:54:36 +0000 (09:54 +0000)]
[MinGW-w64] Centralize workaround for pow() implementation
https://bugs.webkit.org/show_bug.cgi?id=105925

Reviewed by Sam Weinig.

As suggested by Sam, move the MinGW-w64 workaround into MathExtras.h
away from the JSC usage.

Source/JavaScriptCore:

* runtime/MathObject.cpp:
(JSC::mathPow):

Source/WTF:

* wtf/MathExtras.h:
(wtf_pow):

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

9 years agoseamless iframes don't inherit styles when srcdoc is used
mkwst@chromium.org [Thu, 3 Jan 2013 09:13:50 +0000 (09:13 +0000)]
seamless iframes don't inherit styles when srcdoc is used
https://bugs.webkit.org/show_bug.cgi?id=103539

Reviewed by Antti Koivisto.

Source/WebCore:

Seamless iframes populated via a 'srcdoc' attribute should always
inherit styles from their parent documents. At the moment, this is
only the case when they contain a stylesheet or some other markup
that forces a style recalculation on the document. Simple 'srcdoc'
attributes (e.g. "srcdoc='<p>This is a comment.</p>'") bail out of
recalculating style early, resulting in unstyled appearance.

This patch instructs WebCore to treat seamless documents as having an
updated StyleResolver regardless of what actions the parser takes,
which in turn ensures that the document's style is recalculated
correctly.

Test: fast/frames/seamless/seamless-srcdoc.html

* dom/Document.cpp:
(WebCore::Document::implicitOpen):
    If it's a seamless document, notify it that its StyleResolver isn't
    what it might have expected.

LayoutTests:

* fast/frames/seamless/resources/span.html: Added.
* fast/frames/seamless/seamless-contenteditable-not-inherited-expected.txt:
    Updating the previously failing expectation.
* fast/frames/seamless/seamless-srcdoc-expected.txt: Added.
* fast/frames/seamless/seamless-srcdoc.html: Added.
    Exciting new test to ensure that this doesn't regress, neither
    for totally simple srcdoc attriubtes, nor for slightly more
    complex variations.

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

9 years ago[Qt] Implement SimpleFontData::platformBoundsForGlyph
allan.jensen@digia.com [Thu, 3 Jan 2013 08:42:24 +0000 (08:42 +0000)]
[Qt] Implement SimpleFontData::platformBoundsForGlyph
https://bugs.webkit.org/show_bug.cgi?id=104127

Reviewed by Jocelyn Turcotte.

Implements platformBoundsForGlyph which is necessary for working MathML and Ruby.

* platform/graphics/qt/SimpleFontDataQt.cpp:
(WebCore::SimpleFontData::platformBoundsForGlyph):

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

9 years agoAdd failing test expectations for two canvas tests on Mac Lion
rniwa@webkit.org [Thu, 3 Jan 2013 07:11:20 +0000 (07:11 +0000)]
Add failing test expectations for two canvas tests on Mac Lion
since they have been failing as far as we could tell on the flakiness dashboard.

The failure is tracked by the bug 105999.

* platform/mac/TestExpectations:

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

9 years agoRemove superfluous 'IntPoint toPoint(const IntSize&)'
commit-queue@webkit.org [Thu, 3 Jan 2013 07:09:19 +0000 (07:09 +0000)]
Remove superfluous 'IntPoint toPoint(const IntSize&)'
https://bugs.webkit.org/show_bug.cgi?id=105993

Patch by Steve Block <steveblock@chromium.org> on 2013-01-02
Reviewed by Eric Seidel.

Refactoring only, no change in behavior.

* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::elementAccessibilityHitTest):
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::remoteSVGElementHitTest):
* page/EventHandler.cpp:
(WebCore::EventHandler::handleDrag):
* page/scrolling/ScrollingCoordinator.cpp:
(WebCore::ScrollingCoordinator::updateMainFrameScrollPosition):
* page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
(WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
* platform/graphics/IntPoint.h:
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::scrollToOffset):
(WebCore::RenderLayer::offsetFromResizeCorner):
(WebCore::RenderLayer::updateScrollInfoAfterLayout):

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

9 years agoAdd a Mac test expectation for the bug 105998.
rniwa@webkit.org [Thu, 3 Jan 2013 07:05:44 +0000 (07:05 +0000)]
Add a Mac test expectation for the bug 105998.

* platform/mac-wk2/TestExpectations:

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

9 years ago[BlackBerry] file:/// pages don't get correct scales after several rotations and...
zhajiang@rim.com [Thu, 3 Jan 2013 06:11:38 +0000 (06:11 +0000)]
[BlackBerry] file:/// pages don't get correct scales after several rotations and history navigations
https://bugs.webkit.org/show_bug.cgi?id=105996

Patch by Jacky Jiang <zhajiang@rim.com>.
Reviewed by George Staikos.

PR: 273541
When navigating back to the previous page on portrait mode, we were
trying to set virtual viewport after recalculation. However, we didn't
change the fixed layout size so that we still layouted the contents at
the old virtual viewport size. In this case, the old virtual viewport
was 570 * 293 which was set in landscape mode unfortunately. There
would be no chance for such kind of contents size to fit the portrait
mode screen size nicely.
This was a regression of webkit/cc31d9bad where setViewMode() was
removed as a noop. So just get setViewMode() back to apply the fixed
layout size with a little bit change as SVG document path was proved
invalid in that patch. Thanks to George for the float comparison change.
Put a FIXME as we don't have a way to save the scale precisely before
the rotation and history navigation currently.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::setLoadState):
* WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
(WebCore::FrameLoaderClientBlackBerry::saveViewStateToItem):

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

9 years agoMore Mac test expectation updates per bugs 105988 and 105987.
rniwa@webkit.org [Thu, 3 Jan 2013 05:36:32 +0000 (05:36 +0000)]
More Mac test expectation updates per bugs 105988 and 105987.

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

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

9 years ago[EFL][WK2] Fix tooltip bugs in MiniBrowser.
commit-queue@webkit.org [Thu, 3 Jan 2013 04:47:46 +0000 (04:47 +0000)]
[EFL][WK2] Fix tooltip bugs in MiniBrowser.
https://bugs.webkit.org/show_bug.cgi?id=102209

Patch by Byungwoo Lee <bw80.lee@samsung.com> on 2013-01-02
Reviewed by Gyuyoung Kim.

Set tooltip on the elm_window instead of ewk_view, and add delay to
show the tooltip window.

Setting tooltip on the ewk_view makes elementary error message because
ewk_view is not an elementary widget. To remove the error message,
tooltip should be set on the elm_window.

Most browsers show the tooltip after a mouse pointer stays on an
element object that has tooltip text.
But elm_tooltip widget itself doesn't have delay or handle mouse
events to show/hide.

So additional codes are added to show/hide tooltip widget along with
mouse events.
  1) When a mouse pointer stays for a second on an element which has
     tooltip text, then tooltip widget is displayed.
  2) When a mouse pointer is moved or out of ewk_view, hide the tooltip
     widget.

* MiniBrowser/efl/main.c:
(_Tooltip_Information):
(_Browser_Window):
(on_tooltip_show):
(window_tooltip_hide):
(window_tooltip_update):
(on_mouse_in):
(on_mouse_move):
(on_mouse_out):
(window_free):
(on_tooltip_text_set):
(on_tooltip_text_unset):
(window_create):

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

9 years ago[BlackBerry] Do not determine db quota limit using db file size
commit-queue@webkit.org [Thu, 3 Jan 2013 04:44:09 +0000 (04:44 +0000)]
[BlackBerry] Do not determine db quota limit using db file size
https://bugs.webkit.org/show_bug.cgi?id=105991

PR 267191

Patch by Otto Derek Cheung <otcheung@rim.com> on 2013-01-02
Reviewed by George Staikos.

Passing the current quota to WebPageClientImpl::databaseQuota so we can determine a better
quota limit without using the db file size.

* Api/WebPageClient.h:
* WebCoreSupport/ChromeClientBlackBerry.cpp:
(WebCore::ChromeClientBlackBerry::exceededDatabaseQuota):

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

9 years ago[TexMap] Remove m_size in TextureMapperLayer.
commit-queue@webkit.org [Thu, 3 Jan 2013 04:39:01 +0000 (04:39 +0000)]
[TexMap] Remove m_size in TextureMapperLayer.
https://bugs.webkit.org/show_bug.cgi?id=105781

Patch by Huang Dongsung <luxtella@company100.net> on 2013-01-02
Reviewed by Noam Rosenthal.

m_size is duplicated by State::size, so this patch removes it.

No new tests. Refactoring only.

* platform/graphics/texmap/TextureMapperLayer.cpp:
(WebCore::TextureMapperLayer::computeTransformsRecursive):
(WebCore::TextureMapperLayer::paintSelf):
(WebCore::TextureMapperLayer::isVisible):
(WebCore::TextureMapperLayer::flushCompositingStateForThisLayerOnly):
* platform/graphics/texmap/TextureMapperLayer.h:
(WebCore::TextureMapperLayer::layerRect):
(TextureMapperLayer):

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

9 years agoAdd flaky crash expectations for multiple tests on Mac WebKit2.
rniwa@webkit.org [Thu, 3 Jan 2013 03:24:20 +0000 (03:24 +0000)]
Add flaky crash expectations for multiple tests on Mac WebKit2.

* platform/mac-wk2/TestExpectations:

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

9 years ago[chromium] Creation of dedicated workers (isolates) leaks reference to HTMLDocument
kbr@google.com [Thu, 3 Jan 2013 03:22:30 +0000 (03:22 +0000)]
[chromium] Creation of dedicated workers (isolates) leaks reference to HTMLDocument
https://bugs.webkit.org/show_bug.cgi?id=105367

Reviewed by Dmitry Titov.

Source/WebCore:

Eliminated a Chromium-specific object wrapping WorkerMessagingProxy in order to fix a
lifetime management bug, which leaked every Document which started a dedicated worker.

Test: fast/workers/worker-document-leak.html

* workers/WorkerLoaderProxy.h:
(WorkerLoaderProxy):
    Added Chromium-specific casting method to bridge two now-distinct class hierarchies.
* workers/WorkerMessagingProxy.h:
(WorkerMessagingProxy):
    Made destructor protected instead of private to allow subclassing.

Source/WebKit/chromium:

Made WebWorkerClientImpl a subclass of WorkerMessagingProxy rather than an object wrapping
WorkerMessagingProxy. WorkerMessagingProxy manages its own lifetime and it is impossible to
properly synchronize the lifetime of WebWorkerClientImpl separately.

This allowed most of WebWorkerClientImpl to be deleted, but forced a divergence in the class
hierarchies of WebWorkerClientImpl and WebSharedWorkerImpl. Conversion methods were added to
WorkerLoaderProxy and WebWorkerBase to bridge the hierarchies of in-process and
out-of-process workers.

* src/DatabaseObserver.cpp:
(WebCore::DatabaseObserver::canEstablishDatabase):
    Adjusted how WebWorkerBase is obtained from WorkerLoaderProxy.
* src/IDBFactoryBackendProxy.cpp:
(WebKit::AllowIndexedDBMainThreadBridge::signalCompleted):
    Adjusted how WorkerLoaderProxy's methods are called.
(WebKit::IDBFactoryBackendProxy::allowIndexedDB):
    Adjusted how WebWorkerBase is obtained from WorkerLoaderProxy.
* src/LocalFileSystemChromium.cpp:
(WebCore::openFileSystemHelper):
    Adjusted how WebWorkerBase is obtained from WorkerLoaderProxy.
* src/WebSharedWorkerImpl.cpp:
(WebKit::WebSharedWorkerImpl::toWebWorkerBase):
    Implemented new conversion method.
* src/WebSharedWorkerImpl.h:
(WebSharedWorkerImpl):
    Explicitly derive from WorkerLoaderProxy now that WebWorkerBase no longer does.
(WebKit::WebSharedWorkerImpl::workerLoaderProxy):
    Added new conversion method.
* src/WebWorkerBase.h:
(WebWorkerBase):
    Removed derivation from WorkerLoaderProxy. Added method to convert to WorkerLoaderProxy.
* src/WebWorkerClientImpl.cpp:
(WebKit):
    Adjusted comment.
(WebKit::WebWorkerClientImpl::createWorkerContextProxy):
    Adjusted whitespace.
(WebKit::WebWorkerClientImpl::terminateWorkerContext):
    Eliminated delegation to separate object.
(WebKit::WebWorkerClientImpl::toWebWorkerBase):
    Implemented new conversion method.
(WebKit::WebWorkerClientImpl::view):
(WebKit::WebWorkerClientImpl::allowDatabase):
(WebKit::WebWorkerClientImpl::allowFileSystem):
(WebKit::WebWorkerClientImpl::openFileSystem):
(WebKit::WebWorkerClientImpl::allowIndexedDB):
    Eliminated delegation to separate object.
(WebKit::WebWorkerClientImpl::WebWorkerClientImpl):
* src/WebWorkerClientImpl.h:
(WebKit):
    Changed to inherit from WorkerMessagingProxy directly.
(WebWorkerClientImpl):
    Deleted most methods previously overridden from WorkerContextProxy, etc.
* src/WorkerAsyncFileSystemChromium.cpp:
(WebCore::WorkerAsyncFileSystemChromium::WorkerAsyncFileSystemChromium):
(WebCore::WorkerAsyncFileSystemChromium::createWorkerFileSystemCallbacksBridge):
    Hold on to, and use, WorkerLoaderProxy rather than WebWorkerBase.
* src/WorkerAsyncFileSystemChromium.h:
(WebKit):
(WebCore):
(WorkerAsyncFileSystemChromium):
    Hold on to WorkerLoaderProxy rather than WebWorkerBase.

LayoutTests:

* fast/workers/resources/empty-worker.js: Added.
* fast/workers/resources/worker-document-leak-iframe.html: Added.
* fast/workers/worker-document-leak-expected.txt: Added.
* fast/workers/worker-document-leak.html: Added.

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

9 years agoOne more Mac rebaseline attempt for r138654. Also remove an entry for the bug 105514
rniwa@webkit.org [Thu, 3 Jan 2013 03:09:22 +0000 (03:09 +0000)]
One more Mac rebaseline attempt for r138654. Also remove an entry for the bug 105514
which has been dup'ed with the bug 103663 for which we have more specific expectations.

* platform/mac-lion/editing/deleting: Removed.
* platform/mac-lion/editing/deleting/delete-to-select-table-expected.txt: Removed.
* platform/mac-wk2/editing/deleting: Removed.
* platform/mac-wk2/editing/deleting/delete-to-select-table-expected.txt: Removed.
* platform/mac/TestExpectations:
* platform/mac/editing/deleting/delete-to-select-table-expected.txt:

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

9 years agoMake ClassList::reset's purpose obvious and don't keep quirks string when not needed
esprehn@chromium.org [Thu, 3 Jan 2013 02:59:32 +0000 (02:59 +0000)]
Make ClassList::reset's purpose obvious and don't keep quirks string when not needed
https://bugs.webkit.org/show_bug.cgi?id=105963

Reviewed by Ojan Vafai.

ClassList::reset only exists to handle updating the special SpaceSplitString
for quirks mode documents. This adds a new method that makes this obvious and
instead of updating the string immediately clear the value and lazily
update it. We also clear the value whenever we're inserted into the
document so that when moving from a quirks mode document to a non-quirks
mode document we don't keep the SpaceSplitString around if it's not needed.

No new tests, I'm not sure how to write a test that we don't keep the
SpaceSplitString when moving between quirks and non-quirks mode documents.

* dom/Element.cpp:
(WebCore::Element::classAttributeChanged):
(WebCore::Element::insertedInto):
* dom/Element.h:
(Element):
* dom/ElementRareData.h:
(WebCore::ElementRareData::clearClassListValueForQuirksMode):
* html/ClassList.cpp:
* html/ClassList.h:
(WebCore::ClassList::clearValueForQuirksMode):

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

9 years ago[chromium] Remove unused transitional #defines from WebKit Client API
commit-queue@webkit.org [Thu, 3 Jan 2013 02:05:15 +0000 (02:05 +0000)]
[chromium] Remove unused transitional #defines from WebKit Client API
https://bugs.webkit.org/show_bug.cgi?id=105974

Patch by James Robinson <jamesr@chromium.org> on 2013-01-02
Reviewed by Adam Barth.

The transitions these #defines helped with have completed.

* public/WebFileSystemCallbacks.h:
(WebKit):
* public/WebKit.h:
* public/WebRuntimeFeatures.h:
* public/WebSettings.h:
* public/WebWidget.h:

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

9 years agoObjective-C API for JavaScriptCore
barraclough@apple.com [Thu, 3 Jan 2013 02:03:12 +0000 (02:03 +0000)]
Objective-C API for JavaScriptCore
https://bugs.webkit.org/show_bug.cgi?id=105889

Reviewed by Geoff Garen.

Fixes for more issues raised by Darin.

* API/JSBlockAdaptor.mm:
(BlockArgument):
(BlockArgumentStruct::BlockArgumentStruct):
(BlockArgumentTypeDelegate::typeStruct):
(BlockResult):
(BlockResultStruct::BlockResultStruct):
(buildBlockSignature):
(-[JSBlockAdaptor initWithBlockSignatureFromProtocol:]):
(-[JSBlockAdaptor blockFromValue:inContext:withException:]):
    - fix * position for Objective-C types
* API/JSContext.h:
    - fix * position for Objective-C types
* API/JSContext.mm:
(-[JSContext initWithVirtualMachine:]):
(-[JSContext virtualMachine]):
(contextInternalContext):
    - fix * position for Objective-C types
(-[JSContext dealloc]):
(-[JSContext protect:]):
(-[JSContext unprotect:]):
    - HashMap<JSValueRef, size_t> -> HashCountedSet<JSValueRef>
* API/JSContextInternal.h:
(WeakContextRef):
    - fix * position for Objective-C types
* API/JSValue.mm:
(valueToString):
    - fix * position for Objective-C types
(isNSBoolean):
    - Added helper to check for booleans.
(objectToValueWithoutCopy):
    - Added contextRef
    - fix * position for Objective-C types
    - Remove @YES, @NO literal usage, use isNSBoolean instead
(objectToValue):
    - Added contextRef
(+[JSValue valueWithValue:inContext:]):
(-[JSValue initWithValue:inContext:]):
    - fix * position for Objective-C types
(createStructHandlerMap):
(handerForStructTag):
    - getStructTagHandler -> handerForStructTag
    - Split out createStructHandlerMap
    - strncmp -> memcmp
    - String(type).impl() -> StringImpl::create(type)
(+[JSValue selectorForStructToValue:]):
(+[JSValue selectorForValueToStruct:]):
    - getStructTagHandler -> handerForStructTag
(typeToValueInvocationFor):
(valueToTypeInvocationFor):
    - fix * position for Objective-C types
* API/JSValueInternal.h:
    - fix * position for Objective-C types
* API/JSVirtualMachineInternal.h:
    - fix * position for Objective-C types
* API/JSWrapperMap.h:
    - fix * position for Objective-C types
* API/JSWrapperMap.mm:
(selectorToPropertyName):
(createObjectWithCustomBrand):
(createRenameMap):
(putNonEnumerable):
(copyMethodsToObject):
(copyPrototypeProperties):
(-[JSObjCClassInfo initWithContext:forClass:superClassInfo:]):
(-[JSWrapperMap initWithContext:]):
(-[JSWrapperMap wrapperForObject:]):
(getJSExportProtocol):
    - fix * position for Objective-C types
* API/ObjCCallbackFunction.h:
    - fix * position for Objective-C types
* API/ObjCCallbackFunction.mm:
(CallbackArgument):
(CallbackArgumentStruct::CallbackArgumentStruct):
    - fix * position for Objective-C types
(CallbackArgumentBlockCallback::createAdoptingJSBlockAdaptor):
    - Added to make adopt explicit
(CallbackArgumentBlockCallback):
(CallbackArgumentBlockCallback::CallbackArgumentBlockCallback):
(ArgumentTypeDelegate::typeBlock):
    - Call createAdoptingJSBlockAdaptor
(ArgumentTypeDelegate::typeStruct):
(CallbackResult):
(CallbackResultStruct::CallbackResultStruct):
(ResultTypeDelegate::typeStruct):
(ObjCCallbackFunction::ObjCCallbackFunction):
(ObjCCallbackFunction::context):
(objCCallbackFunctionForInvocation):
(objCCallbackFunctionForMethod):
(objCCallbackFunctionForBlock):
    - fix * position for Objective-C types
* API/ObjcRuntimeExtras.h:
(protocolImplementsProtocol):
(forEachProtocolImplementingProtocol):
(forEachMethodInProtocol):
(forEachPropertyInProtocol):
    - fix * position for Objective-C types
* API/tests/testapi.m:
(-[TestObject testArgumentTypesWithInt:double:boolean:string:number:array:dictionary:]):
(testObjectiveCAPI):
    - fix * position for Objective-C types

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

9 years ago[chromium] Remove unused transitional #defines from Platform API
commit-queue@webkit.org [Thu, 3 Jan 2013 01:21:08 +0000 (01:21 +0000)]
[chromium] Remove unused transitional #defines from Platform API
https://bugs.webkit.org/show_bug.cgi?id=105971

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

These are leftovers from multi-sided patches that landed months ago.

* chromium/public/WebContentLayerClient.h:
(WebContentLayerClient):
* chromium/public/WebLayer.h:
* chromium/public/WebLayerTreeView.h:
* chromium/public/WebThread.h:

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

9 years agoMac and Chromium rebaselines after r138654.
rniwa@webkit.org [Thu, 3 Jan 2013 01:20:56 +0000 (01:20 +0000)]
Mac and Chromium rebaselines after r138654.

* editing/deleting/delete-to-select-table-expected.txt: Added.
* platform/chromium-mac/editing/deleting/delete-to-select-table-expected.txt: Added.
* platform/chromium/editing/deleting/delete-to-select-table-expected.txt: Removed.
* platform/efl/editing/deleting/delete-to-select-table-expected.txt: Removed.
* platform/gtk/editing/deleting/delete-to-select-table-expected.txt: Removed.
* platform/mac-lion/editing/deleting/delete-to-select-table-expected.txt: Added.
* platform/mac-wk2/editing/deleting: Added.
* platform/mac-wk2/editing/deleting/delete-to-select-table-expected.txt: Added.

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

9 years agoUnreviewed Chromium gardening.
macpherson@chromium.org [Thu, 3 Jan 2013 01:11:01 +0000 (01:11 +0000)]
Unreviewed Chromium gardening.

Rebaseline win-xp image for svg/dynamic-updates/SVGFEComponentTransferElement-dom-tableValues-attr-expected.html.

* platform/chromium-win-xp/svg/dynamic-updates/SVGFEComponentTransferElement-dom-tableValues-attr-expected.png: Added.

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

9 years agoInitialize WebInputEvent to prevent sending uninitialized bytes with IPC messages.
cdn@chromium.org [Thu, 3 Jan 2013 01:10:24 +0000 (01:10 +0000)]
Initialize WebInputEvent to prevent sending uninitialized bytes with IPC messages.
https://bugs.webkit.org/show_bug.cgi?id=105934

Reviewed by James Robinson.

* public/WebInputEvent.h:
(WebKit::WebInputEvent::WebInputEvent):

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

9 years agoStop pretending its possible to run the WebProcess in threaded mode
weinig@apple.com [Thu, 3 Jan 2013 01:06:53 +0000 (01:06 +0000)]
Stop pretending its possible to run the WebProcess in threaded mode
https://bugs.webkit.org/show_bug.cgi?id=105969

Reviewed by Alexey Proskuryakov.

- Removes WebProcess::isSeparateProcess()
- Stop storing a RunLoop on the WebProcess and just use RunLoop::main().

* WebProcess/Network/NetworkProcessConnection.cpp:
(WebKit::NetworkProcessConnection::NetworkProcessConnection):
* WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
(WebKit::NPRuntimeObjectMap::NPRuntimeObjectMap):
* WebProcess/Plugins/PluginProcessConnection.cpp:
(WebKit::PluginProcessConnection::PluginProcessConnection):
* WebProcess/WebPage/DrawingAreaImpl.cpp:
(WebKit::DrawingAreaImpl::DrawingAreaImpl):
* WebProcess/WebPage/PageOverlay.cpp:
(WebKit::PageOverlay::PageOverlay):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage):
(WebKit::WebPage::close):
* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::initializeConnection):
(WebKit::WebProcess::shouldTerminate):
(WebKit::WebProcess::terminate):
(WebKit::WebProcess::didClose):
* WebProcess/WebProcess.h:
(WebProcess):
* WebProcess/efl/WebProcessMainEfl.cpp:
(WebKit::WebProcessMainEfl):
* WebProcess/gtk/WebProcessMainGtk.cpp:
(WebKit::WebProcessMainGtk):
* WebProcess/mac/WebProcessInitialization.mm:
(WebKit::initializeWebProcess):
* WebProcess/qt/WebProcessMainQt.cpp:
(WebKit::WebProcessMainQt):
* WebProcess/win/WebProcessMainWin.cpp:
(WebKit::WebProcessMain):

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

9 years ago[V8] V8DOMWrapper.cpp has many more includes than necessary
abarth@webkit.org [Thu, 3 Jan 2013 01:04:29 +0000 (01:04 +0000)]
[V8] V8DOMWrapper.cpp has many more includes than necessary
https://bugs.webkit.org/show_bug.cgi?id=105968

Reviewed by Kentaro Hara.

Now that this file isn't in charge of doing everything under the sun,
it can have a more focused set of include directives.

* bindings/v8/V8DOMWrapper.cpp:

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

9 years ago[EFL][CMAKE] Remove duplicated conditionals
gyuyoung.kim@samsung.com [Thu, 3 Jan 2013 01:00:35 +0000 (01:00 +0000)]
[EFL][CMAKE] Remove duplicated conditionals
https://bugs.webkit.org/show_bug.cgi?id=105905

Reviewed by Laszlo Gombos.

.:

* Source/cmake/OptionsEfl.cmake: Remove set(WTF_USE_GLX 1).

Source/WebCore:

Remove conditionals from CMake build system, where the files being built are already wrapped with
the conditionals. It just messes cmake file up.

* PlatformEfl.cmake:

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

9 years agoAX: Chromium needs platform localized strings for media controls.
commit-queue@webkit.org [Thu, 3 Jan 2013 00:55:59 +0000 (00:55 +0000)]
AX: Chromium needs platform localized strings for media controls.
https://bugs.webkit.org/show_bug.cgi?id=105940

Patch by David Tseng <dtseng@google.com> on 2013-01-02
Reviewed by Tony Chang.

Source/Platform:

* chromium/public/WebLocalizedString.h:

Source/WebKit/chromium:

* src/LocalizedStrings.cpp:
(WebCore::localizedMediaControlElementString):
(WebCore):
(WebCore::localizedMediaControlElementHelpText):

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

9 years ago Release build fix.
ap@apple.com [Thu, 3 Jan 2013 00:53:34 +0000 (00:53 +0000)]
    Release build fix.

        * platform/network/cf/FormDataStreamCFNet.cpp: (WebCore::formFinalize):
        Use ASSERT_UNUSED for an otherwise unused variable.

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

9 years agoUnreviewed, rolling out r138661.
tony@chromium.org [Thu, 3 Jan 2013 00:43:42 +0000 (00:43 +0000)]
Unreviewed, rolling out r138661.
http://trac.webkit.org/changeset/138661
https://bugs.webkit.org/show_bug.cgi?id=104740

Compile problems on EFL

.:

* Source/cmake/WebKitMacros.cmake:

Source/WebCore:

* CMakeLists.txt:
* DerivedSources.make:
* DerivedSources.pri:
* GNUmakefile.am:
* UseJSC.cmake:
* UseV8.cmake:
* WebCore.gyp/WebCore.gyp:
* WebCore.gypi:
* WebCore.vcproj/WebCoreTestSupport.vcproj:
* WebCore.xcodeproj/project.pbxproj:
* bindings/scripts/CodeGenerator.pm:
(IDLFileForInterface):
* page/make_settings.pl:
(generateCode):
(generateHeader):
(printGetterAndSetter):
(printInitializer):
* testing/InternalSettings.cpp:
(WebCore::InternalSettings::Backup::Backup):
(WebCore::InternalSettings::Backup::restoreTo):
(WebCore::InternalSettings::from):
(WebCore::InternalSettings::InternalSettings):
(WebCore::InternalSettings::reset):
(WebCore::InternalSettings::setPasswordEchoEnabled):
(WebCore):
(WebCore::InternalSettings::setPasswordEchoDurationInSeconds):
* testing/InternalSettings.h:
(Backup):
(InternalSettings):
* testing/InternalSettings.idl:
* testing/js/WebCoreTestSupport.cpp:
(WebCoreTestSupport::resetInternalsObject):
* testing/v8/WebCoreTestSupport.cpp:
(WebCoreTestSupport::resetInternalsObject):

Tools:

* GNUmakefile.am:
* qmake/mkspecs/features/default_post.prf:

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

9 years ago[V8] There are some extra blank lines after removing INC_STATS
abarth@webkit.org [Thu, 3 Jan 2013 00:30:50 +0000 (00:30 +0000)]
[V8] There are some extra blank lines after removing INC_STATS
https://bugs.webkit.org/show_bug.cgi?id=105964

Reviewed by Ojan Vafai.

This patch is a followup to http://trac.webkit.org/changeset/138665
that removes some extra blank lines that sed wasn't smart enough to
delete for us.

* bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
(WebCore::V8CSSStyleDeclaration::namedPropertyQuery):
* bindings/v8/custom/V8DOMFormDataCustom.cpp:
(WebCore::V8DOMFormData::appendCallback):
* bindings/v8/custom/V8DOMWindowCustom.cpp:
(WebCore::V8DOMWindow::addEventListenerCallback):
(WebCore::V8DOMWindow::removeEventListenerCallback):
(WebCore::V8DOMWindow::postMessageCallback):
* bindings/v8/custom/V8DedicatedWorkerContextCustom.cpp:
(WebCore::V8DedicatedWorkerContext::postMessageCallback):
* bindings/v8/custom/V8DocumentCustom.cpp:
(WebCore::V8Document::evaluateCallback):
* bindings/v8/custom/V8GeolocationCustom.cpp:
(WebCore::V8Geolocation::getCurrentPositionCallback):
(WebCore::V8Geolocation::watchPositionCallback):
* bindings/v8/custom/V8HTMLAllCollectionCustom.cpp:
(WebCore::V8HTMLAllCollection::namedPropertyGetter):
* bindings/v8/custom/V8HTMLCollectionCustom.cpp:
(WebCore::V8HTMLCollection::namedPropertyGetter):
* bindings/v8/custom/V8HTMLFormControlsCollectionCustom.cpp:
(WebCore::V8HTMLFormControlsCollection::namedPropertyGetter):
* bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
(WebCore::v8HTMLImageElementConstructorCallback):
* bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
(WebCore::V8HTMLOptionsCollection::namedPropertyGetter):
* bindings/v8/custom/V8MessagePortCustom.cpp:
(WebCore::V8MessagePort::postMessageCallback):
* bindings/v8/custom/V8NamedNodeMapCustom.cpp:
(WebCore::V8NamedNodeMap::namedPropertyGetter):
* bindings/v8/custom/V8NotificationCustom.cpp:
(WebCore::V8Notification::requestPermissionCallback):
* bindings/v8/custom/V8PopStateEventCustom.cpp:
(WebCore::V8PopStateEvent::stateAccessorGetter):
* bindings/v8/custom/V8SQLResultSetRowListCustom.cpp:
(WebCore::V8SQLResultSetRowList::itemCallback):
* bindings/v8/custom/V8SQLTransactionCustom.cpp:
(WebCore::V8SQLTransaction::executeSqlCallback):
* bindings/v8/custom/V8SQLTransactionSyncCustom.cpp:
(WebCore::V8SQLTransactionSync::executeSqlCallback):
* bindings/v8/custom/V8StorageCustom.cpp:
(WebCore::V8Storage::namedPropertyQuery):
* bindings/v8/custom/V8StyleSheetListCustom.cpp:
(WebCore::V8StyleSheetList::namedPropertyGetter):
* bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
(WebCore::V8WebGLRenderingContext::getAttachedShadersCallback):
(WebCore::V8WebGLRenderingContext::getFramebufferAttachmentParameterCallback):
(WebCore::V8WebGLRenderingContext::getParameterCallback):
(WebCore::V8WebGLRenderingContext::getProgramParameterCallback):
(WebCore::V8WebGLRenderingContext::getShaderParameterCallback):
(WebCore::V8WebGLRenderingContext::getUniformCallback):
* bindings/v8/custom/V8WorkerCustom.cpp:
(WebCore::V8Worker::postMessageCallback):

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

9 years ago [WK2 NetworkProcess] Uploading fails if a client modified the request
ap@apple.com [Thu, 3 Jan 2013 00:26:37 +0000 (00:26 +0000)]
    [WK2 NetworkProcess] Uploading fails if a client modified the request
        https://bugs.webkit.org/show_bug.cgi?id=105965

        Reviewed by Brady Eidson.

        Associating streams with additional information via a side HashMap does not work,
        because the stream we can see is an internal one, with address and other information
        not matching a stream that we created.

        It's surprising that this design issue was not causing major trouble without NetworkProcess.

        * platform/network/cf/FormDataStreamCFNet.cpp:
        (WebCore): Renamed FormContext to FormCreationContext, because this type only used
        for creation. Later, we use FormStreamFields as context.
        (WebCore::closeCurrentStream): Moved a star.
        (WebCore::formCreate): We no longer have a side map to keep updated.
        (WebCore::formFinalize): Ditto.
        (WebCore::formCopyProperty): Added an accessor to get FormData pointer from a stream.
        (WebCore::setHTTPBody): Ditto.
        (WebCore::httpBodyFromStream): Use the new property to get FormData pointer.

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

9 years agoSome renaming in the CodeCache
ggaren@apple.com [Thu, 3 Jan 2013 00:25:26 +0000 (00:25 +0000)]
Some renaming in the CodeCache
https://bugs.webkit.org/show_bug.cgi?id=105966

Reviewed by Gavin Barraclough.

CodeBlockKey => SourceCodeKey because the key is not a CodeBlock.

m_recentlyUsedFunctionCode => m_recentlyUsedFunctions to match other names.

GlobalFunctionKey => FunctionKey because the key is not unique to globalness.

m_cachedGlobalFunctions => m_globalFunctions because "cached" is redundant
for data members in an object called "CodeCache".

kMaxRootCodeBlockEntries => kMaxRootEntries because there are no non-CodeBlock
entries in a CodeBlock cache.

kMaxFunctionCodeBlocks => kMaxChildFunctionEntries to clarify that this
number models a parent-child relationship.

Also removed the initial "k" from enum constants. That's an interesting
style for calling out constants, but it's not the WebKit style.

Finally, a behavior change: Use MaxRootEntries for the limit on global
functions, and not MaxChildFunctionEntries. Previously, there was an
unused constant that seemed to have been intended for this purpose.

* runtime/CodeCache.cpp:
(JSC::CodeCache::makeSourceCodeKey):
(JSC::CodeCache::getCodeBlock):
(JSC::CodeCache::generateFunctionCodeBlock):
(JSC::CodeCache::makeFunctionKey):
(JSC::CodeCache::getFunctionExecutableFromGlobalCode):
(JSC::CodeCache::usedFunctionCode):
* runtime/CodeCache.h:
(JSC::CodeCache::clear):

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

9 years agoClean up dispatchEvent overrides and overloads
esprehn@chromium.org [Thu, 3 Jan 2013 00:21:33 +0000 (00:21 +0000)]
Clean up dispatchEvent overrides and overloads
https://bugs.webkit.org/show_bug.cgi?id=105959

Reviewed by Adam Barth.

Add OVERRIDE to all dispatchEvent overrides and use "using" instead of
reimplementing EventTarget::dispatchEvent in subclasses where having the
virtual override of dispatchEvent hides the overloads in
the superclass.

No new tests, just refactoring.

* Modules/indexeddb/IDBDatabase.h:
(IDBDatabase):
* Modules/indexeddb/IDBOpenDBRequest.h:
(IDBOpenDBRequest):
* Modules/indexeddb/IDBRequest.h:
(IDBRequest):
* Modules/indexeddb/IDBTransaction.h:
(IDBTransaction):
* dom/EventDispatchMediator.h:
(FocusEventDispatchMediator):
(BlurEventDispatchMediator):
* dom/GestureEvent.h:
(GestureEventDispatchMediator):
* dom/KeyboardEvent.h:
(KeyboardEventDispatchMediator):
* dom/MouseEvent.h:
* dom/Node.h:
(Node):
* dom/UIEvent.h:
(FocusInEventDispatchMediator):
(FocusOutEventDispatchMediator):
* dom/WheelEvent.h:
(WheelEventDispatchMediator):
* html/HTMLMediaElement.h:
* html/track/TextTrackCue.cpp:
* html/track/TextTrackCue.h:
(TextTrackCue):
* page/DOMWindow.h:
(DOMWindow):
* svg/SVGElementInstance.h:
(SVGElementInstance):

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

9 years ago[Chromium] Add Platform/chromium to include_dirs
pilgrim@chromium.org [Thu, 3 Jan 2013 00:08:50 +0000 (00:08 +0000)]
[Chromium] Add Platform/chromium to include_dirs
https://bugs.webkit.org/show_bug.cgi?id=105955

Reviewed by James Robinson.

Currently the headers in WebKit/chromium/public/Web*.h can not
include headers from the new Platform/chromium/ directory with the
"#include <public/WebFoo.h>" syntax, because the include_dirs for
dependent builds (like Chromium-within-WebKit) do not include the
new Platform/chromium/ directory. This patch adds that capability
without managing to break anything else.

* WebKit.gyp:

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

9 years agoIndexedDB: Surface a few more leveldb errors.
dgrogan@chromium.org [Wed, 2 Jan 2013 23:55:40 +0000 (23:55 +0000)]
IndexedDB: Surface a few more leveldb errors.
https://bugs.webkit.org/show_bug.cgi?id=105670

Reviewed by Tony Chang.

Two calls to old LevelDBTransaction::get slipped through the cracks.

* Modules/indexeddb/IDBBackingStore.cpp:
(WebCore::IndexKeyCursorImpl::loadCurrentRow):
(WebCore::IndexCursorImpl::loadCurrentRow):
  Make these two functions use safeGet instead of get.

* platform/leveldb/LevelDBTransaction.cpp:
* platform/leveldb/LevelDBTransaction.h:
  Remove get now that it is unused.

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

9 years agoDFG inlining machinery should be robust against the inline callee varying while the...
fpizlo@apple.com [Wed, 2 Jan 2013 23:54:42 +0000 (23:54 +0000)]
DFG inlining machinery should be robust against the inline callee varying while the executable stays the same
https://bugs.webkit.org/show_bug.cgi?id=105953

Reviewed by Mark Hahnenberg.

This institutes the policy that if InlineCallFrame::callee is null, then the callee and scope have already
been stored into the true call frame (i.e. the place where the call frame of the inlined call would have
been) and so any attempt to access the callee or scope should do a load instead of assuming that the value
is constant. This wires the changes through the bytecode parser, the stack scanning logic, and the compiler
optimization phases and backends.

* bytecode/CodeOrigin.cpp:
(JSC::InlineCallFrame::dump):
* bytecode/CodeOrigin.h:
(CodeOrigin):
(InlineCallFrame):
(JSC::InlineCallFrame::isClosureCall):
(JSC::CodeOrigin::stackOffset):
(JSC):
* dfg/DFGAssemblyHelpers.h:
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::get):
(InlineStackEntry):
(JSC::DFG::ByteCodeParser::getScope):
(JSC::DFG::ByteCodeParser::InlineStackEntry::InlineStackEntry):
* dfg/DFGCSEPhase.cpp:
(CSEPhase):
(JSC::DFG::CSEPhase::genericPureCSE):
(JSC::DFG::CSEPhase::pureCSE):
(JSC::DFG::CSEPhase::pureCSERequiringSameInlineCallFrame):
(JSC::DFG::CSEPhase::getMyScopeLoadElimination):
(JSC::DFG::CSEPhase::performNodeCSE):
* dfg/DFGOSRExitCompiler32_64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGOSRExitCompiler64.cpp:
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* interpreter/CallFrame.cpp:
(JSC::CallFrame::trueCallFrame):

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

9 years agoWhen a block's height is determined by min-height/max-height, children with percentag...
commit-queue@webkit.org [Wed, 2 Jan 2013 23:54:21 +0000 (23:54 +0000)]
When a block's height is determined by min-height/max-height, children with percentage heights are sized incorrectly
https://bugs.webkit.org/show_bug.cgi?id=26559

Patch by Bem Jones-Bey <bjonesbe@adobe.com> on 2013-01-02
Reviewed by Tony Chang.

Source/WebCore:

Percentage logical height computation now takes into account the min and max height of the container.

Test: fast/block/min-max-height-percent-height-child.html

* rendering/RenderBox.cpp:
(WebCore::RenderBox::constrainContentBoxLogicalHeightByMinMax): Added. Like constrainLogicalHeightByMinMax,
    but constrains the content box instead of the border box.
(WebCore):
(WebCore::RenderBox::computeContentLogicalHeight): Make const so it can be called from the const method
    constrainContentBoxLogicalHeightByMinMax.
(WebCore::RenderBox::computePercentageLogicalHeight): Use constrainContentBoxLogicalHeightByMinMax to properly
    respect min and max height on the containing box when computing the percentage height.
* rendering/RenderBox.h:
(RenderBox):

LayoutTests:

Add tests to ensure percent heights are correctly determined.

* fast/block/min-max-height-percent-height-child-expected.txt: Added.
* fast/block/min-max-height-percent-height-child.html: Added.

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

9 years agoUnreviewed, force InternalSettings.cpp to rebuild to try and fix the Apple Win build.
tony@chromium.org [Wed, 2 Jan 2013 23:51:20 +0000 (23:51 +0000)]
Unreviewed, force InternalSettings.cpp to rebuild to try and fix the Apple Win build.

* testing/InternalSettings.cpp:

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