Check the com.apple.security.network.client entitlement for all processes
https://bugs.webkit.org/show_bug.cgi?id=131942
<rdar://problem/12354188>

Reviewed by Dan Bernstein.

* NetworkProcess/EntryPoint/mac/XPCService/NetworkServiceEntryPoint.mm:
(WebKit::NetworkServiceInitializerDelegate::NetworkServiceInitializerDelegate):
* Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:
* Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.mm:
(WebKit::XPCServiceInitializerDelegate::checkEntitlements):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167603 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[GTK] Unreviewed GTK gardening

Update gtk/TestExpectations and rebaseline some gtk test results.

Patch by Carlos Alberto Lopez Perez <clopez@igalia.com> on 2014-04-21

* platform/gtk/TestExpectations: Mark fast/repaint/hidpi-wrong-repaint-rect-when-parent-has-noncompositing-transform.html
as failure and fast/dom/Window/mozilla-focus-blur.html as flaky.
* platform/gtk/fast/multicol/newmulticol/client-rects-expected.txt: Rebaseline after r167335.
* platform/gtk/fast/repaint/reflection-redraw-expected.txt: Rebaseline after r167568.
* platform/gtk/fast/table/dynamic-caption-add-remove-before-child-expected.txt: Rebaseline after r167568.
* platform/gtk/fast/table/multiple-captions-display-expected.txt: Rebaseline after r167568.
* platform/gtk/tables/mozilla/marvin/body_col-expected.txt: Rebaseline after r167568.
* platform/gtk/tables/mozilla/marvin/x_th_valign_baseline-expected.txt: Rebaseline after r167568.
* platform/gtk/tables/mozilla/other/body_col-expected.txt: Rebaseline after r167568.
* platform/gtk/tables/mozilla_expected_failures/bugs/bug10140-expected.txt: Rebaseline after r167568.
* platform/gtk/tables/mozilla_expected_failures/bugs/bug10216-expected.txt: Rebaseline after r167568.
* platform/gtk/tables/mozilla_expected_failures/core/captions3-expected.txt: Rebaseline after r167568.
* platform/gtk/tables/mozilla_expected_failures/other/test4-expected.txt: Rebaseline after r167568.
* platform/gtk/fast/repaint/spanner-with-margin-expected.txt: Added. Rebaseline after r167439.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167604 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Move the JSString cache from DOMWrapperWorld to VM.
<https://webkit.org/b/131940>

Source/JavaScriptCore:
Reviewed by Geoff Garen.

* runtime/VM.h:

Source/WebCore:
Since there's no need for JSStrings to be world-specific, this patch
moves the string cache to JSC::VM. This makes jsStringWithCache()
a lot faster since it no longer has to jump through twenty-eleven
hoops to find the DOMWrapperWorld.

Reviewed by Geoff Garen.

* bindings/js/DOMWrapperWorld.cpp:
(WebCore::DOMWrapperWorld::clearWrappers):
* bindings/js/DOMWrapperWorld.h:
* bindings/js/JSDOMBinding.cpp:
(WebCore::jsStringWithCache):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167605 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[New Multicolumn] Add test case for shrink-to-column-height now that
it passes in the new impl.
https://bugs.webkit.org/show_bug.cgi?id=131814

Reviewed by Dean Jackson.

* fast/multicol/newmulticol/compare-with-old-impl/shrink-to-column-height-for-pagination-expected.html: Added.
* fast/multicol/newmulticol/compare-with-old-impl/shrink-to-column-height-for-pagination.html: Added.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167606 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Update results of fast/images/image-controls-basic.html

* platform/mac/TestExpectations:
* platform/mac/fast/images/image-controls-basic-expected.png:
* platform/mac/fast/images/image-controls-basic-expected.txt:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167607 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Provide feedback when we encounter an unrecognied node in the FTL backend.

Rubber stamped by Alexey Proskuryakov.

* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::compileNode):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167608 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Remove unused WebKitSystemInterface functions
https://bugs.webkit.org/show_bug.cgi?id=131938

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2014-04-21
Reviewed by Alexey Proskuryakov.

Source/WebCore:
* WebCore.exp.in:
* platform/ios/WebCoreSystemInterfaceIOS.mm:
* platform/mac/WebCoreSystemInterface.h:
* platform/mac/WebCoreSystemInterface.mm:

Source/WebKit/mac:
* WebCoreSupport/WebSystemInterface.mm:
(InitWebCoreSystemInterface):

