Unreviewed, rolling out r160645.
http://trac.webkit.org/changeset/160645
https://bugs.webkit.org/show_bug.cgi?id=125787

Change breaks test-webkitpy (Requested by bfulgham on
#webkit).

* Scripts/prepare-ChangeLog:
(get_selector_line_ranges_for_css):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160650 268f45cc-cd09-0410-ab3c-d52691b4dbfc
CTTE: Convert more of SVG to use references
https://bugs.webkit.org/show_bug.cgi?id=125762

Patch by Sam Weinig <sam@webkit.org> on 2013-12-16
Reviewed by Darin Adler.

* rendering/svg/RenderSVGImage.cpp:
(WebCore::RenderSVGImage::imageChanged):
* rendering/svg/RenderSVGResource.cpp:
(WebCore::removeFromCacheAndInvalidateDependencies):
(WebCore::RenderSVGResource::markForLayoutAndParentResourceInvalidation):
* rendering/svg/RenderSVGResource.h:
* rendering/svg/RenderSVGResourceClipper.cpp:
(WebCore::RenderSVGResourceClipper::removeClientFromCache):
* rendering/svg/RenderSVGResourceClipper.h:
* rendering/svg/RenderSVGResourceContainer.cpp:
(WebCore::RenderSVGResourceContainer::markAllClientsForInvalidation):
(WebCore::RenderSVGResourceContainer::markAllClientLayersForInvalidation):
(WebCore::RenderSVGResourceContainer::markClientForInvalidation):
(WebCore::RenderSVGResourceContainer::removeClient):
* rendering/svg/RenderSVGResourceContainer.h:
* rendering/svg/RenderSVGResourceFilter.cpp:
(WebCore::RenderSVGResourceFilter::removeClientFromCache):
(WebCore::RenderSVGResourceFilter::postApplyResource):
(WebCore::RenderSVGResourceFilter::primitiveAttributeChanged):
* rendering/svg/RenderSVGResourceFilter.h:
* rendering/svg/RenderSVGResourceGradient.cpp:
(WebCore::RenderSVGResourceGradient::removeClientFromCache):
* rendering/svg/RenderSVGResourceGradient.h:
* rendering/svg/RenderSVGResourceMarker.cpp:
(WebCore::RenderSVGResourceMarker::removeClientFromCache):
* rendering/svg/RenderSVGResourceMarker.h:
* rendering/svg/RenderSVGResourceMasker.cpp:
(WebCore::RenderSVGResourceMasker::removeClientFromCache):
* rendering/svg/RenderSVGResourceMasker.h:
* rendering/svg/RenderSVGResourcePattern.cpp:
(WebCore::RenderSVGResourcePattern::removeClientFromCache):
* rendering/svg/RenderSVGResourcePattern.h:
* rendering/svg/RenderSVGResourceSolidColor.h:
(WebCore::RenderSVGResourceSolidColor::removeClientFromCache):
* rendering/svg/SVGRenderSupport.cpp:
(WebCore::invalidateResourcesOfChildren):
* rendering/svg/SVGResources.cpp:
(WebCore::SVGResources::removeClientFromCache):
* rendering/svg/SVGResources.h:
* rendering/svg/SVGResourcesCache.cpp:
(WebCore::SVGResourcesCache::clientLayoutChanged):
(WebCore::SVGResourcesCache::clientStyleChanged):
(WebCore::SVGResourcesCache::clientWasAddedToTree):
(WebCore::SVGResourcesCache::clientWillBeRemovedFromTree):
(WebCore::SVGResourcesCache::clientDestroyed):
* svg/SVGAnimateMotionElement.cpp:
(WebCore::SVGAnimateMotionElement::applyResultsToTarget):
* svg/SVGCircleElement.cpp:
(WebCore::SVGCircleElement::svgAttributeChanged):
* svg/SVGEllipseElement.cpp:
(WebCore::SVGEllipseElement::svgAttributeChanged):
* svg/SVGFEImageElement.cpp:
(WebCore::SVGFEImageElement::notifyFinished):
* svg/SVGFELightElement.cpp:
(WebCore::SVGFELightElement::childrenChanged):
* svg/SVGFilterPrimitiveStandardAttributes.cpp:
(WebCore::invalidateFilterPrimitiveParent):
* svg/SVGFilterPrimitiveStandardAttributes.h:
(WebCore::SVGFilterPrimitiveStandardAttributes::invalidate):
(WebCore::SVGFilterPrimitiveStandardAttributes::primitiveAttributeChanged):
* svg/SVGForeignObjectElement.cpp:
(WebCore::SVGForeignObjectElement::svgAttributeChanged):
* svg/SVGGElement.cpp:
(WebCore::SVGGElement::svgAttributeChanged):
* svg/SVGGraphicsElement.cpp:
(WebCore::SVGGraphicsElement::svgAttributeChanged):
* svg/SVGImageElement.cpp:
(WebCore::SVGImageElement::svgAttributeChanged):
* svg/SVGLineElement.cpp:
(WebCore::SVGLineElement::svgAttributeChanged):
* svg/SVGPathElement.cpp:
(WebCore::SVGPathElement::svgAttributeChanged):
(WebCore::SVGPathElement::invalidateMPathDependencies):
(WebCore::SVGPathElement::pathSegListChanged):
* svg/SVGPolyElement.cpp:
(WebCore::SVGPolyElement::svgAttributeChanged):
* svg/SVGRectElement.cpp:
(WebCore::SVGRectElement::svgAttributeChanged):
* svg/SVGSVGElement.cpp:
(WebCore::SVGSVGElement::svgAttributeChanged):
(WebCore::SVGSVGElement::setupInitialView):
* svg/SVGStopElement.cpp:
(WebCore::SVGStopElement::svgAttributeChanged):
* svg/SVGTRefElement.cpp:
(WebCore::SVGTRefElement::svgAttributeChanged):
* svg/SVGTextContentElement.cpp:
(WebCore::SVGTextContentElement::svgAttributeChanged):
* svg/SVGTextPathElement.cpp:
(WebCore::SVGTextPathElement::svgAttributeChanged):
* svg/SVGTextPositioningElement.cpp:
(WebCore::SVGTextPositioningElement::svgAttributeChanged):
* svg/SVGUseElement.cpp:
(WebCore::SVGUseElement::svgAttributeChanged):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160651 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Package up some data about scrollability into a struct for use in the scrolling tree
https://bugs.webkit.org/show_bug.cgi?id=125792

Reviewed by Beth Dakin.

Both scrolling state nodes and scrolling nodes share a set of parameters
relating to scrollability and rubberbanding, so package them into a struct
for re-use. Send the struct wholesale to the scrolling thread.

* page/scrolling/ScrollingCoordinator.h:
(WebCore::ScrollableAreaParameters::ScrollableAreaParameters): New struct.
(WebCore::ScrollableAreaParameters::operator==):
* page/scrolling/ScrollingStateScrollingNode.cpp:
(WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode): Reordering.
(WebCore::ScrollingStateScrollingNode::setScrollOrigin): Moved.
(WebCore::ScrollingStateScrollingNode::setScrollableAreaParameters): Set the parameters all at once.
(WebCore::ScrollingStateScrollingNode::setRequestedScrollPosition):
* page/scrolling/ScrollingStateScrollingNode.h: Getters access the struct. Reorder member variables.
* page/scrolling/ScrollingTreeScrollingNode.cpp:
(WebCore::ScrollingTreeScrollingNode::ScrollingTreeScrollingNode):
(WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
* page/scrolling/ScrollingTreeScrollingNode.h:
(WebCore::ScrollingTreeScrollingNode::scrollOrigin):
(WebCore::ScrollingTreeScrollingNode::horizontalScrollElasticity):
(WebCore::ScrollingTreeScrollingNode::verticalScrollElasticity):
(WebCore::ScrollingTreeScrollingNode::hasEnabledHorizontalScrollbar):
(WebCore::ScrollingTreeScrollingNode::hasEnabledVerticalScrollbar):
(WebCore::ScrollingTreeScrollingNode::canHaveScrollbars):
* page/scrolling/mac/ScrollingCoordinatorMac.h:
* page/scrolling/mac/ScrollingCoordinatorMac.mm: Removed setScrollParametersForNode().
(WebCore::ScrollingCoordinatorMac::frameViewLayoutUpdated): Set the params in this
function. Reordering.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160652 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Rename WebData to API::Data
https://bugs.webkit.org/show_bug.cgi?id=125797

Reviewed by Beth Dakin.

* Shared/API/Cocoa/WKRemoteObjectCoder.mm:
(-[WKRemoteObjectEncoder encodeBytes:length:forKey:]):
(-[WKRemoteObjectDecoder decodeBytesForKey:returnedLength:]):
* Shared/API/c/WKData.cpp:
(WKDataGetTypeID):
(WKDataCreate):
* Shared/API/c/WKSharedAPICast.h:
* Shared/API/c/mac/WKWebArchive.cpp:
(WKWebArchiveCopyData):
* Shared/API/c/mac/WKWebArchiveResource.cpp:
(WKWebArchiveResourceCopyData):
* Shared/APIData.h: Renamed from Source/WebKit2/Shared/WebData.h.
(API::Data::createWithoutCopying):
(API::Data::create):
(API::Data::~Data):
(API::Data::bytes):
(API::Data::size):
(API::Data::dataReference):
(API::Data::Data):
(API::Data::fastFreeBytes):
* Shared/Cocoa/WKNSData.h:
(WebKit::wrapper):
* Shared/Cocoa/WKNSData.mm:
(-[WKNSData dealloc]):
* Shared/UserMessageCoders.h:
(WebKit::UserMessageEncoder::baseEncode):
(WebKit::UserMessageDecoder::baseDecode):
* Shared/WebArchive.cpp:
(WebKit::WebArchive::create):
(WebKit::WebArchive::WebArchive):
(WebKit::WebArchive::data):
* Shared/WebArchive.h:
* Shared/WebArchiveResource.cpp:
(WebKit::WebArchiveResource::create):
(WebKit::WebArchiveResource::WebArchiveResource):
(WebKit::WebArchiveResource::data):
* Shared/WebArchiveResource.h:
* UIProcess/API/C/WKPage.cpp:
* UIProcess/API/Cocoa/WKBrowsingContextController.mm:
(-[WKBrowsingContextController loadData:MIMEType:textEncodingName:baseURL:userData:]):
* UIProcess/API/mac/WKPrintingView.mm:
(pageDidDrawToPDF):
* UIProcess/Downloads/DownloadProxy.cpp:
(WebKit::createData):
(WebKit::DownloadProxy::didFail):
(WebKit::DownloadProxy::didCancel):
* UIProcess/Downloads/DownloadProxy.h:
(WebKit::DownloadProxy::resumeData):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::loadData):
(WebKit::WebPageProxy::loadWebArchiveData):
(WebKit::WebPageProxy::dataCallback):
(WebKit::WebPageProxy::saveDataToFileInDownloadsFolder):
(WebKit::WebPageProxy::savePDFToFileInDownloadsFolder):
* UIProcess/WebPageProxy.h:
* UIProcess/WebUIClient.cpp:
(WebKit::WebUIClient::saveDataToFileInDownloadsFolder):
* UIProcess/WebUIClient.h:
* UIProcess/cf/WebPageProxyCF.cpp:
(WebKit::WebPageProxy::sessionStateData):
(WebKit::WebPageProxy::restoreFromSessionStateData):
* WebKit2.xcodeproj/project.pbxproj:
* WebProcess/InjectedBundle/API/c/WKBundle.cpp:
(WKBundleCreateWKDataFromUInt8Array):
* WebProcess/InjectedBundle/InjectedBundle.cpp:
(WebKit::InjectedBundle::createWebDataFromUint8Array):
* WebProcess/InjectedBundle/InjectedBundle.h:
* WebProcess/InjectedBundle/InjectedBundlePageEditorClient.cpp:
(WebKit::InjectedBundlePageEditorClient::getPasteboardDataForRange):
* WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
(WebKit::InjectedBundlePageLoaderClient::willLoadDataRequest):
* WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::loadDataImpl):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160653 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Add a menu option to MiniBrowser to enable UI-side compositing
https://bugs.webkit.org/show_bug.cgi?id=125793

