WebKit-https.git
6 years ago[GTK] Enable skipped http/tests/media/hls/video-controls-live-stream.html
calvaris@igalia.com [Thu, 8 May 2014 10:28:37 +0000 (10:28 +0000)]
[GTK] Enable skipped http/tests/media/hls/video-controls-live-stream.html
https://bugs.webkit.org/show_bug.cgi?id=132329

Reviewed by Eric Carlson.

Source/WebCore:
GTK port needed to define what happened with live stream media
controls. Now we disable and dim the timeline and tweak the
timers.

Test: http/tests/media/hls/video-controls-live-stream.html.

* Modules/mediacontrols/mediaControlsGtk.js:
(ControllerGtk.prototype.configureControls): Moved logic from
setControlsType and changed to use an early return.
(ControllerGtk.prototype.reconnectControls): Redefined to just
configure the controls.
(ControllerGtk.prototype.handlePlay): If stream is live we don't
activate the current time just in case.
(ControllerGtk.prototype.updateDuration): Calls the superclass and
sets timeline.max to 0.
(ControllerGtk.prototype.setControlsType): Deleted.
(ControllerGtk.prototype.setIsLive): Configures controls and
disables the timeline if stream is live.
* css/mediaControlsGtk.css:
(audio::-webkit-media-controls-timeline[disabled])
(video::-webkit-media-controls-timeline[disabled]): Dimmed the
timeline by setting opacity to 0.3.

LayoutTests:
Tweaked test, created GTK results, unskipped in GTK and moved the
current general expectations to be mac only.

* http/tests/media/hls/video-controls-live-stream-expected.txt:
Moved.
* http/tests/media/hls/video-controls-live-stream.html: Dump tree
and check status of the timelime.
* media/media-controls.js:
(dumpMediaControlsTree): Added to dump the shadow dom tree.
* platform/gtk/TestExpectations: Unskipped video-controls-live-stream.
* platform/gtk/http/tests/media/hls/video-controls-live-stream-expected.txt: Added.
* platform/mac/http/tests/media/hls/video-controls-live-stream-expected.txt:
Moved from
LayoutTests/http/tests/media/hls/video-controls-live-stream-expected.txt
and rebaselined.

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

6 years ago[CSS Regions] Content overflowing a fixed positioned region is clipped
mihnea@adobe.com [Thu, 8 May 2014 08:42:44 +0000 (08:42 +0000)]
[CSS Regions] Content overflowing a fixed positioned region is clipped
https://bugs.webkit.org/show_bug.cgi?id=118607

Reviewed by Andrei Bucur.

Fixed by the overflow in regions work, add test to prevent future regressions.

* fast/regions/fixed-pos-region-overflow-content-expected.html: Added.
* fast/regions/fixed-pos-region-overflow-content.html: Added.

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

6 years ago[CSS Blending] Changing isolation CSS property should not trigger repaint in RenderSt...
commit-queue@webkit.org [Thu, 8 May 2014 08:16:31 +0000 (08:16 +0000)]
[CSS Blending] Changing isolation CSS property should not trigger repaint in RenderStyle::changeRequiresLayerRepaint
https://bugs.webkit.org/show_bug.cgi?id=131436

Patch by Ion Rosca <rosca@adobe.com> on 2014-05-08
Reviewed by Dirk Schulze.

Source/WebCore:
The isolation:isolate property will create a stacking context. This is done in
StyleResolver::adjustRenderStyle where z-index is forced to 0.
If the element is already a stacking context for any other reason,
changing the isolation flag should not have any effect.

Tests: css3/blending/repaint/blend-mode-turn-off-isolation-no-effect.html
       css3/blending/repaint/blend-mode-turn-off-isolation.html

* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::changeRequiresLayerRepaint):
do not request repaint if isolation has changed.

LayoutTests:
* css3/blending/repaint/blend-mode-turn-off-isolation-expected.txt: Added.
* css3/blending/repaint/blend-mode-turn-off-isolation-no-effect-expected.txt: Added.
* css3/blending/repaint/blend-mode-turn-off-isolation-no-effect.html: Added.
* css3/blending/repaint/blend-mode-turn-off-isolation.html: Added.

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

6 years agoREGRESSION (r167652): SelectionState is not set properly for non leaf objects in...
rego@igalia.com [Thu, 8 May 2014 08:05:58 +0000 (08:05 +0000)]
REGRESSION (r167652): SelectionState is not set properly for non leaf objects in pages with regions
https://bugs.webkit.org/show_bug.cgi?id=132493

Reviewed by David Hyatt.

Source/WebCore:
Non selection leaf elements were not included in the selection ranges,
that was causing that their selection state was not set properly and
when one of the element was removed as it was marked as SelectionNone
current selection was not removed.

Due to this fix, the regression detected in bug #131982 arose again.
Reverted changes from r167675 and reopened bug as previous fix was not
right. Updated TestExpectations accordingly.

Test: fast/regions/selection/crash-select-all.html

* rendering/RenderView.cpp:
(WebCore::RenderView::splitSelectionBetweenSubtrees): We need to include
non selection leafs in the range, otherwise we won't be marking
selection state of some elements properly.

LayoutTests:
* TestExpectations: Marked
fast/regions/cssom/region-range-for-box-crash.html as crashing on
debug due to regression detected in bug #131982.
* fast/regions/selection/crash-select-all-expected.txt: Added.
* fast/regions/selection/crash-select-all.html: Added.

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

6 years ago[CSS Shapes] Can't select content within the area of the floating box when clip-path...
zoltan@webkit.org [Thu, 8 May 2014 07:57:10 +0000 (07:57 +0000)]
[CSS Shapes] Can't select content within the area of the floating box when clip-path is applied
https://bugs.webkit.org/show_bug.cgi?id=131375

Reviewed by Dirk Schulze.

Source/WebCore:
According to http://www.w3.org/TR/css-masking-1/, the clipped part of the element should
not have pointer event dispatching. So add this logic to RenderBlock::nodeAtPoint. This
fixes the bug as it disallows selection on any clipped parts.

I implemented the proper selection for the various CSS box types and added testing
for them. Also, I made and run performance tests for exposing mouse events over the
clipped/non-clipped area, which results can be seen in bugzilla.

Based on the patch made by Rob Buis <rob.buis@samsung.com>
Blink revision: http://src.chromium.org/viewvc/blink?view=revision&revision=172619

Tests: fast/masking/clip-path-selection.html
       fast/shapes/shape-outside-floats/shape-outside-clip-path-selection.html

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::nodeAtPoint):

LayoutTests:
* fast/masking/clip-path-selection-expected.txt: Added.
* fast/masking/clip-path-selection.html: Added.
* fast/shapes/shape-outside-floats/shape-outside-clip-path-selection-expected.txt: Added.
* fast/shapes/shape-outside-floats/shape-outside-clip-path-selection.html: Added.

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

6 years ago[CSS Blending] Blending doesn't work if the parent stacking context is not a self...
commit-queue@webkit.org [Thu, 8 May 2014 05:42:21 +0000 (05:42 +0000)]
[CSS Blending] Blending doesn't work if the parent stacking context is not a self painting layer
https://bugs.webkit.org/show_bug.cgi?id=130891

Patch by Ion Rosca <rosca@adobe.com> on 2014-05-07
Reviewed by Dean Jackson.

Source/WebCore:
The stacking context layers having unisolated blending descendants should be able
to create transparency layers or to become composited in order to restrict blending
content to accessing the information outside the current stacking context.
Some layers are not self painting layers and these layers cannot crate transparency
layers and cannot be composited, thus they are not able to isolate blending descendants
when it's required.

The solution in this patch is to make a layer isSelfPaintingLayer when
it needs to isolate blending descendants (hasUnisolatedBlendingDescendants).

Tests: css3/blending/blend-mode-isolation-accelerated-overflow-hidden.html
       css3/blending/blend-mode-isolation-overflow-hidden.html
       css3/blending/blend-mode-isolation-turn-off-self-painting-layer.html
       css3/blending/blend-mode-isolation-turn-off-self-painting-layer1.html
       css3/blending/blend-mode-isolation-turn-off-self-painting-layer2.html
       css3/blending/blend-mode-isolation-turn-on-self-painting-layer.html

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::updateAncestorChainHasBlendingDescendants):
When hasUnisolatedBlendingDescendants is set we make sure that isSelfPaintingLayer flag is set too.
(WebCore::RenderLayer::updateDescendantDependentFlags):
The flags might be read or changed while walking the descendants, so we don't want to reset
them before traversing the tree.
(WebCore::RenderLayer::shouldBeSelfPaintingLayer):
Adding isolatesBlending() condition for a layer to be self painting.
* rendering/RenderLayer.h:
Removing ASSERT from hasUnisolatedBlendingDescendants(). It crashes in minibrowser
and in layout tests when painting contents. Similar bugs on other flags: #71044, #71277.
* rendering/RenderLayerModelObject.cpp:
(WebCore::RenderLayerModelObject::styleDidChange):
Telling ancestors that blend mode property has been removed from CSS when the layer for
this element is going to be removed; styleChanged will not be called anymore.

LayoutTests:
Removed position:relative which forced tests to avoid this bug.
* css3/blending/blend-mode-accelerated-parent-overflow-hidden.html:
* css3/blending/blend-mode-clip-accelerated-blending-canvas.html:
* css3/blending/blend-mode-clip-accelerated-blending-child.html:
* css3/blending/blend-mode-clip-accelerated-blending-with-siblings.html:
* css3/blending/blend-mode-clip-accelerated-transformed-blending.html:

New tests:
* css3/blending/blend-mode-isolation-accelerated-overflow-hidden-expected.txt: Added.
* css3/blending/blend-mode-isolation-accelerated-overflow-hidden.html: Added.
* css3/blending/blend-mode-isolation-overflow-hidden-expected.html: Added.
* css3/blending/blend-mode-isolation-overflow-hidden.html: Added.
* css3/blending/blend-mode-isolation-turn-off-self-painting-layer-expected.txt: Added.
* css3/blending/blend-mode-isolation-turn-off-self-painting-layer.html: Added.
* css3/blending/blend-mode-isolation-turn-off-self-painting-layer1-expected.txt: Added.
* css3/blending/blend-mode-isolation-turn-off-self-painting-layer1.html: Added.
* css3/blending/blend-mode-isolation-turn-off-self-painting-layer2-expected.txt: Added.
* css3/blending/blend-mode-isolation-turn-off-self-painting-layer2.html: Added.
* css3/blending/blend-mode-isolation-turn-on-self-painting-layer-expected.txt: Added.
* css3/blending/blend-mode-isolation-turn-on-self-painting-layer.html: Added.

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

6 years agoUnreviewed, rolling out r168451.
commit-queue@webkit.org [Thu, 8 May 2014 04:10:21 +0000 (04:10 +0000)]
Unreviewed, rolling out r168451.
https://bugs.webkit.org/show_bug.cgi?id=132670

Not a speed-up, just do what other compilers do. (Requested by
kling on #webkit).

Reverted changeset:

"[X86] Emit BT instruction for single-bit tests."
https://bugs.webkit.org/show_bug.cgi?id=132650
http://trac.webkit.org/changeset/168451

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

6 years agoDragging text from one paragraph to another does not render as expected
mmaxfield@apple.com [Thu, 8 May 2014 02:51:55 +0000 (02:51 +0000)]
Dragging text from one paragraph to another does not render as expected
https://bugs.webkit.org/show_bug.cgi?id=132633

Reviewed by Darin Adler and Ryosuke Niwa.

Source/WebCore:
When we are dragging and dropping into a content editable field, we detect
if we are trying to put a <p> into an existing <p>, and if so, split the
outer <p> and insert the new <p> as its sibling. However, the outer <p>
might not be editable, so we don't want to do any splitting and inserting
at that location.

Test: editing/pasteboard/drag-drop-paragraph-crasher.html

* editing/ReplaceSelectionCommand.cpp:
(WebCore::ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder):

LayoutTests:
The problem occurs when dragging text that includes a <p> into an editable
area that has a <p> as a parent.

* editing/pasteboard/drag-drop-paragraph-crasher-expected.txt: Added.
* editing/pasteboard/drag-drop-paragraph-crasher.html: Added.

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

6 years agoSource/JavaScriptCore: Make Executable::clearCode() actually clear all of the entrypo...
fpizlo@apple.com [Thu, 8 May 2014 02:35:22 +0000 (02:35 +0000)]
Source/JavaScriptCore: Make Executable::clearCode() actually clear all of the entrypoints, and
clean up some other FTL-related calling convention stuff.
<rdar://problem/16720172>

Rubber stamped by Mark Hahnenberg.

* dfg/DFGOperations.cpp:
* dfg/DFGOperations.h:
* dfg/DFGWorklist.cpp:
(JSC::DFG::Worklist::Worklist):
(JSC::DFG::Worklist::finishCreation):
(JSC::DFG::Worklist::create):
(JSC::DFG::ensureGlobalDFGWorklist):
(JSC::DFG::ensureGlobalFTLWorklist):
* dfg/DFGWorklist.h:
* heap/CodeBlockSet.cpp:
(JSC::CodeBlockSet::dump):
* heap/CodeBlockSet.h:
* runtime/Executable.cpp:
(JSC::ExecutableBase::clearCode):

Source/WTF: UNREACHABLE_FOR_PLATFORM() is meant to be a release crash.

Rubber stamped by Mark Hahnenberg..

* wtf/Assertions.h:
(UNREACHABLE_FOR_PLATFORM):

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

6 years ago[CoordinatedGraphics][WK2] Scale factor and scroll position is not being restored...
gyuyoung.kim@samsung.com [Thu, 8 May 2014 01:42:17 +0000 (01:42 +0000)]
[CoordinatedGraphics][WK2] Scale factor and scroll position is not being restored properly in a back/forward load
https://bugs.webkit.org/show_bug.cgi?id=126022

Reviewed by Benjamin Poulain.

Original author : Thiago de Barros Lacerda, and finished by Gyuyoung Kim.

Source/WebCore:
When user is navigating back/forward to a page that has been scrolled and/or scaled, that page must be shown
with its last scroll position and scale factor. However, when fixed layout was enabled with CoordinatedGraphics
and TILED_BACKING_STORE, Page::setPageScaleFactor() doesn't send previous scroll position since r165652 and r165913.

This patch allows the Page::setPageScaleFactor() send stored position to WK2 implementation by calling delegatedScrollRequested()
directly when delegatesScrolling() is on.

* page/Page.cpp:
(WebCore::Page::setPageScaleFactor): TILED_BACKING_STORE and delegateScrolling are enabled, we pass new scroll position to WK2 though
delegateScrolling is disabled.
* platform/ScrollView.cpp: delegatedScrollRequested() call is moved from ScrollView::setScrollPosition() to Page::setPageScaleFactor().
(WebCore::ScrollView::setScrollPosition):

Source/WebKit2:
When user is navigating back/forward to a page that has been scrolled and/or scaled, that page must be shown
with its last scroll position and scale factor. However, when fixed layout was enabled with CoordinatedGraphics
and TILED_BACKING_STORE, Page::setPageScaleFactor() doesn't send previous scroll position since r165652 and r165913.

This patch allows the Page::setPageScaleFactor() send stored position to WK2 implementation.

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

Tools:
Added an unit test case to check if scroll position and scale are restored properly.

* TestWebKitAPI/PlatformEfl.cmake:
* TestWebKitAPI/Tests/WebKit2/CoordinatedGraphics/WKViewRestoreZoomAndScrollBackForward.cpp: Added.
(TestWebKitAPI::didFinishLoadForFrame):
(TestWebKitAPI::didChangeContentsPosition):
(TestWebKitAPI::TEST):
* TestWebKitAPI/Tests/WebKit2/CoordinatedGraphics/backforward1.html: Added.
* TestWebKitAPI/Tests/WebKit2/CoordinatedGraphics/backforward2.html: Added.

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

6 years agoUsing a fill pattern much larger than actual canvas reliably segfaults browser
dino@apple.com [Thu, 8 May 2014 01:30:21 +0000 (01:30 +0000)]
Using a fill pattern much larger than actual canvas reliably segfaults browser
https://bugs.webkit.org/show_bug.cgi?id=132635

Reviewed by Simon Fraser.

Source/WebCore:
Make sure that createPattern checks that the canvas it is about to use
as a source is valid.

Test: fast/canvas/pattern-too-large-to-create.html

* html/canvas/CanvasRenderingContext2D.cpp:
(WebCore::CanvasRenderingContext2D::createPattern): Check that the source canvas has
an ok ImageBuffer.

LayoutTests:
Test case that makes a huge canvas and tries to create a pattern out of it.

* fast/canvas/pattern-too-large-to-create-expected.html: Added.
* fast/canvas/pattern-too-large-to-create.html: Added.

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

6 years agoPut a better version of the assertion back, and add one when we ensureBackingStore.
simon.fraser@apple.com [Thu, 8 May 2014 01:16:53 +0000 (01:16 +0000)]
Put a better version of the assertion back, and add one when we ensureBackingStore.

Reviewed by Tim Horton.

* WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
(WebKit::PlatformCALayerRemote::recursiveBuildTransaction):
(WebKit::PlatformCALayerRemote::ensureBackingStore):

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

6 years agoThis assertion was wrong and fired every time. Remove it.
simon.fraser@apple.com [Thu, 8 May 2014 00:48:34 +0000 (00:48 +0000)]
This assertion was wrong and fired every time. Remove it.

* WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
(WebKit::PlatformCALayerRemote::recursiveBuildTransaction):

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

6 years ago[Win] Unreviewed 64-bit build fix.
bfulgham@apple.com [Thu, 8 May 2014 00:20:53 +0000 (00:20 +0000)]
[Win] Unreviewed 64-bit build fix.

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in: Add
correct 64-bit symbol definitions.

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

6 years agoREGRESSION (r161429?): Frequent crashes on media/track/media-element-enqueue-event...
ggaren@apple.com [Thu, 8 May 2014 00:07:07 +0000 (00:07 +0000)]
REGRESSION (r161429?): Frequent crashes on media/track/media-element-enqueue-event-crash.html
https://bugs.webkit.org/show_bug.cgi?id=117756

Reviewed by Mark Hahnenberg.

Re-enabled this test because it doesn't seem to crash anymore.

* media/track/media-element-enqueue-event-crash.html: Reduced the number
of test runs because otherwise this test often times out.

* platform/mac/TestExpectations: Re-enable this test because I ran it
for about a minute on my Mac Pro without crashing.

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

6 years agoUse system defaults for hardware jpeg decoding
psolanki@apple.com [Wed, 7 May 2014 23:28:50 +0000 (23:28 +0000)]
Use system defaults for hardware jpeg decoding
https://bugs.webkit.org/show_bug.cgi?id=132661
<rdar://problem/11348201>

Reviewed by Tim Horton.

Remove code that explicitly disabled hardware image decoding. Let the system decide what to do.

Source/WebCore:
* WebCore.exp.in:
* platform/graphics/ImageSource.h:
(WebCore::ImageSource::acceleratedImageDecodingEnabled): Deleted.
(WebCore::ImageSource::setAcceleratedImageDecodingEnabled): Deleted.
* platform/graphics/cg/ImageSourceCG.cpp:
(WebCore::ImageSource::imageSourceOptions):

Source/WebKit/mac:
* WebView/WebView.mm:
(+[WebView _setAcceleratedImageDecoding:]):
(+[WebView _acceleratedImageDecoding]): Deleted.
* WebView/WebViewPrivate.h:

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

6 years ago[X86] Emit BT instruction for single-bit tests.
akling@apple.com [Wed, 7 May 2014 23:22:07 +0000 (23:22 +0000)]
[X86] Emit BT instruction for single-bit tests.
<https://webkit.org/b/132650>

Implement test-bit-and-branch slightly more efficiently by using
BT + JC/JNC instead of TEST + JZ/JNZ when we're only testing for
a single bit.

Reviewed by Michael Saboff.

* assembler/MacroAssemblerX86Common.h:
(JSC::MacroAssemblerX86Common::singleBitIndex):
(JSC::MacroAssemblerX86Common::branchTest32):
* assembler/X86Assembler.h:
(JSC::X86Assembler::bt_i8r):
(JSC::X86Assembler::bt_i8m):

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

6 years agoUse after free in WebCore::RenderObject::nextSibling / WebCore::RenderBoxModelObject...
stavila@adobe.com [Wed, 7 May 2014 22:48:31 +0000 (22:48 +0000)]
Use after free in WebCore::RenderObject::nextSibling / WebCore::RenderBoxModelObject::moveChildrenTo
https://bugs.webkit.org/show_bug.cgi?id=132625

Reviewed by David Hyatt.

Source/WebCore:
Fixed problem with dynamically inserting first letter elements.

Test: fast/multicol/newmulticol/first-letter-create.html

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::getFirstLetter):
(WebCore::RenderBlock::updateFirstLetter):
* rendering/RenderBlock.h:
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::moveChildrenTo):