Source/WebKit2:
* WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
(InitWebCoreSystemInterface):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167609 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Cocoa] Expose WebPage::setDefersLoading
https://bugs.webkit.org/show_bug.cgi?id=131943

Reviewed by Anders Carlsson, but he doesn’t like this.

* WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
(-[WKWebProcessPlugInBrowserContextController _defersLoading]): Added this accessor.
(-[WKWebProcessPlugInBrowserContextController _setDefersLoading:]): Ditto.
* WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextControllerPrivate.h:
Declared new property _defersLoading.

* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::defersLoading): Added this getter.
* WebProcess/WebPage/WebPage.h:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167610 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Need default WKNavigationDelegate behavior
https://bugs.webkit.org/show_bug.cgi?id=131944
<rdar://problem/15949822>

Reviewed by Dan Bernstein.

Port the WebKit1 default delegate behavior over.

* UIProcess/Cocoa/NavigationState.mm:
(WebKit::NavigationState::PolicyClient::decidePolicyForNavigationAction):
(WebKit::NavigationState::PolicyClient::decidePolicyForResponse):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167611 268f45cc-cd09-0410-ab3c-d52691b4dbfc
OSR exit should know about Int52 and Double constants
https://bugs.webkit.org/show_bug.cgi?id=131945

Reviewed by Oliver Hunt.
        
The DFG OSR exit machinery's ignorance would lead to some constants becoming
jsUndefined() after OSR exit.
        
The FTL OSR exit machinery's ignorance just meant that we would sometimes use a
stackmap constant rather than baking the constant into the OSRExit data structure.
So, not a big deal, but worth fixing.
        
Also added some helpful hacks to jsc.cpp for testing such OSR exit pathologies.

* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::handleIntrinsic):
* dfg/DFGMinifiedNode.h:
(JSC::DFG::belongsInMinifiedGraph):
(JSC::DFG::MinifiedNode::hasConstantNumber):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::tryToSetConstantExitArgument):
* jsc.cpp:
(GlobalObject::finishCreation):
(functionOtherFalse):
(functionUndefined):
* runtime/Intrinsic.h:
* tests/stress/fold-to-double-constant-then-exit.js: Added.
(foo):
* tests/stress/fold-to-int52-constant-then-exit.js: Added.
(foo):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167612 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore: Unreviewed test gardening, run the repeat-out-of-bounds tests again.

* tests/stress/float32-repeat-out-of-bounds.js:
* tests/stress/int8-repeat-out-of-bounds.js:

Tools: Unreviewed test gardening, make no-eager runs run everything except eager (as opposed to
being the same as a "quick run", which is meant for genuinely slow tests).

* Scripts/run-jsc-stress-tests:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167613 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS][WK2] Make dynamic viewport size update content aware
https://bugs.webkit.org/show_bug.cgi?id=131874

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-04-21
Reviewed by Tim Horton.

When possible, adjust the scroll position based on the content on dynamic viewport resize.

* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage):
(WebKit::WebPage::scalePage):
(WebKit::WebPage::pageDidScroll):
* WebProcess/WebPage/WebPage.h:
The scrolling heuristic are not invertible, especially the content heuristic. To have the right
behavior when doing resize without changing the page, we save the old scroll position and restore
it when the content size and scale is restored.

* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::dynamicViewportSizeUpdate):
On dynamic update, start by finding what node is at the center of the screen. After the layout, put that
node back in the center.

(WebKit::WebPage::updateVisibleContentRects):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167614 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS][WK2] Fix the dynamic viewport update when the viewport's max-scale conflict with the transition
https://bugs.webkit.org/show_bug.cgi?id=131884

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-04-21
Reviewed by Darin Adler.

<rdar://problem/16667291>

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _beginAnimatedResizeWithUpdates:]):
It is fairly common to have a viewport configuration with min-scale=1 and max-scale=1.
Since we were only changing the minimumScale for the transition, the target scale was affected
by max-scale. This was breaking the transition from portrait to landscale.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167615 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS WebKit2] Implement CSS viewport units
https://bugs.webkit.org/show_bug.cgi?id=131863
<rdar://problem/16279088>

Reviewed by Darin Adler.

* UIProcess/API/Cocoa/WKWebView.mm:
(setMinimumLayoutSizeForMinimalUI):
(-[WKWebView _minimumLayoutSizeOverrideForMinimalUI]):
(-[WKWebView _setMinimumLayoutSizeOverrideForMinimalUI:]):
Add _setMinimumLayoutSizeOverrideForMinimalUI:, which pushes said size
down from the client to WebPageIOS, below.