Reviewed by Anders Carlsson.

Make it possible to test UI-side compositing in MiniBrowser WK2 windows.

* MiniBrowser/mac/BrowserWindowController.h: Add optional protocol method
to toggle UI-side compositing.
* MiniBrowser/mac/MainMenu.xib: Add menu item to Debug menu.
* MiniBrowser/mac/WK2BrowserWindowController.m:
(-[WK2BrowserWindowController validateMenuItem:]):
(-[WK2BrowserWindowController isUISideCompositingEnabled]):
(-[WK2BrowserWindowController toggleUISideCompositing:]):
(-[WK2BrowserWindowController observeValueForKeyPath:ofObject:change:context:]):
Adjust the window title to indicate whether the window is using UI-side compositing.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160654 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fixed Win64 build on VS2013.
https://bugs.webkit.org/show_bug.cgi?id=125753

Patch by Alex Christensen <achristensen@webkit.org> on 2013-12-16
Reviewed by Brent Fulgham.

Source/JavaScriptCore:

* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
* JavaScriptCore.vcxproj/JavaScriptCoreGenerated.vcxproj:
* JavaScriptCore.vcxproj/LLInt/LLIntAssembly/LLIntAssembly.vcxproj:
* JavaScriptCore.vcxproj/LLInt/LLIntDesiredOffsets/LLIntDesiredOffsets.vcxproj:
* JavaScriptCore.vcxproj/LLInt/LLIntOffsetsExtractor/LLIntOffsetsExtractor.vcxproj:
* JavaScriptCore.vcxproj/jsc/jsc.vcxproj:
* JavaScriptCore.vcxproj/testRegExp/testRegExp.vcxproj:
* JavaScriptCore.vcxproj/testapi/testapi.vcxproj:
Added correct PlatformToolset for 64-bit builds.

