Remove unused FrameView::setUseCustomFixedPositionLayoutRect().
<https://webkit.org/b/134194>

Reviewed by Anders Carlsson.

* WebCore.exp.in:
* page/FrameView.cpp:
(WebCore::FrameView::setUseCustomFixedPositionLayoutRect): Deleted.
* page/FrameView.h:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170297 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Give read-only properties proper ownership attributes
https://bugs.webkit.org/show_bug.cgi?id=134197
<rdar://problem/16830117>

Reviewed by Dan Bernstein.

Also, make WKFrameInfo conform to NSCopying since it's a data-only object and thus intended to be copied.

* UIProcess/API/Cocoa/WKBackForwardList.h:
* UIProcess/API/Cocoa/WKBackForwardListItem.h:
* UIProcess/API/Cocoa/WKFrameInfo.h:
* UIProcess/API/Cocoa/WKFrameInfo.mm:
(-[WKFrameInfo copyWithZone:]):
(-[WKFrameInfo setRequest:]): Deleted.
* UIProcess/API/Cocoa/WKNavigation.h:
* UIProcess/API/Cocoa/WKNavigationAction.h:
* UIProcess/API/Cocoa/WKNavigationAction.mm:
(-[WKNavigationAction setSourceFrame:]):
(-[WKNavigationAction setTargetFrame:]):
* UIProcess/API/Cocoa/WKNavigationActionInternal.h:
* UIProcess/API/Cocoa/WKNavigationResponse.h:
* UIProcess/API/Cocoa/WKScriptMessage.h:
* UIProcess/API/Cocoa/WKUserContentController.h:
* UIProcess/API/Cocoa/WKUserScript.h:
* UIProcess/API/Cocoa/WKWebView.h:

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

* WebCoreSupport/WebSystemInterface.mm:
(InitWebCoreSystemInterface):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170299 268f45cc-cd09-0410-ab3c-d52691b4dbfc
More build fixing after r170295.

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

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170300 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Mac] Uncaught exception crash when destroying MediaPlayerPrivateAVFoundationObjC
https://bugs.webkit.org/show_bug.cgi?id=134198

Reviewed by Eric Carlson.

Now that we always create an AVPlayerLayer when creating an AVPlayer, but we don't
return that layer from platformLayer() unless we've been asked to, we no longer are
asked to destroy our video layer from MediaPlayerPrivateAVFoundation::tearDownVideoRendering().

Instead, explicitly destroy our video layer (and remove the KVO-observer which is
causing this exception) in the MediaPlayerPrivateAVFoundationObjC destructor.

* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::~MediaPlayerPrivateAVFoundationObjC):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170301 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS] Use WebGLLayer rather than PlatformLayer in GraphicsContext3D
https://bugs.webkit.org/show_bug.cgi?id=134183

Follow-up review from Sam Weinig.

* platform/graphics/GraphicsContext3D.h: Merge another bit of MAC and IOS
code.
* ChangeLog: Actually read his review comments this time.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170302 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Cocoa] No way to grant storage quotas for WebSQL
https://bugs.webkit.org/show_bug.cgi?id=134175

Reviewed by Anders Carlsson.

* Shared/WebSecurityOrigin.h:
(WebKit::WebSecurityOrigin::securityOrigin): Changed to return a non-const reference.

* UIProcess/API/APIUIClient.h:
(API::UIClient::exceededDatabaseQuota): Added a completion handler parameter than takes the
new quota, and changed the return type to void.

* UIProcess/API/C/WKPage.cpp:
(WKPageSetPageUIClient): Changed the override of exceededDatabaseQuota to call the
completion handler with the new quota, or with the existing quota if the client doesn’t
implement the callback.

* UIProcess/API/Cocoa/WKUIDelegatePrivate.h: Declared new delegate method.

* UIProcess/API/Cocoa/_WKSecurityOrigin.h: Added.
* UIProcess/API/Cocoa/_WKSecurityOrigin.mm: Added.
(-[_WKSecurityOrigin _initWithSecurityOrigin:WebCore::]): Store the origin in an ivar.
(-[_WKSecurityOrigin protocol]): Added this accessor.
(-[_WKSecurityOrigin host]): Ditto.
(-[_WKSecurityOrigin port]): Ditto.
* UIProcess/API/Cocoa/_WKSecurityOriginInternal.h: Added.

* UIProcess/Cocoa/UIDelegate.h: Override API::UIClient::exceededDatabaseQuota. Added flag
to m_delegateMethods struct for new delegate method.
* UIProcess/Cocoa/UIDelegate.mm:
(WebKit::UIDelegate::setDelegate): Set new flag in m_delegateMethods struct.
(WebKit::UIDelegate::UIClient::exceededDatabaseQuota): Added. Calls the new delegate method.

* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::exceededDatabaseQuota): Updated for the new client interface: now
passing a completion handler that replies with the new quota.

* WebKit2.xcodeproj/project.pbxproj: Added references to new files, sorted a group.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170303 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[New Multicolumn] Writing mode changes on the <html> and RenderView need to
be propagated to column sets and flow thread children of those renderers.
https://bugs.webkit.org/show_bug.cgi?id=134121
<rdar://problem/16884527>

Reviewed by Dean Jackson.


Source/WebCore: 
Added fast/multicol/pagination/RightToLeft-rl-dynamic.html

* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::styleDidChange):
Refactor the propagation code for column sets and flow thread styles into a helper
function that is called here.

(WebCore::RenderBlockFlow::updateStylesForColumnChildren):
* rendering/RenderBlockFlow.h:
Add a new helper function for recalculating the styles of the column sets and
flow thread in response to changes.

* rendering/RenderBox.cpp:
(WebCore::RenderBox::styleDidChange):
When the style is changed for a root element or the RenderView in response to
writing mode and direction changes, make sure that style gets propagated to
the column children by calling the new helper function.

LayoutTests: 
* fast/multicol/pagination/RightToLeft-rl-dynamic.html: Added.
* platform/mac/fast/multicol/pagination/BottomToTop-bt-expected.png:
* platform/mac/fast/multicol/pagination/BottomToTop-lr-expected.png:
* platform/mac/fast/multicol/pagination/BottomToTop-rl-expected.png:
* platform/mac/fast/multicol/pagination/BottomToTop-tb-expected.png:
* platform/mac/fast/multicol/pagination/LeftToRight-bt-expected.png:
* platform/mac/fast/multicol/pagination/LeftToRight-lr-expected.png:
* platform/mac/fast/multicol/pagination/LeftToRight-rl-expected.png:
* platform/mac/fast/multicol/pagination/LeftToRight-tb-expected.png:
* platform/mac/fast/multicol/pagination/RightToLeft-bt-expected.png:
* platform/mac/fast/multicol/pagination/RightToLeft-lr-expected.png:
* platform/mac/fast/multicol/pagination/RightToLeft-rl-dynamic-expected.png: Added.
* platform/mac/fast/multicol/pagination/RightToLeft-rl-dynamic-expected.txt: Added.
* platform/mac/fast/multicol/pagination/RightToLeft-rl-expected.png:
* platform/mac/fast/multicol/pagination/RightToLeft-tb-expected.png:
* platform/mac/fast/multicol/pagination/TopToBottom-bt-expected.png:
* platform/mac/fast/multicol/pagination/TopToBottom-lr-expected.png:
* platform/mac/fast/multicol/pagination/TopToBottom-rl-expected.png:
* platform/mac/fast/multicol/pagination/TopToBottom-tb-expected.png:
* platform/mac/fast/multicol/pagination/nested-transforms-expected.png:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170304 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Enable the Web Inspector in MiniBrowser
https://bugs.webkit.org/show_bug.cgi?id=134148

Reviewed by Joseph Pecoraro.

Set the pref to enable Web Inspector in both WK1 and WK2 windows.

* MiniBrowser/mac/AppDelegate.m:
(-[BrowserAppDelegate applicationDidFinishLaunching:]):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170305 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Adding a mask on a simple color compositing layer removes the content
https://bugs.webkit.org/show_bug.cgi?id=134127

Reviewed by Dean Jackson.

Source/WebCore:

In r169053 I moved some updateDrawsContent() into updateAfterDescendents(),
but this isn't called when a composited layer gains or loses a mask (which
doesn't cause a layout). This caused us to fail to allocate backing store
when gaining a mask, resulting in missing content.

Fix by calling updateAfterDescendents() from RenderLayer::styleChange()
when the layer config isn't changing.

Also remove a condition in isSimpleContainerCompositingLayer() that caused us
to fall off the simple layer path for masked layers, since this works just
fine.

Test: compositing/masks/solid-color-masked.html

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::calculateClipRects):
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):

LayoutTests:

* compositing/masks/mask-layer-size-expected.txt:
* compositing/masks/solid-color-masked-expected.html: Added.
* compositing/masks/solid-color-masked.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170306 268f45cc-cd09-0410-ab3c-d52691b4dbfc
CSS clip property should make layers non-opaque
https://bugs.webkit.org/show_bug.cgi?id=134147

Source/WebCore:
<rdar://problem/17324579>

Reviewed by Tim Horton.

https://www.fairphone.com has position:fixed elements with clip: rect(...)
but we were making those layers opaque, resulting in garbage pixels
in areas outside the clip rect.

Fix by checking for the clip property in RenderBox::backgroundIsKnownToBeOpaqueInRect().

Test: compositing/contents-opaque/opaque-with-clip.html

* rendering/RenderBox.cpp:
(WebCore::RenderBox::backgroundIsKnownToBeOpaqueInRect):