* UIProcess/API/Cocoa/WKWebViewPrivate.h:
* UIProcess/WebPageProxy.h:
* UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::setMinimumLayoutSizeForMinimalUI):
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in:
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::setMinimumLayoutSizeForMinimalUI):
(WebKit::WebPage::viewportConfigurationChanged):
Update FrameView's viewport size based on the minimum layout size for minimal UI (if we have it)
or the normal minimum layout size, scaled to the page's initial scale.

* WebCore.exp.in:
* page/FrameView.cpp:
(WebCore::FrameView::setViewportSize):
* page/FrameView.h:
(WebCore::FrameView::viewportSize):
Add setViewportSize() and viewportSize().
If the viewport size changes, we have to do style recalc.
If we have an overridden viewport size, use it.

* rendering/RenderView.cpp:
(WebCore::RenderView::viewportSize):
* rendering/RenderView.h:
Get the size from FrameView.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167616 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[New Multicolumn] Column set drawing under horizontal scrollbar.
https://bugs.webkit.org/show_bug.cgi?id=131812.

Reviewed by Sam Weinig.


Source/WebCore: 
Added fast/multicol/newmulticol/compare-with-old-impl/LeftToRight-tb.html.

* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::layoutBlock):
(WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
* rendering/RenderBlockFlow.h:
Pass in relayoutChildren as a reference boolean to checkForPaginationLogicalHeightChange.
The new columns need to be able to set it to true if the amount of available column
height ever changes, so that the RenderFlowThread and the sets get a layout call.

* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::setColumnStylesFromPaginationMode):
Make sure that the pagination mode is set up with an auto column-fill specified. You
don't ever want to balance when you set a pagination mode on the RenderView.

LayoutTests: 
* fast/multicol/newmulticol/compare-with-old-impl/LeftToRight-tb-expected.html: Added.
* fast/multicol/newmulticol/compare-with-old-impl/LeftToRight-tb.html: Added.



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

* Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:
(WebKit::XPCServiceInitializer):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167618 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[New Multicolumn] vertical-rl/unsplittable-inline-block misrenders the column rule.
https://bugs.webkit.org/show_bug.cgi?id=131818

Reviewed by Anders Carlsson.
        
Patch the test to be column-fill:auto, since the other versions
of the test all had that specified already.

* fast/multicol/vertical-rl/unsplittable-inline-block.html:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167619 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CSS Blending] Remove support for non-separable blend modes from mix-blend-mode
https://bugs.webkit.org/show_bug.cgi?id=131824

Reviewed by Dean Jackson.

Source/WebCore:
Removed support for non-separable blend modes from the CSS parser.

Covered by existing tests

* css/CSSParser.cpp:
(WebCore::isValidKeywordPropertyAndValue):
* platform/graphics/ca/mac/PlatformCAFiltersMac.mm:
(PlatformCAFilters::setBlendingFiltersOnLayer):

LayoutTests:
Removed or updated tests that used non-separable blend modes in combination
with mix-blend-mode.

* css3/compositing/blend-mode-property-expected.txt:
* css3/compositing/blend-mode-property-parsing-expected.txt:
* css3/compositing/blend-mode-simple-composited.html:
* css3/compositing/blend-mode-simple.html:
* css3/compositing/script-tests/blend-mode-property-parsing.js:
* css3/compositing/script-tests/blend-mode-property.js:
* css3/compositing/svg-blend-color.html: Removed.
* css3/compositing/svg-blend-hue.html: Removed.
* css3/compositing/svg-blend-luminosity.html: Removed.
* css3/compositing/svg-blend-saturation.html: Removed.
* platform/mac/css3/compositing/blend-mode-simple-composited-expected.txt:
* platform/mac/css3/compositing/blend-mode-simple-expected.txt:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167620 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Another build fix.

* Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.mm:
(WebKit::XPCServiceInitializerDelegate::checkEntitlements):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@167621 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Don't use ProcessAssertion on simulator
https://bugs.webkit.org/show_bug.cgi?id=131950

Rubber stamped by Benjamin Poulain

* UIProcess/ios/ProcessAssertion.mm:
(WebKit::ProcessAssertion::ProcessAssertion):
(WebKit::ProcessAssertion::setState):



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