Source/ThirdParty/ANGLE:

* ANGLE.vcxproj/libGLESv2.vcxproj:
* ANGLE.vcxproj/preprocessor.vcxproj:
* ANGLE.vcxproj/translator_common.vcxproj:
* ANGLE.vcxproj/translator_glsl.vcxproj:
* ANGLE.vcxproj/translator_hlsl.vcxproj:
Added correct PlatformToolset for 64-bit builds.

Source/WebCore:

* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCoreTestSupport.vcxproj:
Added correct PlatformToolset for 64-bit builds.

Source/WebInspectorUI:

* WebInspectorUI.vcxproj/WebInspectorUI.vcxproj:
Added 64-bit configuration.

Source/WebKit:

* WebKit.vcxproj/WebKit.sln:
Use new 64-bit WebInspectorUI configurations.
* WebKit.vcxproj/Interfaces/Interfaces.vcxproj:
* WebKit.vcxproj/WebKit/WebKit.vcxproj:
* WebKit.vcxproj/WebKitExportGenerator/WebKitExportGenerator.vcxproj:
* WebKit.vcxproj/WebKitGUID/WebKitGUID.vcxproj:
Added correct PlatformToolset for 64-bit builds.

Source/WTF:

* WTF.vcxproj/WTF.vcxproj:
Added correct PlatformToolset for 64-bit builds.