LayoutTests:
Added test for special case which might cause use after free.

* fast/multicol/newmulticol/first-letter-create-expected.html: Added.
* fast/multicol/newmulticol/first-letter-create.html: Added.

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

6 years agoWK2: Programatic scroll requests during scroll or zoom animation to reveal focused...
enrica@apple.com [Wed, 7 May 2014 22:42:46 +0000 (22:42 +0000)]
WK2: Programatic scroll requests during scroll or zoom animation to reveal focused element are ignored.
https://bugs.webkit.org/show_bug.cgi?id=132657
<rdar://problem/16468462>

Reviewed by Benjamin Poulain.

With the scrolling model we use on iOS, a programatic scroll
request can be received while we are still animating to reveal

Source/WebCore:
the focused input element. The WebProcess is unaware that the
scroll position is being changed in the UIProcess, and does not
honor the scroll request from JavaScript.
This is patch changes the behavior for clients using scroll delegates
to always send the scroll request to the UIProcess without checking
the current scroll position.

* page/FrameView.h:
* platform/ScrollView.cpp:
(WebCore::ScrollView::setScrollPosition):
* platform/ScrollView.h:
(WebCore::ScrollView::inProgrammaticScroll):

Source/WebKit2:
the focused input element. Changing the scroll offset while animating
leads to unpredictable results. We now cancel the animation if
a programatic scroll request is received.

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _scrollToContentOffset:WebCore::]):
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::getAssistedNodeInformation):

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

6 years ago[iOS WK2] Speculative fix for crash in PlatformCALayerRemote::recursiveBuildTransaction
simon.fraser@apple.com [Wed, 7 May 2014 22:15:08 +0000 (22:15 +0000)]
[iOS WK2] Speculative fix for crash in PlatformCALayerRemote::recursiveBuildTransaction
https://bugs.webkit.org/show_bug.cgi?id=132666

Reviewed by Tim Horton.

Crash reports suggest that owner() can be null. Assert and protect
against this.

* WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
(WebKit::PlatformCALayerRemote::recursiveBuildTransaction):

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

6 years agoREGRESSION(r166678): Dromaeo/cssquery-dojo.html crashes regularly.
mark.lam@apple.com [Wed, 7 May 2014 22:00:10 +0000 (22:00 +0000)]
REGRESSION(r166678): Dromaeo/cssquery-dojo.html crashes regularly.
<https://webkit.org/b/131356>

Reviewed by Geoffrey Garen.

The issue is that GC needs to be made aware of writes to m_inferredValue
in the VariableWatchpointSet, but was not.  As a result, if a JSCell*
is written to a VariableWatchpointSet m_inferredValue, and that JSCell
does not survive an eden GC shortly after, we will end up with a stale
JSCell pointer left in the m_inferredValue.

This issue can be detected more easily by running Dromaeo/cssquery-dojo.html
using DumpRenderTree with the VM heap in zombie mode.

The fix is to change VariableWatchpointSet m_inferredValue to type
WriteBarrier<Unknown> and ensure that VariableWatchpointSet::notifyWrite()
is executed by all the execution engines so that the WriteBarrier semantics
are honored.

We still check if the value to be written is the same as the one in the
inferredValue.  We'll by-pass calling the slow path notifyWrite() if the
values are the same.

* JavaScriptCore.xcodeproj/project.pbxproj:
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::CodeBlock):
- need to pass the symbolTable to prepareToWatch() because it will be needed
  for instantiating the VariableWatchpointSet in prepareToWatch().

* bytecode/VariableWatchpointSet.h:
(JSC::VariableWatchpointSet::VariableWatchpointSet):
- VariableWatchpointSet now tracks its owner symbol table for its m_inferredValue
  write barrier, and yes, m_inferredValue is now of type WriteBarrier<Unknown>.
(JSC::VariableWatchpointSet::inferredValue):
(JSC::VariableWatchpointSet::invalidate):
(JSC::VariableWatchpointSet::finalizeUnconditionally):
(JSC::VariableWatchpointSet::addressOfInferredValue):
(JSC::VariableWatchpointSet::notifyWrite): Deleted.
* bytecode/VariableWatchpointSetInlines.h: Added.
(JSC::VariableWatchpointSet::notifyWrite):

* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::cellConstant):
- Added an assert in case we try to make constants of zombified JSCells again.

* dfg/DFGOperations.cpp:
* dfg/DFGOperations.h:
* dfg/DFGSpeculativeJIT.h:
(JSC::DFG::SpeculativeJIT::callOperation):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
- We now let the slow path handle the cases when the VariableWatchpointSet is
  in state ClearWatchpoint and IsWatched, and the slow path will ensure that
  we handle the needed write barrier semantics correctly.
  We will by-pass the slow path if the value being written is the same as the
  inferred value.

* ftl/FTLIntrinsicRepository.h:
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::compileNotifyWrite):
- Let the slow path handle the cases when the VariableWatchpointSet is
  in state ClearWatchpoint and IsWatched.
  We will by-pass the slow path if the value being written is the same as the
  inferred value.

* heap/Heap.cpp:
(JSC::Zombify::operator()):
- Use a different value for the zombified bits (to distinguish it from 0xbbadbeef
  which is used everywhere else).
* heap/Heap.h:
(JSC::Heap::isZombified):
- Provide a convenience test function to check if JSCells are zombified.  This is
  currently only used in an assertion in the DFG bytecode parser, but the intent
  it that we'll apply this test in other strategic places later to help with early
  detection of usage of GC'ed objects when we run in zombie mode.

* jit/JITOpcodes.cpp:
(JSC::JIT::emitSlow_op_captured_mov):
* jit/JITOperations.h:
* jit/JITPropertyAccess.cpp:
(JSC::JIT::emitNotifyWrite):
* jit/JITPropertyAccess32_64.cpp:
(JSC::JIT::emitNotifyWrite):
(JSC::JIT::emitSlow_op_put_to_scope):
- Let the slow path for notifyWrite handle the cases when the VariableWatchpointSet
  is in state ClearWatchpoint and IsWatched.
  We will by-pass the slow path if the value being written is the same as the
  inferred value.

* llint/LowLevelInterpreter32_64.asm:
* llint/LowLevelInterpreter64.asm:
- Let the slow path for notifyWrite handle the cases when the VariableWatchpointSet
  is in state ClearWatchpoint and IsWatched.
  We will by-pass the slow path if the value being written is the same as the
  inferred value.

* runtime/CommonSlowPaths.cpp:

* runtime/JSCJSValue.h: Fixed some typos in the comments.
* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::addGlobalVar):
(JSC::JSGlobalObject::addFunction):
* runtime/JSSymbolTableObject.h:
(JSC::symbolTablePut):
(JSC::symbolTablePutWithAttributes):
* runtime/SymbolTable.cpp:
(JSC::SymbolTableEntry::prepareToWatch):
(JSC::SymbolTableEntry::notifyWriteSlow):
* runtime/SymbolTable.h:
(JSC::SymbolTableEntry::notifyWrite):

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

6 years ago[Mac, iOS] REGRESSION: WK2 YouTube support
bfulgham@apple.com [Wed, 7 May 2014 21:59:51 +0000 (21:59 +0000)]
[Mac, iOS] REGRESSION: WK2 YouTube support
https://bugs.webkit.org/show_bug.cgi?id=132568
<rdar://problem/11464344>

Reviewed by Darin Adler.

Source/WebCore:
Move the custom YouTube loader code out of the WebFrameLoaderClient into a
PluginReplacement-based class.

* Modules/plugins/PluginReplacement.h:
(WebCore::PluginReplacement::supportsURL): New predicate so we can restrict
use of a plugin to a particular category of URLs.
* Modules/plugins/QuickTimePluginReplacement.mm:
(WebCore::QuickTimePluginReplacement): Updated for new registrar signature.
* Modules/plugins/YouTubePluginReplacement.h: Added.
(WebCore::YouTubePluginReplacement::parentElement):
* Modules/plugins/YouTubePluginReplacement.cpp: Added.
(WebCore::YouTubePluginReplacement::registerPluginReplacement):
(WebCore::YouTubePluginReplacement::create):
(WebCore::YouTubePluginReplacement::supportsMimeType):
(WebCore::YouTubePluginReplacement::supportsFileExtension):
(WebCore::kit):
(WebCore::YouTubePluginReplacement::YouTubePluginReplacement):
(WebCore::YouTubePluginReplacement::createElementRenderer):
(WebCore::objectForKey):
(WebCore::YouTubePluginReplacement::installReplacement):
(WebCore::createYouTubeURL):
(WebCore::processAndCreateYouTubeURL):
(WebCore::YouTubePluginReplacement::youTubeURL):
* WebCore.exp.in: Add new export from WebCore.
* WebCore.xcodeproj/project.pbxproj:
* html/HTMLPlugInElement.cpp:
(WebCore::pluginReplacementForType): Update to also check that the URL is supported
by the plugin.
(WebCore::registeredPluginReplacements): Add new YouTubePluginReplacement to registry.
* html/HTMLPlugInImageElement.cpp:
(WebCore::HTMLPlugInImageElement::createElementRenderer): Remove custom YouTube code
now that this logic is handled in the plugin replacement class.
(WebCore::HTMLPlugInImageElement::createShadowIFrameSubtree): Deleted.
* html/HTMLPlugInImageElement.h:
* html/shadow/YouTubeEmbedShadowElement.cpp:
(WebCore::YouTubeEmbedShadowElement::YouTubeEmbedShadowElement):
(WebCore::YouTubeEmbedShadowElement::shadowPseudoId): Use correct pseudoID for the
plugin replacement architecture.
* html/shadow/YouTubeEmbedShadowElement.h:
* platform/mac/WebCoreNSURLExtras.h:
* platform/mac/WebCoreNSURLExtras.mm:
(WebCore::unescapedQueryValue): Moved from WebKit/Misc/WebNSURLExtras.
(WebCore::queryKeysAndValues): Ditto.

Source/WebKit/mac:
* Misc/WebNSURLExtras.h:
* Misc/WebNSURLExtras.mm: Remove code that has been converted to C++
and added to YouTubePluginReplacement.cpp.
(-[NSURL _webkit_youTubeURL]):
(-[NSString _webkit_queryKeysAndValues]):
(createYouTubeURL): Deleted.
(-[NSString _webkit_unescapedQueryValue]): Deleted.

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

6 years ago<rdar://problem/16831276> [iOS] Unparenting a WKWebView that’s loading pauses it
mitz@apple.com [Wed, 7 May 2014 21:57:06 +0000 (21:57 +0000)]
<rdar://problem/16831276> [iOS] Unparenting a WKWebView that’s loading pauses it
https://bugs.webkit.org/show_bug.cgi?id=132659

Reviewed by Tim Horton.

* UIProcess/Cocoa/NavigationState.h: Added a member variable.
* UIProcess/Cocoa/NavigationState.mm:
(WebKit::NavigationState::didChangeIsLoading): When transitioning into loading state,
acquire a background activity token. When transitioning out of loading state, dispose of
the token.

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

6 years ago[iOS] Acclerated overflow-scrolling broken in WK1
simon.fraser@apple.com [Wed, 7 May 2014 21:49:10 +0000 (21:49 +0000)]
[iOS] Acclerated overflow-scrolling broken in WK1
https://bugs.webkit.org/show_bug.cgi?id=132665
<rdar://problem/16842909>

Reviewed by Tim Horton.

r168301 added a CALayer delegate to disable implicit animations,
but for some layers we wrap them in UIViews (which are themselves
layer delegates), so bad things happened.

Fix by falling back to setting the null actions dictionary for
layers with custom scrolling behavior.

* platform/graphics/GraphicsLayer.h:
* platform/graphics/ca/mac/PlatformCALayerMac.h:
* platform/graphics/ca/mac/PlatformCALayerMac.mm:
(PlatformCALayerMac::updateCustomBehavior):
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::updateScrollingLayers):

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

6 years agoHTMLMediaElement should exitFullscreen when view is removed from the window.
commit-queue@webkit.org [Wed, 7 May 2014 21:19:03 +0000 (21:19 +0000)]
HTMLMediaElement should exitFullscreen when view is removed from the window.
https://bugs.webkit.org/show_bug.cgi?id=132506

Patch by Jeremy Jones <jeremyj@apple.com> on 2014-05-07
Reviewed by Tim Horton.

Source/WebCore:
* platform/ios/WebVideoFullscreenControllerAVKit.h:
Add -requestExitFullscreen.

* platform/ios/WebVideoFullscreenControllerAVKit.mm:
(-[WebVideoFullscreenController requestExitFullscreen]):
Forward request onto WebVideoFullscreenModelMediaElement.

* platform/ios/WebVideoFullscreenModelMediaElement.mm:
(WebVideoFullscreenModelMediaElement::requestExitFullscreen):
Add some protection here since this may be called when not in fullscreen.

Source/WebKit/mac:
* WebView/WebView.mm:
(-[WebView viewDidMoveToWindow]):
Request WebVideoFullscreenController to exitFullscreen when view is removed from the window.

Source/WebKit2:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::viewStateDidChange):
Request WebVideoFUllscreenManagerProxy to exitFullscreen when removed from the window.
* UIProcess/ios/WebVideoFullscreenManagerProxy.h:
Make requestExitFullscreen() public instead of private.

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

6 years agoImage menu is offset by the amount the view is scrolled
beidson@apple.com [Wed, 7 May 2014 21:17:53 +0000 (21:17 +0000)]
Image menu is offset by the amount the view is scrolled
<rdar://problem/16818966> and https://bugs.webkit.org/show_bug.cgi?id=132663

Reviewed by Tim Horton.

* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::showContextMenu): Use FrameView::contentsToWindow instead of contentsToRoot,
  and skip the [NSView convertPoint:toView:] step.

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