LayoutTests:

Reviewed by Tim Horton.

* compositing/contents-opaque/opaque-with-clip-expected.html: Added.
* compositing/contents-opaque/opaque-with-clip.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170307 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Catch Obj-C exceptions thrown by _linenPatternImage
https://bugs.webkit.org/show_bug.cgi?id=134202

Reviewed by Geoffrey Garen.

Catch Objective-C exceptions thrown by _linenPatternImage and
-[NSImage CGImageForProposedRect:context:hints:].

* platform/mac/ScrollbarThemeMac.mm:
(WebCore::linenBackgroundColor):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170308 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Add skeleton code for updated Gamepad API
https://bugs.webkit.org/show_bug.cgi?id=134165

Reviewed by Dean Jackson.

No new tests (No change in behavior for any tested configuration)

Interface and dummy implementation for the Gamepad object:
* Modules/gamepad/Gamepad.cpp: Added.
(WebCore::Gamepad::Gamepad):
(WebCore::Gamepad::~Gamepad):
(WebCore::Gamepad::axes):
(WebCore::Gamepad::buttons):
* Modules/gamepad/Gamepad.h: Added.
* Modules/gamepad/Gamepad.idl: Added.

Interface and dummy implementation for the GamepadButton object:
* Modules/gamepad/GamepadButton.cpp: Added.
(WebCore::GamepadButton::GamepadButton):
(WebCore::GamepadButton::pressed):
* Modules/gamepad/GamepadButton.h: Added.
(WebCore::GamepadButton::create):
(WebCore::GamepadButton::value):
(WebCore::GamepadButton::setValue):
* Modules/gamepad/GamepadButton.idl: Added.

Interface and dummy implementation for the GamepadEvent object:
* Modules/gamepad/GamepadEvent.cpp: Added.
(WebCore::GamepadEvent::GamepadEvent):
* Modules/gamepad/GamepadEvent.h: Added.
(WebCore::GamepadEventInit::GamepadEventInit):
(WebCore::GamepadEvent::~GamepadEvent):
(WebCore::GamepadEvent::create):
(WebCore::GamepadEvent::gamepad):
* Modules/gamepad/GamepadEvent.idl: Added.
* dom/EventNames.in:

Interface and dummy implementation for additions to the Navigator object:
* Modules/gamepad/NavigatorGamepad.cpp: Added.
(WebCore::NavigatorGamepad::NavigatorGamepad):
(WebCore::NavigatorGamepad::supplementName):
(WebCore::NavigatorGamepad::from):
(WebCore::NavigatorGamepad::getGamepads):
(WebCore::NavigatorGamepad::gamepads):
* Modules/gamepad/NavigatorGamepad.h: Added.
* Modules/gamepad/NavigatorGamepad.idl: Added.

Bindings additions necessary for these new interfaces:
* bindings/js/JSDOMBinding.h:
(WebCore::JSValueTraits<double>::arrayJSValue):
* bindings/js/JSDictionary.cpp:
(WebCore::JSDictionary::convertValue):
* bindings/js/JSDictionary.h:

Project file stuff:
* CMakeLists.txt:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCoreCommon.props:
* WebCore.vcxproj/copyForwardingHeaders.cmd:
* WebCore.xcodeproj/project.pbxproj:
* DerivedSources.make:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170309 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fix a test case failing on WK1 after r170296.

There is now a non-visual render tree dump difference between WK1 and Wk2 results here due to wk1 requiring an additional style synchronization.

* platform/mac-wk2/editing/inserting: Added.
* platform/mac-wk2/editing/inserting/break-blockquote-after-delete-expected.txt: Copied from LayoutTests/platform/mac/editing/inserting/break-blockquote-after-delete-expected.txt.
* platform/mac/editing/inserting/break-blockquote-after-delete-expected.txt:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170310 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unregister notification observer registered in r170156.
https://bugs.webkit.org/show_bug.cgi?id=134204.

Reviewed by Tim Horton.

* UIProcess/API/mac/WKView.mm:
(-[WKView dealloc]):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@170311 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Inline the UnlinkedInstructionStream::Reader logic.
<https://webkit.org/b/134203>

This class is only used by CodeBlock to unpack the unlinked instructions,
and we were spending 0.5% of total time on PLT calling Reader::next().
Move the logic to the header file and mark it ALWAYS_INLINE.

Reviewed by Geoffrey Garen.

* bytecode/UnlinkedInstructionStream.cpp:
* bytecode/UnlinkedInstructionStream.h:
(JSC::UnlinkedInstructionStream::Reader::Reader):
(JSC::UnlinkedInstructionStream::Reader::read8):
(JSC::UnlinkedInstructionStream::Reader::read32):
(JSC::UnlinkedInstructionStream::Reader::next):


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