Tools:

* DumpRenderTree/DumpRenderTree.vcxproj/DumpRenderTree/DumpRenderTree.vcxproj:
* DumpRenderTree/DumpRenderTree.vcxproj/DumpRenderTree/DumpRenderTreeLauncher.vcxproj:
* DumpRenderTree/DumpRenderTree.vcxproj/ImageDiff/ImageDiff.vcxproj:
* DumpRenderTree/DumpRenderTree.vcxproj/ImageDiff/ImageDiffLauncher.vcxproj:
* DumpRenderTree/DumpRenderTree.vcxproj/TestNetscapePlugin/TestNetscapePlugin.vcxproj:
* TestWebKitAPI/TestWebKitAPI.vcxproj/TestWebKitAPI.vcxproj:
* WinLauncher/WinLauncher.vcxproj/WinLauncher.vcxproj:
* WinLauncher/WinLauncher.vcxproj/WinLauncherLib.vcxproj:
* win/record-memory/record-memory.vcxproj:
Added correct PlatformToolset for 64-bit builds.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160655 268f45cc-cd09-0410-ab3c-d52691b4dbfc
UserData should encode and decode API::Data objects
https://bugs.webkit.org/show_bug.cgi?id=125799

Reviewed by Beth Dakin.

* Shared/APIData.cpp: Added.
(API::Data::encode):
(API::Data::decode):
* Shared/APIData.h:
* Shared/UserData.cpp:
(WebKit::UserData::encode):
(WebKit::UserData::decode):
* WebKit2.xcodeproj/project.pbxproj:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160657 268f45cc-cd09-0410-ab3c-d52691b4dbfc
DatabaseProcess: Fix a few bugs with opening an IDB connection
https://bugs.webkit.org/show_bug.cgi?id=125798

Reviewed by Alexey Proskuryakov.

Source/WebCore:

* Modules/indexeddb/IDBDatabaseBackend.cpp:
(WebCore::IDBDatabaseBackend::processPendingCalls): As the comment says, we should only
  early return when there *are* pending delete calls. The logic here was backwards,
  preventing the backend from ever getting to processPendingOpenCalls().

Source/WebKit2:

Database metadata always needs a non-zero database identifier, unique at runtime.

* DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
(WebKit::generateDatabaseId):
(WebKit::UniqueIDBDatabaseBackingStoreSQLite::getOrEstablishMetadata):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160659 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[WK2] The NetworkProcess tries to load SecItemShim.dylib on iOS
https://bugs.webkit.org/show_bug.cgi?id=125800

Patch by Benjamin Poulain <bpoulain@apple.com> on 2013-12-16
Reviewed by Dan Bernstein.

Give the NetworkService its own Info.plist configured without the Shim.

* Configurations/NetworkService.xcconfig:
* NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info-OSX.plist: Copied from Source/WebKit2/NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info.plist.
* NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info-iOS.plist: Renamed from Source/WebKit2/NetworkProcess/EntryPoint/mac/XPCService/NetworkService/Info.plist.
* WebKit2.xcodeproj/project.pbxproj:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160661 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Cocoa] Expose whether the page contains only secure content
https://bugs.webkit.org/show_bug.cgi?id=125758