6 years agoClean up the difference between painting focus rings and adding PDF annotations
dino@apple.com [Wed, 7 May 2014 20:03:13 +0000 (20:03 +0000)]
Clean up the difference between painting focus rings and adding PDF annotations
https://bugs.webkit.org/show_bug.cgi?id=132638

Follow-up comments from Darin Adler.

* rendering/RenderInline.cpp:
(WebCore::RenderInline::paintOutline): Move "else if" to a separate "if" for clarity.
* rendering/RenderObject.cpp:
(WebCore::RenderObject::paintFocusRing): Don't guard against outlineIsAuto(). ASSERT instead.
(WebCore::RenderObject::addPDFURLRect): Give "rect" variable a better name.
(WebCore::RenderObject::paintOutline): Move "else if" to a separate "if" for clarity.

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

6 years agoMake blob size computation lazy
ap@apple.com [Wed, 7 May 2014 18:57:35 +0000 (18:57 +0000)]
Make blob size computation lazy
https://bugs.webkit.org/show_bug.cgi?id=132653

Reviewed by Anders Carlsson.

Source/WebCore:
* fileapi/Blob.cpp:
(WebCore::Blob::Blob):
(WebCore::Blob::size):
* fileapi/Blob.h:
(WebCore::Blob::size): Deleted.
* fileapi/File.cpp:
(WebCore::File::size): Deleted.
* fileapi/File.h:
* fileapi/ThreadableBlobRegistry.cpp:
(WebCore::ThreadableBlobRegistry::registerFileBlobURL):
(WebCore::ThreadableBlobRegistry::registerBlobURL):
(WebCore::ThreadableBlobRegistry::registerBlobURLForSlice):
(WebCore::ThreadableBlobRegistry::blobSize):
(WebCore::ThreadableBlobRegistry::unregisterBlobURL):
(WebCore::unregisterBlobURLTask): Deleted.
* fileapi/ThreadableBlobRegistry.h:
* platform/network/BlobData.cpp:
(WebCore::BlobData::appendData):
* platform/network/BlobRegistry.h:
* platform/network/BlobRegistryImpl.cpp:
(WebCore::BlobRegistryImpl::registerBlobURL):
(WebCore::BlobRegistryImpl::registerBlobURLForSlice):
* platform/network/BlobRegistryImpl.h:

Source/WebKit2:
* NetworkProcess/FileAPI/NetworkBlobRegistry.cpp:
(WebKit::NetworkBlobRegistry::registerBlobURL):
(WebKit::NetworkBlobRegistry::registerBlobURLForSlice):
(WebKit::NetworkBlobRegistry::blobSize):
* NetworkProcess/FileAPI/NetworkBlobRegistry.h:
* NetworkProcess/NetworkConnectionToWebProcess.cpp:
(WebKit::NetworkConnectionToWebProcess::registerBlobURL):
(WebKit::NetworkConnectionToWebProcess::registerBlobURLForSlice):
(WebKit::NetworkConnectionToWebProcess::blobSize):
* NetworkProcess/NetworkConnectionToWebProcess.h:
* NetworkProcess/NetworkConnectionToWebProcess.messages.in:
* WebProcess/FileAPI/BlobRegistryProxy.cpp:
(WebKit::BlobRegistryProxy::registerBlobURL):
(WebKit::BlobRegistryProxy::registerBlobURLForSlice):
(WebKit::BlobRegistryProxy::blobSize):
* WebProcess/FileAPI/BlobRegistryProxy.h:

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

6 years agoWebKit1 is flashy when compositing layers come and go
simon.fraser@apple.com [Wed, 7 May 2014 18:49:26 +0000 (18:49 +0000)]
WebKit1 is flashy when compositing layers come and go
https://bugs.webkit.org/show_bug.cgi?id=132655

Source/WebKit/mac:

Reviewed by Sam Weinig.

In r166117 I removed code to flush compositing layers in FrameView::paintContents(),
which caused problems when painting iframes. However, this removed a flush
that WebKit1 relied on to flush compositing layers when painting, which caused
flashing when compositing layers come and go, and broke WebView snapshotting
in some cases.

Fix by adding back compositing layer flushing, but this time in WebKit1's
-viewWillDraw code path. This allows removal of some flushing in DumpRenderTree.

* WebView/WebHTMLView.mm:
(-[WebHTMLView viewWillDraw]):
* WebView/WebView.mm:
(-[WebView _flushCompositingChanges]):
* WebView/WebViewInternal.h:
* WebView/WebViewPrivate.h:

Tools:
<rdar://problem/16830981&16788846>

Reviewed by Sam Weinig.

Revert the change from r166117.

* DumpRenderTree/mac/DumpRenderTree.mm:
(updateDisplay):

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

6 years agoAdd scrolling tree logging to RemoteLayerTree output
simon.fraser@apple.com [Wed, 7 May 2014 18:42:53 +0000 (18:42 +0000)]
Add scrolling tree logging to RemoteLayerTree output
https://bugs.webkit.org/show_bug.cgi?id=132640

Reviewed by Beth Dakin.

Source/WebCore:

Support scrolling tree logging in the RemoteLayerTree log channel
output.

ScrollingStateTree::commit() unconditionally set treeStateClone->m_hasChangedProperties
to true, but we should set it based on original scrolling state tree's
m_hasChangedProperties.

We have to encode all of the scrolling state nodes anyway (they only encode
changed properties), but we can use this for future optimizations, and to
avoid spurious logging.

* WebCore.exp.in: Export a couple of things we need.
* page/scrolling/ScrollingStateTree.cpp:
(WebCore::ScrollingStateTree::commit):

Source/WebKit2:

Support scrolling tree logging in the RemoteLayerTree log channel
output.

Encode/decode ScrollingStateTree::hasChangedProperties() so we can use
it to avoid logging. Log all the things.

* Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp:
(WebKit::RemoteScrollingCoordinatorTransaction::encode):
(WebKit::RemoteScrollingCoordinatorTransaction::decode):
(WebKit::RemoteScrollingTreeTextStream::RemoteScrollingTreeTextStream):
(WebKit::RemoteScrollingTreeTextStream::increaseIndent):
(WebKit::RemoteScrollingTreeTextStream::decreaseIndent):
(WebKit::RemoteScrollingTreeTextStream::writeIndent):
(WebKit::dumpProperty):
(WebKit::RemoteScrollingTreeTextStream::operator<<):
(WebKit::RemoteScrollingTreeTextStream::dump):
(WebKit::RemoteScrollingTreeTextStream::recursiveDumpNodes):
(WebKit::RemoteScrollingCoordinatorTransaction::description):
(WebKit::RemoteScrollingCoordinatorTransaction::dump):
* Shared/Scrolling/RemoteScrollingCoordinatorTransaction.h:
* UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:
(WebKit::RemoteLayerTreeDrawingAreaProxy::commitLayerTree):

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

6 years agoAX: aria-expanded changes are not communicated to clients
cfleizach@apple.com [Wed, 7 May 2014 18:32:06 +0000 (18:32 +0000)]
AX: aria-expanded changes are not communicated to clients
https://bugs.webkit.org/show_bug.cgi?id=132642

Reviewed by Mario Sanchez Prada.

Source/WebCore:
When aria-expanded changes on non list/tree items, send out a generic
AXExpandedChange notification.

Test: platform/mac/accessibility/expanded-notification.html

* accessibility/AXObjectCache.h:
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::handleAriaExpandedChanged):
* accessibility/mac/AXObjectCacheMac.mm:
(WebCore::AXObjectCache::postPlatformNotification):

LayoutTests:
* platform/mac/accessibility/expanded-notification-expected.txt: Added.
* platform/mac/accessibility/expanded-notification.html: Added.

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

6 years agoRelease build fix.
ap@apple.com [Wed, 7 May 2014 18:24:21 +0000 (18:24 +0000)]
Release build fix.

* platform/MIMETypeRegistry.cpp: (WebCore::initializeSupportedImageMIMETypes):
Removed unused globals.

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

6 years agoEliminate "well known MIME type" support
ap@apple.com [Wed, 7 May 2014 18:19:21 +0000 (18:19 +0000)]
Eliminate "well known MIME type" support
https://bugs.webkit.org/show_bug.cgi?id=132654

Reviewed by Anders Carlsson.

Vestiges of FileSystem API.

* dom/DataTransfer.cpp:
(WebCore::DataTransfer::files):
(WebCore::DataTransfer::hasFileOfType):
* fileapi/File.cpp:
(WebCore::File::File):
(WebCore::File::contentTypeFromFilePathOrName):
* fileapi/File.h:
* html/FileInputType.cpp:
(WebCore::FileInputType::createFileList):
* platform/MIMETypeRegistry.cpp:
(WebCore::initializeSupportedImageMIMETypes):
(WebCore::findMimeType): Deleted.
(WebCore::MIMETypeRegistry::getWellKnownMIMETypeForExtension): Deleted.
* platform/MIMETypeRegistry.h:

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

6 years agoFix windows build.
oliver@apple.com [Wed, 7 May 2014 18:13:04 +0000 (18:13 +0000)]
Fix windows build.

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

6 years ago[HTML] Default argument to HTMLTableElement.insertRow() should be -1
ch.dumez@samsung.com [Wed, 7 May 2014 17:29:33 +0000 (17:29 +0000)]
[HTML] Default argument to HTMLTableElement.insertRow() should be -1
https://bugs.webkit.org/show_bug.cgi?id=132651

Reviewed by Alexey Proskuryakov.

Source/WebCore:
HTMLTableElement.insertRow()'s argument default value should be -1, not 0,
as per the specification:
http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#htmltableelement

The new behavior matches the one of Firefox 29 and IE11, and soon Blink:
https://codereview.chromium.org/270213007/

Test: fast/dom/HTMLTableElement/insertRow-default-argument.html

* html/HTMLTableElement.h:
* html/HTMLTableElement.idl:

LayoutTests:
Add layout test to test that the default argument to HTMLTableElement.insertRow()
is -1.

* fast/dom/HTMLTableElement/insertRow-default-argument-expected.txt: Added.
* fast/dom/HTMLTableElement/insertRow-default-argument.html: Added.

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

6 years agoAX: AXSelectTextWithCriteria should support capitalize/lowercase/uppercase
cfleizach@apple.com [Wed, 7 May 2014 16:17:47 +0000 (16:17 +0000)]
AX: AXSelectTextWithCriteria should support capitalize/lowercase/uppercase
https://bugs.webkit.org/show_bug.cgi?id=132622

Reviewed by Mario Sanchez Prada.

Source/WebCore:
The select text with criteria mechanism used through accessibility needs to support
a few more parameters to be complete (including capitalize, lowercase and uppercase).

Updated: accessibility/select-text.html

* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::selectText):
* accessibility/AccessibilityObject.h:
* accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(accessibilitySelectTextCriteriaForCriteriaParameterizedAttribute):
* rendering/RenderText.cpp:
(WebCore::makeCapitalized):
* rendering/RenderText.h:

Tools:
* DumpRenderTree/AccessibilityUIElement.cpp:
(selectTextWithCriteriaCallback):
(isEqualCallback):
* DumpRenderTree/AccessibilityUIElement.h:
* DumpRenderTree/atk/AccessibilityUIElementAtk.cpp:
(AccessibilityUIElement::selectTextWithCriteria):
* DumpRenderTree/ios/AccessibilityUIElementIOS.mm:
(AccessibilityUIElement::selectTextWithCriteria):
* DumpRenderTree/mac/AccessibilityUIElementMac.mm:
(selectTextParameterizedAttributeForCriteria):
(AccessibilityUIElement::selectTextWithCriteria):
* DumpRenderTree/win/AccessibilityUIElementWin.cpp:
(AccessibilityUIElement::selectTextWithCriteria):
* WebKitTestRunner/InjectedBundle/AccessibilityUIElement.cpp:
(WTR::AccessibilityUIElement::selectTextWithCriteria):
* WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
* WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
* WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
(WTR::AccessibilityUIElement::selectTextWithCriteria):
* WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm:
(WTR::AccessibilityUIElement::selectTextWithCriteria):
* WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
(WTR::selectTextParameterizedAttributeForCriteria):
(WTR::AccessibilityUIElement::selectTextWithCriteria):

LayoutTests:
* platform/mac/accessibility/select-text-expected.txt:
* platform/mac/accessibility/select-text.html:

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

6 years agoShare mac/editing/spelling/editing-multiple-words-with-markers.html with other platforms
g.czajkowski@samsung.com [Wed, 7 May 2014 14:54:56 +0000 (14:54 +0000)]
Share mac/editing/spelling/editing-multiple-words-with-markers.html with other platforms
https://bugs.webkit.org/show_bug.cgi?id=132649

Reviewed by Ryosuke Niwa.

This test does not verify autocorrection feature which is only implemented
by Mac. Other WebKit ports might be interested in running it due to
verification of spelling markers after merging two misspelled words.

Additionally, add the test case confirming spelling markers
before any selection change.

Due to bug 125689, this test starts using asynchronous spellchecking.

* editing/spelling/editing-multiple-words-with-markers-expected.txt:
Renamed from platform/mac/editing/spelling/editing-multiple-words-with-markers-expected.txt
* editing/spelling/editing-multiple-words-with-markers.html:
Renamed from platform/mac/editing/spelling/editing-multiple-words-with-markers.html

* platform/gtk/TestExpectations:
* platform/mac-wk2/TestExpectations:
* platform/win/TestExpectations:
Mark editing-multiple-words-with-markers.html as failing since those
platforms didn't turn on asynchronous spellchecking.

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

6 years agoDocumentLoader::dataReceived assertion failed
commit-queue@webkit.org [Wed, 7 May 2014 14:07:02 +0000 (14:07 +0000)]
DocumentLoader::dataReceived assertion failed
https://bugs.webkit.org/show_bug.cgi?id=132017

Patch by peavo@outlook.com <peavo@outlook.com> on 2014-05-07
Reviewed by Brent Fulgham.

We need to call didReceiveResponse client method before the didReceiveData client method, otherwise we get a lot of asserts.
This patch also fixes frequent crashes in downloadTimerCallback method on page loading.

* platform/network/curl/ResourceHandleManager.cpp:
(WebCore::calculateWebTimingInformations): Initialize local variables.
(WebCore::headerCallback): Call didReceiveResponse client method here instead of in downloadTimerCallback.
(WebCore::ResourceHandleManager::downloadTimerCallback): Remove call to didReceiveResponse method.
(WebCore::ResourceHandleManager::dispatchSynchronousJob): Removed empty line.

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

6 years agoREGRESSION: Animated GIF inside compositing layer never resumes animation when scroll...
antti@apple.com [Wed, 7 May 2014 13:11:00 +0000 (13:11 +0000)]
REGRESSION: Animated GIF inside compositing layer never resumes animation when scrolled back into view
https://bugs.webkit.org/show_bug.cgi?id=132608

Reviewed by Simon Fraser.

Source/WebCore:
Test: fast/repaint/animation-after-layer-scroll.html

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::scrollTo):

    Check if any animations need to be restarted after layer scroll.

LayoutTests:
* fast/repaint/animation-after-layer-scroll-expected.txt: Added.
* fast/repaint/animation-after-layer-scroll.html: Added.

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

6 years agoGraphicsLayer::client() should return a reference.
commit-queue@webkit.org [Wed, 7 May 2014 11:44:00 +0000 (11:44 +0000)]
GraphicsLayer::client() should return a reference.
https://bugs.webkit.org/show_bug.cgi?id=126372

Patch by Hyowon Kim <hw1008.kim@samsung.com> on 2014-05-07
Reviewed by Simon Fraser.

GraphicsLayers always have a GraphicsLayerClient attached,
so make client() a reference and remove some unnecessary branches.
The author of the changes in the mac port is Andreas Kling <akling@apple.com>.