Reviewed by Anders Carlsson.

* UIProcess/API/Cocoa/WKBrowsingContextController.mm:
(-[WKBrowsingContextController hasOnlySecureContent]): Added a getter that calls
PageLoadState::hasOnlySecureContent.
* UIProcess/API/Cocoa/WKBrowsingContextControllerPrivate.h: Declared new property.

* UIProcess/PageLoadState.cpp:
(WebKit::PageLoadState::commitChanges): Notify observers of hasOnlySecureContent() changes.
(WebKit::PageLoadState::reset): Reset hasInsecureContent in the uncommitted state.
(WebKit::PageLoadState::hasOnlySecureContent): Added. Returns true if there is no insecure
content and the URL is an HTTPS URL.
(WebKit::PageLoadState::didCommitLoad): Set hasInsecureContent to false in the uncommitted
state.
(WebKit::PageLoadState::didDisplayOrRunInsecureContent): Set hasInsecureContent to true in
the uncommitted state.
* UIProcess/PageLoadState.h:
(WebKit::PageLoadState::Data::Data): Added hasInsecureContent member.

* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::didDisplayInsecureContentForFrame): Call
PageLoadState::didDisplayOrRunInsecureContent and commit the change before calling out to
the client.
(WebKit::WebPageProxy::didRunInsecureContentForFrame): Ditto.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160662 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Mac] Cache partitioning asserts when associated NSURLRequest is nil
https://bugs.webkit.org/show_bug.cgi?id=125716

Reviewed by Darin Adler.

* platform/network/mac/ResourceRequestMac.mm:
(WebCore::ResourceRequest::doUpdateResourceRequest):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160663 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fix crash when trying to load a null HTML string
https://bugs.webkit.org/show_bug.cgi?id=125801

Reviewed by Dan Bernstein.

Source/WebKit2:

* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::loadString):
Check that the string is not null before calling is8Bit(). Also, Use the latin1 encoding for
8-bit strings, since Latin 1 strings are not necessarily valid UTF-8 strings.

Tools:

* TestWebKitAPI/Tests/WebKit2/WillLoad.cpp:
(TestWebKitAPI::TEST_F):
Update test results.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160664 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Change slow path result to take a void* instead of a ExecState*.
https://bugs.webkit.org/show_bug.cgi?id=125802.

Reviewed by Filip Pizlo.

This is in preparation for C Stack OSR entry work that is coming soon.
In the OSR entry case, we'll be returning a topOfFrame pointer value
instead of the ExecState*.

* offlineasm/cloop.rb:
* runtime/CommonSlowPaths.h:
(JSC::encodeResult):
(JSC::decodeResult):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160665 268f45cc-cd09-0410-ab3c-d52691b4dbfc
DatabaseProcess: Implement openTransaction()
https://bugs.webkit.org/show_bug.cgi?id=125794

Reviewed by Darin Adler.

This patch hooks up all of the necessary infrastructure to open a uniquely
identified transaction in the DatabaseProcess backing store.

The transaction itself is not yet functional.

Add openTransaction messaging to the WebProcess side:
* WebProcess/Databases/IndexedDB/WebIDBServerConnection.cpp:
(WebKit::WebIDBServerConnection::isClosed):
(WebKit::WebIDBServerConnection::getOrEstablishIDBDatabaseMetadata):
(WebKit::WebIDBServerConnection::didGetOrEstablishIDBDatabaseMetadata):
(WebKit::WebIDBServerConnection::openTransaction):
(WebKit::WebIDBServerConnection::didOpenTransaction):
(WebKit::WebIDBServerConnection::deleteObjectStore):
* WebProcess/Databases/IndexedDB/WebIDBServerConnection.h:
* WebProcess/Databases/IndexedDB/WebIDBServerConnection.messages.in:

Add openTransaction messaging to the DatabaseProcess side:
* DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.cpp:
(WebKit::DatabaseProcessIDBConnection::openTransaction):
* DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.h:
* DatabaseProcess/IndexedDB/DatabaseProcessIDBConnection.messages.in:

Add a hashable identifier that represents a connection/transactionID pair:
* DatabaseProcess/IndexedDB/IDBTransactionIdentifier.h: Added.
(WebKit::IDBTransactionIdentifier::IDBTransactionIdentifier):
(WebKit::IDBTransactionIdentifier::isolatedCopy):
(WebKit::IDBTransactionIdentifier::isEmpty):
(WebKit::IDBTransactionIdentifier::hash):
(WebKit::IDBTransactionIdentifier::operator==):
(WebKit::IDBTransactionIdentifier::isHashTableDeletedValue):
(WebKit::IDBTransactionIdentifierHash::hash):
(WebKit::IDBTransactionIdentifierHash::equal):
(WebKit::IDBTransactionIdentifierHashTraits::isEmptyValue):

Allow that identifier to be cross-thread copied:
* Shared/WebCrossThreadCopier.cpp:
(WebCore::::copy):
* Shared/WebCrossThreadCopier.h:

Ask the backing store to open this uniquely identified transaction:
* DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
(WebKit::UniqueIDBDatabase::openTransaction):
(WebKit::UniqueIDBDatabase::openBackingStoreTransaction):
(WebKit::UniqueIDBDatabase::didOpenBackingStoreTransaction):
* DatabaseProcess/IndexedDB/UniqueIDBDatabase.h:

Add the backing store implementation for opening a transaction:
* DatabaseProcess/IndexedDB/UniqueIDBDatabaseBackingStore.h:
* DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.cpp:
(WebKit::UniqueIDBDatabaseBackingStoreSQLite::~UniqueIDBDatabaseBackingStoreSQLite):
(WebKit::UniqueIDBDatabaseBackingStoreSQLite::establishTransaction):
* DatabaseProcess/IndexedDB/sqlite/UniqueIDBDatabaseBackingStoreSQLite.h:

Object to represent the backing store transaction itself, to be used in future patches:
* DatabaseProcess/IndexedDB/sqlite/SQLiteIDBTransaction.cpp:
(WebKit::SQLiteIDBTransaction::SQLiteIDBTransaction):
* DatabaseProcess/IndexedDB/sqlite/SQLiteIDBTransaction.h:
(WebKit::SQLiteIDBTransaction::create):
(WebKit::SQLiteIDBTransaction::identifier):

* WebKit2.xcodeproj/project.pbxproj:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160667 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS] Upstream WebCore/svg changes
https://bugs.webkit.org/show_bug.cgi?id=125784

Reviewed by Darin Adler.

* svg/SVGAElement.cpp:
(WebCore::SVGAElement::willRespondToMouseClickEvents): Added.
* svg/SVGAElement.h:
* svg/SVGElement.cpp:
(WebCore::SVGElement::parseAttribute): Added attribute listeners for touch{cancel, end, move, start},
and gesture{change, end, start}.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160668 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[iOS] Upstream WebCore/history changes
https://bugs.webkit.org/show_bug.cgi?id=125769

Reviewed by Darin Adler.

* history/BackForwardClient.h:
* history/BackForwardList.cpp:
(WebCore::BackForwardList::current): Added; guard by PLATFORM(IOS). Also added FIXME comment.
(WebCore::BackForwardList::setCurrent): Added; guard by PLATFORM(IOS). Also added FIXME comment.
(WebCore::BackForwardList::clearAllPageCaches): Added; guarded by PLATFORM(IOS).
* history/BackForwardList.h:
* history/CachedFrame.cpp:
(WebCore::CachedFrameBase::restore): Added iOS-specific code.
(WebCore::CachedFrame::CachedFrame): Ditto.
* history/CachedPage.cpp:
(WebCore::CachedPage::restore): Ditto.
* history/HistoryItem.cpp:
(WebCore::HistoryItem::HistoryItem): Ditto.
* history/HistoryItem.h:
(WebCore::HistoryItem::scale): Added; guarded by PLATFORM(IOS).
(WebCore::HistoryItem::scaleIsInitial): Added; guarded by PLATFORM(IOS).
(WebCore::HistoryItem::setScale): Added; guarded by PLATFORM(IOS).
(WebCore::HistoryItem::viewportArguments): Added; guarded by PLATFORM(IOS).
(WebCore::HistoryItem::setViewportArguments): Added; guarded by PLATFORM(IOS).
(WebCore::HistoryItem::bookmarkID): Added; guarded by PLATFORM(IOS).
(WebCore::HistoryItem::setBookmarkID): Added; guarded by PLATFORM(IOS).
(WebCore::HistoryItem::sharedLinkUniqueIdentifier): Added; guarded by PLATFORM(IOS).
(WebCore::HistoryItem::setSharedLinkUniqueIdentifier): Added; guarded by PLATFORM(IOS).
* history/PageCache.cpp:
(WebCore::logCanCacheFrameDecision): Added iOS-specific code.
(WebCore::logCanCachePageDecision): Ditto.
(WebCore::PageCache::canCachePageContainingThisFrame): Ditto.
(WebCore::PageCache::canCache): Ditto.
(WebCore::PageCache::pruneToCapacityNow): Added.
* history/PageCache.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160669 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Cache getters and custom accessors on the prototype chain
https://bugs.webkit.org/show_bug.cgi?id=125602