Source/WebCore:
* WebCore.exp.in:
* platform/graphics/GraphicsLayer.cpp:
(WebCore::GraphicsLayer::GraphicsLayer):
(WebCore::GraphicsLayer::willBeDestroyed):
(WebCore::GraphicsLayer::paintGraphicsLayerContents):
(WebCore::GraphicsLayer::addRepaintRect):
(WebCore::dumpChildren):
(WebCore::GraphicsLayer::dumpProperties):
* platform/graphics/GraphicsLayer.h:
(WebCore::GraphicsLayer::client):
(WebCore::GraphicsLayer::pageScaleFactor):
(WebCore::GraphicsLayer::deviceScaleFactor):
* platform/graphics/GraphicsLayerFactory.h:
* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::GraphicsLayer::create):
(WebCore::GraphicsLayerCA::GraphicsLayerCA):
(WebCore::GraphicsLayerCA::initialize):
(WebCore::GraphicsLayerCA::platformCALayerAnimationStarted):
(WebCore::GraphicsLayerCA::computePositionRelativeToBase):
(WebCore::GraphicsLayerCA::flushCompositingStateForThisLayerOnly):
(WebCore::GraphicsLayerCA::computeVisibleRect):
(WebCore::GraphicsLayerCA::recursiveCommitChanges):
(WebCore::GraphicsLayerCA::platformCALayerContentsScaleMultiplierForNewTiles):
(WebCore::GraphicsLayerCA::platformCALayerShouldAggressivelyRetainTiles):
(WebCore::GraphicsLayerCA::platformCALayerShouldTemporarilyRetainTileCohorts):
(WebCore::GraphicsLayerCA::updateContentsOpaque):
(WebCore::GraphicsLayerCA::updateContentsScale):
(WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
(WebCore::GraphicsLayerCA::noteLayerPropertyChanged):
* platform/graphics/ca/GraphicsLayerCA.h:
* platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
(WebCore::GraphicsLayer::create):
(WebCore::GraphicsLayerTextureMapper::GraphicsLayerTextureMapper):
(WebCore::GraphicsLayerTextureMapper::notifyChange):
(WebCore::GraphicsLayerTextureMapper::commitLayerChanges):
* platform/graphics/texmap/GraphicsLayerTextureMapper.h:
* platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:
(WebCore::CompositingCoordinator::createRootLayer):
(WebCore::CompositingCoordinator::createGraphicsLayer):
* platform/graphics/texmap/coordinated/CompositingCoordinator.h:
* platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
(WebCore::CoordinatedGraphicsLayer::notifyFlushRequired):
(WebCore::CoordinatedGraphicsLayer::CoordinatedGraphicsLayer):
(WebCore::CoordinatedGraphicsLayer::computeTransformedVisibleRect):
(WebCore::CoordinatedGraphicsLayer::animationStartedTimerFired):
* platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::createGraphicsLayer):
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::updateLayerForTopOverhangArea):
(WebCore::RenderLayerCompositor::updateLayerForBottomOverhangArea):
(WebCore::RenderLayerCompositor::updateLayerForHeader):
(WebCore::RenderLayerCompositor::updateLayerForFooter):
(WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
(WebCore::RenderLayerCompositor::ensureRootLayer):

Source/WebKit/win:
* WebView.cpp:
(WebView::setAcceleratedCompositing):

Source/WebKit2:
* WebProcess/WebPage/PageOverlayController.cpp:
(WebKit::PageOverlayController::initialize):
(WebKit::PageOverlayController::installPageOverlay):
* WebProcess/WebPage/gtk/LayerTreeHostGtk.cpp:
(WebKit::LayerTreeHostGtk::initialize):
(WebKit::LayerTreeHostGtk::createPageOverlayLayer):
* WebProcess/WebPage/mac/GraphicsLayerCARemote.h:
* WebProcess/WebPage/mac/RemoteLayerTreeContext.h:
* WebProcess/WebPage/mac/RemoteLayerTreeContext.mm:
(WebKit::RemoteLayerTreeContext::createGraphicsLayer):
* WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
* WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
(WebKit::RemoteLayerTreeDrawingArea::RemoteLayerTreeDrawingArea):

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

6 years ago[GStreamer] Corrected typo
calvaris@igalia.com [Wed, 7 May 2014 10:54:29 +0000 (10:54 +0000)]
[GStreamer] Corrected typo
https://bugs.webkit.org/show_bug.cgi?id=132609

Reviewed by Martin Robinson.

Corrected m_canFallBackToLastFinishedSeekPositon typo and
initialized in the constructor to prevent problems in the future.

No test needed.

* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
Initialized m_canFallBackToLastFinishedSeekPosition as false.
(WebCore::MediaPlayerPrivateGStreamer::playbackPosition):
(WebCore::MediaPlayerPrivateGStreamer::handleMessage):
(WebCore::MediaPlayerPrivateGStreamer::asyncStateChangeDone):
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
m_canFallBackToLastFinishedSeekPositon ->
m_canFallBackToLastFinishedSeekPosition

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

6 years agoCleanup the build from unused parameter in UIProcess Module
commit-queue@webkit.org [Wed, 7 May 2014 10:39:48 +0000 (10:39 +0000)]
Cleanup the build from unused parameter in UIProcess Module
https://bugs.webkit.org/show_bug.cgi?id=131969

Patch by Shivakumar JM <shiva.jm@samsung.com> on 2014-05-07
Reviewed by Csaba Osztrogonác.

Fixed unused parameter by omitting the parameter name

* UIProcess/API/C/WKPage.cpp:
(WKPageSetPageFindClient):
* UIProcess/WebFindClient.cpp:
(WebKit::WebFindClient::didFindString):

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

6 years agoConvert PassOwnPtr to unique_ptr in CrossThreadTask.h
gyuyoung.kim@samsung.com [Wed, 7 May 2014 10:20:14 +0000 (10:20 +0000)]
Convert PassOwnPtr to unique_ptr in CrossThreadTask.h
https://bugs.webkit.org/show_bug.cgi?id=132605

Reviewed by Dirk Schulze.

* dom/CrossThreadTask.h: Converted.

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

6 years ago[SOUP] TLSErrors do not cause page load to fail when not ignored
carlosgc@webkit.org [Wed, 7 May 2014 10:11:30 +0000 (10:11 +0000)]
[SOUP] TLSErrors do not cause page load to fail when not ignored
https://bugs.webkit.org/show_bug.cgi?id=121548

Reviewed by Sergio Villar Senin.

Source/WebCore:
This only happens in case of redirection, when the initial URL is
an HTTPS site with an invalid certificate, that redirects to
another location. We are starting the redirection without checking
the TLS errors.

* platform/network/soup/ResourceHandleSoup.cpp:
(WebCore::sendRequestCallback): Check TLS errors before starting a
possible redirection.

Tools:
Add unit tests to check that the load fails with TLS errors in
case of a redirection.

* TestWebKitAPI/Tests/WebKit2Gtk/TestSSL.cpp:
(testTLSErrorsRedirect):
(httpsServerCallback):
(beforeAll):

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

6 years ago[CSS Grid Layout] Remove runtime feature
rego@igalia.com [Wed, 7 May 2014 09:56:14 +0000 (09:56 +0000)]
[CSS Grid Layout] Remove runtime feature
https://bugs.webkit.org/show_bug.cgi?id=132382

Reviewed by Benjamin Poulain.

PerformanceTests:
Remove set of WebKitCSSGridLayoutEnabled preference.

* Layout/auto-grid-lots-of-data.html:
* Layout/fixed-grid-lots-of-data.html:

Source/WebCore:
Remove cssGridLayoutEnabled setting. Update methods using it accordingly.

* WebCore.order:
* css/CSSParser.cpp:
(WebCore::CSSParserContext::CSSParserContext):
(WebCore::operator==):
(WebCore::isValidKeywordPropertyAndValue):
(WebCore::CSSParser::parseValue):
(WebCore::CSSParser::parseGridTemplateShorthand):
(WebCore::CSSParser::parseGridAreaShorthand):
(WebCore::CSSParser::cssGridLayoutEnabled): Deleted.
* css/CSSParser.h:
* css/CSSParserMode.h:
* dom/Document.cpp:
(WebCore::Document::cssGridLayoutEnabled): Deleted.
* dom/Document.h:
* page/Settings.in:

Source/WebKit/efl:
Remove cssGridLayoutEnabled setting usage.

* WebCoreSupport/DumpRenderTreeSupportEfl.cpp:
(DumpRenderTreeSupportEfl::setCSSGridLayoutEnabled): Deleted.
* WebCoreSupport/DumpRenderTreeSupportEfl.h:

Source/WebKit/mac:
Remove cssGridLayoutEnabled setting usage.

* WebKit.order:
* WebView/WebPreferenceKeysPrivate.h:
* WebView/WebPreferences.mm:
(+[WebPreferences initialize]):
(-[WebPreferences cssGridLayoutEnabled]): Deleted.
(-[WebPreferences setCSSGridLayoutEnabled:]): Deleted.
* WebView/WebPreferencesPrivate.h:
* WebView/WebView.mm:
(-[WebView _preferencesChanged:]):

Source/WebKit2:
Remove cssGridLayoutEnabled setting usage.

* Shared/WebPreferencesStore.h:
* UIProcess/API/C/WKPreferences.cpp:
(WKPreferencesSetCSSGridLayoutEnabled): Deleted.
(WKPreferencesGetCSSGridLayoutEnabled): Deleted.
* UIProcess/API/C/WKPreferencesRefPrivate.h:
* UIProcess/API/gtk/WebKitSettings.cpp:
(webKitSettingsConstructed):
* UIProcess/gtk/ExperimentalFeatures.cpp:
* UIProcess/gtk/ExperimentalFeatures.h:
* WebProcess/InjectedBundle/InjectedBundle.cpp:
(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::updatePreferences):
* mac/WebKit2.order:

Tools:
Remove cssGridLayoutEnabled setting usage.

* DumpRenderTree/efl/DumpRenderTreeChrome.cpp:
(DumpRenderTreeChrome::resetDefaultsToConsistentValues):
* DumpRenderTree/efl/TestRunnerEfl.cpp:
(TestRunner::overridePreference):
* DumpRenderTree/mac/DumpRenderTree.mm:
(resetWebPreferencesToConsistentValues):

LayoutTests:
Remove set of WebKitCSSGridLayoutEnabled preference.
Remove fast/css-grid-layout/grid-disabled.html patch as the setting is not available anymore.

* fast/css-grid-layout/anonymous-grid-items-expected.html:
* fast/css-grid-layout/anonymous-grid-items.html:
* fast/css-grid-layout/auto-content-resolution-columns.html:
* fast/css-grid-layout/auto-content-resolution-rows.html:
* fast/css-grid-layout/breadth-size-resolution-grid.html:
* fast/css-grid-layout/calc-resolution-grid-item.html:
* fast/css-grid-layout/containing-block-grids.html:
* fast/css-grid-layout/display-grid-set-get.html:
* fast/css-grid-layout/flex-and-minmax-content-resolution-columns.html:
* fast/css-grid-layout/flex-and-minmax-content-resolution-rows.html:
* fast/css-grid-layout/flex-content-resolution-columns.html:
* fast/css-grid-layout/flex-content-resolution-rows.html:
* fast/css-grid-layout/flex-content-sized-column-use-available-width.html:
* fast/css-grid-layout/flex-content-sized-columns-resize.html:
* fast/css-grid-layout/floating-empty-grids.html:
* fast/css-grid-layout/grid-auto-columns-rows-auto-flow-resolution.html:
* fast/css-grid-layout/grid-auto-columns-rows-get-set.html:
* fast/css-grid-layout/grid-auto-columns-rows-resolution.html:
* fast/css-grid-layout/grid-auto-columns-rows-update.html:
* fast/css-grid-layout/grid-auto-flow-get-set.html:
* fast/css-grid-layout/grid-auto-flow-resolution.html:
* fast/css-grid-layout/grid-auto-flow-update.html:
* fast/css-grid-layout/grid-columns-rows-get-set-multiple.html:
* fast/css-grid-layout/grid-columns-rows-get-set.html:
* fast/css-grid-layout/grid-container-change-named-grid-lines-recompute-child.html:
* fast/css-grid-layout/grid-disabled-expected.txt: Removed.
* fast/css-grid-layout/grid-disabled.html: Removed.
* fast/css-grid-layout/grid-dynamic-updates-relayout.html:
* fast/css-grid-layout/grid-element-border-grid-item.html:
* fast/css-grid-layout/grid-element-border-padding-grid-item.html:
* fast/css-grid-layout/grid-element-change-columns-repaint.html:
* fast/css-grid-layout/grid-element-change-rows-repaint.html:
* fast/css-grid-layout/grid-element-empty-row-column.html:
* fast/css-grid-layout/grid-element-min-max-height.html:
* fast/css-grid-layout/grid-element-min-max-width.html:
* fast/css-grid-layout/grid-element-padding-grid-item.html:
* fast/css-grid-layout/grid-element-padding-margin.html:
* fast/css-grid-layout/grid-element-repeat-get-set.html:
* fast/css-grid-layout/grid-element-shrink-to-fit.html:
* fast/css-grid-layout/grid-item-addition-auto-placement-update.html:
* fast/css-grid-layout/grid-item-addition-track-breadth-update.html:
* fast/css-grid-layout/grid-item-area-get-set.html:
* fast/css-grid-layout/grid-item-bad-named-area-auto-placement.html:
* fast/css-grid-layout/grid-item-bad-resolution-double-span.html:
* fast/css-grid-layout/grid-item-change-column-repaint.html:
* fast/css-grid-layout/grid-item-change-row-repaint.html:
* fast/css-grid-layout/grid-item-column-row-get-set.html:
* fast/css-grid-layout/grid-item-end-after-get-set.html:
* fast/css-grid-layout/grid-item-margin-auto-columns-rows.html:
* fast/css-grid-layout/grid-item-margin-resolution.html:
* fast/css-grid-layout/grid-item-multiple-minmax-content-resolution.html:
* fast/css-grid-layout/grid-item-named-grid-area-resolution.html:
* fast/css-grid-layout/grid-item-named-grid-line-resolution.html:
* fast/css-grid-layout/grid-item-negative-indexes.html:
* fast/css-grid-layout/grid-item-negative-integer-explicit-grid-resolution.html:
* fast/css-grid-layout/grid-item-negative-position-resolution.html:
* fast/css-grid-layout/grid-item-order-auto-flow-resolution.html:
* fast/css-grid-layout/grid-item-order-paint-order.html:
* fast/css-grid-layout/grid-item-position-changed-dynamic.html:
* fast/css-grid-layout/grid-item-removal-auto-placement-update.html:
* fast/css-grid-layout/grid-item-removal-track-breadth-update.html:
* fast/css-grid-layout/grid-item-spanning-resolution.html:
* fast/css-grid-layout/grid-item-start-before-get-set.html:
* fast/css-grid-layout/grid-item-with-percent-height-in-auto-height-grid-resolution.html:
* fast/css-grid-layout/grid-item-with-percent-min-max-height-dynamic.html:
* fast/css-grid-layout/grid-preferred-logical-widths.html:
* fast/css-grid-layout/grid-strict-ordering-crash.html:
* fast/css-grid-layout/grid-template-areas-get-set.html:
* fast/css-grid-layout/grid-template-shorthand-get-set.html:
* fast/css-grid-layout/implicit-columns-auto-resolution.html:
* fast/css-grid-layout/implicit-position-dynamic-change.html:
* fast/css-grid-layout/implicit-rows-auto-resolution.html:
* fast/css-grid-layout/minmax-fixed-logical-height-only.html:
* fast/css-grid-layout/minmax-fixed-logical-width-only.html:
* fast/css-grid-layout/minmax-max-content-resolution-columns.html:
* fast/css-grid-layout/minmax-max-content-resolution-rows.html:
* fast/css-grid-layout/minmax-min-content-column-resolution-columns.html:
* fast/css-grid-layout/minmax-min-content-column-resolution-rows.html:
* fast/css-grid-layout/minmax-spanning-resolution-columns.html:
* fast/css-grid-layout/minmax-spanning-resolution-rows.html:
* fast/css-grid-layout/named-grid-line-get-set.html:
* fast/css-grid-layout/named-grid-lines-with-named-grid-areas-get-set.html:
* fast/css-grid-layout/named-grid-lines-with-named-grid-areas-resolution.html:
* fast/css-grid-layout/non-grid-columns-rows-get-set-multiple.html:
* fast/css-grid-layout/non-grid-columns-rows-get-set.html:
* fast/css-grid-layout/non-grid-element-repeat-get-set.html:
* fast/css-grid-layout/non-named-grid-line-get-set.html:
* fast/css-grid-layout/percent-grid-item-in-percent-grid-track-in-percent-grid.html:
* fast/css-grid-layout/percent-grid-item-in-percent-grid-track-update.html:
* fast/css-grid-layout/percent-grid-item-in-percent-grid-track.html:
* fast/css-grid-layout/percent-padding-margin-resolution-grid-item-update.html:
* fast/css-grid-layout/percent-padding-margin-resolution-grid-item.html:
* fast/css-grid-layout/percent-resolution-grid-item.html:
* fast/css-grid-layout/place-cell-by-index.html:
* fast/css-grid-layout/should-not-collapse-anonymous-blocks.html:
* ietestcenter/css3/grid/grid-column-002.htm:
* ietestcenter/css3/grid/testRunnerEnableGrid.js: Removed.

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

6 years ago[GTK] Unreviewed GTK gardening
berto@igalia.com [Wed, 7 May 2014 08:35:03 +0000 (08:35 +0000)]
[GTK] Unreviewed GTK gardening

Avoid duplicated expectations and remove failure flag for fixed
js/dom/basic-weakmap.html test.

Patch by Lorenzo Tilve <ltilve@igalia.com> on 2014-05-07

* platform/gtk/TestExpectations:

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

6 years agoURTBF after r168393 to fix !IOS builds.
ossy@webkit.org [Wed, 7 May 2014 08:15:54 +0000 (08:15 +0000)]
URTBF after r168393 to fix !IOS builds.

* Shared/WebEvent.h:

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

6 years agoFix build errors for BlobDataItem after r168391.
ossy@webkit.org [Wed, 7 May 2014 07:56:07 +0000 (07:56 +0000)]
Fix build errors for BlobDataItem after r168391.
https://bugs.webkit.org/show_bug.cgi?id=132643

Patch by Praveen R Jadhav <praveen.j@samsung.com> on 2014-05-07
Reviewed by Carlos Garcia Campos.

Patch updates BlobDataItem params usage in ResourceHandleSoup.cpp
to be inline with r168391.

* platform/network/soup/ResourceHandleSoup.cpp:
(WebCore::blobIsOutOfDate): BlobDataItem class is updated in r168391.
Corresponding parameter changes are done to resolve build error.
(WebCore::addEncodedBlobItemToSoupMessageBody): BlobDataItem class is updated
in r168391. Corresponding parameter changes are done to resolve build error.

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

6 years agoFollowup to "Add WK2 SPI to prevent the previous back/forward item from remaining...
beidson@apple.com [Wed, 7 May 2014 05:37:22 +0000 (05:37 +0000)]
Followup to "Add WK2 SPI to prevent the previous back/forward item from remaining in the list"
<rdar://problem/16248710> and https://bugs.webkit.org/show_bug.cgi?id=132636

Reviewed by NOBODY (My mistake while addressing previous review feedback)

* UIProcess/API/C/WKPage.cpp:
(WKPageSetPageLoaderClient): During review feedback, this client switched from default negative to default
  positve, so when the client isn't implemented...  return true instead of false.

* UIProcess/WebBackForwardList.cpp:
(WebKit::WebBackForwardList::addItem): Fix nonsensical comments while I'm at it.

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

6 years agoAdd Makefile targets for copying static libraries (LLVM and WKSI)
ddkilzer@apple.com [Wed, 7 May 2014 05:18:07 +0000 (05:18 +0000)]
Add Makefile targets for copying static libraries (LLVM and WKSI)
<http://webkit.org/b/132619>

Reviewed by Mark Rowe.

.:
* Makefile:
(MODULES): Add WebKitLibraries.

Tools:
* Scripts/copy-webkitlibraries-to-product-directory: Set a
sensible default for product directory if not specified on
either the command-line or in the environment (by Xcode) by
calling productDir() in webkitdirs.pm.

WebKitLibraries:
* Makefile: Added.
(libs): Install both LLVM and WKSI static libraries.
(all): Add dependency on 'libs' target.
(debug d): Set configuration, the call 'libs' target.
(release r): Ditto.

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

6 years agoVersioning.
lforschler@apple.com [Wed, 7 May 2014 05:15:47 +0000 (05:15 +0000)]
Versioning.

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

6 years agoAdd WK2 SPI to prevent the previous back/forward item from remaining in the list
beidson@apple.com [Wed, 7 May 2014 04:50:57 +0000 (04:50 +0000)]
Add WK2 SPI to prevent the previous back/forward item from remaining in the list
<rdar://problem/16248710> and https://bugs.webkit.org/show_bug.cgi?id=132636

Reviewed by Sam Weinig.

Source/WebKit2:
Add new PageLoaderClient SPI to keep the current back/forward item from remaining in the list:
* UIProcess/API/APILoaderClient.h:
(API::LoaderClient::shouldKeepCurrentBackForwardListItemInList):
* UIProcess/API/C/WKPage.cpp:
(WKPageSetPageLoaderClient):
* UIProcess/API/C/WKPageLoaderClient.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::shouldKeepCurrentBackForwardListItemInList):
* UIProcess/WebPageProxy.h:

* UIProcess/WebBackForwardList.cpp:
(WebKit::WebBackForwardList::addItem): Use that SPI to determine whether we should insert the new item after
the previous item, or simply replace the previous item.
(WebKit::WebBackForwardList::goToItem): Use that SPI to determine whether the previous item stays or goes.

Tools:
* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:

* TestWebKitAPI/Tests/WebKit2/ShouldKeepCurrentBackForwardListItemInList.cpp: Added.
(TestWebKitAPI::itemURLLastComponentIsString):
(TestWebKitAPI::didFinishLoadForFrame):
(TestWebKitAPI::willGoToBackForwardListItem):
(TestWebKitAPI::shouldKeepCurrentBackForwardListItemInList):
(TestWebKitAPI::setPageLoaderClient):
(TestWebKitAPI::TEST):
* TestWebKitAPI/Tests/WebKit2/simple2.html: Added.
* TestWebKitAPI/Tests/WebKit2/simple3.html: Added.

* WebKitTestRunner/TestController.cpp:
(WTR::TestController::createWebViewWithOptions): Update for new client layout.

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

6 years agoUnreviewd build fix for C-LOOP after r168396.
msaboff@apple.com [Wed, 7 May 2014 04:01:25 +0000 (04:01 +0000)]
Unreviewd build fix for C-LOOP after r168396.

* runtime/TestRunnerUtils.cpp:
(JSC::optimizeNextInvocation): Wrapped actual call inside #if ENABLE(JIT)

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

6 years ago-[WKWebView isLoading] is NO immediately after -loadRequest: until the provisional...
mitz@apple.com [Wed, 7 May 2014 03:47:06 +0000 (03:47 +0000)]
-[WKWebView isLoading] is NO immediately after -loadRequest: until the provisional load starts
https://bugs.webkit.org/show_bug.cgi?id=132639

Reviewed by Darin Adler.

* UIProcess/PageLoadState.cpp:
(WebKit::PageLoadState::commitChanges): Updated for change from isLoadingState to isLoading.
(WebKit::PageLoadState::isLoading): Renamed from isLoadingState, changed to take Data and
check whether there is a non-null pending API request URL. If so, return true.
* UIProcess/PageLoadState.h:

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

6 years agoClean up the difference between painting focus rings and adding PDF annotations
dino@apple.com [Wed, 7 May 2014 02:58:39 +0000 (02:58 +0000)]
Clean up the difference between painting focus rings and adding PDF annotations
https://bugs.webkit.org/show_bug.cgi?id=132638

Reviewed by Simon Fraser.

The code to add a PDF annotation when printing was called from
drawFocusRing, which is quite confusing. With just little movement
of code, we can detect an annotation and call addPDFURLRect in the
paint phase, and drawFocusRing becomes something that only
draws focus rings.

* rendering/RenderInline.cpp:
(WebCore::RenderInline::paintOutline): Split calls to drawFocusRing
and addPDFURLRect.
* rendering/RenderObject.cpp:
(WebCore::RenderObject::paintFocusRing): Get rid of call to PDF.
(WebCore::RenderObject::addPDFURLRect): Change the signature so it
can be called externally, and calculates the rectangle itself.
(WebCore::RenderObject::paintOutline): Split the calls.
* rendering/RenderObject.h:

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

6 years agoCalling createPattern with a broken image must throw an invalidstate error
cabanier@adobe.com [Wed, 7 May 2014 02:25:00 +0000 (02:25 +0000)]
Calling createPattern with a broken image must throw an invalidstate error
https://bugs.webkit.org/show_bug.cgi?id=132407

Reviewed by Darin Adler.

Source/WebCore:
Updated createPattern so it throws an invalidState exception
if you pass it an image that is in the broken state.

Tests:
* canvas/philip/tests/2d.pattern.image.broken.html:
* canvas/philip/tests/2d.pattern.image.incomplete.empty.html:
* fast/canvas/canvas-empty-image-pattern.html:

* html/canvas/CanvasRenderingContext2D.cpp:
(WebCore::CanvasRenderingContext2D::createPattern):

LayoutTests:
* canvas/philip/tests/2d.pattern.image.broken-expected.txt:
* canvas/philip/tests/2d.pattern.image.broken.html:
* canvas/philip/tests/2d.pattern.image.incomplete.empty-expected.txt:
* canvas/philip/tests/2d.pattern.image.incomplete.empty.html:
* fast/canvas/canvas-empty-image-pattern-expected.txt:
* fast/dom/gc-9-expected.txt:
* fast/dom/gc-9.html:
* platform/mac/canvas/philip/tests/2d.pattern.image.broken-expected.txt: Removed.
* platform/mac/canvas/philip/tests/2d.pattern.image.incomplete.empty-expected.txt: Removed.

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

6 years ago[iOS][Mac] Display sleeps while playing <video> content.
jer.noble@apple.com [Wed, 7 May 2014 01:44:13 +0000 (01:44 +0000)]
[iOS][Mac] Display sleeps while playing <video> content.
https://bugs.webkit.org/show_bug.cgi?id=132624

Reviewed by Darin Adler.

On iOS and Mac, create a DisplaySleepDisablerCocoa rather than an (no-op) DisplaySleepDisabler.

* platform/cocoa/DisplaySleepDisablerCocoa.cpp:
(WebCore::DisplaySleepDisabler::create):
* platform/cocoa/DisplaySleepDisablerCocoa.h:

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

6 years ago[Mac] Allow focus rings to redraw themselves if necessary
dino@apple.com [Wed, 7 May 2014 01:41:57 +0000 (01:41 +0000)]
[Mac] Allow focus rings to redraw themselves if necessary
https://bugs.webkit.org/show_bug.cgi?id=132593

Fix iOS build.

* platform/graphics/mac/GraphicsContextMac.mm:
(WebCore::GraphicsContext::drawFocusRing): We no longer use the color parameter.

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

6 years ago[Mac] Allow focus rings to redraw themselves if necessary
dino@apple.com [Wed, 7 May 2014 01:07:46 +0000 (01:07 +0000)]
[Mac] Allow focus rings to redraw themselves if necessary
https://bugs.webkit.org/show_bug.cgi?id=132593

Reviewed by Simon Fraser.

Source/WebCore:
Mac allows focus rings to change rendering over time. Expose this
functionality to WebKit by having the rendering code detect that
a focused element has asked to repaint itself, and also have
the FocusController object remember how long it has been since
an element was focused.

This patch removes WebCoreNSCellExtras, since a better version is
available in WebKitSystemInterface, and it was going to be cumbersome
to port the code from there into WebKit.

* WebCore.exp.in: Export _wkDrawFocusRingAtTime and _wkDrawCellFocusRingWithFrameAtTime.
* WebCore.xcodeproj/project.pbxproj: Remove WebCoreNSCellExtras.
* page/FocusController.cpp:
(WebCore::FocusController::FocusController): Initialize the repaint timer.
(WebCore::FocusController::~FocusController): Stop the repaint timer on deletion.
(WebCore::FocusController::setFocusedElement): Keep track of the current time when focused.
(WebCore::FocusController::focusedElementNeedsRepaint): Start the repaint timer.
(WebCore::FocusController::focusRepaintTimerFired): Ask the focused element to repaint itself.
(WebCore::FocusController::timeSinceFocusWasSet):
* page/FocusController.h: Expose timeSinceFocusWasSet() and focusedElementNeedsRepaint(), as
well as add the timer for repainting.

* platform/ControlStates.h: Add timeSinceControlWasFocused member variable, allowing the platform
code such as Theme to obtain the value from FocusController.
(WebCore::ControlStates::ControlStates):
(WebCore::ControlStates::timeSinceControlWasFocused):
(WebCore::ControlStates::setTimeSinceControlWasFocused):

* platform/graphics/GraphicsContext.h:
(WebCore::GraphicsContext::drawFocusRing): New Mac-only method that uses timeOffset.

* platform/graphics/mac/GraphicsContextMac.mm:
(WebCore::drawFocusRingToContext): No need to pass in color and radius - these are now
ignored in WKDrawFocusRing. However, I didn't want to change the signature of the
WKSI function.
(WebCore::drawFocusRingToContextAtTime): Call into the new method WKDrawFocusRingAtTime.
(WebCore::GraphicsContext::drawFocusRing): Color and radius no longer used.

* platform/mac/ThemeMac.mm:
(WebCore::checkboxMargins): Update the margins since our focus ring can be a lot bigger.
(WebCore::radioMargins): Ditto.
(WebCore::paintToggleButton): Drawing a focus ring might trigger a repaint too.
(WebCore::buttonMargins): Increase the margins.
(WebCore::paintButton): If our focus ring wants to be drawn again, set the ControlStates flag.

* platform/mac/WebCoreNSCellExtras.h: Removed.
* platform/mac/WebCoreNSCellExtras.m: Removed.

* platform/mac/WebCoreSystemInterface.h: Declare the new methods.
* platform/mac/WebCoreSystemInterface.mm:

* rendering/RenderElement.cpp:
(WebCore::RenderElement::initializeStyle): Expand the overflow rects by the maximum
focus ring width. This might be different from the current outline size.
(WebCore::RenderElement::setStyle): Ditto.

* rendering/RenderObject.cpp:
(WebCore::RenderObject::paintFocusRing): If we're on Mac, use the new drawFocusRing method,
which sets a parameter to true if the focused element needs a repaint.

* rendering/RenderTheme.cpp:
(WebCore::RenderTheme::updateControlStatesForRenderer): Copy the value from FocusController
so that the platform Theme code can use it.

* rendering/RenderTheme.h:
(WebCore::RenderTheme::platformFocusRingMaxWidth): Add a way to get the maximum width
of a focus ring for the platform. This is used to extend the overflow rects.
* rendering/RenderThemeMac.h: Override the focus ring width.
* rendering/RenderThemeMac.mm: On newer versions of OS X, we have a larger focus ring.
(WebCore::RenderThemeMac::platformFocusRingMaxWidth):
(WebCore::RenderThemeMac::paintMenuList): If a menu is focused, and needs a repaint, mark
it as such.

Source/WebKit/mac:
* WebCoreSupport/WebSystemInterface.mm:
(InitWebCoreSystemInterface): Add DrawFocusRingAtTime and DrawCellFocusRingWithFrameAtTime.

Source/WebKit2:
* WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
(InitWebCoreSystemInterface): Add DrawFocusRingAtTime and DrawCellFocusRingWithFrameAtTime.

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

6 years agoAdd test for deleteAllCompiledCode
msaboff@apple.com [Wed, 7 May 2014 00:34:34 +0000 (00:34 +0000)]
Add test for deleteAllCompiledCode
https://bugs.webkit.org/show_bug.cgi?id=132632

Reviewed by Phil Pizlo.

Added two new hooks to jsc, one to call Heap::deleteAllCompiledCode() and
the other to call CodeBlock::optimizeNextInvocation().  Used these two hooks
to write a test that will queue up loads of DFG compiles and then call
Heap::deleteAllCompiledCode() to make sure that it can handle compiled
code as well as code being compiled.

* jsc.cpp:
(GlobalObject::finishCreation):
(functionDeleteAllCompiledCode):
(functionOptimizeNextInvocation):
* runtime/TestRunnerUtils.cpp:
(JSC::optimizeNextInvocation):
* runtime/TestRunnerUtils.h:
* tests/stress/deleteAllCompiledCode.js: Added.
(functionList):
(runTest):

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

6 years ago<rdar://problem/16833442> [iOS WebKit2]: Keep the order of contentView in _scrollView...
benjamin@webkit.org [Wed, 7 May 2014 00:29:29 +0000 (00:29 +0000)]
<rdar://problem/16833442> [iOS WebKit2]: Keep the order of contentView in _scrollView after rotation
https://bugs.webkit.org/show_bug.cgi?id=132634

Reviewed by Enrica Casucci.

Nice idea of Yongjun.

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _beginAnimatedResizeWithUpdates:]):
(-[WKWebView _endAnimatedResize]):

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

6 years agoTake WKView's topContentInset into account when docking Web Inspector to the right.
timothy@apple.com [Wed, 7 May 2014 00:17:00 +0000 (00:17 +0000)]
Take WKView's topContentInset into account when docking Web Inspector to the right.

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

Reviewed by Joseph Pecoraro.

* UIProcess/mac/WebInspectorProxyMac.mm:
(WebKit::WebInspectorProxy::inspectedViewFrameDidChange): Subtract topContentInset
from the height of the frame for the Inspector.

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

6 years ago[iOS][WK2] WebKit2 does not set CanPreventNativeGestures on the platform events
benjamin@webkit.org [Wed, 7 May 2014 00:01:53 +0000 (00:01 +0000)]
[iOS][WK2] WebKit2 does not set CanPreventNativeGestures on the platform events
https://bugs.webkit.org/show_bug.cgi?id=132594

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-05-06
Reviewed by Simon Fraser.

Set CanPreventNativeGestures on the plaform event.
Change the tracking of WKContentView to be similar to WebPageProxy.

* Shared/WebEvent.h:
(WebKit::WebTouchEvent::WebTouchEvent):
(WebKit::WebTouchEvent::canPreventNativeGestures):
(WebKit::WebTouchEvent::setCanPreventNativeGestures):
* Shared/WebEventConversion.cpp:
(WebKit::WebKit2PlatformTouchEvent::WebKit2PlatformTouchEvent):
* Shared/ios/WebTouchEventIOS.cpp:
(WebKit::WebTouchEvent::encode):
(WebKit::WebTouchEvent::decode):
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _webTouchEventsRecognized:]):

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

6 years ago[iOS] Animate AVPlayerLayer into and out of full screen
jer.noble@apple.com [Tue, 6 May 2014 23:36:20 +0000 (23:36 +0000)]
[iOS] Animate AVPlayerLayer into and out of full screen
https://bugs.webkit.org/show_bug.cgi?id=132603

Reviewed by Simon Fraser.

Rather than synchronize animations across the WebProcess / UIProcess boundary, animate
the AVPlayerLayer into place by first resizing the full screen layer to occupy the
entire screen in the WebProcess, and use a sublayerTransform animation in the UIProcess
to scale the AVPlayer from its initial screen location, as well as back to its final screen
location.

* platform/graphics/GeometryUtilities.cpp:
(WebCore::largestRectWithAspectRatioInsideRect): Added utility method.
* platform/graphics/GeometryUtilities.h:
* platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
(-[WebAVVideoLayer init]): Added, initialize video gravity and enable child layer masking.
(-[WebAVVideoLayer setBounds:]): Create a transform to scale the video area.
(WebVideoFullscreenInterfaceAVKit::enterFullscreen): Block implicit animations during setup.
(WebVideoFullscreenInterfaceAVKit::exitFullscreen): Reset the gravity to ResizeAspect
    if necessary.

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