Reviewed by Michael Saboff.

Source/JavaScriptCore:

Support caching of custom getters and accessors on the prototype chain.
This is relatively trivial and just requires a little work compared to
the direct access mode as we're under more register pressure.

* bytecode/StructureStubInfo.h:
  Removed the unsued initGetByIdProto as it was confusing to still have it present.
* jit/Repatch.cpp:
(JSC::generateProtoChainAccessStub):
(JSC::tryCacheGetByID):
(JSC::tryBuildGetByIDList):

Tools:

Make sure bencher scripts also make noInline exist

* Scripts/bencher:

LayoutTests:

Added a bunch of new tests

* js/regress/chain-custom-getter-expected.txt: Added.
* js/regress/chain-custom-getter.html: Added.
* js/regress/chain-getter-access-expected.txt: Added.
* js/regress/chain-getter-access.html: Added.
* js/regress/proto-custom-getter-expected.txt: Added.
* js/regress/proto-custom-getter.html: Added.
* js/regress/proto-getter-access-expected.txt: Added.
* js/regress/proto-getter-access.html: Added.
* js/regress/resources/regress-pre.js:
  Made sure that noInline always exists (either using testRunner.neverInlineFunction
  or a no-op function if nothing else is available)
* js/regress/script-tests/chain-custom-getter.js: Added.
(foo):
* js/regress/script-tests/chain-getter-access.js: Added.
(o.get value):
(foo):
* js/regress/script-tests/proto-custom-getter.js: Added.
(foo):
* js/regress/script-tests/proto-getter-access.js: Added.
(o.get value):
(foo):
* js/regress/script-tests/simple-custom-getter.js: Added.
(cycles.30000.numberObject.Number.foo):
* js/regress/script-tests/simple-getter-access.js: Added.
(o.get value):
(foo):
* js/regress/simple-custom-getter-expected.txt: Added.
* js/regress/simple-custom-getter.html: Added.
* js/regress/simple-getter-access-expected.txt: Added.
* js/regress/simple-getter-access.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160670 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore: [Win] Remove dead code after conversion to VS2013
https://bugs.webkit.org/show_bug.cgi?id=125795

Reviewed by Darin Adler.

* API/tests/testapi.c: Remove local nan implementation

Source/WebCore: [Win] Remove dead code after converstion to VS2013
https://bugs.webkit.org/show_bug.cgi?id=125795

Reviewed by Darin Adler.

* WebCorePrefix.h: Remove VS2012 include kludge.
* loader/FTPDirectoryParser.cpp: Remove gmtime workaround code.
* page/DOMWindow.cpp: Remove older pointer-based open implementation.
* page/DOMWindow.h: Ditto
* platform/text/TextEncodingRegistry.cpp:
(WebCore::TextEncodingNameHash::equal): Remove optimization bug workaround
* testing/Internals.cpp:
(WebCore::Internals::openDummyInspectorFrontend): Remove compiler workaround

Source/WebKit: [Win] Remove dead code after conversion to VS2013
https://bugs.webkit.org/show_bug.cgi?id=125795

Reviewed by Darin Adler.

* WebKit.vcxproj/WebKitExportGenerator/WebKitExports.def.in:
Remove unused function exports.

Source/WTF: [Win] Remove dead code after conversion to VS2013
https://bugs.webkit.org/show_bug.cgi?id=125795

Reviewed by Darin Adler.

* wtf/Assertions.h: Include <inttypes.h> now that it exists.
* wtf/Compiler.h: Update compiler checks for VS2013, and
enable support for NEVER_INLINE
* wtf/HashFunctions.h:
(WTF::PtrHash::hash): Remove compiler workaround.
* wtf/MathExtras.h: Remove C99 functions that are now supplied
by the MS runtime library.
* wtf/Platform.h: Remove old MSVC support flags.
* wtf/StdLibExtras.h: Remove old MSVC workaround code.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160671 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Apply overhang shadow and linen to UI-side layers
https://bugs.webkit.org/show_bug.cgi?id=125807

Source/WebCore:

Reviewed by Tim Horton.

With UI-side compositing, we need to apply the overhang shadow and linen
background to layers in the UI process. Achieve this by setting a "custom
appearance" flag on layers that need a shadow or linen background, and
migrating this flag to the UI process. Static functions on ScrollbarThemeMac
are exposed to do the actual setting.