6 years agoMake BlobDataItem use a refcounted object for files
ap@apple.com [Tue, 6 May 2014 23:34:35 +0000 (23:34 +0000)]
Make BlobDataItem use a refcounted object for files
https://bugs.webkit.org/show_bug.cgi?id=132628

Reviewed by Anders Carlsson.

* CMakeLists.txt:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
Added BlobDataFileReference.{h|cpp}

* WebCore.exp.in: Removed unused exports.

* platform/network/BlobData.h:
(WebCore::BlobDataItem::offset):
(WebCore::BlobDataItem::BlobDataItem):
Use a wrapper class for files, not a path. Changed to be more class-like accordingly.

* platform/network/BlobData.cpp:
(WebCore::BlobData::appendData):
(WebCore::BlobData::appendFile):
(WebCore::BlobData::appendBlob): Deleted.
(WebCore::BlobData::BlobData): Deleted.
We never add blobs to BlobData, they are always resolved to data of file references.
Lots of very confusing code to delete.

* platform/network/BlobDataFileReference.h: Added.
* platform/network/BlobDataFileReference.cpp: Added.
(WebCore::BlobDataFileReference::size):
(WebCore::BlobDataFileReference::expectedModificationTime):
(WebCore::BlobDataFileReference::computeFileSystemData):
A unique reference to a file referenced by blob, to be preserved when you slice
or combine blobs.

* platform/network/BlobRegistryImpl.cpp:
(WebCore::BlobRegistryImpl::appendStorageItems):
(WebCore::BlobRegistryImpl::registerFileBlobURL):
(WebCore::BlobRegistryImpl::registerBlobURL):
(WebCore::BlobRegistryImpl::blobSize):
* platform/network/BlobResourceHandle.cpp:
(WebCore::BlobResourceHandle::getSizeForNext):
(WebCore::BlobResourceHandle::didGetSize):
(WebCore::BlobResourceHandle::readDataSync):
(WebCore::BlobResourceHandle::readFileSync):
(WebCore::BlobResourceHandle::readDataAsync):
(WebCore::BlobResourceHandle::readFileAsync):
* platform/network/BlobResourceHandle.h:
* platform/network/FormData.cpp:
(WebCore::appendBlobResolved):
Updated for BlobDataItem interface changes.

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

6 years ago[HTML] Default argument to HTMLTableRowElement.insertCell() should be -1
ch.dumez@samsung.com [Tue, 6 May 2014 23:32:51 +0000 (23:32 +0000)]
[HTML] Default argument to HTMLTableRowElement.insertCell() should be -1
https://bugs.webkit.org/show_bug.cgi?id=132615

Reviewed by Darin Adler.

Source/WebCore:
HTMLTableRowElement.insertCell()'s argument default value should be -1, not
0, as per the specification:
http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#the-tr-element

The new behavior matches the one of Firefox 29 and IE11, and soon Blink:
https://codereview.chromium.org/263323004/

Test: fast/dom/HTMLTableRowElement/insertCell-default-argument.html

* html/HTMLTableRowElement.h:
* html/HTMLTableRowElement.idl:

LayoutTests:
Add layout test to test that the default argument to
HTMLTableRowElement.insertCell() is -1.

* fast/dom/HTMLTableRowElement/insertCell-default-argument-expected.txt: Added.
* fast/dom/HTMLTableRowElement/insertCell-default-argument.html: Added.

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

6 years agoFix build.
oliver@apple.com [Tue, 6 May 2014 23:11:00 +0000 (23:11 +0000)]
Fix build.

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

6 years ago[iOS][WK2] Add tap highlight on the simple UITapGestureRecognizer
benjamin@webkit.org [Tue, 6 May 2014 22:53:12 +0000 (22:53 +0000)]
[iOS][WK2] Add tap highlight on the simple UITapGestureRecognizer
https://bugs.webkit.org/show_bug.cgi?id=132623
<rdar://problem/16709507>

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-05-06
Reviewed by Enrica Casucci.

Add a low latency highlight for tap/click.

* UIProcess/PageClient.h:
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* UIProcess/ios/PageClientImplIOS.h:
* UIProcess/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::commitPotentialTapFailed):
* UIProcess/ios/WKContentViewInteraction.h:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView setupInteraction]):
(-[WKContentView _showTapHighlightWithColor:WebCore::quads:WebCore::topLeftRadius:WebCore::topRightRadius:WebCore::bottomLeftRadius:WebCore::bottomRightRadius:WebCore::]):
(-[WKContentView _didGetTapHighlightForRequest:color:WebCore::quads:WebCore::topLeftRadius:WebCore::topRightRadius:WebCore::bottomLeftRadius:WebCore::bottomRightRadius:WebCore::]):
(-[WKContentView _finishInteraction]):
(-[WKContentView _highlightLongPressRecognized:]):
(-[WKContentView _singleTapRecognized:]):
(-[WKContentView _singleTapDidReset:]):
(-[WKContentView _commitPotentialTapFailed]):
(-[WKContentView _singleTapCommited:]):
(-[WKContentView _attemptClickAtLocation:]):
* UIProcess/ios/WKSyntheticClickTapGestureRecognizer.h: Added.
* UIProcess/ios/WKSyntheticClickTapGestureRecognizer.m: Added.
(-[WKSyntheticClickTapGestureRecognizer setGestureRecognizedTarget:action:]):
(-[WKSyntheticClickTapGestureRecognizer setResetTarget:action:]):
(-[WKSyntheticClickTapGestureRecognizer setState:]):
(-[WKSyntheticClickTapGestureRecognizer reset]):
* UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::potentialTapAtPosition):
(WebKit::WebPageProxy::commitPotentialTap):
(WebKit::WebPageProxy::cancelPotentialTap):
(WebKit::WebPageProxy::tapHighlightAtPosition):
(WebKit::WebPageProxy::commitPotentialTapFailed):
* WebKit2.xcodeproj/project.pbxproj:
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in:
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::handleSyntheticClick):
(WebKit::WebPage::handleTap):
(WebKit::WebPage::sendTapHighlightForNodeIfNecessary):
(WebKit::WebPage::potentialTapAtPosition):
(WebKit::WebPage::commitPotentialTap):
(WebKit::WebPage::cancelPotentialTap):
(WebKit::WebPage::tapHighlightAtPosition):

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

6 years agoPut WebArchive and WebArchiveResource in the API namespace.
andersca@apple.com [Tue, 6 May 2014 22:44:56 +0000 (22:44 +0000)]
Put WebArchive and WebArchiveResource in the API namespace.

Rubber-stamped by Dan Bernstein.

* Shared/API/c/WKSharedAPICast.h:
* Shared/API/c/mac/WKWebArchive.cpp:
(WKWebArchiveGetTypeID):
(WKWebArchiveCreate):
(WKWebArchiveCreateWithData):
(WKWebArchiveCreateFromRange):
(WKWebArchiveCopyMainResource):
* Shared/API/c/mac/WKWebArchiveResource.cpp:
(WKWebArchiveResourceGetTypeID):
(WKWebArchiveResourceCreate):
* Shared/APIWebArchive.cpp: Renamed from Source/WebKit2/Shared/WebArchive.cpp.
(API::WebArchive::create):
(API::WebArchive::WebArchive):
(API::WebArchive::~WebArchive):
(API::WebArchive::mainResource):
(API::WebArchive::subresources):
(API::WebArchive::subframeArchives):
(API::releaseCFData):
(API::WebArchive::data):
(API::WebArchive::coreLegacyWebArchive):
* Shared/APIWebArchive.h: Renamed from Source/WebKit2/Shared/WebArchive.h.
* Shared/APIWebArchiveResource.cpp: Renamed from Source/WebKit2/Shared/WebArchiveResource.cpp.
(API::WebArchiveResource::create):
(API::WebArchiveResource::WebArchiveResource):
(API::WebArchiveResource::~WebArchiveResource):
(API::releaseCFData):
(API::WebArchiveResource::data):
(API::WebArchiveResource::URL):
(API::WebArchiveResource::MIMEType):
(API::WebArchiveResource::textEncoding):
(API::WebArchiveResource::coreArchiveResource):
* Shared/APIWebArchiveResource.h: Renamed from Source/WebKit2/Shared/WebArchiveResource.h.
* WebKit2.xcodeproj/project.pbxproj:

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

6 years agoAdd missing line from r168384.
akling@apple.com [Tue, 6 May 2014 22:27:23 +0000 (22:27 +0000)]
Add missing line from r168384.

* dom/ContainerNode.h:
(WebCore::ChildNodesLazySnapshot::~ChildNodesLazySnapshot):

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

6 years agoCan't make a booking at virginamerica.com
oliver@apple.com [Tue, 6 May 2014 22:17:04 +0000 (22:17 +0000)]
Can't make a booking at virginamerica.com
https://bugs.webkit.org/show_bug.cgi?id=132626

Reviewed by Geoffrey Garen.

Source/WebCore:
Test: fast/dom/assign-to-prototype-accessor-on-prototype-should-be-silent.html

We can't throw an exception when a site incorrectly attempts
to use a dom property setter directly on the prototype as
there are sites that do this as compatibility workarounds
for old browsers. Instead we treat use of the setter on
the prototype object in the same way we do getters, and just
log a warning to the console.