* WebCore.exp.in: Export ScrollbarThemeMac and GraphicsLayerCA functions.
* WebCore.xcodeproj/project.pbxproj: ScrollbarThemeMac.h and ScrollbarThemeComposite.h
need to be Private.
* platform/graphics/GraphicsLayer.cpp: Initialize m_customAppearance.
(WebCore::GraphicsLayer::GraphicsLayer):
* platform/graphics/GraphicsLayer.h: Getter/setter for CustomAppearance.
(WebCore::GraphicsLayer::setCustomAppearance):
(WebCore::GraphicsLayer::customAppearance):
* platform/graphics/ca/GraphicsLayerCA.cpp: Update CustomAppearanceChanged as
we do other properties.
(WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
(WebCore::GraphicsLayerCA::updateCustomAppearance):
(WebCore::GraphicsLayerCA::setCustomAppearance):
* platform/graphics/ca/GraphicsLayerCA.h:
* platform/graphics/ca/PlatformCALayer.h:
* platform/graphics/ca/mac/PlatformCALayerMac.h:
* platform/graphics/ca/mac/PlatformCALayerMac.mm: When we have a custom
appearance, use ScrollbarThemeMac functions to update the layer. Ensure
that if the bounds change, we update the shadow (whose path depends on the bounds).
(PlatformCALayerMac::PlatformCALayerMac):
(PlatformCALayerMac::clone):
(PlatformCALayerMac::setBounds):
(PlatformCALayerMac::requiresCustomAppearanceUpdateOnBoundsChange):
(PlatformCALayerMac::updateCustomAppearance):
* platform/mac/ScrollbarThemeMac.h: Export some static functions.
* platform/mac/ScrollbarThemeMac.mm: Change code to use static functions.
(WebCore::ScrollbarThemeMac::setUpOverhangAreaBackground):
(WebCore::ScrollbarThemeMac::removeOverhangAreaBackground):
(WebCore::ScrollbarThemeMac::setUpOverhangAreaShadow):
(WebCore::ScrollbarThemeMac::removeOverhangAreaShadow):
(WebCore::ScrollbarThemeMac::setUpOverhangAreasLayerContents):
(WebCore::ScrollbarThemeMac::setUpContentShadowLayer):
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::updateRootLayerPosition): No need to call
setUpContentShadowLayer() now when size changes; PlatformCALayer takes
care of that.
(WebCore::RenderLayerCompositor::updateOverflowControlsLayers): Now set
custom appearance via GraphicsLayer.

Source/WebKit2:

Reviewed by Tim Horton.

With UI-side compositing, we need to apply the overhang shadow and linen
background to layers in the UI process. Achieve this by setting a "custom
appearance" flag on layers that need a shadow or linen background, and
migrating this flag to the UI process. Static functions on ScrollbarThemeMac
are exposed to do the actual setting.

* Shared/mac/RemoteLayerTreePropertyApplier.mm:
(WebKit::updateCustomAppearance): Use ScrollbarThemeMac to update the
appearance.
(WebKit::RemoteLayerTreePropertyApplier::applyPropertiesToLayer):
* Shared/mac/RemoteLayerTreeTransaction.h:
* Shared/mac/RemoteLayerTreeTransaction.mm:
(WebKit::RemoteLayerTreeTransaction::LayerProperties::encode):
(WebKit::RemoteLayerTreeTransaction::LayerProperties::decode):
(WebKit::dumpChangedLayers):
* WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
(PlatformCALayerRemote::setBounds): If the bounds change, also set the
CustomAppearanceChanged bit so that the UI side updates the shadow bounds
(done here because the UI side is not stateful).
(PlatformCALayerRemote::requiresCustomAppearanceUpdateOnBoundsChange):
(PlatformCALayerRemote::customAppearance):
(PlatformCALayerRemote::updateCustomAppearance):
* WebProcess/WebPage/mac/PlatformCALayerRemote.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@160672 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[WK2] Remove the constraint that highlight rects must be smaller than the scrollview bounds
https://bugs.webkit.org/show_bug.cgi?id=125812

Patch by Benjamin Poulain <bpoulain@apple.com> on 2013-12-16
Reviewed by Dan Bernstein.

Currently, _scrollView is never set on WKInteractionView and all highlight rects are discarded.

Eventually, the constraint rect should be computed from the useful area of ScrollView and the scale
of the document. In the meantime, the constraint code is just causing troubles.

The issue is tracked by <rdar://problem/15673655>.

* UIProcess/API/ios/WKInteractionView.mm:
(-[WKInteractionView _didGetTapHighlightForRequest:color:WebCore::quads:WebCore::topLeftRadius:WebCore::topRightRadius:WebCore::bottomLeftRadius:WebCore::bottomRightRadius:WebCore::]):


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