* bindings/js/JSDOMBinding.cpp:
(WebCore::reportDeprecatedSetterError):
* bindings/js/JSDOMBinding.h:
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateImplementation):
* bindings/scripts/test/JS/JSTestInterface.cpp:
(WebCore::setJSTestInterfaceImplementsStr2):
(WebCore::setJSTestInterfaceImplementsStr3):
(WebCore::setJSTestInterfaceImplementsNode):
(WebCore::setJSTestInterfaceSupplementalStr2):
(WebCore::setJSTestInterfaceSupplementalStr3):
(WebCore::setJSTestInterfaceSupplementalNode):
* bindings/scripts/test/JS/JSTestNondeterministic.cpp:
(WebCore::setJSTestNondeterministicNondeterministicWriteableAttr):
(WebCore::setJSTestNondeterministicNondeterministicExceptionAttr):
(WebCore::setJSTestNondeterministicNondeterministicGetterExceptionAttr):
(WebCore::setJSTestNondeterministicNondeterministicSetterExceptionAttr):
* bindings/scripts/test/JS/JSTestObj.cpp:
(WebCore::setJSTestObjTestSubObjEnabledBySettingConstructor):
(WebCore::setJSTestObjEnumAttr):
(WebCore::setJSTestObjByteAttr):
(WebCore::setJSTestObjOctetAttr):
(WebCore::setJSTestObjShortAttr):
(WebCore::setJSTestObjUnsignedShortAttr):
(WebCore::setJSTestObjLongAttr):
(WebCore::setJSTestObjLongLongAttr):
(WebCore::setJSTestObjUnsignedLongLongAttr):
(WebCore::setJSTestObjStringAttr):
(WebCore::setJSTestObjTestObjAttr):
(WebCore::setJSTestObjXMLObjAttr):
(WebCore::setJSTestObjCreate):
(WebCore::setJSTestObjReflectedStringAttr):
(WebCore::setJSTestObjReflectedIntegralAttr):
(WebCore::setJSTestObjReflectedUnsignedIntegralAttr):
(WebCore::setJSTestObjReflectedBooleanAttr):
(WebCore::setJSTestObjReflectedURLAttr):
(WebCore::setJSTestObjReflectedCustomIntegralAttr):
(WebCore::setJSTestObjReflectedCustomBooleanAttr):
(WebCore::setJSTestObjReflectedCustomURLAttr):
(WebCore::setJSTestObjTypedArrayAttr):
(WebCore::setJSTestObjAttrWithGetterException):
(WebCore::setJSTestObjAttrWithSetterException):
(WebCore::setJSTestObjStringAttrWithGetterException):
(WebCore::setJSTestObjStringAttrWithSetterException):
(WebCore::setJSTestObjCustomAttr):
(WebCore::setJSTestObjWithScriptStateAttribute):
(WebCore::setJSTestObjWithScriptExecutionContextAttribute):
(WebCore::setJSTestObjWithScriptStateAttributeRaises):
(WebCore::setJSTestObjWithScriptExecutionContextAttributeRaises):
(WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttribute):
(WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
(WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
(WebCore::setJSTestObjWithScriptArgumentsAndCallStackAttribute):
(WebCore::setJSTestObjConditionalAttr1):
(WebCore::setJSTestObjConditionalAttr2):
(WebCore::setJSTestObjConditionalAttr3):
(WebCore::setJSTestObjConditionalAttr4Constructor):
(WebCore::setJSTestObjConditionalAttr5Constructor):
(WebCore::setJSTestObjConditionalAttr6Constructor):
(WebCore::setJSTestObjAnyAttribute):
(WebCore::setJSTestObjMutablePoint):
(WebCore::setJSTestObjImmutablePoint):
(WebCore::setJSTestObjStrawberry):
(WebCore::setJSTestObjStrictFloat):
(WebCore::setJSTestObjId):
(WebCore::setJSTestObjReplaceableAttribute):
(WebCore::setJSTestObjNullableLongSettableAttribute):
(WebCore::setJSTestObjNullableStringValue):
(WebCore::setJSTestObjAttributeWithReservedEnumType):
* bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
(WebCore::setJSTestSerializedScriptValueInterfaceValue):
(WebCore::setJSTestSerializedScriptValueInterfaceCachedValue):
* bindings/scripts/test/JS/JSTestTypedefs.cpp:
(WebCore::setJSTestTypedefsUnsignedLongLongAttr):
(WebCore::setJSTestTypedefsImmutableSerializedScriptValue):
(WebCore::setJSTestTypedefsAttrWithGetterException):
(WebCore::setJSTestTypedefsAttrWithSetterException):
(WebCore::setJSTestTypedefsStringAttrWithGetterException):
(WebCore::setJSTestTypedefsStringAttrWithSetterException):

LayoutTests:
Add testcase to make sure that we are silently ignoring usage
of prototype setters and the prototype itself. We dump a warning
to the console as throwing an exception breaks sites that used
to rely on essentially no-op behavior.

* fast/dom/assign-to-prototype-accessor-on-prototype-should-be-silent-expected.txt: Added.
* fast/dom/assign-to-prototype-accessor-on-prototype-should-be-silent.html: Added.

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

6 years agoJSString::toAtomicString() should return AtomicString.
akling@apple.com [Tue, 6 May 2014 22:16:22 +0000 (22:16 +0000)]
JSString::toAtomicString() should return AtomicString.
<https://webkit.org/b/132627>

Remove premature optimization where I was trying to avoid refcount
churn when returning an already atomicized String.

Instead of using reinterpret_cast to mangle the String member into
a const AtomicString& return value, just return AtomicString.

Reviewed by Geoff Garen.

* runtime/JSString.h:
(JSC::JSString::toAtomicString):

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

6 years agoChildNodesLazySnapshot::m_childNodes needs two heap allocations.
akling@apple.com [Tue, 6 May 2014 22:13:45 +0000 (22:13 +0000)]
ChildNodesLazySnapshot::m_childNodes needs two heap allocations.
<https://webkit.org/b/132616>

This seems a bit silly, since ChildNodesLazySnapshot is always
allocated on the stack.

Change it to be a bool + a Vector instead of using the nullity
as a presence indicator. This way we also don't end up with an
out-of-line ~OwnPtr for the Vector.

Reviewed by Geoff Garen.

* dom/ContainerNode.h:
(WebCore::ChildNodesLazySnapshot::ChildNodesLazySnapshot):
(WebCore::ChildNodesLazySnapshot::nextNode):
(WebCore::ChildNodesLazySnapshot::takeSnapshot):
(WebCore::ChildNodesLazySnapshot::hasSnapshot):

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

6 years agoEliminate BlobStorageData
ap@apple.com [Tue, 6 May 2014 22:11:07 +0000 (22:11 +0000)]
Eliminate BlobStorageData
https://bugs.webkit.org/show_bug.cgi?id=132617

Reviewed by Anders Carlsson.

* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
* platform/network/BlobData.h:
(WebCore::BlobData::create):
(WebCore::BlobData::BlobData):
* platform/network/BlobRegistryImpl.cpp:
(WebCore::loadResourceSynchronously):
(WebCore::BlobRegistryImpl::appendStorageItems):
(WebCore::BlobRegistryImpl::registerFileBlobURL):
(WebCore::BlobRegistryImpl::registerBlobURL):
(WebCore::BlobRegistryImpl::registerBlobURLForSlice):
(WebCore::BlobRegistryImpl::getBlobDataFromURL):
(WebCore::BlobRegistryImpl::blobSize):
* platform/network/BlobRegistryImpl.h:
* platform/network/BlobResourceHandle.cpp:
(WebCore::BlobResourceHandle::createAsync):
(WebCore::BlobResourceHandle::loadResourceSynchronously):
(WebCore::BlobResourceHandle::BlobResourceHandle):
(WebCore::BlobResourceHandle::doStart):
(WebCore::BlobResourceHandle::getSizeForNext):
(WebCore::BlobResourceHandle::didGetSize):
(WebCore::BlobResourceHandle::seek):
(WebCore::BlobResourceHandle::readSync):
(WebCore::BlobResourceHandle::readDataSync):
(WebCore::BlobResourceHandle::readFileSync):
(WebCore::BlobResourceHandle::readAsync):
(WebCore::BlobResourceHandle::readDataAsync):
(WebCore::BlobResourceHandle::readFileAsync):
(WebCore::BlobResourceHandle::notifyResponseOnSuccess):
* platform/network/BlobResourceHandle.h:
* platform/network/BlobStorageData.h: Removed.
* platform/network/FormData.cpp:
(WebCore::appendBlobResolved):
* platform/network/soup/ResourceHandleSoup.cpp:
(WebCore::addEncodedBlobToSoupMessageBody):

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

6 years agoFix the iOS build.
simon.fraser@apple.com [Tue, 6 May 2014 21:45:08 +0000 (21:45 +0000)]
Fix the iOS build.

WebCore::Editor::replaceNodeFromPasteboard(WebCore::Node*, WTF::String const&) is Mac-only.
Also sort the export file.

* WebCore.exp.in:

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

6 years agoBegin Removal of Old Multi-Column Code.
hyatt@apple.com [Tue, 6 May 2014 21:35:52 +0000 (21:35 +0000)]
Begin Removal of Old Multi-Column Code.
https://bugs.webkit.org/show_bug.cgi?id=132480

Reviewed by Andreas Kling.

Source/WebCore:
* dom/Document.cpp:
(WebCore::Document::regionBasedColumnsEnabled): Deleted.
* dom/Document.h:
* page/FrameView.cpp:
(WebCore::updateLayerPositionFlags):
* page/Settings.in:
* rendering/LayoutState.cpp:
(WebCore::LayoutState::LayoutState):
(WebCore::LayoutState::clearPaginationInformation):
(WebCore::LayoutState::addForcedColumnBreak): Deleted.
* rendering/LayoutState.h:
(WebCore::LayoutState::LayoutState):
(WebCore::LayoutState::isPaginatingColumns): Deleted.
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::~RenderBlock):
(WebCore::RenderBlock::addChildToContinuation):
(WebCore::RenderBlock::addChild):
(WebCore::RenderBlock::addChildIgnoringContinuation):
(WebCore::RenderBlock::removeLeftoverAnonymousBlock):
(WebCore::canMergeContiguousAnonymousBlocks):
(WebCore::RenderBlock::removeChild):
(WebCore::RenderBlock::recomputeLogicalWidth):
(WebCore::RenderBlock::addOverflowFromChildren):
(WebCore::RenderBlock::expandsToEncloseOverhangingFloats):
(WebCore::RenderBlock::simplifiedLayout):
(WebCore::RenderBlock::layoutPositionedObjects):
(WebCore::RenderBlock::paintObject):
(WebCore::RenderBlock::selectionGaps):
(WebCore::RenderBlock::nodeAtPoint):
(WebCore::RenderBlock::offsetForContents):
(WebCore::RenderBlock::computeIntrinsicLogicalWidths):
(WebCore::RenderBlock::createAnonymousBoxWithSameTypeAs):
(WebCore::RenderBlock::childBoxIsUnsplittableForFragmentation):
(WebCore::RenderBlock::renderName):
(WebCore::RenderBlock::addChildToAnonymousColumnBlocks): Deleted.
(WebCore::RenderBlock::containingColumnsBlock): Deleted.
(WebCore::RenderBlock::splitFlow): Deleted.
(WebCore::RenderBlock::makeChildrenAnonymousColumnBlocks): Deleted.
(WebCore::RenderBlock::columnsBlockForSpanningElement): Deleted.
(WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks): Deleted.
(WebCore::RenderBlock::updateLogicalWidthAndColumnWidth): Deleted.
(WebCore::RenderBlock::isTopLayoutOverflowAllowed): Deleted.
(WebCore::RenderBlock::isLeftLayoutOverflowAllowed): Deleted.
(WebCore::RenderBlock::paintColumnRules): Deleted.
(WebCore::RenderBlock::initialBlockOffsetForPainting): Deleted.
(WebCore::RenderBlock::blockDeltaForPaintingNextColumn): Deleted.
(WebCore::RenderBlock::paintColumnContents): Deleted.
(WebCore::ColumnRectIterator::ColumnRectIterator): Deleted.
(WebCore::ColumnRectIterator::advance): Deleted.
(WebCore::ColumnRectIterator::columnRect): Deleted.
(WebCore::ColumnRectIterator::hasMore): Deleted.
(WebCore::ColumnRectIterator::adjust): Deleted.
(WebCore::ColumnRectIterator::update): Deleted.
(WebCore::RenderBlock::hitTestColumns): Deleted.
(WebCore::RenderBlock::adjustForColumnRect): Deleted.
(WebCore::RenderBlock::availableLogicalWidth): Deleted.
(WebCore::RenderBlock::columnGap): Deleted.
(WebCore::RenderBlock::computeColumnCountAndWidth): Deleted.
(WebCore::RenderBlock::requiresColumns): Deleted.
(WebCore::RenderBlock::setComputedColumnCountAndWidth): Deleted.
(WebCore::RenderBlock::updateColumnProgressionFromStyle): Deleted.
(WebCore::RenderBlock::computedColumnWidth): Deleted.
(WebCore::RenderBlock::computedColumnCount): Deleted.
(WebCore::RenderBlock::columnInfo): Deleted.
(WebCore::RenderBlock::columnCount): Deleted.
(WebCore::RenderBlock::columnRectAt): Deleted.
(WebCore::RenderBlock::adjustPointToColumnContents): Deleted.
(WebCore::RenderBlock::adjustRectForColumns): Deleted.
(WebCore::RenderBlock::flipForWritingModeIncludingColumns): Deleted.
(WebCore::RenderBlock::adjustStartEdgeForWritingModeIncludingColumns): Deleted.
(WebCore::RenderBlock::adjustForColumns): Deleted.
(WebCore::RenderBlock::adjustIntrinsicLogicalWidthsForColumns): Deleted.
(WebCore::RenderBlock::paginationUnit): Deleted.
(WebCore::RenderBlock::createAnonymousColumnsWithParentRenderer): Deleted.
(WebCore::RenderBlock::createAnonymousColumnSpanWithParentRenderer): Deleted.
(WebCore::RenderBlock::computeLineGridPaginationOrigin): Deleted.
* rendering/RenderBlock.h:
(WebCore::RenderBlock::pixelSnappedLogicalRightOffsetForLine):
(WebCore::RenderBlock::createAnonymousBlock):
(WebCore::RenderBlock::paintColumnRules):
(WebCore::RenderBlock::createAnonymousColumnsBlock): Deleted.
(WebCore::RenderBlock::createAnonymousColumnSpanBlock): Deleted.
* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::adjustIntrinsicLogicalWidthsForColumns):
(WebCore::RenderBlockFlow::computeIntrinsicLogicalWidths):
(WebCore::RenderBlockFlow::recomputeLogicalWidthAndColumnWidth):
(WebCore::RenderBlockFlow::columnGap):
(WebCore::RenderBlockFlow::computeColumnCountAndWidth):
(WebCore::RenderBlockFlow::layoutBlock):
(WebCore::inNormalFlow):
(WebCore::RenderBlockFlow::applyBeforeBreak):
(WebCore::RenderBlockFlow::applyAfterBreak):
(WebCore::RenderBlockFlow::updateMinimumPageHeight):
(WebCore::RenderBlockFlow::computeOverflow):
(WebCore::RenderBlockFlow::addOverhangingFloats):
(WebCore::RenderBlockFlow::hasOverhangingFloat):
(WebCore::RenderBlockFlow::relayoutForPagination):
(WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
(WebCore::RenderBlockFlow::requiresColumns):
(WebCore::RenderBlockFlow::setComputedColumnCountAndWidth):
(WebCore::RenderBlockFlow::updateColumnProgressionFromStyle):
(WebCore::RenderBlockFlow::computedColumnWidth):
(WebCore::RenderBlockFlow::computedColumnCount):
* rendering/RenderBlockFlow.h:
(WebCore::RenderBlockFlow::hasOverhangingFloats):
* rendering/RenderBox.cpp:
(WebCore::RenderBox::styleDidChange):
(WebCore::RenderBox::offsetFromContainer):
(WebCore::RenderBox::computeRectForRepaint):
(WebCore::RenderBox::layoutOverflowRectForPropagation):
* rendering/RenderBox.h:
* rendering/RenderBoxModelObject.cpp:
(WebCore::RenderBoxModelObject::adjustedPositionRelativeToOffsetParent):
(WebCore::RenderBoxModelObject::mapAbsoluteToLocalPoint):
* rendering/RenderBoxModelObject.h:
(WebCore::RenderBoxModelObject::canHaveBoxInfoInRegion):
* rendering/RenderFlexibleBox.cpp:
(WebCore::RenderFlexibleBox::layoutBlock):
* rendering/RenderFlowThread.h:
* rendering/RenderGeometryMap.cpp:
(WebCore::canMapBetweenRenderers):
* rendering/RenderInline.cpp:
(WebCore::RenderInline::clippedOverflowRectForRepaint):
(WebCore::RenderInline::computeRectForRepaint):
(WebCore::RenderInline::offsetFromContainer):
(WebCore::RenderInline::mapLocalToContainer):
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::RenderLayer):
(WebCore::RenderLayer::updateLayerPositions):
(WebCore::RenderLayer::updatePagination):
(WebCore::accumulateOffsetTowardsAncestor):
(WebCore::RenderLayer::paintList):
(WebCore::RenderLayer::hitTestList):
(WebCore::checkContainingBlockChainForPagination): Deleted.
(WebCore::RenderLayer::useRegionBasedColumns): Deleted.
(WebCore::RenderLayer::paintPaginatedChildLayer): Deleted.
(WebCore::RenderLayer::paintChildLayerIntoColumns): Deleted.
(WebCore::RenderLayer::hitTestPaginatedChildLayer): Deleted.
(WebCore::RenderLayer::hitTestChildLayerColumns): Deleted.
* rendering/RenderLayer.h:
* rendering/RenderMultiColumnFlowThread.cpp:
(WebCore::RenderMultiColumnFlowThread::shouldCheckColumnBreaks):
* rendering/RenderMultiColumnFlowThread.h:
* rendering/RenderObject.cpp:
(WebCore::RenderObject::computeRectForRepaint):
(WebCore::RenderObject::mapLocalToContainer):
(WebCore::RenderObject::pushMappingToContainer):
(WebCore::RenderObject::offsetFromContainer):
* rendering/RenderObject.h:
(WebCore::RenderObject::isAnonymousBlock):
(WebCore::RenderObject::RenderObjectBitfields::RenderObjectBitfields):
(WebCore::RenderObject::hasColumns): Deleted.
(WebCore::RenderObject::setHasColumns): Deleted.
(WebCore::RenderObject::isAnonymousColumnsBlock): Deleted.
(WebCore::RenderObject::isAnonymousColumnSpanBlock): Deleted.
(WebCore::RenderObject::adjustForColumns): Deleted.
(WebCore::RenderObject::offsetForColumns): Deleted.
* rendering/RenderText.cpp:
(WebCore::RenderText::selectionRectForRepaint):
* rendering/RenderView.cpp:
(WebCore::RenderView::availableLogicalHeight):
(WebCore::RenderView::pageOrViewLogicalHeight):
(WebCore::RenderView::unextendedBackgroundRect):
(WebCore::RenderView::backgroundRect):
(WebCore::RenderView::shouldDisableLayoutStateForSubtree):
(WebCore::RenderView::pageNumberForBlockProgressionOffset):
(WebCore::RenderView::pageCount):
(WebCore::RenderView::paginationUnit): Deleted.
* rendering/RenderView.h:
(WebCore::LayoutStateMaintainer::LayoutStateMaintainer):
(WebCore::LayoutStateMaintainer::push):
* rendering/SimpleLineLayout.cpp:
(WebCore::SimpleLineLayout::canUseFor):
* rendering/svg/RenderSVGText.cpp:
(WebCore::RenderSVGText::layout):
* style/StyleResolveForDocument.cpp:
(WebCore::Style::resolveForDocument):

LayoutTests:
* platform/mac/fast/multicol/client-rects-expected.png:
* platform/mac/fast/multicol/client-rects-expected.txt:
* platform/mac/fast/multicol/client-rects-spanners-complex-expected.png:
* platform/mac/fast/multicol/client-rects-spanners-complex-expected.txt:
* platform/mac/fast/multicol/client-rects-spanners-expected.png:
* platform/mac/fast/multicol/client-rects-spanners-expected.txt:
* platform/mac/fast/multicol/newmulticol/client-rects-expected.png:
* platform/mac/fast/multicol/newmulticol/client-rects-expected.txt:

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

6 years agoPut the symlink in the right place.
andersca@apple.com [Tue, 6 May 2014 21:32:25 +0000 (21:32 +0000)]
Put the symlink in the right place.

* WebKit.xcodeproj/project.pbxproj:

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

6 years agoDon't select an image that is about to have its menu shown.
beidson@apple.com [Tue, 6 May 2014 21:08:14 +0000 (21:08 +0000)]
Don't select an image that is about to have its menu shown.
<rdar://problem/16807845> and https://bugs.webkit.org/show_bug.cgi?id=132579

Reviewed by Tim Horton.

Source/WebCore:
* WebCore.exp.in:

* editing/Editor.h:
* editing/mac/EditorMac.mm:
(WebCore::Editor::replaceNodeFromPasteboard): New method that first selects
  the Node and then immediately pastes over it. Since it’s synchronous the
  selection never has a chance to paint.

* html/shadow/mac/ImageControlsButtonElementMac.cpp:
(WebCore::ImageControlsButtonElementMac::defaultEventHandler): Don’t select the image.

Source/WebKit/mac:
* Misc/WebSharingServicePickerController.mm:
(-[WebSharingServicePickerController didShareImageData:confirmDataIsValidTIFFData:]):
  Call the new replaceNodeFromPasteboard API instead of readSelectionFromPasteboard.

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

6 years ago[Mac] make metadata cue attributes consistent
eric.carlson@apple.com [Tue, 6 May 2014 20:19:31 +0000 (20:19 +0000)]
[Mac] make metadata cue attributes consistent
https://bugs.webkit.org/show_bug.cgi?id=132610

Reviewed by Jer Noble.

Source/WebCore:
No new tests, updated http/tests/media/track-in-band-hls-metadata.html.

* platform/mac/SerializedPlatformRepresentationMac.mm:
(WebCore::jsValueWithAVMetadataItemInContext): Don't include keys @dataTypeNamespace
    or @pictureType, @dataType -> @type.

LayoutTests:
* http/tests/media/track-in-band-hls-metadata-expected.txt:
* http/tests/media/track-in-band-hls-metadata.html:

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

6 years ago"Flash of content without image" when pasting a raw image from the pasteboard
beidson@apple.com [Tue, 6 May 2014 20:10:01 +0000 (20:10 +0000)]
"Flash of content without image" when pasting a raw image from the pasteboard
<rdar://problem/16826199> and https://bugs.webkit.org/show_bug.cgi?id=132612

Reviewed by Tim Horton.

Let an ArchiveResource be flagged as "should load immediately":
* loader/archive/ArchiveResource.cpp:
(WebCore::ArchiveResource::ArchiveResource):
* loader/archive/ArchiveResource.h:
(WebCore::ArchiveResource::setShouldLoadImmediately):
(WebCore::ArchiveResource::shouldLoadImmediately):

Set that flag on the ArchiveResource for the image.
Note we quite explicitly do this only in the "read a single image" from the pasteboard
case, because we don't want to do this synchronous step for multiple images at once
such as when pasting a WebArchive:
* editing/mac/EditorMac.mm:
(WebCore::Editor::WebContentReader::readImage):

When creating a new CachedResource, if there is an ArchiveResource that is set to
load immediately, populate the CachedResource immediately instead of scheduling a load:
* loader/cache/CachedResourceLoader.cpp:
(WebCore::CachedResourceLoader::requestResource):

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

6 years ago[CSSRegions] Enabled regions performance tests by default
stavila@adobe.com [Tue, 6 May 2014 19:48:53 +0000 (19:48 +0000)]
[CSSRegions] Enabled regions performance tests by default
https://bugs.webkit.org/show_bug.cgi?id=128244

Reviewed by Andreas Kling.

Enabled regions performance tests.

* Skipped:

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

6 years agoRoll out r167889
mhahnenberg@apple.com [Tue, 6 May 2014 19:15:42 +0000 (19:15 +0000)]
Roll out r167889

Rubber stamped by Geoff Garen.

It broke some websites.

Source/JavaScriptCore:
* runtime/JSPropertyNameIterator.cpp:
(JSC::JSPropertyNameIterator::create):
* runtime/PropertyMapHashTable.h:
(JSC::PropertyTable::hasDeletedOffset):
(JSC::PropertyTable::hadDeletedOffset): Deleted.
* runtime/Structure.cpp:
(JSC::Structure::Structure):
(JSC::Structure::materializePropertyMap):
(JSC::Structure::removePropertyTransition):
(JSC::Structure::changePrototypeTransition):
(JSC::Structure::despecifyFunctionTransition):
(JSC::Structure::attributeChangeTransition):
(JSC::Structure::toDictionaryTransition):
(JSC::Structure::preventExtensionsTransition):
(JSC::Structure::addPropertyWithoutTransition):
(JSC::Structure::removePropertyWithoutTransition):
(JSC::Structure::pin):
(JSC::Structure::pinAndPreventTransitions): Deleted.
* runtime/Structure.h:
* runtime/StructureInlines.h:
(JSC::Structure::setEnumerationCache):
(JSC::Structure::propertyTable):
(JSC::Structure::checkOffsetConsistency):
(JSC::Structure::hadDeletedOffsets): Deleted.
* tests/stress/for-in-after-delete.js:
(foo): Deleted.

LayoutTests:
* js/regress/delete-a-few-properties-then-get-by-id-expected.txt:
* js/regress/delete-a-few-properties-then-get-by-id.html:
* js/regress/script-tests/delete-a-few-properties-then-get-by-id.js:
(MyObject): Deleted.
(foo): Deleted.

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

6 years agoMove the WebKitLegacy header check to the right file
andersca@apple.com [Tue, 6 May 2014 19:14:19 +0000 (19:14 +0000)]
Move the WebKitLegacy header check to the right file
https://bugs.webkit.org/show_bug.cgi?id=132620
<rdar://problem/16815716>

Reviewed by Dan Bernstein.

* WebKitLegacy/MigrateHeadersFromWebKitLegacy.make:
* WebKitLegacy/WebKit.h:

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

6 years agoUnreviewed build fix for debug after r168367.
achristensen@apple.com [Tue, 6 May 2014 18:32:31 +0000 (18:32 +0000)]
Unreviewed build fix for debug after r168367.

* platform/NotImplemented.cpp:
Added include NotImplemented.h.

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

6 years agoRemoved unnecessary notImplemented.h includes.
enrica@apple.com [Tue, 6 May 2014 18:30:18 +0000 (18:30 +0000)]
Removed unnecessary notImplemented.h includes.
https://bugs.webkit.org/show_bug.cgi?id=132587

Patch by Alex Christensen <achristensen@webkit.org> on 2014-05-06
Reviewed by Anders Carlsson.

* Modules/webdatabase/Database.cpp:
* accessibility/AccessibilityObject.cpp:
* bindings/js/Dictionary.h:
* bindings/js/SerializedScriptValue.cpp:
* html/HTMLMediaSession.cpp:
* html/ImageDocument.cpp:
* html/parser/HTMLFormattingElementList.cpp:
* loader/appcache/ApplicationCacheStorage.cpp:
* page/mac/EventHandlerMac.mm:
* platform/NotImplemented.cpp:
* platform/audio/ios/MediaSessionManagerIOS.mm:
* platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
* platform/graphics/mac/GraphicsContext3DMac.mm:
* platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
* platform/ios/PlatformScreenIOS.mm:
* platform/mac/PlatformScreenMac.mm:
* platform/mac/WidgetMac.mm:
* platform/mediastream/MediaStreamTrackPrivate.cpp:
* platform/mediastream/mac/AVCaptureDeviceManager.mm:
* platform/mediastream/mac/AVMediaCaptureSource.mm:
* rendering/RenderGrid.cpp:
* workers/SharedWorkerGlobalScope.cpp:
* workers/WorkerGlobalScope.cpp:
* workers/WorkerMessagingProxy.cpp:
Removed notImplemented from list of includes.

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

6 years ago[GTK] Unreviewed GTK gardening
commit-queue@webkit.org [Tue, 6 May 2014 18:30:07 +0000 (18:30 +0000)]
[GTK] Unreviewed GTK gardening

Rebaseline affected tests by the modifications done to
inline SVG sizing behavior introduced on r168350.

Patch by Lorenzo Tilve <ltilve@igalia.com> on 2014-05-06

* platform/gtk/svg/custom/bug45331-expected.txt:
* platform/gtk/svg/custom/external-paintserver-reference-expected.txt:
* platform/gtk/svg/custom/junk-data-expected.txt:
* platform/gtk/svg/custom/linking-base-external-reference-expected.txt:
* platform/gtk/svg/custom/missing-xlink-expected.txt:
* platform/gtk/svg/custom/path-bad-data-expected.txt:
* platform/gtk/svg/custom/use-font-face-crash-expected.txt:
* platform/gtk/svg/foreignObject/svg-document-in-html-document-expected.txt:
* platform/gtk/svg/hixie/error/012-expected.txt:
* platform/gtk/svg/in-html/circle-expected.txt:
* platform/gtk/svg/transforms/animated-path-inside-transformed-html-expected.txt:
* platform/gtk/svg/transforms/text-with-pattern-inside-transformed-html-expected.txt:
* platform/gtk/svg/wicd/rightsizing-grid-expected.txt:
* platform/gtk/svg/wicd/test-rightsizing-b-expected.txt:
* platform/gtk/svg/zoom/page/zoom-foreignObject-expected.txt:
* platform/gtk/svg/zoom/page/zoom-svg-through-object-with-absolute-size-2-expected.txt:
* platform/gtk/svg/zoom/page/zoom-svg-through-object-with-absolute-size-expected.txt:
* platform/gtk/svg/zoom/page/zoom-svg-through-object-with-override-size-expected.txt:
* platform/gtk/svg/zoom/page/zoom-svg-through-object-with-percentage-size-expected.txt:
* platform/gtk/svg/zoom/text/zoom-foreignObject-expected.txt:

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

6 years agoPut WebKitPluginHost.app in WebKitLegacy.framework
andersca@apple.com [Tue, 6 May 2014 18:16:40 +0000 (18:16 +0000)]
Put WebKitPluginHost.app in WebKitLegacy.framework
https://bugs.webkit.org/show_bug.cgi?id=132592
<rdar://problem/15920046>

Reviewed by Dan Bernstein.

Source/WebKit:
* WebKit.xcodeproj/project.pbxproj:

Source/WebKit/mac:
* Plugins/Hosted/NetscapePluginHostManager.mm:
(WebKit::NetscapePluginHostManager::spawnPluginHost):

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

6 years agoRemoved unnecessary notImplemented.h includes.
commit-queue@webkit.org [Tue, 6 May 2014 18:04:53 +0000 (18:04 +0000)]
Removed unnecessary notImplemented.h includes.
https://bugs.webkit.org/show_bug.cgi?id=132587

Patch by Alex Christensen <achristensen@webkit.org> on 2014-05-06
Reviewed by Anders Carlsson.

Source/WebCore:
* Modules/webdatabase/Database.cpp:
* accessibility/AccessibilityObject.cpp:
* bindings/js/Dictionary.h:
* bindings/js/SerializedScriptValue.cpp:
* html/HTMLMediaSession.cpp:
* html/ImageDocument.cpp:
* html/parser/HTMLFormattingElementList.cpp:
* loader/appcache/ApplicationCacheStorage.cpp:
* page/mac/EventHandlerMac.mm:
* platform/NotImplemented.cpp:
* platform/audio/ios/MediaSessionManagerIOS.mm:
* platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
* platform/graphics/mac/GraphicsContext3DMac.mm:
* platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
* platform/ios/PlatformScreenIOS.mm:
* platform/mac/PlatformScreenMac.mm:
* platform/mac/WidgetMac.mm:
* platform/mediastream/MediaStreamTrackPrivate.cpp:
* platform/mediastream/mac/AVCaptureDeviceManager.mm:
* platform/mediastream/mac/AVMediaCaptureSource.mm:
* rendering/RenderGrid.cpp:
* workers/SharedWorkerGlobalScope.cpp:
* workers/WorkerGlobalScope.cpp:
* workers/WorkerMessagingProxy.cpp:
Removed notImplemented from list of includes.

Source/WebKit2:
* UIProcess/ios/WKContentViewInteraction.mm:
* UIProcess/mac/WebContextMenuProxyMac.mm:
* WebProcess/Databases/IndexedDB/WebIDBFactoryBackend.cpp:
* WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp:
Removed notImplemented from list of includes.

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

6 years agoUnreviewed build fix after http://trac.webkit.org/changeset/168364
enrica@apple.com [Tue, 6 May 2014 17:58:13 +0000 (17:58 +0000)]
Unreviewed build fix after trac.webkit.org/changeset/168364

* rendering/RenderLineBreak.cpp:

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

6 years ago[HTML] Default argument to HTMLTableSectionElement.insertRow() should be -1
ch.dumez@samsung.com [Tue, 6 May 2014 17:54:40 +0000 (17:54 +0000)]
[HTML] Default argument to HTMLTableSectionElement.insertRow() should be -1
https://bugs.webkit.org/show_bug.cgi?id=132570

Reviewed by Darin Adler.

Source/WebCore:
HTMLTableSectionElement.insertRow()'s argument default value should be -1, not
0, as per the specification:
http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#the-tbody-element

The new behavior matches the one of Firefox 29 and IE11, and soon Blink:
https://code.google.com/p/chromium/issues/detail?id=369803

Test: fast/dom/HTMLTableSectionElement/insertRow-default-argument.html

* html/HTMLTableSectionElement.h:
* html/HTMLTableSectionElement.idl:

LayoutTests:
Add layout test to test that the default argument to
HTMLTableSectionElement.insertRow() is -1.

* fast/dom/HTMLTableSectionElement/insertRow-default-argument-expected.txt: Added.
* fast/dom/HTMLTableSectionElement/insertRow-default-argument.html: Added.

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

6 years agoREGRESSION(r155957): Selection rects are incorrect when the selection contains BR...
enrica@apple.com [Tue, 6 May 2014 17:49:51 +0000 (17:49 +0000)]
REGRESSION(r155957): Selection rects are incorrect when the selection contains BR elements.
https://bugs.webkit.org/show_bug.cgi?id=132596
<rdar://problem/16692206>

Reviewed by Antti Koivisto.

This patch adds an implementation of collectSelectionRects to RenderLineBreak.
It uses the same logic used by RenderText to compute and annotate the returned rect
which is computed, like the caret rect, using information from the rootline box.

* rendering/RenderLineBreak.cpp:
(WebCore::RenderLineBreak::collectSelectionRects):
* rendering/RenderLineBreak.h:

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

6 years ago[CSS Regions] Optimize the number of regions invalidations
abucur@adobe.com [Tue, 6 May 2014 17:30:40 +0000 (17:30 +0000)]
[CSS Regions] Optimize the number of regions invalidations
https://bugs.webkit.org/show_bug.cgi?id=132611

Reviewed by David Hyatt.

Source/WebCore:
It is possible to invalidate the region chain of a flow thread
during the layout of the region when its height is not final.

This patch places the check after the height of the region
is determined, reducing the number of invalidations.

Tests: Less invalidations and repaints in the repaint tests for
the flow threads.

* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::updateLogicalHeight):
* rendering/RenderNamedFlowFragment.cpp:
(WebCore::RenderNamedFlowFragment::layoutBlock):
(WebCore::RenderNamedFlowFragment::invalidateRegionIfNeeded):
* rendering/RenderNamedFlowFragment.h:

LayoutTests:
Because there are less region invalidations there are less repaints
of the flow threads.

* fast/regions/repaint/repaint-regions-overflow-expected.txt:

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

6 years ago[Extended Background] Respect repeat-x/repeat-y when creating margin tiles
weinig@apple.com [Tue, 6 May 2014 16:44:41 +0000 (16:44 +0000)]
[Extended Background] Respect repeat-x/repeat-y when creating margin tiles
https://bugs.webkit.org/show_bug.cgi?id=132534

Reviewed by Beth Dakin.

If the background image that is causing margin tiles only repeats in dimension only create
the tiles in that dimension.

* page/FrameView.cpp:
(WebCore::FrameView::updateExtendBackgroundIfNecessary):
(WebCore::FrameView::calculateExtendedBackgroundMode):
(WebCore::FrameView::updateTilesForExtendedBackgroundMode):
(WebCore::FrameView::setBackgroundExtendsBeyondPage): Deleted.
(WebCore::FrameView::needsExtendedBackgroundRectForPainting): Deleted.
(WebCore::FrameView::setHasExtendedBackgroundRectForPainting): Deleted.
* page/FrameView.h:
* page/Settings.cpp:
(WebCore::Settings::setBackgroundShouldExtendBeyondPage):
* platform/graphics/TiledBacking.h:
* platform/graphics/ca/mac/TileController.h:
* platform/graphics/ca/mac/TileController.mm:
(WebCore::TileController::hasHorizontalMargins):
(WebCore::TileController::hasVerticalMargins):
* rendering/RenderElement.cpp:
(WebCore::RenderElement::styleWillChange):
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::setTiledBackingHasMargins):
* rendering/RenderLayerBacking.h:

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

6 years agoTry to fix iOS build.
darin@apple.com [Tue, 6 May 2014 16:19:22 +0000 (16:19 +0000)]
Try to fix iOS build.

* DumpRenderTree/mac/TestRunnerMac.mm:
(-[APITestDelegateIPhone initWithTestRunner:utf8Data:baseURL:]):
Updated since I changed testRunner into a pointer instead of a reference.
Updated argument names to avoid conflict with field names.
(-[APITestDelegateIPhone run]): Ditto.
(-[APITestDelegateIPhone _cleanUp]): Ditto.

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

6 years agoAX: VoiceOver does not announce text changes for content editable regions in Safari
cfleizach@apple.com [Tue, 6 May 2014 16:17:19 +0000 (16:17 +0000)]
AX: VoiceOver does not announce text changes for content editable regions in Safari
https://bugs.webkit.org/show_bug.cgi?id=132577

Reviewed by Mario Sanchez Prada.

Source/WebCore:
When text or children are changed inside of a contenteditable region, we need to
convert those actions into AXValueChange notifications.

Test: accessibility/content-editable-set-inner-text-generates-axvalue-notification.html

* accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityNodeObject::childrenChanged):
(WebCore::AccessibilityNodeObject::hasContentEditableAttributeSet): Deleted.
* accessibility/AccessibilityNodeObject.h:
* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::hasContentEditableAttributeSet):
* accessibility/AccessibilityObject.h:
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::textChanged):

LayoutTests:
* accessibility/content-editable-set-inner-text-generates-axvalue-notification-expected.txt: Added.
* accessibility/content-editable-set-inner-text-generates-axvalue-notification.html: Added.

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

6 years ago[iOS] Fix two more AdoptCF I missed in my last patch.
darin@apple.com [Tue, 6 May 2014 14:14:49 +0000 (14:14 +0000)]
[iOS] Fix two more AdoptCF I missed in my last patch.

* WebView/WebHTMLView.mm:
(imageFromRect): Use adoptCF instead of AdoptCF.

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

6 years ago[SVG2] Share "on"- event attributes with HTMLElement
krit@webkit.org [Tue, 6 May 2014 14:04:13 +0000 (14:04 +0000)]
[SVG2] Share "on"- event attributes with HTMLElement
https://bugs.webkit.org/show_bug.cgi?id=132604

Reviewed by Mihnea Ovidenie.

Source/WebCore:
Share "on" event attribute parsing between SVGElement and HTMLElement.

Tests: fast/dom/script-tests/event-attribute-availability.js:

* html/HTMLElement.cpp:
(WebCore::HTMLElement::populateEventNameForAttributeLocalNameMap):
(WebCore::populateEventNameForAttributeLocalNameMap): Deleted.
* html/HTMLElement.h: Make populateEventNameForAttributeLocalNameMap
    public for use in SVGElement.
* svg/SVGElement.cpp: Use HTMLElement code to parse "on" event
    attributes.
(WebCore::SVGElement::parseAttribute):

LayoutTests:
Test that the "on" event attributes supported by HTMLElement are
supported by SVGElement as well.

* fast/dom/event-attribute-availability-expected.txt:
* fast/dom/script-tests/event-attribute-availability.js:

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

6 years agoUnreviewed, rolling out r168304.
commit-queue@webkit.org [Tue, 6 May 2014 13:34:58 +0000 (13:34 +0000)]
Unreviewed, rolling out r168304.
https://bugs.webkit.org/show_bug.cgi?id=132607

Broke the build (Requested by KaL on #webkit).

Reverted changeset:

"[GTK][CMake] Unable to do make install"
https://bugs.webkit.org/show_bug.cgi?id=130188
http://trac.webkit.org/changeset/168304

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

6 years ago[CSS Blending] Rename all the tests css3/compositing to css3/blending
commit-queue@webkit.org [Tue, 6 May 2014 13:17:26 +0000 (13:17 +0000)]
[CSS Blending] Rename all the tests css3/compositing to css3/blending
https://bugs.webkit.org/show_bug.cgi?id=132606

Patch by Ion Rosca <rosca@adobe.com> on 2014-05-06
Reviewed by Andrei Bucur.

* css3/blending: Renamed from LayoutTests/css3/compositing.

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

6 years agoWeb Inspector: [CSS Regions] Add the regionOversetChange event to the iOS 7.0 WebInsp...
stavila@adobe.com [Tue, 6 May 2014 12:37:52 +0000 (12:37 +0000)]
Web Inspector: [CSS Regions] Add the regionOversetChange event to the iOS 7.0 WebInspector UI
https://bugs.webkit.org/show_bug.cgi?id=132566

Reviewed by Antti Koivisto.

The regionOversetChange event was missing from the iOS7 WebInspector.

* UserInterface/Protocol/Legacy/7.0/InspectorWebBackendCommands.js:
* Versions/Inspector-iOS-7.0.json:

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