ChangeLog-2015-11-21   [plain text]


2015-11-21  Michael Catanzaro  <mcatanzaro@igalia.com>

        [GTK] Off-by-one error in getStyleContext()
        https://bugs.webkit.org/show_bug.cgi?id=151524

        Reviewed by Carlos Garcia Campos.

        GtkWidgetPath* path = gtk_widget_path_new();
        gtk_widget_path_append_type(path, widgetType);
        // ...
        gtk_widget_path_iter_add_class(path, 0, GTK_STYLE_CLASS_BUTTON);
        gtk_widget_path_iter_add_class(path, 1, "text-button");

        Only one widget type was appended to the widget path, so the maximum valid index is 0. This
        code means to add both style classes to the first widget type in the widget path, so the
        second call should use index 0 rather than index 1.

        This caused no bug in practice, because when the index is invalid,
        gtk_widget_path_iter_add_class() automatically changes the index to the last valid position
        in the widget path -- in this case, 0. This is routinely done with -1 as a convention for
        specifying the last position in the widget path.

        * rendering/RenderThemeGtk.cpp:
        (WebCore::getStyleContext):

2015-11-21  Michael Catanzaro  <mcatanzaro@igalia.com>

        [GTK] Warning spam from GtkStyleContext
        https://bugs.webkit.org/show_bug.cgi?id=151520

        Reviewed by Carlos Garcia Campos.

        Audit every use of gtk_style_context_get_* to fix compatibility with GTK+ 3.19. Some of
        these were already fine and are only changed for clarity.

        Company:  gtk_style_context_get() (and _get_padding/border/color()) should only ever be
                  called with the same state as gtk_style_context_get_state()
        Company:  usually that's a simple replacing of the old state (like in the trace you posted)
        Company:  sometimes it requires calling gtk_style_context_set_sate() with the right state
                  first
        Company:  and in very rare cases it needs a gtk_style_context_save() before the set_state(),
                  too

        * platform/gtk/ScrollbarThemeGtk.cpp:
        (WebCore::adjustRectAccordingToMargin):
        * rendering/RenderThemeGtk.cpp:
        (gtk_css_section_print):
        (WebCore::getStyleContext):
        (WebCore::RenderThemeGtk::initMediaColors):
        (WebCore::renderButton):
        (WebCore::getComboBoxMetrics):
        (WebCore::RenderThemeGtk::paintMenuList):
        (WebCore::RenderThemeGtk::paintTextField):
        (WebCore::RenderThemeGtk::paintProgressBar):
        (WebCore::spinButtonArrowSize):
        (WebCore::RenderThemeGtk::adjustInnerSpinButtonStyle):
        (WebCore::styleColor):

2015-11-20  Brady Eidson  <beidson@apple.com>

        Modern IDB: After versionchange transactions complete, fire onsuccess on the original IDBOpenDBRequest
        https://bugs.webkit.org/show_bug.cgi?id=151522

        Reviewed by Alex Christensen.

        Test: storage/indexeddb/modern/opendatabase-success-after-versionchange.html (And changes to other existing tests)

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::startVersionChangeTransaction):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:
        
        * Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBOpenDBRequest::fireSuccessAfterVersionChangeCommit):
        (WebCore::IDBClient::IDBOpenDBRequest::onUpgradeNeeded):
        * Modules/indexeddb/client/IDBOpenDBRequestImpl.h:
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::create):
        (WebCore::IDBClient::IDBTransaction::IDBTransaction):
        (WebCore::IDBClient::IDBTransaction::dispatchEvent):
        * Modules/indexeddb/client/IDBTransactionImpl.h:

2015-11-20  Simon Fraser  <simon.fraser@apple.com>

        More deviceRGB color cleanup
        https://bugs.webkit.org/show_bug.cgi?id=151523
        <rdar://problem/23638597>

        Reviewed by Tim Horton.

        Replace calls to deviceRGBColorSpaceRef() with sRGBColorSpaceRef(), and use
        sRGBColorSpaceRef() in a few places that were manually creating the colorspace.

        Also use cachedCGColor() in a more places that were manually constructing CGColorRefs
        from Colors.

        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
        (WebCore::MediaPlayerPrivateAVFoundationObjC::createImageForTimeInRect):
        (WebCore::createImageFromPixelBuffer):
        * platform/graphics/ca/cocoa/PlatformCAFiltersCocoa.mm:
        * platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:
        (PlatformCALayerCocoa::setBackgroundColor):
        (PlatformCALayerCocoa::setBorderColor):
        * platform/graphics/ca/cocoa/WebSystemBackdropLayer.mm:
        (-[WebLightSystemBackdropLayer init]):
        (-[WebDarkSystemBackdropLayer init]):
        * platform/graphics/cg/GradientCG.cpp:
        (WebCore::Gradient::platformGradient):
        * platform/graphics/cg/GraphicsContext3DCG.cpp:
        (WebCore::GraphicsContext3D::ImageExtractor::extractImage):
        (WebCore::GraphicsContext3D::paintToCanvas):
        * platform/graphics/cg/ImageBufferCG.cpp:
        (WebCore::ImageBuffer::copyImage):
        (WebCore::ImageBuffer::toDataURL):
        (WebCore::ImageDataToDataURL):
        * platform/graphics/mac/GraphicsContextMac.mm:
        (WebCore::linearRGBColorSpaceRef):
        * platform/graphics/mac/WebGLLayer.mm:
        (-[WebGLLayer copyImageSnapshotWithColorSpace:]):
        * platform/mediastream/mac/AVVideoCaptureSource.mm:
        (WebCore::AVVideoCaptureSource::currentFrameCGImage):
        * rendering/RenderThemeIOS.mm:
        (WebCore::drawRadialGradient):
        * rendering/RenderThemeMac.mm:
        (WebCore::RenderThemeMac::paintMenuListButtonGradients):
        (WebCore::RenderThemeMac::paintSliderTrack):

2015-11-20  Katlyn Graff  <kgraff@apple.com>

        Renaming PageCache suspension code to support more reasons for suspension.
        https://bugs.webkit.org/show_bug.cgi?id=151527

        Reviewed by Ryosuke Niwa.

        No new tests because this is simply a refactor.

        Renamed Element:: and Document:: documentWillSuspendForPageCache(),
        documentDidResumeFromPageCache(),
        registerForPageCacheSuspensionCallbacks(),
        unregisterForPageCacheSuspensionCallbacks() to prepare to support
        alternate reasons for document-level suspension.

        * dom/Document.cpp:
        (WebCore::Document::suspend):
        (WebCore::Document::resume):
        (WebCore::Document::registerForDocumentSuspensionCallbacks):
        (WebCore::Document::unregisterForDocumentSuspensionCallbacks):
        (WebCore::Document::documentWillSuspendForPageCache): Deleted.
        (WebCore::Document::documentDidResumeFromPageCache): Deleted.
        (WebCore::Document::registerForPageCacheSuspensionCallbacks): Deleted.
        (WebCore::Document::unregisterForPageCacheSuspensionCallbacks): Deleted.
        * dom/Document.h:
        * dom/Element.h:
        (WebCore::Element::prepareForDocumentSuspension):
        (WebCore::Element::resumeFromDocumentSuspension):
        (WebCore::Element::documentWillSuspendForPageCache): Deleted.
        (WebCore::Element::documentDidResumeFromPageCache): Deleted.
        * history/CachedFrame.cpp:
        (WebCore::CachedFrameBase::restore):
        (WebCore::CachedFrame::CachedFrame):
        * html/HTMLFormElement.cpp:
        (WebCore::HTMLFormElement::~HTMLFormElement):
        (WebCore::HTMLFormElement::parseAttribute):
        (WebCore::HTMLFormElement::resumeFromDocumentSuspension):
        (WebCore::HTMLFormElement::didMoveToNewDocument):
        (WebCore::HTMLFormElement::documentDidResumeFromPageCache): Deleted.
        * html/HTMLFormElement.h:
        * html/HTMLInputElement.cpp:
        (WebCore::HTMLInputElement::~HTMLInputElement):
        (WebCore::HTMLInputElement::registerForSuspensionCallbackIfNeeded):
        (WebCore::HTMLInputElement::unregisterForSuspensionCallbackIfNeeded):
        (WebCore::HTMLInputElement::resumeFromDocumentSuspension):
        (WebCore::HTMLInputElement::prepareForDocumentSuspension):
        (WebCore::HTMLInputElement::didMoveToNewDocument):
        (WebCore::HTMLInputElement::documentDidResumeFromPageCache): Deleted.
        (WebCore::HTMLInputElement::documentWillSuspendForPageCache): Deleted.
        * html/HTMLInputElement.h:
        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::registerWithDocument):
        (WebCore::HTMLMediaElement::unregisterWithDocument):
        (WebCore::HTMLMediaElement::prepareForDocumentSuspension):
        (WebCore::HTMLMediaElement::resumeFromDocumentSuspension):
        (WebCore::HTMLMediaElement::documentWillSuspendForPageCache): Deleted.
        (WebCore::HTMLMediaElement::documentDidResumeFromPageCache): Deleted.
        * html/HTMLMediaElement.h:
        * html/HTMLPlugInImageElement.cpp:
        (WebCore::HTMLPlugInImageElement::~HTMLPlugInImageElement):
        (WebCore::HTMLPlugInImageElement::createElementRenderer):
        (WebCore::HTMLPlugInImageElement::didMoveToNewDocument):
        (WebCore::HTMLPlugInImageElement::prepareForDocumentSuspension):
        (WebCore::HTMLPlugInImageElement::resumeFromDocumentSuspension):
        (WebCore::HTMLPlugInImageElement::documentWillSuspendForPageCache): Deleted.
        (WebCore::HTMLPlugInImageElement::documentDidResumeFromPageCache): Deleted.
        * html/HTMLPlugInImageElement.h:
        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::commitProvisionalLoad):
        * svg/SVGSVGElement.cpp:
        (WebCore::SVGSVGElement::SVGSVGElement):
        (WebCore::SVGSVGElement::~SVGSVGElement):
        (WebCore::SVGSVGElement::didMoveToNewDocument):
        (WebCore::SVGSVGElement::prepareForDocumentSuspension):
        (WebCore::SVGSVGElement::resumeFromDocumentSuspension):
        (WebCore::SVGSVGElement::documentWillSuspendForPageCache): Deleted.
        (WebCore::SVGSVGElement::documentDidResumeFromPageCache): Deleted.
        * svg/SVGSVGElement.h:

2015-11-20  Simon Fraser  <simon.fraser@apple.com>

        Fix the Windows build.

        * platform/graphics/cg/IOSurfacePool.h:

2015-11-20  Simon Fraser  <simon.fraser@apple.com>

        Allow more buffer formats in the IOSurface pool
        https://bugs.webkit.org/show_bug.cgi?id=151516

        Reviewed by Tim Horton.

        Previously IOSurface::create was only looking in the pool for RGBA-format surfaces. Change that to
        always look in the pool, and to cache all format types. We include format in the criteria used
        to pick a surface from the pool.
        
        * platform/graphics/cg/IOSurfacePool.cpp:
        (WebCore::surfaceMatchesParameters):
        (WebCore::IOSurfacePool::takeSurface):
        (WebCore::IOSurfacePool::shouldCacheFormat):
        (WebCore::IOSurfacePool::shouldCacheSurface):
        (WebCore::IOSurfacePool::addSurface):
        * platform/graphics/cg/IOSurfacePool.h:
        * platform/graphics/cocoa/IOSurface.h:
        * platform/graphics/cocoa/IOSurface.mm:
        (IOSurface::surfaceFromPool):
        (IOSurface::create):
        (IOSurface::IOSurface):

2015-11-20  Brent Fulgham  <bfulgham@apple.com>

        [Win] Support High DPI drawing with CACFLayers
        https://bugs.webkit.org/show_bug.cgi?id=147242
        <rdar://problem/19861992>

        Reviewed by Simon Fraser.

        * platform/graphics/ca/win/WKCACFViewLayerTreeHost.cpp:
        (WebCore::WKCACFViewLayerTreeHost::initializeContext): Set correct content scale factor
        for current screen, and apply an appropriate base transform to the CACFLayer so drawing
        operations are done properly.

2015-11-20  Brady Eidson  <beidson@apple.com>

        Modern IDB: In the VersionChangeEvent for delete database calls, oldVersion should be null instead of 0.
        https://bugs.webkit.org/show_bug.cgi?id=151481

        Reviewed by Sam Weinig.

        No new tests, covered by changes to:
            storage/indexeddb/modern/deletedatabase-1.html
            storage/indexeddb/modern/deletedatabase-2.html

        * Modules/indexeddb/IDBVersionChangeEvent.h:
        * Modules/indexeddb/IDBVersionChangeEvent.idl:
        
        * Modules/indexeddb/client/IDBVersionChangeEventImpl.cpp:
        (WebCore::IDBClient::IDBVersionChangeEvent::newVersion):
        * Modules/indexeddb/client/IDBVersionChangeEventImpl.h:
        
        * Modules/indexeddb/legacy/LegacyVersionChangeEvent.cpp:
        (WebCore::LegacyVersionChangeEvent::newVersion):
        * Modules/indexeddb/legacy/LegacyVersionChangeEvent.h:

2015-11-20  Brady Eidson  <beidson@apple.com>

        Addressing missed review feedback for:
        Modern IDB: Make in-memory ObjectStore cursors work.
        https://bugs.webkit.org/show_bug.cgi?id=151196

        Reviewed by Darin Adler.

        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::maybeOpenCursor):
        * Modules/indexeddb/server/MemoryObjectStoreCursor.cpp:
        (WebCore::IDBServer::MemoryObjectStoreCursor::create): Deleted.
        * Modules/indexeddb/server/MemoryObjectStoreCursor.h:

2015-11-20  Chris Dumez  <cdumez@apple.com>

        Caching of properties on objects that have named property getters is sometimes incorrect
        https://bugs.webkit.org/show_bug.cgi?id=151453
        <rdar://problem/23049343>

        Reviewed by Gavin Barraclough.

        In r188590, we dropped the JSC::GetOwnPropertySlotIsImpure TypeInfo flag for
        interfaces that have a non-'OverrideBuiltins' named property getter in order
        to allow caching of properties returns by GetOwnPropertySlot(). We assumed
        this was safe as it was no longer possible for named properties to override
        own properties (or properties on the prototype).

        However, there is an issue when we cache the non-existence of a property.
        Even though at one point the property did not exist, a named property with
        this name may later become available. In such case, caching would cause us
        to wrongly report a property as missing.

        To address the problem, this patch introduces a new
        GetOwnPropertySlotIsImpureForPropertyAbsence TypeInfo flag and uses it for
        interfaces that have a non-'OverrideBuiltins' named property getter. This
        will cause us to not cache the fact that a property is missing on such
        objects, while maintaining the performance win from r188590 in the common
        case.

        Test: fast/dom/NamedNodeMap-named-getter-caching.html

        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateHeader):
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
        * bindings/scripts/test/JS/JSTestEventTarget.h:
        * bindings/scripts/test/JS/JSTestOverrideBuiltins.h:

2015-11-19  Simon Fraser  <simon.fraser@apple.com>

        Back-buffer to front-buffer copy fails for some buffer formats
        https://bugs.webkit.org/show_bug.cgi?id=151475
        rdar://problem/23617899

        Reviewed by Tim Horton.
        
        Fix some fo the bitsPerComponent/bitsPerPixel options in IOSurface::ensurePlatformContext()
        for RGB10 buffers. Fix IOSurface::format() to return the new formats.
        
        Implement IOSurface::copyToSurface(), which does a synchronous copy between
        surfaces.

        * platform/graphics/cocoa/IOSurface.h:
        * platform/graphics/cocoa/IOSurface.mm:
        (IOSurface::create):
        (IOSurface::ensurePlatformContext):
        (IOSurface::format):
        (IOSurface::copyToSurface):

2015-11-20  Zalan Bujtas  <zalan@apple.com>

        Simple line layout: Add text-indent support.
        https://bugs.webkit.org/show_bug.cgi?id=151472

        Reviewed by Simon Fraser.

        This enables us to use simple line layout on text-indent content.

        Test: fast/text/simple-line-text-indent.html

        * rendering/SimpleLineLayout.cpp:
        (WebCore::SimpleLineLayout::updateLineConstrains):
        (WebCore::SimpleLineLayout::createTextRuns):
        (WebCore::SimpleLineLayout::canUseForStyle): Deleted.

2015-11-20  Brady Eidson  <beidson@apple.com>

        Modern IDB: IDBFactory.deleteDatabase() support.
        https://bugs.webkit.org/show_bug.cgi?id=151456

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/deletedatabase-1.html
               storage/indexeddb/modern/deletedatabase-2.html

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::hasPendingActivity):
        (WebCore::IDBClient::IDBDatabase::didCommitOrAbortTransaction):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:
        
        * Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBOpenDBRequest::onDeleteDatabaseSuccess):
        (WebCore::IDBClient::IDBOpenDBRequest::requestCompleted):
        * Modules/indexeddb/client/IDBOpenDBRequestImpl.h:
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::hasPendingActivity): Deleted.
        
        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::deleteDatabase):
        (WebCore::IDBServer::IDBServer::deleteUniqueIDBDatabase):
        * Modules/indexeddb/server/IDBServer.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::UniqueIDBDatabase):
        (WebCore::IDBServer::UniqueIDBDatabase::hasAnyPendingCallbacks):
        (WebCore::IDBServer::UniqueIDBDatabase::maybeDeleteDatabase):
        (WebCore::IDBServer::UniqueIDBDatabase::handleOpenDatabaseOperations):
        (WebCore::IDBServer::UniqueIDBDatabase::handleDelete):
        (WebCore::IDBServer::UniqueIDBDatabase::notifyConnectionsOfVersionChangeForUpgrade):
        (WebCore::IDBServer::UniqueIDBDatabase::notifyConnectionsOfVersionChange):
        (WebCore::IDBServer::UniqueIDBDatabase::connectionClosedFromClient):
        (WebCore::IDBServer::UniqueIDBDatabase::enqueueTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::invokeDeleteOrRunTransactionTimer):
        (WebCore::IDBServer::UniqueIDBDatabase::deleteOrRunTransactionsTimerFired):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformActivateTransactionInBackingStore):
        (WebCore::IDBServer::UniqueIDBDatabase::inProgressTransactionCompleted):
        (WebCore::IDBServer::UniqueIDBDatabase::invokeTransactionScheduler): Deleted.
        (WebCore::IDBServer::UniqueIDBDatabase::transactionSchedulingTimerFired): Deleted.
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        (WebCore::IDBServer::UniqueIDBDatabase::identifier):
        (WebCore::IDBServer::UniqueIDBDatabase::deletePending):
        
        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::deleteDatabaseSuccess):
        * Modules/indexeddb/shared/IDBResultData.h:

2015-11-20  Brady Eidson  <beidson@apple.com>

        Modern IDB: Get IDBRequest.readyState right.
        https://bugs.webkit.org/show_bug.cgi?id=151484

        Reviewed by Alex Christensen.

        Test: storage/indexeddb/modern/request-readystate.html

        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::readyState):

2015-11-20  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Use HTTPHeaderName as much as possible in XMLHttpRequest
        https://bugs.webkit.org/show_bug.cgi?id=151438

        Reviewed by Darin Adler.

        Removing XMLHttpRequest::setRequestHeaderInternal and XMLHttpRequest::getRequestHeader.
        Using directly HTTPHeaderMap.add, HTTPHeaderMap.set and HTTPHeaderMap.get.

        No change in behavior.

        * xml/XMLHttpRequest.cpp:
        (WebCore::XMLHttpRequest::send):
        (WebCore::XMLHttpRequest::setRequestHeader):
        (WebCore::XMLHttpRequest::getAllResponseHeaders):
        * xml/XMLHttpRequest.h:

2015-11-20  Eric Carlson  <eric.carlson@apple.com>

        MediaStream: Fix mock video source crash
        https://bugs.webkit.org/show_bug.cgi?id=151462

        Reviewed by Alexey Proskuryakov.

        No new tests, this fixes existing tests.

        * platform/mock/MockRealtimeVideoSource.cpp:
        (WebCore::MockRealtimeVideoSource::drawText): Declare the String used to intialize a 
          StringView explicitly so it outlives the StringView.

2015-11-20  David Kilzer  <ddkilzer@apple.com>

        REGRESSION (r192460,r192677): Fix all the builds

        * platform/spi/cocoa/QuartzCoreSPI.h: Check different.

2015-11-19  David Kilzer  <ddkilzer@apple.com>

        REGRESSION (r192460): Fix tvOS build again

        * platform/spi/cocoa/QuartzCoreSPI.h: Update version check.
        This will probably need to be backed out in the future.

2015-11-19  Adam Bergkvist  <adam.bergkvist@ericsson.com>

        WebRTC: Initial testing of updated RTCPeerConnection API
        https://bugs.webkit.org/show_bug.cgi?id=151304

        Reviewed by Eric Carlson.

        Remove faulty ASSERT since the selector argument to
        RTCPeerConnection.getStats() is nullable. Also use
        pointers instead of a ref (for the same reason).

        Tests: Unskip two crashing tests.

        * Modules/mediastream/MediaEndpointPeerConnection.cpp:
        (WebCore::MediaEndpointPeerConnection::getStats):
        * Modules/mediastream/MediaEndpointPeerConnection.h:
        * Modules/mediastream/PeerConnectionBackend.h:
        * Modules/mediastream/RTCPeerConnection.cpp:
        (WebCore::RTCPeerConnection::privateGetStats):

2015-11-19  Hunseop Jeong  <hs85.jeong@samsung.com>

        [EFL][GTK] context_menu API test failed after r192333
        https://bugs.webkit.org/show_bug.cgi?id=151437

        Reviewed by Carlos Garcia Campos.

        EFL,GTK port didn't use the share Menu.

        * page/ContextMenuController.cpp:
        (WebCore::ContextMenuController::populate):

2015-11-19  Brian Burg  <bburg@apple.com>

        Web Inspector: yank/kill shortcuts (CTRL+Y, K) don't work in Console / QuickConsole
        https://bugs.webkit.org/show_bug.cgi?id=151157

        Reviewed by Joseph Pecoraro.

        CodeMirror maintains its own editor buffer and implements its own
        `killLine` command but doesn't implement the yank command. So, text
        that is "killed" with CTRL-k inside a CodeMirror instance isn't
        added to Editor's kill ring. Subsequent yank commands won't match
        up with the killed text, instead returning text from a prior kill
        that was handled by Editor (i.e., in a contenteditable or form input).

        This patch adds a host function so that the Inspector frontend can
        append "missed" killed text to Editor's kill ring. Subsequent
        yanks handled by Editor will then match the text killed by CodeMirror.

        No new tests, because we need to use both InspectorFrontendHost
        and TestRunner.execCommand, but the latter is not available in
        the inspector context where we would need to simulate a kill.

        * inspector/InspectorFrontendHost.cpp:
        (WebCore::InspectorFrontendHost::killText):

            Added. This appends the killed text to the kill ring, starting
            a new sequence if necessary. Unlike Editor, Inspector waits
            until the next kill command to clear the existing sequence.

        * inspector/InspectorFrontendHost.h:
        * inspector/InspectorFrontendHost.idl:

2015-11-19  Zalan Bujtas  <zalan@apple.com>

        Simple line layout: Add word-spacing support.
        https://bugs.webkit.org/show_bug.cgi?id=151420

        Reviewed by Antti Koivisto.

        This enables us to use simple line layout on word-spacing content.

        Test: fast/text/simple-line-wordspacing.html

        * rendering/SimpleLineLayout.cpp:
        (WebCore::SimpleLineLayout::createLineRuns):
        (WebCore::SimpleLineLayout::canUseForStyle): Deleted.
        * rendering/SimpleLineLayoutTextFragmentIterator.cpp:
        (WebCore::SimpleLineLayout::TextFragmentIterator::Style::Style):
        (WebCore::SimpleLineLayout::TextFragmentIterator::skipToNextPosition):
        (WebCore::SimpleLineLayout::TextFragmentIterator::runWidth):
        * rendering/SimpleLineLayoutTextFragmentIterator.h:

2015-11-19  Brady Eidson  <beidson@apple.com>

        Modern IDB: IDBObjectStore.deleteIndex() support.
        https://bugs.webkit.org/show_bug.cgi?id=150911

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/deleteindex-1.html
               storage/indexeddb/modern/deleteindex-2.html

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::deleteIndex):
        (WebCore::IDBClient::IDBConnectionToServer::didDeleteIndex):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::didDeleteIndexInfo):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:

        * Modules/indexeddb/client/IDBIndexImpl.cpp:
        (WebCore::IDBClient::IDBIndex::markAsDeleted):
        * Modules/indexeddb/client/IDBIndexImpl.h:

        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::index):
        (WebCore::IDBClient::IDBObjectStore::deleteIndex):

        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::deleteIndex):
        (WebCore::IDBClient::IDBTransaction::deleteIndexOnServer):
        (WebCore::IDBClient::IDBTransaction::didDeleteIndexOnServer):
        * Modules/indexeddb/client/IDBTransactionImpl.h:

        * Modules/indexeddb/client/TransactionOperation.h:
        (WebCore::IDBClient::createTransactionOperation):

        * Modules/indexeddb/server/IDBBackingStore.h:

        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didDeleteIndex):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:

        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::deleteIndex):
        * Modules/indexeddb/server/IDBServer.h:

        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::indexDeleted):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:

        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::deleteIndex):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:

        * Modules/indexeddb/server/MemoryIndex.cpp:
        (WebCore::IDBServer::MemoryIndex::clearIndexValueStore):
        * Modules/indexeddb/server/MemoryIndex.h:

        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::maybeRestoreDeletedIndex):
        (WebCore::IDBServer::MemoryObjectStore::takeIndexByName):
        (WebCore::IDBServer::MemoryObjectStore::deleteIndex):
        * Modules/indexeddb/server/MemoryObjectStore.h:

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::deleteIndex):
        (WebCore::IDBServer::UniqueIDBDatabase::performDeleteIndex):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformDeleteIndex):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::didDeleteIndex):
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::deleteIndex):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:

        * Modules/indexeddb/shared/IDBDatabaseInfo.cpp:
        (WebCore::IDBDatabaseInfo::loggingString):
        * Modules/indexeddb/shared/IDBDatabaseInfo.h:

        * Modules/indexeddb/shared/IDBIndexInfo.cpp:
        (WebCore::IDBIndexInfo::loggingString):
        * Modules/indexeddb/shared/IDBIndexInfo.h:

        * Modules/indexeddb/shared/IDBObjectStoreInfo.cpp:
        (WebCore::IDBObjectStoreInfo::hasIndex):
        (WebCore::IDBObjectStoreInfo::deleteIndex):
        (WebCore::IDBObjectStoreInfo::loggingString):
        * Modules/indexeddb/shared/IDBObjectStoreInfo.h:

        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::deleteIndexSuccess):
        * Modules/indexeddb/shared/IDBResultData.h:

        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didDeleteIndex):
        (WebCore::InProcessIDBServer::createIndex):
        (WebCore::InProcessIDBServer::deleteIndex):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

2015-11-19  Brian Burg  <bburg@apple.com>

        REGRESSION(r8780): Backwards delete by word incorrectly appends deleted text to kill ring, should be prepend
        https://bugs.webkit.org/show_bug.cgi?id=151300

        Reviewed by Darin Adler.

        Over 11 years ago, someone was in a big hurry to fix a bunch
        of emacs keybindings bugs, and accidentally regressed the kill ring
        behavior for backwards-delete-word. It should prepend to the beginning.

        This patch fixes the regression and cleans up the kill ring-related
        code in Editor and commands. It also adds some tests to cover the
        regressed code a bit better.

        Tests: editing/pasteboard/emacs-killring-alternating-append-prepend.html
               editing/pasteboard/emacs-killring-backward-delete-prepend.html

        * editing/Editor.cpp:

            Use more explicit names for insertion mode parameters and member variables.

        (WebCore::Editor::deleteWithDirection):
        (WebCore::Editor::performDelete):
        (WebCore::Editor::addRangeToKillRing):
        (WebCore::Editor::addTextToKillRing):

            Only one call site for now, but another will be added in a dependent fix.

        (WebCore::Editor::addToKillRing): Deleted.
        * editing/Editor.h:
        * editing/TypingCommand.cpp:
        (WebCore::TypingCommand::TypingCommand):
        (WebCore::TypingCommand::deleteKeyPressed):
        (WebCore::TypingCommand::forwardDeleteKeyPressed):
        (WebCore::TypingCommand::doApply):
        * editing/TypingCommand.h:
        * platform/mac/KillRingMac.mm:
        (WebCore::KillRing::append):
        (WebCore::KillRing::prepend):

            It turns out that the native API implicitly clears the kill sequence when
            alternating between prepend and append operations. Its behavior does not match
            what Sublime Text or Emacs do in this case. Clear the previous operation flag
            to prevent this behavior from happening.

2015-11-19  Myles C. Maxfield  <mmaxfield@apple.com>

        Tatechuyoko in ruby sits too high
        https://bugs.webkit.org/show_bug.cgi?id=151309
        <rdar://problem/23536621>

        Reviewed by Darin Adler.

        When combining text, we ask what the text's width is in order to determine if it fits in the
        column. However, when we do that, we were not setting the font's orientation to horizontal.
        This means that, for CJK text, the "width" which was returned was actually the height of the
        glyph, and the GlyphOverflow data was similarly garbled.

        We actually already were creating a corrected FontDescription, and using it in two places.
        However, we weren't using it in the last place, which was causing this bug.

        Test: fast/text/text-combine-placement.html

        * platform/graphics/FontCascade.cpp:
        (WebCore::FontCascade::width):
        * rendering/RenderCombineText.cpp:
        (WebCore::RenderCombineText::combineText):

2015-11-19  Hunseop Jeong  <hs85.jeong@samsung.com>

        [EFL] http/tests/navigation/useragent test failed after r192459.
        https://bugs.webkit.org/show_bug.cgi?id=151340

        Reviewed by Gyuyoung Kim.

        We need the convert process the predifined value to string. 

        * platform/efl/UserAgentEfl.cpp:
        (WebCore::versionForUAString):

2015-11-19  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r192622.
        https://bugs.webkit.org/show_bug.cgi?id=151446

        This test is failing on multiple mac testers (Requested by
        ryanhaddad on #webkit).

        Reverted changeset:

        "Add a test for media control dropoff"
        https://bugs.webkit.org/show_bug.cgi?id=151287
        http://trac.webkit.org/changeset/192622

2015-11-19  Csaba Osztrogonác  <ossy@webkit.org>

        [EFL] Fix -Winconsistent-missing-override clang warnings
        https://bugs.webkit.org/show_bug.cgi?id=151443

        Reviewed by Darin Adler.

        * loader/EmptyClients.h:
        (WebCore::EmptyChromeClient::delegatedScrollRequested):
        (WebCore::EmptyChromeClient::scheduleAnimation):

2015-11-19  Jon Lee  <jonlee@apple.com>

        Add a test for media control dropoff
        https://bugs.webkit.org/show_bug.cgi?id=151287
        rdar://problem/23544666

        Reviewed by Dean Jackson.

        Test: media/controls/inline-elements-dropoff-order.html

        * Modules/mediacontrols/mediaControlsApple.css:
        (audio::-webkit-media-controls-timeline-container.dropped): Override the
        display:none since we want the container to remain visible but acting
        as a flexible width space to push the other elements to the ends of the
        inline flexbox. We will want to refactor the CSS rules so that all of the
        components in the timeline are keyed off of the container's dropped class
        rather than having each individual component have that class attached.
        (audio::-webkit-media-controls-panel.hidden): Deleted. Consolidate a
        couple rules.
        * Modules/mediacontrols/mediaControlsApple.js:
        (Controller.prototype.updateLayoutForDisplayedWidth): Also attach the
        "dropped" class on the timeline box. Add the captions button for reporting
        media control state.
        * testing/Internals.cpp:
        (WebCore::Internals::setMockMediaPlaybackTargetPickerState): Extend this to
        also take "DeviceNotAvailable" to update the mock device's availability.

        * testing/Internals.cpp: Update to use a reference to Page.
        (WebCore::Internals::resetToConsistentState): Reset mock enabled setting for
        each test.
        * testing/Internals.h:
        * testing/js/WebCoreTestSupport.cpp:
        (WebCoreTestSupport::resetInternalsObject): Update to use a reference to Page.

2015-11-19  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Implement IsReadableStreamDisturbed according to spec
        https://bugs.webkit.org/show_bug.cgi?id=151356

        Reviewed by Darin Adler.

        Implemente IsReadableStreamDisturbed according to the spec. This is an internal function to be used by other
        internal implementations.

        The function is exported as internals to be tested.

        Test: streams/reference-implementation/abstract-ops.html.

        * Modules/streams/ReadableStream.js:
        (initializeReadableStream):
        * Modules/streams/ReadableStreamInternals.js:
        (cancelReadableStream):
        (readFromReadableStreamReader):
        (isReadableStreamDisturbed):
        * bindings/js/WebCoreBuiltinNames.h:
        * testing/Internals.cpp:
        (WebCore::Internals::isReadableStreamDisturbed):
        * testing/Internals.h:
        * testing/Internals.idl:

2015-11-19  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        XHR should not combine empty content-type value with default one
        https://bugs.webkit.org/show_bug.cgi?id=147784

        Reviewed by Darin Adler.

        Previously, XHR was testing whether a "Content-Type" was set using setRequestHeader by checking whether a "Content-Type" header value was empty.
        This now tests whether "Content-Type" request header is set using either HTTPHeaderMap::contains or checking whether a "Content-Type" header value is null.

        Test: http/tests/xmlhttprequest/post-empty-content-type.html

        * xml/XMLHttpRequest.cpp:
        (WebCore::XMLHttpRequest::send):

2015-11-19  Brady Eidson  <beidson@apple.com>

        Modern IDB: Populate indexes created in object stores that already have records.
        https://bugs.webkit.org/show_bug.cgi?id=151421

        Reviewed by Alex Christensen.

        Test: storage/indexeddb/modern/index-4.html
              storage/indexeddb/modern/index-5.html

        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::createIndex):
        (WebCore::IDBServer::MemoryObjectStore::populateIndexWithExistingRecords):
        * Modules/indexeddb/server/MemoryObjectStore.h:

2015-11-18  Brady Eidson  <beidson@apple.com>

        Modern IDB:Make in-memory Index cursors work.
        https://bugs.webkit.org/show_bug.cgi?id=151278

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/index-cursor-1.html
               storage/indexeddb/modern/index-cursor-2.html
               storage/indexeddb/modern/index-cursor-3.html

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:

        * Modules/indexeddb/client/IDBIndexImpl.cpp:
        (WebCore::IDBClient::IDBIndex::openCursor):
        (WebCore::IDBClient::IDBIndex::openKeyCursor):
        
        * Modules/indexeddb/server/IndexValueEntry.cpp:
        (WebCore::IDBServer::IndexValueEntry::removeKey):
        (WebCore::IDBServer::IndexValueEntry::Iterator::Iterator):
        (WebCore::IDBServer::IndexValueEntry::Iterator::key):
        (WebCore::IDBServer::IndexValueEntry::Iterator::isValid):
        (WebCore::IDBServer::IndexValueEntry::Iterator::invalidate):
        (WebCore::IDBServer::IndexValueEntry::Iterator::operator++):
        (WebCore::IDBServer::IndexValueEntry::begin):
        (WebCore::IDBServer::IndexValueEntry::reverseBegin):
        (WebCore::IDBServer::IndexValueEntry::find):
        (WebCore::IDBServer::IndexValueEntry::reverseFind):
        * Modules/indexeddb/server/IndexValueEntry.h:
        (WebCore::IDBServer::IndexValueEntry::Iterator::Iterator):
        (WebCore::IDBServer::IndexValueEntry::unique):
        
        * Modules/indexeddb/server/IndexValueStore.cpp:
        (WebCore::IDBServer::IndexValueStore::removeEntriesWithValueKey):
        (WebCore::IDBServer::IndexValueStore::lowestKeyWithRecordInRange):
        (WebCore::IDBServer::IndexValueStore::lowestIteratorInRange):
        (WebCore::IDBServer::IndexValueStore::highestReverseIteratorInRange):
        (WebCore::IDBServer::IndexValueStore::find):
        (WebCore::IDBServer::IndexValueStore::reverseFind):
        (WebCore::IDBServer::IndexValueStore::Iterator::Iterator):
        (WebCore::IDBServer::IndexValueStore::Iterator::nextIndexEntry):
        (WebCore::IDBServer::IndexValueStore::Iterator::operator++):
        (WebCore::IDBServer::IndexValueStore::Iterator::invalidate):
        (WebCore::IDBServer::IndexValueStore::Iterator::isValid):
        (WebCore::IDBServer::IndexValueStore::Iterator::key):
        (WebCore::IDBServer::IndexValueStore::Iterator::primaryKey):
        * Modules/indexeddb/server/IndexValueStore.h:
        (WebCore::IDBServer::IndexValueStore::Iterator::Iterator):
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::openCursor):
        
        * Modules/indexeddb/server/MemoryIndex.cpp:
        (WebCore::IDBServer::MemoryIndex::cursorDidBecomeClean):
        (WebCore::IDBServer::MemoryIndex::cursorDidBecomeDirty):
        (WebCore::IDBServer::MemoryIndex::objectStoreCleared):
        (WebCore::IDBServer::MemoryIndex::notifyCursorsOfValueChange):
        (WebCore::IDBServer::MemoryIndex::notifyCursorsOfAllRecordsChanged):
        (WebCore::IDBServer::MemoryIndex::putIndexKey):
        (WebCore::IDBServer::MemoryIndex::removeRecord):
        (WebCore::IDBServer::MemoryIndex::removeEntriesWithValueKey):
        (WebCore::IDBServer::MemoryIndex::maybeOpenCursor):
        * Modules/indexeddb/server/MemoryIndex.h:
        (WebCore::IDBServer::MemoryIndex::valueStore):
        (WebCore::IDBServer::MemoryIndex::objectStore):
        
        * Modules/indexeddb/server/MemoryIndexCursor.cpp: Added.
        (WebCore::IDBServer::MemoryIndexCursor::MemoryIndexCursor):
        (WebCore::IDBServer::MemoryIndexCursor::~MemoryIndexCursor):
        (WebCore::IDBServer::MemoryIndexCursor::currentData):
        (WebCore::IDBServer::MemoryIndexCursor::iterate):
        (WebCore::IDBServer::MemoryIndexCursor::indexRecordsAllChanged):
        (WebCore::IDBServer::MemoryIndexCursor::indexValueChanged):
        * Modules/indexeddb/server/MemoryIndexCursor.h:
        
        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::indexForIdentifier):
        (WebCore::IDBServer::MemoryObjectStore::valueForKey):
        * Modules/indexeddb/server/MemoryObjectStore.h:
        
        * Modules/indexeddb/shared/IDBCursorInfo.cpp:
        (WebCore::IDBCursorInfo::objectStoreCursor):
        (WebCore::IDBCursorInfo::indexCursor):
        (WebCore::IDBCursorInfo::IDBCursorInfo):
        (WebCore::IDBCursorInfo::isDirectionNoDuplicate):
        (WebCore::IDBCursorInfo::isolatedCopy):
        * Modules/indexeddb/shared/IDBCursorInfo.h:
        (WebCore::IDBCursorInfo::objectStoreIdentifier):

2015-11-18  Antti Koivisto  <antti@apple.com>

        Assertion failure in RenderTreePosition::computeNextSibling
        https://bugs.webkit.org/show_bug.cgi?id=151337
        rdar://problem/23250075

        Reviewed by Zalan Bujtas.

        Test: fast/html/details-mathml-crash.html

        * html/ads: Added.
        * style/StyleResolveTree.cpp:
        (WebCore::Style::resolveChildAtShadowBoundary):

            Factor common code for resolving child here from resolveShadowTree.

        (WebCore::Style::resolveShadowTree):

            We don't need StyleResolverParentPusher because shadow tree uses different style resolver anyway.

        (WebCore::Style::resolveSlotAssignees):

            This needs to call renderTreePosition.invalidateNextSibling() if there is a renderer already.
            Achieve this by calling the new common function resolveChildAtShadowBoundary.

2015-11-18  Jer Noble  <jer.noble@apple.com>

        WebGL slow video to texture
        https://bugs.webkit.org/show_bug.cgi?id=129626

        Reviewed by Dean Jackson.

        Support a direct GPU-to-GPU copy of video textures. Add a new AVPlayerItemVideoOutput which,
        when lazily-created, will emit CVPixelBuffers which are guaranteed to be compatible with
        OpenGL framebuffers. Then, use a CVOpenGLTextureCache object to convert those CVPixelBuffers
        to OpenGL textures. Once the video frame is in an OpenGL texture, use an OpenGL framebuffer
        to copy the underlying video texture memory to the destination texture.

        The copy step uses glTexImage2D, which requires format and type parameters, so change the
        signature of copyVideoTextureToPlatformTexture() to pass those parameters in.

        * html/HTMLVideoElement.cpp:
        (WebCore::HTMLVideoElement::copyVideoTextureToPlatformTexture): Changed signature.
        * html/HTMLVideoElement.h:
        * html/canvas/WebGLRenderingContextBase.cpp:
        (WebCore::WebGLRenderingContextBase::texImage2D): Changed signature.
        * platform/graphics/MediaPlayer.cpp:
        (WebCore::MediaPlayer::copyVideoTextureToPlatformTexture): Changed signature.
        * platform/graphics/MediaPlayer.h:
        * platform/graphics/MediaPlayerPrivate.h:
        (WebCore::MediaPlayerPrivateInterface::copyVideoTextureToPlatformTexture): Changed signature.
        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
        (WebCore::MediaPlayerPrivateAVFoundationObjC::createOpenGLVideoOutput): Create an OpenGL-compatible
            AVPlayerItemVideoOutput.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::destroyOpenGLVideoOutput): Destroy same.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::updateLastOpenGLImage): Cache the current frame, if available.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::copyVideoTextureToPlatformTexture): Convert the
            current frame to a texture, and use that texture to render into the destination texture.

2015-11-18  Jiewen Tan  <jiewen_tan@apple.com>

        [WK1] Crash loading Blink layout test fast/dom/Window/property-access-on-cached-window-after-frame-removed.html
        https://bugs.webkit.org/show_bug.cgi?id=150198
        <rdar://problem/23136026>

        Reviewed by Brent Fulgham.

        Test: fast/dom/Window/property-access-on-cached-window-after-frame-removed.html

        Properties of a contentWindow could be accessed even if the frame who owns the window is
        detached. Therefore, check whether the document loader is still alive before using it.

        * page/PerformanceTiming.cpp:
        (WebCore::PerformanceTiming::monotonicTimeToIntegerMilliseconds):

2015-11-18  Eric Carlson  <eric.carlson@apple.com>

        MediaStream: Implement MediaDevices.getSupportedConstraints
        https://bugs.webkit.org/show_bug.cgi?id=151394

        Reviewed by Brent Fulgham.

        Test: fast/mediastream/MediaDevices-getSupportedConstraints.html

        * CMakeLists.txt: Add MediaTrackSupportedConstraints and JSMediaTrackSupportedConstraintsCustom.

        * DerivedSources.make: Ditto.

        * Modules/mediastream/MediaDevices.cpp:
        (WebCore::MediaDevices::getSupportedConstraints): New.
        * Modules/mediastream/MediaDevices.h:
        * Modules/mediastream/MediaDevices.idl:

        * Modules/mediastream/MediaTrackSupportedConstraints.h: Added. Wrapper around a 
          RealtimeMediaSourceSupportedConstraints.
        (WebCore::MediaTrackSupportedConstraints::create):
        (WebCore::MediaTrackSupportedConstraints::supportsWidth):
        (WebCore::MediaTrackSupportedConstraints::supportsHeight):
        (WebCore::MediaTrackSupportedConstraints::supportsAspectRatio):
        (WebCore::MediaTrackSupportedConstraints::supportsFrameRate):
        (WebCore::MediaTrackSupportedConstraints::supportsFacingMode):
        (WebCore::MediaTrackSupportedConstraints::supportsVolume):
        (WebCore::MediaTrackSupportedConstraints::supportsSampleRate):
        (WebCore::MediaTrackSupportedConstraints::supportsSampleSize):
        (WebCore::MediaTrackSupportedConstraints::supportsEchoCancellation):
        (WebCore::MediaTrackSupportedConstraints::supportsDeviceId):
        (WebCore::MediaTrackSupportedConstraints::supportsGroupId):
        (WebCore::MediaTrackSupportedConstraints::MediaTrackSupportedConstraints):
        * Modules/mediastream/MediaTrackSupportedConstraints.idl: Added.

        * WebCore.xcodeproj/project.pbxproj: Add JSMediaTrackSupportedConstraintsCustom.cpp, 
          RealtimeMediaSourceSupportedConstraints.h, and MediaTrackSupportedConstraints.*.

        A MediaTrackSupportedConstraints only contains the properties supported by the currently
        available capture devices, so implement getOwnPropertySlot and getOwnPropertyNames so
        we don't have to declare any attributes in the idl file.
        * bindings/js/JSMediaTrackSupportedConstraintsCustom.cpp: Added.
        (WebCore::JSMediaTrackSupportedConstraints::getOwnPropertySlotDelegate):
        (WebCore::JSMediaTrackSupportedConstraints::getOwnPropertyNames):

        * platform/mediastream/RealtimeMediaSourceCenter.h:
        * platform/mediastream/RealtimeMediaSourceSupportedConstraints.h: Added.
        (WebCore::RealtimeMediaSourceSupportedConstraints::RealtimeMediaSourceSupportedConstraints):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsWidth):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsWidth):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsHeight):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsHeight):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsAspectRatio):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsAspectRatio):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsFrameRate):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsFrameRate):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsFacingMode):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsFacingMode):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsVolume):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsVolume):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsSampleRate):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsSampleRate):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsSampleSize):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsSampleSize):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsEchoCancellation):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsEchoCancellation):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsDeviceId):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsDeviceId):
        (WebCore::RealtimeMediaSourceSupportedConstraints::supportsGroupId):
        (WebCore::RealtimeMediaSourceSupportedConstraints::setSupportsGroupId):

        * platform/mediastream/mac/RealtimeMediaSourceCenterMac.cpp:
        (WebCore::RealtimeMediaSourceCenterMac::RealtimeMediaSourceCenterMac): Initialize supported constraints.
        * platform/mediastream/mac/RealtimeMediaSourceCenterMac.h:

        * platform/mock/MockRealtimeMediaSource.cpp: Delete some dead code.

        * platform/mock/MockRealtimeMediaSourceCenter.cpp:
        (WebCore::MockRealtimeMediaSourceCenter::MockRealtimeMediaSourceCenter): Initialize supported constraints.
        * platform/mock/MockRealtimeMediaSourceCenter.h:

2015-11-18  Alex Christensen  <achristensen@webkit.org>

        Progress towards implementing Downloads with NETWORK_SESSION
        https://bugs.webkit.org/show_bug.cgi?id=151414

        Reviewed begrudgingly by Brady Eidson.

        There is no change in behavior except that SessionIDs are sent across IPC and passed as parameters,
        and they are not used yet.

        * loader/DocumentLoader.cpp:
        (WebCore::DocumentLoader::continueAfterContentPolicy):
        Removed an unused default. Compiler warnings will let us know if we add an unhandled case to this switch.
        * loader/EmptyClients.h:
        * loader/FrameLoaderClient.h:
        Pass SessionIDs around.

2015-11-18  Andreas Kling  <akling@apple.com>

        ResourceUsageOverlay should have better accounting for reclaimable memory.
        <https://webkit.org/b/151407>

        Reviewed by Anders Carlsson.

        Add code to inspect the purgeable state of VM regions when traversing the
        web process VM map, and track reclaimable regions of memory separately.

        Memory categories that have some amount of reclaimable memory are now
        displayed with the reclaimable amount in brackets, e.g "123.45 MB [56.78MB]"

        * page/ResourceUsageOverlay.h:
        * page/cocoa/ResourceUsageOverlayCocoa.mm:
        (WebCore::ResourceUsageOverlay::platformDraw):
        (WebCore::TagInfo::TagInfo):
        (WebCore::pagesPerVMTag):
        (WebCore::runSamplerThread):
        (WebCore::dirtyPagesPerVMTag): Deleted.

2015-11-18  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Client Blocked Resource Requests causes Crash under InspectorPageAgent::cachedResource
        https://bugs.webkit.org/show_bug.cgi?id=151398

        Reviewed by Brian Burg.

        Test: inspector/network/client-blocked-load.html

        * inspector/InspectorPageAgent.cpp:
        (WebCore::InspectorPageAgent::cachedResource):
        Gracefully handle null request.

        * loader/cache/CachedResourceLoader.cpp:
        (WebCore::CachedResourceLoader::cachedResource):
        ASSERT if someone tried to pass a null URL.

2015-11-18  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Timeline Recording across page navigations behaves poorly
        https://bugs.webkit.org/show_bug.cgi?id=151112

        Reviewed by Timothy Hatcher.

        * inspector/InspectorPageAgent.cpp:
        (WebCore::InspectorPageAgent::frameStartedLoading): Deleted.
        Don't reset the execution stopwatch on page navigation.
        If a timeline is actively being recorded on the frontend
        then all new timestamps suddenly downshifted towards zero
        introduces bad data.

2015-11-18  Daniel Bates  <dabates@apple.com>

        [iOS] ASSERTION FAILED: temporaryFilePath.last() == '/' in WebCore::openTemporaryFile()
        https://bugs.webkit.org/show_bug.cgi?id=151392
        <rdar://problem/23595341>

        Reviewed by Alexey Proskuryakov.

        Workaround <rdar://problem/23579077> where confstr(_CS_DARWIN_USER_TEMP_DIR, ..., ...) retrieves
        the path to the user temporary directory without a trailing slash in the iOS simulator.

        * platform/mac/FileSystemMac.mm:
        (WebCore::openTemporaryFile): Add a path separator (/) between the directory path and filename.

2015-11-18  Chris Dumez  <cdumez@apple.com>

        Null dereference in Performance::Performance(WebCore::Frame*)
        https://bugs.webkit.org/show_bug.cgi?id=151390

        Reviewed by Brady Eidson.

        Based on the stack trace, it appears the DocumentLoader can be null
        when constructing the Performance object. This patch thus adds a null
        check before trying to dereference it.

        No new tests, was not able to reproduce.

        * page/DOMWindow.cpp:
        (WebCore::DOMWindow::navigator):
        (WebCore::DOMWindow::performance):
        * page/Performance.cpp:
        (WebCore::Performance::Performance):
        (WebCore::Performance::scriptExecutionContext):
        * page/Performance.h:

2015-11-18  Per Arne Vollan  <peavo@outlook.com>

        [WinCairo][MediaFoundation] The main thread can sometimes be blocked forever when ending a media session.
        https://bugs.webkit.org/show_bug.cgi?id=151387

        Reviewed by Alex Christensen.

        This happens because the main thread is waiting for the sample scheduler thread to finish,
        but sometimes it never does. This can be resolved by emptying the scheduler's sample queue
        before requesting the scheduler thread to finish. This will make sure the scheduler thread
        returns to its main loop quickly, and can handle the termination request.

        * platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::stopScheduler):

2015-11-18  Adam Bergkvist  <adam.bergkvist@ericsson.com>

        WebRTC: Initial testing of updated RTCPeerConnection API
        https://bugs.webkit.org/show_bug.cgi?id=151304

        Reviewed by Eric Carlson.

        Add an empty implementation of MediaEndpointPeerConnection which
        realizes the PeerConnectionBackend interface. This makes it possible
        to construct an RTCPeerConnection and do initial testing.

        Tests: fast/mediastream/RTCPeerConnection-overloaded-operations-params.html
               fast/mediastream/RTCPeerConnection-overloaded-operations.html

        Also unskip three existing RTCPeerConnection tests on GTK.

        * CMakeLists.txt:
        * Modules/mediastream/MediaEndpointPeerConnection.cpp: Added.
        (WebCore::createMediaEndpointPeerConnection):
        (WebCore::MediaEndpointPeerConnection::MediaEndpointPeerConnection):
        (WebCore::MediaEndpointPeerConnection::createOffer):
        (WebCore::MediaEndpointPeerConnection::createAnswer):
        (WebCore::MediaEndpointPeerConnection::setLocalDescription):
        (WebCore::MediaEndpointPeerConnection::localDescription):
        (WebCore::MediaEndpointPeerConnection::currentLocalDescription):
        (WebCore::MediaEndpointPeerConnection::pendingLocalDescription):
        (WebCore::MediaEndpointPeerConnection::setRemoteDescription):
        (WebCore::MediaEndpointPeerConnection::remoteDescription):
        (WebCore::MediaEndpointPeerConnection::currentRemoteDescription):
        (WebCore::MediaEndpointPeerConnection::pendingRemoteDescription):
        (WebCore::MediaEndpointPeerConnection::setConfiguration):
        (WebCore::MediaEndpointPeerConnection::addIceCandidate):
        (WebCore::MediaEndpointPeerConnection::getStats):
        (WebCore::MediaEndpointPeerConnection::stop):
        (WebCore::MediaEndpointPeerConnection::markAsNeedingNegotiation):
        * Modules/mediastream/MediaEndpointPeerConnection.h: Added.
        * WebCore.xcodeproj/project.pbxproj:

2015-11-18  Alejandro G. Castro  <alex@igalia.com>

        [Cairo] SolidStroke broken in drawLine after r191658
        https://bugs.webkit.org/show_bug.cgi?id=151385

        Reviewed by Carlos Garcia Campos.

        Fix the drawLine function after r191658, we have to make sure the
        color is set when line is SolidStroke.

        * platform/graphics/cairo/GraphicsContextCairo.cpp:
        (WebCore::GraphicsContext::drawLine):

2015-11-18  Javier Fernandez  <jfernandez@igalia.com>

        [CSS Grid Layout] inline margins not honored when not using stretch in row-axis alignment
        https://bugs.webkit.org/show_bug.cgi?id=151323

        Reviewed by Sergio Villar Senin.

        There are some situations where we avoid to compute the inline-axis
        margins when computing the logical width of a box. One of those situations
        is when we have set an override width; this only affects for now to flex
        and grid items. We also follow this approach when setting the logical
        width based on the restrictions of 'auto' value in the 'min-width'
        property.

        This behavior is not correct, since there is no reason to avoid
        computing this margins, in the general case. I think this logic was
        designed as an optimization for flexbox, which was already computing
        the margins by its own, but it's not applicable in the general case, so
        grid needs these margins to be computed properly.

        For the shrink-to-fit behavior we can add some grid related logic to the
        already defined RenderBox function "sizesLogicalWidthToFitContent",
        so we avoid the override width.

        Tests: fast/css-grid-layout/grid-item-auto-sized-align-justify-margin-border-padding.html
               fast/css-grid-layout/min-width-height-auto-and-margins.html

        * rendering/RenderBox.cpp:
        (WebCore::RenderBox::computeLogicalWidthInRegion):
        (WebCore::RenderBox::sizesLogicalWidthToFitContent):
        * rendering/RenderGrid.cpp:
        (WebCore::defaultAlignmentChangedFromStretchInRowAxis):
        (WebCore::selfAlignmentChangedFromStretchInRowAxis):
        (WebCore::RenderGrid::styleDidChange):
        (WebCore::RenderGrid::applyStretchAlignmentToChildIfNeeded):
        (WebCore::selfAlignmentChangedFromStretchInColumnAxis): Deleted.
        (WebCore::RenderGrid::computeMarginLogicalHeightForChild): Deleted.
        (WebCore::RenderGrid::availableAlignmentSpaceForChildBeforeStretching): Deleted.

2015-11-18  Aaron Chu  <arona.chu@gmail.com>

        AX: Shadow DOM video player controls menus need aria-owns on the trigger buttons
        https://bugs.webkit.org/show_bug.cgi?id=127065

        Reviewed by Darin Adler.

        Test: media/accessibility-closed-captions-has-aria-owns.html

        * Modules/mediacontrols/mediaControlsApple.js:
        (Controller.prototype.createControls):
        (Controller.prototype.buildCaptionMenu):
        * Modules/mediacontrols/mediaControlsBase.js:
        (Controller.prototype.createControls):
        (Controller.prototype.buildCaptionMenu):

2015-11-17  Carlos Garcia Campos  <cgarcia@igalia.com>

        Null dereference loading Blink layout test editing/execCommand/indent-button-crash.html
        https://bugs.webkit.org/show_bug.cgi?id=151187

        Reviewed by Darin Adler.

        This is a merge of Blink r174671:
        https://codereview.chromium.org/291143002

        Fixes imported/blink/editing/execCommand/indent-button-crash.html.

        * editing/ApplyBlockElementCommand.cpp:
        (WebCore::ApplyBlockElementCommand::doApply):

2015-11-17  Carlos Garcia Campos  <cgarcia@igalia.com>

        REGRESSION(r192459): [GTK] User agent string is broken after r192459
        https://bugs.webkit.org/show_bug.cgi?id=151347

        Reviewed by Žan Doberšek.

        Remove the incorrect macro and simply use the given values
        USER_AGENT_GTK_MAJOR_VERSION and USER_AGENT_GTK_MINOR_VERSION that
        are now strings.

        * platform/gtk/UserAgentGtk.cpp:
        (WebCore::versionForUAString):
        (WebCore::buildUserAgentString):

2015-11-17  Zalan Bujtas  <zalan@apple.com>

        Simple line layout: Add letter-spacing support.
        https://bugs.webkit.org/show_bug.cgi?id=151362

        Reviewed by Antti Koivisto.

        This enables us to use simple line layout on letter-spacing content.
        (fixme: webkit.org/b/151368 -> Repaint rect is not computed correctly when negative letter-spacing applied)

        Test: fast/text/simple-line-letterspacing.html

        * rendering/SimpleLineLayout.cpp:
        (WebCore::SimpleLineLayout::canUseForStyle):
        * rendering/SimpleLineLayoutFunctions.cpp:
        (WebCore::SimpleLineLayout::paintFlow): RenderLineBoxList tests vertical intersection only. 
        * rendering/SimpleLineLayoutTextFragmentIterator.cpp:
        (WebCore::SimpleLineLayout::TextFragmentIterator::runWidth):

2015-11-17  Per Arne Vollan  <peavo@outlook.com>

        [WinCairo][MediaFoundation] Current playback time is not shown.
        https://bugs.webkit.org/show_bug.cgi?id=151357

        Reviewed by Alex Christensen.

        We need to implement the currentTime() method.

        * platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:
        (WebCore::MediaPlayerPrivateMediaFoundation::durationDouble):
        (WebCore::MediaPlayerPrivateMediaFoundation::currentTime):
        (WebCore::MediaPlayerPrivateMediaFoundation::paused):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::paintCurrentFrame):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::currentTime):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::isActive):
        * platform/graphics/win/MediaPlayerPrivateMediaFoundation.h:

2015-11-17  Zalan Bujtas  <zalan@apple.com>

        Split SimpleLineLayout::canUseFor into canUseForStyle and canUseForFontAndText.
        https://bugs.webkit.org/show_bug.cgi?id=151338

        Reviewed by Myles C. Maxfield.

        No change in functionality.

        * rendering/SimpleLineLayout.cpp:
        (WebCore::SimpleLineLayout::canUseForFontAndText):
        (WebCore::SimpleLineLayout::canUseForStyle):
        (WebCore::SimpleLineLayout::canUseFor):

2015-11-17  Brady Eidson  <beidson@apple.com>

        Modern IDB: Support IDBObjectStore.indexNames.
        https://bugs.webkit.org/show_bug.cgi?id=151341

        Reviewed by Alex Christensen.

        No new tests (Covered by existing storage/indexeddb/modern/objectstore-attributes.html).

        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::indexNames):
        * Modules/indexeddb/shared/IDBObjectStoreInfo.cpp:
        (WebCore::IDBObjectStoreInfo::indexNames):
        * Modules/indexeddb/shared/IDBObjectStoreInfo.h:

2015-11-17  Sergio Villar Senin  <svillar@igalia.com>

        ASSERTION FAILED: contentSize >= 0 in WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax
        https://bugs.webkit.org/show_bug.cgi?id=151025

        Reviewed by Darin Adler.

        Negative margins could make RenderFlexibleBox compute negative
        intrinsic sizes. Clamp intrinsic sizes to 0.

        Test: css3/flexbox/negative-margins-assert.html

        * rendering/RenderFlexibleBox.cpp:
        (WebCore::RenderFlexibleBox::computeIntrinsicLogicalWidths):

2015-11-17  Sergio Villar Senin  <svillar@igalia.com>

        [css-grid] Fix alignment with gutters and negative free spaces
        https://bugs.webkit.org/show_bug.cgi?id=151307

        Reviewed by Zalan Bujtas.

        This is a regression caused by r192154. The problem was that
        the free space was not properly computed when the grid
        container was narrower than the track sizes + gutters size for
        a given axis. The culprit was an unneeded clamp to 0 which was
        polluting the freeSpace computation as the track sizing
        algorithm works perfectly OK with negative freeSpace values.

        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::computeTrackSizesForDirection):

2015-11-17  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GStreamer] Use RunLoop instead of GMainLoop in AudioFileReaderGStreamer
        https://bugs.webkit.org/show_bug.cgi?id=151256

        Reviewed by Žan Doberšek.

        Use RunLoop instead of the platform specific code. The AudioBus
        can be created from any thread, so we create a helper thread to
        ensure we don't use the main RunLoop.

        This patch also includes some code cleanups:
          - Uses smart pointers when possible.
          - Fixes uninitialized members in constructors.
          - Makes private members private.
          - Uses lambdas instead of static non-members functions.
          - nullptr instead of 0 in some places.

        * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
        (WebCore::AudioFileReader::createWeakPtr):
        (WebCore::AudioFileReader::deinterleavePadAddedCallback):
        (WebCore::AudioFileReader::deinterleaveReadyCallback):
        (WebCore::AudioFileReader::decodebinPadAddedCallback):
        (WebCore::AudioFileReader::AudioFileReader):
        (WebCore::AudioFileReader::~AudioFileReader):
        (WebCore::AudioFileReader::handleSample):
        (WebCore::AudioFileReader::handleMessage):
        (WebCore::AudioFileReader::handleNewDeinterleavePad):
        (WebCore::AudioFileReader::deinterleavePadsConfigured):
        (WebCore::AudioFileReader::plugDeinterleave):
        (WebCore::AudioFileReader::decodeAudioForBusCreation):
        (WebCore::AudioFileReader::createBus):
        (WebCore::createBusFromAudioFile):
        (WebCore::createBusFromInMemoryAudioFile):
        (WebCore::onAppsinkPullRequiredCallback): Deleted.
        (WebCore::messageCallback): Deleted.
        (WebCore::onGStreamerDeinterleavePadAddedCallback): Deleted.
        (WebCore::onGStreamerDeinterleaveReadyCallback): Deleted.
        (WebCore::onGStreamerDecodebinPadAddedCallback): Deleted.
        * platform/graphics/gstreamer/GRefPtrGStreamer.cpp:
        (WTF::adoptGRef):
        (WTF::refGPtr<GstBufferList>):
        (WTF::derefGPtr<GstBufferList>):
        * platform/graphics/gstreamer/GRefPtrGStreamer.h:

2015-11-16  Eric Carlson  <eric.carlson@apple.com>

        [MediaStream] VideoTrack should respond to MediaStreamTrack state changes
        https://bugs.webkit.org/show_bug.cgi?id=151299

        Reviewed by Jer Noble.

        Test: fast/mediastream/MediaStream-video-element-track-stop.html

        * Modules/mediastream/MediaStreamTrack.cpp:
        (WebCore::MediaStreamTrack::ended): Check m_ended.
        (WebCore::MediaStreamTrack::stopProducingData): Set m_ended before telling private track to 
          stop so we won't fire an 'ended' event.
        (WebCore::MediaStreamTrack::trackEnded): Set m_ended, add comments from spec.
        * Modules/mediastream/MediaStreamTrack.h:

        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::mediaPlayerTimeChanged): Live streams have infinite duration,
          not indefinite.

        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:
        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::platformLayer): Return NULL when displayMode
          is None.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentDisplayMode): Calculate current 
          displayMode based on MediaStream state.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::updateDisplayMode): Renamed from 
          setPausedImageVisible, use m_displayMode. Don't start/stop clock, it makes more sense
          to do that in play and pause.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::play): Start clock. 
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::pause): Stop clock.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentReadyState): Call updateDisplayMode.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::activeStatusChanged): Ditto.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::updateIntrinsicSize):
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::createPreviewLayers): Always try to create
          both layers if necessary.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::renderingModeChanged): New, update displayMode
          and call back to the media element.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::characteristicsChanged):
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::updateTracks): Get rid of some unused locals.
          React to a change in the enabled video track.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::paintCurrentFrameInContext): Paint black when
          the active video track is disabled.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::setPausedImageVisible): Deleted.

        * platform/mediastream/MediaStreamPrivate.cpp:
        (WebCore::MediaStreamPrivate::updateActiveState): Split the logic of updating the active video
          track out into updateActiveVideoTrack.
        (WebCore::MediaStreamPrivate::hasVideo): Check for track.ended.
        (WebCore::MediaStreamPrivate::hasAudio): Ditto.
        (WebCore::MediaStreamPrivate::paintCurrentFrameInContext): Don't call the source directly.
        (WebCore::MediaStreamPrivate::updateActiveVideoTrack): New.
        (WebCore::MediaStreamPrivate::trackEnabledChanged): Call updateActiveVideoTrack.
        (WebCore::MediaStreamPrivate::trackEnded): new.
        * platform/mediastream/MediaStreamPrivate.h:

        * platform/mediastream/MediaStreamTrackPrivate.cpp:
        (WebCore::MediaStreamTrackPrivate::setEnabled): Call observers if enabled state changes.
        (WebCore::MediaStreamTrackPrivate::endTrack): Call observers.
        (WebCore::MediaStreamTrackPrivate::paintCurrentFrameInContext): New.
        (WebCore::MediaStreamTrackPrivate::preventSourceFromStopping): Add comments.
        * platform/mediastream/MediaStreamTrackPrivate.h:

        * platform/mock/MockRealtimeVideoSource.cpp:
        (WebCore::MockRealtimeVideoSource::paintCurrentFrameInContext): Remove a commented-out line.

2015-11-16  Pranjal Jumde  <pjumde@apple.com>

        Fixes the buffer-overflow when reading characters from textRun
        https://bugs.webkit.org/attachment.cgi?bugid=151055
        <rdar://problem/23251789>

        Reviewed by Brent Fulgham.

        * platform/graphics/FontCascade.cpp

2015-11-16  Brady Eidson  <beidson@apple.com>

        Modern IDB:Make in-memory ObjectStore cursors work.
        https://bugs.webkit.org/show_bug.cgi?id=151196

        Reviewed by Darin Adler.

        Tests: storage/indexeddb/modern/cursor-2.html
               storage/indexeddb/modern/cursor-3.html
               storage/indexeddb/modern/cursor-4.html
               storage/indexeddb/modern/cursor-5.html
               storage/indexeddb/modern/cursor-6.html
               storage/indexeddb/modern/cursor-7.html
               storage/indexeddb/modern/cursor-8.html
               storage/indexeddb/modern/objectstore-cursor-advance-failures.html
               storage/indexeddb/modern/objectstore-cursor-continue-failures.html

        Object store cursors directly hold on to a std::set<>::iterator to act as the cursor.
        
        The object store tells all of its cursors when it is cleared or records are deleted
        so the cursors can invalidate their iterators as needed.
        
        In case of such invalidation, the cursor hangs on to the current key value so it can 
        pick up where it left off in case it is iterated.

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:

        * Modules/indexeddb/IDBGetResult.h:
        (WebCore::IDBGetResult::isolatedCopy):
        
        * Modules/indexeddb/IDBKeyRangeData.cpp:
        (WebCore::IDBKeyRangeData::containsKey):
        (WebCore::IDBKeyRangeData::loggingString):
        * Modules/indexeddb/IDBKeyRangeData.h:
        
        * Modules/indexeddb/client/IDBAnyImpl.cpp:
        (WebCore::IDBClient::IDBAny::modernIDBCursor):
        
        * Modules/indexeddb/client/IDBCursorImpl.cpp:
        (WebCore::IDBClient::IDBCursor::update):
        (WebCore::IDBClient::IDBCursor::advance):
        (WebCore::IDBClient::IDBCursor::continueFunction):
        (WebCore::IDBClient::IDBCursor::setGetResult):
        * Modules/indexeddb/client/IDBCursorImpl.h:
        
        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::dispatchEvent):
        (WebCore::IDBClient::IDBRequest::didOpenOrIterateCursor):
        * Modules/indexeddb/client/IDBRequestImpl.h:
        (WebCore::IDBClient::IDBRequest::pendingCursor):
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::addRequest): Deleted.
        
        * Modules/indexeddb/client/TransactionOperation.cpp:
        (WebCore::IDBClient::TransactionOperation::TransactionOperation):
        * Modules/indexeddb/client/TransactionOperation.h:
        (WebCore::IDBClient::TransactionOperation::cursorIdentifier):
        
        * Modules/indexeddb/server/IDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::objectStoreCleared):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:
        
        * Modules/indexeddb/server/MemoryCursor.cpp: Added.
        (WebCore::IDBServer::cursorMap):
        (WebCore::IDBServer::MemoryCursor::MemoryCursor):
        (WebCore::IDBServer::MemoryCursor::~MemoryCursor):
        (WebCore::IDBServer::MemoryCursor::cursorForIdentifier):
        * Modules/indexeddb/server/MemoryCursor.h: Added.
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::openCursor):
        (WebCore::IDBServer::MemoryIDBBackingStore::iterateCursor):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::clear):
        (WebCore::IDBServer::MemoryObjectStore::replaceKeyValueStore):
        (WebCore::IDBServer::MemoryObjectStore::deleteRecord):
        (WebCore::IDBServer::MemoryObjectStore::addRecord):
        (WebCore::IDBServer::MemoryObjectStore::updateCursorsForPutRecord):
        (WebCore::IDBServer::MemoryObjectStore::updateCursorsForDeleteRecord):
        (WebCore::IDBServer::MemoryObjectStore::maybeOpenCursor):
        * Modules/indexeddb/server/MemoryObjectStore.h:
        (WebCore::IDBServer::MemoryObjectStore::orderedKeys):
        
        * Modules/indexeddb/server/MemoryObjectStoreCursor.cpp: Added.
        (WebCore::IDBServer::MemoryObjectStoreCursor::create):
        (WebCore::IDBServer::MemoryObjectStoreCursor::MemoryObjectStoreCursor):
        (WebCore::IDBServer::MemoryObjectStoreCursor::objectStoreCleared):
        (WebCore::IDBServer::MemoryObjectStoreCursor::keyDeleted):
        (WebCore::IDBServer::MemoryObjectStoreCursor::keyAdded):
        (WebCore::IDBServer::MemoryObjectStoreCursor::setFirstInRemainingRange):
        (WebCore::IDBServer::MemoryObjectStoreCursor::firstForwardIteratorInRemainingRange):
        (WebCore::IDBServer::MemoryObjectStoreCursor::firstReverseIteratorInRemainingRange):
        (WebCore::IDBServer::MemoryObjectStoreCursor::currentData):
        (WebCore::IDBServer::MemoryObjectStoreCursor::incrementForwardIterator):
        (WebCore::IDBServer::MemoryObjectStoreCursor::incrementReverseIterator):
        (WebCore::IDBServer::MemoryObjectStoreCursor::hasValidPosition):
        (WebCore::IDBServer::MemoryObjectStoreCursor::iterate):
        * Modules/indexeddb/server/MemoryObjectStoreCursor.h: Added.

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::iterateCursor):
        (WebCore::IDBServer::UniqueIDBDatabase::performIterateCursor):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:

        * Modules/indexeddb/shared/IDBCursorInfo.h:
        (WebCore::IDBCursorInfo::range):

        * Modules/indexeddb/shared/IDBRequestData.cpp:
        (WebCore::IDBRequestData::IDBRequestData):
        (WebCore::IDBRequestData::cursorIdentifier):
        * Modules/indexeddb/shared/IDBRequestData.h:

2015-11-16  Anders Carlsson  <andersca@apple.com>

        Add identifier strings for a bunch of context menu items
        https://bugs.webkit.org/show_bug.cgi?id=151272

        Reviewed by Dan Bernstein.

        Have NSMenuItem conform to NSUserInterfaceItemIdentification.

        * platform/spi/mac/NSMenuSPI.h:

2015-11-16  Jiewen Tan  <jiewen_tan@apple.com>

        Null-pointer dereference in WebCore::firstEditablePositionAfterPositionInRoot
        https://bugs.webkit.org/show_bug.cgi?id=151288
        <rdar://problem/23450367>

        Reviewed by Darin Adler.

        Some problematic organization of body element could cause problems to JustifyRight
        and Indent commnads.

        Tests: editing/execCommand/justify-right-then-indent-with-problematic-body.html
               editing/execCommand/justify-right-with-problematic-body.html

        * editing/CompositeEditCommand.cpp:
        (WebCore::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
        Assertion at l1017 is not held anymore with the testcase:
        editing/execCommand/justify-right-with-problematic-body.html.
        Therefore, change it to an if statement.
        Also, add a guardance before calling insertNewDefaultParagraphElementAt()
        as insertNodeAt() requires an editable position.
        (WebCore::CompositeEditCommand::moveParagraphWithClones):
        Add a guardance before calling insertNodeAt() as it requires an editable position.
        * editing/htmlediting.cpp:
        (WebCore::firstEditablePositionAfterPositionInRoot):
        (WebCore::lastEditablePositionBeforePositionInRoot):

2015-11-16  Simon Fraser  <simon.fraser@apple.com>

        Sort the Xcode project files.

        * WebCore.xcodeproj/project.pbxproj:

2015-11-16  Sebastian Dröge  <sebastian@centricular.com>

        WebRTC: Expose RTCPeerConnectionInternals functions to JS builtins.
        https://bugs.webkit.org/show_bug.cgi?id=151302

        Reviewed by Youenn Fablet.

        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::JSDOMWindowBase::finishCreation):
        Expose RTCPeerConnectionInternals functions to JS builtins.

2015-11-16  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Update the implementation up to spec of Nov 11 2015
        https://bugs.webkit.org/show_bug.cgi?id=151195

        Reviewed by Youenn Fablet.

        Updated the implementation of Readable and Writable Streams to the latest changes in the spec. Main changes are
        the removal of the error and the state from the reader, readers are not automatically released and then minor or
        style changes.

        Implementation is up to date with version
        https://github.com/whatwg/streams/commit/48c8a3c30ea7e76c5e4eb9f157a438dd755bcc8e.

        Tests: streams/reference-implementation/readable-stream-templated.html
               streams/reference-implementation/readable-stream-reader.html

        * Modules/streams/ReadableStream.js:
        (getReader): Removed check for locked stream.
        * Modules/streams/ReadableStreamInternals.js:
        (privateInitializeReadableStreamReader): Removed setting @error and @state and initialized owner and owner's
        reader as per spec.
        (teeReadableStreamPullFunction): Added assertions.
        (isReadableStreamReader): Added comment about resetting the reader owner to null instead of undefined as a means
        to distinguish between not having the slot and having it unset.
        (finishClosingReadableStream): Inline @closeReadableStreamReader as it is used only here now.
        (readFromReadableStreamReader): Reworked the state and error to use the stream one and changed the conditions to
        pull again as per spec.
        (errorReadableStream): Not releasing the reader and removed the reader error and state management.
        (releaseReadableStreamReader): Deleted.
        (closeReadableStreamReader): Deleted.
        * Modules/streams/ReadableStreamReader.js:
        (cancel): Removed some checks and assertions as per spec.
        (read): Added check for owner.
        (releaseLock): No closing the reader and rejecting close promise and unlinking reader and owner instead.
        * Modules/streams/WritableStream.js:
        (abort): Style change.
        * Modules/streams/WritableStreamInternals.js:
        (writableStreamAdvanceQueue):
        (closeWritableStream): Used @call instead of @apply.

2015-11-15  Adam Bergkvist  <adam.bergkvist@ericsson.com>

        WebRTC: Update RTCPeerConnection API and introduce PeerConnectionBackend
        https://bugs.webkit.org/show_bug.cgi?id=150166

        Reviewed by Eric Carlson and Youenn Fablet

        This change introduces PeerConnectionBackend which is a WebCore interface
        that allows RTCPeerConnection to have platform abstractions at different
        levels. For example, the MediaEndpoint interface [1] is a lower level
        WebRTC backend abstraction where a big part of the WebRTC specification
        is implemented in WebCore to be reusable. RTCPeerConnectionHandler (in
        the repo today) is on the other hand a higher level WebRTC backend
        abstraction where the calls are mostly forwarded directly to the
        backend. The PeerConnectionBackend interface facilitates both approaches.

        RTCPeerConnection
         | (has)
         |
        PeerConnectionBackend
         |   |
         |   | (realizes)
         |  MediaEndpointPeerConnection
         |   | (has)
         |   |
         |  MediaEndpoint (platform interface)
         |
         | (realizes)
        RTCPeerHandlerPeerConnection
         | (has)
         |
        RCPeerConnectionHandler (existing platform interface)

        Notable changes:

        # Overloaded methods on RTCPeerConnection (Promise + legacy callback
        signatures) are implemented with JSBuiltins.

        # "Queued operations" ([1] Section 4.3.1) is implemented in JS bindings
        with Promises.

        # New RTCPeerConnection features
         - add/removeTrack()
         - pending/currentLocal/RemoteDescription attributes
         - RTCRtpSender/Receiver

        # Information carrying objects like RTCSessionDescription and
        RTCCandidate don't encapsulate a "mirrored" platform object anymore.

        # Remove RTCPeerConnection specific callback implementations (not used
        with JS bindings)

        [1] http://webkit.org/b/150165
        [2] https://w3c.github.io/webrtc-pc/archives/20151006/webrtc.html

        Tests: Mock should be added to test future WebRTC backend abstractions.

        * CMakeLists.txt:
        * DerivedSources.make:
        * Modules/mediastream/PeerConnectionBackend.cpp: Added.
        (WebCore::createPeerConnectionBackend):
        * Modules/mediastream/PeerConnectionBackend.h: Added.
        (WebCore::PeerConnectionBackendClient::~PeerConnectionBackendClient):
        (WebCore::PeerConnectionBackend::~PeerConnectionBackend):
        * Modules/mediastream/PeerConnectionStates.h: Added.
        * Modules/mediastream/RTCConfiguration.cpp: Added.
        (WebCore::validateIceServerURL):
        (WebCore::parseIceServer):
        (WebCore::RTCConfiguration::create):
        (WebCore::RTCConfiguration::RTCConfiguration):
        (WebCore::RTCConfiguration::initialize):
        * Modules/mediastream/RTCConfiguration.h:
        (WebCore::RTCConfiguration::iceTransportPolicy):
        (WebCore::RTCConfiguration::bundlePolicy):
        (WebCore::RTCConfiguration::iceServers):
        (WebCore::RTCConfiguration::create): Deleted.
        (WebCore::RTCConfiguration::appendServer): Deleted.
        (WebCore::RTCConfiguration::numberOfServers): Deleted.
        (WebCore::RTCConfiguration::server): Deleted.
        (WebCore::RTCConfiguration::iceTransports): Deleted.
        (WebCore::RTCConfiguration::setIceTransports): Deleted.
        (WebCore::RTCConfiguration::requestIdentity): Deleted.
        (WebCore::RTCConfiguration::setRequestIdentity): Deleted.
        (WebCore::RTCConfiguration::privateConfiguration): Deleted.
        (WebCore::RTCConfiguration::RTCConfiguration): Deleted.
        * Modules/mediastream/RTCConfiguration.idl:
        * Modules/mediastream/RTCIceCandidate.cpp:
        (WebCore::RTCIceCandidate::create):
        (WebCore::RTCIceCandidate::RTCIceCandidate):
        (WebCore::RTCIceCandidate::~RTCIceCandidate): Deleted.
        (WebCore::RTCIceCandidate::candidate): Deleted.
        (WebCore::RTCIceCandidate::sdpMid): Deleted.
        (WebCore::RTCIceCandidate::sdpMLineIndex): Deleted.
        (WebCore::RTCIceCandidate::descriptor): Deleted.
        * Modules/mediastream/RTCIceCandidate.h:
        (WebCore::RTCIceCandidate::~RTCIceCandidate):
        (WebCore::RTCIceCandidate::candidate):
        (WebCore::RTCIceCandidate::setCandidate):
        (WebCore::RTCIceCandidate::sdpMid):
        (WebCore::RTCIceCandidate::setSdpMid):
        (WebCore::RTCIceCandidate::sdpMLineIndex):
        (WebCore::RTCIceCandidate::setSdpMLineIndex):
        * Modules/mediastream/RTCIceCandidate.idl:
        * Modules/mediastream/RTCIceCandidateEvent.cpp:
        (WebCore::RTCIceCandidateEvent::create):
        (WebCore::RTCIceCandidateEvent::RTCIceCandidateEvent):
        * Modules/mediastream/RTCIceCandidateEvent.h:
        * Modules/mediastream/RTCIceServer.h:
        (WebCore::RTCIceServer::urls):
        (WebCore::RTCIceServer::credential):
        (WebCore::RTCIceServer::username):
        (WebCore::RTCIceServer::RTCIceServer):
        (WebCore::RTCIceServer::create): Deleted.
        (WebCore::RTCIceServer::privateServer): Deleted.
        * Modules/mediastream/RTCOfferAnswerOptions.cpp:
        (WebCore::RTCOfferAnswerOptions::RTCOfferAnswerOptions):
        (WebCore::RTCOfferAnswerOptions::initialize):
        (WebCore::RTCOfferOptions::RTCOfferOptions):
        (WebCore::RTCOfferOptions::initialize):
        (WebCore::RTCAnswerOptions::create):
        (WebCore::RTCAnswerOptions::initialize):
        (WebCore::RTCOfferAnswerOptions::create): Deleted.
        * Modules/mediastream/RTCOfferAnswerOptions.h:
        (WebCore::RTCOfferAnswerOptions::voiceActivityDetection):
        (WebCore::RTCOfferOptions::offerToReceiveVideo):
        (WebCore::RTCOfferOptions::offerToReceiveAudio):
        (WebCore::RTCOfferOptions::iceRestart):
        (WebCore::RTCAnswerOptions::RTCAnswerOptions):
        (WebCore::RTCOfferAnswerOptions::requestIdentity): Deleted.
        (WebCore::RTCOfferAnswerOptions::privateOfferAnswerOptions): Deleted.
        (WebCore::RTCOfferAnswerOptions::RTCOfferAnswerOptions): Deleted.
        (WebCore::RTCOfferOptions::voiceActivityDetection): Deleted.
        (WebCore::RTCOfferOptions::privateOfferOptions): Deleted.
        (WebCore::RTCOfferOptions::~RTCOfferOptions): Deleted.
        (WebCore::RTCOfferOptions::RTCOfferOptions): Deleted.
        * Modules/mediastream/RTCPeerConnection.cpp:
        (WebCore::RTCPeerConnection::create):
        (WebCore::RTCPeerConnection::RTCPeerConnection):
        (WebCore::RTCPeerConnection::getSenders):
        (WebCore::RTCPeerConnection::getReceivers):
        (WebCore::RTCPeerConnection::addTrack):
        (WebCore::RTCPeerConnection::removeTrack):
        (WebCore::RTCPeerConnection::queuedCreateOffer):
        (WebCore::RTCPeerConnection::queuedCreateAnswer):
        (WebCore::RTCPeerConnection::queuedSetLocalDescription):
        (WebCore::RTCPeerConnection::localDescription):
        (WebCore::RTCPeerConnection::currentLocalDescription):
        (WebCore::RTCPeerConnection::pendingLocalDescription):
        (WebCore::RTCPeerConnection::queuedSetRemoteDescription):
        (WebCore::RTCPeerConnection::remoteDescription):
        (WebCore::RTCPeerConnection::currentRemoteDescription):
        (WebCore::RTCPeerConnection::pendingRemoteDescription):
        (WebCore::RTCPeerConnection::queuedAddIceCandidate):
        (WebCore::RTCPeerConnection::signalingState):
        (WebCore::RTCPeerConnection::iceGatheringState):
        (WebCore::RTCPeerConnection::iceConnectionState):
        (WebCore::RTCPeerConnection::setConfiguration):
        (WebCore::RTCPeerConnection::privateGetStats):
        (WebCore::RTCPeerConnection::createDataChannel):
        (WebCore::RTCPeerConnection::close):
        (WebCore::RTCPeerConnection::stop):
        (WebCore::RTCPeerConnection::setSignalingState):
        (WebCore::RTCPeerConnection::updateIceGatheringState):
        (WebCore::RTCPeerConnection::updateIceConnectionState):
        (WebCore::RTCPeerConnection::scheduleNegotiationNeededEvent):
        (WebCore::RTCPeerConnection::fireEvent):
        (WebCore::validateIceServerURL): Deleted.
        (WebCore::processIceServer): Deleted.
        (WebCore::RTCPeerConnection::parseConfiguration): Deleted.
        (WebCore::RTCPeerConnection::~RTCPeerConnection): Deleted.
        (WebCore::RTCPeerConnection::createOffer): Deleted.
        (WebCore::RTCPeerConnection::createAnswer): Deleted.
        (WebCore::RTCPeerConnection::checkStateForLocalDescription): Deleted.
        (WebCore::RTCPeerConnection::checkStateForRemoteDescription): Deleted.
        (WebCore::RTCPeerConnection::setLocalDescription): Deleted.
        (WebCore::RTCPeerConnection::setRemoteDescription): Deleted.
        (WebCore::RTCPeerConnection::updateIce): Deleted.
        (WebCore::RTCPeerConnection::addIceCandidate): Deleted.
        (WebCore::RTCPeerConnection::addStream): Deleted.
        (WebCore::RTCPeerConnection::removeStream): Deleted.
        (WebCore::RTCPeerConnection::getLocalStreams): Deleted.
        (WebCore::RTCPeerConnection::getRemoteStreams): Deleted.
        (WebCore::RTCPeerConnection::getStreamById): Deleted.
        (WebCore::RTCPeerConnection::getStats): Deleted.
        (WebCore::RTCPeerConnection::hasLocalStreamWithTrackId): Deleted.
        (WebCore::RTCPeerConnection::createDTMFSender): Deleted.
        (WebCore::RTCPeerConnection::negotiationNeeded): Deleted.
        (WebCore::RTCPeerConnection::didGenerateIceCandidate): Deleted.
        (WebCore::RTCPeerConnection::didChangeSignalingState): Deleted.
        (WebCore::RTCPeerConnection::didChangeIceGatheringState): Deleted.
        (WebCore::RTCPeerConnection::didChangeIceConnectionState): Deleted.
        (WebCore::RTCPeerConnection::didAddRemoteStream): Deleted.
        (WebCore::RTCPeerConnection::didRemoveRemoteStream): Deleted.
        (WebCore::RTCPeerConnection::didAddRemoteDataChannel): Deleted.
        (WebCore::RTCPeerConnection::didAddOrRemoveTrack): Deleted.
        (WebCore::RTCPeerConnection::changeSignalingState): Deleted.
        (WebCore::RTCPeerConnection::changeIceGatheringState): Deleted.
        (WebCore::RTCPeerConnection::changeIceConnectionState): Deleted.
        (WebCore::RTCPeerConnection::scheduleDispatchEvent): Deleted.
        (WebCore::RTCPeerConnection::scheduledEventTimerFired): Deleted.
        * Modules/mediastream/RTCPeerConnection.h:
        * Modules/mediastream/RTCPeerConnection.idl:
        * Modules/mediastream/RTCPeerConnection.js: Added.
        (createOffer):
        (createAnswer):
        (setLocalDescription):
        (setRemoteDescription):
        (addIceCandidate):
        (getStats):
        * Modules/mediastream/RTCPeerConnectionErrorCallback.h:
        (WebCore::RTCPeerConnectionErrorCallback::~RTCPeerConnectionErrorCallback): Deleted.
        * Modules/mediastream/RTCPeerConnectionInternals.js: Added.
        (runNext):
        (enqueueOperation):
        (setLocalOrRemoteDescription):
        (extractCallbackArg):
        * Modules/mediastream/RTCRtpReceiver.cpp: Added.
        (WebCore::RTCRtpReceiver::RTCRtpReceiver):
        * Modules/mediastream/RTCRtpReceiver.h: Added.
        (WebCore::RTCRtpReceiver::create):
        * Modules/mediastream/RTCRtpReceiver.idl: Added.
        * Modules/mediastream/RTCRtpSender.cpp: Added.
        (WebCore::RTCRtpSender::RTCRtpSender):
        * Modules/mediastream/RTCRtpSender.h: Added.
        (WebCore::RTCRtpSender::create):
        (WebCore::RTCRtpSender::mediaStreamId):
        * Modules/mediastream/RTCRtpSender.idl: Added.
        * Modules/mediastream/RTCRtpSenderReceiverBase.h: Added.
        (WebCore::RTCRtpSenderReceiverBase::~RTCRtpSenderReceiverBase):
        (WebCore::RTCRtpSenderReceiverBase::track):
        (WebCore::RTCRtpSenderReceiverBase::RTCRtpSenderReceiverBase):
        * Modules/mediastream/RTCSessionDescription.cpp:
        (WebCore::RTCSessionDescription::create):
        (WebCore::RTCSessionDescription::RTCSessionDescription):
        (WebCore::RTCSessionDescription::setType):
        (WebCore::RTCSessionDescription::~RTCSessionDescription): Deleted.
        (WebCore::RTCSessionDescription::type): Deleted.
        (WebCore::RTCSessionDescription::sdp): Deleted.
        (WebCore::RTCSessionDescription::setSdp): Deleted.
        (WebCore::RTCSessionDescription::descriptor): Deleted.
        * Modules/mediastream/RTCSessionDescription.h:
        (WebCore::RTCSessionDescription::~RTCSessionDescription):
        (WebCore::RTCSessionDescription::type):
        (WebCore::RTCSessionDescription::sdp):
        (WebCore::RTCSessionDescription::setSdp):
        * Modules/mediastream/RTCSessionDescriptionCallback.h:
        (WebCore::RTCSessionDescriptionCallback::~RTCSessionDescriptionCallback): Deleted.
        * Modules/mediastream/RTCSessionDescriptionRequestImpl.cpp: Removed.
        (WebCore::RTCSessionDescriptionRequestImpl::create): Deleted.
        (WebCore::RTCSessionDescriptionRequestImpl::RTCSessionDescriptionRequestImpl): Deleted.
        (WebCore::RTCSessionDescriptionRequestImpl::~RTCSessionDescriptionRequestImpl): Deleted.
        (WebCore::RTCSessionDescriptionRequestImpl::requestSucceeded): Deleted.
        (WebCore::RTCSessionDescriptionRequestImpl::requestFailed): Deleted.
        (WebCore::RTCSessionDescriptionRequestImpl::stop): Deleted.
        (WebCore::RTCSessionDescriptionRequestImpl::activeDOMObjectName): Deleted.
        (WebCore::RTCSessionDescriptionRequestImpl::canSuspendForPageCache): Deleted.
        (WebCore::RTCSessionDescriptionRequestImpl::clear): Deleted.
        * Modules/mediastream/RTCSessionDescriptionRequestImpl.h: Removed.
        * Modules/mediastream/RTCStatsCallback.h: Removed.
        (WebCore::RTCStatsCallback::~RTCStatsCallback): Deleted.
        * Modules/mediastream/RTCStatsCallback.idl: Removed.
        * Modules/mediastream/RTCStatsRequestImpl.cpp: Removed.
        (WebCore::RTCStatsRequestImpl::create): Deleted.
        (WebCore::RTCStatsRequestImpl::RTCStatsRequestImpl): Deleted.
        (WebCore::RTCStatsRequestImpl::~RTCStatsRequestImpl): Deleted.
        (WebCore::RTCStatsRequestImpl::createResponse): Deleted.
        (WebCore::RTCStatsRequestImpl::hasSelector): Deleted.
        (WebCore::RTCStatsRequestImpl::track): Deleted.
        (WebCore::RTCStatsRequestImpl::requestSucceeded): Deleted.
        (WebCore::RTCStatsRequestImpl::requestFailed): Deleted.
        (WebCore::RTCStatsRequestImpl::stop): Deleted.
        (WebCore::RTCStatsRequestImpl::activeDOMObjectName): Deleted.
        (WebCore::RTCStatsRequestImpl::canSuspendForPageCache): Deleted.
        (WebCore::RTCStatsRequestImpl::clear): Deleted.
        * Modules/mediastream/RTCStatsRequestImpl.h: Removed.
        * Modules/mediastream/RTCTrackEvent.cpp: Added.
        (WebCore::RTCTrackEventInit::RTCTrackEventInit):
        (WebCore::RTCTrackEvent::create):
        (WebCore::RTCTrackEvent::RTCTrackEvent):
        * Modules/mediastream/RTCTrackEvent.h: Added.
        (WebCore::RTCTrackEvent::receiver):
        (WebCore::RTCTrackEvent::track):
        (WebCore::RTCTrackEvent::eventInterface):
        * Modules/mediastream/RTCTrackEvent.idl: Added.
        * Modules/mediastream/RTCVoidRequestImpl.cpp: Removed.
        (WebCore::RTCVoidRequestImpl::create): Deleted.
        (WebCore::RTCVoidRequestImpl::RTCVoidRequestImpl): Deleted.
        (WebCore::RTCVoidRequestImpl::~RTCVoidRequestImpl): Deleted.
        (WebCore::RTCVoidRequestImpl::requestSucceeded): Deleted.
        (WebCore::RTCVoidRequestImpl::requestFailed): Deleted.
        (WebCore::RTCVoidRequestImpl::stop): Deleted.
        (WebCore::RTCVoidRequestImpl::activeDOMObjectName): Deleted.
        (WebCore::RTCVoidRequestImpl::canSuspendForPageCache): Deleted.
        (WebCore::RTCVoidRequestImpl::clear): Deleted.
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/JSDictionary.cpp:
        (WebCore::JSDictionary::convertValue):
        * bindings/js/JSDictionary.h:
        * bindings/js/WebCoreBuiltinNames.h:
        * bindings/js/WebCoreJSBuiltinInternals.h:
        (WebCore::JSBuiltinInternalFunctions::JSBuiltinInternalFunctions):
        (WebCore::JSBuiltinInternalFunctions::rTCPeerConnectionInternals):
        (WebCore::JSBuiltinInternalFunctions::visit):
        (WebCore::JSBuiltinInternalFunctions::init):
        * bindings/js/WebCoreJSBuiltins.cpp:
        * bindings/js/WebCoreJSBuiltins.h:
        (WebCore::JSBuiltinFunctions::JSBuiltinFunctions):
        (WebCore::JSBuiltinFunctions::rTCPeerConnectionBuiltins):
        (WebCore::JSBuiltinFunctions::rTCPeerConnectionInternalsBuiltins):
        * dom/EventNames.in:

2015-11-15  David Kilzer  <ddkilzer@apple.com>

        REGRESSION (r192404): Fix tvOS and watchOS builds

        * platform/spi/cocoa/QuartzCoreSPI.h: Add more version checks to
        fix all the builds.

2015-11-14  Gyuyoung Kim  <gyuyoung.kim@webkit.org>

        [EFL][GTK] Remove use of String::format() in versionForUAString()
        https://bugs.webkit.org/show_bug.cgi?id=151250

        Reviewed by Darin Adler.

        As String::format() will be deprecated due to the security problem, reimplement
        versionForUAString() using a macro.

        * platform/efl/UserAgentEfl.cpp:
        (WebCore::versionForUAString):
        * platform/gtk/UserAgentGtk.cpp:
        (WebCore::platformVersionForUAString):
        (WebCore::versionForUAString):

2015-11-14  Antti Koivisto  <antti@apple.com>

        Regression(r188820): Downloads of data URLs is broken
        https://bugs.webkit.org/show_bug.cgi?id=150900
        rdar://problem/23399223

        Reviewed by Darin Adler.

        No test, the current test infrastructure only allows testing policy decisions, not the actual download.

        * loader/DocumentLoader.cpp:
        (WebCore::DocumentLoader::continueAfterContentPolicy):

        Use normal download path for data URLs instead of trying to convert the main resource load.
        Since we decode data URLs locally there is no associated resource load on WebKit side.

2015-11-14  Nan Wang  <n_wang@apple.com>

        AX: add a new trait for elements in fieldset on iOS
        https://bugs.webkit.org/show_bug.cgi?id=151281

        Reviewed by Chris Fleizach.

        Added a new trait for elements in the fieldset, so VoiceOver can speak the legend
        information for those elements.

        Test: accessibility/ios-simulator/fieldset-traits.html

        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
        (-[WebAccessibilityObjectWrapper accessibilityCanFuzzyHitTest]):
        (-[WebAccessibilityObjectWrapper _accessibilityTableAncestor]):
        (-[WebAccessibilityObjectWrapper _accessibilityFieldsetAncestor]):
        (-[WebAccessibilityObjectWrapper _accessibilityTraitsFromAncestors]):

2015-11-13  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r192445, r192451, and r192452.
        https://bugs.webkit.org/show_bug.cgi?id=151291

        Broke Mavericks build (and thus EWS) (Requested by ap on
        #webkit).

        Reverted changesets:

        "Add identifier strings for a bunch of context menu items"
        https://bugs.webkit.org/show_bug.cgi?id=151272
        http://trac.webkit.org/changeset/192445

        "Try to fix the 32-bit build"
        http://trac.webkit.org/changeset/192451

        "Try to fix the 32-bit build"
        http://trac.webkit.org/changeset/192452

2015-11-13  Anders Carlsson  <andersca@apple.com>

        Add identifier strings for a bunch of context menu items
        https://bugs.webkit.org/show_bug.cgi?id=151272

        Reviewed by Dan Bernstein.

        Have NSMenuItem conform to NSUserInterfaceItemIdentification.

        * platform/spi/mac/NSMenuSPI.h:

2015-11-13  Zalan Bujtas  <zalan@apple.com>

        Always render at least a device pixel line when border/outline width > 0.
        https://bugs.webkit.org/show_bug.cgi?id=151269

        This matches Firefox behaviour.

        Reviewed by Simon Fraser.

        Existing test is modified to reflect the new behaviour.

        * css/StyleBuilderConverter.h:
        (WebCore::StyleBuilderConverter::convertLineWidth):
        * rendering/BorderEdge.cpp:
        (WebCore::BorderEdge::BorderEdge): Deleted.
        * rendering/BorderEdge.h:

2015-11-13  Per Arne Vollan  <peavo@outlook.com>

        [WinCairo][MediaFoundation] Video rendered at wrong position.
        https://bugs.webkit.org/show_bug.cgi?id=151271

        Reviewed by Alex Christensen.

        The source rectangle used when blitting a frame to the graphics context
        should have offset (0, 0).

        * platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::paintCurrentFrame):

2015-11-13  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Provide a way to override the WKWebView remote inspector name
        https://bugs.webkit.org/show_bug.cgi?id=151075

        Reviewed by Tim Horton.

        * page/Page.cpp:
        (WebCore::Page::remoteInspectionNameOverride):
        (WebCore::Page::setRemoteInspectionNameOverride):
        * page/Page.h:
        * page/PageDebuggable.cpp:
        (WebCore::PageDebuggable::name):
        (WebCore::PageDebuggable::setNameOverride):
        * page/PageDebuggable.h:

2015-11-13  Jiewen Tan  <jiewen_tan@apple.com>

        Element::focus() should acquire the ownership of Frame.
        https://bugs.webkit.org/show_bug.cgi?id=150204
        <rdar://problem/23136794>

        Reviewed by Brent Fulgham.

        The FrameSelection::setSelection method sometimes releases the last reference to a frame.
        When this happens, the Element::updateFocusAppearance would attempt to use dereferenced memory.
        Instead, we should ensure that the Frame lifetime is guaranteed to extend through the duration
        of the method call.

        Test: editing/selection/focus-iframe-removal-crash.html

        * dom/Element.cpp:
        (WebCore::Element::updateFocusAppearance):

2015-11-13  Sergio Villar Senin  <svillar@igalia.com>

        [css-grid] Remove unused GridResolvedPosition constructor
        https://bugs.webkit.org/show_bug.cgi?id=151133

        Reviewed by Mario Sanchez Prada.

        No new tests required, just deleting dead code.

        * rendering/style/GridResolvedPosition.cpp:
        (WebCore::GridResolvedPosition::GridResolvedPosition): Deleted.
        * rendering/style/GridResolvedPosition.h:

2015-11-13  Sergio Villar Senin  <svillar@igalia.com>

        ASSERTION FAILED: m_isEngaged in WTF::Optional::value
        https://bugs.webkit.org/show_bug.cgi?id=151094

        Reviewed by Darin Adler.

        That ASSERT was hit because the precondition was incorrectly
        met, i.e., we're considering that the main axis length was
        definite when it was actually not. The problem is that to
        determine whether it was indefinite or not we're using
        RenderBox::hasDefiniteLogicalHeight() which did not perfectly
        match RenderBox::computePercentageLogicalHeight() for the case
        of RenderTables. So computePercentageLogicalHeight() was
        returning Nullopt (i.e. indefinite) while
        hasDefiniteLogicalHeight() was returning true (so definite).

        Some checks were refactored in a helper function to solve the
        inconsistency so that both functions behave the same way even
        in this particular situation.

        Test: css3/flexbox/inline-flex-percentage-height-in-table-crash.html

        * rendering/RenderBox.cpp:
        (WebCore::tableCellShouldHaveZeroInitialSize):
        (WebCore::RenderBox::computePercentageLogicalHeight):
        (WebCore::percentageLogicalHeightIsResolvable):
        (WebCore::RenderBox::percentageLogicalHeightIsResolvableFromBlock):
        * rendering/RenderBox.h:

2015-11-13  Csaba Osztrogonác  <ossy@webkit.org>

        Unreviewed, really fix the Mac CMake build after r192376.

        * PlatformMac.cmake:

2015-11-13  Csaba Osztrogonác  <ossy@webkit.org>

        Unreviewed, fix the Mac CMake build after r192376.

        * PlatformMac.cmake:

2015-11-12  Tim Horton  <timothy_horton@apple.com>

        Follow up to the previous change

        * platform/spi/cocoa/QuartzCoreSPI.h:
        Somehow this escaped.

2015-11-12  Tim Horton  <timothy_horton@apple.com>

        Try to fix the Watch/TV build

        * platform/spi/cocoa/QuartzCoreSPI.h:
        Be more accurate about where we need these.

2015-11-12  Brady Eidson  <beidson@apple.com>

        Modern IDB: Pipe through cursor functions from client to server.
        https://bugs.webkit.org/show_bug.cgi?id=151197

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/cursor-1.html
               storage/indexeddb/modern/opencursor-failures.html

        This patch implements most IDBCursor considerations at the IDL level, as well as pipes the
        appropriate messages through from client to server.
        
        All operations currently end in errors. Bug 151196 will fix that by making cursors functional.
        
        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:

        * Modules/indexeddb/IDBCursor.h:
        (WebCore::IDBCursor::isKeyCursor): Deleted.
        * Modules/indexeddb/IDBCursorWithValue.h:

        * Modules/indexeddb/IDBGetResult.h:

        * Modules/indexeddb/IDBKeyData.h:
        (WebCore::IDBKeyData::string):
        (WebCore::IDBKeyData::date):
        (WebCore::IDBKeyData::number):
        (WebCore::IDBKeyData::array):

        * Modules/indexeddb/IndexedDB.h:

        * Modules/indexeddb/client/IDBAnyImpl.cpp:
        (WebCore::IDBClient::IDBAny::IDBAny):
        (WebCore::IDBClient::IDBAny::idbCursor):
        (WebCore::IDBClient::IDBAny::idbCursorWithValue):
        (WebCore::IDBClient::IDBAny::idbIndex):
        (WebCore::IDBClient::IDBAny::idbObjectStore):
        (WebCore::IDBClient::IDBAny::modernIDBCursor):
        * Modules/indexeddb/client/IDBAnyImpl.h:
        (WebCore::IDBClient::IDBAny::create):

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::openCursor):
        (WebCore::IDBClient::IDBConnectionToServer::didOpenCursor):
        (WebCore::IDBClient::IDBConnectionToServer::iterateCursor):
        (WebCore::IDBClient::IDBConnectionToServer::didIterateCursor):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:

        * Modules/indexeddb/client/IDBCursorImpl.cpp:
        (WebCore::IDBClient::IDBCursor::create):
        (WebCore::IDBClient::IDBCursor::IDBCursor):
        (WebCore::IDBClient::IDBCursor::sourcesDeleted):
        (WebCore::IDBClient::IDBCursor::effectiveObjectStore):
        (WebCore::IDBClient::IDBCursor::transaction):
        (WebCore::IDBClient::IDBCursor::direction):
        (WebCore::IDBClient::IDBCursor::key):
        (WebCore::IDBClient::IDBCursor::primaryKey):
        (WebCore::IDBClient::IDBCursor::value):
        (WebCore::IDBClient::IDBCursor::source):
        (WebCore::IDBClient::IDBCursor::update):
        (WebCore::IDBClient::IDBCursor::advance):
        (WebCore::IDBClient::IDBCursor::continueFunction):
        (WebCore::IDBClient::IDBCursor::uncheckedIteratorCursor):
        (WebCore::IDBClient::IDBCursor::deleteFunction):
        (WebCore::IDBClient::IDBCursor::setGetResult):
        * Modules/indexeddb/client/IDBCursorImpl.h:
        (WebCore::IDBClient::IDBCursor::info):
        (WebCore::IDBClient::IDBCursor::setRequest):
        (WebCore::IDBClient::IDBCursor::clearRequest):
        (WebCore::IDBClient::IDBCursor::request):

        * Modules/indexeddb/client/IDBCursorWithValueImpl.cpp:
        (WebCore::IDBClient::IDBCursorWithValue::create):
        (WebCore::IDBClient::IDBCursorWithValue::IDBCursorWithValue):
        (WebCore::IDBClient::IDBCursorWithValue::~IDBCursorWithValue):
        * Modules/indexeddb/client/IDBCursorWithValueImpl.h:

        * Modules/indexeddb/client/IDBIndexImpl.cpp:
        (WebCore::IDBClient::IDBIndex::openCursor):
        (WebCore::IDBClient::IDBIndex::openKeyCursor):
        * Modules/indexeddb/client/IDBIndexImpl.h:
        (WebCore::IDBClient::IDBIndex::modernObjectStore):
        (WebCore::IDBClient::IDBIndex::isDeleted):

        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::openCursor):
        (WebCore::IDBClient::IDBObjectStore::deleteFunction):
        * Modules/indexeddb/client/IDBObjectStoreImpl.h:

        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::create):
        (WebCore::IDBClient::IDBRequest::IDBRequest):
        (WebCore::IDBClient::IDBRequest::~IDBRequest):
        (WebCore::IDBClient::IDBRequest::source):
        (WebCore::IDBClient::IDBRequest::resultCursor):
        (WebCore::IDBClient::IDBRequest::willIterateCursor):
        (WebCore::IDBClient::IDBRequest::didOpenOrIterateCursor):
        (WebCore::IDBClient::IDBRequest::requestCompleted):
        * Modules/indexeddb/client/IDBRequestImpl.h:
        (WebCore::IDBClient::IDBRequest::modernResult):

        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::requestOpenCursor):
        (WebCore::IDBClient::IDBTransaction::doRequestOpenCursor):
        (WebCore::IDBClient::IDBTransaction::openCursorOnServer):
        (WebCore::IDBClient::IDBTransaction::didOpenCursorOnServer):
        (WebCore::IDBClient::IDBTransaction::iterateCursor):
        (WebCore::IDBClient::IDBTransaction::iterateCursorOnServer):
        (WebCore::IDBClient::IDBTransaction::didIterateCursorOnServer):
        * Modules/indexeddb/client/IDBTransactionImpl.h:

        * Modules/indexeddb/client/TransactionOperation.h:
        (WebCore::IDBClient::createTransactionOperation):

        * Modules/indexeddb/legacy/LegacyCursor.cpp:
        (WebCore::LegacyCursor::source):
        * Modules/indexeddb/legacy/LegacyCursor.h:
        (WebCore::LegacyCursor::continueFunction): Deleted.
        (WebCore::LegacyCursor::isKeyCursor): Deleted.
        * Modules/indexeddb/legacy/LegacyCursorWithValue.h:

        * Modules/indexeddb/server/IDBBackingStore.h:

        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didOpenCursor):
        (WebCore::IDBServer::IDBConnectionToClient::didIterateCursor):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:

        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::openCursor):
        (WebCore::IDBServer::IDBServer::iterateCursor):
        * Modules/indexeddb/server/IDBServer.h:

        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::openCursor):
        (WebCore::IDBServer::MemoryIDBBackingStore::iterateCursor):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::openCursor):
        (WebCore::IDBServer::UniqueIDBDatabase::performOpenCursor):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformOpenCursor):
        (WebCore::IDBServer::UniqueIDBDatabase::iterateCursor):
        (WebCore::IDBServer::UniqueIDBDatabase::performIterateCursor):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformIterateCursor):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::deleteRecord):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::openCursor):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::iterateCursor):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:

        * Modules/indexeddb/shared/IDBCursorInfo.cpp: Added.
        (WebCore::IDBCursorInfo::objectStoreCursor):
        (WebCore::IDBCursorInfo::indexCursor):
        (WebCore::IDBCursorInfo::IDBCursorInfo):
        (WebCore::IDBCursorInfo::isDirectionForward):
        (WebCore::IDBCursorInfo::isolatedCopy):
        * Modules/indexeddb/shared/IDBCursorInfo.h: Added.
        (WebCore::IDBCursorInfo::identifier):
        (WebCore::IDBCursorInfo::sourceIdentifier):
        (WebCore::IDBCursorInfo::cursorSource):
        (WebCore::IDBCursorInfo::cursorDirection):
        (WebCore::IDBCursorInfo::cursorType):

        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::openCursorSuccess):
        (WebCore::IDBResultData::iterateCursorSuccess):
        * Modules/indexeddb/shared/IDBResultData.h:

        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didOpenCursor):
        (WebCore::InProcessIDBServer::didIterateCursor):
        (WebCore::InProcessIDBServer::openCursor):
        (WebCore::InProcessIDBServer::iterateCursor):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

        * bindings/js/IDBBindingUtilities.cpp:
        (WebCore::idbKeyDataToJSValue):
        * bindings/js/IDBBindingUtilities.h:

        * platform/CrossThreadCopier.cpp:
        (WebCore::IDBCursorInfo>::copy):
        * platform/CrossThreadCopier.h:

2015-11-12  Anders Carlsson  <andersca@apple.com>

        Delete PlatformMenuDescription.h
        https://bugs.webkit.org/show_bug.cgi?id=151229

        Reviewed by Beth Dakin.

        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * WebCore.xcodeproj/project.pbxproj:
        * page/ContextMenuClient.h:
        * platform/ContextMenu.h:
        * platform/ContextMenuItem.h:
        * platform/PlatformMenuDescription.h: Removed.

2015-11-12  Anders Carlsson  <andersca@apple.com>

        ContextMenuAction and WebMenuItemTag shouldn't have to be in sync
        https://bugs.webkit.org/show_bug.cgi?id=151226

        Reviewed by Tim Horton.

        * page/ContextMenuController.cpp:
        * platform/ContextMenuItem.h:
        Remove now unneeded comments. Also, remove ContextMenuItemTagOpenLinkInThisWindow since it wasn't used by any of our remaining ports.

2015-11-12  Zalan Bujtas  <zalan@apple.com>

        Ignore visited background color when deciding if the input renderer needs to be painted natively.
        https://bugs.webkit.org/show_bug.cgi?id=151211
        rdar://problem/21449823

        Reviewed by Antti Koivisto.

        Test: fast/css/pseudo-visited-background-color-on-input.html

        * rendering/RenderTheme.cpp:
        (WebCore::RenderTheme::isControlStyled):
        * rendering/style/RenderStyle.h:

2015-11-12  David Hyatt  <hyatt@apple.com>

        Tatechuyoko shrink-to-fit breaks after changing color, background-color or text-decoration
        https://bugs.webkit.org/show_bug.cgi?id=151218
        <rdar://problem/23521702>

        Reviewed by Myles Maxfield.

        Added fast/text/text-combine-shrink-on-color-change.html

        * rendering/RenderCombineText.cpp:
        (WebCore::RenderCombineText::styleDidChange):

2015-11-12  Anders Carlsson  <andersca@apple.com>

        Use ContextMenuItemTagNoAction instead of ContextMenuItemCustomTagNoAction
        https://bugs.webkit.org/show_bug.cgi?id=151222

        Reviewed by Joseph Pecoraro.

        * bindings/js/JSInspectorFrontendHostCustom.cpp:
        (WebCore::populateContextMenuItems):
        * page/ContextMenuController.cpp:
        (WebCore::ContextMenuController::checkOrEnableIfNeeded): Deleted.
        * platform/ContextMenuItem.h:

2015-11-12  Myles C. Maxfield  <mmaxfield@apple.com>

        [Cocoa] Font fallback is not language-sensitive
        https://bugs.webkit.org/show_bug.cgi?id=147390

        Reviewed by Dean Jackson.

        Test: fast/text/fallback-language-han-2.html

        * platform/graphics/cocoa/FontCacheCoreText.cpp:
        (WebCore::FontCache::systemFallbackForCharacters):

2015-11-12  Anders Carlsson  <andersca@apple.com>

        ContextMenuController::contextMenuItemSelected only needs the action and title, not the full item
        https://bugs.webkit.org/show_bug.cgi?id=151217

        Reviewed by Joseph Pecoraro.

        * inspector/InspectorFrontendHost.cpp:
        * page/ContextMenuController.cpp:
        (WebCore::ContextMenuController::contextMenuItemSelected):
        * page/ContextMenuController.h:
        * page/ContextMenuProvider.h:

2015-11-12  Anders Carlsson  <andersca@apple.com>

        Remove an unused function
        https://bugs.webkit.org/show_bug.cgi?id=151215

        Reviewed by Joseph Pecoraro.

        * loader/EmptyClients.h:
        * page/ContextMenuClient.h:
        * page/ContextMenuController.cpp:
        (WebCore::ContextMenuController::contextMenuItemSelected): Deleted.

2015-11-11  Anders Carlsson  <andersca@apple.com>

        Enable cross-platform context menus by default
        https://bugs.webkit.org/show_bug.cgi?id=151173

        Reviewed by Tim Horton.

        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/JSInspectorFrontendHostCustom.cpp:
        (WebCore::JSInspectorFrontendHost::showContextMenu):
        * page/ContextMenuController.cpp:
        (WebCore::ContextMenuController::addInspectElementItem): Deleted.
        * platform/ContextMenu.cpp:
        * platform/ContextMenu.h:
        * platform/ContextMenuItem.cpp:
        * platform/ContextMenuItem.h:
        (WebCore::ContextMenuItem::isNull): Deleted.
        * platform/mac/ContextMenuItemMac.mm: Removed.
        (WebCore::menuToArray): Deleted.
        (WebCore::ContextMenuItem::ContextMenuItem): Deleted.
        (WebCore::createPlatformMenuItemDescription): Deleted.
        (WebCore::ContextMenuItem::~ContextMenuItem): Deleted.
        (WebCore::ContextMenuItem::platformDescription): Deleted.
        (WebCore::ContextMenuItem::type): Deleted.
        (WebCore::ContextMenuItem::action): Deleted.
        (WebCore::ContextMenuItem::title): Deleted.
        (WebCore::ContextMenuItem::platformSubMenu): Deleted.
        (WebCore::ContextMenuItem::setType): Deleted.
        (WebCore::ContextMenuItem::setAction): Deleted.
        (WebCore::ContextMenuItem::setTitle): Deleted.
        (WebCore::ContextMenuItem::setSubMenu): Deleted.
        (WebCore::ContextMenuItem::setChecked): Deleted.
        (WebCore::ContextMenuItem::setEnabled): Deleted.
        (WebCore::ContextMenuItem::enabled): Deleted.
        (WebCore::ContextMenuItem::checked): Deleted.
        * platform/mac/ContextMenuMac.mm: Removed.
        (WebCore::ContextMenu::ContextMenu): Deleted.
        (WebCore::ContextMenu::~ContextMenu): Deleted.
        (WebCore::ContextMenu::appendItem): Deleted.
        (WebCore::ContextMenu::insertItem): Deleted.
        (WebCore::ContextMenu::itemCount): Deleted.
        (WebCore::ContextMenu::setPlatformDescription): Deleted.
        (WebCore::ContextMenu::platformDescription): Deleted.
        (WebCore::ContextMenu::releasePlatformDescription): Deleted.
        (WebCore::contextMenuItemVector): Deleted.
        (WebCore::platformMenuDescription): Deleted.

2015-11-12  Myles C. Maxfield  <mmaxfield@apple.com>

        [Cocoa] Font fallback is not language-sensitive
        https://bugs.webkit.org/show_bug.cgi?id=147390

        Reviewed by Dean Jackson.

        This re-applies r190754 in a somewhat more performant way.

        Test: fast/text/fallback-language-han-2.html

        * platform/graphics/Font.cpp:
        (WebCore::CharacterFallbackMapKey::CharacterFallbackMapKey):
        (WebCore::CharacterFallbackMapKey::operator==):
        (WebCore::CharacterFallbackMapKeyHash::hash):
        (WebCore::Font::systemFallbackFontForCharacter):
        * platform/graphics/cocoa/FontCacheCoreText.cpp:
        (WebCore::FontCache::systemFallbackForCharacters):

2015-11-11  Jon Honeycutt  <jhoneycutt@apple.com>

        popstate event should be dispatched asynchronously
        https://bugs.webkit.org/show_bug.cgi?id=36202
        <rdar://problem/7761279>

        Based on an original patch by Mihai Parparita <mihaip@chromium.org>.

        Reviewed by Brent Fulgham.

        Tests: fast/loader/remove-iframe-during-history-navigation-different.html
               fast/loader/remove-iframe-during-history-navigation-same.html
               fast/loader/stateobjects/popstate-is-asynchronous.html

        * dom/Document.cpp:
        (WebCore::Document::enqueuePopstateEvent):
        Use enqueueWindowEvent().

2015-11-12  Csaba Osztrogonác  <ossy@webkit.org>

        Fix build failure due to missing NeverDestroyed.h include after r192169
        https://bugs.webkit.org/show_bug.cgi?id=151186

        Reviewed by Darin Adler.

        * rendering/RenderCombineText.cpp:

2015-11-12  Csaba Osztrogonác  <ossy@webkit.org>

        Fix build failure due to missing forward declaration of FontVariantSettings after r191968
        https://bugs.webkit.org/show_bug.cgi?id=151185

        Reviewed by Myles C. Maxfield.

        * css/CSSFontFaceSource.h:

2015-11-12  Eric Carlson  <eric.carlson@apple.com>

        [MediaStream] Reflect media stream tracks as HTMLMediaElement tracks
        https://bugs.webkit.org/show_bug.cgi?id=151145

        Reviewed by Jer Noble.

        Test: fast/mediastream/MediaStream-video-element.html

        * WebCore.xcodeproj/project.pbxproj: Add new header files.

        * html/track/AudioTrack.h: Add comments to clean things up slightly.
        * html/track/VideoTrack.h: Ditto.

        Create a AudioTrackPrivateMediaStream or VideoTrackPrivateMediaStream for each track in
        the MediaStream.
        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:
        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::load): Call updateTracks.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::didAddTrack): Ditto.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::didRemoveTrack): Ditto.
        (WebCore::updateTracksOfType): New, template function to update audio or video tracks.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::updateTracks): New.

        * platform/mediastream/AudioTrackPrivateMediaStream.h: Added.

        * platform/mediastream/MediaStreamPrivate.cpp:
        (WebCore::MediaStreamPrivate::currentFrameImage): Fix a typo, early return if the track is
          not active OR there is no active video track.
        * platform/mediastream/MediaStreamPrivate.h:
        (WebCore::MediaStreamPrivate::activeVideoTrack): Accessor for active video track, if any.

        * platform/mediastream/VideoTrackPrivateMediaStream.h: Added.

        * platform/mediastream/mac/AVAudioCaptureSource.mm:
        (WebCore::AVAudioCaptureSource::updateStates): Set current states.

        * platform/mediastream/mac/AVMediaCaptureSource.mm:
        (WebCore::AVMediaCaptureSource::states): Set source ID.
        (WebCore::AVMediaCaptureSource::capabilities): Set source ID directly.

        * platform/mediastream/mac/AVVideoCaptureSource.mm:
        (WebCore::AVVideoCaptureSource::AVVideoCaptureSource):
        (WebCore::AVVideoCaptureSource::updateStates): Set states here instead of in the constructor.

        * platform/mock/MockRealtimeMediaSource.cpp:
        (WebCore::MockRealtimeMediaSource::capabilities): Set source ID directly.

        * platform/mock/MockRealtimeVideoSource.cpp:
        (WebCore::MockRealtimeVideoSource::updateStates): Set source type.

2015-11-12  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        XHR abort() event firing does not match spec
        https://bugs.webkit.org/show_bug.cgi?id=98404

        Reviewed by Darin Adler.

        Introducing explicit sendFlag as in the specification.
        Previously, sendFlag was computed using !!m_loader.
        But this does not work well for loadstart events since sendFlag should be true but m_loader is still null at that time.

        Updated abort event firing test according specification.
        For instance, compared to previously, the abort event is not fired in DONE state or if sendFlag is not set.

        Covered by rebased tests.

        * xml/XMLHttpRequest.cpp:
        (WebCore::XMLHttpRequest::callReadyStateChangeListener): Compute whether dispatching the load event before calling XHR readystatechange event callback.
        (WebCore::XMLHttpRequest::setWithCredentials): Replacing m_loader by m_sendFlag to align with the spec.
        (WebCore::XMLHttpRequest::open): Unsetting m_sendFlag..
        (WebCore::XMLHttpRequest::initSend): Replacing m_loader by m_sendFlag to align with the spec.
        (WebCore::XMLHttpRequest::createRequest): Setting m_sendFlag.
        (WebCore::XMLHttpRequest::abort): Checking m_sendFlag and updating code to follow the specification.
        (WebCore::XMLHttpRequest::genericError): Unsetting m_sendFlag.
        (WebCore::XMLHttpRequest::setRequestHeader): Replacing m_loader by m_sendFlag to align with the spec.
        (WebCore::XMLHttpRequest::didFinishLoading): Ditto.
        (WebCore::XMLHttpRequest::didReachTimeout): Ditto.
        * xml/XMLHttpRequest.h: Added m_sendFlag.

2015-11-12  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GStreamer] Use RunLoop::timer in MediaPlayerPrivateGStreamerBase for GL drawing
        https://bugs.webkit.org/show_bug.cgi?id=151099

        Reviewed by Philippe Normand.

        Instead of the GThreadSafeMainLoopSource.

        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
        (WebCore::MediaPlayerPrivateGStreamerBase::MediaPlayerPrivateGStreamerBase):
        (WebCore::MediaPlayerPrivateGStreamerBase::repaint):
        (WebCore::MediaPlayerPrivateGStreamerBase::triggerRepaint):
        (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase): Deleted.
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:

2015-11-12  Csaba Osztrogonác  <ossy@webkit.org>

        Remove ENABLE(SATURATED_LAYOUT_ARITHMETIC) guards
        https://bugs.webkit.org/show_bug.cgi?id=150972

        Reviewed by Darin Adler.

        * Configurations/FeatureDefines.xcconfig:
        * platform/LayoutUnit.h:
        (WebCore::operator*):
        (WebCore::LayoutUnit::LayoutUnit): Deleted.
        (WebCore::LayoutUnit::fromFloatCeil): Deleted.
        (WebCore::LayoutUnit::fromFloatFloor): Deleted.
        (WebCore::LayoutUnit::fromFloatRound): Deleted.
        (WebCore::LayoutUnit::ceil): Deleted.
        (WebCore::LayoutUnit::round): Deleted.
        (WebCore::LayoutUnit::floor): Deleted.
        (WebCore::LayoutUnit::setValue): Deleted.
        (WebCore::operator/): Deleted.
        (WebCore::operator+): Deleted.
        (WebCore::operator-): Deleted.
        (WebCore::operator+=): Deleted.
        (WebCore::operator-=): Deleted.
        * rendering/LayoutState.cpp:
        (WebCore::LayoutState::LayoutState):
        * rendering/LayoutState.h:
        (WebCore::LayoutState::LayoutState):
        * rendering/RenderView.h:

2015-11-11  Chris Dumez  <cdumez@apple.com>

        Stop passing a PassRefPtr to dispatchEvent()
        https://bugs.webkit.org/show_bug.cgi?id=151158

        Reviewed by Alex Christensen.

        Stop passing a PassRefPtr to dispatchEvent() because:
        1. PassRefPtr is legacy and should no longer be used
        2. We don't actually transfer ownership of the Event to the callee

        Pass a C++ reference instead.

2015-11-11  Chris Dumez  <cdumez@apple.com>

        Fix leaks in idbKeyFromInspectorObject()
        https://bugs.webkit.org/show_bug.cgi?id=151179

        Reviewed by Brian Burg.

        Fix leaks in idbKeyFromInspectorObject() that were caused by the
        NeverDestroyed<> not being marked as static.

        * inspector/InspectorIndexedDBAgent.cpp:

2015-11-11  Geoffrey Garen  <ggaren@apple.com>

        Rename handle.*Event to dispatch.*Event
        https://bugs.webkit.org/show_bug.cgi?id=151168

        Reviewed by Chris Dumez.

        * dom/Document.cpp:
        (WebCore::Document::implicitClose):
        * dom/Document.h:
        * loader/DocumentLoader.cpp:
        (WebCore::DocumentLoader::DocumentLoader):
        (WebCore::DocumentLoader::getIconDataForIconURL):
        (WebCore::DocumentLoader::dispatchOnloadEvents):
        (WebCore::DocumentLoader::handledOnloadEvents): Deleted.
        * loader/DocumentLoader.h:
        (WebCore::DocumentLoader::isClientRedirect):
        (WebCore::DocumentLoader::setIsClientRedirect):
        (WebCore::DocumentLoader::wasOnloadDispatched):
        (WebCore::DocumentLoader::overrideEncoding):
        (WebCore::DocumentLoader::wasOnloadHandled): Deleted.
        * loader/EmptyClients.h:
        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::submitForm):
        (WebCore::FrameLoader::stopLoading):
        (WebCore::FrameLoader::userAgent):
        (WebCore::FrameLoader::dispatchOnloadEvents):
        (WebCore::FrameLoader::frameDetached):
        (WebCore::FrameLoader::shouldClose):
        (WebCore::FrameLoader::dispatchUnloadEvents):
        (WebCore::FrameLoader::dispatchBeforeUnloadEvent):
        (WebCore::FrameLoader::handledOnloadEvents): Deleted.
        (WebCore::FrameLoader::handleUnloadEvents): Deleted.
        (WebCore::FrameLoader::handleBeforeUnloadEvent): Deleted.
        * loader/FrameLoader.h:
        * loader/FrameLoaderClient.h:
        * loader/NavigationScheduler.cpp:
        (WebCore::NavigationScheduler::mustLockBackForwardList):

2015-11-11  Anders Carlsson  <andersca@apple.com>

        Remove more dead code
        https://bugs.webkit.org/show_bug.cgi?id=151170

        Reviewed by Beth Dakin.

        * platform/ContextMenu.cpp:
        (WebCore::findItemWithAction): Deleted.
        (WebCore::ContextMenu::itemWithAction): Deleted.
        * platform/ContextMenu.h:
        (WebCore::ContextMenu::itemAtIndex): Deleted.
        * platform/ContextMenuItem.h:

2015-11-11  Anders Carlsson  <andersca@apple.com>

        De-indent ContextMenu.h and ContextMenuItem.h.

        Rubber-stamped by Andreas Kling.

        * platform/ContextMenu.h:
        * platform/ContextMenuItem.h:

2015-11-11  Anders Carlsson  <andersca@apple.com>

        Remove ContextMenuWin.cpp and ContextMenuItemWin.cpp
        https://bugs.webkit.org/show_bug.cgi?id=150467

        Reviewed by Beth Dakin.

        These files are not needed anymore.

        * PlatformWin.cmake:
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * platform/win/ContextMenuItemWin.cpp: Removed.
        (WebCore::ContextMenuItem::ContextMenuItem): Deleted.
        (WebCore::ContextMenuItem::platformContextMenuItem): Deleted.
        * platform/win/ContextMenuWin.cpp: Removed.
        (WebCore::ContextMenu::ContextMenu): Deleted.
        (WebCore::ContextMenu::getContextMenuItems): Deleted.
        (WebCore::ContextMenu::createPlatformContextMenuFromItems): Deleted.
        (WebCore::ContextMenu::platformContextMenu): Deleted.

2015-11-11  Anders Carlsson  <andersca@apple.com>

        Get rid of ContextMenuNone.cpp and ContextMenuItemNone.cpp
        https://bugs.webkit.org/show_bug.cgi?id=151169

        Reviewed by Beth Dakin.

        * PlatformEfl.cmake:
        * platform/ContextMenuItemNone.cpp: Removed.
        (WebCore::ContextMenuItem::platformContextMenuItem): Deleted.
        * platform/ContextMenuNone.cpp: Removed.
        (WebCore::ContextMenu::ContextMenu): Deleted.
        (WebCore::ContextMenu::getContextMenuItems): Deleted.
        (WebCore::ContextMenu::createPlatformContextMenuFromItems): Deleted.
        (WebCore::ContextMenu::platformContextMenu): Deleted.

2015-11-11  Anders Carlsson  <andersca@apple.com>

        Remove more dead context menu code
        https://bugs.webkit.org/show_bug.cgi?id=151163

        Reviewed by Tim Horton.

        * loader/EmptyClients.h:
        * page/ContextMenuClient.h:
        * page/ContextMenuController.cpp:
        (WebCore::ContextMenuController::populate):
        * platform/ContextMenuItem.h:
        * platform/mac/ContextMenuItemMac.mm:
        (WebCore::ContextMenuItem::shareMenuItem): Deleted.

2015-11-10  Jon Honeycutt  <jhoneycutt@apple.com>

        Crash loading Blink layout test fast/parser/strip-script-attrs-on-input.html
        https://bugs.webkit.org/show_bug.cgi?id=150201
        <rdar://problem/23136478>

        Reviewed by Brent Fulgham.

        Test: fast/parser/strip-script-attrs-on-input.html

        * html/parser/HTMLTreeBuilder.cpp:
        (WebCore::HTMLTreeBuilder::processStartTagForInBody):
        Get the attribute after calling
        HTMLConstructionSite::insertSelfClosingHTMLElement(), as this may
        mutate the token's attributes.

2015-11-11  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Remove bind usage
        https://bugs.webkit.org/show_bug.cgi?id=151104

        Reviewed by Youenn Fablet.

        Instead of using bind, an inline error function was created.

        Internal rework, no tests needed.

        * Modules/streams/WritableStream.js:
        (error):
        (initializeWritableStream):

2015-11-10  Brady Eidson  <beidson@apple.com>

        Modern IDB: Make indexes actually index.
        https://bugs.webkit.org/show_bug.cgi?id=150939

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/index-1.html
               storage/indexeddb/modern/index-2.html
               storage/indexeddb/modern/index-3.html

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:

        * Modules/indexeddb/IDBKeyData.h:
        (WebCore::IDBKeyData::hash): Deleted.

        * Modules/indexeddb/IDBKeyRangeData.cpp:
        (WebCore::IDBKeyRangeData::isExactlyOneKey):

        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::didGetRecordOnServer):

        * Modules/indexeddb/server/IndexValueEntry.cpp: Copied from Source/WebCore/Modules/indexeddb/server/MemoryIndex.cpp.
        (WebCore::IDBServer::IndexValueEntry::IndexValueEntry):
        (WebCore::IDBServer::IndexValueEntry::~IndexValueEntry):
        (WebCore::IDBServer::IndexValueEntry::addKey):
        (WebCore::IDBServer::IndexValueEntry::removeKey):
        (WebCore::IDBServer::IndexValueEntry::getLowest):
        (WebCore::IDBServer::IndexValueEntry::getCount):
        * Modules/indexeddb/server/IndexValueEntry.h: Copied from Source/WebCore/Modules/indexeddb/server/MemoryIndex.h.

        * Modules/indexeddb/server/IndexValueStore.cpp: Added.
        (WebCore::IDBServer::IndexValueStore::IndexValueStore):
        (WebCore::IDBServer::IndexValueStore::lowestValueForKey):
        (WebCore::IDBServer::IndexValueStore::countForKey):
        (WebCore::IDBServer::IndexValueStore::contains):
        (WebCore::IDBServer::IndexValueStore::addRecord):
        (WebCore::IDBServer::IndexValueStore::removeRecord):
        (WebCore::IDBServer::IndexValueStore::removeEntriesWithValueKey):
        (WebCore::IDBServer::IndexValueStore::lowestKeyWithRecordInRange):
        * Modules/indexeddb/server/IndexValueStore.h: Copied from Source/WebCore/Modules/indexeddb/server/MemoryIndex.h.

        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::objectStoreCleared):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::indexCleared):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:

        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::addRecord):

        * Modules/indexeddb/server/MemoryIndex.cpp:
        (WebCore::IDBServer::MemoryIndex::create):
        (WebCore::IDBServer::MemoryIndex::MemoryIndex):
        (WebCore::IDBServer::MemoryIndex::objectStoreCleared):
        (WebCore::IDBServer::MemoryIndex::replaceIndexValueStore):
        (WebCore::IDBServer::MemoryIndex::getResultForKeyRange):
        (WebCore::IDBServer::MemoryIndex::countForKeyRange):
        (WebCore::IDBServer::MemoryIndex::putIndexKey):
        (WebCore::IDBServer::MemoryIndex::removeRecord):
        (WebCore::IDBServer::MemoryIndex::removeEntriesWithValueKey):
        (WebCore::IDBServer::MemoryIndex::valueForKeyRange): Deleted.
        * Modules/indexeddb/server/MemoryIndex.h:

        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::createIndex):
        (WebCore::IDBServer::MemoryObjectStore::clear):
        (WebCore::IDBServer::MemoryObjectStore::deleteRecord):
        (WebCore::IDBServer::MemoryObjectStore::addRecord):
        (WebCore::IDBServer::indexVM):
        (WebCore::IDBServer::indexGlobalExec):
        (WebCore::IDBServer::MemoryObjectStore::updateIndexesForDeleteRecord):
        (WebCore::IDBServer::MemoryObjectStore::updateIndexesForPutRecord):
        (WebCore::IDBServer::MemoryObjectStore::indexValueForKeyRange):
        * Modules/indexeddb/server/MemoryObjectStore.h:
        (WebCore::IDBServer::MemoryObjectStore::writeTransaction):

        * Modules/indexeddb/shared/IndexKey.cpp: Copied from Source/WebCore/Modules/indexeddb/IDBKeyRangeData.cpp.
        (WebCore::IndexKey::IndexKey):
        (WebCore::IndexKey::isolatedCopy):
        (WebCore::IndexKey::asOneKey):
        (WebCore::IndexKey::multiEntry):
        * Modules/indexeddb/shared/IndexKey.h: Added.
        (WebCore::IndexKey::isNull):

        * bindings/js/IDBBindingUtilities.cpp:
        (WebCore::idbValueDataToJSValue):
        (WebCore::deserializeIDBValueBuffer):
        (WebCore::idbKeyDataToScriptValue):
        (WebCore::createKeyPathArray):
        (WebCore::generateIndexKeyForValue):
        * bindings/js/IDBBindingUtilities.h:

2015-11-10  Myles C. Maxfield  <mmaxfield@apple.com>

        Move locale information into FontDescription
        https://bugs.webkit.org/show_bug.cgi?id=147457

        Reviewed by Andreas Kling.

        Currently, the "lang" attribute on a node sets locale information in RenderStyle.
        Font selection is sensitive to this locale information, and occurs deep within
        platform/ code, far away from RenderStyle. Because every RenderStyle owns a
        FontDescription, and font selection can consult with FontDescriptions, it makes
        sense to move the variable from RenderStyle to FontDescription, and provide
        convenience methods on RenderStyle which inspect its FontDescription for locale
        information.

        This patch is in preparation for correctly obeying locale information when
        performing font fallback.

        No new tests because there is no behavior change.

        * css/CSSPropertyNames.in:
        * css/StyleBuilderCustom.h:
        (WebCore::StyleBuilderCustom::applyValueWebkitLocale):
        * platform/graphics/FontCache.h:
        * platform/graphics/FontDescription.cpp:
        (WebCore::FontDescription::setLocale):
        * platform/graphics/FontDescription.h:
        (WebCore::FontDescription::locale):
        (WebCore::FontDescription::operator==):
        (WebCore::FontCascadeDescription::initialLocale):
        (WebCore::FontDescription::setScript): Deleted.
        * rendering/style/RenderStyle.cpp:
        (WebCore::RenderStyle::changeRequiresLayout): Deleted.
        * rendering/style/RenderStyle.h:
        * rendering/style/StyleRareInheritedData.cpp:
        (WebCore::StyleRareInheritedData::StyleRareInheritedData): Deleted.
        (WebCore::StyleRareInheritedData::operator==): Deleted.
        * rendering/style/StyleRareInheritedData.h:
        * style/StyleResolveForDocument.cpp:
        (WebCore::Style::resolveForDocument):

2015-11-10  Gyuyoung Kim  <gyuyoung.kim@webkit.org>

        [EFL] Support an applicationVersion argument to UserAgentEfl::standardUserAgent() 
        https://bugs.webkit.org/show_bug.cgi?id=151060

        Reviewed by Darin Adler.

        *applicationVersion* was missed to support by r192148. This patch adds it as well as
        missed Darin comments are fixed.

        * platform/efl/UserAgentEfl.cpp:
        (WebCore::platformVersionForUAString):
        (WebCore::versionForUAString):
        (WebCore::standardUserAgent):

2015-11-10  Simon Fraser  <simon.fraser@apple.com>

        Use different pixel formats for displays that support them
        https://bugs.webkit.org/show_bug.cgi?id=151122
        rdar://problem/22846841

        Reviewed by Tim Horton.

        Add new IOSurface format enum values, and set up the appropriate IOSurfaceCreate()
        property dictionaries for them.

        * platform/graphics/cocoa/IOSurface.h:
        * platform/graphics/cocoa/IOSurface.mm:
        (IOSurface::IOSurface):
        * platform/spi/cocoa/IOSurfaceSPI.h:

2015-11-10  Brent Fulgham  <bfulgham@apple.com>

        Crash running webaudio/panner-loop.html
        https://bugs.webkit.org/show_bug.cgi?id=150200
        <rdar://problem/23136282>

        Reviewed by Jer Noble.

        Test: webaudio/panner-loop.html

        This is based on the changes in Blink r164822:
        https://codereview.chromium.org/130003002

        Avoid infinitely recursing on audio nodes by keeping track of which nodes we've already
        visited.

        * Modules/webaudio/PannerNode.cpp:
        (WebCore::PannerNode::pullInputs): Pass set of visited nodes so we don't revisit
        nodes we've already serviced.
        (WebCore::PannerNode::notifyAudioSourcesConnectedToNode): Accept visitedNodes argument
        so we can avoid revisiting nodes. Check if the current node has already been visited
        before processing it.
        * Modules/webaudio/PannerNode.h:

2015-11-10  Tim Horton  <timothy_horton@apple.com>

        Adopt formal protocols for CA delegates
        https://bugs.webkit.org/show_bug.cgi?id=151121
        <rdar://problem/6739193>

        Reviewed by Anders Carlsson.

        * platform/graphics/cocoa/WebActionDisablingCALayerDelegate.h:
        Note that our WebActionDisablingCALayerDelegate is, in fact, a CALayerDelegate.

        * platform/spi/cocoa/QuartzCoreSPI.h:
        Add empty protocol definitions where necessary.

        * WebCore.xcodeproj/project.pbxproj:
        * platform/spi/mac/NSAccessibilitySPI.h: Added.
        * platform/spi/mac/NSApplicationSPI.h: Added.
        * platform/spi/mac/NSTextFinderSPI.h: Added.
        * platform/spi/mac/NSViewSPI.h: Added.
        Split out SPI headers from WebKit2's AppKitSPI.h.
        Add NSViewSPI to note that NSView is (internally) a CALayerDelegate,
        which WebHTMLView depends on.

2015-11-10  Zalan Bujtas  <zalan@apple.com>

        Continuations with anonymous wrappers inside misplaces child renderers.
        https://bugs.webkit.org/show_bug.cgi?id=150908

        When a child is appended to an inline container and the beforeChild is not a direct child, but 
        it is inside a generated subtree, we need to special case the inline split to form continuation.

        RenderInline::splitInlines() assumes that beforeChild is always a direct child of the current
        inline container. However when beforeChild type requires wrapper content (such as table cells), the DOM and the
        render tree get out of sync. In such cases, we need to ensure that both the beforeChild and its siblings end up
        in the correct generated block.

        Reviewed by Darin Adler and David Hyatt.

        Test: fast/inline/continuation-with-anon-wrappers.html

        * rendering/RenderInline.cpp:
        (WebCore::RenderInline::splitInlines):
        (WebCore::RenderInline::addChildToContinuation):

2015-11-10  Geoffrey Garen  <ggaren@apple.com>

        alert, confirm, prompt, showModalDialog should be forbidden during page close and navigation
        https://bugs.webkit.org/show_bug.cgi?id=150980

        Reviewed by Chris Dumez.

        Tests: fast/events/beforeunload-alert.html
               fast/events/beforeunload-confirm.html
               fast/events/beforeunload-prompt.html
               fast/events/beforeunload-showModalDialog.html
               fast/events/pagehide-alert.html
               fast/events/pagehide-confirm.html
               fast/events/pagehide-prompt.html
               fast/events/pagehide-showModalDialog.html
               fast/events/unload-alert.html
               fast/events/unload-confirm.html
               fast/events/unload-prompt.html
               fast/events/unload-showModalDialog.html

        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::stopLoading): Factored out a helper function for
        unload event processing.
        (WebCore::FrameLoader::handleUnloadEvents): Forbid prompts in unload
        events just like we do in beforeunload events, and for the same reasons.

        (WebCore::FrameLoader::handleBeforeUnloadEvent): Updated for renames.

        * loader/FrameLoader.h:

        * page/DOMWindow.cpp:
        (WebCore::DOMWindow::print):
        (WebCore::DOMWindow::alert):
        (WebCore::DOMWindow::confirm):
        (WebCore::DOMWindow::prompt):
        (WebCore::DOMWindow::showModalDialog): Updated for renames. Refactored
        some of this code to handle null pages more cleanly. In particular, we
        sometimes used to treat null page as "everything is permitted" -- but it
        is best practice in a permissions context to treat lack of information
        as no permission granted rather than all permissions granted. (I don't
        know of a way to trigger this condition in practice.)

        * page/Page.cpp:
        (WebCore::Page::Page):
        (WebCore::Page::forbidPrompts):
        (WebCore::Page::allowPrompts):
        (WebCore::Page::arePromptsAllowed): Renamed to make these functions
        reflect their new, broader context.

        (WebCore::Page::incrementFrameHandlingBeforeUnloadEventCount): Deleted.
        (WebCore::Page::decrementFrameHandlingBeforeUnloadEventCount): Deleted.
        (WebCore::Page::isAnyFrameHandlingBeforeUnloadEvent): Deleted.

        * page/Page.h:

2015-11-09  David Hyatt  <hyatt@apple.com>

        tate-chu-yoko should shrink to fit when it exceeds the available width.
        <rdar://problem/12130468>
        https://bugs.webkit.org/show_bug.cgi?id=151051

        Reviewed by Myles Maxfield.

        Covered by existing tests

        * rendering/RenderCombineText.cpp:
        (WebCore::RenderCombineText::combineText):

        When testing for text-combine, find the font variant that is the best fit, i.e.,
        that exceeds the available width by the smallest amount. Scale that best fit down
        repeatedly until it fits within the available space. We set a pixel size of 6 as
        the threshold at which we give up.

        Also make sure to reset glyphOverflow on each measurement, as this was creating
        a potential bug both with variant checking and then with scaling, since glyphOverflow
        isn't reset when width() is invoked.

2015-11-10  Myles C. Maxfield  <mmaxfield@apple.com>

        Tatechuyoko text is not vertically centered in its vertical advance
        https://bugs.webkit.org/show_bug.cgi?id=151074
        <rdar://problem/20074305>

        Reviewed by David Hyatt.

        During paint time, the run origin of tatechuyoko needs to be adjusted to compensate for the
        rotation of the writing mode. The calculation which performed this adjustment was incorrect.

        It is incorrect for two reasons:
        1. It used the existing text origin, which had the font's ascent incorporated in it, but did
        not compensate by either inspecting the overflow bounds' ascent nor the font's ascent proper.
        2. It did not distinguish between the overflow bounds' ascent vs. descent. Instead, it added
        them together and treated both values together.

        No new tests yet. I need to make a font to test this.

        * rendering/InlineTextBox.cpp:
        (WebCore::InlineTextBox::paint):
        * rendering/RenderCombineText.cpp:
        (WebCore::RenderCombineText::computeTextOrigin):
        (WebCore::RenderCombineText::combineText):
        (WebCore::RenderCombineText::adjustTextOrigin): Deleted.
        * rendering/RenderCombineText.h:

2015-11-10  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        XMLHttpRequestUpload should support ontimeout event handler
        https://bugs.webkit.org/show_bug.cgi?id=128531

        Reviewed by Darin Adler.

        Covered by rebased tests.

        * xml/XMLHttpRequestUpload.idl: Adding ontimeout event handler.

2015-11-10  Zalan Bujtas  <zalan@apple.com>

        Force display: block on ::-webkit-media-controls.
        https://bugs.webkit.org/show_bug.cgi?id=149178
        <rdar://problem/23448397>

        Reviewed by Simon Fraser.

        This patch ensures that we always have a block level container for media controls
        so that continuation never needs to split RenderMedia into multiple subtrees.

        Current inline continuation logic assumes that only inline elements with RenderInline
        type of renderers participate in continuation. This is mostly the case since other inline renderers
        such as RenderReplaced, RenderImage, RenderEmbeddedObject etc can't have (accessible) children.
        (Unlike video::-webkit-media-controls)

        Test: media/webkit-media-controls-display.html

        * Modules/mediacontrols/mediaControlsApple.css:
        (::-webkit-media-controls):
        * Modules/mediacontrols/mediaControlsiOS.css:
        (::-webkit-media-controls):
        * css/mediaControls.css:
        (::-webkit-media-controls):

2015-11-10  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GTK] Use CROSS_PLATFORM_CONTEXT_MENUS
        https://bugs.webkit.org/show_bug.cgi?id=150642

        Reviewed by Martin Robinson.

        Remove GTK+ implementations of old context menu classes.

        * PlatformGTK.cmake:
        * platform/ContextMenuItem.h:
        * platform/gtk/ContextMenuGtk.cpp: Removed.
        * platform/gtk/ContextMenuItemGtk.cpp: Removed.

2015-11-10  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Fix style issues
        https://bugs.webkit.org/show_bug.cgi?id=151089

        Reviewed by Youenn Fablet.

        Inlined some things, converted var into let and const, removed some undefined parameters and returns, added
        missing "use strict" clauses and other minor style changes.

        Internal rework, no new tests needed.

        * Modules/streams/ReadableStream.js:
        (initializeReadableStream):
        * Modules/streams/ReadableStreamController.js:
        (enqueue):
        (error):
        (close):
        * Modules/streams/ReadableStreamInternals.js:
        (teeReadableStream):
        (teeReadableStreamPullFunction):
        (teeReadableStreamBranch2CancelFunction):
        (errorReadableStream):
        (finishClosingReadableStream):
        (closeReadableStreamReader):
        (enqueueInReadableStream):
        (readFromReadableStreamReader):
        * Modules/streams/ReadableStreamReader.js:
        (releaseLock):
        * Modules/streams/StreamInternals.js:
        (invokeOrNoop):
        (promiseInvokeOrNoop):
        (promiseInvokeOrFallbackOrNoop):
        (validateAndNormalizeQueuingStrategy):
        (newQueue):
        (dequeueValue):
        (enqueueValueWithSize):
        (peekQueueValue):
        * Modules/streams/WritableStream.js:
        (initializeWritableStream):
        (abort):
        (close):
        * Modules/streams/WritableStreamInternals.js:
        (syncWritableStreamStateWithQueue):
        (errorWritableStream):
        (callOrScheduleWritableStreamAdvanceQueue):
        (writableStreamAdvanceQueue):
        (closeWritableStream): Deleted.

2015-11-10  Carlos Garcia Campos  <cgarcia@igalia.com>

        Unreviewed. Fix scrollbars/custom-scrollbar-appearance-property.html after r191991.

        Use a similar fix to the mac one.

        * rendering/RenderThemeGtk.cpp:
        (WebCore::centerRectVerticallyInParentInputElement):

2015-11-10  Csaba Osztrogonác  <ossy@webkit.org>

        Unreviewed speculative buildfix after r192200.

        * platform/mock/MediaPlaybackTargetPickerMock.cpp:
        (WebCore::MediaPlaybackTargetPickerMock::showPlaybackTargetPicker):

2015-11-10  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Shield promises when prototype is replaced from a promise
        https://bugs.webkit.org/show_bug.cgi?id=151033

        Reviewed by Darin Adler.

        Instead of calling @then or @catch, that could have disappeared if the user successfully replaces a promise
        constructor, we call the methods stored at @Promise.prototype, which are safe as @Promise.prototype.@then.@call
        and @Promise.prototype.@catch.@call.

        Test: streams/streams-promises.html, expectations updated.

        * Modules/streams/ReadableStream.js:
        (initializeReadableStream):
        * Modules/streams/ReadableStreamInternals.js:
        (teeReadableStream):
        (teeReadableStreamPullFunction):
        (teeReadableStreamBranch2CancelFunction):
        (cancelReadableStream):
        * Modules/streams/WritableStream.js:
        (initializeWritableStream):
        (abort):
        * Modules/streams/WritableStreamInternals.js:
        (callOrScheduleWritableStreamAdvanceQueue):

2015-11-10  Jon Lee  <jonlee@apple.com>

        REGRESSION (r189567): Inline controls on Mac are misplaced
        https://bugs.webkit.org/show_bug.cgi?id=151072

        Reviewed by Eric Carlson.

        Test: media/controls/fullscreen-button-inline-layout.html

        For a certain range of video widths, r189567 caused the timeline track to be
        too large, pushing the buttons on the right side of the inline controls out of
        the rect bounds.

        The fix is to set min-width to 0. The test added checks to see that the right
        edge of the fullscreen button is within the rect bounds.

        * Modules/mediacontrols/mediaControlsApple.css:
        (audio::-webkit-media-controls-timeline-container): Add min-width.
        (audio::-webkit-media-controls-panel .thumbnail-track): Ditto. Fly-by fix of height rule.

2015-11-09  Eric Carlson  <eric.carlson@apple.com>

        [Mac] Add a mock AppleTV device for testing
        https://bugs.webkit.org/show_bug.cgi?id=148912
        <rdar://problem/22596272>

        Reviewed by Tim Horton.

        No new tests, updated media/controls/airplay-picker.html.

        * Modules/mediasession/WebMediaSessionManager.cpp:
        (WebCore::WebMediaSessionManager::setMockMediaPlaybackTargetPickerEnabled): New, enable or disable
          the mock picker.
        (WebCore::WebMediaSessionManager::setMockMediaPlaybackTargetPickerState): New, set mock picker state.
        (WebCore::WebMediaSessionManager::mockPicker): New.
        (WebCore::WebMediaSessionManager::targetPicker): Return the platform or mock picker, as per settings.
        (WebCore::webMediaSessionManagerOverride): Deleted.
        (WebCore::WebMediaSessionManager::shared): Deleted.
        (WebCore::WebMediaSessionManager::setWebMediaSessionManagerOverride): Deleted.
        * Modules/mediasession/WebMediaSessionManager.h:

        * WebCore.xcodeproj/project.pbxproj: Add MediaPlaybackTargetPickerMock.* and MediaPlaybackTargetMock.*.

        * page/ChromeClient.h: add setMockMediaPlaybackTargetPickerEnabled and setMockMediaPlaybackTargetPickerState.

        * page/Page.cpp:
        (WebCore::Page::playbackTargetPickerClientStateDidChange):
        (WebCore::Page::setMockMediaPlaybackTargetPickerEnabled): New.
        (WebCore::Page::setMockMediaPlaybackTargetPickerState): New.
        (WebCore::Page::setPlaybackTarget):
        * page/Page.h:

        * platform/graphics/MediaPlaybackTarget.h:
        (WebCore::noMediaPlaybackTargetContext):
        (WebCore::MediaPlaybackTarget::~MediaPlaybackTarget):
        (WebCore::MediaPlaybackTarget::deviceName):
        (WebCore::MediaPlaybackTarget::MediaPlaybackTarget):

        * platform/graphics/MediaPlaybackTargetContext.h: Make a class instead of a struct.
        (WebCore::MediaPlaybackTargetContext::MediaPlaybackTargetContext):
        (WebCore::MediaPlaybackTargetContext::type):
        (WebCore::MediaPlaybackTargetContext::mockDeviceName):
        (WebCore::MediaPlaybackTargetContext::mockState):
        (WebCore::MediaPlaybackTargetContext::avOutputContext):
        (WebCore::MediaPlaybackTargetContext::encodingRequiresPlatformData):

        * platform/graphics/MediaPlaybackTargetPicker.cpp: Move much of the code from MediaPlaybackTargetMac.mm
          here so it can be the base class.
        (WebCore::MediaPlaybackTargetPicker::MediaPlaybackTargetPicker):
        (WebCore::MediaPlaybackTargetPicker::~MediaPlaybackTargetPicker):
        (WebCore::MediaPlaybackTargetPicker::pendingActionTimerFired):
        (WebCore::MediaPlaybackTargetPicker::addPendingAction):
        (WebCore::MediaPlaybackTargetPicker::showPlaybackTargetPicker):
        * platform/graphics/MediaPlaybackTargetPicker.h:
        (WebCore::MediaPlaybackTargetPicker::availableDevicesDidChange):
        (WebCore::MediaPlaybackTargetPicker::currentDeviceDidChange):
        (WebCore::MediaPlaybackTargetPicker::client):
        (WebCore::MediaPlaybackTargetPicker::setClient):

        * platform/graphics/avfoundation/MediaPlaybackTargetMac.h:
        (WebCore::MediaPlaybackTargetMac::outputContext):
        (WebCore::MediaPlaybackTargetMac::targetType): Deleted.
        * platform/graphics/avfoundation/MediaPlaybackTargetMac.mm:
        (WebCore::MediaPlaybackTargetMac::targetContext):
        (WebCore::MediaPlaybackTargetMac::hasActiveRoute):
        (WebCore::MediaPlaybackTargetMac::deviceName):

        * platform/graphics/avfoundation/WebMediaSessionManagerMac.cpp:
        (WebCore::WebMediaSessionManager::shared): Renamed from platformManager.
        (WebCore::WebMediaSessionManagerMac::platformPicker): Renamed from targetPicker.
        (WebCore::WebMediaSessionManager::platformManager): Deleted.
        (WebCore::WebMediaSessionManagerMac::targetPicker): Deleted.
        * platform/graphics/avfoundation/WebMediaSessionManagerMac.h:

        * platform/graphics/avfoundation/objc/MediaPlaybackTargetPickerMac.h:
        * platform/graphics/avfoundation/objc/MediaPlaybackTargetPickerMac.mm:
        (WebCore::MediaPlaybackTargetPickerMac::MediaPlaybackTargetPickerMac):
        (WebCore::MediaPlaybackTargetPickerMac::~MediaPlaybackTargetPickerMac):
        (WebCore::MediaPlaybackTargetPickerMac::externalOutputDeviceAvailable):
        (WebCore::MediaPlaybackTargetPickerMac::playbackTarget):
        (WebCore::MediaPlaybackTargetPickerMac::devicePicker):
        (WebCore::MediaPlaybackTargetPickerMac::showPlaybackTargetPicker):
        (WebCore::MediaPlaybackTargetPickerMac::startingMonitoringPlaybackTargets):
        (WebCore::MediaPlaybackTargetPickerMac::pendingActionTimerFired): Deleted.
        (WebCore::MediaPlaybackTargetPickerMac::availableDevicesDidChange): Deleted.
        (WebCore::MediaPlaybackTargetPickerMac::addPendingAction): Deleted.
        (WebCore::MediaPlaybackTargetPickerMac::currentDeviceDidChange): Deleted.

        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
        (WebCore::MediaPlayerPrivateAVFoundationObjC::isCurrentPlaybackTargetWireless): Add support for
          mock target.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::wirelessPlaybackTargetName): Ditto.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::setWirelessPlaybackTarget): Ditto.
        (WebCore::MediaPlayerPrivateAVFoundationObjC::setShouldPlayToPlaybackTarget): Ditto.

        * platform/mock/MediaPlaybackTargetMock.cpp: Added.
        (WebCore::MediaPlaybackTargetMock::create): 
        (WebCore::MediaPlaybackTargetMock::MediaPlaybackTargetMock):
        (WebCore::MediaPlaybackTargetMock::~MediaPlaybackTargetMock):
        (WebCore::MediaPlaybackTargetMock::targetContext):
        (WebCore::toMediaPlaybackTargetMock):
        * platform/mock/MediaPlaybackTargetMock.h: Added.

        * platform/mock/MediaPlaybackTargetPickerMock.cpp: Added.
        (WebCore::MediaPlaybackTargetPickerMock::create):
        (WebCore::MediaPlaybackTargetPickerMock::MediaPlaybackTargetPickerMock):
        (WebCore::MediaPlaybackTargetPickerMock::~MediaPlaybackTargetPickerMock):
        (WebCore::MediaPlaybackTargetPickerMock::externalOutputDeviceAvailable):
        (WebCore::MediaPlaybackTargetPickerMock::playbackTarget):
        (WebCore::MediaPlaybackTargetPickerMock::timerFired):
        (WebCore::MediaPlaybackTargetPickerMock::showPlaybackTargetPicker):
        (WebCore::MediaPlaybackTargetPickerMock::startingMonitoringPlaybackTargets):
        (WebCore::MediaPlaybackTargetPickerMock::stopMonitoringPlaybackTargets):
        (WebCore::MediaPlaybackTargetPickerMock::invalidatePlaybackTargets):
        (WebCore::MediaPlaybackTargetPickerMock::setState):
        * platform/mock/MediaPlaybackTargetPickerMock.h: Added.

        * testing/Internals.cpp:
        (WebCore::Internals::Internals):
        (WebCore::Internals::setMockMediaPlaybackTargetPickerEnabled):
        (WebCore::Internals::setMockMediaPlaybackTargetPickerState):
        * testing/Internals.h:
        * testing/Internals.idl:

2015-11-09  Wenson Hsieh  <wenson_hsieh@apple.com>

        Unreviewed, fix the windows build

        Update the signature of scrollableAreaBoundingBox, changed by r192193.

        * platform/win/PopupMenuWin.cpp:
        (WebCore::PopupMenuWin::scrollableAreaBoundingBox):
        * platform/win/PopupMenuWin.h:

2015-11-09  Simon Fraser  <simon.fraser@apple.com>

        Allow iOS to create linearRGB colorspaces
        https://bugs.webkit.org/show_bug.cgi?id=151059

        Reviewed by Tim Horton.

        Remove iOS #ifdefs around code that creates linearized RGB colorspaces, as used
        by SVG filters. Blending doesn't actually work correctly, but there's no reason
        to #ifdef differently here.

        * platform/graphics/cg/GraphicsContextCG.cpp:
        * platform/graphics/mac/GraphicsContextMac.mm:
        (WebCore::linearRGBColorSpaceRef):

2015-11-09  Wenson Hsieh  <wenson_hsieh@apple.com>

        Sometimes unable to scroll fixed div when the body is scrollable
        https://bugs.webkit.org/show_bug.cgi?id=151015
        <rdar://problem/23445723>

        Reviewed by Simon Fraser.

        Currently, if we scroll a page containing a fixed scrollable area, the non-fast-scrollable region corresponding to a fixed
        area will not move down to reflect its new bounds in absolute coordinates, making it impossible to scroll position: fixed
        overflow elements when the body's scroll position changes. To fix this, we inflate the non-fast-scrollable region
        corresponding to scrollable position: fixed elements such that their regions encompass the area, relative to the page,
        wherein the fixed element may lie when the page is scrolled by any amount within its scroll limits.

        We also optimize the non-fast-scrollable regions emitted by elements that handle wheel events. Currently, if a fixed element
        also has a wheel event handler, we take the entire document's rect to be non-fast-scrollable. This patch changes this region
        to behave the same way as fixed scrollable elements above.

        This patch also folds some common logic used to accomplish this into FrameView for use by RenderLayerCompositor and RenderView.

        Test: tiled-drawing/scrolling/non-fast-region/fixed-div-in-scrollable-page.html

        * page/FrameView.cpp:
        (WebCore::FrameView::fixedScrollableAreaBoundsInflatedForScrolling):
        (WebCore::FrameView::scrollOffsetRespectingCustomFixedPosition):
        * page/FrameView.h:
        * page/scrolling/ScrollingCoordinator.cpp:
        (WebCore::ScrollingCoordinator::absoluteNonFastScrollableRegionForFrame):
        * platform/ScrollableArea.h:
        (WebCore::ScrollableArea::scrollableAreaBoundingBox):
        * rendering/RenderLayer.cpp:
        (WebCore::RenderLayer::scrollableAreaBoundingBox):
        * rendering/RenderLayer.h:
        * rendering/RenderLayerCompositor.cpp:
        (WebCore::RenderLayerCompositor::computeExtent):
        (WebCore::fixedPositionOffset): Deleted.
        * rendering/RenderView.cpp:
        (WebCore::RenderView::mapLocalToContainer):
        (WebCore::RenderView::pushMappingToContainer):
        (WebCore::RenderView::mapAbsoluteToLocalPoint):
        (WebCore::RenderView::computeRectForRepaint):
        (WebCore::fixedPositionOffset): Deleted.

2015-11-09  Ryan Haddad  <ryanhaddad@apple.com>

        Unreviewed, rolling out r192181.

        This change causes asserts on mac-wk1 debug testers

        Reverted changeset:

        "Fixed crash loading Mozilla layout test
        editor/libeditor/crashtests/431086-1.xhtml."
        https://bugs.webkit.org/show_bug.cgi?id=150252
        http://trac.webkit.org/changeset/192181

2015-11-09  Jiewen Tan  <jiewen_tan@apple.com>

        Crash when right clicking in input box with -webkit-user-select: none
        https://bugs.webkit.org/show_bug.cgi?id=145981
        <rdar://problem/22441925>

        Reviewed by Enrica Casucci.

        Test: editing/selection/minimal-user-select-crash.html

        * editing/Editor.cpp:
        (WebCore::Editor::hasBidiSelection):
        Visible position cannot be created because of the style that doesn't allow the selection.

2015-11-09  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: $0 stops working after navigating to a different domain
        https://bugs.webkit.org/show_bug.cgi?id=147962

        Reviewed by Brian Burg.

        Test: http/tests/inspector/console/cross-domain-inspected-node-access.html

        The inspector backend injects the CommandLineAPI Source with a
        corresponding CommandLineAPIHost into each execution context
        created by the page (main frame, sub frames, etc).

        When creating the JSValue wrapper for the CommandLineAPIHost using
        the generated toJS(...) DOM bindings, we were using the cached
        CommandLineAPIHost wrapper values in the single DOMWrapperWorld shared
        across all frames. This meant that the first time the wrapper was
        needed it was created in context A. But when needed for context B
        it was using the wrapper created in context A. Using this wrapper
        in context B was producing unexpected cross-origin warnings.

        The solution taken here, is to create a new JSValue wrapper for
        the CommandLineAPIHost per execution context. This way each time
        the CommandLineAPIHost wrapper is used in a frame, it is using
        the one created for that frame.

        The C++ host object being wrapped has a lifetime equivalent to
        the Page. It does not change in this patch. The wrapper values
        are cleared on page navigation or when the page is closed, and
        will be garbage collected.

        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * ForwardingHeaders/inspector/PerGlobalObjectWrapperWorld.h: Added.
        New forwarding header.

        * inspector/CommandLineAPIHost.h:
        * inspector/CommandLineAPIHost.cpp:
        (WebCore::CommandLineAPIHost::CommandLineAPIHost):
        (WebCore::CommandLineAPIHost::wrapper):
        Cached JSValue wrappers per GlobalObject.

        (WebCore::CommandLineAPIHost::clearAllWrappers):
        Clear any wrappers we have, including the $0 value itself
        which we weren't explicitly clearing previously.

        * inspector/CommandLineAPIModule.cpp:
        (WebCore::CommandLineAPIModule::host):
        Simplify creating the wrapper.

        * inspector/WebInjectedScriptManager.h:
        * inspector/WebInjectedScriptManager.cpp:
        (WebCore::WebInjectedScriptManager::discardInjectedScripts):
        When the main frame window object clears, also clear the
        CommandLineAPI wrappers we may have created. Also take this
        opportunity to clear any $0 value that may have pointed
        to a value in the previous page.

2015-11-09  Per Arne Vollan  <peavo@outlook.com>

        [WinCairo][Video][MediaFoundation] Video should be rendered in provided graphics context.
        https://bugs.webkit.org/show_bug.cgi?id=150941

        Reviewed by Brent Fulgham.

        On WinCairo, we currently render video in a child window of the main browser window.
        This makes it difficult to render things on top of the video, like video controls and
        context menus. We should render the video in the graphics context provided by the paint
        method. This is done by implementing a custom EVR (Enhanced Video Renderer) presenter
        for Media Foundation.

        * platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:
        (MFCreateMediaType):
        (WebCore::MediaPlayerPrivateMediaFoundation::MediaPlayerPrivateMediaFoundation):
        (WebCore::MediaPlayerPrivateMediaFoundation::registerMediaEngine):
        (WebCore::MediaPlayerPrivateMediaFoundation::isAvailable):
        (WebCore::MediaPlayerPrivateMediaFoundation::setSize):
        (WebCore::MediaPlayerPrivateMediaFoundation::paint):
        (WebCore::MediaPlayerPrivateMediaFoundation::createSession):
        (WebCore::MediaPlayerPrivateMediaFoundation::endGetEvent):
        (WebCore::MediaPlayerPrivateMediaFoundation::createVideoWindow):
        (WebCore::MediaPlayerPrivateMediaFoundation::destroyVideoWindow):
        (WebCore::MediaPlayerPrivateMediaFoundation::invalidateFrameView):
        (WebCore::MediaPlayerPrivateMediaFoundation::addListener):
        (WebCore::MediaPlayerPrivateMediaFoundation::createOutputNode):
        (WebCore::MediaPlayerPrivateMediaFoundation::onTopologySet):
        (WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::onMediaPlayerDeleted):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::CustomVideoPresenter):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::~CustomVideoPresenter):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::QueryInterface):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::AddRef):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::Release):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::OnClockStart):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::OnClockStop):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::OnClockPause):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::OnClockRestart):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::OnClockSetRate):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::ProcessMessage):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetCurrentMediaType):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetDeviceID):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::InitServicePointers):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::ReleaseServicePointers):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetService):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::ActivateObject):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::DetachObject):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::ShutdownObject):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetVideoWindow):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetVideoWindow):
        (WebCore::setMixerSourceRect):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetVideoPosition):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetVideoPosition):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::RepaintVideo):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::Invoke):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::onMediaPlayerDeleted):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::paintCurrentFrame):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::isActive):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::configureMixer):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::flush):
        (WebCore::areMediaTypesEqual):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::setMediaType):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::checkShutdown):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::renegotiateMediaType):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::processInputNotify):
        (WebCore::MFOffsetToFloat):
        (WebCore::MakeOffset):
        (WebCore::MakeArea):
        (WebCore::validateVideoArea):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::beginStreaming):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::endStreaming):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::checkEndOfStream):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::isMediaTypeSupported):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::createOptimalVideoType):
        (WebCore::correctAspectRatio):
        (WebCore::GetVideoDisplayArea):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::calculateOutputRectangle):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::processOutputLoop):
        (WebCore::setDesiredSampleTime):
        (WebCore::clearDesiredSampleTime):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::processOutput):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::deliverSample):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::trackSample):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::releaseResources):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::onSampleFree):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::notifyEvent):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoSamplePool::getSample):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoSamplePool::returnSample):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoSamplePool::areSamplesPending):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoSamplePool::initialize):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoSamplePool::clear):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::setFrameRate):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::startScheduler):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::stopScheduler):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::flush):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::scheduleSample):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::processSamplesInQueue):
        (WebCore::MFTimeToMilliseconds):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::processSample):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::schedulerThreadProc):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::schedulerThreadProcPrivate):
        (WebCore::findAdapter):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::Direct3DPresenter):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::~Direct3DPresenter):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::getService):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::checkFormat):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::setVideoWindow):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::setDestinationRect):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::createVideoSamples):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::releaseResources):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::checkDeviceState):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::presentSample):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::paintCurrentFrame):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::initializeD3D):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::createD3DDevice):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::createD3DSample):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::presentSwapChain):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::getSwapChainPresentParameters):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::updateDestRect):
        * platform/graphics/win/MediaPlayerPrivateMediaFoundation.h:
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoSamplePool::VideoSamplePool):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoSamplePool::~VideoSamplePool):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::VideoScheduler):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::~VideoScheduler):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::setPresenter):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::setClockRate):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::lastSampleTime):
        (WebCore::MediaPlayerPrivateMediaFoundation::VideoScheduler::frameDuration):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::getVideoWindow):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::getDestinationRect):
        (WebCore::MediaPlayerPrivateMediaFoundation::Direct3DPresenter::refreshRate):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetItem):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetItemType):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::CompareItem):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::Compare):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetUINT32):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetUINT64):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetDouble):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetGUID):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetStringLength):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetString):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetAllocatedString):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetBlobSize):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetBlob):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetAllocatedBlob):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetUnknown):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetItem):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::DeleteItem):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::DeleteAllItems):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetUINT32):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetUINT64):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetDouble):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetGUID):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetString):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetBlob):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetUnknown):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::LockStore):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::UnlockStore):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetCount):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetItemByIndex):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::CopyAllItems):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetNativeVideoSize):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetIdealVideoSize):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetAspectRatioMode):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetAspectRatioMode):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetCurrentImage):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetBorderColor):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetBorderColor):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetRenderingPrefs):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetRenderingPrefs):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::SetFullscreen):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetFullscreen):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::GetParameters):
        (WebCore::MediaPlayerPrivateMediaFoundation::CustomVideoPresenter::isScrubbing):

2015-11-09  Alex Christensen  <achristensen@webkit.org>

        XHR timeouts should not fire if there is an immediate network error.
        https://bugs.webkit.org/show_bug.cgi?id=150577

        Reviewed by Darin Adler.

        This fixes flakiness of http/tests/contentextensions/async-xhr-onerror.html since r191077.

        * xml/XMLHttpRequest.cpp:
        (WebCore::XMLHttpRequest::createRequest):
        (WebCore::XMLHttpRequest::internalAbort):
        (WebCore::XMLHttpRequest::didFinishLoading):
        If the timeout timer has been started and we are going to immediately report a network error, then stop the timeout timer.
        The timeout timer sometimes fired before the network error timer if it was a very short timeout (such as 1ms).
        Also checks to isActive before calling stop on a timer are not necessary.

2015-11-09  Eric Carlson  <eric.carlson@apple.com>

        [MediaStream] Add mock audio and video sources
        https://bugs.webkit.org/show_bug.cgi?id=150997
        <rdar://problem/23453358>

        Reviewed by Jer Noble.

        Create basic mock audio and video realtime media source classes so we can test MediaStream
        API without requiring test machines to have audio/video input hardware. No new tests added
        yet, thoe will follow.

        No new tests, these changes will allow us to write MediaStream tests.

        * CMakeLists.txt: Add MockRealtimeAudioSource.cpp, MockRealtimeMediaSource.cpp, and 
          MockRealtimeVideoSource.cpp

        * PlatformMac.cmake: Add MockRealtimeVideoSourceMac.mm

        * WebCore.xcodeproj/project.pbxproj: Add new files.

        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::createPreviewLayers): Don't set autoresizingMask,
          it isn't necessary.

        * platform/mediastream/mac/AVCaptureDeviceManager.mm:
        (WebCore::refreshCaptureDeviceList): AVCaptureDevice -> getAVCaptureDeviceClass()
        (WebCore::AVCaptureDeviceManager::bestDeviceForFacingMode): Ditto.
        (WebCore::AVCaptureDeviceManager::sourceWithUID): Ditto.

        Mac class implements RealtimeVideoSource::platformLayer, returns a CALayer which uses the
        GraphicsContext as contents.
        * platform/mediastream/mac/MockRealtimeVideoSourceMac.h: Added.
        * platform/mediastream/mac/MockRealtimeVideoSourceMac.mm: Added.
        (WebCore::MockRealtimeVideoSource::create):
        (WebCore::MockRealtimeVideoSourceMac::MockRealtimeVideoSourceMac):
        (WebCore::MockRealtimeVideoSourceMac::platformLayer):
        (WebCore::MockRealtimeVideoSourceMac::updatePlatformLayer):

        Mock audio source. Doesn't provide data yet, only provides states and capabilities.
        * platform/mock/MockRealtimeAudioSource.cpp: Added.
        (WebCore::MockRealtimeAudioSource::create):
        (WebCore::MockRealtimeAudioSource::MockRealtimeAudioSource):
        (WebCore::MockRealtimeAudioSource::updateStates):
        (WebCore::MockRealtimeAudioSource::initializeCapabilities):
        * platform/mock/MockRealtimeAudioSource.h: Added.
        (WebCore::MockRealtimeAudioSource::~MockRealtimeAudioSource):

        Mock source base class, sets persistent ID and updates states and capabilities.
        * platform/mock/MockRealtimeMediaSource.cpp: Added.
        (WebCore::MockRealtimeMediaSource::mockAudioPersistentID):
        (WebCore::MockRealtimeMediaSource::mockVideoPersistentID):
        (WebCore::MockRealtimeMediaSource::MockRealtimeMediaSource):
        (WebCore::MockRealtimeMediaSource::capabilities):
        (WebCore::MockRealtimeMediaSource::states):
        * platform/mock/MockRealtimeMediaSource.h: Added.
        (WebCore::MockRealtimeMediaSource::mockAudioSourcePersistentID):
        (WebCore::MockRealtimeMediaSource::mockAudioSourceName):
        (WebCore::MockRealtimeMediaSource::mockVideoSourcePersistentID):
        (WebCore::MockRealtimeMediaSource::mockVideoSourceName):
        (WebCore::MockRealtimeMediaSource::trackSourceWithUID):
        (WebCore::MockRealtimeMediaSource::~MockRealtimeMediaSource):
        (WebCore::MockRealtimeMediaSource::currentStates):
        (WebCore::MockRealtimeMediaSource::constraints):

        Use new mock source classes. Create a new source instance for each request instead of reusing the
        same sources each time.
        * platform/mock/MockRealtimeMediaSourceCenter.cpp:
        (WebCore::mockSourceMap):
        (WebCore::MockRealtimeMediaSourceCenter::registerMockRealtimeMediaSourceCenter):
        (WebCore::MockRealtimeMediaSourceCenter::validateRequestConstraints):
        (WebCore::MockRealtimeMediaSourceCenter::createMediaStream):
        (WebCore::MockRealtimeMediaSourceCenter::getMediaStreamTrackSources):
        (WebCore::MockSource::MockSource): Deleted.
        (WebCore::MockSource::~MockSource): Deleted.
        (WebCore::MockSource::capabilities): Deleted.
        (WebCore::MockSource::states): Deleted.
        (WebCore::mockAudioSourceID): Deleted.
        (WebCore::mockVideoSourceID): Deleted.
        (WebCore::initializeMockSources): Deleted.

        Mock video source. Generate bip-bop inspired frames with burned in state information.
        * platform/mock/MockRealtimeVideoSource.cpp: Added.
        (WebCore::MockRealtimeVideoSource::create):
        (WebCore::MockRealtimeVideoSource::MockRealtimeVideoSource):
        (WebCore::MockRealtimeVideoSource::startProducingData):
        (WebCore::MockRealtimeVideoSource::stopProducingData):
        (WebCore::MockRealtimeVideoSource::elapsedTime):
        (WebCore::MockRealtimeVideoSource::updateStates):
        (WebCore::MockRealtimeVideoSource::initializeCapabilities):
        (WebCore::MockRealtimeVideoSource::setFacingMode):
        (WebCore::MockRealtimeVideoSource::setFrameRate):
        (WebCore::MockRealtimeVideoSource::setSize):
        (WebCore::MockRealtimeVideoSource::drawAnimation):
        (WebCore::MockRealtimeVideoSource::drawBoxes):
        (WebCore::MockRealtimeVideoSource::drawText):
        (WebCore::MockRealtimeVideoSource::generateFrame):
        (WebCore::MockRealtimeVideoSource::imageBuffer):
        (WebCore::MockRealtimeVideoSource::paintCurrentFrameInContext):
        (WebCore::MockRealtimeVideoSource::currentFrameImage):
        * platform/mock/MockRealtimeVideoSource.h: Added.
        (WebCore::MockRealtimeVideoSource::~MockRealtimeVideoSource):
        (WebCore::MockRealtimeVideoSource::size):
        (WebCore::MockRealtimeVideoSource::updatePlatformLayer):

2015-11-09  Nan Wang  <n_wang@apple.com>

        AX: Input type: time is not accessible on iOS
        https://bugs.webkit.org/show_bug.cgi?id=150984

        Reviewed by Chris Fleizach.

        Exposed input type: time as popup button on iOS.

        Test: accessibility/ios-simulator/input-type-time.html

        * accessibility/AccessibilityRenderObject.cpp:
        (WebCore::AccessibilityRenderObject::determineAccessibilityRole):

2015-11-09  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test editing/inserting/insert-html-crash-01.html
        https://bugs.webkit.org/show_bug.cgi?id=149298
        <rdar://problem/22746918>

        Reviewed by Ryosuke Niwa.

        The test crashes in the method WebCore::CompositeEditCommand::moveParagraphs() because
        the other method WebCore::CompositeEditCommand::cleanupAfterDeletion() accidentally
        deletes the destination node. In WebCore::CompositeEditCommand::cleanupAfterDeletion(),
        it fails to determine that caretAfterDelete equals to destination as Position::operator==,
        which is called in VisiblePosition::operator==, only checks the equality of tuple
        <Anchor Node, Anchor Type, Offset>. It is insufficient as a single position can be
        represented by multiple tuples. Therefore, this change adds Position::equals() to fortify
        the equal checking of two positions by considering combinations of different tuple
        representations.

        Furthermore, it adds VisiblePosition::equals() which considers affinity and call
        Position::equals() while comparing two visible positions.

        Test: editing/inserting/insert-html-crash-01.html

        * dom/Position.cpp:
        (WebCore::Position::equals):
        * dom/Position.h:
        * editing/CompositeEditCommand.cpp:
        (WebCore::CompositeEditCommand::cleanupAfterDeletion):
        Replace operator== with VisiblePosition::equals() to tackle the test case.
        * editing/VisiblePosition.cpp:
        (WebCore::VisiblePosition::equals):
        * editing/VisiblePosition.h:

2015-11-09  Myles C. Maxfield  <mmaxfield@apple.com>

        Some style changes cause tatechuyoko to be drawn off center
        https://bugs.webkit.org/show_bug.cgi?id=150986
        <rdar://problem/20748013>

        Reviewed by Darin Adler.

        Layouts should be idempotent. In particular, during layout, an element should not
        rely on a previous call to styleDidChange() with a sufficiently high StyleDifference.
        RenderCombineText was assuming that, if a layout occurs, a previous call to
        styleDidChange() would have reset the renderedText. However, an ancestor element might
        cause the RenderCombineText to re-combine when it is already combined. Therefore, the
        recombination should fully uncombine before recombining.

        Test: fast/text/text-combine-style-change-extra-layout.html

        * rendering/RenderCombineText.cpp:
        (WebCore::RenderCombineText::combineText): Fully uncombine before recombining.

2015-11-09  Brent Fulgham  <bfulgham@apple.com>

        [Win] Recognize context flush as an event that requires an update
        https://bugs.webkit.org/show_bug.cgi?id=151001
        <rdar://problem/22956040>

        Reviewed by Simon Fraser.

        * platform/graphics/ca/win/WKCACFViewLayerTreeHost.cpp:
        (WebCore::WKCACFViewLayerTreeHost::flushContext): Mark view as needing an update
        when flushing so internal drawing code will do the paint.
        * rendering/RenderLayerBacking.cpp:
        (WebCore::RenderLayerBacking::paintIntoLayer): Skip WK2 assert that does
        not apply to Windows drawing path.

2015-11-09  Brady Eidson  <beidson@apple.com>

        Modern IDB: Refactor memory objectstore/transaction interation.
        https://bugs.webkit.org/show_bug.cgi?id=151014

        Reviewed by Darin Adler.

        No new tests (Refactor, no change in behavior).

        * Modules/indexeddb/server/IDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::recordValueChanged):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::addRecord):
        (WebCore::IDBServer::MemoryIDBBackingStore::putRecord): Deleted. Renamed to addRecord.
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::deleteRecord):
        (WebCore::IDBServer::MemoryObjectStore::addRecord):
        (WebCore::IDBServer::MemoryObjectStore::putRecord): Deleted. Renamed to addRecord.
        (WebCore::IDBServer::MemoryObjectStore::setKeyValue): Deleted. Folded into addRecord.
        * Modules/indexeddb/server/MemoryObjectStore.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::performPutOrAdd):

2015-11-09  Said Abou-Hallawa  <sabouhallawa@apple.com>

        REGRESSION (r190883): Error calculating the tile size for an SVG with no intrinsic size but with large floating intrinsic ratio
        https://bugs.webkit.org/show_bug.cgi?id=150904

        Reviewed by Darin Adler.
        
        This patch addresses two issues. The first one is a regression from r190883
        which was rolling out r184895. There was a missing if-statement in 
        RenderBoxModelObject::calculateImageIntrinsicDimension(). We should return
        it back. But this if-statement is an optimization; if we hit it we should
        return the image resolvedSize. But we should also return the same result
        if we call resolveAgainstIntrinsicWidthOrHeightAndRatio().
        
        We had a bug in resolving the intrinsic size of an image using a large
        intrinsic ratio. We need to do the calculation in LayoutUnits always.
        Using float calculations and then casting the output to an integer results
        in significant truncation if the intrinsic ratio is large.

        Test: fast/backgrounds/background-image-large-float-intrinsic-ratio.html

        * rendering/RenderBoxModelObject.cpp:
        (WebCore::resolveWidthForRatio):
        (WebCore::resolveHeightForRatio):
        (WebCore::resolveAgainstIntrinsicWidthOrHeightAndRatio):
        (WebCore::resolveAgainstIntrinsicRatio):
        Resolve the image size using its intrinsic ratio in LayoutUnits.
        
        (WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions):
        Put back an if-statement which was missing from rolling out r184895

2015-11-09  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        [Streams API] Activate assertions
        https://bugs.webkit.org/show_bug.cgi?id=151021

        Reviewed by Darin Adler.

        Activating assertions in streams API.
        Fixing a bug in ReadableStream implementation: when pull promise is rejected,
        the readable stream may already be errored by some other means.

        Covered by existing test sets in Debug builds.

        * Modules/streams/ReadableStreamInternals.js:
        (teeReadableStream):
        (teeReadableStreamPullFunction):
        (errorReadableStream):
        (requestReadableStreamPull):
        (finishClosingReadableStream):
        (closeReadableStream):
        (enqueueInReadableStream):
        (readFromReadableStreamReader):
        * Modules/streams/ReadableStreamReader.js:
        (cancel):
        * Modules/streams/StreamInternals.js:
        (peekQueueValue):
        * Modules/streams/WritableStream.js:
        (write):
        (state):
        * Modules/streams/WritableStreamInternals.js:
        (syncWritableStreamStateWithQueue):
        (closeWritableStream): Deleted.

2015-11-09  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Shield implementation from mangling then and catch promise methods
        https://bugs.webkit.org/show_bug.cgi?id=150934

        Reviewed by Youenn Fablet.

        This is a first step to get streams code shielded from user replacing the then and catch methods in our
        promises. We use newly introduced @then and @catch prototype internal slots and that should solve a lot of use
        cases.

        Test: streams/streams-promises.html.

        * Modules/streams/ReadableStream.js:
        (initializeReadableStream):
        * Modules/streams/ReadableStreamInternals.js:
        (teeReadableStream):
        (teeReadableStreamPullFunction):
        (cancelReadableStream):
        * Modules/streams/WritableStream.js:
        (initializeWritableStream):
        (abort):
        * Modules/streams/WritableStreamInternals.js:
        (callOrScheduleWritableStreamAdvanceQueue):

2015-11-09  Manuel Rego Casasnovas  <rego@igalia.com>

        [css-grid] Refactor cachedGridCoordinate() to cachedGridSpan()
        https://bugs.webkit.org/show_bug.cgi?id=151017

        Reviewed by Sergio Villar Senin.

        We were using cachedGridCoordinate() in lots of places and checking the
        direction just in the next line. Creating a generic function to do this.

        No new tests, no behavior change.

        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::computeUsedBreadthOfGridTracks):
        (WebCore::GridItemWithSpan::GridItemWithSpan):
        (WebCore::GridItemWithSpan::span):
        (WebCore::GridItemWithSpan::operator<):
        (WebCore::RenderGrid::spanningItemCrossesFlexibleSizedTracks):
        (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctions):
        (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctionsForNonSpanningItems):
        (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctionsForItems):
        (WebCore::RenderGrid::cachedGridSpan):
        (WebCore::RenderGrid::gridAreaBreadthForChild):
        (WebCore::RenderGrid::gridAreaBreadthForChildIncludingAlignmentOffsets):
        (WebCore::RenderGrid::columnAxisOffsetForChild):
        (WebCore::RenderGrid::rowAxisOffsetForChild):
        (WebCore::GridItemWithSpan::gridItem): Deleted.
        (WebCore::RenderGrid::populateGridPositions): Deleted.
        * rendering/RenderGrid.h:

2015-11-09  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        JS Built-ins functions should be able to assert
        https://bugs.webkit.org/show_bug.cgi?id=150333

        Reviewed by Yusuke Suzuki.

        * Modules/streams/ReadableStreamInternals.js:
        (privateInitializeReadableStreamReader): Activating an @assert.

2015-11-02  Sergio Villar Senin  <svillar@igalia.com>

        [css-grid] Improve grid container sizing with size constraints and intrinsic sizes
        https://bugs.webkit.org/show_bug.cgi?id=150679

        Reviewed by Darin Adler.

        The grid container stores from now on its min-content and
        max-content block sizes in order to be able to properly
        compute its intrinsic size. It has to redefine
        computeIntrinsicLogicalContentHeightUsing() because the
        behavior of grid is different to "normal" blocks:

        - the min-content size is the sum of the grid container's
        track sizes in the appropiate axis when the grid is sized
        under a min-content constraint.
        - the max-content size is the sum of the grid container's
        track sizes in the appropiate axis when the grid is sized
        under a max-content constraint.
        - the auto block size is the max-content size.

        A nice side effect is that we can now properly detect whether
        the grid has a definite size on a given axis or not.

        Tests: fast/css-grid-layout/absolute-positioning-definite-sizes.html
               fast/css-grid-layout/flex-and-intrinsic-sizes.html
               fast/css-grid-layout/maximize-tracks-definite-indefinite-height.html
               fast/css-grid-layout/maximize-tracks-definite-indefinite-width.html

        * rendering/RenderBox.h: made
        computeIntrinsicLogicalContentHeightUsing() virtual.
        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::GridSizingData::GridSizingData):
        (WebCore::RenderGrid::GridSizingData::freeSpaceForDirection):
        (WebCore::RenderGrid::GridSizingData::setFreeSpaceForDirection):
        (WebCore::RenderGrid::computeTrackBasedLogicalHeight):
        (WebCore::RenderGrid::computeTrackSizesForDirection):
        (WebCore::RenderGrid::layoutBlock):
        (WebCore::RenderGrid::computeIntrinsicLogicalWidths):
        (WebCore::RenderGrid::computeIntrinsicLogicalHeight):
        (WebCore::RenderGrid::computeIntrinsicLogicalContentHeightUsing):
        (WebCore::RenderGrid::computeUsedBreadthOfGridTracks):
        (WebCore::RenderGrid::distributeSpaceToTracks):
        (WebCore::RenderGrid::tracksAreWiderThanMinTrackBreadth):
        (WebCore::RenderGrid::applyStretchAlignmentToTracksIfNeeded):
        (WebCore::RenderGrid::layoutGridItems):
        (WebCore::RenderGrid::populateGridPositions):
        (WebCore::RenderGrid::gridElementIsShrinkToFit): Deleted.
        * rendering/RenderGrid.h:

2015-11-05  Sergio Villar Senin  <svillar@igalia.com>

        [css-grid] Grid placement conflict handling
        https://bugs.webkit.org/show_bug.cgi?id=150891

        Reviewed by Darin Adler.

        If the placement for a grid item contains two lines, and the
        start line is further end-ward than the end line, swap the two
        lines. If the start line is equal to the end line, remove the
        end line.

        Test: fast/css-grid-layout/swap-lines-if-start-is-further-endward-than-end-line.html

        * rendering/style/GridResolvedPosition.cpp:
        (WebCore::resolveNamedGridLinePositionFromStyle):
        (WebCore::resolveGridPositionFromStyle):
        (WebCore::GridResolvedPosition::GridResolvedPosition):
        (WebCore::GridResolvedPosition::resolveGridPositionsFromStyle):
        (WebCore::adjustGridPositionForSide): Deleted.
        * rendering/style/GridResolvedPosition.h:
        (WebCore::GridResolvedPosition::prev):

2015-11-08  Gyuyoung Kim  <gyuyoung.kim@webkit.org>

        [EFL] Add UserAgentEFl.cpp|h
        https://bugs.webkit.org/show_bug.cgi?id=151007

        Reviewed by Darin Adler.

        As other ports EFL port starts to have UserAgentEfl class in order to support more detailed
        UA.

        No new tests, no behavior change.

        * PlatformEfl.cmake:
        * platform/efl/UserAgentEfl.cpp: Added.
        (WebCore::platformForUAString):
        (WebCore::platformVersionForUAString):
        (WebCore::versionForUAString):
        (WebCore::standardUserAgent):
        * platform/efl/UserAgentEfl.h: Added.

2015-11-08  David Kilzer  <ddkilzer@apple.com>

        REGRESSION (r192140): Windows build broke after removing ColorSpace argument to all drawing calls
        <http://webkit.org/b/150967>

        Unreviewed attempt to fix the Windows build.

        * platform/graphics/ca/win/PlatformCALayerWin.cpp:
        (PlatformCALayerWin::drawTextAtPoint):
        * platform/graphics/win/ImageCGWin.cpp:
        (WebCore::BitmapImage::drawFrameMatchingSourceSize):
        * rendering/RenderThemeWin.cpp:
        (WebCore::RenderThemeWin::paintSearchFieldCancelButton):
        (WebCore::RenderThemeWin::paintSearchFieldResultsDecorationPart):
        (WebCore::RenderThemeWin::paintSearchFieldResultsButton):

2015-11-08  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        generate-js-builtins.js should support @internal annotation
        https://bugs.webkit.org/show_bug.cgi?id=150929

        Reviewed by Darin Adler.

        No change in behavior.

        * Modules/streams/ReadableStreamInternals.js: Renamed @internals to @internal.
        * Modules/streams/StreamInternals.js: Ditto.
        * Modules/streams/WritableStreamInternals.js: Ditto.

2015-11-07  Simon Fraser  <simon.fraser@apple.com>

        Remove ColorSpace argument to all the drawing calls
        https://bugs.webkit.org/show_bug.cgi?id=150967

        Reviewed by Darin Adler.

        Since the -webkit-color-correction CSS property was removed in r188202, and ColorSpaceDeviceRGB
        and ColorSpaceSRGB are functionally equivalent, we can remove all the ColorSpace arguments passed
        to drawing functions, and remove RenderStyle::colorSpace(), which was hardcoded to return ColorSpaceSRGB.
        
        Fill and stroke ColorSpaces are also remove from graphics state, simplifying color save/restore.
        
        * bindings/scripts/CodeGeneratorObjC.pm:
        (GenerateImplementation):
        * css/CSSFilterImageValue.cpp:
        (WebCore::CSSFilterImageValue::image):
        * editing/FrameSelection.cpp:
        (WebCore::CaretBase::paintCaret):
        * editing/cocoa/HTMLConverter.mm:
        (_platformColor):
        * html/HTMLCanvasElement.cpp:
        (WebCore::HTMLCanvasElement::paint):
        * html/canvas/CanvasRenderingContext2D.cpp:
        (WebCore::CanvasRenderingContext2D::clearRect):
        (WebCore::CanvasRenderingContext2D::applyShadow):
        (WebCore::CanvasRenderingContext2D::drawImage):
        (WebCore::CanvasRenderingContext2D::compositeBuffer):
        (WebCore::drawImageToContext):
        (WebCore::CanvasRenderingContext2D::fullCanvasCompositedDrawImage):
        (WebCore::CanvasRenderingContext2D::drawTextInternal):
        * html/canvas/CanvasRenderingContext2D.h:
        * html/canvas/CanvasStyle.cpp:
        (WebCore::CanvasStyle::applyStrokeColor):
        (WebCore::CanvasStyle::applyFillColor):
        * html/canvas/WebGLRenderingContextBase.cpp:
        (WebCore::WebGLRenderingContextBase::drawImageIntoBuffer):
        * page/DebugPageOverlays.cpp:
        (WebCore::RegionOverlay::drawRect):
        * page/FrameView.cpp:
        (WebCore::FrameView::paintScrollCorner):
        (WebCore::FrameView::paintScrollbar):
        (WebCore::FrameView::paintContents):
        * page/PrintContext.cpp:
        (WebCore::PrintContext::spoolAllPagesWithBoundaries):
        * platform/ScrollView.cpp:
        (WebCore::ScrollView::paintPanScrollIcon):
        * platform/ScrollbarTheme.h:
        (WebCore::ScrollbarTheme::defaultPaintScrollCorner):
        * platform/ScrollbarThemeComposite.cpp:
        (WebCore::ScrollbarThemeComposite::paintScrollCorner):
        (WebCore::ScrollbarThemeComposite::paintOverhangAreas):
        * platform/Theme.cpp:
        (WebCore::Theme::drawNamedImage):
        * platform/cocoa/ThemeCocoa.cpp:
        (WebCore::ThemeCocoa::drawNamedImage):
        * platform/graphics/BitmapImage.cpp:
        (WebCore::BitmapImage::drawPattern):
        * platform/graphics/BitmapImage.h:
        * platform/graphics/Color.h:
        * platform/graphics/CrossfadeGeneratedImage.cpp:
        (WebCore::drawCrossfadeSubimage):
        (WebCore::CrossfadeGeneratedImage::draw):
        (WebCore::CrossfadeGeneratedImage::drawPattern):
        * platform/graphics/CrossfadeGeneratedImage.h:
        * platform/graphics/GeneratedImage.h:
        * platform/graphics/GradientImage.cpp:
        (WebCore::GradientImage::draw):
        (WebCore::GradientImage::drawPattern):
        * platform/graphics/GradientImage.h:
        * platform/graphics/GraphicsContext.cpp:
        (WebCore::GraphicsContext::drawRaisedEllipse):
        (WebCore::GraphicsContext::setStrokeColor):
        (WebCore::GraphicsContext::setShadow):
        (WebCore::GraphicsContext::setLegacyShadow):
        (WebCore::GraphicsContext::getShadow):
        (WebCore::GraphicsContext::setFillColor):
        (WebCore::GraphicsContext::drawImage):
        (WebCore::GraphicsContext::drawTiledImage):
        (WebCore::GraphicsContext::drawImageBuffer):
        (WebCore::GraphicsContext::fillRect):
        (WebCore::GraphicsContext::fillRoundedRect):
        (WebCore::GraphicsContext::fillRectWithRoundedHole):
        (WebCore::GraphicsContext::clearShadow): Deleted.
        * platform/graphics/GraphicsContext.h:
        (WebCore::GraphicsContext::strokeColorSpace): Deleted.
        (WebCore::GraphicsContext::fillColorSpace): Deleted.
        * platform/graphics/Image.cpp:
        (WebCore::Image::fillWithSolidColor):
        (WebCore::Image::drawTiled):
        * platform/graphics/Image.h:
        (WebCore::Image::drawFrameMatchingSourceSize):
        * platform/graphics/ImageBuffer.h:
        (WebCore::ImageBuffer::create):
        * platform/graphics/NamedImageGeneratedImage.cpp:
        (WebCore::NamedImageGeneratedImage::draw):
        (WebCore::NamedImageGeneratedImage::drawPattern):
        * platform/graphics/NamedImageGeneratedImage.h:
        * platform/graphics/ShadowBlur.cpp:
        (WebCore::ScratchBuffer::setCachedShadowValues):
        (WebCore::ScratchBuffer::setCachedInsetShadowValues):
        (WebCore::ShadowBlur::ShadowBlur):
        (WebCore::ShadowBlur::setShadowValues):
        (WebCore::ShadowBlur::drawShadowBuffer):
        (WebCore::ShadowBlur::drawRectShadowWithoutTiling):
        (WebCore::ShadowBlur::drawInsetShadowWithoutTiling):
        (WebCore::ShadowBlur::drawInsetShadowWithTiling):
        (WebCore::ShadowBlur::drawRectShadowWithTiling):
        (WebCore::ShadowBlur::drawLayerPieces):
        (WebCore::ShadowBlur::blurAndColorShadowBuffer):
        (WebCore::ShadowBlur::beginShadowLayer):
        (WebCore::ShadowBlur::endShadowLayer):
        * platform/graphics/ShadowBlur.h:
        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerLayer):
        (WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput):
        * platform/graphics/ca/GraphicsLayerCA.cpp:
        (WebCore::GraphicsLayerCA::setContentsToImage): Deleted.
        * platform/graphics/ca/TileGrid.cpp:
        (WebCore::TileGrid::platformCALayerPaintContents):
        * platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
        (PlatformCALayerWinInternal::drawRepaintCounters):
        * platform/graphics/cairo/BitmapImageCairo.cpp:
        (WebCore::BitmapImage::draw):
        * platform/graphics/cairo/GraphicsContextCairo.cpp:
        (WebCore::GraphicsContext::fillRect):
        (WebCore::GraphicsContext::setPlatformFillColor):
        (WebCore::GraphicsContext::setPlatformStrokeColor):
        (WebCore::GraphicsContext::setPlatformShadow):
        (WebCore::GraphicsContext::platformFillRoundedRect):
        (WebCore::GraphicsContext::fillRectWithRoundedHole):
        (WebCore::GraphicsContext::drawPattern):
        * platform/graphics/cairo/ImageBufferCairo.cpp:
        (WebCore::ImageBuffer::draw):
        (WebCore::ImageBuffer::drawPattern):
        * platform/graphics/cairo/ImageCairo.cpp:
        (WebCore::Image::drawPattern):
        * platform/graphics/cg/BitmapImageCG.cpp:
        (WebCore::BitmapImage::draw):
        * platform/graphics/cg/ColorCG.cpp:
        (WebCore::leakCGColor):
        (WebCore::cachedCGColor):
        * platform/graphics/cg/GraphicsContext3DCG.cpp:
        (WebCore::GraphicsContext3D::paintToCanvas):
        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::setCGFillColor):
        (WebCore::setCGStrokeColor):
        (WebCore::GraphicsContext::platformInit):
        (WebCore::GraphicsContext::drawNativeImage):
        (WebCore::GraphicsContext::drawPattern):
        (WebCore::GraphicsContext::drawRect):
        (WebCore::GraphicsContext::drawLine):
        (WebCore::GraphicsContext::applyFillPattern):
        (WebCore::GraphicsContext::fillRect):
        (WebCore::GraphicsContext::platformFillRoundedRect):
        (WebCore::GraphicsContext::fillRectWithRoundedHole):
        (WebCore::GraphicsContext::setPlatformShadow):
        (WebCore::GraphicsContext::drawLinesForText):
        (WebCore::GraphicsContext::setPlatformStrokeColor):
        (WebCore::GraphicsContext::setPlatformFillColor):
        (WebCore::sRGBColorSpaceRef): Deleted.
        * platform/graphics/cg/ImageBufferCG.cpp:
        (WebCore::ImageBuffer::copyImage):
        (WebCore::ImageBuffer::draw):
        (WebCore::ImageBuffer::drawPattern):
        * platform/graphics/cg/ImageCG.cpp:
        (WebCore::Image::drawPattern):
        (WebCore::Image::imageWithColorSpace): Deleted.
        * platform/graphics/cg/PDFDocumentImage.cpp:
        (WebCore::PDFDocumentImage::draw):
        * platform/graphics/cg/PDFDocumentImage.h:
        * platform/graphics/cocoa/FontCascadeCocoa.mm:
        (WebCore::FontCascade::drawGlyphs):
        * platform/graphics/filters/FEBlend.cpp:
        (WebCore::FEBlend::platformApplySoftware):
        * platform/graphics/filters/FEColorMatrix.cpp:
        (WebCore::FEColorMatrix::platformApplySoftware):
        * platform/graphics/filters/FEComposite.cpp:
        (WebCore::FEComposite::platformApplySoftware):
        * platform/graphics/filters/FEDropShadow.cpp:
        (WebCore::FEDropShadow::platformApplySoftware):
        * platform/graphics/filters/FEFlood.cpp:
        (WebCore::FEFlood::platformApplySoftware):
        * platform/graphics/filters/FEMerge.cpp:
        (WebCore::FEMerge::platformApplySoftware):
        * platform/graphics/filters/FEOffset.cpp:
        (WebCore::FEOffset::platformApplySoftware):
        * platform/graphics/filters/FETile.cpp:
        (WebCore::FETile::platformApplySoftware):
        * platform/graphics/filters/SourceAlpha.cpp:
        (WebCore::SourceAlpha::platformApplySoftware):
        * platform/graphics/filters/SourceGraphic.cpp:
        (WebCore::SourceGraphic::platformApplySoftware):
        * platform/graphics/ios/IconIOS.mm:
        (WebCore::Icon::paint):
        * platform/graphics/texmap/coordinated/CoordinatedImageBacking.cpp:
        * platform/graphics/texmap/coordinated/UpdateAtlas.cpp:
        * platform/graphics/win/FontCGWin.cpp:
        (WebCore::FontCascade::drawGlyphs):
        * platform/graphics/win/GraphicsContextCGWin.cpp:
        (WebCore::GraphicsContext::drawFocusRing):
        * platform/graphics/win/ImageCGWin.cpp:
        (WebCore::BitmapImage::getHBITMAPOfSize):
        (WebCore::BitmapImage::drawFrameMatchingSourceSize):
        * platform/graphics/win/ImageCairoWin.cpp:
        (WebCore::BitmapImage::getHBITMAPOfSize):
        (WebCore::BitmapImage::drawFrameMatchingSourceSize):
        * platform/ios/LegacyTileCache.mm:
        (WebCore::LegacyTileCache::drawLayer):
        * platform/ios/LegacyTileGridTile.mm:
        (WebCore::LegacyTileGridTile::showBorder):
        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
        (WebVideoFullscreenControllerContext::didSetupFullscreen):
        * platform/mac/DragImageMac.mm:
        (WebCore::drawAtPoint):
        * platform/mac/ScrollbarThemeMac.mm:
        (WebCore::ScrollbarThemeMac::setUpOverhangAreaBackground):
        * platform/mac/ThemeMac.mm:
        (WebCore::ThemeMac::drawCellOrFocusRingWithViewIntoContext):
        * platform/mediastream/MediaStreamPrivate.cpp:
        (WebCore::MediaStreamPrivate::paintCurrentFrameInContext):
        * platform/mock/ScrollbarThemeMock.cpp:
        (WebCore::ScrollbarThemeMock::paintTrackBackground):
        (WebCore::ScrollbarThemeMock::paintThumb):
        * platform/win/DragImageWin.cpp:
        (WebCore::createDragImageForLink):
        * platform/win/PopupMenuWin.cpp:
        (WebCore::PopupMenuWin::paint):
        * platform/win/WebCoreTextRenderer.cpp:
        (WebCore::doDrawTextAtPoint):
        * rendering/EllipsisBox.cpp:
        (WebCore::EllipsisBox::paint):
        (WebCore::EllipsisBox::paintSelection):
        * rendering/FilterEffectRenderer.cpp:
        (WebCore::FilterEffectRendererHelper::applyFilterEffect):
        * rendering/InlineTextBox.cpp:
        (WebCore::InlineTextBox::paintSelection):
        (WebCore::InlineTextBox::paintCompositionBackground):
        (WebCore::InlineTextBox::paintDecoration):
        (WebCore::InlineTextBox::paintTextMatchMarker):
        (WebCore::InlineTextBox::paintCompositionUnderline):
        * rendering/RenderBlock.cpp:
        (WebCore::RenderBlock::blockSelectionGap):
        (WebCore::RenderBlock::logicalLeftSelectionGap):
        (WebCore::RenderBlock::logicalRightSelectionGap):
        * rendering/RenderBox.cpp:
        (WebCore::RenderBox::paintClippingMask):
        * rendering/RenderBoxModelObject.cpp:
        (WebCore::applyBoxShadowForBackground):
        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
        (WebCore::RenderBoxModelObject::paintBorder):
        (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
        (WebCore::RenderBoxModelObject::paintBoxShadow):
        * rendering/RenderDetailsMarker.cpp:
        (WebCore::RenderDetailsMarker::paint):
        * rendering/RenderElement.cpp:
        (WebCore::RenderElement::drawLineForBoxSide):
        (WebCore::RenderElement::paintOutline):
        * rendering/RenderEmbeddedObject.cpp:
        (WebCore::RenderEmbeddedObject::paintSnapshotImage):
        (WebCore::RenderEmbeddedObject::paintReplaced):
        * rendering/RenderFileUploadControl.cpp:
        (WebCore::RenderFileUploadControl::paintObject):
        * rendering/RenderFrameSet.cpp:
        (WebCore::RenderFrameSet::paintColumnBorder):
        (WebCore::RenderFrameSet::paintRowBorder):
        * rendering/RenderImage.cpp:
        (WebCore::RenderImage::paintReplaced):
        (WebCore::RenderImage::paintIntoRect):
        * rendering/RenderLayer.cpp:
        (WebCore::RenderLayer::beginTransparencyLayers):
        (WebCore::RenderLayer::paintScrollCorner):
        (WebCore::RenderLayer::drawPlatformResizerImage):
        (WebCore::RenderLayer::paintResizer):
        * rendering/RenderListBox.cpp:
        (WebCore::RenderListBox::paintItemForeground):
        (WebCore::RenderListBox::paintItemBackground):
        * rendering/RenderListMarker.cpp:
        (WebCore::RenderListMarker::paint):
        * rendering/RenderReplaced.cpp:
        (WebCore::RenderReplaced::paint):
        * rendering/RenderScrollbarTheme.cpp:
        (WebCore::RenderScrollbarTheme::paintScrollCorner):
        * rendering/RenderSnapshottedPlugIn.cpp:
        (WebCore::RenderSnapshottedPlugIn::paintSnapshot):
        * rendering/RenderTheme.cpp:
        (WebCore::RenderTheme::paintSliderTicks):
        * rendering/RenderThemeIOS.mm:
        (WebCore::drawAxialGradient):
        (WebCore::drawRadialGradient):
        (WebCore::RenderThemeIOS::paintCheckboxDecorations):
        (WebCore::RenderThemeIOS::paintRadioDecorations):
        (WebCore::RenderThemeIOS::paintMenuListButtonDecorations):
        (WebCore::RenderThemeIOS::paintSliderTrack):
        (WebCore::RenderThemeIOS::paintProgressBar):
        (WebCore::RenderThemeIOS::paintFileUploadIconDecorations):
        * rendering/RenderThemeMac.mm:
        (WebCore::RenderThemeMac::paintProgressBar):
        (WebCore::RenderThemeMac::paintMenuListButtonDecorations):
        (WebCore::RenderThemeMac::paintSnapshottedPluginOverlay):
        (WebCore::titleTextColorForAttachment):
        (WebCore::AttachmentLayout::layOutSubtitle):
        (WebCore::paintAttachmentIconBackground):
        (WebCore::paintAttachmentTitleBackground):
        (WebCore::paintAttachmentProgress):
        * rendering/RenderView.cpp:
        (WebCore::RenderView::paint):
        (WebCore::RenderView::paintBoxDecorations):
        * rendering/RenderWidget.cpp:
        (WebCore::RenderWidget::paint):
        * rendering/RootInlineBox.cpp:
        (WebCore::RootInlineBox::lineSelectionGap):
        * rendering/SimpleLineLayoutFunctions.cpp:
        (WebCore::SimpleLineLayout::paintDebugBorders):
        * rendering/TextPaintStyle.cpp:
        (WebCore::TextPaintStyle::TextPaintStyle):
        (WebCore::adjustColorForVisibilityOnBackground):
        (WebCore::computeTextPaintStyle):
        (WebCore::updateGraphicsContext):
        * rendering/TextPaintStyle.h:
        (WebCore::TextPaintStyle::TextPaintStyle):
        * rendering/TextPainter.cpp:
        (WebCore::ShadowApplier::ShadowApplier):
        (WebCore::paintTextWithShadows):
        * rendering/mathml/RenderMathMLBlock.cpp:
        (WebCore::RenderMathMLBlock::paint):
        * rendering/mathml/RenderMathMLFraction.cpp:
        (WebCore::RenderMathMLFraction::paint):
        * rendering/mathml/RenderMathMLMenclose.cpp:
        (WebCore::RenderMathMLMenclose::paint):
        * rendering/mathml/RenderMathMLOperator.cpp:
        (WebCore::RenderMathMLOperator::paint):
        * rendering/mathml/RenderMathMLRadicalOperator.cpp:
        (WebCore::RenderMathMLRadicalOperator::paint):
        * rendering/mathml/RenderMathMLRoot.cpp:
        (WebCore::RenderMathMLRoot::paint):
        * rendering/shapes/Shape.cpp:
        (WebCore::Shape::createRasterShape):
        * rendering/style/NinePieceImage.cpp:
        (WebCore::NinePieceImage::paint):
        * rendering/style/RenderStyle.h:
        * rendering/svg/RenderSVGImage.cpp:
        (WebCore::RenderSVGImage::paintForeground):
        * rendering/svg/RenderSVGPath.cpp:
        (WebCore::useStrokeStyleToFill):
        * rendering/svg/RenderSVGResourceFilter.cpp:
        (WebCore::RenderSVGResourceFilter::postApplyResource):
        * rendering/svg/RenderSVGResourceSolidColor.cpp:
        (WebCore::RenderSVGResourceSolidColor::applyResource):
        * rendering/svg/SVGInlineTextBox.cpp:
        (WebCore::SVGInlineTextBox::paintSelectionBackground):
        * rendering/svg/SVGRenderingContext.cpp:
        (WebCore::SVGRenderingContext::prepareToRenderSVGContent):
        (WebCore::SVGRenderingContext::bufferForeground):
        * svg/SVGAnimatedColor.cpp:
        (WebCore::SVGAnimatedColorAnimator::calculateAnimatedValue):
        * svg/graphics/SVGImage.cpp:
        (WebCore::SVGImage::drawForContainer):
        (WebCore::SVGImage::nativeImageForCurrentFrame):
        (WebCore::SVGImage::drawPatternForContainer):
        (WebCore::SVGImage::draw):
        * svg/graphics/SVGImage.h:
        * svg/graphics/SVGImageForContainer.cpp:
        (WebCore::SVGImageForContainer::draw):
        (WebCore::SVGImageForContainer::drawPattern):
        * svg/graphics/SVGImageForContainer.h:
        * svg/graphics/filters/SVGFEImage.cpp:
        (WebCore::FEImage::platformApplySoftware):
        * testing/MockPageOverlayClient.cpp:
        (WebCore::MockPageOverlayClient::drawRect):

2015-11-07  Simon Fraser  <simon.fraser@apple.com>

        Use ColorSpaceSRGB for image buffers everywhere
        https://bugs.webkit.org/show_bug.cgi?id=150990

        Reviewed by Zalan Bujtas.

        ColorSpaceSRGB and ColorSpaceDeviceRGB are equivalent now, so convert
        code that creates image buffers tagged with ColorSpaceDeviceRGB to use ColorSpaceSRGB.

        * platform/graphics/GraphicsContext.cpp:
        (WebCore::GraphicsContext::createCompatibleBuffer):
        * platform/graphics/ImageBuffer.h:
        (WebCore::ImageBuffer::create):
        * platform/graphics/cg/BitmapImageCG.cpp:
        (WebCore::BitmapImage::checkForSolidColor):
        * platform/graphics/cg/ColorCG.cpp:
        (WebCore::Color::Color):
        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::sRGBColorSpaceRef): Deleted.
        * platform/graphics/cg/ImageBufferCG.cpp:
        (WebCore::ImageBuffer::putByteArray):
        * platform/graphics/cocoa/IOSurface.mm:
        (IOSurface::createFromImage):
        * platform/graphics/filters/FEFlood.h:
        * platform/graphics/filters/FETile.cpp:
        (WebCore::FETile::platformApplySoftware):
        * platform/graphics/filters/FilterEffect.cpp:
        (WebCore::FilterEffect::FilterEffect):
        * platform/graphics/filters/SourceGraphic.h:
        (WebCore::SourceGraphic::SourceGraphic):
        * rendering/FilterEffectRenderer.cpp:
        (WebCore::FilterEffectRenderer::build):
        (WebCore::FilterEffectRenderer::apply):
        * rendering/RenderThemeMac.mm:
        (WebCore::RenderThemeMac::paintProgressBar):
        * rendering/svg/RenderSVGResourceClipper.cpp:
        (WebCore::RenderSVGResourceClipper::applyClippingToContext):
        * rendering/svg/RenderSVGResourceFilter.cpp:
        (WebCore::RenderSVGResourceFilter::buildPrimitives):
        * rendering/svg/RenderSVGResourceGradient.cpp:
        (WebCore::createMaskAndSwapContextForTextGradient):
        * rendering/svg/RenderSVGResourceMasker.cpp:
        (WebCore::RenderSVGResourceMasker::applyResource):
        * rendering/svg/RenderSVGResourcePattern.cpp:
        (WebCore::RenderSVGResourcePattern::createTileImage):
        * svg/graphics/SVGImage.cpp:
        (WebCore::SVGImage::drawPatternForContainer):
        * svg/graphics/filters/SVGFEImage.cpp:
        (WebCore::FEImage::platformApplySoftware):

2015-11-07  Zalan Bujtas  <zalan@apple.com>

        Crash when subtree layout is set on FrameView while auto size mode is enabled.
        https://bugs.webkit.org/show_bug.cgi?id=150995
        rdar://problem/22785262

        Reviewed by Beth Dakin.

        Autosizing initiates multiple synchronous layouts to calculate preferred view width for current content.
        FrameView::autoSizeIfEnabled() is called from FrameView::layout() while we are in InPreLayout state.
        It is safe to do during full layout.
        However, since we setup the subtree state just before the autoSizeIfEnabled() call, reentering it with
        a newly issued layout confuses SubtreeLayoutStateMaintainer.

        This patch reverses the order of autoSizeIfEnabled() call and the subtree layout state setup.
        It also ensures that the first layout requested by autoSizeIfEnabled() always runs on the whole tree.  

        Test: fast/dynamic/crash-subtree-layout-when-auto-size-enabled.html

        * page/FrameView.cpp:
        (WebCore::FrameView::layout):
        (WebCore::FrameView::convertSubtreeLayoutToFullLayout):
        (WebCore::FrameView::scheduleRelayout):
        (WebCore::FrameView::scheduleRelayoutOfSubtree):
        (WebCore::FrameView::autoSizeIfEnabled):
        * page/FrameView.h:
        * testing/Internals.cpp:
        (WebCore::Internals::enableAutoSizeMode):
        * testing/Internals.h:
        * testing/Internals.idl:

2015-11-07  Chris Dumez  <cdumez@apple.com>

        embed element without src and type attributes should represent nothing
        https://bugs.webkit.org/show_bug.cgi?id=148853
        <rdar://problem/22588235>

        Reviewed by Zalan Bujtas.

        As per the HTML specification, an embed element without src and type
        attributes should represent nothing:
        https://html.spec.whatwg.org/multipage/embedded-content.html#the-embed-element

        This patch fixes the issue by making sure we don't construct a
        renderer for such embed elements.

        The new behavior is consistent with Firefox but differs from Chrome.

        No new tests, already covered by existing tests.

        * html/HTMLEmbedElement.cpp:
        (WebCore::HTMLEmbedElement::rendererIsNeeded):

2015-11-07  Michael Catanzaro  <mcatanzaro@igalia.com>

        Node.h:392:12: warning: 'this' pointer cannot be null in well-defined C++ code
        https://bugs.webkit.org/show_bug.cgi?id=150996

        Reviewed by Andreas Kling.

        Remove ASSERT(this) statement that is triggering hundreds of warnings from Clang.

        * dom/Node.h:
        (WebCore::Node::document):

2015-11-07  Michael Catanzaro  <mcatanzaro@igalia.com>

        Unreviewed, fix GTK build after r191981

        * html/HTMLFormControlElement.cpp:

2015-11-06  Scott Valentine  <svalentine@ikayzo.com>

        Allow an optional hash algorithm to be passed to generateKey for RSA keys.
        https://bugs.webkit.org/show_bug.cgi?id=144938

        Reviewed by Alexey Proskuryakov.

        Test: crypto/subtle/rsa-export-generated-keys.html

        This changeset allows an optional hash parameter to be passed to the generate
        key function for RSA type keys. Previously, there was no way to export generated
        keys, as no hash function could be associated with the key (required for JWK).

        The current WebCrypto API draft requires the hash function to be specified in the
        algorithm object passed to generateKey (http://www.w3.org/TR/WebCryptoAPI 20.4),
        however, they were made optional in this implementation to maintain compatiblity.

        * bindings/js/JSCryptoAlgorithmDictionary.cpp:
        (WebCore::getHashAlgorithm):
        (WebCore::createHmacParams):
        (WebCore::createHmacKeyParams):
        (WebCore::createRsaKeyGenParams):
        (WebCore::createRsaOaepParams):
        (WebCore::createRsaSsaParams):
        (WebCore::JSCryptoAlgorithmDictionary::createParametersForImportKey): Deleted.
        * bindings/js/SerializedScriptValue.cpp:
        (WebCore::CloneDeserializer::readRSAKey):
        * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp:
        (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::generateKey):
        (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey):
        * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp:
        (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::generateKey):
        (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::importKey):
        * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp:
        (WebCore::CryptoAlgorithmRSA_OAEP::generateKey):
        (WebCore::CryptoAlgorithmRSA_OAEP::importKey):
        * crypto/gnutls/CryptoKeyRSAGnuTLS.cpp:
        (WebCore::CryptoKeyRSA::CryptoKeyRSA):
        (WebCore::CryptoKeyRSA::create):
        (WebCore::CryptoKeyRSA::generatePair):
        (WebCore::CryptoKeyRSA::restrictToHash): Deleted.
        * crypto/keys/CryptoKeyRSA.h:
        * crypto/mac/CryptoKeyRSAMac.cpp:
        (WebCore::CryptoKeyRSA::CryptoKeyRSA):
        (WebCore::CryptoKeyRSA::create):
        (WebCore::CryptoKeyRSA::generatePair):
        (WebCore::CryptoKeyRSA::restrictToHash): Deleted.
        * crypto/parameters/CryptoAlgorithmRsaKeyGenParams.h:

2015-11-06  Wenson Hsieh  <wenson_hsieh@apple.com>

        Scrolling iframe inside scrollable div does not work with trackpad
        https://bugs.webkit.org/show_bug.cgi?id=150168
        <rdar://problem/23143931>

        Reviewed by Brent Fulgham.

        When scrolling in an iframe nested under an overflow scrolling region, EventHandler::platformPrepareForWheelEvents
        fails to compute the correct scrollableArea, using the overflow div's scrollable area instead of the iframe's view.
        This causes the latching algorithm to bail out of handling the wheel event. To avoid this, we special-case the
        decision to compute the scrollableArea from the scrollableContainer if we are attempting to scroll in an iframe.

        Test: fast/scrolling/latching/scroll-iframe-in-overflow.html

        * page/mac/EventHandlerMac.mm:
        (WebCore::EventHandler::platformPrepareForWheelEvents):

2015-11-06  Brady Eidson  <beidson@apple.com>

        Modern IDB: Make the result data for a "get" request be an IDBGetResult.
        https://bugs.webkit.org/show_bug.cgi?id=150985

        Reviewed by Alex Christensen.

        No new tests (Refactor, no change in behavior).

        * Modules/indexeddb/IDBGetResult.h:
        (WebCore::IDBGetResult::IDBGetResult):
        (WebCore::IDBGetResult::dataFromBuffer):
        (WebCore::IDBGetResult::isolatedCopy):
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::didGetRecordOnServer):
        
        * Modules/indexeddb/legacy/IDBTransactionBackendOperations.cpp:
        (WebCore::GetOperation::perform):
        
        * Modules/indexeddb/server/IDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::getIndexRecord):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryIndex.cpp:
        (WebCore::IDBServer::MemoryIndex::valueForKeyRange):
        * Modules/indexeddb/server/MemoryIndex.h:
        
        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::indexValueForKeyRange):
        * Modules/indexeddb/server/MemoryObjectStore.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::storeCallback):
        (WebCore::IDBServer::UniqueIDBDatabase::getRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::performGetIndexRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformGetRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::performGetResultCallback):
        (WebCore::IDBServer::UniqueIDBDatabase::performValueDataCallback): Deleted.
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::getRecord):
        
        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::IDBResultData):
        (WebCore::IDBResultData::getRecordSuccess):
        (WebCore::IDBResultData::getResult):
        * Modules/indexeddb/shared/IDBResultData.h:
        (WebCore::IDBResultData::resultData): Deleted.

2015-11-06  Chris Dumez  <cdumez@apple.com>

        Remove unused HTMLFormControlsCollection::namedItem()
        https://bugs.webkit.org/show_bug.cgi?id=150975

        Reviewed by Andreas Kling.

        Remove unused HTMLFormControlsCollection::namedItem().
        JSHTMLFormControlsCollection::namedItem() calls namedItems() on the
        implementation object, not namedItem() because it returns a
        RadioNodeList when there are several matches.

        * html/HTMLFormControlsCollection.cpp:
        (WebCore::firstNamedItem): Deleted.
        (WebCore::HTMLFormControlsCollection::namedItem): Deleted.
        * html/HTMLFormControlsCollection.h:

2015-11-06  Myles C. Maxfield  <mmaxfield@apple.com>

        REGRESSION(r182286): Tatechuyoko following ruby is drawn too far to the right
        https://bugs.webkit.org/show_bug.cgi?id=150923

        Reviewed by Zalan Bujtas.

        Ever since r182286, expansion opportunities in justified ruby were moved to their neighboring
        elements (thereby forbidding trailing nor leading expansions inside ruby). However, when the
        neighboring element is tatechuyoko, we will erroneously honor the expansion opportunity inside
        the tatechuyoko, thereby moving it horizontally.

        Tatechuyoko should never have expansion opportunities inside it.

        Test: fast/text/ruby-justify-tatechuyoko.html

        * rendering/RenderBlockLineLayout.cpp:
        (WebCore::expansionBehaviorForInlineTextBox):

2015-11-06  Mario Sanchez Prada  <mario@endlessm.com>

        Layout Test accessibility/win/linked-elements.html is crashing on win debug
        https://bugs.webkit.org/show_bug.cgi?id=150944

        Reviewed by Chris Fleizach.

        Be more precise ASSERTing on textUnderElement, only checking that the render
        tree is stable before using TextIteraror when in 'IncludeAllChildren' mode.

        * accessibility/AccessibilityRenderObject.cpp:
        (WebCore::AccessibilityRenderObject::textUnderElement):

2015-11-06  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GStreamer] Use MainThreadNotifier to send notifications to main thread in WebKitWebSourceGStreamer
        https://bugs.webkit.org/show_bug.cgi?id=150890

        Reviewed by Žan Doberšek.

        Instead of the GThreadSafeMainLoopSources.

        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
        (webKitWebSrcStop):
        (webKitWebSrcChangeState):
        (webKitWebSrcNeedData):
        (webKitWebSrcEnoughData):
        (webKitWebSrcSeek):
        (StreamingClient::handleResponseReceived):
        (StreamingClient::handleDataReceived):
        (StreamingClient::handleNotifyFinished):
        (webKitWebSrcFinalize): Deleted.
        (webKitWebSrcSetProperty): Deleted.
        (webKitWebSrcGetProperty): Deleted.
        (webKitWebSrcSetExtraHeader): Deleted.
        (webKitWebSrcStart): Deleted.
        (webKitWebSrcGetProtocols): Deleted.
        (webKitWebSrcGetUri): Deleted.
        (webKitWebSrcSetUri): Deleted.
        (webKitWebSrcUriHandlerInit): Deleted.

2015-11-06  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GStreamer] Use MainThreadNotifier to send notifications to main thread in TrackPrivateGStreamer
        https://bugs.webkit.org/show_bug.cgi?id=150889

        Reviewed by Žan Doberšek.

        Instead of the GThreadSafeMainLoopSources.

        * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
        (WebCore::InbandTextTrackPrivateGStreamer::InbandTextTrackPrivateGStreamer):
        (WebCore::InbandTextTrackPrivateGStreamer::handleSample):
        (WebCore::InbandTextTrackPrivateGStreamer::streamChanged):
        * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.h:
        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
        (WebCore::TrackPrivateBaseGStreamer::TrackPrivateBaseGStreamer):
        (WebCore::TrackPrivateBaseGStreamer::disconnect):
        (WebCore::TrackPrivateBaseGStreamer::activeChangedCallback):
        (WebCore::TrackPrivateBaseGStreamer::tagsChangedCallback):
        (WebCore::TrackPrivateBaseGStreamer::tagsChanged):
        (WebCore::TrackPrivateBaseGStreamer::~TrackPrivateBaseGStreamer): Deleted.
        (WebCore::TrackPrivateBaseGStreamer::notifyTrackOfActiveChanged): Deleted.
        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h:

2015-11-06  Csaba Osztrogonác  <ossy@webkit.org>

        Suppress deprecated-declarations warning in WebCore/platform/URL.cpp
        https://bugs.webkit.org/show_bug.cgi?id=150803

        Reviewed by Alexey Proskuryakov.

        * platform/URL.cpp:
        (WebCore::appendEncodedHostname):

2015-11-06  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GStreamer] Do not use GThreadSafeMainLoopSource to send notifications to the main thread in MediaPlayerPrivateGStreamer
        https://bugs.webkit.org/show_bug.cgi?id=150888

        Reviewed by Žan Doberšek.

        Analyzing how the main loop sources were used in GST code I've
        noticed that in most of the cases they are used to send
        notifications to the main thread. The way it works in those cases
        is that some state is updated in whatever thread and we notify the
        main thread to use the new state. There's no data passed to the
        main thread, they are just notifications. I've also noticed that
        we are not doing this exactly as expected in several of those
        cases. GThreadSafeMainLoopSource cancels the current source when a
        new one is scheduled, and that was done this way because previous
        code in GST using GSources directly did it that way. But that's
        not what we want, if there's a notification pending, since the
        state is updated, we can just wait for it to happen instead of
        cancelling and scheduling a new one. I've also noticed that in
        most of the cases where we schedule notifications to the main
        thread, we can be already in the main thread, so we could avoid
        the schedule entirely.
        We can use RunLoop::dispatch() to send notifications to the main
        thread, but there's no way to cancel those tasks. This patch adds
        a new helper class MainThreadNotifier that uses an enum of flags to
        handle different kind of notifications. It uses
        RunLoop::dispatch() to send notifications to the main thread, but
        only if there isn't one pending for the given type.
        This patch also makes signal callbacks static members to be able
        to make the private methods actually private.

        * platform/graphics/gstreamer/MainThreadNotifier.h: Added.
        (WebCore::MainThreadNotifier::MainThreadNotifier):
        (WebCore::MainThreadNotifier::notify):
        (WebCore::MainThreadNotifier::cancelPendingNotifications):
        (WebCore::MainThreadNotifier::addPendingNotification):
        (WebCore::MainThreadNotifier::removePendingNotification):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
        (WebCore::MediaPlayerPrivateGStreamer::setAudioStreamPropertiesCallback):
        (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):
        (WebCore::MediaPlayerPrivateGStreamer::videoChangedCallback):
        (WebCore::MediaPlayerPrivateGStreamer::videoSinkCapsChangedCallback):
        (WebCore::MediaPlayerPrivateGStreamer::audioChangedCallback):
        (WebCore::MediaPlayerPrivateGStreamer::textChangedCallback):
        (WebCore::MediaPlayerPrivateGStreamer::newTextSampleCallback):
        (WebCore::MediaPlayerPrivateGStreamer::sourceChangedCallback):
        (WebCore::MediaPlayerPrivateGStreamer::createAudioSink):
        (WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin):
        (WebCore::MediaPlayerPrivateGStreamer::setAudioStreamProperties): Deleted.
        (WebCore::MediaPlayerPrivateGStreamer::registerMediaEngine): Deleted.
        (WebCore::initializeGStreamerAndRegisterWebKitElements): Deleted.
        (WebCore::MediaPlayerPrivateGStreamer::load): Deleted.
        (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideo): Deleted.
        (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfAudio): Deleted.
        (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfText): Deleted.
        (WebCore::MediaPlayerPrivateGStreamer::canSaveMediaData): Deleted.
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
        (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
        (WebCore::MediaPlayerPrivateGStreamerBase::volumeChangedCallback):
        (WebCore::MediaPlayerPrivateGStreamerBase::muteChangedCallback):
        (WebCore::MediaPlayerPrivateGStreamerBase::repaintCallback):
        (WebCore::MediaPlayerPrivateGStreamerBase::drawCallback):
        (WebCore::MediaPlayerPrivateGStreamerBase::createVideoSink):
        (WebCore::MediaPlayerPrivateGStreamerBase::setStreamVolumeElement):
        (WebCore::MediaPlayerPrivateGStreamerBase::MediaPlayerPrivateGStreamerBase): Deleted.
        (WebCore::MediaPlayerPrivateGStreamerBase::setPipeline): Deleted.
        (WebCore::MediaPlayerPrivateGStreamerBase::handleSyncMessage): Deleted.
        (WebCore::MediaPlayerPrivateGStreamerBase::muted): Deleted.
        (WebCore::MediaPlayerPrivateGStreamerBase::updateTexture): Deleted.
        (WebCore::MediaPlayerPrivateGStreamerBase::droppedFrameCount): Deleted.
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
        (WebCore::MediaPlayerPrivateGStreamerBase::setVisible): Deleted.

2015-11-06  Yoav Weiss  <yoav@yoav.ws>

        Expose HTMLImageElement sizes attribute in IDL
        https://bugs.webkit.org/show_bug.cgi?id=150230

        Reviewed by Darin Adler.

        No new tests, but fixed test expectations for exposed interfaces.

        * html/HTMLImageElement.idl: Make sure that `sizes` is exposed as an IDL attribute, to ensure proper feature detection of sizes support.

2015-11-05  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GStreamer] Use RunLoop::Timer instead of GMainLoopSource in video sink
        https://bugs.webkit.org/show_bug.cgi?id=150807

        Reviewed by Žan Doberšek.

        Since we always wait until the sample is actually rendered we
        don't really need either a thread safe main loop source, nor
        cancelling if already requested and other things GMainLoopSource does.
        This adds a helper class VideoRenderRequestScheduler to use the
        RunLoop::Timer. All the logic to syncronize between threads has
        been moved to this helper class too.

        * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
        (VideoRenderRequestScheduler::VideoRenderRequestScheduler):
        (VideoRenderRequestScheduler::start):
        (VideoRenderRequestScheduler::stop):
        (VideoRenderRequestScheduler::requestRender):
        (VideoRenderRequestScheduler::isUnlocked):
        (VideoRenderRequestScheduler::render):
        (_WebKitVideoSinkPrivate::_WebKitVideoSinkPrivate):
        (webkitVideoSinkRepaintRequested):
        (webkitVideoSinkRender):
        (webkitVideoSinkUnlock):
        (webkitVideoSinkUnlockStop):
        (webkitVideoSinkStop):
        (webkitVideoSinkStart):
        (_WebKitVideoSinkPrivate::~_WebKitVideoSinkPrivate): Deleted.
        (webkitVideoSinkTimeoutCallback): Deleted.
        (unlockSampleMutex): Deleted.

2015-11-05  Nikos Andronikos  <nikos.andronikos-webkit@cisra.canon.com.au>

        Add runtime and compile time flags for enabling Web Animations API and model.
        https://bugs.webkit.org/show_bug.cgi?id=150914

        Reviewed by Benjamin Poulain.

        Add ENABLE_WEB_ANIMATIONS compile time flag, runtime flag webAnimationsEnabled and Expose WK2 preference for runtime flag.

        * Configurations/FeatureDefines.xcconfig:
        * bindings/generic/RuntimeEnabledFeatures.cpp:
        (WebCore::RuntimeEnabledFeatures::RuntimeEnabledFeatures):
        * bindings/generic/RuntimeEnabledFeatures.h:
        (WebCore::RuntimeEnabledFeatures::setWebAnimationsEnabled):
        (WebCore::RuntimeEnabledFeatures::webAnimationsEnabled):

2015-11-05  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r192089.
        https://bugs.webkit.org/show_bug.cgi?id=150966

        This change broke an existing layout test on Yosemite and
        Mavericks (Requested by ryanhaddad on #webkit).

        Reverted changeset:

        "Preview on apple.com/contact with all text selected shows a
        map"
        https://bugs.webkit.org/show_bug.cgi?id=150963
        http://trac.webkit.org/changeset/192089

2015-11-05  Tim Horton  <timothy_horton@apple.com>

        Preview on apple.com/contact with all text selected shows a map
        https://bugs.webkit.org/show_bug.cgi?id=150963
        <rdar://problem/23421750>

        Reviewed by Beth Dakin.

        * editing/mac/DictionaryLookup.h:
        * editing/mac/DictionaryLookup.mm:
        (WebCore::DictionaryLookup::rangeForSelection):
        If the range that Lookup decides to use doesn't intersect the hit point,
        just ignore Lookup.

        (WebCore::DictionaryLookup::rangeAtHitTestResult):
        If the selection-based Lookup fails to find a usable result, fall back
        to looking around the hit point.

2015-11-05  Brady Eidson  <beidson@apple.com>

        Modern IDB: Implement IDBIndex get/getKey/count requests.
        https://bugs.webkit.org/show_bug.cgi?id=150910

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/index-get-count-basic.html
               storage/indexeddb/modern/index-get-count-failures.html

        * Modules/indexeddb/IndexedDB.h:

        * Modules/indexeddb/client/IDBAnyImpl.cpp:
        (WebCore::IDBClient::IDBAny::IDBAny):
        (WebCore::IDBClient::IDBAny::modernIDBIndex):
        * Modules/indexeddb/client/IDBAnyImpl.h:
        (WebCore::IDBClient::IDBAny::create):
        (WebCore::IDBClient::IDBAny::createUndefined):

        * Modules/indexeddb/client/IDBIndexImpl.cpp:
        (WebCore::IDBClient::IDBIndex::count):
        (WebCore::IDBClient::IDBIndex::doCount):
        (WebCore::IDBClient::IDBIndex::get):
        (WebCore::IDBClient::IDBIndex::doGet):
        (WebCore::IDBClient::IDBIndex::getKey):
        (WebCore::IDBClient::IDBIndex::doGetKey):
        * Modules/indexeddb/client/IDBIndexImpl.h:
        (WebCore::IDBClient::IDBIndex::info):
        
        * Modules/indexeddb/client/IDBObjectStoreImpl.h:
        (WebCore::IDBClient::IDBObjectStore::isDeleted):
        (WebCore::IDBClient::IDBObjectStore::modernTransaction):
        
        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::createCount):
        (WebCore::IDBClient::IDBRequest::createGet):
        (WebCore::IDBClient::IDBRequest::IDBRequest):
        (WebCore::IDBClient::IDBRequest::sourceObjectStoreIdentifier):
        (WebCore::IDBClient::IDBRequest::sourceIndexIdentifier):
        (WebCore::IDBClient::IDBRequest::requestedIndexRecordType):
        (WebCore::IDBClient::IDBRequest::setResultToUndefined):
        * Modules/indexeddb/client/IDBRequestImpl.h:
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::requestGetValue):
        (WebCore::IDBClient::IDBTransaction::requestGetKey):
        (WebCore::IDBClient::IDBTransaction::didGetRecordOnServer):
        (WebCore::IDBClient::IDBTransaction::requestCount):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        
        * Modules/indexeddb/client/TransactionOperation.cpp:
        (WebCore::IDBClient::TransactionOperation::TransactionOperation):
        * Modules/indexeddb/client/TransactionOperation.h:
        (WebCore::IDBClient::TransactionOperation::indexIdentifier):
        (WebCore::IDBClient::TransactionOperation::indexRecordType):
        
        * Modules/indexeddb/server/IDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::getRecord):
        (WebCore::IDBServer::MemoryIDBBackingStore::getIndexRecord):
        (WebCore::IDBServer::MemoryIDBBackingStore::getCount):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryIndex.cpp:
        (WebCore::IDBServer::MemoryIndex::valueForKeyRange):
        (WebCore::IDBServer::MemoryIndex::countForKeyRange):
        * Modules/indexeddb/server/MemoryIndex.h:
        
        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::createIndex):
        (WebCore::IDBServer::MemoryObjectStore::countForKeyRange):
        (WebCore::IDBServer::MemoryObjectStore::indexValueForKeyRange):
        * Modules/indexeddb/server/MemoryObjectStore.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::getRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::performGetIndexRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::getCount):
        (WebCore::IDBServer::UniqueIDBDatabase::performGetCount):
        (WebCore::IDBServer::UniqueIDBDatabase::performGetRecord): Deleted.
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        
        * Modules/indexeddb/shared/IDBRequestData.cpp:
        (WebCore::IDBRequestData::IDBRequestData):
        (WebCore::IDBRequestData::objectStoreIdentifier):
        (WebCore::IDBRequestData::indexIdentifier):
        (WebCore::IDBRequestData::indexRecordType):
        * Modules/indexeddb/shared/IDBRequestData.h:

2015-11-05  Zhuo Li  <zachli@apple.com>

        Rename the variable to avoid conflict between the variable and the parameter.
        https://bugs.webkit.org/show_bug.cgi?id=150019.

        Reviewed by Dan Bernstein.

        * platform/cocoa/SearchPopupMenuCocoa.mm:
        (WebCore::typeCheckedRecentSearchesRemovingRecentSearchesAddedAfterDate): Rename `date`
        to `dateAdded` so that it does not have the same name as the parameter passed in.

2015-11-05  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Clean up InjectedScript uses
        https://bugs.webkit.org/show_bug.cgi?id=150921

        Reviewed by Timothy Hatcher.

        * inspector/CommandLineAPIModule.cpp:
        (WebCore::CommandLineAPIModule::injectIfNeeded):
        (WebCore::CommandLineAPIModule::CommandLineAPIModule):
        * inspector/CommandLineAPIModule.h:
        * inspector/WebInjectedScriptManager.cpp:
        (WebCore::WebInjectedScriptManager::didCreateInjectedScript):
        * inspector/WebInjectedScriptManager.h:

2015-11-05  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Put ScriptDebugServer into InspectorEnvironment and cleanup duplicate references
        https://bugs.webkit.org/show_bug.cgi?id=150869

        Reviewed by Brian Burg.

        Refactoring covered by existing tests.

        * WebCore.xcodeproj/project.pbxproj:
        Privately export PageScriptDebuggerAgent.h due to InspectorController.h needing it.

        * inspector/InspectorController.h:
        * inspector/InspectorController.cpp:
        (WebCore::InspectorController::InspectorController):
        (WebCore::InspectorController::scriptDebugServer):
        Own the PageScriptDebugServer.

        * inspector/WorkerInspectorController.h:
        * inspector/WorkerInspectorController.cpp:
        (WebCore::WorkerInspectorController::WorkerInspectorController):
        (WebCore::WorkerInspectorController::scriptDebugServer):
        Own the WorkerScriptDebugServer.

        (WebCore::WorkerInspectorController::vm):
        Use the VM accessed through the worker global object.

        * inspector/InspectorWebAgentBase.h:
        (WebCore::InspectorAgentBase::InspectorAgentBase):
        Given Web agents a m_environment convenience to access the InspectorEnvironment.

        * inspector/InspectorNetworkAgent.cpp:
        (WebCore::InspectorNetworkAgent::timestamp):
        * inspector/InspectorPageAgent.cpp:
        (WebCore::InspectorPageAgent::timestamp):
        (WebCore::InspectorPageAgent::enable):
        (WebCore::InspectorPageAgent::frameStartedLoading):
        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::InspectorTimelineAgent::didCreateFrontendAndBackend):
        (WebCore::InspectorTimelineAgent::willDestroyFrontendAndBackend):
        (WebCore::InspectorTimelineAgent::internalStart):
        (WebCore::InspectorTimelineAgent::internalStop):
        (WebCore::InspectorTimelineAgent::timestamp):
        (WebCore::InspectorTimelineAgent::startFromConsole):
        (WebCore::InspectorTimelineAgent::willCallFunction):
        (WebCore::InspectorTimelineAgent::willEvaluateScript):
        (WebCore::InspectorTimelineAgent::setPageScriptDebugServer): Deleted.
        * inspector/InspectorTimelineAgent.h:
        Use the InspectorEnvironment for VM / ScriptDebugServer.

        * inspector/PageDebuggerAgent.cpp:
        (WebCore::PageDebuggerAgent::PageDebuggerAgent): Deleted.
        (WebCore::PageDebuggerAgent::scriptDebugServer): Deleted.
        * inspector/PageDebuggerAgent.h:
        * inspector/PageRuntimeAgent.cpp:
        (WebCore::PageRuntimeAgent::globalVM): Deleted.
        * inspector/PageRuntimeAgent.h:
        * inspector/WorkerDebuggerAgent.h:
        * inspector/WorkerRuntimeAgent.cpp:
        (WebCore::WorkerRuntimeAgent::globalVM): Deleted.
        * inspector/WorkerRuntimeAgent.h:
        * inspector/WorkerDebuggerAgent.cpp:
        (WebCore::WorkerDebuggerAgent::WorkerDebuggerAgent): Deleted.
        (WebCore::WorkerDebuggerAgent::scriptDebugServer): Deleted.
        Remove now unnecessary subclass code.

        (WebCore::WorkerDebuggerAgent::interruptAndDispatchInspectorCommands):
        One more special case for accessing Worker properties from the ScriptDebugServer.

2015-11-05  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Shield implementation from user mangling Promise.reject and resolve methods
        https://bugs.webkit.org/show_bug.cgi?id=150895

        Reviewed by Youenn Fablet.

        Replace all calls to @Promise.resolve and @Promise.reject with their internal slot counterparts. This way we
        ensure that if the user replaces those constructor methods, our implementation still works.

        Test: streams/streams-promises.html.

        * Modules/streams/ReadableStream.js:
        (initializeReadableStream):
        (cancel):
        * Modules/streams/ReadableStreamInternals.js:
        (privateInitializeReadableStreamReader):
        (cancelReadableStream):
        (readFromReadableStreamReader):
        * Modules/streams/ReadableStreamReader.js:
        (cancel):
        (read):
        (closed):
        * Modules/streams/StreamInternals.js:
        (promiseInvokeOrNoop):
        (promiseInvokeOrFallbackOrNoop):
        * Modules/streams/WritableStream.js:
        (initializeWritableStream):
        (abort):
        (close):
        (write):
        (closed):
        (ready):

2015-11-05  Andreas Kling  <akling@apple.com>

        Give ResourceUsageOverlay a stacked chart for dirty memory per category.
        <https://webkit.org/b/150905>

        Reviewed by Antti Koivisto.

        Refactored the data gathering to operate on "memory categories", a memory category is at
        the top level a VM tag, e.g the VM tag for our bmalloc allocator. It can in turn have
        sub-categories, e.g one for the GC heap, which allocates all of its blocks through bmalloc
        and thus end up in the same tag.

        Each category also has a hard-coded color, which is used consistently in labels and charts.

        Also went back to drawing everything with CGContext directly instead of GraphicsContext
        since the latter is not thread safe.

        * page/ResourceUsageOverlay.h:
        * page/cocoa/ResourceUsageOverlayCocoa.mm:
        (-[WebOverlayLayer drawInContext:]):
        (WebCore::RingBuffer::last):
        (WebCore::MemoryCategoryInfo::MemoryCategoryInfo):
        (WebCore::ResourceUsageData::ResourceUsageData):
        (WebCore::showText):
        (WebCore::drawGraphLabel):
        (WebCore::drawCpuHistory):
        (WebCore::drawGCHistory):
        (WebCore::drawMemHistory):
        (WebCore::drawSlice):
        (WebCore::drawMemoryPie):
        (WebCore::ResourceUsageOverlay::platformDraw):
        (WebCore::categoryForVMTag):
        (WebCore::runSamplerThread):
        (WebCore::drawPlate): Deleted.
        (WebCore::fontCascade): Deleted.
        (WebCore::ResourceUsageOverlay::draw): Deleted.

2015-11-05  Simon Fraser  <simon.fraser@apple.com>

        Having page overlays causes iframe to get composited
        https://bugs.webkit.org/show_bug.cgi?id=150920

        Reviewed by Tim Horton.
        
        When deciding whether to enable compositing for a subframe, don't consult the
        main frame's overlay count. Only do that for the main frame.

        (WebCore::RenderLayerCompositor::updateCompositingLayers):

2015-11-05  Manuel Rego Casasnovas  <rego@igalia.com>

        [css-grid] Support positioned grid children
        https://bugs.webkit.org/show_bug.cgi?id=150837

        Reviewed by Darin Adler.

        According to the spec positioned grid children have
        a special behavior described at:
        https://drafts.csswg.org/css-grid/#abspos

        The idea is that for positioned children the containing block will
        correspond to the padding edges of the grid container, unless the
        grid placement properties are defined.
        This not only affects to positioned grid items (direct children) but
        also to any descendant where the containing block is the grid container.

        In order to manage this special behavior, the patch is overriding
        RenderBlock::layoutPositionedObject() to calculate the position and size
        depending on the grid-placement properties.

        RenderBox class has some changes to calculate the containing block width
        and height for positioned objects (using the override value). And also
        to compute their static position.

        Finally, the positioned items are not taken into account in all the
        different grid methods, in order that they do not interfere the layout
        of the grid as stated in the spec.

        Tests: fast/css-grid-layout/absolute-positioning-grid-container-containing-block.html
               fast/css-grid-layout/absolute-positioning-grid-container-parent.html
               fast/css-grid-layout/grid-positioned-items-background.html
               fast/css-grid-layout/grid-positioned-items-implicit-grid-line.html
               fast/css-grid-layout/grid-positioned-items-implicit-grid.html
               fast/css-grid-layout/grid-positioned-items-unknown-named-grid-line.html
               fast/css-grid-layout/grid-sizing-positioned-items.html
               fast/css-grid-layout/positioned-grid-items-should-not-create-implicit-tracks.html
               fast/css-grid-layout/positioned-grid-items-should-not-take-up-space.html

        * rendering/OrderIterator.cpp:
        (WebCore::OrderIterator::next): Fix method to avoid issues if no items
        are added to the iterator.
        * rendering/RenderBlock.h: Mark layoutPositionedObject() as virtual.
        * rendering/RenderBox.cpp: Add new maps for inline/block extra offsets.
        (WebCore::RenderBox::~RenderBox): Clear the new maps.
        (WebCore::RenderBox::extraInlineOffset): Extra offset that we need to
        apply to positioned grid children due to the grid placement properties.
        (WebCore::RenderBox::extraBlockOffset): Ditto.
        (WebCore::RenderBox::setExtraInlineOffset):
        (WebCore::RenderBox::setExtraBlockOffset):
        (WebCore::RenderBox::clearExtraInlineAndBlockOffests):
        (WebCore::RenderBox::containingBlockLogicalWidthForPositioned): Use the
        override containing block if any.
        (WebCore::RenderBox::containingBlockLogicalHeightForPositioned): Ditto.
        (WebCore::RenderBox::computePositionedLogicalWidth): Add the extra
        offset if it's a positioned element.
        (WebCore::RenderBox::computePositionedLogicalHeight): Ditto.
        * rendering/RenderBox.h:
        (WebCore::RenderBox::scrollbarLogicalWidth): Add utility method.
        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::layoutBlock): Clear grid after layout positioned
        objects instead of at the end of layoutGridItems().
        (WebCore::RenderGrid::placeItemsOnGrid): Ignore positioned items.
        (WebCore::RenderGrid::populateExplicitGridAndOrderIterator): Ditto.
        (WebCore::RenderGrid::layoutGridItems): Ditto.
        (WebCore::RenderGrid::prepareChildForPositionedLayout): Set static
        position for positioned items.
        (WebCore::RenderGrid::layoutPositionedObject): Calculate position and
        size for positioned children.
        (WebCore::RenderGrid::offsetAndBreadthForPositionedChild): Calculate
        extra offset and breadth for positioned children.
        * rendering/RenderGrid.h:
        * rendering/style/GridResolvedPosition.cpp:
        (WebCore::GridResolvedPosition::isNonExistentNamedLineOrArea): Make it a
        public static method.
        (WebCore::GridUnresolvedSpan::adjustGridPositionsFromStyle): Fix calls
        to isNonExistentNamedLineOrArea().
        (WebCore::resolveGridPositionFromStyle): Ditto.
        * rendering/style/GridResolvedPosition.h: Make
        isNonExistentNamedLineOrArea() public.

2015-11-04  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test editing/execCommand/delete-hidden-crash.html
        https://bugs.webkit.org/show_bug.cgi?id=149289
        <rdar://problem/22746352>

        Reviewed by Enrica Casucci.

        This is a merge of Blink r176497:
        https://codereview.chromium.org/340713003

        It ensures the start & end positions in DeleteSelectionCommand::initializePositionData
        are editable.

        Test: editing/execCommand/delete-hidden-crash.html

        * editing/DeleteSelectionCommand.cpp:
        (WebCore::DeleteSelectionCommand::initializePositionData):
        * editing/Editor.cpp:
        (WebCore::Editor::advanceToNextMisspelling):
        * editing/htmlediting.cpp:
        (WebCore::firstEditablePositionAfterPositionInRoot):
        (WebCore::lastEditablePositionBeforePositionInRoot):
        These two functions don't make any sense to return VisiblePosition. Change them
        to return Position instead. Since there is a viable conversion from Position to
        VisiblePosition. It should not change the behavior of any other components depending
        on it.
        * editing/htmlediting.h:

2015-11-03  Myles C. Maxfield  <mmaxfield@apple.com>

        Ruby base ending in tatechuyoko forces a line break before the tatechuyoko
        https://bugs.webkit.org/show_bug.cgi?id=150883

        Reviewed by Darin Adler.

        Asking the width of a 0-length tatechuyoko should return 0.

        Test: fast/text/ruby-tatechuyoko.html

        * rendering/RenderCombineText.cpp:
        (WebCore::RenderCombineText::width):

2015-11-04  Tim Horton  <timothy_horton@apple.com>

        Update the name of a Mail class that we hardcode
        https://bugs.webkit.org/show_bug.cgi?id=150879
        <rdar://problem/23384627>

        Reviewed by Alexey Proskuryakov.

        * editing/cocoa/HTMLConverter.mm:
        (_WebMessageDocumentClass):

2015-11-04  Eric Carlson  <eric.carlson@apple.com>

        [MediaStream] A RealtimeMediaSource should begin producing data automatically
        https://bugs.webkit.org/show_bug.cgi?id=150851
        rdar://problem/23380636

        A RealtimeMediaSource should be producing data unless it is muted, which is not under the 
        control of the application, so a local source should begin producing data as soon as it
        is added to a stream. Remove "producing data" and "enabled" observer callbacks because 
        they don't provide anything that the "muted" callback already provides.
        
        Reviewed by Jer Noble.

        * Modules/mediastream/MediaStreamTrack.cpp:
        (WebCore::MediaStreamTrack::trackProducingDataChanged): Deleted.
        * Modules/mediastream/MediaStreamTrack.h:

        * Modules/mediastream/UserMediaRequest.cpp:
        (WebCore::UserMediaRequest::didCreateStream): Tell sources to begin producing data.

        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::load): Don't call stream->startProducingData,
          it isn't necessary.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::setReadyState): Call characteristicsChanged 
          when the readyState changes.

        * platform/mediastream/MediaStreamPrivate.cpp:
        (WebCore::MediaStreamPrivate::trackProducingDataChanged): Deleted.
        * platform/mediastream/MediaStreamPrivate.h:

        * platform/mediastream/MediaStreamTrackPrivate.cpp:
        (WebCore::MediaStreamTrackPrivate::sourceProducingDataChanged): Deleted.
        (WebCore::MediaStreamTrackPrivate::sourceEnabledChanged): Deleted.
        * platform/mediastream/MediaStreamTrackPrivate.h:

        * platform/mediastream/RealtimeMediaSource.cpp:
        (WebCore::RealtimeMediaSource::isProducingDataDidChange): Deleted.
        (WebCore::RealtimeMediaSource::setEnabled): Deleted.
        * platform/mediastream/RealtimeMediaSource.h:

        * platform/mediastream/mac/AVAudioCaptureSource.mm:
        (WebCore::AVAudioCaptureSource::captureOutputDidOutputSampleBufferFromConnection): !enabled() -> muted().

        * platform/mediastream/mac/AVMediaCaptureSource.mm:
        (WebCore::AVMediaCaptureSource::captureSessionIsRunningDidChange): Don't call isProducingDataDidChange..

        * platform/mediastream/mac/AVVideoCaptureSource.mm:
        (WebCore::AVVideoCaptureSource::processNewFrame): !enabled() -> muted().

2015-11-04  Jer Noble  <jer.noble@apple.com>

        [iOS] <video> elements without audio tracks should not interrupt music
        https://bugs.webkit.org/show_bug.cgi?id=149888

        Reviewed by Eric Carlson.

        Tests: TestWebKitAPI/Tests/WebKit/ios/AudioSessionCategoryIOS.mm

        Only set the AVAudioSession category to "playback" when the video element in question has an
        audio track.

        Add a new PlatformMediaSessionClient method called canProduceAudio(), overridden in HTMLMediaElement
        and AudioContext, which is checked when updating the AudioSession category in 
        PlatformMediaSessionManager::updateSessionState().

        * Modules/webaudio/AudioContext.h:
        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::mediaPlayerCharacteristicChanged):
        * html/HTMLMediaElement.h:
        * platform/audio/PlatformMediaSession.cpp:
        (WebCore::PlatformMediaSession::activeAudioSessionRequired):
        (WebCore::PlatformMediaSession::setCanProduceAudio):
        * platform/audio/PlatformMediaSession.h:
        (WebCore::PlatformMediaSession::canProduceAudio):
        * platform/audio/PlatformMediaSessionManager.cpp:
        (WebCore::PlatformMediaSessionManager::canProduceAudio):
        (WebCore::PlatformMediaSessionManager::sessionCanProduceAudioChanged):
        (WebCore::PlatformMediaSessionManager::activeAudioSessionRequired):
        (WebCore::PlatformMediaSessionManager::sessionWillBeginPlayback):
        * platform/audio/PlatformMediaSessionManager.h:
        * platform/audio/mac/MediaSessionManagerMac.cpp:
        (PlatformMediaSessionManager::updateSessionState):

2015-11-03  Dean Jackson  <dino@apple.com>

        Accept 8 and 4 value hex colors (#RRGGBBAA)
        https://bugs.webkit.org/show_bug.cgi?id=150853
        <rdar://problem/23380930>

        Reviewed by Simon Fraser.

        CSS Color Level 4 allows #RGBA and #RRGGBBAA values
        for colors.

        Test: fast/css/hex-colors.html

        * platform/graphics/Color.cpp:
        (WebCore::parseHexColorInternal): Update the color parsing for
        the new syntax.

2015-11-04  Mario Sanchez Prada  <mario@webkit.org>

        [AX] WebProcess from WebKitGtk+ 2.10.0 compiled in Debug mode hits ASSERT on textUnderElement
        https://bugs.webkit.org/show_bug.cgi?id=150670

        Reviewed by Chris Fleizach.

        Move the ASSERTs stating that the render tree is stable before using the
        TextIterator to their right place, in AccessibilityRenderObject, so that
        we don't crash in debug builds in cases when this condition is irrelevant.

        Test: accessibility/gtk/list-item-with-pseudo-element-crash.html

        * accessibility/AccessibilityNodeObject.cpp:
        (WebCore::AccessibilityNodeObject::textUnderElement): Removed ASSERTs.
        * accessibility/AccessibilityRenderObject.cpp:
        (WebCore::AccessibilityRenderObject::textUnderElement): Added ASSERTs, but
        only before calling plainText and using the right document for the node.

2015-11-04  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Shield streams against user replacing the Promise constructor
        https://bugs.webkit.org/show_bug.cgi?id=150887

        Reviewed by Youenn Fablet.

        With this rework, we shield the Streams implementation against the user doing something like "Promise =
        function() { /* do garbage */ };".

        Test: streams/streams-promises.html.

        * Modules/streams/ReadableStream.js:
        (initializeReadableStream):
        (cancel):
        * Modules/streams/ReadableStreamInternals.js:
        (privateInitializeReadableStreamReader):
        (cancelReadableStream):
        (readFromReadableStreamReader):
        * Modules/streams/ReadableStreamReader.js:
        (cancel):
        (read):
        (closed):
        * Modules/streams/StreamInternals.js:
        (promiseInvokeOrNoop):
        (promiseInvokeOrFallbackOrNoop):
        * Modules/streams/WritableStream.js:
        (initializeWritableStream):
        (abort):
        (close):
        (write):
        (closed):
        (ready):
        * Modules/streams/WritableStreamInternals.js:
        (syncWritableStreamStateWithQueue):

2015-11-04  Antoine Quint  <graouts@apple.com>

        SVG: hit testing region for <text> elements is incorrect
        https://bugs.webkit.org/show_bug.cgi?id=150838

        Reviewed by Dean Jackson.

        Hit testing for SVG <text> elements was using the same code as hit testing
        for CSS-rendered elements. However, in SVG, text elements should only hit
        test based on their character cells, not the rectangular bounds of the
        element, see section 16.6 of the SVG 1.1 specification:
        
        http://www.w3.org/TR/SVG11/interact.html#PointerEventsProperty
        
        So we now hit test each SVGTextFragment of each SVGInlineTextBox
        that is a child of an SVGRootInlineBox to correctly find whether the
        provided HitTestLocation is contained within a character cell. 

        Tests: svg/hittest/text-dominant-baseline-hanging.svg
               svg/hittest/text-multiple-dx-values.svg
               svg/hittest/text-with-multiple-tspans.svg
               svg/hittest/text-with-text-node-and-content-elements.svg
               svg/hittest/text-with-text-node-only.svg
               svg/hittest/text-with-text-path.svg

        * rendering/RootInlineBox.h:
        Remove the final keyword since nodeAtPoint() may now be subclassed as
        implemented in SVGRootInlineBox.
 
        * rendering/svg/SVGInlineTextBox.cpp:
        (WebCore::SVGInlineTextBox::nodeAtPoint):
        Iterate over the SVGTextFragments to look for a fragment containing the
        provided HitTestLocation.
 
        * rendering/svg/SVGRootInlineBox.cpp:
        (WebCore::SVGRootInlineBox::nodeAtPoint):
        * rendering/svg/SVGRootInlineBox.h:
        Override RootInlineBox::nodeAtPoint() to delegate hit testing to the
        children inline boxes.

2015-11-04  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GStreamer] Use RunLoop::Timer for ready state timer in MediaPlayerPrivateGStreamer
        https://bugs.webkit.org/show_bug.cgi?id=150836

        Reviewed by Philippe Normand.

        We don't really need a GThreadSafeMainLoopSource for this simple timer.

        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
        (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
        (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):
        (WebCore::MediaPlayerPrivateGStreamer::readyTimerFired):
        (WebCore::MediaPlayerPrivateGStreamer::changePipelineState):
        (WebCore::MediaPlayerPrivateGStreamer::loadingFailed):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:

2015-11-04  Frederic Wang  <fred.wang@free.fr>

        Add support for the USE_TYPO_METRICS flag on iOS
        https://bugs.webkit.org/show_bug.cgi?id=131839

        Reviewed by Darin Adler.

        Make the iOS Font service use the typo metrics for fonts with a MATH table when the OS/2 USE_TYPO_METRICS flag is set.
        The code shared by iOS, OS X and AppleWin is moved into a separate OpenTypeCG module.

        No new tests because this is already tested by fonts/use-typo-metrics-1.html

        * PlatformAppleWin.cmake: Add OpenTypeCG files.
        * PlatformMac.cmake: ditto.
        * WebCore.vcxproj/WebCore.vcxproj: ditto.
        * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
        * WebCore.xcodeproj/project.pbxproj: ditto.
        * platform/graphics/cocoa/FontCocoa.mm:
        (WebCore::Font::platformInit): Use functions from OpenTypeCG.
        (WebCore::fontHasMathTable): Deleted.
        * platform/graphics/ios/FontServicesIOS.mm:
        (WebCore::FontServicesIOS::FontServicesIOS): Use the typo metrics for fonts with a MATH table when the OS/2 USE_TYPO_METRICS flag is set.
        * platform/graphics/opentype/OpenTypeCG.h: Added.
        * platform/graphics/opentype/OpenTypeCG.cpp: Added.
        (WebCore::OpenType::fontHasMathTable): Move this code from FontCocoa.mm.
        (WebCore::OpenType::readShortFromTable): Inline function to read a 16-bit big endian integer from the OS/2 table and to cast it into a short integer.
        (WebCore::OpenType::tryGetTypoMetrics): Move this code from FontCocoa.mm.
        * platform/graphics/opentype/OpenTypeTypes.h: Add missing Glyph.h header needed by TableWithCoverage::getCoverageIndex.
        * platform/graphics/win/SimpleFontDataCGWin.cpp:
        (WebCore::Font::platformInit): Use functions from OpenTypeCG.

2015-11-04  Chris Dumez  <cdumez@apple.com>

        Regression(r191652): Colloquy doesn’t render any chat content
        https://bugs.webkit.org/show_bug.cgi?id=150861
        <rdar://problem/23381007>

        Reviewed by Antti Koivisto.

        Do a partial revert of r191652 as this web-exposed behavior change
        broke Colloquy app. This only reverts the code change, the tests
        are left as is so that they don't rely of the frame ID setting the
        Window name.

        * html/HTMLFrameElementBase.cpp:
        (WebCore::HTMLFrameElementBase::parseAttribute):
        (WebCore::HTMLFrameElementBase::setNameAndOpenURL):

2015-11-03  Brady Eidson  <beidson@apple.com>

        Modern IDB: Fill out IDBIndex, create MemoryIndex in backing store.
        https://bugs.webkit.org/show_bug.cgi?id=150868

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/create-index-failures.html
               storage/indexeddb/modern/get-index-failures.html
               storage/indexeddb/modern/idbindex-properties-basic.html

        Note: The MemoryIndex in the backing store doesn't actually do anything yet.
        
        That's coming next.
    
        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:

        * Modules/indexeddb/IDBIndex.h:

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::createIndex):
        (WebCore::IDBClient::IDBConnectionToServer::didCreateIndex):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:

        * Modules/indexeddb/client/IDBCursorWithValueImpl.h:

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::didCreateIndexInfo):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:

        * Modules/indexeddb/client/IDBIndexImpl.cpp:
        (WebCore::IDBClient::IDBIndex::create):
        (WebCore::IDBClient::IDBIndex::IDBIndex):
        (WebCore::IDBClient::IDBIndex::objectStore):
        (WebCore::IDBClient::IDBIndex::keyPathAny):
        (WebCore::IDBClient::IDBIndex::openCursor):
        (WebCore::IDBClient::IDBIndex::count):
        (WebCore::IDBClient::IDBIndex::openKeyCursor):
        (WebCore::IDBClient::IDBIndex::get):
        (WebCore::IDBClient::IDBIndex::getKey):
        * Modules/indexeddb/client/IDBIndexImpl.h:

        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::createIndex):
        (WebCore::IDBClient::IDBObjectStore::index):
        * Modules/indexeddb/client/IDBObjectStoreImpl.h:

        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::createObjectStore):
        (WebCore::IDBClient::IDBTransaction::createIndex):
        (WebCore::IDBClient::IDBTransaction::createIndexOnServer):
        (WebCore::IDBClient::IDBTransaction::didCreateIndexOnServer):
        * Modules/indexeddb/client/IDBTransactionImpl.h:

        * Modules/indexeddb/legacy/LegacyIndex.h:

        * Modules/indexeddb/server/IDBBackingStore.h:

        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didCreateIndex):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:

        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::createIndex):
        * Modules/indexeddb/server/IDBServer.h:

        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::addNewIndex):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::addExistingIndex):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:

        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::createIndex):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:

        * Modules/indexeddb/server/MemoryIndex.cpp: Added.
        (WebCore::IDBServer::MemoryIndex::create):
        (WebCore::IDBServer::MemoryIndex::MemoryIndex):
        (WebCore::IDBServer::MemoryIndex::~MemoryIndex):
        * Modules/indexeddb/server/MemoryIndex.h: Added.
        (WebCore::IDBServer::MemoryIndex::info):

        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::createIndex):
        (WebCore::IDBServer::MemoryObjectStore::registerIndex):
        (WebCore::IDBServer::MemoryObjectStore::unregisterIndex):
        * Modules/indexeddb/server/MemoryObjectStore.h:

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::createIndex):
        (WebCore::IDBServer::UniqueIDBDatabase::performCreateIndex):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformCreateIndex):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::didCreateIndex):
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::createIndex):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:

        * Modules/indexeddb/shared/IDBDatabaseInfo.cpp:
        (WebCore::IDBDatabaseInfo::getInfoForExistingObjectStore):
        (WebCore::IDBDatabaseInfo::infoForExistingObjectStore):
        * Modules/indexeddb/shared/IDBDatabaseInfo.h:

        * Modules/indexeddb/shared/IDBIndexInfo.cpp:
        (WebCore::IDBIndexInfo::IDBIndexInfo):
        (WebCore::IDBIndexInfo::isolatedCopy):
        * Modules/indexeddb/shared/IDBIndexInfo.h:
        (WebCore::IDBIndexInfo::identifier):
        (WebCore::IDBIndexInfo::objectStoreIdentifier):

        * Modules/indexeddb/shared/IDBObjectStoreInfo.cpp:
        (WebCore::IDBObjectStoreInfo::createNewIndex):
        (WebCore::IDBObjectStoreInfo::addExistingIndex):
        (WebCore::IDBObjectStoreInfo::hasIndex):
        (WebCore::IDBObjectStoreInfo::infoForExistingIndex):
        (WebCore::IDBObjectStoreInfo::isolatedCopy):
        * Modules/indexeddb/shared/IDBObjectStoreInfo.h:

        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::createIndexSuccess):
        * Modules/indexeddb/shared/IDBResultData.h:

        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didCreateIndex):
        (WebCore::InProcessIDBServer::createIndex):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

        * bindings/js/JSIDBObjectStoreCustom.cpp:
        (WebCore::JSIDBObjectStore::createIndex):

        * platform/CrossThreadCopier.cpp:
        (WebCore::IDBIndexInfo>::copy):
        * platform/CrossThreadCopier.h:

2015-11-03  Andy Estes  <aestes@apple.com>

        [Cocoa] Only query for kMGQDeviceName on iOS
        https://bugs.webkit.org/show_bug.cgi?id=150858

        Reviewed by Brent Fulgham.

        * platform/ios/Device.cpp:
        (WebCore::deviceName): On non-iOS platorms, just return "iPhone" as the device name.

2015-11-03  Geoffrey Garen  <ggaren@apple.com>

        Provide a way to turn off const in WebKit2.

        Reviewed by Sam Weinig.

        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::JSDOMWindowBase::commonVM):
        * page/Settings.h:
        (WebCore::Settings::shouldUseHighResolutionTimers):
        (WebCore::Settings::shouldRewriteConstAsVar):
        (WebCore::Settings::setShouldRewriteConstAsVar):
        (WebCore::Settings::backgroundShouldExtendBeyondPage):

2015-11-03  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Remove duplication among ScriptDebugServer subclasses
        https://bugs.webkit.org/show_bug.cgi?id=150860

        Reviewed by Timothy Hatcher.

        Refactoring covered by existing tests.

        * bindings/js/WorkerScriptDebugServer.cpp:
        (WebCore::WorkerScriptDebugServer::attachDebugger):
        (WebCore::WorkerScriptDebugServer::detachDebugger):
        (WebCore::WorkerScriptDebugServer::addListener): Deleted.
        (WebCore::WorkerScriptDebugServer::removeListener): Deleted.
        * bindings/js/WorkerScriptDebugServer.h:
        * inspector/PageDebuggerAgent.cpp:
        (WebCore::PageDebuggerAgent::startListeningScriptDebugServer): Deleted.
        (WebCore::PageDebuggerAgent::stopListeningScriptDebugServer): Deleted.
        * inspector/PageDebuggerAgent.h:
        * inspector/PageScriptDebugServer.cpp:
        (WebCore::PageScriptDebugServer::attachDebugger):
        (WebCore::PageScriptDebugServer::detachDebugger):
        (WebCore::PageScriptDebugServer::addListener): Deleted.
        (WebCore::PageScriptDebugServer::removeListener): Deleted.
        * inspector/PageScriptDebugServer.h:
        * inspector/WorkerDebuggerAgent.cpp:
        (WebCore::WorkerDebuggerAgent::startListeningScriptDebugServer): Deleted.
        (WebCore::WorkerDebuggerAgent::stopListeningScriptDebugServer): Deleted.
        * inspector/WorkerDebuggerAgent.h:

2015-11-03  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test scrollbars/custom-scrollbar-appearance-property.html
        https://bugs.webkit.org/show_bug.cgi?id=149312
        <rdar://problem/22748910>

        Reviewed by Darin Adler.

        This is a merge from Blink r167503:
        https://codereview.chromium.org/173433002

        Test: scrollbars/custom-scrollbar-appearance-property.html

        * rendering/RenderThemeMac.mm:
        (WebCore::RenderThemeMac::paintSearchFieldCancelButton):
        (WebCore::RenderThemeMac::paintSearchFieldResultsDecorationPart):

2015-11-03  Andreas Kling  <akling@apple.com>

        ResourceUsageOverlay should show GC-owned malloc memory.
        <https://webkit.org/b/150846>

        Reviewed by Anders Carlsson.

        Add a memory category for GC-owned malloc memory. This carves a significant chunk off of
        the gigantic "bmalloc" mystery slice.

        * page/ResourceUsageOverlay.h:
        * page/cocoa/ResourceUsageOverlayCocoa.mm:
        (WebCore::drawMemoryPie):
        (WebCore::ResourceUsageOverlay::draw):
        (WebCore::runSamplerThread):

2015-11-03  Saam barati  <sbarati@apple.com>

        Rewrite "const" as "var" for iTunes/iBooks on the Mac
        https://bugs.webkit.org/show_bug.cgi?id=150852

        Reviewed by Geoffrey Garen.

        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::JSDOMWindowBase::commonVM):

2015-10-30  Jon Honeycutt  <jhoneycutt@apple.com>

        Implement support for the autocomplete attribute
        https://bugs.webkit.org/show_bug.cgi?id=150731
        rdar://problem/21078968

        The autocomplete attribute is defined by
        https://html.spec.whatwg.org/multipage/forms.html#autofill.

        Reviewed by Brent Fulgham.

        Test: fast/forms/autocomplete-tokens.html

        * html/HTMLFormControlElement.cpp:
        (WebCore::isContactToken):
        Return true if this is a contact token.
        (WebCore::categoryForAutofillFieldToken):
        Adds all of the autofill field tokens to a map, and returns the
        category for a given token.
        (WebCore::maxTokensForAutofillFieldCategory):
        Return the maximum number of tokens an autofill category supports.
        (WebCore::HTMLFormControlElement::parseAutocompleteAttribute):
        Implement the processing model defined in
        https://html.spec.whatwg.org/multipage/forms.html#processing-model-3
        with respect to the IDL-exposed autofill value.
        (WebCore::HTMLFormControlElement::setAutocomplete):
        Set the autocomplete attribute to the given string.

        * html/HTMLFormControlElement.h:
        Declare setAutocomplete() and autocomplete().

        * html/HTMLInputElement.idl:
        Remove the Reflect attribute. We now have custom processing for getting
        this attribute.

        * html/HTMLSelectElement.idl:
        Declare the autocomplete attribute.

        * html/HTMLTextAreaElement.idl:
        Ditto.

2015-11-03  Brady Eidson  <beidson@apple.com>

        Modern IDB: Land empty IDBCursor/Index IDL implementations.
        https://bugs.webkit.org/show_bug.cgi?id=150839

        Reviewed by Alex Christensen.

        No new tests (No change in behavior).

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:

        * Modules/indexeddb/IDBIndex.h:
        
        * Modules/indexeddb/client/IDBCursorImpl.cpp: Added.
        (WebCore::IDBClient::IDBCursor::~IDBCursor):
        (WebCore::IDBClient::IDBCursor::direction):
        (WebCore::IDBClient::IDBCursor::key):
        (WebCore::IDBClient::IDBCursor::primaryKey):
        (WebCore::IDBClient::IDBCursor::value):
        (WebCore::IDBClient::IDBCursor::source):
        (WebCore::IDBClient::IDBCursor::update):
        (WebCore::IDBClient::IDBCursor::advance):
        (WebCore::IDBClient::IDBCursor::continueFunction):
        (WebCore::IDBClient::IDBCursor::deleteFunction):
        * Modules/indexeddb/client/IDBCursorImpl.h: Added.
        
        * Modules/indexeddb/client/IDBCursorWithValueImpl.cpp: Added.
        * Modules/indexeddb/client/IDBCursorWithValueImpl.h: Added.
        
        * Modules/indexeddb/client/IDBIndexImpl.cpp: Added.
        (WebCore::IDBClient::IDBIndex::~IDBIndex):
        (WebCore::IDBClient::IDBIndex::name):
        (WebCore::IDBClient::IDBIndex::objectStore):
        (WebCore::IDBClient::IDBIndex::keyPathAny):
        (WebCore::IDBClient::IDBIndex::keyPath):
        (WebCore::IDBClient::IDBIndex::unique):
        (WebCore::IDBClient::IDBIndex::multiEntry):
        (WebCore::IDBClient::IDBIndex::openCursor):
        (WebCore::IDBClient::IDBIndex::count):
        (WebCore::IDBClient::IDBIndex::openKeyCursor):
        (WebCore::IDBClient::IDBIndex::get):
        (WebCore::IDBClient::IDBIndex::getKey):
        * Modules/indexeddb/client/IDBIndexImpl.h: Copied from Source/WebCore/Modules/indexeddb/IDBIndex.h.
        
        * Modules/indexeddb/legacy/LegacyIndex.h:
        (WebCore::LegacyIndex::id):
        
        * Modules/indexeddb/shared/IDBIndexInfo.cpp: Added.
        * Modules/indexeddb/shared/IDBIndexInfo.h: Added.
        (WebCore::IDBIndexInfo::name):
        (WebCore::IDBIndexInfo::keyPath):
        (WebCore::IDBIndexInfo::unique):
        (WebCore::IDBIndexInfo::multiEntry):

2015-11-03  Myles C. Maxfield  <mmaxfield@apple.com>

        Addressing post-review comments on r191934.

        Unreviewed.

        * platform/graphics/mac/FontCustomPlatformData.cpp:
        (WebCore::FontCustomPlatformData::supportsFormat):

2015-11-03  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Move ScriptDebugServer::Task to WorkerScriptDebugServer where it is actually used
        https://bugs.webkit.org/show_bug.cgi?id=150847

        Reviewed by Timothy Hatcher.

        * bindings/js/WorkerScriptDebugServer.cpp:
        (WebCore::WorkerScriptDebugServer::interruptAndRunTask):
        * bindings/js/WorkerScriptDebugServer.h:
        * inspector/WorkerDebuggerAgent.cpp:

2015-11-03  Tim Horton  <timothy_horton@apple.com>

        Fix the build.

        * platform/Widget.h:
        (WebCore::Widget::boundsRect):
        (WebCore::Widget::resize):

2015-11-03  Myles C. Maxfield  <mmaxfield@apple.com>

        font-variant-* properties in @font-face declarations should be honored
        https://bugs.webkit.org/show_bug.cgi?id=149771

        Reviewed by Simon Fraser.

        According to the CSS Fonts Level 3 spec, web authors are allowed to put
        font-feature-settings / font-variant-* inside @font-face blocks. These
        properties are supposed to be applied at a specific time during the
        font selection algorithm.

        This patch gives a FontFeatureSettings object and a FontVariantSettings
        object to CSSFontFace, and moves common parsing logic from
        StyleBuilderCustom to a shared location. Then, once the two properties
        are parsed from the @font-face block, the relevant data structures are
        passed down into the font selection algorithm. This algorithm then
        consults with these values at the correct time (inside
        preparePlatformFont()).

        Tests: css3/font-feature-settings-font-face-rendering.html
               css3/font-variant-font-face-all.html
               css3/font-variant-font-face-override.html

        * WebCore.xcodeproj/project.pbxproj: Add a header for the common
        location of parsing font-variant-ligatures, font-variant-numeric,
        and font-variant-east-asian.
        * css/CSSFontFace.cpp:
        (WebCore::CSSFontFace::font): Pass the relevant data structures
        into the font selection algorithm.
        * css/CSSFontFace.h: Add FontFeatureSettings and FontVariantSettings
        member variables.
        (WebCore::CSSFontFace::insertFeature):
        (WebCore::CSSFontFace::setVariantCommonLigatures):
        (WebCore::CSSFontFace::setVariantDiscretionaryLigatures):
        (WebCore::CSSFontFace::setVariantHistoricalLigatures):
        (WebCore::CSSFontFace::setVariantContextualAlternates):
        (WebCore::CSSFontFace::setVariantPosition):
        (WebCore::CSSFontFace::setVariantCaps):
        (WebCore::CSSFontFace::setVariantNumericFigure):
        (WebCore::CSSFontFace::setVariantNumericSpacing):
        (WebCore::CSSFontFace::setVariantNumericFraction):
        (WebCore::CSSFontFace::setVariantNumericOrdinal):
        (WebCore::CSSFontFace::setVariantNumericSlashedZero):
        (WebCore::CSSFontFace::setVariantAlternates):
        (WebCore::CSSFontFace::setVariantEastAsianVariant):
        (WebCore::CSSFontFace::setVariantEastAsianWidth):
        (WebCore::CSSFontFace::setVariantEastAsianRuby):
        * css/CSSFontFaceSource.cpp:
        (WebCore::CSSFontFaceSource::font): Pass the relevant data
        structures into the font selection algorithm.
        * css/CSSFontFaceSource.h: Ditto.
        * css/CSSFontSelector.cpp:
        (WebCore::CSSFontSelector::addFontFaceRule): Call the shared
        parsing logic to populate the FontFeatureSettings and
        FontVariantSettings members.
        * css/FontVariantBuilder.h: Added. Destination for shared parsing
        logic.
        (WebCore::applyValueFontVariantLigatures):
        (WebCore::applyValueFontVariantNumeric):
        (WebCore::applyValueFontVariantEastAsian):
        * css/StyleBuilderCustom.h: Source for shared parsing logic.
        (WebCore::StyleBuilderCustom::applyValueFontVariantLigatures):
        (WebCore::StyleBuilderCustom::applyValueFontVariantNumeric):
        (WebCore::StyleBuilderCustom::applyValueFontVariantEastAsian):
        * loader/cache/CachedFont.cpp: Pass the relevant data structures
        into the font selection algorithm.
        (WebCore::CachedFont::createFont):
        (WebCore::CachedFont::platformDataFromCustomData):
        * loader/cache/CachedFont.h: Ditto.
        * loader/cache/CachedSVGFont.cpp: Ditto.
        (WebCore::CachedSVGFont::createFont):
        (WebCore::CachedSVGFont::platformDataFromCustomData):
        * loader/cache/CachedSVGFont.h: Ditto.
        * platform/graphics/FontCache.h: Ditto.
        * platform/graphics/FontCascade.cpp:
        (WebCore::FontCascade::codePath): Adjust comment.
        * platform/graphics/cocoa/FontCacheCoreText.cpp:
        (WebCore::preparePlatformFont): Consult with the newly parsed values.
        (WebCore::fontWithFamily): Pass the relevant data structures into the
        font selection algorithm.
        (WebCore::FontCache::systemFallbackForCharacters): Ditto.
        * platform/graphics/mac/FontCustomPlatformData.cpp:
        (WebCore::FontCustomPlatformData::fontPlatformData): Ditto.
        * platform/graphics/mac/FontCustomPlatformData.h: Ditto.

2015-11-03  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Handle or Remove ParseHTML Timeline Event Records
        https://bugs.webkit.org/show_bug.cgi?id=150689

        Reviewed by Timothy Hatcher.

        Remove ParseHTML nesting recordings. We were not using them
        and for most pages their self-time is very small in comparison
        to other events. We may consider adding it back later for
        UI purposes but for now the frontend doesn't use the records
        so lets remove it.

        * html/parser/HTMLDocumentParser.cpp:
        (WebCore::HTMLDocumentParser::pumpTokenizer): Deleted.
        * inspector/InspectorInstrumentation.cpp:
        (WebCore::InspectorInstrumentation::willWriteHTMLImpl): Deleted.
        (WebCore::InspectorInstrumentation::didWriteHTMLImpl): Deleted.
        * inspector/InspectorInstrumentation.h:
        (WebCore::InspectorInstrumentation::willWriteHTML): Deleted.
        (WebCore::InspectorInstrumentation::didWriteHTML): Deleted.
        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::InspectorTimelineAgent::willWriteHTML): Deleted.
        (WebCore::InspectorTimelineAgent::didWriteHTML): Deleted.
        (WebCore::toProtocol): Deleted.
        * inspector/InspectorTimelineAgent.h:
        * inspector/TimelineRecordFactory.cpp:
        (WebCore::TimelineRecordFactory::createParseHTMLData): Deleted.
        * inspector/TimelineRecordFactory.h:

2015-11-03  Keith Rollin  <krollin@apple.com>

        HTMLOptionElement.text should never return the value of label
        https://bugs.webkit.org/show_bug.cgi?id=148862
        rdar://problem/22589226

        Reviewed by Darin Adler.

        According to the HTML spec, `option` elements should have the
        following behavior:

            - the `text` property should return text contents of element
            - the `label` property should return value of label attribute if
              it exists, else return text property
            - the UI should display label property

        12 years ago, in order to be compatibile with browsers of the time, we
        diverged from this behavior: the text property behaved like the label
        property, and the text property was used for display. This resulted in
        our UI incidentally conforming to the spec, but also in the text
        property *not* conforming to the spec. See <rdar://problem/3532519>
        for discussion on this change.

        The behavior of the browsers we were conforming to has changed. In
        particular, the text property in Firefox now conforms to the spec
        instead of behaving as we did. Therefore, it's less important to
        retain our old behavior for the sake of compatibility. This check-in
        brings us into conformance with the spec. The result is that the UI
        stays the same, but the text property will return different values than
        it used to if the option element has a label attribute that used to
        hide it.

        Updated tests:
        - fast/dom/HTMLOptionElement/option-text.html:
        - fast/forms/HTMLOptionElement_label01.html:
        - fast/forms/HTMLOptionElement_label02.html:
        - fast/forms/HTMLOptionElement_label03.html:
        - fast/forms/HTMLOptionElement_label04.html:
        - fast/forms/HTMLOptionElement_label05.html:
        - fast/forms/HTMLOptionElement_label06.html:
        - fast/forms/HTMLOptionElement_label07.html:
        - fast/forms/option-value-and-label.html:

        * accessibility/AccessibilityListBoxOption.cpp:
        (WebCore::AccessibilityListBoxOption::stringValue):
        * accessibility/AccessibilityMenuListOption.cpp:
        (WebCore::AccessibilityMenuListOption::stringValue):
        * html/HTMLOptionElement.cpp:
        (WebCore::HTMLOptionElement::text):
        (WebCore::HTMLOptionElement::textIndentedToRespectGroupLabel):

2015-11-03  Andreas Kling  <akling@apple.com>

        ResourceUsageOverlay should draw itself using WebCore::GraphicsContext.
        <https://webkit.org/b/150841>

        Reviewed by Antti Koivisto.

        Use WebCore text drawing primitives instead of poking at the CGContext directly.
        And stop using deprecated CoreGraphics APIs, too.

        * page/cocoa/ResourceUsageOverlayCocoa.mm:
        (WebCore::drawCpuHistory):
        (WebCore::drawGCHistory):

            Adjust for unflipped Y axis.

        (WebCore::fontCascade):
        (WebCore::showText):

            Draw using WebCore text drawing primitives.

        (WebCore::ResourceUsageOverlay::draw):

            Remove CGContext calls and stop flipping the Y axis.

2015-11-03  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        [Streams API] Vended promise capabilities should not need @resolve/@reject fields
        https://bugs.webkit.org/show_bug.cgi?id=150835

        Reviewed by Darin Adler.

        No change in behavior, covered by existing tests.

        * Modules/streams/ReadableStreamInternals.js:
        (privateInitializeReadableStreamReader): Removed @resolve/@reject fields from resolved/rejected @closedPromiseCapability.
        * Modules/streams/WritableStream.js:
        (initializeWritableStream): Removed @resolve/@reject fields from resolved readyPromiseCapability.
        * Modules/streams/WritableStreamInternals.js:
        (syncWritableStreamStateWithQueue): Updated code to be closer to spec and removing the need to resolve an already resolved promise.

2015-11-03  Hunseop Jeong  <hs85.jeong@samsung.com>

        Replace 0 and NULL with nullptr in WebCore/dom.
        https://bugs.webkit.org/show_bug.cgi?id=150788

        Reviewed by Darin Adler.

        No new tests because there is no behavior change.

        * dom/Attr.cpp:
        (WebCore::Attr::Attr):
        (WebCore::Attr::detachFromElementWithValue):
        (WebCore::Attr::attachToElement):
        * dom/Attr.h:
        * dom/CheckedRadioButtons.cpp:
        (WebCore::RadioButtonGroup::updateCheckedState):
        (WebCore::CheckedRadioButtons::checkedButtonForGroup):
        (WebCore::CheckedRadioButtons::isInRequiredGroup):
        * dom/ChildListMutationScope.cpp:
        (WebCore::ChildListMutationAccumulator::enqueueMutationRecord):
        * dom/ContainerNode.cpp:
        (WebCore::ContainerNode::removeBetween):
        * dom/ContainerNode.h:
        (WebCore::ContainerNode::ContainerNode):
        * dom/ContainerNodeAlgorithms.cpp:
        (WebCore::notifyNodeRemovedFromDocument):
        * dom/Document.h:
        (WebCore::Document::wellFormed):
        (WebCore::Document::scriptRunner):
        (WebCore::Document::moduleLoader):
        (WebCore::Document::currentScript):
        (WebCore::Document::webkitFullscreenElement):
        * dom/DocumentOrderedMap.h:
        (WebCore::DocumentOrderedMap::MapEntry::MapEntry):
        * dom/DocumentParser.cpp:
        (WebCore::DocumentParser::detach):
        (WebCore::DocumentParser::suspendScheduledTasks):
        * dom/Element.cpp:
        (WebCore::Element::setAttributeInternal):
        (WebCore::Element::shadowRoot):
        (WebCore::Element::blur):
        (WebCore::Element::beforePseudoElement):
        (WebCore::Element::afterPseudoElement):
        (WebCore::Element::setBeforePseudoElement):
        * dom/Event.cpp:
        (WebCore::Event::Event):
        * dom/Event.h:
        (WebCore::Event::legacyReturnValue):
        (WebCore::Event::setLegacyReturnValue):
        (WebCore::Event::clipboardData):
        * dom/EventContext.cpp:
        (WebCore::MouseOrFocusEventContext::MouseOrFocusEventContext):
        * dom/EventDispatcher.cpp:
        (WebCore::EventPath::lastContextIfExists):
        (WebCore::EventDispatcher::dispatchEvent):
        * dom/EventListenerMap.cpp:
        (WebCore::EventListenerMap::copyEventListenersNotCreatedFromMarkupToTarget):
        (WebCore::EventListenerIterator::EventListenerIterator):
        * dom/EventListenerMap.h:
        * dom/EventTarget.cpp:
        (WebCore::EventTarget::fireEventListeners):
        * dom/FocusEvent.cpp:
        (WebCore::FocusEventInit::FocusEventInit):
        * dom/GenericEventQueue.cpp:
        (WebCore::GenericEventQueue::enqueueEvent):
        * dom/IdTargetObserverRegistry.h:
        (WebCore::IdTargetObserverRegistry::IdTargetObserverRegistry):
        (WebCore::IdTargetObserverRegistry::notifyObservers):
        * dom/IgnoreDestructiveWriteCountIncrementer.h:
        (WebCore::IgnoreDestructiveWriteCountIncrementer::IgnoreDestructiveWriteCountIncrementer):
        * dom/MessageEvent.cpp:
        (WebCore::MessageEvent::MessageEvent):
        * dom/MessageEvent.h:
        * dom/MessagePort.cpp:
        (WebCore::MessagePort::contextDestroyed):
        (WebCore::MessagePort::dispatchMessages):
        (WebCore::MessagePort::locallyEntangledPort):
        (WebCore::MessagePort::disentanglePorts):
        * dom/MouseEvent.cpp:
        (WebCore::MouseEventInit::MouseEventInit):
        (WebCore::MouseEvent::cloneFor):
        * dom/MouseEvent.h:
        (WebCore::MouseEvent::dataTransfer):
        * dom/MouseRelatedEvent.cpp:
        (WebCore::MouseRelatedEvent::MouseRelatedEvent):
        (WebCore::MouseRelatedEvent::computeRelativePosition):
        * dom/MutationEvent.h:
        * dom/Node.cpp:
        (WebCore::Node::nodeLists):
        (WebCore::Node::clearNodeLists):
        (WebCore::Node::nonShadowBoundaryParentNode):
        (WebCore::Node::parentOrShadowHostElement):
        * dom/Node.h:
        * dom/NodeRareData.h:
        (WebCore::NodeListsNodeData::removeCachedCollection):
        (WebCore::NodeListsNodeData::isEmpty):
        * dom/PendingScript.cpp:
        (WebCore::PendingScript::releaseElementAndClear):
        * dom/PopStateEvent.cpp:
        (WebCore::PopStateEvent::PopStateEvent):
        * dom/Position.h:
        (WebCore::Position::deprecatedNode):
        (WebCore::Position::document):
        (WebCore::Position::rootEditableElement):
        * dom/PositionIterator.cpp:
        (WebCore::PositionIterator::decrement):
        * dom/PositionIterator.h:
        (WebCore::PositionIterator::PositionIterator):
        * dom/ProcessingInstruction.cpp:
        (WebCore::ProcessingInstruction::ProcessingInstruction):
        (WebCore::ProcessingInstruction::checkStyleSheet):
        (WebCore::ProcessingInstruction::parseStyleSheet):
        * dom/ProcessingInstruction.h:
        * dom/RangeBoundaryPoint.h:
        (WebCore::RangeBoundaryPoint::RangeBoundaryPoint):
        * dom/ScriptElement.cpp:
        (WebCore::ScriptElement::ScriptElement):
        (WebCore::ScriptElement::stopLoadRequest):
        (WebCore::ScriptElement::notifyFinished):
        (WebCore::ScriptElement::ignoresLoadRequest):
        * dom/ScriptedAnimationController.h:
        (WebCore::ScriptedAnimationController::create):
        (WebCore::ScriptedAnimationController::clearDocumentPointer):
        * dom/StyledElement.cpp:
        (WebCore::PresentationAttributeCacheKey::PresentationAttributeCacheKey):
        (WebCore::StyledElement::addSubresourceAttributeURLs):
        (WebCore::StyledElement::rebuildPresentationAttributeStyle):
        * dom/StyledElement.h:
        (WebCore::StyledElement::additionalPresentationAttributeStyle):
        (WebCore::StyledElement::inlineStyle):
        * dom/TemplateContentDocumentFragment.h:
        * dom/TextEvent.cpp:
        (WebCore::TextEvent::TextEvent):
        * dom/UIEvent.cpp:
        (WebCore::UIEventInit::UIEventInit):
        * dom/UserTypingGestureIndicator.cpp:
        (WebCore::UserTypingGestureIndicator::UserTypingGestureIndicator):
        (WebCore::UserTypingGestureIndicator::~UserTypingGestureIndicator):
        * dom/ViewportArguments.cpp:
        (WebCore::restrictScaleFactorToInitialScaleIfNotUserScalable):
        (WebCore::numericPrefix):
        * dom/default/PlatformMessagePortChannel.cpp:
        (WebCore::MessagePortChannel::disentangle):
        (WebCore::MessagePortChannel::postMessageToRemote):
        (WebCore::PlatformMessagePortChannel::PlatformMessagePortChannel):
        * dom/default/PlatformMessagePortChannel.h:

2015-11-02  Wenson Hsieh  <wenson_hsieh@apple.com>

        Tapping *below* some <input>s can focus them in Mobile Safari
        https://bugs.webkit.org/show_bug.cgi?id=146244
        <rdar://problem/21509310>

        Reviewed by Darin Adler.

        Removes iOS-specific logic in positionForPointRespectingEditingBoundaries that was causing us to focus inputs by
        tapping on the document element. We believe this logic, which causes VisiblePosition finding to recurse from a non-
        editable element to an editable child, is not necessary to focus editable elements underneath non-editable elements,
        since hit-testing will already have selected the contentEditable element prior to searching for a suitable
        VisiblePosition. Further investigation shows that this logic was added to fix <rdar://problem/5545799>, in which the
        first character in a Notes document could not be selected. However, I have not been able to reproduce this bug after
        removing this logic.

        As a result of this change, we can also enable a WK1 test, editing/selection/click-outside-editable-div.html, that
        had also been marked as failing due to positionForPointRespectingEditingBoundaries recursing into a contentEditable
        div.

        Test: fast/events/ios/clicking-document-should-not-trigger-focus.html

        * rendering/RenderBlock.cpp:
        (WebCore::positionForPointRespectingEditingBoundaries): Deleted.

2015-11-03  Myles C. Maxfield  <mmaxfield@apple.com>

        Update to match text-orientation spec
        https://bugs.webkit.org/show_bug.cgi?id=150765

        Reviewed by Darin Adler.

        The CSS spec has removed the "sideways-right" value of text-orientation in favor
        of "sideways." This patch makes the parser treat "sideways-right" the same as
        "sideways."

        Test: fast/text/orientation-sideways-right.html

        * css/CSSPrimitiveValueMappings.h:
        (WebCore::CSSPrimitiveValue::operator TextOrientation):
        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Deleted.
        * rendering/style/RenderStyle.cpp:
        (WebCore::RenderStyle::fontAndGlyphOrientation): Deleted.
        * rendering/style/RenderStyleConstants.h:

2015-11-03  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Rework promises to use @newPromiseCapability
        https://bugs.webkit.org/show_bug.cgi?id=150627

        Reviewed by Youenn Fablet.

        We are removing the stream promises functions in favor of @newPromiseCapabity which basically provides the same
        functionality (keeping the resolve and reject functions without external slots). Slots and variables were
        renamed as *PromiseCapability to show that they no longer hold just a promise, but a promise capability.

        Internal rework, no new tests needed.

        * Modules/streams/ReadableStreamInternals.js:
        (privateInitializeReadableStreamReader.this.closedPromiseCapability.resolve):
        (privateInitializeReadableStreamReader.this.closedPromiseCapability.reject):
        (privateInitializeReadableStreamReader):
        (teeReadableStream):
        (teeReadableStreamBranch2CancelFunction):
        (errorReadableStream):
        (closeReadableStreamReader):
        (enqueueInReadableStream):
        (readFromReadableStreamReader):
        * Modules/streams/ReadableStreamReader.js:
        (closed):
        * Modules/streams/StreamInternals.js:
        (createNewStreamsPromise): Deleted.
        (resolveStreamsPromise): Deleted.
        (rejectStreamsPromise): Deleted.
        * Modules/streams/WritableStream.js:
        (this.readyPromiseCapability.resolve):
        (this.readyPromiseCapability.reject):
        (initializeWritableStream):
        (close):
        (write):
        (closed):
        (ready):
        * Modules/streams/WritableStreamInternals.js:
        (syncWritableStreamStateWithQueue):
        (errorWritableStream):
        * bindings/js/WebCoreBuiltinNames.h:

2015-11-03  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Move webkitGetUserMedia to JS Builtin
        https://bugs.webkit.org/show_bug.cgi?id=149499

        Reviewed by Darin Adler.

        Implemented webkitGetUserMedia as a JSBuiltin wrapper around navigator.mediaDevices.getUserMedia.

        Removed cpp based version.

        The js builting implementation checks for argument but does not raise exception when the request is not supported.
        The error callback is called instead, in an asynchronous fashion.
        The js builtin implementation does not check first that it is called on navigator, contrary to the cpp implementation.
        This is done afterwards when calling navigator.MediaDevices.@getUserMedia.

        Covered by existing and modified tests.

        * CMakeLists.txt: Adding NavigatorUserMedia.js as built-in JS file.
        * DerivedSources.make: Ditto.
        * Modules/mediastream/NavigatorUserMedia.idl: Making webkitGetUserMedia JSBuiltin
        * Modules/mediastream/NavigatorUserMedia.js:
        (webkitGetUserMedia):
        * Modules/mediastream/NavigatorUserMediaErrorCallback.h: Removed.
        * Modules/mediastream/NavigatorUserMediaErrorCallback.idl: Removed.
        * Modules/mediastream/NavigatorUserMediaSuccessCallback.h: Removed.
        * Modules/mediastream/NavigatorUserMediaSuccessCallback.idl: Removed.
        * Modules/mediastream/UserMediaRequest.cpp:
        * Modules/mediastream/UserMediaRequest.h:
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::JSDOMWindowBase::finishCreation): Style modifications.
        * bindings/js/JSNavigatorCustom.cpp: Removed.
        * bindings/js/WebCoreJSBuiltins.cpp: Adding support for NavigatorUserMedia.js built-in JS file.
        * bindings/js/WebCoreJSBuiltins.h: Ditto.
        (WebCore::JSBuiltinFunctions::JSBuiltinFunctions):
        (WebCore::JSBuiltinFunctions::navigatorUserMediaBuiltins):

2015-11-03  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GStreamer] Use GstBus sync message handler and schedule tasks to the main thread with RunLoop::dispatch
        https://bugs.webkit.org/show_bug.cgi?id=150800

        Reviewed by Philippe Normand.

        This way we would avoid all the GScource + polling mechanism that
        GST uses internally to handle messages asynchronously in the main thread.

        * platform/graphics/gstreamer/GRefPtrGStreamer.cpp:
        (WTF::adoptGRef):
        (WTF::refGPtr<GstMessage>):
        (WTF::derefGPtr<GstMessage>):
        * platform/graphics/gstreamer/GRefPtrGStreamer.h:
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
        (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
        Initialize the WeakPtr factory.
        (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):
        reset the GstBus sync handler.
        (WebCore::MediaPlayerPrivateGStreamer::handleMessage): Make it void.
        (WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin): Add a
        GstBus sync message handler and schedule the messages to the main
        thread with RunLoop::main().dispatch().
        (WebCore::mediaPlayerPrivateMessageCallback): Deleted.
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
        (WebCore::MediaPlayerPrivateGStreamer::createWeakPtr): Create a WeakPtr.
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
        (WebCore::MediaPlayerPrivateGStreamerBase::handleSyncMessage):
        Handle the need context message that needs to be handled in the
        caller thread.
        (WebCore::mediaPlayerPrivateNeedContextMessageCallback): Deleted.
        (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
        (WebCore::MediaPlayerPrivateGStreamerBase::setPipeline): Do not
        connect to sync-message signal, handleSyncMessage() will be called
        to handled messages synchronously.
        (WebCore::MediaPlayerPrivateGStreamerBase::handleNeedContextMessage): Deleted.
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:

2015-11-03  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GStreamer] Cleanup the iradio properties
        https://bugs.webkit.org/show_bug.cgi?id=148522

        Reviewed by Philippe Normand.

        Remove unused icecast code.

        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
        (StreamingClient::handleResponseReceived):
        (webKitWebSrcGetProperty): Deleted.
        (webKitWebSrcStop): Deleted.

2015-11-02  Keith Rollin  <krollin@apple.com>

        input[type=number] does not increment/decrement integers with trailing decimal characters
        https://bugs.webkit.org/show_bug.cgi?id=148867
        rdar://problem/22589693

        Reviewed by Chris Dumez.

        Support input[type=number].value attributes of the form "###." (that
        is, leading digits with a decimal but no trailing digits). This form
        was supported in the setting of the attribute, but not when changing
        it through stepUp/Down.

        Testing turned up similarly incorrect processing of -.###, so
        addressed that, too.

        Test: fast/forms/range/input-appearance-range-decimals.html

        Updated the following tests:
        - fast/forms/number/number-stepup-stepdown-from-renderer.html
        - fast/forms/number/number-stepup-stepdown.html
        - fast/forms/range/range-stepup-stepdown-from-renderer.html
        - fast/forms/range/range-stepup-stepdown.html

        * html/InputType.cpp:
        (WebCore::InputType::stepUpFromRenderer):
        * platform/Decimal.cpp:
        (WebCore::Decimal::fromString):

2015-11-02  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test fast/css/background-repeat-null-y-crash.html
        https://bugs.webkit.org/show_bug.cgi?id=150211
        <rdar://problem/23137321>

        Reviewed by Alex Christensen.

        This is a merge of Blink r188842:
        https://codereview.chromium.org/846933002

        By setting the backgroundRepeatY property to null it can
        happen that accessing that CSS value returns a null pointer.
        In that case simply bail out early.

        Test: fast/css/background-repeat-null-y-crash.html

        * css/StyleProperties.cpp:
        (WebCore::StyleProperties::getLayeredShorthandValue):

2015-11-02  Myles C. Maxfield  <mmaxfield@apple.com>

        [Vertical Writing Mode] Rename "vertical-right" CSS value to match spec
        https://bugs.webkit.org/show_bug.cgi?id=150766

        Reviewed by Darin Adler.

        The spec has changed the initial value of text-orientation from "vertical-right"
        to "mixed." This patch follows this movement, but also keeps the existing
        property working (the parser will treat both values the same).

        Test: fast/text/vertical-mixed.html

        * css/CSSParser.cpp:
        (WebCore::CSSParser::parseValue):
        * css/CSSPrimitiveValueMappings.h:
        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
        (WebCore::CSSPrimitiveValue::operator TextOrientation):
        * css/CSSValueKeywords.in:
        * css/StyleResolver.cpp:
        (WebCore::checkForOrientationChange):
        * platform/graphics/FontCascadeFonts.cpp:
        (WebCore::glyphDataForNonCJKCharacterWithGlyphOrientation):
        * platform/graphics/FontDescription.cpp:
        (WebCore::FontDescription::FontDescription):
        * platform/graphics/cocoa/FontCascadeCocoa.mm:
        (WebCore::FontCascade::fontForCombiningCharacterSequence):
        * platform/text/TextFlags.h:
        * rendering/style/RenderStyle.cpp:
        (WebCore::RenderStyle::getFontAndGlyphOrientation):
        * rendering/style/RenderStyle.h:
        * rendering/style/RenderStyleConstants.h:
        * rendering/style/StyleRareInheritedData.cpp:
        (WebCore::StyleRareInheritedData::StyleRareInheritedData):
        * style/StyleResolveForDocument.cpp:
        (WebCore::Style::resolveForDocument):

2015-11-02  Myles C. Maxfield  <mmaxfield@apple.com>

        [Cocoa] Support WOFF2
        https://bugs.webkit.org/show_bug.cgi?id=150830

        Reviewed by Zalan Bujtas.

        On platforms which support it, WebKit only needs to recognize WOFF2.

        Test: fast/text/woff2.html

        * platform/graphics/mac/FontCustomPlatformData.cpp:
        (WebCore::FontCustomPlatformData::supportsFormat):

2015-11-02  Nan Wang  <n_wang@apple.com>

        AX: Add support for ARIA 1.1 attribute 'aria-modal' for dialog and alertdialog
        https://bugs.webkit.org/show_bug.cgi?id=138566

        Reviewed by Chris Fleizach.

        Added support for aria-modal attribute on dialog/alertdialog roles.
        When modal dialog is displayed, all other contents will be unaccessible.

        Tests: accessibility/aria-modal-multiple-dialogs.html
               accessibility/aria-modal.html

        * accessibility/AXObjectCache.cpp:
        (WebCore::AXObjectCache::AXObjectCache):
        (WebCore::AXObjectCache::~AXObjectCache):
        (WebCore::AXObjectCache::findAriaModalNodes):
        (WebCore::AXObjectCache::updateCurrentAriaModalNode):
        (WebCore::AXObjectCache::isNodeVisible):
        (WebCore::AXObjectCache::ariaModalNode):
        (WebCore::AXObjectCache::focusedImageMapUIElement):
        (WebCore::AXObjectCache::remove):
        (WebCore::AXObjectCache::handleAttributeChanged):
        (WebCore::AXObjectCache::handleAriaModalChange):
        (WebCore::AXObjectCache::labelChanged):
        * accessibility/AXObjectCache.h:
        (WebCore::AXObjectCache::handleActiveDescendantChanged):
        (WebCore::AXObjectCache::handleAriaExpandedChange):
        (WebCore::AXObjectCache::handleAriaRoleChanged):
        (WebCore::AXObjectCache::handleAriaModalChange):
        (WebCore::AXObjectCache::handleFocusedUIElementChanged):
        (WebCore::AXObjectCache::handleScrollbarUpdate):
        (WebCore::AXObjectCache::handleAttributeChanged):
        * accessibility/AccessibilityObject.cpp:
        (WebCore::AccessibilityObject::ariaCurrentState):
        (WebCore::AccessibilityObject::isAriaModalDescendant):
        (WebCore::AccessibilityObject::ignoredFromARIAModalPresence):
        (WebCore::AccessibilityObject::hasTagName):
        (WebCore::AccessibilityObject::defaultObjectInclusion):
        * accessibility/AccessibilityObject.h:
        * html/HTMLAttributeNames.in:

2015-11-02  Brady Eidson  <beidson@apple.com>

        Modern IDB: IBDObjectStore.delete() support.
        https://bugs.webkit.org/show_bug.cgi?id=150784

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/idbobjectstore-delete-1.html
               storage/indexeddb/modern/idbobjectstore-delete-2.html
               storage/indexeddb/modern/idbobjectstore-delete-failures.html

        * Modules/indexeddb/IDBKeyRangeData.cpp:
        (WebCore::IDBKeyRangeData::isValid):
        * Modules/indexeddb/IDBKeyRangeData.h:
        
        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::deleteRecord):
        (WebCore::IDBClient::IDBConnectionToServer::didDeleteRecord):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:
        
        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::get):
        (WebCore::IDBClient::IDBObjectStore::deleteFunction):
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::requestDeleteRecord):
        (WebCore::IDBClient::IDBTransaction::deleteRecordOnServer):
        (WebCore::IDBClient::IDBTransaction::didDeleteRecordOnServer):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        
        * Modules/indexeddb/server/IDBBackingStore.h:
        
        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didDeleteRecord):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:
        
        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::deleteRecord):
        * Modules/indexeddb/server/IDBServer.h:
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::deleteRange):
        (WebCore::IDBServer::MemoryIDBBackingStore::deleteRecord): Deleted.
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::deleteRange):
        * Modules/indexeddb/server/MemoryObjectStore.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::performPutOrAdd):
        (WebCore::IDBServer::UniqueIDBDatabase::deleteRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::performDeleteRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformDeleteRecord):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::getCount):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::deleteRecord):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
        
        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::deleteRecordSuccess):
        * Modules/indexeddb/shared/IDBResultData.h:
        
        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didDeleteRecord):
        (WebCore::InProcessIDBServer::deleteRecord):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

2015-11-02  Andy Estes  <aestes@apple.com>

        Fix the iOS build again.

        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm: supportsPictureInPicture() needs to be declared even when
        AVKit is disabled.

2015-11-02  Tim Horton  <timothy_horton@apple.com>

        PDFPlugin should take advantage of threaded scrolling
        https://bugs.webkit.org/show_bug.cgi?id=150037

        Reviewed by Anders Carlsson.

        * page/PageOverlay.cpp:
        (WebCore::PageOverlay::PageOverlay):
        (WebCore::PageOverlay::setNeedsDisplay):
        Don't reset the overlay layer's opacity if we're not animating,
        because it's possible the client wants to manage it.

        * page/PageOverlayController.cpp:
        (WebCore::PageOverlayController::updateForceSynchronousScrollLayerPositionUpdates):
        Let the overlay itself determine whether it needes synchronous scrolling,
        and let PageOverlay clients override the default.

        * platform/Widget.h:
        (WebCore::Widget::boundsRect):
        Export a few useful things.

2015-11-02  Chris Dumez  <cdumez@apple.com>

        Regression(r191673): Crash in RunLoopTimer::schedule()
        https://bugs.webkit.org/show_bug.cgi?id=150816
        <rdar://problem/23335285>

        Reviewed by Anders Carlsson.

        The crash was happening when the RunLoopTimer would fire during the
        call to RunLoopTimer::schedule(), which can happen because we are
        calling schedule() from a background thread. In such case, the
        timerFired() callback execution would cause |this| to get destroyed.

        To avoid this issue, DecodingResultDispatcher is now ref-counted. The
        object is ref'd while calling startTimer() so that the object cannot go
        away during the execution of this method. Also, we explicitly ref the
        object when starting the timer to keep the object alive until the
        RunLoopTimer has fired, at which point we explicitely de-ref.

        This should handle correctly the cases where the RunLoopTimer fires
        during AND after the execution of startTimer().

        * platform/network/DataURLDecoder.cpp:
        (WebCore::DataURLDecoder::DecodingResultDispatcher::dispatch):
        (WebCore::DataURLDecoder::DecodingResultDispatcher::startTimer):
        (WebCore::DataURLDecoder::DecodingResultDispatcher::timerFired):

2015-11-02  Andy Estes  <aestes@apple.com>

        [Cocoa] Add tvOS and watchOS to SUPPORTED_PLATFORMS
        https://bugs.webkit.org/show_bug.cgi?id=150819

        Reviewed by Dan Bernstein.

        This tells Xcode to include these platforms in its Devices dropdown, making it possible to build in the IDE.

        * Configurations/Base.xcconfig:

2015-11-02  Brent Fulgham  <bfulgham@apple.com>

        [Win] MiniBrowser unable to use WebInspector
        https://bugs.webkit.org/show_bug.cgi?id=150810
        <rdar://problem/23358514>

        Reviewed by Timothy Hatcher.

        The CMakeList rule for creating the InjectedScriptSource.min.js was improperly including
        the quote characters in the text prepended to InjectedScriptSource.min.js. This caused a
        parsing error in the JS file.
        
        The solution was to switch from using "COMMAND echo" to use the more cross-platform
        compatible command "COMMAND ${CMAKE_COMMAND} -E echo ...", which handles the string
        escaping properly on all platforms.

        * CMakeLists.txt: Switch the 'echo' command syntax to be more cross-platform.

2015-11-02  Zalan Bujtas  <zalan@apple.com>

        hasOverflowClip() does not necessarily mean valid layer().
        https://bugs.webkit.org/show_bug.cgi?id=150814

        Reviewed by Simon Fraser.

        Certain RenderLayerModelObject derived classes simply return false for ::requiresLayer(), which means
        that we end up not creating a layer for the overflow clipped content.   

        No change in functionality.

        * rendering/RenderBlock.cpp:
        (WebCore::RenderBlock::updateScrollInfoAfterLayout):
        (WebCore::RenderBlock::paint):
        * rendering/RenderBox.cpp:
        (WebCore::RenderBox::styleDidChange):
        (WebCore::RenderBox::scrollWidth):
        (WebCore::RenderBox::scrollHeight):
        (WebCore::RenderBox::scrollLeft):
        (WebCore::RenderBox::scrollTop):
        (WebCore::RenderBox::setScrollLeft):
        (WebCore::RenderBox::setScrollTop):
        (WebCore::RenderBox::includeVerticalScrollbarSize):
        (WebCore::RenderBox::includeHorizontalScrollbarSize):
        (WebCore::RenderBox::intrinsicScrollbarLogicalWidth):
        (WebCore::RenderBox::usesCompositedScrolling):

2015-11-02  Alex Christensen  <achristensen@webkit.org>

        Fix Mac CMake build after r191904.

        * PlatformMac.cmake:
        Move SettingsMac.mm to SettingsCocoa.mm.

2015-11-02  Eric Carlson  <eric.carlson@apple.com>

        Add HTMLMediaElement behavior and attribute value restrictions for MediaStream
        https://bugs.webkit.org/show_bug.cgi?id=146853

        Reviewed by Jer Noble.

        * Modules/mediastream/MediaStream.cpp:
        (WebCore::MediaStream::scheduleActiveStateChange): Do nothing if the active state hasn't changed.
        (WebCore::MediaStream::activityEventTimerFired): Remove FIXME.

        * Modules/mediastream/MediaStreamTrack.cpp:
        (WebCore::MediaStreamTrack::stopProducingData): Add comments. Notify observers that the track ended.
        (WebCore::MediaStreamTrack::trackEnded): Don't dispatch events after having been stopped.
        (WebCore::MediaStreamTrack::trackMutedChanged): Ditto.

        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::defaultPlaybackRate): Always return 1 when using a MediaStream.
        (WebCore::HTMLMediaElement::setDefaultPlaybackRate): Do nothing when using a MediaStream.
        (WebCore::HTMLMediaElement::playbackRate): Always return 1 when using a MediaStream.
        (WebCore::HTMLMediaElement::setPlaybackRate): Do nothing when using a MediaStream.
        (WebCore::HTMLMediaElement::ended): Ask the media engine when using a MediaStream.
        (WebCore::HTMLMediaElement::preload): Always return "none" when using a MediaStream.
        (WebCore::HTMLMediaElement::setPreload): Do nothing when using a MediaStream.
        (WebCore::HTMLMediaElement::mediaPlayerTimeChanged): Avoid unnecessary comparisons when the duration
          is not definite. Send ended event when MediaStream says stream has ended.

        * platform/graphics/MediaPlayer.cpp:
        (WebCore::MediaPlayer::ended): New, passthrough to engine.
        * platform/graphics/MediaPlayer.h:
        * platform/graphics/MediaPlayerPrivate.h:

        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:
        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::load): Set m_ended from stream.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::cancelLoad): Pause the stream if necessary.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::play): Return early if ended or already playing.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::pause): Return early if ended or already paused.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentReadyState): Cleanup. Try to grab a paused
          image if the stream isn't active.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::updateReadyState): New.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::activeStatusChanged): Call updateReadyState.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::characteristicsChanged): Ditto.

        * platform/mediastream/MediaStreamPrivate.cpp:
        (WebCore::MediaStreamPrivate::trackEnabledChanged): Call updateActiveState so the state will
          be updated if necessary.

        * platform/mediastream/RealtimeMediaSource.cpp:
        (WebCore::RealtimeMediaSource::stop): Don't call reset, there is no need to tear everything down.

2015-10-31  Andy Estes  <aestes@apple.com>

        Replace iOS-only WebKitSystemInterface calls with SPI
        https://bugs.webkit.org/show_bug.cgi?id=150763

        Reviewed by Darin Adler.

        * WebCore.xcodeproj/project.pbxproj:
        * config.h: Removed WEBCORE_NAVIGATOR_PLATFORM and WEBCORE_NAVIGATOR_VENDOR.
        * css/MediaQueryEvaluator.cpp:
        (WebCore::isRunningOnIPhoneOrIPod): Used deviceClass() instead of iosDeviceClass().
        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::shouldOverrideBackgroundPlaybackRestriction): Used supportsPictureInPicture() instead of wkIsOptimizedFullscreenSupported().
        * html/HTMLObjectElement.cpp:
        (WebCore::shouldNotPerformURLAdjustment): Used dyld_get_program_sdk_version() instead of iosExecutableWasLinkedOnOrAfterVersion().
        * html/HTMLVideoElement.cpp:
        (WebCore::HTMLVideoElement::webkitSupportsPresentationMode): Used supportsPictureInPicture() instead of wkIsOptimizedFullscreenSupported().
        * page/NavigatorBase.cpp:
        * page/Settings.h:
        * page/ViewportConfiguration.cpp:
        (WebCore::ViewportConfiguration::textDocumentParameters): Used screenSize() instead of wkGetScreenSize().
        * page/ios/UserAgentIOS.mm:
        (WebCore::isClassic): Added to return -[UIApplication _isClassic].
        (WebCore::osNameForUserAgent): Upstreamed the implementation of WKGetOSNameForUserAgent() from WebKitSystemInterface.
        (WebCore::deviceName): Ditto for wkGetDeviceName().
        (WebCore::standardUserAgentWithApplicationName): Called deviceName() and osNameForUserAgent().
        * page/mac/SettingsCocoa.mm: Renamed from Source/WebCore/page/mac/SettingsMac.mm.
        (WebCore::Settings::defaultMinimumZoomFontSize): Upstreamed the implementation of WKGetMinimumZoomFontSize() from WebKitSystemInterface.
        * platform/PlatformScreen.h:
        * platform/ios/Device.cpp: Added functions that answer queries about the iOS device from MobileGestalt.
        (WebCore::deviceClass):
        (WebCore::deviceName):
        (WebCore::deviceHasIPadCapability):
        * platform/ios/Device.h:
        * platform/ios/PlatformScreenIOS.mm:
        (WebCore::screenPPIFactor): Used MGGetSInt32Answer() and MGGetFloat32Answer() instead of mobileGestaltFloatValue().
        (WebCore::screenSize): Upstreamed the implementation of WKGetScreenSize() from WebKitSystemInterface.
        (WebCore::availableScreenSize): Ditto for WKGetAvailableScreenSize().
        (WebCore::screenScaleFactor): Ditto for WKGetScreenScaleFactor() and WKGetScaleFactorForScreen().
        (WebCore::mobileGestaltFloatValue): Deleted.
        * platform/ios/WebCoreSystemInterfaceIOS.h: Removed.
        (iosExecutableWasLinkedOnOrAfterVersion): Deleted.
        (iosDeviceClass): Deleted.
        * platform/ios/WebCoreSystemInterfaceIOS.mm:
        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
        (WebVideoFullscreenInterfaceAVKit::mayAutomaticallyShowVideoPictureInPicture): Used supportsPictureInPicture() instead of wkIsOptimizedFullscreenSupported().
        (WebCore::supportsPictureInPicture): Upstreamed the implementation of WKIsOptimizedFullscreenSupported() from WebKitSystemInterface.
        * platform/ios/wak/WAKWindow.mm:
        (-[WAKWindow initWithLayer:]): Used screenScaleFactor() instead of WKGetScreenScaleFactor().
        (-[WAKWindow initWithFrame:]): Ditto.
        * platform/ios/wak/WKGraphics.mm:
        (WKGraphicsCreateImageFromBundleWithName): Ditto.
        (WKDrawPatternBitmap): Ditto.
        * platform/mac/WebCoreSystemInterface.h:
        * platform/spi/cocoa/DynamicLinkerSPI.h: Defined additional DYLD_IOS_VERSION macros.
        * platform/spi/ios/MobileGestaltSPI.h: Defined additional MobileGestalt queries, enum MGDeviceClass, MGGetSInt32Answer, and MGGetFloat32Answer.
        * platform/spi/ios/UIKitSPI.h: Copied from Source/WebCore/platform/spi/ios/UIColorSPI.h, and added SPI declarations for UIApplication and UIScreen.
        * rendering/RenderThemeIOS.mm: Included UIKitSPI.h instead of UIColorSPI.h, and removed unnecessary forward declarations for the iOS public SDK build.

2015-11-02  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r191902.
        https://bugs.webkit.org/show_bug.cgi?id=150811

        This change broke iOS builders (Requested by ryanhaddad on
        #webkit).

        Reverted changeset:

        "Replace iOS-only WebKitSystemInterface calls with SPI"
        https://bugs.webkit.org/show_bug.cgi?id=150763
        http://trac.webkit.org/changeset/191902

2015-10-31  Andy Estes  <aestes@apple.com>

        Replace iOS-only WebKitSystemInterface calls with SPI
        https://bugs.webkit.org/show_bug.cgi?id=150763

        Reviewed by Darin Adler.

        * WebCore.xcodeproj/project.pbxproj:
        * config.h: Removed WEBCORE_NAVIGATOR_PLATFORM and WEBCORE_NAVIGATOR_VENDOR.
        * css/MediaQueryEvaluator.cpp:
        (WebCore::isRunningOnIPhoneOrIPod): Used deviceClass() instead of iosDeviceClass().
        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::shouldOverrideBackgroundPlaybackRestriction): Used supportsPictureInPicture() instead of wkIsOptimizedFullscreenSupported().
        * html/HTMLObjectElement.cpp:
        (WebCore::shouldNotPerformURLAdjustment): Used dyld_get_program_sdk_version() instead of iosExecutableWasLinkedOnOrAfterVersion().
        * html/HTMLVideoElement.cpp:
        (WebCore::HTMLVideoElement::webkitSupportsPresentationMode): Used supportsPictureInPicture() instead of wkIsOptimizedFullscreenSupported().
        * page/NavigatorBase.cpp:
        * page/Settings.h:
        * page/ViewportConfiguration.cpp:
        (WebCore::ViewportConfiguration::textDocumentParameters): Used screenSize() instead of wkGetScreenSize().
        * page/ios/UserAgentIOS.mm:
        (WebCore::isClassic): Added to return -[UIApplication _isClassic].
        (WebCore::osNameForUserAgent): Upstreamed the implementation of WKGetOSNameForUserAgent() from WebKitSystemInterface.
        (WebCore::deviceName): Ditto for wkGetDeviceName().
        (WebCore::standardUserAgentWithApplicationName): Called deviceName() and osNameForUserAgent().
        * page/mac/SettingsCocoa.mm: Renamed from Source/WebCore/page/mac/SettingsMac.mm.
        (WebCore::Settings::defaultMinimumZoomFontSize): Upstreamed the implementation of WKGetMinimumZoomFontSize() from WebKitSystemInterface.
        * platform/PlatformScreen.h:
        * platform/ios/Device.cpp: Added functions that answer queries about the iOS device from MobileGestalt.
        (WebCore::deviceClass):
        (WebCore::deviceName):
        (WebCore::deviceHasIPadCapability):
        * platform/ios/Device.h:
        * platform/ios/PlatformScreenIOS.mm:
        (WebCore::screenPPIFactor): Used MGGetSInt32Answer() and MGGetFloat32Answer() instead of mobileGestaltFloatValue().
        (WebCore::screenSize): Upstreamed the implementation of WKGetScreenSize() from WebKitSystemInterface.
        (WebCore::availableScreenSize): Ditto for WKGetAvailableScreenSize().
        (WebCore::screenScaleFactor): Ditto for WKGetScreenScaleFactor() and WKGetScaleFactorForScreen().
        (WebCore::mobileGestaltFloatValue): Deleted.
        * platform/ios/WebCoreSystemInterfaceIOS.h: Removed.
        (iosExecutableWasLinkedOnOrAfterVersion): Deleted.
        (iosDeviceClass): Deleted.
        * platform/ios/WebCoreSystemInterfaceIOS.mm:
        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
        (WebVideoFullscreenInterfaceAVKit::mayAutomaticallyShowVideoPictureInPicture): Used supportsPictureInPicture() instead of wkIsOptimizedFullscreenSupported().
        (WebCore::supportsPictureInPicture): Upstreamed the implementation of WKIsOptimizedFullscreenSupported() from WebKitSystemInterface.
        * platform/ios/wak/WAKWindow.mm:
        (-[WAKWindow initWithLayer:]): Used screenScaleFactor() instead of WKGetScreenScaleFactor().
        (-[WAKWindow initWithFrame:]): Ditto.
        * platform/ios/wak/WKGraphics.mm:
        (WKGraphicsCreateImageFromBundleWithName): Ditto.
        (WKDrawPatternBitmap): Ditto.
        * platform/mac/WebCoreSystemInterface.h:
        * platform/spi/cocoa/DynamicLinkerSPI.h: Defined additional DYLD_IOS_VERSION macros.
        * platform/spi/ios/MobileGestaltSPI.h: Defined additional MobileGestalt queries, enum MGDeviceClass, MGGetSInt32Answer, and MGGetFloat32Answer.
        * platform/spi/ios/UIKitSPI.h: Copied from Source/WebCore/platform/spi/ios/UIColorSPI.h, and added SPI declarations for UIApplication and UIScreen.
        * rendering/RenderThemeIOS.mm:

2015-11-02  Frederic Wang  <fred.wang@free.fr>

        [Win] Add support for the USE_TYPO_METRICS flag
        https://bugs.webkit.org/show_bug.cgi?id=150451

        Reviewed by Darin Adler.

        Make the Windows backend use the typo metrics when the OS/2 USE_TYPO_METRICS flag is set.

        No new tests because this is already tested by fonts/use-typo-metrics-1.html

        * platform/graphics/win/SimpleFontDataCGWin.cpp:
        (WebCore::Font::platformInit):
        * platform/graphics/win/SimpleFontDataCairoWin.cpp:
        (WebCore::Font::platformInit):
        * platform/graphics/win/SimpleFontDataWin.cpp:
        (WebCore::Font::initGDIFont):

2015-11-02  Hyunduk Kim  <hyunduk.kim@samsung.com>

        Enable MediaSource::isTypeSupported() to handle the upper-cased MIME type & Codec
        https://bugs.webkit.org/show_bug.cgi?id=150436

        Reviewed by Darin Adler.

        Got the new test case from
        https://github.com/w3c/web-platform-tests/blob/master/media-source/mediasource-is-type-supported.html 
        Tests: http\tests\media\media-source\mediasource-is-type-supported.html

        * Modules/mediasource/MediaSource.cpp:
        (WebCore::MediaSource::isTypeSupported):

2015-11-02  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Rename JSDOMWrapper.impl to JSDOMWrapper.wrapped
        https://bugs.webkit.org/show_bug.cgi?id=150613

        Reviewed by Darin Adler.

        Renaming impl to wrapped in classes and binding generated classes.
        No change in behavior.

        * Modules/plugins/QuickTimePluginReplacement.mm:
        (WebCore::JSQuickTimePluginReplacement::timedMetaData):
        (WebCore::JSQuickTimePluginReplacement::accessLog):
        (WebCore::JSQuickTimePluginReplacement::errorLog):
        * bindings/js/JSAttrCustom.cpp:
        (WebCore::JSAttr::visitAdditionalChildren):
        * bindings/js/JSAudioBufferSourceNodeCustom.cpp:
        (WebCore::JSAudioBufferSourceNode::setBuffer):
        * bindings/js/JSAudioTrackCustom.cpp:
        (WebCore::JSAudioTrack::visitAdditionalChildren):
        (WebCore::JSAudioTrack::setKind):
        (WebCore::JSAudioTrack::setLanguage):
        * bindings/js/JSAudioTrackListCustom.cpp:
        (WebCore::JSAudioTrackList::visitAdditionalChildren):
        * bindings/js/JSBiquadFilterNodeCustom.cpp:
        (WebCore::JSBiquadFilterNode::setType):
        * bindings/js/JSCSSRuleCustom.cpp:
        (WebCore::JSCSSRule::visitAdditionalChildren):
        * bindings/js/JSCSSRuleListCustom.cpp:
        (WebCore::JSCSSRuleListOwner::isReachableFromOpaqueRoots):
        * bindings/js/JSCSSStyleDeclarationCustom.cpp:
        (WebCore::JSCSSStyleDeclaration::visitAdditionalChildren):
        (WebCore::getPropertyValueFallback):
        (WebCore::cssPropertyGetterPixelOrPosPrefix):
        (WebCore::cssPropertyGetter):
        (WebCore::JSCSSStyleDeclaration::putDelegate):
        (WebCore::JSCSSStyleDeclaration::getPropertyCSSValue):
        (WebCore::JSCSSStyleDeclaration::getOwnPropertyNames):
        * bindings/js/JSCSSValueCustom.cpp:
        (WebCore::JSCSSValueOwner::isReachableFromOpaqueRoots):
        (WebCore::JSCSSValueOwner::finalize):
        * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
        (WebCore::toHTMLCanvasStyle):
        (WebCore::JSCanvasRenderingContext2D::strokeStyle):
        (WebCore::JSCanvasRenderingContext2D::setStrokeStyle):
        (WebCore::JSCanvasRenderingContext2D::fillStyle):
        (WebCore::JSCanvasRenderingContext2D::setFillStyle):
        (WebCore::JSCanvasRenderingContext2D::webkitLineDash):
        (WebCore::JSCanvasRenderingContext2D::setWebkitLineDash):
        * bindings/js/JSCanvasRenderingContextCustom.cpp:
        (WebCore::JSCanvasRenderingContext::visitAdditionalChildren):
        * bindings/js/JSCharacterDataCustom.cpp:
        (WebCore::JSCharacterData::before):
        (WebCore::JSCharacterData::after):
        (WebCore::JSCharacterData::replaceWith):
        * bindings/js/JSCommandLineAPIHostCustom.cpp:
        (WebCore::JSCommandLineAPIHost::inspectedObject):
        (WebCore::JSCommandLineAPIHost::getEventListeners):
        (WebCore::JSCommandLineAPIHost::inspect):
        (WebCore::JSCommandLineAPIHost::databaseId):
        (WebCore::JSCommandLineAPIHost::storageId):
        * bindings/js/JSCryptoCustom.cpp:
        (WebCore::JSCrypto::getRandomValues):
        * bindings/js/JSCryptoKeyCustom.cpp:
        (WebCore::JSCryptoKey::algorithm):
        * bindings/js/JSCryptoKeyPairCustom.cpp:
        (WebCore::JSCryptoKeyPair::visitAdditionalChildren):
        * bindings/js/JSCustomEventCustom.cpp:
        (WebCore::JSCustomEvent::detail):
        * bindings/js/JSCustomXPathNSResolver.cpp:
        (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
        * bindings/js/JSDOMBinding.cpp:
        (WebCore::reportException):
        (WebCore::activeDOMWindow):
        (WebCore::firstDOMWindow):
        * bindings/js/JSDOMFormDataCustom.cpp:
        (WebCore::toHTMLFormElementOrNull):
        (WebCore::JSDOMFormData::append):
        * bindings/js/JSDOMMimeTypeArrayCustom.cpp:
        (WebCore::JSDOMMimeTypeArray::nameGetter):
        * bindings/js/JSDOMNamedFlowCollectionCustom.cpp:
        (WebCore::JSDOMNamedFlowCollection::nameGetter):
        * bindings/js/JSDOMPluginArrayCustom.cpp:
        (WebCore::JSDOMPluginArray::nameGetter):
        * bindings/js/JSDOMPluginCustom.cpp:
        (WebCore::JSDOMPlugin::nameGetter):
        * bindings/js/JSDOMStringListCustom.cpp:
        (WebCore::JSDOMStringList::toWrapped):
        * bindings/js/JSDOMStringMapCustom.cpp:
        (WebCore::JSDOMStringMap::getOwnPropertySlotDelegate):
        (WebCore::JSDOMStringMap::getOwnPropertyNames):
        (WebCore::JSDOMStringMap::deleteProperty):
        (WebCore::JSDOMStringMap::putDelegate):
        * bindings/js/JSDOMTokenListCustom.cpp:
        (WebCore::JSDOMTokenList::toggle):
        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::shouldAllowAccessFrom):
        (WebCore::JSDOMWindowBase::JSDOMWindowBase):
        (WebCore::JSDOMWindowBase::updateDocument):
        (WebCore::JSDOMWindowBase::scriptExecutionContext):
        (WebCore::JSDOMWindowBase::printErrorMessage):
        (WebCore::JSDOMWindowBase::supportsProfiling):
        (WebCore::JSDOMWindowBase::supportsRichSourceInfo):
        (WebCore::JSDOMWindowBase::shouldInterruptScript):
        (WebCore::JSDOMWindowBase::shouldInterruptScriptBeforeTimeout):
        (WebCore::JSDOMWindowBase::javaScriptRuntimeFlags):
        (WebCore::JSDOMWindowBase::moduleLoaderResolve):
        (WebCore::JSDOMWindowBase::moduleLoaderFetch):
        (WebCore::JSDOMWindowBase::moduleLoaderEvaluate):
        * bindings/js/JSDOMWindowBase.h:
        * bindings/js/JSDOMWindowCustom.cpp:
        (WebCore::JSDOMWindow::visitAdditionalChildren):
        (WebCore::childFrameGetter):
        (WebCore::namedItemGetter):
        (WebCore::jsDOMWindowWebKit):
        (WebCore::jsDOMWindowIndexedDB):
        (WebCore::JSDOMWindow::getOwnPropertySlot):
        (WebCore::JSDOMWindow::getOwnPropertySlotByIndex):
        (WebCore::JSDOMWindow::put):
        (WebCore::JSDOMWindow::putByIndex):
        (WebCore::JSDOMWindow::deleteProperty):
        (WebCore::JSDOMWindow::deletePropertyByIndex):
        (WebCore::JSDOMWindow::getEnumerableLength):
        (WebCore::JSDOMWindow::getStructurePropertyNames):
        (WebCore::JSDOMWindow::getGenericPropertyNames):
        (WebCore::JSDOMWindow::getPropertyNames):
        (WebCore::JSDOMWindow::getOwnPropertyNames):
        (WebCore::JSDOMWindow::defineOwnProperty):
        (WebCore::JSDOMWindow::setLocation):
        (WebCore::JSDOMWindow::open):
        (WebCore::JSDOMWindow::showModalDialog):
        (WebCore::JSDOMWindow::postMessage):
        (WebCore::JSDOMWindow::setTimeout):
        (WebCore::JSDOMWindow::setInterval):
        (WebCore::JSDOMWindow::addEventListener):
        (WebCore::JSDOMWindow::removeEventListener):
        (WebCore::JSDOMWindow::toWrapped):
        * bindings/js/JSDOMWindowShell.cpp:
        (WebCore::JSDOMWindowShell::setWindow):
        (WebCore::JSDOMWindowShell::wrapped):
        * bindings/js/JSDOMWindowShell.h:
        * bindings/js/JSDOMWrapper.h:
        (WebCore::JSDOMWrapper::wrapped):
        (WebCore::JSDOMWrapper::JSDOMWrapper):
        * bindings/js/JSDataCueCustom.cpp:
        (WebCore::JSDataCue::value):
        (WebCore::JSDataCue::setValue):
        * bindings/js/JSDataTransferCustom.cpp:
        (WebCore::JSDataTransfer::types):
        * bindings/js/JSDedicatedWorkerGlobalScopeCustom.cpp:
        (WebCore::JSDedicatedWorkerGlobalScope::postMessage):
        * bindings/js/JSDeviceMotionEventCustom.cpp:
        (WebCore::JSDeviceMotionEvent::acceleration):
        (WebCore::JSDeviceMotionEvent::accelerationIncludingGravity):
        (WebCore::JSDeviceMotionEvent::rotationRate):
        (WebCore::JSDeviceMotionEvent::interval):
        (WebCore::JSDeviceMotionEvent::initDeviceMotionEvent):
        * bindings/js/JSDeviceOrientationEventCustom.cpp:
        (WebCore::JSDeviceOrientationEvent::alpha):
        (WebCore::JSDeviceOrientationEvent::beta):
        (WebCore::JSDeviceOrientationEvent::gamma):
        (WebCore::JSDeviceOrientationEvent::webkitCompassHeading):
        (WebCore::JSDeviceOrientationEvent::webkitCompassAccuracy):
        (WebCore::JSDeviceOrientationEvent::absolute):
        (WebCore::JSDeviceOrientationEvent::initDeviceOrientationEvent):
        * bindings/js/JSDocumentCustom.cpp:
        (WebCore::JSDocument::prepend):
        (WebCore::JSDocument::append):
        * bindings/js/JSDocumentFragmentCustom.cpp:
        (WebCore::JSDocumentFragment::prepend):
        (WebCore::JSDocumentFragment::append):
        * bindings/js/JSDocumentTypeCustom.cpp:
        (WebCore::JSDocumentType::before):
        (WebCore::JSDocumentType::after):
        (WebCore::JSDocumentType::replaceWith):
        * bindings/js/JSElementCustom.cpp:
        (WebCore::JSElement::before):
        (WebCore::JSElement::after):
        (WebCore::JSElement::replaceWith):
        (WebCore::JSElement::prepend):
        (WebCore::JSElement::append):
        * bindings/js/JSEventCustom.cpp:
        (WebCore::JSEvent::clipboardData):
        * bindings/js/JSEventListener.cpp:
        (WebCore::JSEventListener::handleEvent):
        * bindings/js/JSEventTargetCustom.cpp:
        * bindings/js/JSFileReaderCustom.cpp:
        (WebCore::JSFileReader::result):
        * bindings/js/JSGeolocationCustom.cpp:
        (WebCore::JSGeolocation::getCurrentPosition):
        (WebCore::JSGeolocation::watchPosition):
        * bindings/js/JSHTMLAllCollectionCustom.cpp:
        (WebCore::namedItems):
        (WebCore::callHTMLAllCollection):
        (WebCore::JSHTMLAllCollection::item):
        * bindings/js/JSHTMLCanvasElementCustom.cpp:
        (WebCore::JSHTMLCanvasElement::getContext):
        (WebCore::JSHTMLCanvasElement::probablySupportsContext):
        (WebCore::JSHTMLCanvasElement::toDataURL):
        * bindings/js/JSHTMLCollectionCustom.cpp:
        (WebCore::JSHTMLCollection::nameGetter):
        * bindings/js/JSHTMLDocumentCustom.cpp:
        (WebCore::JSHTMLDocument::nameGetter):
        (WebCore::JSHTMLDocument::all):
        (WebCore::findCallingDocument):
        (WebCore::JSHTMLDocument::open):
        (WebCore::documentWrite):
        * bindings/js/JSHTMLElementCustom.cpp:
        (WebCore::JSHTMLElement::pushEventHandlerScope):
        * bindings/js/JSHTMLFormControlsCollectionCustom.cpp:
        (WebCore::namedItems):
        * bindings/js/JSHTMLFormElementCustom.cpp:
        (WebCore::JSHTMLFormElement::nameGetter):
        * bindings/js/JSHTMLFrameElementCustom.cpp:
        (WebCore::JSHTMLFrameElement::setLocation):
        * bindings/js/JSHTMLFrameSetElementCustom.cpp:
        (WebCore::JSHTMLFrameSetElement::nameGetter):
        * bindings/js/JSHTMLInputElementCustom.cpp:
        (WebCore::JSHTMLInputElement::selectionStart):
        (WebCore::JSHTMLInputElement::setSelectionStart):
        (WebCore::JSHTMLInputElement::selectionEnd):
        (WebCore::JSHTMLInputElement::setSelectionEnd):
        (WebCore::JSHTMLInputElement::selectionDirection):
        (WebCore::JSHTMLInputElement::setSelectionDirection):
        (WebCore::JSHTMLInputElement::setSelectionRange):
        * bindings/js/JSHTMLMediaElementCustom.cpp:
        (WebCore::JSHTMLMediaElement::setController):
        * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
        (WebCore::JSHTMLOptionsCollection::nameGetter):
        (WebCore::JSHTMLOptionsCollection::setLength):
        (WebCore::JSHTMLOptionsCollection::indexSetter):
        (WebCore::JSHTMLOptionsCollection::remove):
        * bindings/js/JSHTMLSelectElementCustom.cpp:
        (WebCore::JSHTMLSelectElement::remove):
        (WebCore::JSHTMLSelectElement::indexSetter):
        * bindings/js/JSHTMLTemplateElementCustom.cpp:
        (WebCore::JSHTMLTemplateElement::content):
        * bindings/js/JSHistoryCustom.cpp:
        (WebCore::JSHistory::getOwnPropertySlotDelegate):
        (WebCore::JSHistory::putDelegate):
        (WebCore::JSHistory::deleteProperty):
        (WebCore::JSHistory::deletePropertyByIndex):
        (WebCore::JSHistory::getOwnPropertyNames):
        (WebCore::JSHistory::state):
        (WebCore::JSHistory::pushState):
        (WebCore::JSHistory::replaceState):
        * bindings/js/JSIDBDatabaseCustom.cpp:
        (WebCore::JSIDBDatabase::createObjectStore):
        * bindings/js/JSIDBObjectStoreCustom.cpp:
        (WebCore::JSIDBObjectStore::createIndex):
        * bindings/js/JSInspectorFrontendHostCustom.cpp:
        (WebCore::JSInspectorFrontendHost::showContextMenu):
        * bindings/js/JSLocationCustom.cpp:
        (WebCore::JSLocation::getOwnPropertySlotDelegate):
        (WebCore::JSLocation::putDelegate):
        (WebCore::JSLocation::deleteProperty):
        (WebCore::JSLocation::deletePropertyByIndex):
        (WebCore::JSLocation::getOwnPropertyNames):
        (WebCore::JSLocation::toStringFunction):
        * bindings/js/JSMediaSourceStatesCustom.cpp:
        (WebCore::JSMediaSourceStates::width):
        (WebCore::JSMediaSourceStates::height):
        (WebCore::JSMediaSourceStates::frameRate):
        (WebCore::JSMediaSourceStates::aspectRatio):
        (WebCore::JSMediaSourceStates::facingMode):
        (WebCore::JSMediaSourceStates::volume):
        * bindings/js/JSMessageChannelCustom.cpp:
        (WebCore::JSMessageChannel::visitAdditionalChildren):
        * bindings/js/JSMessageEventCustom.cpp:
        (WebCore::JSMessageEvent::data):
        (WebCore::handleInitMessageEvent):
        * bindings/js/JSMessagePortCustom.cpp:
        (WebCore::JSMessagePort::visitAdditionalChildren):
        (WebCore::JSMessagePort::postMessage):
        * bindings/js/JSMockContentFilterSettingsCustom.cpp:
        (WebCore::JSMockContentFilterSettings::decisionPoint):
        (WebCore::JSMockContentFilterSettings::setDecisionPoint):
        (WebCore::JSMockContentFilterSettings::decision):
        (WebCore::JSMockContentFilterSettings::setDecision):
        (WebCore::JSMockContentFilterSettings::unblockRequestDecision):
        (WebCore::JSMockContentFilterSettings::setUnblockRequestDecision):
        * bindings/js/JSMutationObserverCustom.cpp:
        (WebCore::JSMutationObserverOwner::isReachableFromOpaqueRoots):
        * bindings/js/JSNamedNodeMapCustom.cpp:
        (WebCore::JSNamedNodeMap::nameGetter):
        * bindings/js/JSNavigatorCustom.cpp:
        (WebCore::JSNavigator::webkitGetUserMedia):
        * bindings/js/JSNodeCustom.cpp:
        (WebCore::JSNodeOwner::isReachableFromOpaqueRoots):
        (WebCore::JSNode::insertBefore):
        (WebCore::JSNode::replaceChild):
        (WebCore::JSNode::removeChild):
        (WebCore::JSNode::appendChild):
        (WebCore::JSNode::visitAdditionalChildren):
        * bindings/js/JSNodeIteratorCustom.cpp:
        (WebCore::JSNodeIterator::visitAdditionalChildren):
        * bindings/js/JSNodeListCustom.cpp:
        (WebCore::JSNodeListOwner::isReachableFromOpaqueRoots):
        * bindings/js/JSNodeOrString.cpp:
        (WebCore::toNodeOrStringVector):
        * bindings/js/JSOscillatorNodeCustom.cpp:
        (WebCore::JSOscillatorNode::setType):
        * bindings/js/JSPannerNodeCustom.cpp:
        (WebCore::JSPannerNode::setPanningModel):
        (WebCore::JSPannerNode::setDistanceModel):
        * bindings/js/JSPluginElementFunctions.cpp:
        (WebCore::pluginScriptObjectFromPluginViewBase):
        (WebCore::pluginScriptObject):
        (WebCore::pluginElementGetCallData):
        * bindings/js/JSPopStateEventCustom.cpp:
        (WebCore::JSPopStateEvent::state):
        * bindings/js/JSRTCStatsResponseCustom.cpp:
        (WebCore::JSRTCStatsResponse::nameGetter):
        * bindings/js/JSSQLResultSetRowListCustom.cpp:
        (WebCore::JSSQLResultSetRowList::item):
        * bindings/js/JSSQLTransactionCustom.cpp:
        (WebCore::JSSQLTransaction::executeSql):
        * bindings/js/JSSVGLengthCustom.cpp:
        (WebCore::JSSVGLength::value):
        (WebCore::JSSVGLength::setValue):
        (WebCore::JSSVGLength::convertToSpecifiedUnits):
        * bindings/js/JSStorageCustom.cpp:
        (WebCore::JSStorage::nameGetter):
        (WebCore::JSStorage::deleteProperty):
        (WebCore::JSStorage::getOwnPropertyNames):
        (WebCore::JSStorage::putDelegate):
        * bindings/js/JSStyleSheetCustom.cpp:
        (WebCore::JSStyleSheet::visitAdditionalChildren):
        * bindings/js/JSStyleSheetListCustom.cpp:
        (WebCore::JSStyleSheetList::nameGetter):
        * bindings/js/JSSubtleCryptoCustom.cpp:
        (WebCore::JSSubtleCrypto::encrypt):
        (WebCore::JSSubtleCrypto::decrypt):
        (WebCore::JSSubtleCrypto::sign):
        (WebCore::JSSubtleCrypto::verify):
        (WebCore::JSSubtleCrypto::wrapKey):
        (WebCore::JSSubtleCrypto::unwrapKey):
        * bindings/js/JSTextTrackCueCustom.cpp:
        (WebCore::JSTextTrackCueOwner::isReachableFromOpaqueRoots):
        (WebCore::JSTextTrackCue::visitAdditionalChildren):
        * bindings/js/JSTextTrackCustom.cpp:
        (WebCore::JSTextTrack::visitAdditionalChildren):
        (WebCore::JSTextTrack::setKind):
        (WebCore::JSTextTrack::setLanguage):
        * bindings/js/JSTextTrackListCustom.cpp:
        (WebCore::JSTextTrackList::visitAdditionalChildren):
        * bindings/js/JSTrackCustom.cpp:
        (WebCore::toTrack):
        * bindings/js/JSTrackEventCustom.cpp:
        (WebCore::JSTrackEvent::track):
        * bindings/js/JSTreeWalkerCustom.cpp:
        (WebCore::JSTreeWalker::visitAdditionalChildren):
        * bindings/js/JSUserMessageHandlersNamespaceCustom.cpp:
        (WebCore::JSUserMessageHandlersNamespace::getOwnPropertySlotDelegate):
        * bindings/js/JSVideoTrackCustom.cpp:
        (WebCore::JSVideoTrack::visitAdditionalChildren):
        (WebCore::JSVideoTrack::setKind):
        (WebCore::JSVideoTrack::setLanguage):
        * bindings/js/JSVideoTrackListCustom.cpp:
        (WebCore::JSVideoTrackList::visitAdditionalChildren):
        * bindings/js/JSWebGL2RenderingContextCustom.cpp:
        (WebCore::JSWebGL2RenderingContext::visitAdditionalChildren):
        (WebCore::JSWebGL2RenderingContext::getIndexedParameter):
        * bindings/js/JSWebGLRenderingContextBaseCustom.cpp:
        (WebCore::getObjectParameter):
        (WebCore::JSWebGLRenderingContextBase::visitAdditionalChildren):
        (WebCore::JSWebGLRenderingContextBase::getAttachedShaders):
        (WebCore::JSWebGLRenderingContextBase::getExtension):
        (WebCore::JSWebGLRenderingContextBase::getFramebufferAttachmentParameter):
        (WebCore::JSWebGLRenderingContextBase::getParameter):
        (WebCore::JSWebGLRenderingContextBase::getProgramParameter):
        (WebCore::JSWebGLRenderingContextBase::getShaderParameter):
        (WebCore::JSWebGLRenderingContextBase::getSupportedExtensions):
        (WebCore::JSWebGLRenderingContextBase::getUniform):
        (WebCore::JSWebGLRenderingContextBase::uniform1fv):
        (WebCore::JSWebGLRenderingContextBase::uniform1iv):
        (WebCore::JSWebGLRenderingContextBase::uniform2fv):
        (WebCore::JSWebGLRenderingContextBase::uniform2iv):
        (WebCore::JSWebGLRenderingContextBase::uniform3fv):
        (WebCore::JSWebGLRenderingContextBase::uniform3iv):
        (WebCore::JSWebGLRenderingContextBase::uniform4fv):
        (WebCore::JSWebGLRenderingContextBase::uniform4iv):
        (WebCore::JSWebGLRenderingContextBase::uniformMatrix2fv):
        (WebCore::JSWebGLRenderingContextBase::uniformMatrix3fv):
        (WebCore::JSWebGLRenderingContextBase::uniformMatrix4fv):
        (WebCore::JSWebGLRenderingContextBase::vertexAttrib1fv):
        (WebCore::JSWebGLRenderingContextBase::vertexAttrib2fv):
        (WebCore::JSWebGLRenderingContextBase::vertexAttrib3fv):
        (WebCore::JSWebGLRenderingContextBase::vertexAttrib4fv):
        * bindings/js/JSWebGLRenderingContextCustom.cpp:
        (WebCore::JSWebGLRenderingContext::visitAdditionalChildren):
        * bindings/js/JSWorkerCustom.cpp:
        (WebCore::JSWorker::postMessage):
        (WebCore::constructJSWorker):
        * bindings/js/JSWorkerGlobalScopeBase.cpp:
        (WebCore::JSWorkerGlobalScopeBase::JSWorkerGlobalScopeBase):
        (WebCore::JSWorkerGlobalScopeBase::scriptExecutionContext):
        * bindings/js/JSWorkerGlobalScopeBase.h:
        (WebCore::JSWorkerGlobalScopeBase::wrapped):
        * bindings/js/JSWorkerGlobalScopeCustom.cpp:
        (WebCore::JSWorkerGlobalScope::visitAdditionalChildren):
        (WebCore::JSWorkerGlobalScope::importScripts):
        (WebCore::JSWorkerGlobalScope::setTimeout):
        (WebCore::JSWorkerGlobalScope::setInterval):
        * bindings/js/JSXMLHttpRequestCustom.cpp:
        (WebCore::JSXMLHttpRequest::visitAdditionalChildren):
        (WebCore::JSXMLHttpRequest::open):
        (WebCore::JSXMLHttpRequest::send):
        (WebCore::JSXMLHttpRequest::responseText):
        (WebCore::JSXMLHttpRequest::response):
        * bindings/js/JSXPathResultCustom.cpp:
        (WebCore::JSXPathResult::visitAdditionalChildren):
        * bindings/js/JSXSLTProcessorCustom.cpp:
        (WebCore::JSXSLTProcessor::setParameter):
        (WebCore::JSXSLTProcessor::getParameter):
        (WebCore::JSXSLTProcessor::removeParameter):
        * bindings/js/ScheduledAction.cpp:
        (WebCore::ScheduledAction::execute):
        * bindings/js/ScriptCachedFrameData.cpp:
        (WebCore::ScriptCachedFrameData::restore):
        * bindings/js/ScriptController.cpp:
        (WebCore::ScriptController::clearWindowShell):
        (WebCore::ScriptController::collectIsolatedContexts):
        * bindings/js/ScriptState.cpp:
        (WebCore::domWindowFromExecState):
        * bindings/objc/DOM.mm:
        (+[DOMNode _nodeFromJSWrapper:]):
        * bindings/objc/DOMUtility.mm:
        (JSC::createDOMWrapper):
        * bindings/objc/WebScriptObject.mm:
        (-[WebScriptObject _isSafeScript]):
        (+[WebScriptObject _convertValueToObjcValue:originRootObject:rootObject:]):
        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateGetOwnPropertySlotBody):
        (GenerateHeader):
        (GetIndexedGetterExpression):
        (GenerateImplementation):
        (NativeToJSValue):
        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
        (WebCore::jsTestActiveDOMObjectExcitingAttr):
        (WebCore::jsTestActiveDOMObjectConstructor):
        (WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunction):
        (WebCore::jsTestActiveDOMObjectPrototypeFunctionPostMessage):
        (WebCore::JSTestActiveDOMObjectOwner::finalize):
        (WebCore::JSTestActiveDOMObject::toWrapped):
        * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectOwner::finalize):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObject::toWrapped):
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
        (WebCore::jsTestCustomNamedGetterPrototypeFunctionAnotherFunction):
        (WebCore::JSTestCustomNamedGetterOwner::finalize):
        (WebCore::JSTestCustomNamedGetter::toWrapped):
        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
        (WebCore::jsTestEventConstructorAttr1):
        (WebCore::jsTestEventConstructorAttr2):
        (WebCore::JSTestEventConstructorOwner::finalize):
        (WebCore::JSTestEventConstructor::toWrapped):
        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
        (WebCore::JSTestEventTarget::getOwnPropertySlot):
        (WebCore::JSTestEventTarget::getOwnPropertySlotByIndex):
        (WebCore::JSTestEventTarget::getOwnPropertyNames):
        (WebCore::jsTestEventTargetPrototypeFunctionItem):
        (WebCore::jsTestEventTargetPrototypeFunctionAddEventListener):
        (WebCore::jsTestEventTargetPrototypeFunctionRemoveEventListener):
        (WebCore::jsTestEventTargetPrototypeFunctionDispatchEvent):
        (WebCore::JSTestEventTarget::visitChildren):
        (WebCore::JSTestEventTargetOwner::isReachableFromOpaqueRoots):
        (WebCore::JSTestEventTargetOwner::finalize):
        (WebCore::JSTestEventTarget::toWrapped):
        * bindings/scripts/test/JS/JSTestException.cpp:
        (WebCore::jsTestExceptionName):
        (WebCore::JSTestExceptionOwner::finalize):
        (WebCore::JSTestException::toWrapped):
        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
        (WebCore::JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots):
        (WebCore::JSTestGenerateIsReachableOwner::finalize):
        (WebCore::JSTestGenerateIsReachable::toWrapped):
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        (WebCore::jsTestInterfaceImplementsStr1):
        (WebCore::jsTestInterfaceImplementsStr2):
        (WebCore::jsTestInterfaceImplementsNode):
        (WebCore::jsTestInterfaceSupplementalStr1):
        (WebCore::jsTestInterfaceSupplementalStr2):
        (WebCore::jsTestInterfaceSupplementalNode):
        (WebCore::setJSTestInterfaceImplementsStr2):
        (WebCore::setJSTestInterfaceImplementsNode):
        (WebCore::setJSTestInterfaceSupplementalStr2):
        (WebCore::setJSTestInterfaceSupplementalNode):
        (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod1):
        (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2):
        (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod1):
        (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
        (WebCore::JSTestInterfaceOwner::isReachableFromOpaqueRoots):
        (WebCore::JSTestInterfaceOwner::finalize):
        (WebCore::JSTestInterface::toWrapped):
        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
        (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):
        (WebCore::JSTestMediaQueryListListenerOwner::finalize):
        (WebCore::JSTestMediaQueryListListener::toWrapped):
        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
        (WebCore::JSTestNamedConstructorOwner::isReachableFromOpaqueRoots):
        (WebCore::JSTestNamedConstructorOwner::finalize):
        (WebCore::JSTestNamedConstructor::toWrapped):
        * bindings/scripts/test/JS/JSTestNode.cpp:
        (WebCore::jsTestNodeName):
        (WebCore::setJSTestNodeName):
        (WebCore::JSTestNode::visitChildren):
        * bindings/scripts/test/JS/JSTestNode.h:
        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
        (WebCore::jsTestNondeterministicNondeterministicReadonlyAttr):
        (WebCore::jsTestNondeterministicNondeterministicWriteableAttr):
        (WebCore::jsTestNondeterministicNondeterministicExceptionAttr):
        (WebCore::jsTestNondeterministicNondeterministicGetterExceptionAttr):
        (WebCore::jsTestNondeterministicNondeterministicSetterExceptionAttr):
        (WebCore::setJSTestNondeterministicNondeterministicWriteableAttr):
        (WebCore::setJSTestNondeterministicNondeterministicExceptionAttr):
        (WebCore::setJSTestNondeterministicNondeterministicGetterExceptionAttr):
        (WebCore::setJSTestNondeterministicNondeterministicSetterExceptionAttr):
        (WebCore::jsTestNondeterministicPrototypeFunctionNondeterministicZeroArgFunction):
        (WebCore::JSTestNondeterministicOwner::finalize):
        (WebCore::JSTestNondeterministic::toWrapped):
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::jsTestObjReadOnlyLongAttr):
        (WebCore::jsTestObjReadOnlyStringAttr):
        (WebCore::jsTestObjReadOnlyTestObjAttr):
        (WebCore::jsTestObjTestSubObjEnabledBySettingConstructor):
        (WebCore::jsTestObjEnumAttr):
        (WebCore::jsTestObjByteAttr):
        (WebCore::jsTestObjOctetAttr):
        (WebCore::jsTestObjShortAttr):
        (WebCore::jsTestObjUnsignedShortAttr):
        (WebCore::jsTestObjLongAttr):
        (WebCore::jsTestObjLongLongAttr):
        (WebCore::jsTestObjUnsignedLongLongAttr):
        (WebCore::jsTestObjStringAttr):
        (WebCore::jsTestObjTestObjAttr):
        (WebCore::jsTestObjXMLObjAttr):
        (WebCore::jsTestObjCreate):
        (WebCore::jsTestObjReflectedStringAttr):
        (WebCore::jsTestObjReflectedIntegralAttr):
        (WebCore::jsTestObjReflectedUnsignedIntegralAttr):
        (WebCore::jsTestObjReflectedBooleanAttr):
        (WebCore::jsTestObjReflectedURLAttr):
        (WebCore::jsTestObjReflectedCustomIntegralAttr):
        (WebCore::jsTestObjReflectedCustomBooleanAttr):
        (WebCore::jsTestObjReflectedCustomURLAttr):
        (WebCore::jsTestObjTypedArrayAttr):
        (WebCore::jsTestObjAttrWithGetterException):
        (WebCore::jsTestObjAttrWithSetterException):
        (WebCore::jsTestObjStringAttrWithGetterException):
        (WebCore::jsTestObjStringAttrWithSetterException):
        (WebCore::jsTestObjStrictTypeCheckingAttribute):
        (WebCore::jsTestObjOnfoo):
        (WebCore::jsTestObjWithScriptStateAttribute):
        (WebCore::jsTestObjWithCallWithAndSetterCallWithAttribute):
        (WebCore::jsTestObjWithScriptExecutionContextAttribute):
        (WebCore::jsTestObjWithScriptStateAttributeRaises):
        (WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
        (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttribute):
        (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
        (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
        (WebCore::jsTestObjWithScriptArgumentsAndCallStackAttribute):
        (WebCore::jsTestObjConditionalAttr1):
        (WebCore::jsTestObjConditionalAttr2):
        (WebCore::jsTestObjConditionalAttr3):
        (WebCore::jsTestObjCachedAttribute1):
        (WebCore::jsTestObjCachedAttribute2):
        (WebCore::jsTestObjAnyAttribute):
        (WebCore::jsTestObjContentDocument):
        (WebCore::jsTestObjMutablePoint):
        (WebCore::jsTestObjImmutablePoint):
        (WebCore::jsTestObjStrawberry):
        (WebCore::jsTestObjStrictFloat):
        (WebCore::jsTestObjDescription):
        (WebCore::jsTestObjId):
        (WebCore::jsTestObjHash):
        (WebCore::jsTestObjReplaceableAttribute):
        (WebCore::jsTestObjNullableDoubleAttribute):
        (WebCore::jsTestObjNullableLongAttribute):
        (WebCore::jsTestObjNullableBooleanAttribute):
        (WebCore::jsTestObjNullableStringAttribute):
        (WebCore::jsTestObjNullableLongSettableAttribute):
        (WebCore::jsTestObjNullableStringValue):
        (WebCore::jsTestObjAttribute):
        (WebCore::jsTestObjAttributeWithReservedEnumType):
        (WebCore::jsTestObjPutForwardsAttribute):
        (WebCore::jsTestObjPutForwardsNullableAttribute):
        (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::setJSTestObjStrictTypeCheckingAttribute):
        (WebCore::setJSTestObjOnfoo):
        (WebCore::setJSTestObjWithScriptStateAttribute):
        (WebCore::setJSTestObjWithCallWithAndSetterCallWithAttribute):
        (WebCore::setJSTestObjWithScriptExecutionContextAttribute):
        (WebCore::setJSTestObjWithScriptStateAttributeRaises):
        (WebCore::setJSTestObjWithScriptExecutionContextAttributeRaises):
        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttribute):
        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
        (WebCore::setJSTestObjWithScriptArgumentsAndCallStackAttribute):
        (WebCore::setJSTestObjConditionalAttr1):
        (WebCore::setJSTestObjConditionalAttr2):
        (WebCore::setJSTestObjConditionalAttr3):
        (WebCore::setJSTestObjAnyAttribute):
        (WebCore::setJSTestObjMutablePoint):
        (WebCore::setJSTestObjImmutablePoint):
        (WebCore::setJSTestObjStrawberry):
        (WebCore::setJSTestObjStrictFloat):
        (WebCore::setJSTestObjId):
        (WebCore::setJSTestObjNullableLongSettableAttribute):
        (WebCore::setJSTestObjNullableStringValue):
        (WebCore::setJSTestObjAttributeWithReservedEnumType):
        (WebCore::setJSTestObjPutForwardsAttribute):
        (WebCore::setJSTestObjPutForwardsNullableAttribute):
        (WebCore::jsTestObjPrototypeFunctionVoidMethod):
        (WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
        (WebCore::jsTestObjPrototypeFunctionByteMethod):
        (WebCore::jsTestObjPrototypeFunctionByteMethodWithArgs):
        (WebCore::jsTestObjPrototypeFunctionOctetMethod):
        (WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgs):
        (WebCore::jsTestObjPrototypeFunctionLongMethod):
        (WebCore::jsTestObjPrototypeFunctionLongMethodWithArgs):
        (WebCore::jsTestObjPrototypeFunctionObjMethod):
        (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
        (WebCore::jsTestObjPrototypeFunctionMethodWithSequenceArg):
        (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
        (WebCore::jsTestObjPrototypeFunctionMethodWithEnumArg):
        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalEnumArgAndDefaultValue):
        (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
        (WebCore::jsTestObjPrototypeFunctionSerializedValue):
        (WebCore::jsTestObjPrototypeFunctionOptionsObject):
        (WebCore::jsTestObjPrototypeFunctionMethodWithException):
        (WebCore::jsTestObjPrototypeFunctionPrivateMethod):
        (WebCore::jsTestObjPrototypeFunctionAddEventListener):
        (WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
        (WebCore::jsTestObjPrototypeFunctionWithScriptStateVoid):
        (WebCore::jsTestObjPrototypeFunctionWithScriptStateObj):
        (WebCore::jsTestObjPrototypeFunctionWithScriptStateVoidException):
        (WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContext):
        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptState):
        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateObjException):
        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateWithSpaces):
        (WebCore::jsTestObjPrototypeFunctionWithScriptArgumentsAndCallStack):
        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArg):
        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArgAndDefaultValue):
        (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArg):
        (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgs):
        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalString):
        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringAndDefaultValue):
        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsUndefined):
        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsNullString):
        (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
        (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
        (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArg):
        (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackFunctionArg):
        (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackFunctionArg):
        (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackFunctionAndOptionalArg):
        (WebCore::jsTestObjPrototypeFunctionConditionalMethod1):
        (WebCore::jsTestObjPrototypeFunctionConditionalMethod2):
        (WebCore::jsTestObjPrototypeFunctionConditionalMethod3):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod1):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod3):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod4):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod6):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod7):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod8):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod9):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod10):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod11):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod12):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter1):
        (WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter2):
        (WebCore::jsTestObjPrototypeFunctionClassMethodWithClamp):
        (WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequence):
        (WebCore::jsTestObjPrototypeFunctionStringArrayFunction):
        (WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
        (WebCore::jsTestObjPrototypeFunctionMethodWithAndWithoutNullableSequence):
        (WebCore::jsTestObjPrototypeFunctionMethodWithAndWithoutNullableSequence2):
        (WebCore::jsTestObjPrototypeFunctionGetSVGDocument):
        (WebCore::jsTestObjPrototypeFunctionConvert1):
        (WebCore::jsTestObjPrototypeFunctionConvert2):
        (WebCore::jsTestObjPrototypeFunctionConvert4):
        (WebCore::jsTestObjPrototypeFunctionConvert5):
        (WebCore::jsTestObjPrototypeFunctionMutablePointFunction):
        (WebCore::jsTestObjPrototypeFunctionImmutablePointFunction):
        (WebCore::jsTestObjPrototypeFunctionOrange):
        (WebCore::jsTestObjPrototypeFunctionStrictFunction):
        (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithSequence):
        (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithArray):
        (WebCore::jsTestObjPrototypeFunctionVariadicStringMethod):
        (WebCore::jsTestObjPrototypeFunctionVariadicDoubleMethod):
        (WebCore::jsTestObjPrototypeFunctionVariadicNodeMethod):
        (WebCore::jsTestObjPrototypeFunctionAny):
        (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionPromise):
        (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithFloatArgumentPromise):
        (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithExceptionPromise):
        (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithOptionalIntArgumentPromise):
        (WebCore::JSTestObjOwner::finalize):
        (WebCore::JSTestObj::toWrapped):
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
        (WebCore::JSTestOverloadedConstructorsOwner::finalize):
        (WebCore::JSTestOverloadedConstructors::toWrapped):
        * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
        (WebCore::JSTestOverrideBuiltins::getOwnPropertyNames):
        (WebCore::jsTestOverrideBuiltinsPrototypeFunctionNamedItem):
        (WebCore::JSTestOverrideBuiltinsOwner::finalize):
        (WebCore::JSTestOverrideBuiltins::toWrapped):
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
        (WebCore::jsTestSerializedScriptValueInterfaceValue):
        (WebCore::jsTestSerializedScriptValueInterfaceReadonlyValue):
        (WebCore::jsTestSerializedScriptValueInterfaceCachedValue):
        (WebCore::jsTestSerializedScriptValueInterfacePorts):
        (WebCore::jsTestSerializedScriptValueInterfaceCachedReadonlyValue):
        (WebCore::setJSTestSerializedScriptValueInterfaceValue):
        (WebCore::setJSTestSerializedScriptValueInterfaceCachedValue):
        (WebCore::JSTestSerializedScriptValueInterfaceOwner::finalize):
        (WebCore::JSTestSerializedScriptValueInterface::toWrapped):
        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
        (WebCore::jsTestTypedefsUnsignedLongLongAttr):
        (WebCore::jsTestTypedefsImmutableSerializedScriptValue):
        (WebCore::jsTestTypedefsAttrWithGetterException):
        (WebCore::jsTestTypedefsAttrWithSetterException):
        (WebCore::jsTestTypedefsStringAttrWithGetterException):
        (WebCore::jsTestTypedefsStringAttrWithSetterException):
        (WebCore::setJSTestTypedefsUnsignedLongLongAttr):
        (WebCore::setJSTestTypedefsImmutableSerializedScriptValue):
        (WebCore::setJSTestTypedefsAttrWithGetterException):
        (WebCore::setJSTestTypedefsAttrWithSetterException):
        (WebCore::setJSTestTypedefsStringAttrWithGetterException):
        (WebCore::setJSTestTypedefsStringAttrWithSetterException):
        (WebCore::jsTestTypedefsPrototypeFunctionFunc):
        (WebCore::jsTestTypedefsPrototypeFunctionSetShadow):
        (WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArg):
        (WebCore::jsTestTypedefsPrototypeFunctionNullableArrayArg):
        (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClamp):
        (WebCore::jsTestTypedefsPrototypeFunctionImmutablePointFunction):
        (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction):
        (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction2):
        (WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresInclude):
        (WebCore::jsTestTypedefsPrototypeFunctionMethodWithException):
        (WebCore::JSTestTypedefsOwner::finalize):
        (WebCore::JSTestTypedefs::toWrapped):
        * bindings/scripts/test/JS/JSattribute.cpp:
        (WebCore::jsattributeReadonly):
        (WebCore::JSattributeOwner::finalize):
        (WebCore::JSattribute::toWrapped):
        * bindings/scripts/test/JS/JSreadonly.cpp:
        (WebCore::JSreadonlyOwner::finalize):
        (WebCore::JSreadonly::toWrapped):
        * bridge/runtime_method.cpp:
        (JSC::callRuntimeMethod):
        * inspector/InspectorController.cpp:
        (WebCore::InspectorController::canAccessInspectedScriptState):

2015-11-02  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        IDL functions and attributes should be JSBuiltin by default if interface is marked as JSBuiltinConstructor
        https://bugs.webkit.org/show_bug.cgi?id=150438

        Reviewed by Darin Adler.

        Binding generator is now deducing that function/attribute is JSBuiltin if the interface is marked as JSBuiltin.
        One exception is custom setters, getters or functions which remain C++ handled.
        Updated streams API IDLs accordingly.

        Binding generator knows whether class needs a DOM class by checking whether the interface is marked as JSBuiltin.
        Binding generator knows that class uses a JS built-in constructor if marked as JSBuiltin+Constructor.
        In particular, JSBuiltIn+CustomConstructor means that a DOM class is not needed and constructor is not JS built-in.

        Applied JSBuiltin+CustomConstructor to ReadableStreamReader and ReadableStreamController.
        Removing ReadableStreamReader and ReadableStreamController classes.

        Removed unneeded "Default" keyword for cancel function in WebIDL.

        Added a binding test case.
        No change in behavior.

        * Modules/streams/ByteLengthQueuingStrategy.idl: Marking interface as JSBuiltin and Constructable.
        * Modules/streams/CountQueuingStrategy.idl: Ditto.
        * Modules/streams/ReadableStream.idl: Ditto.
        * Modules/streams/ReadableStreamController.h: Removed.
        * Modules/streams/ReadableStreamController.idl: Marking interface as JSBuiltin and Constructable.
        * Modules/streams/ReadableStreamReader.h: Removed.
        * Modules/streams/ReadableStreamReader.idl: Marking interface as JSBuiltin and Constructable.
        * Modules/streams/WritableStream.idl: Ditto.
        * bindings/js/JSReadableStreamPrivateConstructors.cpp:
        (WebCore::JSBuiltinReadableStreamReaderPrivateConstructor::createJSObject): Updated according new constructor.
        (WebCore::JSBuiltinReadableStreamControllerPrivateConstructor::createJSObject): Ditto.
        * bindings/scripts/CodeGeneratorJS.pm:
        (NeedsImplementationClass):
        (GetAttributeGetterName):
        (GetAttributeSetterName):
        (GetFunctionName):
        (InstanceNeedsVisitChildren):
        (GenerateHeader):
        (GenerateAttributesHashTable):
        (GenerateImplementation):
        (GetConstructorTemplateClassName):
        (GenerateConstructorDefinition):
        (GenerateConstructorHelperMethods):
        (IsConstructable):
        (ComputeFunctionSpecial):
        (IsJSBuiltin):
        (IsJSBuiltinConstructor):
        (AddJSBuiltinIncludesIfNeeded):
        (GetJSBuiltinFunctionName): Deleted.
        (GetJSBuiltinFunctionNameFromString): Deleted.
        (GetJSBuiltinScopeName): Deleted.
        * bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.cpp:
        (webkit_dom_test_js_builtin_constructor_set_property):
        (webkit_dom_test_js_builtin_constructor_get_property):
        (webkit_dom_test_js_builtin_constructor_class_init):
        (webkit_dom_test_js_builtin_constructor_test_function):
        (webkit_dom_test_js_builtin_constructor_get_test_attribute):
        (webkit_dom_test_js_builtin_constructor_set_test_attribute):
        * bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.h:
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
        (WebCore::JSTestJSBuiltinConstructor::JSTestJSBuiltinConstructor):
        (WebCore::JSTestJSBuiltinConstructor::getOwnPropertySlot):
        (WebCore::jsTestJSBuiltinConstructorTestAttribute):
        (WebCore::jsTestJSBuiltinConstructorTestAttributeCustom):
        (WebCore::jsTestJSBuiltinConstructorTestAttributeRWCustom):
        (WebCore::setJSTestJSBuiltinConstructorTestAttribute):
        (WebCore::setJSTestJSBuiltinConstructorTestAttributeRWCustom):
        (WebCore::jsTestJSBuiltinConstructorPrototypeFunctionTestFunction):
        (WebCore::jsTestJSBuiltinConstructorPrototypeFunctionTestCustomFunction):
        (WebCore::JSTestJSBuiltinConstructorOwner::isReachableFromOpaqueRoots):
        (WebCore::JSTestJSBuiltinConstructorOwner::finalize):
        (WebCore::toJSNewlyCreated):
        (WebCore::toJS):
        (WebCore::JSTestJSBuiltinConstructor::toWrapped):
        (WebCore::JSTestJSBuiltinConstructorPrototype::createStructure): Deleted.
        (WebCore::JSTestJSBuiltinConstructorConstructor::initializeProperties): Deleted.
        (WebCore::JSTestJSBuiltinConstructor::createPrototype): Deleted.
        (WebCore::JSTestJSBuiltinConstructor::getPrototype): Deleted.
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.h:
        (WebCore::JSTestJSBuiltinConstructor::create):
        (WebCore::JSTestJSBuiltinConstructor::finishCreation):
        (WebCore::wrapperOwner):
        (WebCore::toJS):
        (WebCore::JSTestJSBuiltinConstructor::createStructure): Deleted.
        * bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.h:
        * bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.mm:
        (-[DOMTestJSBuiltinConstructor testAttribute]):
        (-[DOMTestJSBuiltinConstructor setTestAttribute:]):
        (-[DOMTestJSBuiltinConstructor testAttributeCustom]):
        (-[DOMTestJSBuiltinConstructor testAttributeRWCustom]):
        (-[DOMTestJSBuiltinConstructor setTestAttributeRWCustom:]):
        (-[DOMTestJSBuiltinConstructor testFunction]):
        (-[DOMTestJSBuiltinConstructor testCustomFunction]):
        * bindings/scripts/test/TestJSBuiltinConstructor.idl:

2015-10-29  Sergio Villar Senin  <svillar@igalia.com>

        [CSS Grid Layout] min-content row does not always shrink
        https://bugs.webkit.org/show_bug.cgi?id=144581

        Reviewed by Zalan Bujtas.

        Grid items height must be recomputed whenever the grid tracks
        change if the items had been previously stretched. In those
        cases we have to clear the override height and layout the item
        with the new row size.

        Tests: fast/css-grid-layout/min-content-row-must-shrink-when-column-grows.html
               fast/css-grid-layout/relayout-indefinite-heights.html

        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::logicalContentHeightForChild):

2015-11-01  Brady Eidson  <beidson@apple.com>

        Modern IDB: IBDObjectStore.count() support.
        https://bugs.webkit.org/show_bug.cgi?id=150785

        Reviewed by Darin Adler.

        Tests: storage/indexeddb/modern/idbobjectstore-count-1.html
               storage/indexeddb/modern/idbobjectstore-count-failures.html

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::getCount):
        (WebCore::IDBClient::IDBConnectionToServer::didGetCount):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:
        
        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::count):
        (WebCore::IDBClient::IDBObjectStore::doCount):
        * Modules/indexeddb/client/IDBObjectStoreImpl.h:
        
        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::setResult):
        * Modules/indexeddb/client/IDBRequestImpl.h:
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::requestCount):
        (WebCore::IDBClient::IDBTransaction::getCountOnServer):
        (WebCore::IDBClient::IDBTransaction::didGetCountOnServer):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        
        * Modules/indexeddb/server/IDBBackingStore.h:
        
        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didGetCount):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:
        
        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::getCount):
        * Modules/indexeddb/server/IDBServer.h:
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::getCount):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::countForKeyRange):
        (WebCore::IDBServer::MemoryObjectStore::valueForKeyRange):
        (WebCore::IDBServer::MemoryObjectStore::lowestKeyWithRecordInRange):
        * Modules/indexeddb/server/MemoryObjectStore.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::storeCallback):
        (WebCore::IDBServer::UniqueIDBDatabase::getCount):
        (WebCore::IDBServer::UniqueIDBDatabase::performGetCount):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformGetCount):
        (WebCore::IDBServer::UniqueIDBDatabase::performCountCallback):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::getRecord):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::getCount):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
        
        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::IDBResultData):
        (WebCore::IDBResultData::getCountSuccess):
        * Modules/indexeddb/shared/IDBResultData.h:
        (WebCore::IDBResultData::resultInteger):
        
        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didGetCount):
        (WebCore::InProcessIDBServer::getCount):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

2015-11-01  Darin Adler  <darin@apple.com>

        Tidy handling of type=color in HTMLInputElement a bit
        https://bugs.webkit.org/show_bug.cgi?id=150786

        Reviewed by Andreas Kling.

        * html/ColorInputType.cpp: Fix formatting.
        (WebCore::ColorInputType::fallbackValue): Use ASCIILiteral for slightly
        better performance.
        (WebCore::ColorInputType::sanitizeValue): Use convertToASCIILowercase,
        since there is no need for the general purpose Unicode lowercasing here;
        those non-ASCII characters aren't allowed by isValidColorString.
        (WebCore::ColorInputType::suggestions): Rewrote data list code to remove
        peculiarities such as using a null check to terminate the loop instead of
        the collection length, calling back to HTMLInputElement just to get the
        isValidColorString function called. Also used reserveInitialCapacity and
        uncheckedAppend for better memory use in the result vector.
        (WebCore::ColorInputType::selectColor): Added.

        * html/ColorInputType.h: Made derivation from ColorChooserClient private.
        Made most functions private. Added overrides for valueAsColor and selectColor,
        now both virtual functions in InputType.

        * html/HTMLInputElement.cpp: Removed now-unneeded include of ColorInputType.h.
        (WebCore::HTMLInputElement::valueAsColor): Added. Calls through to the InputType.
        In a later patch, will be used by accessibility code to get the color so it
        does not have to replicate the color parsing logic from this element.
        (WebCore::HTMLInputElement::selectColor): Renamed from selectColorInColorChooser,
        because the longer name is not clearer. Also made this non-conditional.

        * html/HTMLInputElement.h: Added valueAsColor, renamed selectColorInColorChooser
        to selectColor and made it available unconditionally.

        * html/InputType.cpp:
        (WebCore::InputType::valueAsColor): Added. Returns transparent color.
        (WebCore::InputType::selectColor): Added. Does nothing by default.

        * html/InputType.h: Added virtual valueAsColor and selectColor. Also tidied
        up the header a bit and removed unneeded Noncopyable (since this class has
        a reference for one of the data members and so is intrinsically not copyable).
        Made isColorControl available unconditionally.

        * testing/Internals.cpp:
        (WebCore::Internals::selectColorInColorChooser): Removed conditionals and
        made this call selectColor rather than selectColorInColorChooser.

        * testing/Internals.h: Made selectColorInColorChooser unconditional.

        * testing/Internals.idl: Made selectColorInColorChooser unconditionally
        present. Not important to optimize the test internals class by leaving it
        out when INPUT_TYPE_COLOR is not enabled.

2015-11-01  Yusuke Suzuki  <utatane.tea@gmail.com>

        [ES6] Support Generator Syntax
        https://bugs.webkit.org/show_bug.cgi?id=150769

        Reviewed by Geoffrey Garen.

        Added ENABLE_ES6_GENERATORS flag.

        * Configurations/FeatureDefines.xcconfig:

2015-11-01  Myles C. Maxfield  <mmaxfield@apple.com>

        Clean up some CSS & Font code
        https://bugs.webkit.org/show_bug.cgi?id=150767

        Reviewed by Darin Adler.

        This patch migrates some CSS code to use references instead of pointers.
        It also migrates some Font code to use RefPtr instead of PassRefPtr.

        No new tests because there is no behavior change.

        * css/CSSDefaultStyleSheets.cpp:
        (WebCore::CSSDefaultStyleSheets::loadFullDefaultStyle):
        (WebCore::CSSDefaultStyleSheets::loadSimpleDefaultStyle):
        (WebCore::CSSDefaultStyleSheets::ensureDefaultStyleSheetsForElement):
        * css/CSSFontSelector.cpp:
        (WebCore::createFontFace):
        (WebCore::CSSFontSelector::addFontFaceRule):
        * css/CSSFontSelector.h:
        * css/DocumentRuleSets.cpp:
        (WebCore::DocumentRuleSets::initUserStyle):
        (WebCore::DocumentRuleSets::collectRulesFromUserStyleSheets):
        (WebCore::DocumentRuleSets::appendAuthorStyleSheets):
        * css/RuleSet.cpp:
        (WebCore::RuleSet::addChildRules):
        (WebCore::RuleSet::addRulesFromSheet):
        * css/RuleSet.h:
        * css/StyleInvalidationAnalysis.cpp:
        (WebCore::StyleInvalidationAnalysis::StyleInvalidationAnalysis):
        * platform/graphics/Font.cpp:
        (WebCore::Font::verticalRightOrientationFont):
        (WebCore::Font::uprightOrientationFont):
        (WebCore::Font::smallCapsFont):
        (WebCore::Font::emphasisMarkFont):
        (WebCore::Font::brokenIdeographFont):
        (WebCore::Font::nonSyntheticItalicFont):
        (WebCore::Font::createScaledFont):
        * platform/graphics/Font.h:
        (WebCore::Font::variantFont):
        * platform/graphics/cocoa/FontCocoa.mm:
        (WebCore::Font::platformCreateScaledFont):
        * svg/SVGFontFaceElement.h:

2015-11-01  Darin Adler  <darin@apple.com>

        Remove some dead and unneeded code (ScrollbarThemeSafari, RenderThemeSafari, OPENCL, a little color space logic)
        https://bugs.webkit.org/show_bug.cgi?id=150783

        Reviewed by Tim Horton.

        * PlatformWinCairo.cmake: Removed ScrollbarThemeSafari.cpp, no reason to compile it.

        * platform/graphics/ca/GraphicsLayerCA.cpp:
        (WebCore::GraphicsLayerCA::setContentsToImage): Removed the code that set a color space
        on an image if it's set to device color space. This has been dead code for many releases
        of OS X and iOS at this point.

        * platform/graphics/filters/FEColorMatrix.h: Removed some ENABLE(OPENCL)-only code.
        * platform/graphics/filters/FEFlood.h: Ditto.
        * platform/graphics/filters/FEMerge.h: Ditto.
        * platform/graphics/filters/FETurbulence.h: Ditto.
        * platform/graphics/filters/FilterEffect.cpp:
        (WebCore::FilterEffect::applyAll): Removed.
        (WebCore::FilterEffect::apply): Removed ENABLE(OPENCL)-only code.
        (WebCore::FilterEffect::platformApplyOpenCL): Removed.
        (WebCore::FilterEffect::clearResult): Removed ENABLE(OPENCL)-only code.
        (WebCore::FilterEffect::asImageBuffer): Ditto.
        (WebCore::FilterEffect::openCLImageToImageBuffer): Removed.
        (WebCore::FilterEffect::createOpenCLImageResult): Removed.
        (WebCore::FilterEffect::transformResultColorSpace): Removed ENABLE(OPENCL)-only code.

        * platform/graphics/filters/FilterEffect.h: Removed ENABLE(OPENCL)-only code.
        * platform/graphics/filters/SourceAlpha.h: Ditto.
        * platform/graphics/filters/SourceGraphic.h: Ditto.

        * platform/win/ScrollbarThemeSafari.cpp: Removed.
        * platform/win/ScrollbarThemeSafari.h: Removed.

        * rendering/RenderThemeMac.mm: Removed an obsolete comment.

        * rendering/RenderThemeSafari.cpp: Removed.
        * rendering/RenderThemeSafari.h: Removed.

        * svg/graphics/filters/SVGFEImage.h: Removed ENABLE(OPENCL)-only code.

2015-11-01  Andreas Kling  <akling@apple.com>

        Move the ResourceUsageOverlay out of the way by default.
        <https://webkit.org/b/150776>

        Reviewed by Darin Adler.

        Have the ResourceUsageOverlay show up in the bottom center of the viewport
        by default, instead of the top left. This way, you won't have to drag it
        out of the way all the time.

        * page/ResourceUsageOverlay.cpp:
        (WebCore::ResourceUsageOverlay::ResourceUsageOverlay):
        (WebCore::ResourceUsageOverlay::initialize):
        * page/ResourceUsageOverlay.h:
        * page/cocoa/ResourceUsageOverlayCocoa.mm:
        (WebCore::ResourceUsageOverlay::platformInitialize):

2015-11-01  Philip Chimento  <philip.chimento@gmail.com>

        [GTK] Fix combinations of PLATFORM(GTK) and OS(DARWIN)
        https://bugs.webkit.org/show_bug.cgi?id=144560

        Reviewed by Darin Adler.

        * platform/graphics/PlatformDisplay.cpp: Only include the
        X11-specific GDK header on PLATFORM(X11). In other cases the
        normal gdk.h header is needed, which would otherwise be pulled in
        by gdkx.h.
        * platform/graphics/opentype/OpenTypeMathData.cpp: Change check
        for FourCharCode type from OS(DARWIN) to PLATFORM(COCOA). We
        can't remove it altogether because OT_MAKE_TAG doesn't work for
        all platforms.

2015-11-01  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GTK] Use RunLoop::Timer in main thread shared timer GTK+ implementation
        https://bugs.webkit.org/show_bug.cgi?id=150754

        Reviewed by Darin Adler.

        It's more efficient because it uses a persistent source and it
        simplifies the code even more.

        * platform/MainThreadSharedTimer.cpp:
        (WebCore::MainThreadSharedTimer::fired): Make it non-const to be
        able to use it as function callback of a RunLoop::Timer.
        * platform/MainThreadSharedTimer.h:
        * platform/gtk/MainThreadSharedTimerGtk.cpp:
        (WebCore::MainThreadSharedTimer::MainThreadSharedTimer):
        Initialize the RunLoop::Timer and set the prioriry.
        (WebCore::MainThreadSharedTimer::setFireInterval):
        (WebCore::MainThreadSharedTimer::stop):

2015-10-31  Andreas Kling  <akling@apple.com>

        Add a debug overlay with information about web process resource usage.
        <https://webkit.org/b/150599>

        Unreviewed follow-up to r191849.

        Add missing call to uninstall the PageOverlay if the ResourceUsageOverlay is being
        disabled through the setting. This way you don't end up with an unremovable overlay
        in the MiniBrowser.

        * page/ResourceUsageOverlay.cpp:
        (WebCore::ResourceUsageOverlay::~ResourceUsageOverlay):

2015-10-31  Brady Eidson  <beidson@apple.com>

        IDB: Date objects don't work as keys or values.
        https://bugs.webkit.org/show_bug.cgi?id=150743

        Reviewed by Darin Adler.

        Test: storage/indexeddb/modern/date-basic.html

        The combination of the autogenerated bindings with Deprecated::ScriptValue was
        losing the fidelity of "Date" objects being Dates, and not just normal Objects.
        
        This was breaking their usage as IDBKeys.
        
        Custom binding + reworking the IDBObjectStore IDLs to use JSValue instead of ScriptValue
        fixes this handily.
        
        * Modules/indexeddb/IDBObjectStore.h:
        * Modules/indexeddb/IDBObjectStore.idl:
        
        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::add):
        (WebCore::IDBClient::IDBObjectStore::put):
        (WebCore::IDBClient::IDBObjectStore::putOrAdd):
        * Modules/indexeddb/client/IDBObjectStoreImpl.h:
        
        * Modules/indexeddb/legacy/LegacyObjectStore.cpp:
        (WebCore::LegacyObjectStore::add):
        (WebCore::LegacyObjectStore::put):
        * Modules/indexeddb/legacy/LegacyObjectStore.h:
        
        * bindings/js/IDBBindingUtilities.cpp:
        (WebCore::internalCreateIDBKeyFromScriptValueAndKeyPath):
        (WebCore::maybeCreateIDBKeyFromScriptValueAndKeyPath):
        (WebCore::canInjectIDBKeyIntoScriptValue):
        (WebCore::scriptValueToIDBKey):
        * bindings/js/IDBBindingUtilities.h:

        * bindings/js/JSIDBObjectStoreCustom.cpp:
        (WebCore::putOrAdd):
        (WebCore::JSIDBObjectStore::putRecord):
        (WebCore::JSIDBObjectStore::add):

2015-10-31  Andreas Kling  <akling@apple.com>

        Add a debug overlay with information about web process resource usage.
        <https://webkit.org/b/150599>

        Reviewed by Darin Adler.

        A new kind of PageOverlay is added behind the ENABLE(RESOURCE_USAGE_OVERLAY) flag.
        It's owned by Page, but not instantiated unless the Settings::resourceUsageOverlayVisible flag is set.

        All ResourceUsageOverlay objects share a single sampler thread. The thread currently runs every 500ms
        and samples CPU usage, dirty memory regions, and GC heap size/capacity.

        Most things in here are currently quite Mac-specific, but I will be iterating on this towards a more
        cross-platform friendly solution.

        There are two small changes to PageOverlay in order to support dragging the resource usage overlay:

            - A "should ignore mouse events outside bounds" state flag. This is on by default
              but turned off during a drag.
            - PageOverlay::bounds() will now return the override frame verbatim if one is set,
              instead of returning it relocated to 0,0.

        Note that this is intended as a tool for WebKit engine developers to better understand memory usage.
        It's not a goal to expose this information to end users.

        * WebCore.xcodeproj/project.pbxproj:
        * page/Page.cpp:
        (WebCore::Page::setResourceUsageOverlayVisible):
        * page/Page.h:
        * page/PageOverlay.cpp:
        (WebCore::PageOverlay::bounds):
        (WebCore::PageOverlay::mouseEvent):
        * page/PageOverlay.h:
        * page/ResourceUsageOverlay.cpp: Added.
        (WebCore::ResourceUsageOverlay::ResourceUsageOverlay):
        (WebCore::ResourceUsageOverlay::~ResourceUsageOverlay):
        (WebCore::ResourceUsageOverlay::mouseEvent):
        * page/ResourceUsageOverlay.h: Added.
        * page/Settings.cpp:
        (WebCore::Settings::setResourceUsageOverlayVisible):
        * page/Settings.h:
        (WebCore::Settings::resourceUsageOverlayVisible):
        * page/cocoa/ResourceUsageOverlayCocoa.mm: Added.
        (-[WebOverlayLayer initWithResourceUsageOverlay:]):
        (-[WebOverlayLayer drawInContext:]):
        (WebCore::RingBuffer::RingBuffer):
        (WebCore::RingBuffer::append):
        (WebCore::RingBuffer::last):
        (WebCore::RingBuffer::forEach):
        (WebCore::RingBuffer::incrementIndex):
        (WebCore::RingBuffer::decrementIndex):
        (WebCore::sharedData):
        (WebCore::ResourceUsageOverlay::platformInitialize):
        (WebCore::ResourceUsageOverlay::platformDestroy):
        (WebCore::drawCpuHistory):
        (WebCore::drawGCHistory):
        (WebCore::drawSlice):
        (WebCore::drawPlate):
        (WebCore::drawMemoryPie):
        (WebCore::formatByteNumber):
        (WebCore::showText):
        (WebCore::ResourceUsageOverlay::draw):
        (WebCore::dirtyPagesPerVMTag):
        (WebCore::cpuUsage):
        (WebCore::runSamplerThread):
        * platform/spi/cocoa/MachVMSPI.h:

2015-10-31  Brady Eidson  <beidson@apple.com>

        storage/indexeddb/modern/idbdatabase-deleteobjectstore-failures.html is flaky.
        https://bugs.webkit.org/show_bug.cgi?id=150735

        Reviewed by Darin Adler.

        No new tests (Covered by existing tests).

        Transactions were liable to commit too early because IDBRequests could be waiting
        to dispatch their error/success events but their operations would no longer be
        registered with the transaction.
        
        Having outstanding requests should also keep a transaction from committing, just
        like having outstanding operations should.
        
        * Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBOpenDBRequest::onUpgradeNeeded):
        
        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::dispatchEvent):
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::addRequest):
        (WebCore::IDBClient::IDBTransaction::removeRequest):
        (WebCore::IDBClient::IDBTransaction::operationTimerFired):
        (WebCore::IDBClient::IDBTransaction::requestGetRecord):
        (WebCore::IDBClient::IDBTransaction::requestClearObjectStore):
        (WebCore::IDBClient::IDBTransaction::requestPutOrAdd):
        (WebCore::IDBClient::IDBTransaction::operationDidComplete):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        
        * Modules/indexeddb/client/TransactionOperation.h:
        (WebCore::IDBClient::TransactionOperation::completed):

2015-10-31  Philippe Normand  <pnormand@igalia.com>

        [GStreamer][Mac] Fix WebAudio build
        https://bugs.webkit.org/show_bug.cgi?id=150030

        Reviewed by Darin Adler.

        Wrap Accelerate.framework API calls around USE(ACCELERATE) ifdefs.

        * platform/audio/Biquad.cpp:
        (WebCore::Biquad::Biquad):
        (WebCore::Biquad::process):
        (WebCore::Biquad::reset):
        * platform/audio/Biquad.h:
        * platform/audio/DirectConvolver.cpp:
        (WebCore::DirectConvolver::process):
        * platform/audio/FFTFrame.h:
        * platform/audio/VectorMath.cpp:

2015-10-31  Brian Burg  <bburg@apple.com>

        Builtins generator should put WebCore-only wrappers in the per-builtin header
        https://bugs.webkit.org/show_bug.cgi?id=150539

        Reviewed by Youenn Fablet.

        Fix includes of removed XXXWrapper.h headers.

        * CMakeLists.txt:
        * DerivedSources.make:
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/WebCoreJSBuiltinInternals.h:
        * bindings/js/WebCoreJSBuiltins.h:

2015-10-31  Yusuke Suzuki  <utatane.tea@gmail.com>

        Add the support for Symbol attributes on IDL
        https://bugs.webkit.org/show_bug.cgi?id=150586

        Reviewed by Ryosuke Niwa.

        This patch addes readonly attribute support for Symbols.
        It involves the IDL generator functionality converting Native type (PrivateName) to Symbol.

        * bindings/scripts/CodeGeneratorGObject.pm:
        (SkipAttribute):
        (SkipFunction):
        * bindings/scripts/CodeGeneratorJS.pm:
        (NativeToJSValue):
        * bindings/scripts/CodeGeneratorObjC.pm:
        (SkipFunction):
        (SkipAttribute):
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::jsTestObjReadOnlySymbolAttr):
        (WebCore::jsTestObjConstructorStaticReadOnlySymbolAttr):
        * bindings/scripts/test/TestObj.idl:

2015-10-30  Brady Eidson  <beidson@apple.com>

        Modern IDB: Support IDBObjectStore.get() for IDBKeyRanges.
        https://bugs.webkit.org/show_bug.cgi?id=150718

        Reviewed by Alex Christensen.

        Test: storage/indexeddb/modern/get-keyrange.html

        * Modules/indexeddb/IDBKeyRangeData.cpp:
        (WebCore::IDBKeyRangeData::IDBKeyRangeData):
        * Modules/indexeddb/IDBKeyRangeData.h:
        
        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::getRecord):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:
        
        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::get):
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::requestGetRecord):
        (WebCore::IDBClient::IDBTransaction::getRecordOnServer):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        
        * Modules/indexeddb/server/IDBBackingStore.h:
        
        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::getRecord):
        * Modules/indexeddb/server/IDBServer.h:
        
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::recordValueChanged):
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::getRecord):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:
        
        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::deleteRecord):
        (WebCore::IDBServer::MemoryObjectStore::setKeyValue):
        (WebCore::IDBServer::MemoryObjectStore::valueForKeyRange): Using a std::set, find the appropriate
          key in the range, and return the value if one exists.
        (WebCore::IDBServer::MemoryObjectStore::valueForKey): Deleted.
        * Modules/indexeddb/server/MemoryObjectStore.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::getRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::performGetRecord):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::getRecord):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
        
        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::getRecord):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

2015-10-30  Brady Eidson  <beidson@apple.com>

        Modern IDB: IDBObjectStore.clear() support.
        https://bugs.webkit.org/show_bug.cgi?id=150733

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/idbobjectstore-clear-1.html
               storage/indexeddb/modern/idbobjectstore-clear-2.html

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::clearObjectStore):
        (WebCore::IDBClient::IDBConnectionToServer::didClearObjectStore):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:
        
        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::clear):
        
        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::setResultToUndefined):
        * Modules/indexeddb/client/IDBRequestImpl.h:
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::requestClearObjectStore):
        (WebCore::IDBClient::IDBTransaction::clearObjectStoreOnServer):
        (WebCore::IDBClient::IDBTransaction::didClearObjectStoreOnServer):
        * Modules/indexeddb/client/IDBTransactionImpl.h:

        * Modules/indexeddb/server/IDBBackingStore.h:

        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didClearObjectStore):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:

        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::clearObjectStore):
        * Modules/indexeddb/server/IDBServer.h:

        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::objectStoreCleared):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::recordValueChanged):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::isAborting):

        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::clearObjectStore):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:

        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::clear):
        (WebCore::IDBServer::MemoryObjectStore::replaceKeyValueStore):
        * Modules/indexeddb/server/MemoryObjectStore.h:

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::clearObjectStore):
        (WebCore::IDBServer::UniqueIDBDatabase::performClearObjectStore):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformClearObjectStore):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::didClearObjectStore):
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::clearObjectStore):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:

        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::clearObjectStoreSuccess):
        * Modules/indexeddb/shared/IDBResultData.h:

        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didClearObjectStore):
        (WebCore::InProcessIDBServer::clearObjectStore):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

2015-10-30  Joseph Pecoraro  <pecoraro@apple.com>

        CSSParserVariable leaks seen on leaks bots
        https://bugs.webkit.org/show_bug.cgi?id=150724

        Reviewed by Darin Adler.

        * css/CSSParserValues.cpp:
        (WebCore::destroy):
        Cleanup variable CSSParserValues.

2015-10-30  Alex Christensen  <achristensen@webkit.org>

        Fix Windows build.

        * PlatformWin.cmake:
        Add missing files.

2015-10-30  Beth Dakin  <bdakin@apple.com>

        Tapping and holding a link should have a share option
        https://bugs.webkit.org/show_bug.cgi?id=150693
        -and corresponding-
        rdar://problem/21319702

        Reviewed by Tim Horton.

        * English.lproj/Localizable.strings:

2015-10-30  Joseph Pecoraro  <pecoraro@apple.com>

        Minor CGColor leaks seen on bots allocated in WebSystemBackdropLayer.mm
        https://bugs.webkit.org/show_bug.cgi?id=150722

        Reviewed by Andreas Kling.

        * platform/graphics/ca/cocoa/WebSystemBackdropLayer.mm:
        (-[WebLightSystemBackdropLayer init]):
        (-[WebDarkSystemBackdropLayer init]):

2015-10-30  Csaba Osztrogonác  <ossy@webkit.org>

        [EFL] Fix the debug build after r191758
        https://bugs.webkit.org/show_bug.cgi?id=150719

        Reviewed by Alex Christensen.

        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::createObjectStore):

2015-10-30  Dan Bernstein  <mitz@apple.com>

        Fixed the build.

        * platform/graphics/Image.cpp:
        (WebCore::Image::draw): Deleted an infinitely-recursive implementation that caused the
          compiler to emit an error.
        * platform/graphics/Image.h:
        (WebCore::Image::draw): Made this pure virtual.

2015-10-30  Brady Eidson  <beidson@apple.com>

        Modern IDB: IDBObjectStore.add() support.
        https://bugs.webkit.org/show_bug.cgi?id=150711

        Reviewed by Alex Christensen.

        Test: storage/indexeddb/modern/basic-add.html

        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::add):

        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::requestGetRecord):

2015-10-30  Hunseop Jeong  <hs85.jeong@samsung.com>

        Use modern for-loops in WebCore/dom.
        https://bugs.webkit.org/show_bug.cgi?id=150664

        Reviewed by Darin Adler.

        No new tests because there is no behavior change.

        * dom/AuthorStyleSheets.cpp:
        (WebCore::AuthorStyleSheets::analyzeStyleSheetChange):
        (WebCore::filterEnabledNonemptyCSSStyleSheets):
        (WebCore::AuthorStyleSheets::activeStyleSheetsContains):
        * dom/CheckedRadioButtons.cpp:
        (WebCore::RadioButtonGroup::updateValidityForAllButtons):
        * dom/ClientRectList.cpp:
        (WebCore::ClientRectList::ClientRectList):
        (WebCore::ClientRectList::~ClientRectList):
        * dom/ContainerNode.cpp:
        (WebCore::ContainerNode::insertBefore):
        * dom/DOMNamedFlowCollection.cpp:
        (WebCore::DOMNamedFlowCollection::DOMNamedFlowCollection):
        (WebCore::DOMNamedFlowCollection::length):
        (WebCore::DOMNamedFlowCollection::item):
        (WebCore::DOMNamedFlowCollection::namedItem):
        * dom/DOMStringList.cpp:
        (WebCore::DOMStringList::contains):
        * dom/Document.cpp:
        (WebCore::Document::Document):
        (WebCore::Document::~Document):
        (WebCore::Document::removedLastRef):
        (WebCore::Document::adjustFloatQuadsForScrollAndAbsoluteZoomAndFrameScale):
        (WebCore::Document::updateHoverActiveState):
        * dom/DocumentMarkerController.cpp:
        (WebCore::DocumentMarkerController::copyMarkers):
        (WebCore::DocumentMarkerController::removeMarkers):
        (WebCore::DocumentMarkerController::repaintMarkers):
        (DocumentMarkerController::showMarkers):
        * dom/ElementData.cpp:
        (WebCore::UniqueElementData::findAttributeByName):
        * dom/EventDispatcher.cpp:
        (WebCore::EventPath::updateTouchLists):
        (WebCore::EventPath::hasEventListeners):
        * dom/EventListenerMap.cpp:
        (WebCore::EventListenerMap::contains):
        (WebCore::EventListenerMap::containsCapturing):
        (WebCore::EventListenerMap::eventTypes):
        (WebCore::EventListenerMap::add):
        (WebCore::EventListenerMap::find):
        (WebCore::copyListenersNotCreatedFromMarkupToTarget):
        (WebCore::EventListenerMap::copyEventListenersNotCreatedFromMarkupToTarget):
        (WebCore::EventListenerIterator::EventListenerIterator):
        * dom/EventTarget.cpp:
        (WebCore::EventTarget::removeEventListener):
        (WebCore::EventTarget::getAttributeEventListener):
        (WebCore::EventTarget::removeAllEventListeners):
        * dom/IdTargetObserverRegistry.cpp:
        (WebCore::IdTargetObserverRegistry::notifyObserversInternal):
        * dom/MessagePort.cpp:
        (WebCore::MessagePort::postMessage):
        (WebCore::MessagePort::disentanglePorts):
        * dom/MutationObserver.cpp:
        (WebCore::MutationObserver::observe):
        (WebCore::MutationObserver::deliver):
        (WebCore::MutationObserver::deliverAllMutations):
        * dom/NamedFlowCollection.cpp:
        (WebCore::NamedFlowCollection::namedFlows):
        (WebCore::NamedFlowCollection::createCSSOMSnapshot):
        * dom/Node.cpp:
        (WebCore::Node::notifyMutationObserversNodeWillDetach):
        * dom/Range.cpp:
        (WebCore::Range::processNodes):
        (WebCore::Range::processAncestorsAndTheirSiblings):
        (WebCore::Range::absoluteBoundingBox):
        (WebCore::Range::collectSelectionRects):
        * dom/ScriptRunner.cpp:
        (WebCore::ScriptRunner::timerFired):
        * dom/ScriptedAnimationController.cpp:
        (WebCore::ScriptedAnimationController::serviceScriptedAnimations):
        * dom/SelectorQuery.cpp:
        (WebCore::SelectorDataList::matches):
        (WebCore::SelectorDataList::executeFastPathForIdSelector):
        (WebCore::SelectorDataList::executeSingleMultiSelectorData):
        (WebCore::SelectorDataList::executeCompiledSingleMultiSelectorData):
        (WebCore::SelectorDataList::execute):
        * dom/TreeScopeAdopter.cpp:
        (WebCore::TreeScopeAdopter::moveTreeToNewScope):

2015-10-30  Carlos Garcia Campos  <cgarcia@igalia.com>

        Make every port implement MainThreadSharedTimer instead of using global functions
        https://bugs.webkit.org/show_bug.cgi?id=150498

        Reviewed by Darin Adler.

        Move MainThreadSharedTimer to its own files and add the common
        implementation there.

        * CMakeLists.txt: Add MainThreadSharedTimer.cpp.
        * PlatformEfl.cmake: Update filenames.
        * PlatformGTK.cmake: Ditto.
        * PlatformMac.cmake: Ditto.
        * PlatformWin.cmake: Ditto.
        * platform/MainThreadSharedTimer.cpp: Copied from Source/WebCore/platform/efl/SharedTimerEfl.cpp.
        (WebCore::MainThreadSharedTimer::singleton):
        (WebCore::MainThreadSharedTimer::MainThreadSharedTimer):
        (WebCore::MainThreadSharedTimer::setFiredFunction):
        (WebCore::MainThreadSharedTimer::fired):
        * platform/MainThreadSharedTimer.h: Copied from Source/WebCore/platform/gtk/SharedTimerGtk.cpp.
        * platform/SharedTimer.h: Remove MainThreadSharedTimer
        implementation and reindent the code.
        (WebCore::SharedTimer::SharedTimer):
        (WebCore::SharedTimer::~SharedTimer):
        (WebCore::SharedTimer::invalidate):
        * platform/ThreadTimers.cpp:
        (WebCore::ThreadTimers::ThreadTimers): Use MainThreadSharedTimer::singleton().
        (WebCore::ThreadTimers::setSharedTimer): Use a lambda function
        instead of a pointer to a static method.
        (WebCore::ThreadTimers::sharedTimerFired): Deleted.
        * platform/ThreadTimers.h: Removed unsused static method sharedTimerFired.
        * platform/cf/MainThreadSharedTimerCF.cpp: Renamed from Source/WebCore/platform/cf/SharedTimerCF.cpp.
        (WebCore::applicationDidBecomeActive):
        (WebCore::setupPowerObserver):
        (WebCore::timerFired):
        (WebCore::restartSharedTimer):
        (WebCore::MainThreadSharedTimer::invalidate):
        (WebCore::MainThreadSharedTimer::setFireInterval):
        (WebCore::MainThreadSharedTimer::stop):
        * platform/efl/MainThreadSharedTimerEfl.cpp: Renamed from Source/WebCore/platform/efl/SharedTimerEfl.cpp.
        (WebCore::timerEvent):
        (WebCore::MainThreadSharedTimer::stop):
        (WebCore::MainThreadSharedTimer::setFireInterval):
        (WebCore::MainThreadSharedTimer::invalidate):
        * platform/gtk/MainThreadSharedTimerGtk.cpp: Renamed from Source/WebCore/platform/gtk/SharedTimerGtk.cpp.
        (WebCore::MainThreadSharedTimer::setFireInterval):
        (WebCore::MainThreadSharedTimer::stop):
        (WebCore::MainThreadSharedTimer::invalidate):
        * platform/win/MainThreadSharedTimerWin.cpp: Renamed from Source/WebCore/platform/win/SharedTimerWin.cpp.
        (WebCore::TimerWindowWndProc):
        (WebCore::initializeOffScreenTimerWindow):
        (WebCore::queueTimerProc):
        (WebCore::MainThreadSharedTimer::setFireInterval):
        (WebCore::MainThreadSharedTimer::stop):
        (WebCore::MainThreadSharedTimer::invalidate):
        * workers/WorkerRunLoop.cpp: Update WorkerSharedTimer
        implementation to use std::function instead of a pointer. Also
        mark the class as final and the virtual implementations as override.

2015-10-30  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GTK] Use RunLoop::Timer instead of GMainLoopSource
        https://bugs.webkit.org/show_bug.cgi?id=150592

        Reviewed by Žan Doberšek.

        * platform/network/ResourceHandle.h:
        * platform/network/ResourceHandleInternal.h:
        (WebCore::ResourceHandleInternal::ResourceHandleInternal):
        * platform/network/soup/ResourceHandleSoup.cpp:
        (WebCore::cleanupSoupRequestOperation):
        (WebCore::ResourceHandle::timeoutFired):
        (WebCore::ResourceHandle::sendPendingRequest):
        (WebCore::ResourceHandle::platformSetDefersLoading):

2015-10-30  Hunseop Jeong  <hs85.jeong@samsung.com>

        REGRESSION(r191776): EFL build broken.
        https://bugs.webkit.org/show_bug.cgi?id=150713

        Reviewed by Csaba Osztrogonác.

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::performPutOrAdd):

2015-10-29  Brady Eidson  <beidson@apple.com>

        Modern IDB: autoIncrement support.
        https://bugs.webkit.org/show_bug.cgi?id=150695

        Reviewed by Alex Christensen.

        Test: storage/indexeddb/modern/autoincrement-abort.html

        * Modules/indexeddb/server/IDBBackingStore.h:
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::addNewObjectStore):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::addExistingObjectStore):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::putRecord):
        (WebCore::IDBServer::MemoryIDBBackingStore::generateKeyNumber):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:
        * Modules/indexeddb/server/MemoryObjectStore.h:
        (WebCore::IDBServer::MemoryObjectStore::currentKeyGeneratorValue):
        (WebCore::IDBServer::MemoryObjectStore::setKeyGeneratorValue):
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::performPutOrAdd):

2015-10-29  Alex Christensen  <achristensen@webkit.org>

        Make WebCore a framework in Mac CMake build
        https://bugs.webkit.org/show_bug.cgi?id=150702

        Reviewed by Geoffrey Garen.

        * CMakeLists.txt:
        * PlatformEfl.cmake:
        * PlatformGTK.cmake:
        * PlatformMac.cmake:

2015-10-29  Alex Christensen  <achristensen@webkit.org>

        CMake build fix.

        * editing/mac/EditorMac.mm:
        (WebCore::Editor::WebContentReader::readFilenames):
        Before r191553, text was a local variable and could be changed.
        This restores the same behavior and compiles correctly when ATTACHMENT_ELEMENT is disabled.
        * platform/mac/CursorMac.mm:
        (WebCore::Cursor::Cursor):
        (WebCore::Cursor::operator=):
        Added preprocessor macros.

2015-10-29  Brady Eidson  <beidson@apple.com>

        Modern IDB: deleteObjectStore support.
        https://bugs.webkit.org/show_bug.cgi?id=150673

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/deleteobjectstore-1.html
               storage/indexeddb/modern/idbdatabase-deleteobjectstore-failures.html
               storage/indexeddb/modern/idbobjectstore-get-failures.html

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::deleteObjectStore):
        (WebCore::IDBClient::IDBConnectionToServer::didDeleteObjectStore):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::deleteObjectStore):
        (WebCore::IDBClient::IDBDatabase::willCommitTransaction):
        (WebCore::IDBClient::IDBDatabase::willAbortTransaction):
        (WebCore::IDBClient::IDBDatabase::commitTransaction): Deleted.
        (WebCore::IDBClient::IDBDatabase::abortTransaction): Deleted.
        * Modules/indexeddb/client/IDBDatabaseImpl.h:

        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::markAsDeleted):
        * Modules/indexeddb/client/IDBObjectStoreImpl.h:

        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::IDBTransaction):
        (WebCore::IDBClient::IDBTransaction::abort):
        (WebCore::IDBClient::IDBTransaction::abortOnServer):
        (WebCore::IDBClient::IDBTransaction::commit):
        (WebCore::IDBClient::IDBTransaction::commitOnServer):
        (WebCore::IDBClient::IDBTransaction::deleteObjectStore):
        (WebCore::IDBClient::IDBTransaction::deleteObjectStoreOnServer):
        (WebCore::IDBClient::IDBTransaction::didDeleteObjectStoreOnServer):
        (WebCore::IDBClient::IDBTransaction::activate):
        (WebCore::IDBClient::IDBTransaction::activationTimerFired): Deleted.
        (WebCore::IDBClient::IDBTransaction::createObjectStoreOnServer): Deleted.
        (WebCore::IDBClient::IDBTransaction::didCreateObjectStoreOnServer): Deleted.
        (WebCore::IDBClient::IDBTransaction::getRecordOnServer): Deleted.
        (WebCore::IDBClient::IDBTransaction::putOrAddOnServer): Deleted.
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        
        * Modules/indexeddb/client/TransactionOperation.h:
        (WebCore::IDBClient::TransactionOperation::completed):
        (WebCore::IDBClient::createTransactionOperation):
        
        * Modules/indexeddb/server/IDBBackingStore.h:
        
        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didDeleteObjectStore):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:
        
        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::deleteObjectStore):
        * Modules/indexeddb/server/IDBServer.h:
        
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::objectStoreDeleted):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::finish):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::createObjectStore):
        (WebCore::IDBServer::MemoryIDBBackingStore::deleteObjectStore):
        (WebCore::IDBServer::MemoryIDBBackingStore::restoreObjectStoreForVersionChangeAbort):
        (WebCore::IDBServer::MemoryIDBBackingStore::takeObjectStoreByName):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::performCreateObjectStore):
        (WebCore::IDBServer::UniqueIDBDatabase::deleteObjectStore):
        (WebCore::IDBServer::UniqueIDBDatabase::performDeleteObjectStore):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformDeleteObjectStore):
        (WebCore::IDBServer::UniqueIDBDatabase::createObjectStore): Deleted.
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::didDeleteObjectStore):
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::deleteObjectStore):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
        
        * Modules/indexeddb/shared/IDBDatabaseInfo.cpp:
        (WebCore::IDBDatabaseInfo::deleteObjectStore):
        * Modules/indexeddb/shared/IDBDatabaseInfo.h:
        
        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::deleteObjectStoreSuccess):
        * Modules/indexeddb/shared/IDBResultData.h:
        
        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didDeleteObjectStore):
        (WebCore::InProcessIDBServer::deleteObjectStore):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

2015-10-29  Simon Fraser  <simon.fraser@apple.com>

        Very slow typing on pages with wheel event handlers on the body, and deep content
        https://bugs.webkit.org/show_bug.cgi?id=150692
        rdar://problem/23242631

        Reviewed by Zalan Bujtas.
        
        On a large page with a wheel event handler on the body, we would call
        Element::absoluteEventHandlerBounds() for every element under the body,
        and compute an absolute bounds for each one. This is very slow.
        
        For now, optimize computing a region for the <body> by just using the document
        bounds, which will always be as big or larger. It's OK for this region to
        be an overestimate.

        * dom/Document.cpp:
        (WebCore::Document::absoluteRegionForEventTargets):

2015-10-29  Wenson Hsieh  <wenson_hsieh@apple.com>

        Date input values should not overlap with menu list dropdown button on iOS
        https://bugs.webkit.org/show_bug.cgi?id=150681
        <rdar://problem/19965078>

        Reviewed by Zalan Bujtas.

        Adds a right margin on iOS date and time inputs so that the inner div does
        not render the value of the date on top of the dropdown button on the right
        of the menu list.

        Tests: fast/forms/date/date-input-rendering-basic.html
               fast/forms/time/time-input-rendering-basic.html

        * css/html.css:
        (input::-webkit-date-and-time-value):

2015-10-29  Alex Christensen  <achristensen@webkit.org>

        Fix Mac CMake build
        https://bugs.webkit.org/show_bug.cgi?id=150686

        Reviewed by Filip Pizlo.

        * PlatformMac.cmake:

2015-10-29  Csaba Osztrogonác  <ossy@webkit.org>

        One more URTBF after r191731.

        * rendering/svg/RenderSVGResourcePattern.cpp:

2015-10-29  Csaba Osztrogonác  <ossy@webkit.org>

        URTBF after r191731.

        * rendering/svg/RenderSVGResourcePattern.cpp:

2015-10-29  Zalan Bujtas  <zalan@apple.com>

        Fix ENABLE(TREE_DEBUGGING) release build.

        Unreviewed build fix.

        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
        * dom/Position.cpp:

2015-10-29  Beth Dakin  <bdakin@apple.com>

        Overlay scrollbars disappear during manual drag-scroll
        https://bugs.webkit.org/show_bug.cgi?id=150646
        -and corresponding-
        rdar://problem/23145734

        Reviewed by Tim Horton.

        New ScrollAnimator function so that we can tell the ScrollbarPainter whether 
        or not the mouse is tracking the scrollbar.
        * platform/ScrollAnimator.h:
        (WebCore::ScrollAnimator::ScrollAnimator::mouseIsDownInScrollbar):
        * platform/ScrollableArea.cpp:
        (WebCore::ScrollableArea::mouseIsDownInScrollbar):
        * platform/ScrollableArea.h:

        Call into the new ScrollAnimator function of mouseDown and mouseUp.
        * platform/Scrollbar.cpp:
        (WebCore::Scrollbar::mouseUp):
        (WebCore::Scrollbar::mouseDown):

        Add setTracking to the ScrollbarPainter.
        * platform/mac/NSScrollerImpDetails.h:

        Implement mouseIsDownInScrollbar to call setTracking appropriately and to set 
        begin/endScrollGesture since drag scrolling does not normally trigger that 
        state change.
        * platform/mac/ScrollAnimatorMac.h:
        * platform/mac/ScrollAnimatorMac.mm:
        (WebCore::ScrollAnimatorMac::mouseIsDownInScrollbar):

2015-10-29  Eric Carlson  <eric.carlson@apple.com>

        MediaPlayer::getSupportedTypes only returns types from the last engine registered
        https://bugs.webkit.org/show_bug.cgi?id=150669

        Reviewed by Jer Noble.

        No new tests, fixes existing tests.

        * platform/graphics/MediaPlayer.cpp:
        (WebCore::MediaPlayer::getSupportedTypes):
        (WebCore::MediaPlayer::isAvailable):

2015-10-29  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Clean up and audit TimelineRecordFactory records
        https://bugs.webkit.org/show_bug.cgi?id=150660

        Reviewed by Brian Burg.

        Cleanup included removing unused methods and payload data that the
        frontend wasn't likely to use. Also added ASCIILiteral and removed
        unnecessary includes.

        * inspector/InspectorNetworkAgent.cpp:
        * inspector/InspectorPageAgent.cpp:
        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::InspectorTimelineAgent::willLayout):
        * inspector/InspectorTimelineAgent.h:
        * inspector/TimelineRecordFactory.cpp:
        (WebCore::TimelineRecordFactory::createGenericRecord):
        (WebCore::TimelineRecordFactory::createFunctionCallData):
        (WebCore::TimelineRecordFactory::createConsoleProfileData):
        (WebCore::TimelineRecordFactory::createEventDispatchData):
        (WebCore::TimelineRecordFactory::createGenericTimerData):
        (WebCore::TimelineRecordFactory::createTimerInstallData):
        (WebCore::TimelineRecordFactory::createEvaluateScriptData):
        (WebCore::TimelineRecordFactory::createTimeStampData):
        (WebCore::TimelineRecordFactory::createParseHTMLData):
        (WebCore::TimelineRecordFactory::createAnimationFrameData):
        (WebCore::TimelineRecordFactory::createPaintData):
        (WebCore::TimelineRecordFactory::appendLayoutRoot):
        (WebCore::TimelineRecordFactory::createBackgroundRecord): Deleted.
        (WebCore::TimelineRecordFactory::createLayoutData): Deleted.
        * inspector/TimelineRecordFactory.h:
        (WebCore::TimelineRecordFactory::TimelineRecordFactory):

2015-10-29  Said Abou-Hallawa  <sabouhallawa@apple.com>

        Exploitable crash happens when an SVG contains an indirect resource inheritance cycle
        https://bugs.webkit.org/show_bug.cgi?id=150203

        Reviewed by Brent Fulgham.

        Detecting cycles in SVG resource references happens in two places.
        1. In SVGResourcesCycleSolver::resolveCycles() which it is called from 
           SVGResourcesCache::addResourcesFromRenderer(). When a cycle is deleted,
           SVGResourcesCycleSolver::breakCycle() is called to break the link. In
           the case of a cyclic resource inheritance, SVGResources::resetLinkedResource()
           is called to break this cycle.
        2. SVGPatternElement::collectPatternAttributes() which is called from
           RenderSVGResourcePattern::buildPattern(). The purpose is to resolve
           the pattern attributes and to build a tile image which can be used to
           fill the SVG element renderer. Detecting the cyclic resource reference
           in this function is not sufficient and can detect simple cycles like
            <pattern id="a" xlink:href="#b"/>
            <pattern id="b" xlink:href="#a"/>.
           But it does not detect cycles like:
            <pattern id="a">
                <rect fill="url(#b)"/>
            </pattern>
            <pattern id="b" xlink:href="#a"/>.
   
        The fix is to get rid of SVGPatternElement::collectPatternAttributes() which
        uses SVGURIReference::targetElementFromIRIString() to navigates through the
        referenced resource elements and tries to detect cycles. Instead we can
        implement RenderSVGResourcePattern::collectPatternAttributes() which calls
        SVGResourcesCache::cachedResourcesForRenderer() to get the SVGResources
        of the pattern. Then we use SVGResources::linkedResource() to navigate the
        resource inheritance tree. The cached SVGResources is guaranteed to be free
        of cycles.

        Tests: svg/custom/pattern-content-inheritance-cycle.svg

        * rendering/svg/RenderSVGResourcePattern.cpp:
        (WebCore::RenderSVGResourcePattern::collectPatternAttributes):
        Collect the pattern attributes through the cachedResourcesForRenderer().
        
        (WebCore::RenderSVGResourcePattern::buildPattern):
        Direct the call to the renderer function.
        
        * rendering/svg/RenderSVGResourcePattern.h:
        
        * rendering/svg/RenderSVGRoot.cpp:
        (WebCore::RenderSVGRoot::layout):
        RenderSVGRoot needs to call SVGResourcesCache::clientStyleChanged() for all
        the invalidated resources. If an attribute of an SVG resource was updated
        dynamically, the cached SVGResources associated with the renderer of this
        resource was stale.
        
        * rendering/svg/SVGRenderTreeAsText.cpp:
        (WebCore::writeSVGResourceContainer):
        Direct the call to the renderer function.        
        
        * svg/SVGPatternElement.cpp:
        (WebCore::SVGPatternElement::collectPatternAttributes):
        (WebCore::setPatternAttributes): Deleted.
        collectPatternAttributes() is a replacement of setPatternAttributes().
        
2015-10-29  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Turn WS states into integers and fix state initialization
        https://bugs.webkit.org/show_bug.cgi?id=150667

        Reviewed by Youenn Fablet.

        The goal of this patch is turning the writable stream states into integers instead of strings.

        First readable stream states were reworked to be shared with writable stream too, they are now just @stream*.

        Next step was having writable stream using integers instead of strings and translating those integers back to
        strings to be able to return them correctly with the writable stream state attribute.

        The state initialization was fixed and now it is not needed to check for the state to be undefined.

        Rework, no new tests needed.

        * Modules/streams/ReadableStream.js:
        (initializeReadableStream):
        * Modules/streams/ReadableStreamController.js:
        (enqueue):
        (error):
        (close):
        * Modules/streams/ReadableStreamInternals.js:
        (privateInitializeReadableStreamReader):
        (errorReadableStream):
        (cancelReadableStream):
        (finishClosingReadableStream):
        (closeReadableStream):
        (closeReadableStreamReader):
        (enqueueInReadableStream):
        (readFromReadableStreamReader):
        * Modules/streams/ReadableStreamReader.js:
        (cancel):
        * Modules/streams/WritableStream.js:
        (initializeWritableStream):
        (abort):
        (close):
        (write):
        (state):
        * Modules/streams/WritableStreamInternals.js:
        (syncWritableStreamStateWithQueue):
        (errorWritableStream):
        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::JSDOMWindowBase::finishCreation):
        * bindings/js/WebCoreBuiltinNames.h:

2015-10-28  Brady Eidson  <beidson@apple.com>

        Modern IDB: Support IDBDatabase.transaction() (and transaction scheduling in general).
        https://bugs.webkit.org/show_bug.cgi?id=150614

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/idbdatabase-transaction-failures.html
               storage/indexeddb/modern/transaction-scheduler-1.html
               storage/indexeddb/modern/transaction-scheduler-2.html
               storage/indexeddb/modern/transaction-scheduler-3.html
               storage/indexeddb/modern/transaction-scheduler-4.html
               storage/indexeddb/modern/transaction-scheduler-5.html
               storage/indexeddb/modern/transaction-scheduler-6.html

        * Modules/indexeddb/IDBDatabase.idl:

        * Modules/indexeddb/IndexedDB.h:

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::establishTransaction):
        (WebCore::IDBClient::IDBConnectionToServer::didStartTransaction):
        (WebCore::IDBClient::IDBConnectionToServer::hasRecordOfTransaction):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::transaction):
        (WebCore::IDBClient::IDBDatabase::didStartTransaction):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:

        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::IDBTransaction):
        (WebCore::IDBClient::IDBTransaction::operationTimerFired):
        (WebCore::IDBClient::IDBTransaction::didStart):
        (WebCore::IDBClient::IDBTransaction::establishOnServer):
        (WebCore::IDBClient::IDBTransaction::activate):
        (WebCore::IDBClient::IDBTransaction::deactivate):
        * Modules/indexeddb/client/IDBTransactionImpl.h:

        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didStartTransaction):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:

        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::establishTransaction):
        * Modules/indexeddb/server/IDBServer.h:

        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::beginTransaction):
        (WebCore::IDBServer::MemoryIDBBackingStore::createObjectStore):
        (WebCore::IDBServer::MemoryIDBBackingStore::removeObjectStoreForVersionChangeAbort):
        (WebCore::IDBServer::MemoryIDBBackingStore::keyExistsInObjectStore):
        (WebCore::IDBServer::MemoryIDBBackingStore::deleteRecord):
        (WebCore::IDBServer::MemoryIDBBackingStore::putRecord):
        (WebCore::IDBServer::MemoryIDBBackingStore::getRecord):
        (WebCore::IDBServer::MemoryIDBBackingStore::registerObjectStore):
        (WebCore::IDBServer::MemoryIDBBackingStore::unregisterObjectStore):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::startVersionChangeTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::performCommitTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformCommitTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformAbortTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::enqueueTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::transactionSchedulingTimerFired):
        (WebCore::IDBServer::UniqueIDBDatabase::activateTransactionInBackingStore):
        (WebCore::IDBServer::UniqueIDBDatabase::performActivateTransactionInBackingStore):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformActivateTransactionInBackingStore):
        (WebCore::IDBServer::scopesOverlap):
        (WebCore::IDBServer::UniqueIDBDatabase::takeNextRunnableTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::inProgressTransactionCompleted):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::establishTransaction):
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::create):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::UniqueIDBDatabaseTransaction):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::objectStoreIdentifiers):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::didActivateInBackingStore):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
        
        * Modules/indexeddb/shared/IDBTransactionInfo.cpp:
        (WebCore::IDBTransactionInfo::clientTransaction):
        (WebCore::IDBTransactionInfo::isolatedCopy):
        * Modules/indexeddb/shared/IDBTransactionInfo.h:
        
        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::establishTransaction):
        (WebCore::InProcessIDBServer::didStartTransaction):
        * Modules/indexeddb/shared/InProcessIDBServer.h:
        
        * bindings/js/IDBBindingUtilities.cpp:
        (WebCore::deserializeIDBValueData):
        
        * bindings/js/JSIDBDatabaseCustom.cpp:
        (WebCore::JSIDBDatabase::transaction):
        
        * bindings/js/ScriptState.cpp:
        (WebCore::execStateFromPage):

2015-10-28  Eric Carlson  <eric.carlson@apple.com>

        [MediaStream] Play MediaStream through media element and rendered to canvas
        https://bugs.webkit.org/show_bug.cgi?id=150449

        Reviewed by Jer Noble.

        * Modules/mediastream/MediaStream.cpp:
        (WebCore::MediaStream::create): Don't die a recursive death.
        (WebCore::MediaStream::MediaStream): setClient -> addObserver. Set private stream's public stream pointer.
        (WebCore::MediaStream::~MediaStream): setClient -> addObserver. Clear private stream's public stream pointer.
        (WebCore::MediaStream::didAddTrack): Short circuit calling internalAddTrack when the track is unknown.
        (WebCore::MediaStream::didRemoveTrack): ASSERT that the track is known.
        * Modules/mediastream/MediaStream.h:

        * Modules/mediastream/MediaStreamTrack.cpp:
        (WebCore::MediaStreamTrack::trackProducingDataChanged): New.
        (WebCore::MediaStreamTrack::trackEnabledChanged): New.
        * Modules/mediastream/MediaStreamTrack.h:

        * Modules/mediastream/RTCPeerConnection.cpp:
        (WebCore::RTCPeerConnection::didRemoveRemoteStream): Use the new MediaStreamPrivate::publicStream() method.

        * Modules/webaudio/MediaStreamAudioSource.cpp:
]        (WebCore::MediaStreamAudioSource::capabilities): capabilities isn't const.
        * Modules/webaudio/MediaStreamAudioSource.h:

        * Modules/webaudio/MediaStreamAudioSourceNode.cpp:
        (WebCore::MediaStreamAudioSourceNode::setFormat): Reformat to make it use early return.

        * WebCore.xcodeproj/project.pbxproj: Remove MediaStreamPrivateAVFObjC.mm/h, they are no longer necessary.

        * platform/graphics/MediaPlayer.cpp:
        (WebCore::buildMediaEnginesVector): Register MediaPlayerPrivateMediaStreamAVFObjC engine.

        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:
        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::MediaPlayerPrivateMediaStreamAVFObjC): Cleanup, add logging.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::~MediaPlayerPrivateMediaStreamAVFObjC): Add
          logging, remove private stream observer.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::registerMediaEngine): Cleanup.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::isAvailable): Ditto.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::getSupportedTypes): Return an empty vector.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::load): Use the MediaStreamPrivate passed instead
          of creating a new private stream. 
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::cancelLoad): Pause output.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::prepareToPlay): Add logging.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::platformLayer): m_previewLayer -> m_videoBackgroundLayer.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::setPausedImageVisible): New, show/hide the preview layer and configure
          the background layer so we show a still image even though the capture device continues to run. Start/stop clock.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::play): Don't need to start the source, that happens in in load. Just
          set flags and hide the paused image.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::pause): Don't stop the source, it may be shared by more than one 
          stream/track. Just set the playing flag and show the paused image.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::paused): Fix.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::internalSetVolume): New, called by setMuted and setVolume.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::setVolume): New.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::setMuted): Don't mute the source, it doesn't do what you think.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::hasVideo): Pass-through to stream.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::hasAudio): Ditto.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentMediaTime): Return clock time.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentReadyState): New.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::activeStatusChanged): Update readyState.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::updateIntrinsicSize): Update intrinsic size, create layers if necessary.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::createPreviewLayers): Create preview layers.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::characteristicsChanged): Update for changed characteristics.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::seekable): 'seekable' must return an empty TimeRanges object.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::paintCurrentFrameInContext): New.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::scheduleDeferredTask):
        (WebCore::mimeTypeCache): Deleted.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::platformMedia): Deleted.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::playInternal): Deleted.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::pauseInternal): Deleted.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::sizeChanged): Deleted.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::maxMediaTimeSeekable): Deleted.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::minMediaTimeSeekable): Deleted.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::createImageFromSampleBuffer): Deleted.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::supportsAcceleratedRendering): Deleted.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::movieLoadType): Deleted.
        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::extraMemoryCost): Deleted.

        Delete MediaStreamPrivateAVFObjC.mm/.h as they aren't necessary. 
        * platform/graphics/avfoundation/objc/MediaStreamPrivateAVFObjC.h: Removed.
        * platform/graphics/avfoundation/objc/MediaStreamPrivateAVFObjC.mm: Removed.

        * platform/mediastream/MediaStreamPrivate.cpp:
        (WebCore::MediaStreamPrivate::MediaStreamPrivate): Add track observer!
        (WebCore::MediaStreamPrivate::addObserver): New.
        (WebCore::MediaStreamPrivate::removeObserver): New.
        (WebCore::MediaStreamPrivate::updateActiveState): Remember the first active video track.
        (WebCore::MediaStreamPrivate::addTrack): Notify observers.
        (WebCore::MediaStreamPrivate::removeTrack): Ditto.
        (WebCore::MediaStreamPrivate::startProducingData): Pass-through to tracks.
        (WebCore::MediaStreamPrivate::stopProducingData): Ditto.
        (WebCore::MediaStreamPrivate::isProducingData): Ditto.
        (WebCore::MediaStreamPrivate::hasVideo): Ditto.
        (WebCore::MediaStreamPrivate::hasAudio): Ditto.
        (WebCore::MediaStreamPrivate::platformLayer): Ditto.
        (WebCore::MediaStreamPrivate::paintCurrentFrameInContext): Either pass-through to first active video
          track, or paint the context black.
        (WebCore::MediaStreamPrivate::currentFrameImage): Pass-through to first active video track.
        (WebCore::MediaStreamPrivate::characteristicsChanged): Inform observers.
        (WebCore::MediaStreamPrivate::trackMutedChanged):
        (WebCore::MediaStreamPrivate::trackStatesChanged):
        (WebCore::MediaStreamPrivate::trackEnabledChanged):
        (WebCore::MediaStreamPrivate::trackProducingDataChanged):
        (WebCore::MediaStreamPrivate::scheduleDeferredTask): New, call a function asynchronously on
          the main thread.
        * platform/mediastream/MediaStreamPrivate.h:

        * platform/mediastream/MediaStreamTrackPrivate.cpp:
        (WebCore::MediaStreamTrackPrivate::endTrack):
        (WebCore::MediaStreamTrackPrivate::sourceProducingDataChanged): New, inform observers.
        (WebCore::MediaStreamTrackPrivate::sourceEnabledChanged): Ditto.
        * platform/mediastream/MediaStreamTrackPrivate.h:

        * platform/mediastream/RealtimeMediaSource.cpp:
        (WebCore::RealtimeMediaSource::isProducingDataDidChange): New, inform observers.
        (WebCore::RealtimeMediaSource::setEnabled): Ditto.
        (WebCore::RealtimeMediaSource::stop): Call reset();
        * platform/mediastream/RealtimeMediaSource.h: Don't declare "capabilities" as const so 
          capabilities can be created and initialized lazily.

        * platform/mediastream/mac/AVAudioCaptureSource.h:
        * platform/mediastream/mac/AVAudioCaptureSource.mm:
        (WebCore::AVAudioCaptureSource::initializeCapabilities): New.
        (WebCore::AVAudioCaptureSource::addObserver): Hold the lock while calling observers so the list
          can't be mutated.
        (WebCore::AVAudioCaptureSource::setupCaptureSession): Log and fail if the session won't add the
          input or output.
        (WebCore::AVAudioCaptureSource::shutdownCaptureSession): Cleanup.
        (WebCore::AVAudioCaptureSource::captureOutputDidOutputSampleBufferFromConnection): Don't block
          if it isn't possible to acquire the lock. Hold the lock while calling observers.
        (WebCore::AVAudioCaptureSource::capabilities): Deleted.

        * platform/mediastream/mac/AVCaptureDeviceManager.mm:
        (WebCore::refreshCaptureDeviceList): Don't include devices that can't be used.
        (WebCore::AVCaptureDeviceManager::bestSourcesForTypeAndConstraints):  Use AVCaptureDeviceManager::sourceWithUID
          so constraints are considered.
        (WebCore::AVCaptureDeviceManager::sourceWithUID): Don't consider disabled devices. Always
          create a new capture device so each track starts out with a unique source.
        * platform/mediastream/mac/AVMediaCaptureSource.h:

        * platform/mediastream/mac/AVMediaCaptureSource.mm:
        (WebCore::globaAudioCaptureSerialQueue):
        (WebCore::AVMediaCaptureSource::AVMediaCaptureSource):
        (WebCore::AVMediaCaptureSource::~AVMediaCaptureSource): Remove KVO observers.
        (WebCore::AVMediaCaptureSource::startProducingData): m_isRunning is changed in captureSessionIsRunningDidChange.
        (WebCore::AVMediaCaptureSource::stopProducingData): Ditto.
        (WebCore::AVMediaCaptureSource::capabilities): New.
        (WebCore::AVMediaCaptureSource::setupSession): Add KVObservers for the properties we care about.
        (WebCore::AVMediaCaptureSource::reset): New, cleanup.
        (WebCore::AVMediaCaptureSource::captureSessionIsRunningDidChange): Dispatch to the main thread 
          to set m_isRunning, call isProducingDataDidChange so observers can find out.
        (WebCore::sessionKVOProperties):
        (-[WebCoreAVMediaCaptureSourceObserver disconnect]):
        (-[WebCoreAVMediaCaptureSourceObserver captureOutput:didOutputSampleBuffer:fromConnection:]):
        (-[WebCoreAVMediaCaptureSourceObserver observeValueForKeyPath:ofObject:change:context:]): Respond
          to running changes.
        (WebCore::AVMediaCaptureSource::captureSessionStoppedRunning): Deleted.
        (-[WebCoreAVMediaCaptureSourceObserver captureSessionStoppedRunning:]): Deleted.

        * platform/mediastream/mac/AVVideoCaptureSource.h:
        * platform/mediastream/mac/AVVideoCaptureSource.mm:
        (WebCore::AVVideoCaptureSource::initializeCapabilities): Partial implementation.
        (WebCore::AVVideoCaptureSource::setupCaptureSession):  Log and fail if the session won't add the
          input or output.
        (WebCore::AVVideoCaptureSource::shutdownCaptureSession): Cleanup.
        (WebCore::AVVideoCaptureSource::updateFramerate): Renamed from calculateFramerate.
        (WebCore::AVVideoCaptureSource::currentFrameImage): Return an Image.
        (WebCore::AVVideoCaptureSource::platformLayer): New.
        (WebCore::AVVideoCaptureSource::capabilities): Deleted.
        (WebCore::AVVideoCaptureSource::calculateFramerate): Deleted.

        * platform/mediastream/mac/WebAudioSourceProviderAVFObjC.h:
        * platform/mediastream/mac/WebAudioSourceProviderAVFObjC.mm:
        (WebCore::WebAudioSourceProviderAVFObjC::~WebAudioSourceProviderAVFObjC): AudioConverterRef is
          not a CF/ObjC object so we can't use a RetainPtr<> for it.
        (WebCore::WebAudioSourceProviderAVFObjC::provideInput): Ditto.
        (WebCore::WebAudioSourceProviderAVFObjC::prepare): Ditto.
        (WebCore::WebAudioSourceProviderAVFObjC::unprepare): Ditto.
        (WebCore::WebAudioSourceProviderAVFObjC::process): Fix typo in logging.

        * platform/mock/MockRealtimeMediaSourceCenter.cpp:
        (WebCore::MockSource::capabilities): Update for capabilities change.

        * platform/mediastream/openwebrtc/RealtimeMediaSourceOwr.h: Update for capabilities change.

2015-10-28  Chris Dumez  <cdumez@apple.com>

        Regression(r191673): [WIN][EFL][GTK] layout tests using data URLs time out
        https://bugs.webkit.org/show_bug.cgi?id=150661

        Reviewed by Gyuyoung Kim.

        Do a partial revert of r191673. For some reason, using a Timer in
        DataURLDecoder does not work (it does not fire). Since non COCOA ports
        don't support RunLoopTimer, this patch reintroduces the use of
        callOnMainThread() on non-COCOA ports.

        * platform/network/DataURLDecoder.cpp:
        (WebCore::DataURLDecoder::decode):
        (WebCore::DataURLDecoder::DecodingResultDispatcher::startTimer): Deleted.

2015-10-28  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Rename InspectorResourceAgent to InspectorNetworkAgent
        https://bugs.webkit.org/show_bug.cgi?id=150654

        Reviewed by Geoffrey Garen.

        * CMakeLists.txt:
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * WebCore.xcodeproj/project.pbxproj:
        * inspector/InspectorAllInOne.cpp:
        * inspector/InspectorController.cpp:
        (WebCore::InspectorController::InspectorController):
        * inspector/InspectorController.h:
        * inspector/InspectorDOMDebuggerAgent.h:
        * inspector/InspectorFrontendClient.h:
        * inspector/InspectorInstrumentation.cpp:
        (WebCore::InspectorInstrumentation::willRecalculateStyleImpl):
        (WebCore::InspectorInstrumentation::didRecalculateStyleImpl):
        (WebCore::InspectorInstrumentation::didScheduleStyleRecalculationImpl):
        (WebCore::InspectorInstrumentation::willSendRequestImpl):
        (WebCore::InspectorInstrumentation::markResourceAsCachedImpl):
        (WebCore::InspectorInstrumentation::didLoadResourceFromMemoryCacheImpl):
        (WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
        (WebCore::InspectorInstrumentation::didReceiveDataImpl):
        (WebCore::InspectorInstrumentation::didFinishLoadingImpl):
        (WebCore::InspectorInstrumentation::didFailLoadingImpl):
        (WebCore::InspectorInstrumentation::didFinishXHRLoadingImpl):
        (WebCore::InspectorInstrumentation::didReceiveXHRResponseImpl):
        (WebCore::InspectorInstrumentation::willLoadXHRSynchronouslyImpl):
        (WebCore::InspectorInstrumentation::didLoadXHRSynchronouslyImpl):
        (WebCore::InspectorInstrumentation::scriptImportedImpl):
        (WebCore::InspectorInstrumentation::didReceiveScriptResponseImpl):
        (WebCore::InspectorInstrumentation::didCommitLoadImpl):
        (WebCore::InspectorInstrumentation::willDestroyCachedResourceImpl):
        (WebCore::InspectorInstrumentation::didCreateWebSocketImpl):
        (WebCore::InspectorInstrumentation::willSendWebSocketHandshakeRequestImpl):
        (WebCore::InspectorInstrumentation::didReceiveWebSocketHandshakeResponseImpl):
        (WebCore::InspectorInstrumentation::didCloseWebSocketImpl):
        (WebCore::InspectorInstrumentation::didReceiveWebSocketFrameImpl):
        (WebCore::InspectorInstrumentation::didReceiveWebSocketFrameErrorImpl):
        (WebCore::InspectorInstrumentation::didSendWebSocketFrameImpl):
        * inspector/InspectorLayerTreeAgent.h:
        * inspector/InspectorNetworkAgent.cpp: Renamed from Source/WebCore/inspector/InspectorResourceAgent.cpp.
        (WebCore::InspectorNetworkAgent::InspectorNetworkAgent):
        (WebCore::InspectorNetworkAgent::didCreateFrontendAndBackend):
        (WebCore::InspectorNetworkAgent::willDestroyFrontendAndBackend):
        (WebCore::buildObjectForHeaders):
        (WebCore::buildObjectForTiming):
        (WebCore::buildObjectForResourceRequest):
        (WebCore::buildObjectForResourceResponse):
        (WebCore::buildObjectForCachedResource):
        (WebCore::InspectorNetworkAgent::~InspectorNetworkAgent):
        (WebCore::InspectorNetworkAgent::timestamp):
        (WebCore::InspectorNetworkAgent::willSendRequest):
        (WebCore::InspectorNetworkAgent::markResourceAsCached):
        (WebCore::InspectorNetworkAgent::didReceiveResponse):
        (WebCore::isErrorStatusCode):
        (WebCore::InspectorNetworkAgent::didReceiveData):
        (WebCore::InspectorNetworkAgent::didFinishLoading):
        (WebCore::InspectorNetworkAgent::didFailLoading):
        (WebCore::InspectorNetworkAgent::didLoadResourceFromMemoryCache):
        (WebCore::InspectorNetworkAgent::setInitialScriptContent):
        (WebCore::InspectorNetworkAgent::didReceiveScriptResponse):
        (WebCore::InspectorNetworkAgent::didFinishXHRLoading):
        (WebCore::InspectorNetworkAgent::didReceiveXHRResponse):
        (WebCore::InspectorNetworkAgent::willLoadXHRSynchronously):
        (WebCore::InspectorNetworkAgent::didLoadXHRSynchronously):
        (WebCore::InspectorNetworkAgent::willDestroyCachedResource):
        (WebCore::InspectorNetworkAgent::willRecalculateStyle):
        (WebCore::InspectorNetworkAgent::didRecalculateStyle):
        (WebCore::InspectorNetworkAgent::didScheduleStyleRecalculation):
        (WebCore::InspectorNetworkAgent::buildInitiatorObject):
        (WebCore::InspectorNetworkAgent::didCreateWebSocket):
        (WebCore::InspectorNetworkAgent::willSendWebSocketHandshakeRequest):
        (WebCore::InspectorNetworkAgent::didReceiveWebSocketHandshakeResponse):
        (WebCore::InspectorNetworkAgent::didCloseWebSocket):
        (WebCore::InspectorNetworkAgent::didReceiveWebSocketFrame):
        (WebCore::InspectorNetworkAgent::didSendWebSocketFrame):
        (WebCore::InspectorNetworkAgent::didReceiveWebSocketFrameError):
        (WebCore::InspectorNetworkAgent::enable):
        (WebCore::InspectorNetworkAgent::disable):
        (WebCore::InspectorNetworkAgent::setExtraHTTPHeaders):
        (WebCore::InspectorNetworkAgent::getResponseBody):
        (WebCore::InspectorNetworkAgent::setCacheDisabled):
        (WebCore::InspectorNetworkAgent::loadResource):
        (WebCore::InspectorNetworkAgent::mainFrameNavigated):
        * inspector/InspectorNetworkAgent.h: Renamed from Source/WebCore/inspector/InspectorResourceAgent.h.
        * inspector/InspectorPageAgent.h:
        * inspector/InstrumentingAgents.cpp:
        (WebCore::InstrumentingAgents::reset):
        * inspector/InstrumentingAgents.h:
        (WebCore::InstrumentingAgents::inspectorNetworkAgent):
        (WebCore::InstrumentingAgents::setInspectorNetworkAgent):
        (WebCore::InstrumentingAgents::inspectorResourceAgent): Deleted.
        (WebCore::InstrumentingAgents::setInspectorResourceAgent): Deleted.
        * inspector/NetworkResourcesData.h:

2015-10-28  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Remove unused / duplicate WebSocket timeline records
        https://bugs.webkit.org/show_bug.cgi?id=150647

        Reviewed by Timothy Hatcher.

        * Modules/websockets/WebSocketChannel.cpp:
        (WebCore::WebSocketChannel::connect):
        Only send what is needed by inspector now.

        * inspector/InspectorInstrumentation.h:
        (WebCore::InspectorInstrumentation::didCreateWebSocket):
        (WebCore::InspectorInstrumentation::willSendWebSocketHandshakeRequest):
        (WebCore::InspectorInstrumentation::didReceiveWebSocketHandshakeResponse):
        (WebCore::InspectorInstrumentation::didCloseWebSocket):
        (WebCore::InspectorInstrumentation::didReceiveWebSocketFrame):
        (WebCore::InspectorInstrumentation::didReceiveWebSocketFrameError):
        (WebCore::InspectorInstrumentation::didSendWebSocketFrame):
        These can all fast return if there is no frontend because the inspector
        doesn't record any information about web sockets until a frontend is connected.
        The inspector in this case just sends events to the frontend when things happen.

        * inspector/InspectorInstrumentation.cpp:
        (WebCore::InspectorInstrumentation::didCreateWebSocketImpl):
        (WebCore::InspectorInstrumentation::willSendWebSocketHandshakeRequestImpl):
        (WebCore::InspectorInstrumentation::didReceiveWebSocketHandshakeResponseImpl):
        (WebCore::InspectorInstrumentation::didCloseWebSocketImpl):
        Stop messaging the Timeline agent, we already message the Resource agent.

        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::InspectorTimelineAgent::didCreateWebSocket): Deleted.
        (WebCore::InspectorTimelineAgent::willSendWebSocketHandshakeRequest): Deleted.
        (WebCore::InspectorTimelineAgent::didReceiveWebSocketHandshakeResponse): Deleted.
        (WebCore::InspectorTimelineAgent::didDestroyWebSocket): Deleted.
        * inspector/InspectorTimelineAgent.h:
        * inspector/TimelineRecordFactory.h:
        (WebCore::TimelineRecordFactory::createWebSocketCreateData): Deleted.
        (WebCore::TimelineRecordFactory::createGenericWebSocketData): Deleted.
        This is all duplicate information from the network domain.

2015-10-28  Andy Estes  <aestes@apple.com>

        [Content Filtering] Crash when allowing a 0-byte resource to load
        https://bugs.webkit.org/show_bug.cgi?id=150644
        <rdar://problem/23288538>

        Reviewed by Darin Adler.

        Test: contentfiltering/allow-empty-document.html

        * loader/ContentFilter.cpp:
        (WebCore::ContentFilter::deliverResourceData): resourceBuffer will be null if the resource contained no data.

2015-10-28  Chris Dumez  <cdumez@apple.com>

        Assertion failure in WebCore::FrameLoader::stopLoading() running fast/events tests
        https://bugs.webkit.org/show_bug.cgi?id=150624

        Reviewed by Darin Adler.

        After r191652, a form's target attribute can no longer refer to a frame's id,
        only its name. This is because the frame's id no longer sets the Window name
        when the frame's name attribute is missing. This caused a change in behavior
        for the fast/events/form-iframe-target-before-load-crash*.html tests, which
        exposed a pre-existing bug.

        This patch updates the fast/events/form-iframe-target-before-load-crash*.html
        tests so they keep testing the same thing as before r191652. It also adds a
        variant to keep covering the newly exposed bug.

        The issue was that the frame was no longer navigated when submitting the form
        (due to the form's target not matching the frame name). Therefore, when
        removing the iframe from the document, its navigation has not started yet and
        DocumentLoadTiming::navigationStart() is not initialized yet when
        FrameLoader::stopLoading() is called and we hit an assertion. This patch
        replaces the assertion with an if check as we now know it can happen and we
        have test coverage for it.

        Test: fast/events/form-iframe-target-before-load-crash.html

        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::stopLoading):

2015-10-28  Brian Burg  <bburg@apple.com>

        Builtins generator should emit ENABLE(FEATURE) guards based on @conditional annotation
        https://bugs.webkit.org/show_bug.cgi?id=150536

        Reviewed by Yusuke Suzuki.

        Replace @optional=FEATURE with @conditional=ENABLE(FEATURE) in builtins files.

        * Modules/streams/ByteLengthQueuingStrategy.js:
        * Modules/streams/CountQueuingStrategy.js:
        * Modules/streams/ReadableStream.js:
        * Modules/streams/ReadableStreamController.js:
        * Modules/streams/ReadableStreamInternals.js:
        * Modules/streams/ReadableStreamReader.js:
        * Modules/streams/StreamInternals.js:
        * Modules/streams/WritableStream.js:
        * Modules/streams/WritableStreamInternals.js:

2015-10-28  Zalan Bujtas  <zalan@apple.com>

        Should never be reached failure in WebCore::backgroundRectForBox
        https://bugs.webkit.org/show_bug.cgi?id=150232

        Reviewed by Simon Fraser.

        We should never end up with simple container for composited layer when background-clip: text is present.
        (not even when the box has no decoration to paint)

        Test: fast/backgrounds/background-clip-text-with-simple-container.html

        * rendering/RenderLayerBacking.cpp:
        (WebCore::RenderLayerBacking::paintsBoxDecorations):
        (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
        (WebCore::backgroundRectForBox):

2015-10-28  Chris Dumez  <cdumez@apple.com>

        Use RunLoopTimer in DataURLDecoder to avoid issues related to runloops
        https://bugs.webkit.org/show_bug.cgi?id=150609
        <rdar://problem/22702894>

        Reviewed by Antti Koivisto.

        Use RunLoopTimer in DataURLDecoder to avoid issues related to RunLoops.
        In particular, the callOnMainThread() call could fail to dispatch the
        decoding result to the main thread if the client-side would spin its own
        RunLoop.

        This is similar to the approach used in DocumentLoader for
        DocumentLoaderTimer.

        No new tests, verified through manual testing.

        * WebCore.xcodeproj/project.pbxproj:
        * loader/ResourceLoader.cpp:
        (WebCore::ResourceLoader::loadDataURL):
        * page/Page.cpp:
        (WebCore::Page::Page):
        * page/Page.h:
        * page/mac/PageMac.mm: Renamed from Source/WebCore/page/mac/PageMac.cpp.
        (WebCore::Page::platformInitialize):
        (WebCore::Page::addSchedulePair):
        (WebCore::Page::removeSchedulePair):
        * platform/network/DataURLDecoder.cpp:
        (WebCore::DataURLDecoder::DecodingResultDispatcher::dispatch):
        (WebCore::DataURLDecoder::DecodingResultDispatcher::DecodingResultDispatcher):
        (WebCore::DataURLDecoder::DecodingResultDispatcher::startTimer):
        (WebCore::DataURLDecoder::DecodingResultDispatcher::timerFired):
        (WebCore::DataURLDecoder::createDecodeTask):
        (WebCore::DataURLDecoder::decode):
        * platform/network/DataURLDecoder.h:

2015-10-28  Brady Eidson  <beidson@apple.com>

        Modern IDB: Implement most readonly attributes of IDBObjectStore.
        https://bugs.webkit.org/show_bug.cgi?id=150617

        Reviewed by Alex Christensen.

        Test: storage/indexeddb/modern/objectstore-attributes.html

        * Modules/indexeddb/IDBObjectStore.h:

        * Modules/indexeddb/client/IDBAnyImpl.cpp:
        (WebCore::IDBClient::IDBAny::IDBAny):
        * Modules/indexeddb/client/IDBAnyImpl.h:
        (WebCore::IDBClient::IDBAny::create):

        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::name):
        (WebCore::IDBClient::IDBObjectStore::keyPathAny):
        (WebCore::IDBClient::IDBObjectStore::keyPath):
        (WebCore::IDBClient::IDBObjectStore::transaction):
        (WebCore::IDBClient::IDBObjectStore::id): Deleted.
        * Modules/indexeddb/client/IDBObjectStoreImpl.h:

        * Modules/indexeddb/legacy/LegacyObjectStore.h:
        (WebCore::LegacyObjectStore::transaction):

2015-10-28  Hunseop Jeong  <hs85.jeong@samsung.com>

        Replace 0 and NULL with nullptr in WebCore/editing.
        https://bugs.webkit.org/show_bug.cgi?id=150555

        Reviewed by Darin Adler.

        No new tests because there is no behavior change.

        * editing/ApplyStyleCommand.cpp:
        (WebCore::ApplyStyleCommand::ApplyStyleCommand):
        (WebCore::ApplyStyleCommand::splitAncestorsWithUnicodeBidi):
        (WebCore::ApplyStyleCommand::applyInlineStyle):
        * editing/ApplyStyleCommand.h:
        (WebCore::ApplyStyleCommand::shouldRemoveInlineStyleFromElement):
        * editing/CompositeEditCommand.cpp:
        (WebCore::CompositeEditCommand::applyCommandToComposite):
        (WebCore::CompositeEditCommand::deleteInsignificantText):
        * editing/DeleteSelectionCommand.cpp:
        (WebCore::DeleteSelectionCommand::DeleteSelectionCommand):
        (WebCore::DeleteSelectionCommand::initializeStartEnd):
        * editing/EditCommand.cpp:
        (WebCore::EditCommand::EditCommand):
        * editing/EditCommand.h:
        * editing/EditingStyle.cpp:
        (WebCore::HTMLElementEquivalent::HTMLElementEquivalent):
        * editing/EditingStyle.h:
        (WebCore::EditingStyle::conflictsWithInlineStyleOfElement):
        * editing/Editor.h:
        * editing/EditorCommand.cpp:
        (WebCore::Editor::commandIsSupportedFromMenuOrKeyBinding):
        (WebCore::Editor::Command::Command):
        * editing/FrameSelection.cpp:
        (WebCore::DragCaretController::setCaretPosition):
        (WebCore::FrameSelection::directionOfSelection):
        * editing/MarkupAccumulator.cpp:
        (WebCore::MarkupAccumulator::entityMaskForText):
        * editing/MarkupAccumulator.h:
        * editing/RenderedPosition.cpp:
        (WebCore::rendererFromPosition):
        (WebCore::RenderedPosition::RenderedPosition):
        * editing/RenderedPosition.h:
        (WebCore::RenderedPosition::operator==):
        (WebCore::RenderedPosition::uncachedInlineBox):
        (WebCore::RenderedPosition::RenderedPosition):
        * editing/ReplaceSelectionCommand.cpp:
        (WebCore::ReplaceSelectionCommand::handleStyleSpans):
        * editing/SetNodeAttributeCommand.cpp:
        (WebCore::SetNodeAttributeCommand::doUnapply):
        * editing/SmartReplaceCF.cpp:
        (WebCore::getSmartSet):
        * editing/SpellChecker.cpp:
        (WebCore::SpellCheckRequest::SpellCheckRequest):
        (WebCore::SpellCheckRequest::didSucceed):
        (WebCore::SpellCheckRequest::didCancel):
        (WebCore::SpellCheckRequest::setCheckerAndSequence):
        (WebCore::SpellCheckRequest::requesterDestroyed):
        (WebCore::SpellChecker::SpellChecker):
        * editing/SpellChecker.h:
        * editing/VisiblePosition.cpp:
        (WebCore::VisiblePosition::leftVisuallyDistinctCandidate):
        (WebCore::VisiblePosition::rightVisuallyDistinctCandidate):
        (WebCore::VisiblePosition::localCaretRect):
        (WebCore::enclosingBlockFlowElement):
        * editing/VisibleUnits.cpp:
        (WebCore::CachedLogicallyOrderedLeafBoxes::CachedLogicallyOrderedLeafBoxes):
        (WebCore::CachedLogicallyOrderedLeafBoxes::previousTextOrLineBreakBox):
        (WebCore::visualWordPosition):
        (WebCore::previousLinePosition):
        (WebCore::nextLinePosition):
        * editing/htmlediting.cpp:
        (WebCore::highestEnclosingNodeOfType):
        (WebCore::highestNodeToRemoveInPruning):
        * editing/htmlediting.h:
        (WebCore::firstPositionInOrBeforeNode):
        * editing/ios/EditorIOS.mm:
        (WebCore::Editor::setTextAlignmentForChangedBaseWritingDirection):
        (WebCore::Editor::fontForSelection):
        * editing/mac/AlternativeTextUIController.mm:
        (WebCore::AlternativeTextUIController::AlernativeTextContextController::alternativesForContext):
        * editing/mac/EditorMac.mm:
        (WebCore::Editor::fontForSelection):
        * editing/markup.cpp:
        * editing/markup.h:

2015-10-28  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Add write method to writable stream
        https://bugs.webkit.org/show_bug.cgi?id=150589

        Reviewed by Darin Adler.

        Write method implemented on writable streams according to the spec.

        Current test set suffices. Expectations are updated accordingly.

        * Modules/streams/WritableStream.js:
        (write):

2015-10-27  Hunseop Jeong  <hs85.jeong@samsung.com>

        [Cairo] Incorrect dashed and dotted border painting after r177686.
        https://bugs.webkit.org/show_bug.cgi?id=141967

        Reviewed by Gyuyoung Kim.

        Fix the incorrect dashed/dotted border painting in cairo.

        * platform/graphics/cairo/GraphicsContextCairo.cpp:
        (WebCore::GraphicsContext::drawLine):
        (WebCore::calculateStrokePatternOffset): Deleted.
        (WebCore::drawLineOnCairoContext): Deleted.

2015-10-27  Chris Dumez  <cdumez@apple.com>

        id of iframe incorrectly sets window name
        https://bugs.webkit.org/show_bug.cgi?id=150565

        Reviewed by Darin Adler.

        As per the specification, the iframe's contentWindow name should be an
        empty string if the frame's name attribute is unset:
        http://www.whatwg.org/specs/web-apps/current-work/multipage/the-iframe-element.html#attr-iframe-name

        Instead, WebKit was using the iframe's id as window name if the name
        was unset.

        Firefox, IE and Chrome behave according to the specification.

        This is a merge of the following Blink commit:
        https://src.chromium.org/viewvc/blink?revision=169803&view=revision

        Test: fast/frames/iframe-no-name.html

        * html/HTMLFrameElementBase.cpp:
        (WebCore::HTMLFrameElementBase::parseAttribute):
        (WebCore::HTMLFrameElementBase::insertedInto): Deleted.

2015-10-27  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Remove Timeline MarkDOMContent and MarkLoad, data is already available
        https://bugs.webkit.org/show_bug.cgi?id=150615

        Reviewed by Timothy Hatcher.

        The timestamp only event data is already available from `Page.domContentEventFired`
        and `Page.loadEventFired` events. We can drop the Timeline specific events in
        favor of these which have existed for a very long time (before iOS 7).

        * inspector/InspectorInstrumentation.cpp:
        (WebCore::InspectorInstrumentation::loadEventFiredImpl):
        (WebCore::InspectorInstrumentation::domContentLoadedEventFiredImpl): Deleted.
        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::InspectorTimelineAgent::didMarkDOMContentEvent): Deleted.
        (WebCore::InspectorTimelineAgent::didMarkLoadEvent): Deleted.
        (WebCore::toProtocol): Deleted.
        * inspector/InspectorTimelineAgent.h:
        * inspector/TimelineRecordFactory.cpp:
        (WebCore::TimelineRecordFactory::createMarkData): Deleted.
        * inspector/TimelineRecordFactory.h:

2015-10-27  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test editing/execCommand/format-block-uneditable-crash.html
        https://bugs.webkit.org/show_bug.cgi?id=150207
        <rdar://problem/23137066>

        Reviewed by Enrica Casucci.

        This is a merge of Blink r200238:
        https://codereview.chromium.org/1280263002

        Test: editing/execCommand/format-block-uneditable-crash.html

        * editing/ApplyBlockElementCommand.cpp:
        (WebCore::ApplyBlockElementCommand::rangeForParagraphSplittingTextNodesIfNeeded):
        splitTextNode() will return early if the given text node is not editable. Hence, check
        its editablity before calling the method.

2015-10-27  Brady Eidson  <beidson@apple.com>

        Modern IDB: IDBTransaction.objectStore() support.
        https://bugs.webkit.org/show_bug.cgi?id=150607

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/aborted-put.html
               storage/indexeddb/modern/idbtransaction-objectstore-failures.html

        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::put):
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::objectStore):
        (WebCore::IDBClient::IDBTransaction::createObjectStoreOnServer):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::addExistingObjectStore):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::beginTransaction):
        
        * Modules/indexeddb/shared/IDBDatabaseInfo.cpp:
        (WebCore::IDBDatabaseInfo::infoForExistingObjectStore):
        * Modules/indexeddb/shared/IDBDatabaseInfo.h:
        
        * Modules/indexeddb/shared/IDBTransactionInfo.h:
        (WebCore::IDBTransactionInfo::objectStores):

2015-10-27  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Remove unused / duplicated XHR timeline instrumentation
        https://bugs.webkit.org/show_bug.cgi?id=150605

        Reviewed by Timothy Hatcher.

        These records are just duplicates of "EventDispatch" records for XHR
        load and readystatechange events. Due to the nesting, the XHR records
        were themselves never getting looked at, and their data (URL / readyState)
        not shown in the frontend.

        * inspector/InspectorInstrumentation.cpp:
        (WebCore::InspectorInstrumentation::willDispatchXHRReadyStateChangeEventImpl): Deleted.
        (WebCore::InspectorInstrumentation::didDispatchXHRReadyStateChangeEventImpl): Deleted.
        (WebCore::InspectorInstrumentation::willDispatchXHRLoadEventImpl): Deleted.
        (WebCore::InspectorInstrumentation::didDispatchXHRLoadEventImpl): Deleted.
        * inspector/InspectorInstrumentation.h:
        (WebCore::InspectorInstrumentation::willDispatchXHRReadyStateChangeEvent): Deleted.
        (WebCore::InspectorInstrumentation::didDispatchXHRReadyStateChangeEvent): Deleted.
        (WebCore::InspectorInstrumentation::willDispatchXHRLoadEvent): Deleted.
        (WebCore::InspectorInstrumentation::didDispatchXHRLoadEvent): Deleted.
        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::InspectorTimelineAgent::willDispatchXHRReadyStateChangeEvent): Deleted.
        (WebCore::InspectorTimelineAgent::didDispatchXHRReadyStateChangeEvent): Deleted.
        (WebCore::InspectorTimelineAgent::willDispatchXHRLoadEvent): Deleted.
        (WebCore::InspectorTimelineAgent::didDispatchXHRLoadEvent): Deleted.
        (WebCore::toProtocol): Deleted.
        * inspector/InspectorTimelineAgent.h:
        * inspector/TimelineRecordFactory.cpp:
        (WebCore::TimelineRecordFactory::createXHRReadyStateChangeData): Deleted.
        (WebCore::TimelineRecordFactory::createXHRLoadData): Deleted.
        * inspector/TimelineRecordFactory.h:
        * xml/XMLHttpRequest.cpp:
        (WebCore::XMLHttpRequest::callReadyStateChangeListener): Deleted.

2015-10-27  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Do not send RenderingFrame TimelineRecords that have no children
        https://bugs.webkit.org/show_bug.cgi?id=150600

        Reviewed by Timothy Hatcher.

        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::InspectorTimelineAgent::didCompleteCurrentRecord):
        The frontend already filters out empty RenderingFrame records
        (in TimelineManager.prototype._processRecord). Filter them out
        on the backend to reduce protocol traffic / noise.

2015-10-27  Alex Christensen  <achristensen@webkit.org>

        Cancel navigation policy checks like we do content policy checks.
        https://bugs.webkit.org/show_bug.cgi?id=150582
        rdar://problem/22077579

        Reviewed by Brent Fulgham.

        This was verified manually and I'll write a layout test for it soon.

        * loader/DocumentLoader.cpp:
        (WebCore::DocumentLoader::DocumentLoader):
        (WebCore::DocumentLoader::~DocumentLoader):
        (WebCore::DocumentLoader::willSendRequest):
        (WebCore::DocumentLoader::continueAfterNavigationPolicy):
        (WebCore::DocumentLoader::cancelPolicyCheckIfNeeded):
        * loader/DocumentLoader.h:
        Add a bool to keep track of whether we are waiting for navigation policy checks, like we do with content policy checks.
        Without this check, sometimes callbacks are made to DocumentLoaders that do not exist any more because they do not get
        cancelled by cancelPolicyCheckIfNeeded when detaching from the frame.

2015-10-27  Brady Eidson  <beidson@apple.com>

        Modern IDB: Support IDBObjectStore.put/get support.
        https://bugs.webkit.org/show_bug.cgi?id=150468

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/basic-put.html
               storage/indexeddb/modern/keypath-basic.html

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:

        * Modules/indexeddb/IDBKeyData.cpp:
        (WebCore::IDBKeyData::deletedValue):
        (WebCore::IDBKeyData::operator<):
        (WebCore::IDBKeyData::operator==):
        * Modules/indexeddb/IDBKeyData.h:
        (WebCore::IDBKeyData::isValid):
        (WebCore::IDBKeyData::operator!=):
        (WebCore::IDBKeyData::hash):
        (WebCore::IDBKeyData::isDeletedValue):
        (WebCore::IDBKeyDataHash::hash):
        (WebCore::IDBKeyDataHash::equal):
        (WebCore::IDBKeyDataHashTraits::constructDeletedValue):
        (WebCore::IDBKeyDataHashTraits::isDeletedValue):
        (WebCore::IDBKeyDataHashTraits::emptyValue):
        (WebCore::IDBKeyDataHashTraits::isEmptyValue):

        * Modules/indexeddb/IndexedDB.h:

        * Modules/indexeddb/client/IDBAnyImpl.cpp:
        (WebCore::IDBClient::IDBAny::IDBAny):
        (WebCore::IDBClient::IDBAny::modernIDBObjectStore):
        * Modules/indexeddb/client/IDBAnyImpl.h:
        (WebCore::IDBClient::IDBAny::create):

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::createObjectStore):
        (WebCore::IDBClient::IDBConnectionToServer::didCreateObjectStore):
        (WebCore::IDBClient::IDBConnectionToServer::putOrAdd):
        (WebCore::IDBClient::IDBConnectionToServer::didPutOrAdd):
        (WebCore::IDBClient::IDBConnectionToServer::getRecord):
        (WebCore::IDBClient::IDBConnectionToServer::didGetRecord):
        (WebCore::IDBClient::IDBConnectionToServer::saveOperation):
        (WebCore::IDBClient::IDBConnectionToServer::completeOperation):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:

        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp:
        (WebCore::IDBClient::IDBObjectStore::autoIncrement):
        (WebCore::IDBClient::IDBObjectStore::put):
        (WebCore::IDBClient::IDBObjectStore::get):
        (WebCore::IDBClient::IDBObjectStore::putOrAdd):
        * Modules/indexeddb/client/IDBObjectStoreImpl.h:
        (WebCore::IDBClient::IDBObjectStore::info):

        * Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBOpenDBRequest::IDBOpenDBRequest): Deleted.

        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::create):
        (WebCore::IDBClient::IDBRequest::IDBRequest):
        (WebCore::IDBClient::IDBRequest::sourceObjectStoreIdentifier):
        (WebCore::IDBClient::IDBRequest::hasPendingActivity):
        (WebCore::IDBClient::IDBRequest::dispatchEvent):
        (WebCore::IDBClient::IDBRequest::setResult):
        (WebCore::IDBClient::IDBRequest::setResultToStructuredClone):
        (WebCore::IDBClient::IDBRequest::requestCompleted):
        (WebCore::IDBClient::IDBRequest::onError):
        (WebCore::IDBClient::IDBRequest::onSuccess):
        * Modules/indexeddb/client/IDBRequestImpl.h:

        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::IDBTransaction):
        (WebCore::IDBClient::IDBTransaction::hasPendingActivity):
        (WebCore::IDBClient::IDBTransaction::isActive):
        (WebCore::IDBClient::IDBTransaction::operationTimerFired):
        (WebCore::IDBClient::IDBTransaction::commit):
        (WebCore::IDBClient::IDBTransaction::didAbort):
        (WebCore::IDBClient::IDBTransaction::createObjectStoreOnServer):
        (WebCore::IDBClient::IDBTransaction::requestGetRecord):
        (WebCore::IDBClient::IDBTransaction::getRecordOnServer):
        (WebCore::IDBClient::IDBTransaction::didGetRecordOnServer):
        (WebCore::IDBClient::IDBTransaction::requestPutOrAdd):
        (WebCore::IDBClient::IDBTransaction::putOrAddOnServer):
        (WebCore::IDBClient::IDBTransaction::didPutOrAddOnServer):
        (WebCore::IDBClient::IDBTransaction::activate):
        (WebCore::IDBClient::IDBTransaction::deactivate):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        (WebCore::IDBClient::IDBTransaction::isReadOnly):
        (WebCore::IDBClient::TransactionActivator::TransactionActivator):
        (WebCore::IDBClient::TransactionActivator::~TransactionActivator):

        * Modules/indexeddb/client/TransactionOperation.cpp: 
        (WebCore::IDBClient::TransactionOperation::TransactionOperation):
        * Modules/indexeddb/client/TransactionOperation.h:
        (WebCore::IDBClient::TransactionOperation::objectStoreIdentifier):
        (WebCore::IDBClient::TransactionOperation::transaction):
        (WebCore::IDBClient::createTransactionOperation):

        * Modules/indexeddb/server/IDBBackingStore.h:
        
        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didPutOrAdd):
        (WebCore::IDBServer::IDBConnectionToClient::didGetRecord):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:

        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::putOrAdd):
        (WebCore::IDBServer::IDBServer::getRecord):
        * Modules/indexeddb/server/IDBServer.h:

        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::recordValueChanged):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:

        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::keyExistsInObjectStore):
        (WebCore::IDBServer::MemoryIDBBackingStore::deleteRecord):
        (WebCore::IDBServer::MemoryIDBBackingStore::putRecord):
        (WebCore::IDBServer::MemoryIDBBackingStore::getRecord):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:

        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::containsRecord):
        (WebCore::IDBServer::MemoryObjectStore::deleteRecord):
        (WebCore::IDBServer::MemoryObjectStore::putRecord):
        (WebCore::IDBServer::MemoryObjectStore::valueForKey):
        * Modules/indexeddb/server/MemoryObjectStore.h:

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::storeCallback):
        (WebCore::IDBServer::UniqueIDBDatabase::putOrAdd):
        (WebCore::IDBServer::UniqueIDBDatabase::performPutOrAdd):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformPutOrAdd):
        (WebCore::IDBServer::UniqueIDBDatabase::getRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::performGetRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformGetRecord):
        (WebCore::IDBServer::UniqueIDBDatabase::performKeyDataCallback):
        (WebCore::IDBServer::UniqueIDBDatabase::performValueDataCallback):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::isReadOnly):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::putOrAdd):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::getRecord):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:

        * Modules/indexeddb/shared/IDBDatabaseInfo.cpp:
        (WebCore::IDBDatabaseInfo::infoForExistingObjectStore):
        * Modules/indexeddb/shared/IDBDatabaseInfo.h:

        * Modules/indexeddb/shared/IDBError.cpp:
        (WebCore::idbErrorName):
        (WebCore::idbErrorDescription):
        * Modules/indexeddb/shared/IDBError.h:

        * Modules/indexeddb/shared/IDBRequestData.cpp:
        (WebCore::IDBRequestData::IDBRequestData):
        (WebCore::IDBRequestData::serverConnectionIdentifier):
        (WebCore::IDBRequestData::objectStoreIdentifier):
        * Modules/indexeddb/shared/IDBRequestData.h:

        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::IDBResultData):
        (WebCore::IDBResultData::putOrAddSuccess):
        (WebCore::IDBResultData::getRecordSuccess):
        * Modules/indexeddb/shared/IDBResultData.h:
        (WebCore::IDBResultData::resultKey):
        (WebCore::IDBResultData::resultData):

        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didPutOrAdd):
        (WebCore::InProcessIDBServer::didGetRecord):
        (WebCore::InProcessIDBServer::putOrAdd):
        (WebCore::InProcessIDBServer::getRecord):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

        * bindings/js/IDBBindingUtilities.cpp:
        (WebCore::idbKeyToJSValue):
        (WebCore::maybeCreateIDBKeyFromScriptValueAndKeyPath):
        (WebCore::canInjectIDBKeyIntoScriptValue):
        (WebCore::deserializeIDBValueData):
        (WebCore::scriptValueToIDBKey):
        (WebCore::idbKeyDataToScriptValue):
        * bindings/js/IDBBindingUtilities.h:

        * platform/CrossThreadCopier.cpp:
        (WebCore::ThreadSafeDataBuffer>::copy):
        * platform/CrossThreadCopier.h:

        * platform/ThreadSafeDataBuffer.h: Added.
        (WebCore::ThreadSafeDataBufferImpl::ThreadSafeDataBufferImpl):
        (WebCore::ThreadSafeDataBuffer::adoptVector):
        (WebCore::ThreadSafeDataBuffer::copyVector):
        (WebCore::ThreadSafeDataBuffer::ThreadSafeDataBuffer):
        (WebCore::ThreadSafeDataBuffer::data):

2015-10-27  Tim Horton  <timothy_horton@apple.com>

        WKView being inside WKWebView leads to weird API issues
        https://bugs.webkit.org/show_bug.cgi?id=150174

        Reviewed by Anders Carlsson.

        * platform/spi/cg/CoreGraphicsSPI.h:

2015-10-27  Zhuo Li  <zachli@apple.com>

        Add WebKit API to clear data type Search Field Recent Searches.
        https://bugs.webkit.org/show_bug.cgi?id=150019.

        Reviewed by Anders Carlsson.

        * platform/cocoa/SearchPopupMenuCocoa.h: Add a function to remove recent searches based on
        time.
        * platform/cocoa/SearchPopupMenuCocoa.mm:
        (WebCore::typeCheckedRecentSearchesArray): Return nil if the recent searches array is
        corrupted, otherwise return the array.
        (WebCore::typeCheckedDateInRecentSearch): Return nil if the date in recent search is
        corrupted, otherwise return the date.
        (WebCore::typeCheckedRecentSearchesRemovingRecentSearchesAddedAfterDate): Return nil if the recent searches plist is
        corrupted, otherwise return the recent searches plist.
        (WebCore::writeEmptyRecentSearchesPlist): Replace the existing recent searches plist if there is
        any with a clean one.
        (WebCore::loadRecentSearches): Use -typeCheckedRecentSearchesArray and -typeCheckedDateInRecentSearch.
        (WebCore::removeRecentlyModifiedRecentSearches):
        When the time passed in is equivalent to [NSDate distantPast], clear all recent searches in
        the Recent Searches plist. Otherwise, we only clear the recent searches that were created
        after or at the time that is passed in as the parameter. If all recent searches associated
        with an autosave name were created after or at the time that is passed in as the parameter,
        remove this autosave name key and all of its values in the plist. If all recent searches
        associated with every autosave name in the plist were created after or at the time that is
        passed in as the parameter, clear all recent searches in the Recent Searches plist.

        Also, we clear all recent searches in the Recent Searches plist when we find the plist is
        corrupted.

2015-10-27  Keith Rollin  <krollin@apple.com>

        Do not sanitize user input for input[type=url]
        https://bugs.webkit.org/show_bug.cgi?id=150346
        <rdar://problem/23243240>

        Reviewed by Darin Adler.

        Do not sanitize user input in text-based input fields that support
        the Selection API, in order to not break JavaScript code that expects
        element.value to match what's on the screen.

        Test: fast/forms/input-user-input-sanitization.html

        * html/TextFieldInputType.cpp:
        (WebCore::TextFieldInputType::subtreeHasChanged):

2015-10-20  Zalan Bujtas  <zalan@apple.com>

        Subpixel layout: Convert RenderTable* and AutoTableLayout to use LayoutUnit.
        https://bugs.webkit.org/show_bug.cgi?id=149366

        Reviewed by David Hyatt.

        This patch enables non-integral cell space distribution for both
        auto and fixed table layout.
        Due to the tight layout, float is used to calculate each cell's dimension/position and
        we convert them to LayoutUnits while said values are set on the renderer.
        Due to the (lack of) LayoutUnit precision, a fudge factor is applied on table cell's minimum width.   

        Collapsed table borders are still integral based, tracked here: webkit.org/b/150383

        Covered by existing tests.

        (WebCore::RenderTableSection::firstLineBaseline): Baseline is still integral (same as normal line layout)
        * rendering/RenderTreeAsText.cpp: flooring produces the least amount of rebaseline diff (still over 1200 tests). It doesn't really matter which direction we round
        as long as it is consistent.
        (WebCore::writeTextRun):
        (WebCore::writeSimpleLine):
        * platform/graphics/LayoutRect.h:
        (WebCore::LayoutRect::LayoutRect):
        * rendering/AutoTableLayout.cpp:
        (WebCore::AutoTableLayout::recalcColumn):
        (WebCore::AutoTableLayout::computeIntrinsicLogicalWidths):
        (WebCore::AutoTableLayout::applyPreferredLogicalWidthQuirks):
        (WebCore::AutoTableLayout::calcEffectiveLogicalWidth):
        (WebCore::AutoTableLayout::layout):
        * rendering/AutoTableLayout.h:
        * rendering/FixedTableLayout.cpp:
        (WebCore::FixedTableLayout::calcWidthArray):
        (WebCore::FixedTableLayout::applyPreferredLogicalWidthQuirks):
        (WebCore::FixedTableLayout::layout):
        * rendering/FixedTableLayout.h:
        * rendering/RenderBlock.cpp:
        (WebCore::RenderBlock::computePreferredLogicalWidths):
        * rendering/RenderTable.cpp:
        (WebCore::RenderTable::updateLogicalWidth):
        (WebCore::RenderTable::distributeExtraLogicalHeight):
        (WebCore::RenderTable::layout):
        (WebCore::RenderTable::addOverflowFromChildren):
        (WebCore::RenderTable::computePreferredLogicalWidths):
        (WebCore::RenderTable::offsetWidthForColumn):
        (WebCore::RenderTable::calcBorderStart):
        (WebCore::RenderTable::calcBorderEnd):
        (WebCore::RenderTable::outerBorderBefore):
        (WebCore::RenderTable::outerBorderAfter):
        (WebCore::RenderTable::outerBorderStart):
        (WebCore::RenderTable::outerBorderEnd):
        * rendering/RenderTable.h:
        (WebCore::RenderTable::hBorderSpacing):
        (WebCore::RenderTable::vBorderSpacing):
        (WebCore::RenderTable::outerBorderLeft):
        (WebCore::RenderTable::outerBorderRight):
        (WebCore::RenderTable::outerBorderTop):
        (WebCore::RenderTable::outerBorderBottom):
        (WebCore::RenderTable::columnPositions):
        (WebCore::RenderTable::setColumnPosition):
        * rendering/RenderTableCell.cpp:
        (WebCore::RenderTableCell::logicalWidthFromColumns):
        (WebCore::RenderTableCell::computeIntrinsicPadding):
        (WebCore::RenderTableCell::setCellLogicalWidth):
        (WebCore::RenderTableCell::layout):
        (WebCore::RenderTableCell::paddingTop):
        (WebCore::RenderTableCell::paddingBottom):
        (WebCore::RenderTableCell::paddingLeft):
        (WebCore::RenderTableCell::paddingRight):
        (WebCore::RenderTableCell::paddingBefore):
        (WebCore::RenderTableCell::paddingAfter):
        (WebCore::RenderTableCell::clippedOverflowRectForRepaint):
        (WebCore::RenderTableCell::borderLeft):
        (WebCore::RenderTableCell::borderRight):
        (WebCore::RenderTableCell::borderTop):
        (WebCore::RenderTableCell::borderBottom):
        (WebCore::RenderTableCell::borderStart):
        (WebCore::RenderTableCell::borderEnd):
        (WebCore::RenderTableCell::borderBefore):
        (WebCore::RenderTableCell::borderAfter):
        (WebCore::RenderTableCell::borderHalfLeft):
        (WebCore::RenderTableCell::borderHalfRight):
        (WebCore::RenderTableCell::borderHalfTop):
        (WebCore::RenderTableCell::borderHalfBottom):
        (WebCore::RenderTableCell::borderHalfStart):
        (WebCore::RenderTableCell::borderHalfEnd):
        (WebCore::RenderTableCell::borderHalfBefore):
        (WebCore::RenderTableCell::borderHalfAfter):
        (WebCore::CollapsedBorders::addBorder):
        (WebCore::RenderTableCell::paintCollapsedBorders):
        (WebCore::RenderTableCell::paintBackgroundsBehindCell):
        (WebCore::RenderTableCell::paintBoxDecorations):
        (WebCore::RenderTableCell::paintMask):
        * rendering/RenderTableCell.h:
        (WebCore::RenderTableCell::logicalHeightForRowSizing):
        * rendering/RenderTableSection.cpp:
        (WebCore::RenderTableSection::calcRowLogicalHeight):
        (WebCore::RenderTableSection::layout):
        (WebCore::RenderTableSection::distributeExtraLogicalHeightToPercentRows):
        (WebCore::RenderTableSection::distributeExtraLogicalHeightToAutoRows):
        (WebCore::RenderTableSection::distributeRemainingExtraLogicalHeight):
        (WebCore::RenderTableSection::distributeExtraLogicalHeightToRows):
        (WebCore::RenderTableSection::layoutRows):
        (WebCore::RenderTableSection::calcOuterBorderBefore):
        (WebCore::RenderTableSection::calcOuterBorderAfter):
        (WebCore::RenderTableSection::calcOuterBorderStart):
        (WebCore::RenderTableSection::calcOuterBorderEnd):
        (WebCore::RenderTableSection::logicalRectForWritingModeAndDirection):
        (WebCore::RenderTableSection::dirtiedColumns):
        (WebCore::RenderTableSection::spannedColumns):
        (WebCore::RenderTableSection::offsetLeftForRowGroupBorder):
        (WebCore::RenderTableSection::offsetTopForRowGroupBorder):
        (WebCore::RenderTableSection::verticalRowGroupBorderHeight):
        (WebCore::RenderTableSection::horizontalRowGroupBorderWidth):
        (WebCore::RenderTableSection::paintRowGroupBorderIfRequired):
        (WebCore::RenderTableSection::setLogicalPositionForCell):
        * rendering/RenderTableSection.h:
        (WebCore::RenderTableSection::outerBorderLeft):
        (WebCore::RenderTableSection::outerBorderRight):
        (WebCore::RenderTableSection::outerBorderTop):
        (WebCore::RenderTableSection::outerBorderBottom):
        * rendering/style/CollapsedBorderValue.h:
        (WebCore::CollapsedBorderValue::CollapsedBorderValue):
        (WebCore::CollapsedBorderValue::width):

2015-10-27  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Add close method to writable stream
        https://bugs.webkit.org/show_bug.cgi?id=150560

        Reviewed by Darin Adler.

        Added the close method which requires three additional writable stream internal functions plus a queuing
        function to retrieve a value from the queue according to the spec.

        Current test set suffices. Expectations were updated accordingly.

        * Modules/streams/StreamInternals.js:
        (peekQueueValue):
        * Modules/streams/WritableStream.js:
        (close):
        * Modules/streams/WritableStreamInternals.js:
        (callOrScheduleWritableStreamAdvanceQueue):
        (writableStreamAdvanceQueue):
        (closeWritableStream): Added as per spec.

2015-10-26  Brady Eidson  <beidson@apple.com>

        Make IDBKeyData from a struct to a class.
        https://bugs.webkit.org/show_bug.cgi?id=150576

        Reviewed by Alex Christensen.

        No new tests (No change in behavior).

        * Modules/indexeddb/IDBKeyData.cpp:
        (WebCore::IDBKeyData::IDBKeyData):
        (WebCore::IDBKeyData::maybeCreateIDBKey):
        (WebCore::IDBKeyData::isolatedCopy):
        (WebCore::IDBKeyData::encode):
        (WebCore::IDBKeyData::decode):
        (WebCore::IDBKeyData::compare):
        (WebCore::IDBKeyData::loggingString):
        (WebCore::IDBKeyData::setArrayValue):
        (WebCore::IDBKeyData::setStringValue):
        (WebCore::IDBKeyData::setDateValue):
        (WebCore::IDBKeyData::setNumberValue):
        * Modules/indexeddb/IDBKeyData.h:
        (WebCore::IDBKeyData::IDBKeyData):
        (WebCore::IDBKeyData::minimum):
        (WebCore::IDBKeyData::maximum):
        (WebCore::IDBKeyData::isNull):
        (WebCore::IDBKeyData::type):
        (WebCore::IDBKeyData::encode):
        (WebCore::IDBKeyData::decode):
        * Modules/indexeddb/legacy/IDBTransactionBackendOperations.cpp:
        (WebCore::GetOperation::perform):
        * bindings/js/IDBBindingUtilities.h:
        * platform/CrossThreadCopier.h:

2015-10-26  Philip Chimento  <philip.chimento@gmail.com>

        [GTK] [Stable] Build GL texture mapper only if USE_TEXTURE_MAPPER_GL
        https://bugs.webkit.org/show_bug.cgi?id=148606

        Unreviewed, build-only change.

        No new tests, build-only change.

        * PlatformGTK.cmake: Remove sources requiring GL from list of
        sources that are built when USE_TEXTURE_MAPPER is true, and add a
        separate condition within the USE_TEXTURE_MAPPER condition to
        build those sources when USE_TEXTURE_MAPPER_GL is true.

2015-10-26  Simon Fraser  <simon.fraser@apple.com>

        Remove redundant GraphicsContext::clip(const Path&, WindRule)
        https://bugs.webkit.org/show_bug.cgi?id=150584

        Reviewed by Tim Horton.

        GraphicsContext had both clipPath(const Path&, WindRule) and clip(const Path&, WindRule),
        which were mostly the same other than GraphicsContext::clipPath() not clipping if the path
        was empty (added, I think by mistake, in r72926), and not calling m_data->clip().

        Make clipPath() be the winner, and have it behave like clip() with empty paths, and call m_data->clip().

        * platform/graphics/GraphicsContext.cpp:
        (WebCore::GraphicsContext::clipRoundedRect):
        * platform/graphics/GraphicsContext.h:
        * platform/graphics/cairo/GraphicsContextCairo.cpp:
        (WebCore::GraphicsContext::clipPath):
        (WebCore::GraphicsContext::clip): Deleted.
        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::GraphicsContext::clipPath):
        (WebCore::GraphicsContext::canvasClip):
        (WebCore::GraphicsContext::clip): Deleted.
        * rendering/RenderBoxModelObject.cpp:
        (WebCore::RenderBoxModelObject::paintBoxShadow): Making a path, calling addRoundedRect() and then clipping
        to the path is the same as context.clipRoundedRect().
        * rendering/mathml/RenderMathMLRadicalOperator.cpp:
        (WebCore::RenderMathMLRadicalOperator::paint):

2015-10-26  Zalan Bujtas  <zalan@apple.com>

        Floating box is misplaced after content change.
        https://bugs.webkit.org/show_bug.cgi?id=150271

        Reviewed by David Hyatt.

        Collapse anonymous block when as the result of a sibling removal only floating siblings are left.

        Test: fast/block/collapse-anon-block-with-float-siblings-only.html

        * rendering/RenderBlock.cpp:
        (WebCore::canCollapseAnonymousBlock):
        (WebCore::canMergeContiguousAnonymousBlocks):
        (WebCore::RenderBlock::collapseAnonymousBoxChild):
        (WebCore::RenderBlock::removeChild):
        (WebCore::canMergeAnonymousBlock): Deleted.
        * rendering/RenderBlock.h:
        * rendering/RenderElement.cpp:
        (WebCore::RenderElement::removeAnonymousWrappersForInlinesIfNecessary):

2015-10-26  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test editing/execCommand/crash-replacing-list-by-list.html
        https://bugs.webkit.org/show_bug.cgi?id=149288
        <rdar://problem/22746310>

        Reviewed by Chris Dumez.

        This is a merge of Blink r170821:
        https://codereview.chromium.org/220233013

        Test: editing/execCommand/crash-replacing-list-by-list.html

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

2015-10-26  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test editing/execCommand/insert-image-changing-visibility-crash.html
        https://bugs.webkit.org/show_bug.cgi?id=150208
        <rdar://problem/23137109>

        Reviewed by Chris Dumez.

        This is a merge from Blink r168502:
        https://codereview.chromium.org/183893018

        Test: editing/execCommand/insert-image-changing-visibility-crash.html

        * editing/ReplaceSelectionCommand.cpp:
        (WebCore::ReplaceSelectionCommand::doApply):
        We should check again the visibility of the inserted position again since
        the replacement might change the visibility.

2015-10-26  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test editing/execCommand/insert-ordered-list-crash.html
        https://bugs.webkit.org/show_bug.cgi?id=150209
        <rdar://problem/23137198>

        Reviewed by Chris Dumez.

        This is a merge from Blink r168006:
        https://codereview.chromium.org/181283002

        Test: editing/execCommand/insert-ordered-list-crash.html

        * editing/InsertListCommand.cpp:
        (WebCore::InsertListCommand::doApply):
        setEndingSelection() might change endingSelection(), we should check again.

2015-10-26  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test editing/execCommand/insert-html-to-document-element-crash.html
        https://bugs.webkit.org/show_bug.cgi?id=149294
        <rdar://problem/22746657>

        Reviewed by Darin Adler.

        This is a merge of Blink r175019:
        https://codereview.chromium.org/300143012

        Test: editing/execCommand/insert-html-to-document-element-crash.html

        * editing/ReplaceSelectionCommand.cpp:
        (WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline):
        check nullable value |element->parentNode()| before using it.

2015-10-26  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test editing/execCommand/indent-nested-blockquotes-crash.html
        https://bugs.webkit.org/show_bug.cgi?id=149291
        <rdar://problem/22746473>

        Reviewed by Darin Adler.

        This is a merge of Blink r172967:
        https://codereview.chromium.org/251723003

        Test: editing/execCommand/indent-nested-blockquotes-crash.html

        * editing/CompositeEditCommand.cpp:
        (WebCore::CompositeEditCommand::insertNodeAfter):

2015-10-26  Brady Eidson  <beidson@apple.com>

        Modern IDB: Backing store objectStores (plumbing for b/150468).
        https://bugs.webkit.org/show_bug.cgi?id=150543

        Reviewed by Alex Christensen.

        No new tests (No change in behavior, plumbing for future testability)

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:

        * Modules/indexeddb/server/IDBBackingStore.h:

        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::addNewObjectStore):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::commit):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::finish):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::isWriting):

        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::createObjectStore):
        (WebCore::IDBServer::MemoryIDBBackingStore::removeObjectStoreForVersionChangeAbort):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:

        * Modules/indexeddb/server/MemoryObjectStore.cpp:
        (WebCore::IDBServer::MemoryObjectStore::create):
        (WebCore::IDBServer::MemoryObjectStore::MemoryObjectStore):
        (WebCore::IDBServer::MemoryObjectStore::~MemoryObjectStore):
        (WebCore::IDBServer::MemoryObjectStore::writeTransactionStarted):
        (WebCore::IDBServer::MemoryObjectStore::writeTransactionFinished):
        * Modules/indexeddb/server/MemoryObjectStore.h:
        (WebCore::IDBServer::MemoryObjectStore::info):

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::createObjectStore):

        * Modules/indexeddb/shared/IDBError.cpp:
        (WebCore::idbErrorName):
        (WebCore::idbErrorDescription):
        * Modules/indexeddb/shared/IDBError.h:

2015-10-26  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test editing/execCommand/indent-inline-box-crash.html
        https://bugs.webkit.org/show_bug.cgi?id=149290
        <rdar://problem/22746435>

        Reviewed by Alex Christensen.

        This is a merge of Blink r174952:
        https://codereview.chromium.org/297203004

        Test: editing/execCommand/indent-inline-box-crash.html

        * editing/IndentOutdentCommand.cpp:
        (WebCore::IndentOutdentCommand::tryIndentingAsListItem):

2015-10-26  Jiewen Tan  <jiewen_tan@apple.com>

        Null dereference loading Blink layout test editing/execCommand/indent-no-visible-contents-crash.html
        https://bugs.webkit.org/show_bug.cgi?id=149292
        <rdar://problem/22746530>

        Reviewed by Alex Christensen.

        This is a merge of Blink r176735:
        https://codereview.chromium.org/349143002

        Test: editing/execCommand/indent-no-visible-contents-crash.html

        * editing/CompositeEditCommand.cpp:
        (WebCore::CompositeEditCommand::moveParagraphWithClones):
        Sometimes callers of this method will pass null startOfParagraphToMove || endOfParagraphToMove,
        hence check them before proceeding.

2015-10-26  Anders Carlsson  <andersca@apple.com>

        Remove dead context menu code
        https://bugs.webkit.org/show_bug.cgi?id=150567

        Reviewed by Tim Horton.

        * loader/EmptyClients.h:
        * page/ContextMenuClient.h:
        * page/ContextMenuController.cpp:
        (WebCore::ContextMenuController::showContextMenu): Deleted.

2015-10-26  Simon Fraser  <simon.fraser@apple.com>

        Implement 'round' and 'space' values for border-image
        https://bugs.webkit.org/show_bug.cgi?id=14185

        Reviewed by Tim Horton.
        
        Add support for "round" and "space" values for border-image-repeat.
        Following "stretch" and "repeat", the code is added to Image::drawTiled().
        
        For "round", we compute an integral number of copies of the image that fit,
        and then adjust the tile scale.
        
        For "space", we also compute an integral number N of copies that will fit,
        and then divide the remaining space amongst N+1 gaps, adjusting the tiling
        phase so that with an even number of images, a gap is centered.

        Tests: fast/borders/border-image-round.html
               fast/borders/border-image-space.html

        * platform/graphics/Image.cpp:
        (WebCore::Image::drawTiled):
        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::GraphicsContext::drawPattern):

2015-10-26  Simon Fraser  <simon.fraser@apple.com>

        Incorrect repeated background-size behavior in keyframes
        https://bugs.webkit.org/show_bug.cgi?id=150309

        Reviewed by Zalan Bujtas.
        
        After computing the style for a keyframe, we failed to propagate unset
        fill-layer properties to all layers, which caused incorrect behavior when
        there were multiple background images, but only one value on a background
        property in the keyframes.
        
        Fix by calling adjustRenderStyle() on keyframe styles, which invokes
        style.adjustBackgroundLayers() which fixes the bug.

        Test: animations/multiple-backgrounds.html

        * css/StyleResolver.cpp:
        (WebCore::StyleResolver::styleForKeyframe):

2015-10-26  Chris Dumez  <cdumez@apple.com>

        Indexing an object with an integer that is not a supported property index should not call the named property getter
        https://bugs.webkit.org/show_bug.cgi?id=148871
        <rdar://problem/22589952>

        Reviewed by Darin Adler.

        Indexing an object with an integer that is not a supported property
        index should not call the named property getter, as per the Web IDL
        specification:
        https://heycam.github.io/webidl/#idl-indexed-properties (Note in blue)

        Firefox and Chrome both already behave according to the specification
        here so this patch aligns our behavior with other browsers as well.

        No new tests, already covered by existing test.

        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateGetOwnPropertySlotBody):
        (GenerateImplementation):
        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
        (WebCore::JSTestEventTarget::getOwnPropertySlot):
        (WebCore::JSTestEventTarget::getOwnPropertySlotByIndex): Deleted.
        (WebCore::jsTestEventTargetConstructor): Deleted.

2015-10-26  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Implement abort method on writable streams
        https://bugs.webkit.org/show_bug.cgi?id=150444

        Reviewed by Darin Adler.

        Abort method on writable streams implemented according to the spec.

        Current test set suffices. Expectations are updated accordingly.

        * Modules/streams/StreamInternals.js:
        (promiseInvokeOrFallbackOrNoop): Implemented according to the spec.
        * Modules/streams/WritableStream.js:
        (abort): Implemented according to the spec.

2015-10-25  Hunseop Jeong  <hs85.jeong@samsung.com>

        Use modern for-loops in WebCore/editing.
        https://bugs.webkit.org/show_bug.cgi?id=150354

        Reviewed by Darin Adler.

        No new tests because there is no behavior change.

        * editing/AlternativeTextController.cpp:
        (WebCore::AlternativeTextController::applyAlternativeTextToRange):
        (WebCore::AlternativeTextController::applyAutocorrectionBeforeTypingIfAppropriate):
        (WebCore::AlternativeTextController::rootViewRectForRange):
        (WebCore::AlternativeTextController::markCorrection):
        * editing/ApplyStyleCommand.cpp:
        (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
        (WebCore::dummySpanAncestorForNode):
        (WebCore::ApplyStyleCommand::cleanupUnstyledAppleStyleSpans):
        (WebCore::ApplyStyleCommand::splitAncestorsWithUnicodeBidi):
        (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange):
        (WebCore::ApplyStyleCommand::removeImplicitlyStyledElement):
        (WebCore::ApplyStyleCommand::pushDownInlineStyleAroundNode):
        (WebCore::ApplyStyleCommand::joinChildTextNodes):
        * editing/CompositeEditCommand.cpp:
        (WebCore::EditCommandComposition::reapply):
        (WebCore::EditCommandComposition::getNodesInCommand):
        (WebCore::CompositeEditCommand::removeChildrenInRange):
        (WebCore::CompositeEditCommand::removeNode):
        (WebCore::copyMarkers):
        (WebCore::CompositeEditCommand::replaceTextInNodePreservingMarkers):
        (WebCore::CompositeEditCommand::deleteInsignificantText):
        * editing/DictationCommand.cpp:
        (WebCore::DictationMarkerSupplier::addMarkersToTextNode):
        (WebCore::DictationCommand::collectDictationAlternativesInRange):
        * editing/EditingStyle.cpp:
        (WebCore::isEditingProperty):
        (WebCore::EditingStyle::extractConflictingImplicitStyleOfAttributes):
        (WebCore::EditingStyle::elementIsStyledSpanOrHTMLEquivalent):
        (WebCore::EditingStyle::mergeInlineAndImplicitStyleOfElement):
        (WebCore::styleFromMatchedRulesForElement):
        (WebCore::diffTextDecorations):
        * editing/Editor.cpp:
        (WebCore::Editor::setComposition):
        (WebCore::Editor::markAndReplaceFor):
        * editing/EditorCommand.cpp:
        (WebCore::createCommandMap):
        * editing/MarkupAccumulator.cpp:
        (WebCore::MarkupAccumulator::totalLength):
        * editing/MergeIdenticalElementsCommand.cpp:
        (WebCore::MergeIdenticalElementsCommand::doApply):
        (WebCore::MergeIdenticalElementsCommand::doUnapply):
        * editing/ReplaceSelectionCommand.cpp:
        (WebCore::ReplacementFragment::removeUnrenderedNodes):
        (WebCore::ReplacementFragment::removeInterchangeNodes):
        (WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline):
        (WebCore::removeHeadContents):
        * editing/SpellChecker.cpp:
        (WebCore::SpellChecker::~SpellChecker):
        (WebCore::SpellChecker::client):
        (WebCore::SpellChecker::enqueueRequest):
        * editing/SplitElementCommand.cpp:
        (WebCore::SplitElementCommand::executeApply):
        (WebCore::SplitElementCommand::doApply):
        (WebCore::SplitElementCommand::doUnapply):
        * editing/TextCheckingHelper.cpp:
        (WebCore::TextCheckingHelper::findFirstMisspellingOrBadGrammar):
        (WebCore::TextCheckingHelper::guessesForMisspelledOrUngrammaticalRange):
        * editing/WrapContentsInDummySpanCommand.cpp:
        (WebCore::WrapContentsInDummySpanCommand::executeApply):
        (WebCore::WrapContentsInDummySpanCommand::doUnapply):
        * editing/ios/EditorIOS.mm:
        (WebCore::Editor::createFragmentAndAddResources):
        * editing/mac/EditorMac.mm:
        (WebCore::Editor::WebContentReader::readFilenames):
        (WebCore::Editor::createFragmentAndAddResources):
        * editing/markup.cpp:
        (WebCore::completeURLs):

2015-10-25  Simon Fraser  <simon.fraser@apple.com>

        Support bezier paths in clip-path property
        https://bugs.webkit.org/show_bug.cgi?id=149996

        Reviewed by Darin Adler.
        
        Support path() in the -webkit-clip-path property, as specified in
        https://drafts.csswg.org/css-shapes-2/#supported-basic-shapes
        
        Added BasicShapePath and CSSBasicShapePath, which both represent the path
        as a SVGPathByteStream and wind rule.
        
        Make BasicShape::canBlend() a virtual function, and implement it on each subclass.
        Make various BasicShape subclass function overrides private, other than windRule()
        wich is called on derived classes in a few places.
        
        Add SVGPathBlender::canBlendPaths() which returns true if the given paths can be
        interpolated. Uses the same logic as blendAnimatedPath(), without doing any interpolation.
        
        RenderElement::createsGroup() is fixed to have clip-path trigger a group,
        which fixes rendering of clip-path with a descendant compositing layer.

        Tests: compositing/masks/clip-path-composited-descendent.html
               css3/masking/clip-path-with-path.html
               transitions/clip-path-path-transitions.html

        * css/BasicShapeFunctions.cpp:
        (WebCore::valueForBasicShape):
        (WebCore::basicShapeForValue):
        * css/CSSBasicShapes.cpp:
        (WebCore::CSSBasicShapePath::CSSBasicShapePath):
        (WebCore::CSSBasicShapePath::pathData):
        (WebCore::buildPathString):
        (WebCore::CSSBasicShapePath::cssText):
        (WebCore::CSSBasicShapePath::equals):
        * css/CSSBasicShapes.h:
        * css/CSSParser.cpp:
        (WebCore::CSSParser::parseBasicShapePath):
        (WebCore::CSSParser::parseBasicShape):
        * css/CSSParser.h:
        * rendering/RenderElement.h:
        (WebCore::RenderElement::createsGroup):
        * rendering/style/BasicShapes.cpp:
        (WebCore::BasicShapeCircle::canBlend):
        (WebCore::BasicShapeEllipse::canBlend):
        (WebCore::BasicShapePolygon::canBlend):
        (WebCore::BasicShapePath::BasicShapePath):
        (WebCore::BasicShapePath::path):
        (WebCore::BasicShapePath::operator==):
        (WebCore::BasicShapePath::canBlend):
        (WebCore::BasicShapePath::blend):
        (WebCore::BasicShapeInset::canBlend):
        (WebCore::BasicShape::canBlend): Deleted.
        * rendering/style/BasicShapes.h:
        * svg/SVGPathBlender.cpp:
        (WebCore::SVGPathBlender::addAnimatedPath):
        (WebCore::SVGPathBlender::blendAnimatedPath):
        (WebCore::SVGPathBlender::canBlendPaths):
        (WebCore::SVGPathBlender::SVGPathBlender):
        (WebCore::SVGPathBlender::blendMoveToSegment):
        (WebCore::SVGPathBlender::blendLineToSegment):
        (WebCore::SVGPathBlender::blendLineToHorizontalSegment):
        (WebCore::SVGPathBlender::blendLineToVerticalSegment):
        (WebCore::SVGPathBlender::blendCurveToCubicSegment):
        (WebCore::SVGPathBlender::blendCurveToCubicSmoothSegment):
        (WebCore::SVGPathBlender::blendCurveToQuadraticSegment):
        (WebCore::SVGPathBlender::blendCurveToQuadraticSmoothSegment):
        (WebCore::SVGPathBlender::blendArcToSegment):
        * svg/SVGPathBlender.h:
        * svg/SVGPathByteStream.h:
        (WebCore::SVGPathByteStream::operator==):
        * svg/SVGPathUtilities.cpp:
        (WebCore::canBlendSVGPathByteStreams):
        * svg/SVGPathUtilities.h:

2015-10-25  Gwang Yoon Hwang  <yoon@igalia.com>

        [TexMap] Fix a misused flag for GstGL
        https://bugs.webkit.org/show_bug.cgi?id=150545

        Reviewed by Žan Doberšek.

        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
        (WebCore::MediaPlayerPrivateGStreamerBase::paintToTextureMapper):
        We should pass TextureMapperGL::Flags to the TextureMapperGL::drawTexture instead of
        BitmapTexture::Flags.

2015-10-25  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Use ImplementedAs for MediaDevices.getUserMediaFromJS
        https://bugs.webkit.org/show_bug.cgi?id=150439

        Reviewed by Darin Adler.

        No change in behavior.

        * Modules/mediastream/MediaDevices.h: Removing getUserMediaFromJS C++ function.
        * Modules/mediastream/MediaDevices.idl: Marking getUserMediaFromJS as ImplementedAS=getUserMedia

2015-10-24  Gwang Yoon Hwang  <yoon@igalia.com>

        Remove setApplyDeviceScaleFactorInCompositor
        https://bugs.webkit.org/show_bug.cgi?id=150538

        Reviewed by Tim Horton.

        It was used to support the device scale factor for chromium port and blackberry
        port. But it was removed quite a while ago.

        * page/Settings.in:
        applyDeviceScaleFactorInCompositor: Deleted
        * platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:
        (WebCore::CompositingCoordinator::CompositingCoordinator): Remove uses
        of applyDeviceScaleFactorInCompositor.

2015-10-24  Tim Horton  <timothy_horton@apple.com>

        Expose more information about the exception in WKErrorJavaScriptExceptionOccurred errors
        https://bugs.webkit.org/show_bug.cgi?id=150525

        Reviewed by Darin Adler.

        Adjusted API test to cover this: WKWebView.EvaluateJavaScriptErrorCases.

        * bindings/js/JSDOMBinding.cpp:
        (WebCore::reportException):
        * bindings/js/JSDOMBinding.h:
        Fill in the given struct with computed exception data if it was given.

        * bindings/js/ScriptController.cpp:
        (WebCore::ScriptController::evaluateInWorld):
        (WebCore::ScriptController::evaluate):
        (WebCore::ScriptController::executeScript):
        * bindings/js/ScriptController.h:
        Plumb aforementioned struct through ScriptController.

2015-10-24  Gwang Yoon Hwang  <yoon@igalia.com>

        [TexMap] Clean up BitmapTexture and BitmapTextureGL.
        https://bugs.webkit.org/show_bug.cgi?id=143298

        Reviewed by Žan Doberšek.

        No new tests, this is just a refactor.

        * platform/graphics/texmap/BitmapTexture.h:
        (WebCore::BitmapTexture::canReuseWith): Deleted.
        Reuseability of a BitmapTexture is only decided by its size.
        We can use size() instead of this method.

        * platform/graphics/texmap/BitmapTextureGL.h:
        (WebCore::driverSupportsExternalTextureBGRA): Deleted.
        We do not have to check a suitable texture format in every
        update/reset. It is enough to store the formats in construction time
        and reuse them.

2015-10-24  Simon Fraser  <simon.fraser@apple.com>

        REGRESSION (r187121): Delayed instantaneous animations not honouring ' forwards' fill-mode
        https://bugs.webkit.org/show_bug.cgi?id=150326

        Reviewed by Darin Adler.
        
        With a zero-duration, delayed fill-forwards animation, we'd end up trying
        to interpolate between the last and first keyframes, and picking the first
        because AnimationBase::progress() had a special case for zero duration. Removing
        this check fixes the bug.

        Test: animations/fill-mode-forwards-zero-duration.html

        * page/animation/AnimationBase.cpp:
        (WebCore::AnimationBase::progress):

2015-10-23  Chris Dumez  <cdumez@apple.com>

        RadioNodeList should be exposed on Window
        https://bugs.webkit.org/show_bug.cgi?id=148869
        <rdar://problem/22589828>

        Reviewed by Ryosuke Niwa.

        RadioNodeList should be exposed on on the global Window object, as per
        the HTML specification:
        https://html.spec.whatwg.org/multipage/infrastructure.html#radionodelist

        This patch addresses the issue, and aligns our behavior with Firefox
        and Chrome.

        No new tests, already covered by existing tests.

        * html/RadioNodeList.idl:

2015-10-23  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Remove unused ScrollLayer Timeline EventType
        https://bugs.webkit.org/show_bug.cgi?id=150518

        Reviewed by Timothy Hatcher.

        * inspector/InspectorInstrumentation.cpp:
        (WebCore::InspectorInstrumentation::willScrollLayerImpl): Deleted.
        (WebCore::InspectorInstrumentation::didScrollLayerImpl): Deleted.
        * inspector/InspectorInstrumentation.h:
        (WebCore::InspectorInstrumentation::willScrollLayer): Deleted.
        (WebCore::InspectorInstrumentation::didScrollLayer): Deleted.
        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::InspectorTimelineAgent::willScroll): Deleted.
        (WebCore::InspectorTimelineAgent::didScroll): Deleted.
        * inspector/InspectorTimelineAgent.h:
        * rendering/RenderLayer.cpp:
        (WebCore::RenderLayer::scrollTo): Deleted.

2015-10-23  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Clean up InspectorInstrumentation includes
        https://bugs.webkit.org/show_bug.cgi?id=150523

        Reviewed by Timothy Hatcher.

        * Modules/webdatabase/DatabaseManager.cpp:
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * WebCore.xcodeproj/project.pbxproj:
        * css/MediaQueryEvaluator.cpp:
        * dom/EventDispatcher.cpp:
        * dom/ExtensionStyleSheets.cpp:
        * inspector/InspectorController.h:
        * inspector/InspectorDOMDebuggerAgent.cpp:
        * inspector/InspectorDatabaseInstrumentation.h: Removed.
        * inspector/InspectorInstrumentation.h:
        (WebCore::InspectorInstrumentation::didOpenDatabase):
        * inspector/InspectorPageAgent.cpp:
        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::toProtocol): Deleted.
        * loader/ResourceLoadScheduler.cpp:
        * loader/mac/ResourceLoaderMac.mm:
        * page/Screen.cpp:
        * rendering/TextAutosizer.cpp:
        * testing/Internals.cpp:
        (WebCore::Internals::consoleMessageArgumentCounts): Deleted.
        * testing/Internals.h:
        * testing/Internals.idl:
        * workers/AbstractWorker.cpp:

2015-10-23  Simon Fraser  <simon.fraser@apple.com>

        Avoid SVG-induced layouts inside Element::absoluteEventBounds()
        https://bugs.webkit.org/show_bug.cgi?id=150516

        Reviewed by Zalan Bujtas.

        Speculative fix for a crash under RenderObject::localToContainerQuad() when
        computing the wheel event handler region, which uses Element::absoluteEventHandlerBounds().
        Element::absoluteEventBounds() was calling SVGElement::getBoundingBox() in a way
        that could trigger a layout.

        * dom/Element.cpp:
        (WebCore::Element::absoluteEventBounds):

2015-10-23  Alex Christensen  <achristensen@webkit.org>

        Progress towards CMake on Mac
        https://bugs.webkit.org/show_bug.cgi?id=150517

        Reviewed by Tim Horton.

        * PlatformMac.cmake:

2015-10-23  Per Arne Vollan  <peavo@outlook.com>

        [WinCairo] Improve test results for fast layouttests.
        https://bugs.webkit.org/show_bug.cgi?id=150464

        Reviewed by Alex Christensen.

        Disable the Mac ascent hack for WinCairo.

        * platform/graphics/win/SimpleFontDataCairoWin.cpp:
        (WebCore::Font::platformInit):

2015-10-23  Simon Fraser  <simon.fraser@apple.com>

        REGRESSION (r187121): Multiple-keyframe animations not honouring ' forwards' fill-mode
        https://bugs.webkit.org/show_bug.cgi?id=150328

        Reviewed by Dean Jackson.
        
        AnimationBase::getElapsedTime() for a finished animation would return 1 (a progress),
        rather than a time value as the caller expects. Fix it to return the total duration
        if the animation has finished. This fixes the bug.
        
        Change CompositeAnimation::pauseAnimationAtTime() to be more permissive, allowing
        testing of filling-forwards animations with the pause API.

        Test: animations/fill-forwards-end-state.html

        * page/animation/AnimationBase.cpp:
        (WebCore::AnimationBase::getElapsedTime):
        * page/animation/CompositeAnimation.cpp:
        (WebCore::CompositeAnimation::pauseAnimationAtTime):

2015-10-23  Chris Dumez  <cdumez@apple.com>

        A label element not in a document should not label an element in a document
        https://bugs.webkit.org/show_bug.cgi?id=148863
        <rdar://problem/22589300>

        Reviewed by Ryosuke Niwa.

        As per the HTML specification, a label element's 'for' attribute may be
        specified to indicate a form control with which the caption is to be
        associated. If the attribute is specified, the attribute's value must
        be the ID of a labelable element in the same Document as the label
        element:
        https://html.spec.whatwg.org/multipage/forms.html#attr-label-for

        However, our code was failing to check if the label element was actually
        in the document before calling document.getElementById(). In such case,
        we would potentially return a labelable Element that is not in the same
        document as the label Element. This patch fixes the problem.

        The new behavior is consistent with Firefox.

        No new tests, already covered by existing test.

        * html/HTMLLabelElement.cpp:
        (WebCore::HTMLLabelElement::control):

2015-10-23  Antoine Quint  <graouts@apple.com>

        Support for SVG `beginEvent` event and `onbegin` attribute
        https://bugs.webkit.org/show_bug.cgi?id=150442

        Reviewed by Dean Jackson.

        Add support for the SVG `beginEvent` event, which is fired as an SVG timing element enters its active interval.
        Also add support for the SVG `onbegin` attribute which allows the definition of a JS event listener declaratively
        for the SVG `beginEvent` event.

        Tests: svg/animations/begin-event-attribute.svg
               svg/animations/begin-event-script.svg
               svg/animations/begin-event-syncbase.svg

        * dom/EventNames.h:
        * svg/animation/SVGSMILElement.cpp:
        (WebCore::smilBeginEventSender):
        (WebCore::smilEndEventSender):
        (WebCore::SVGSMILElement::~SVGSMILElement):
        (WebCore::SVGSMILElement::parseAttribute):
        (WebCore::SVGSMILElement::progress):
        (WebCore::SVGSMILElement::dispatchPendingEvent):
        * svg/svgattrs.in:

2015-10-23  Hyemi Shin  <hyemi.sin@samsung.com>

        ConvolverNode.buffer must have same sample-rate as the AudioContext 
        https://bugs.webkit.org/show_bug.cgi?id=150385 

        Reviewed by Chris Dumez.

        ConvolverNode.buffer must be of the same sample-rate as the AudioContext
        or an NOT_SUPPORTED_ERR exception MUST be thrown.

        Test : webaudio/convolver-setBuffer-different-samplerate.html

        * Modules/webaudio/ConvolverNode.cpp:
        (WebCore::ConvolverNode::setBuffer):
        * Modules/webaudio/ConvolverNode.h:
        * Modules/webaudio/ConvolverNode.idl:

2015-10-22  Myles C. Maxfield  <mmaxfield@apple.com>

        [OS X] Migrate GraphicsContext::drawLineForDocumentMarker() away from LocalCurrentGraphicsContext
        https://bugs.webkit.org/show_bug.cgi?id=150483

        Reviewed by Simon Fraser.

        LocalCurrentGraphicsContext is an ugly hack to work around the problem that many NS* functions
        operate on the current context rather than a context passed as an argument. This patch
        migrates from NSRectFillUsingOperation() which has this behavior to CGContextDrawTiledImage()
        which performs the same operation but with a passed-in CGContextRef. An added benefit is that
        we don't have to mess around with pattern-based NSColors. 

        No new tests because there is no behavior change.

        * platform/graphics/mac/GraphicsContextMac.mm:
        (WebCore::findImage):
        (WebCore::GraphicsContext::updateDocumentMarkerResources):
        (WebCore::GraphicsContext::drawLineForDocumentMarker):
        (WebCore::makePatternColor): Deleted.

2015-10-22  Sam Weinig  <sam@webkit.org>

        Navigations on the same host (but with different schemes and ports) should not trigger universal links
        <rdar://problem/22811325>
        https://bugs.webkit.org/show_bug.cgi?id=150481

        Reviewed by Dan Bernstein.

        Add new helper which efficiently compares the hosts of two URLs.

        * platform/URL.cpp:
        (WebCore::hostsAreEqual):
        * platform/URL.h:

2015-10-22  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Remove unused Timeline GCEvent Record type
        https://bugs.webkit.org/show_bug.cgi?id=150477

        Reviewed by Timothy Hatcher.

        This event is dispatched through the Heap domain, not Timelines.

        * inspector/TimelineRecordFactory.cpp:
        (WebCore::TimelineRecordFactory::createGCEventData): Deleted.
        * inspector/TimelineRecordFactory.h:

2015-10-22  Gordon Sheridan  <gordon_sheridan@apple.com>

        Fix build for clang-700.0.59.5 by replacing deprecated calls to convert points between screen and window coordinates for Mac.
        https://bugs.webkit.org/show_bug.cgi?id=150379

        Reviewed by Andy Estes.

        Provide WAKWindow versions of the non-deprecated methods for converting an NSRect between
        window and screen coordinates, which replace the deprecated methods that operated on an NSPoint.

        * platform/ios/wak/WAKWindow.h:
        * platform/ios/wak/WAKWindow.mm:
        (-[WAKWindow convertRectToScreen:]): Added.
        (-[WAKWindow convertRectFromScreen:]): Added.

2015-10-22  Alex Christensen  <achristensen@webkit.org>

        Fix Mac CMake build after r191433.

        * PlatformMac.cmake:
        Use CMakeLists.txt to generate UserAgentScripts.h and cpp.

2015-10-22  Daniel Bates  <dabates@apple.com>

        Unreviewed, rolling out r191113.

        Rollout r144451 since it regressed the visibility of the
        search cancel button when a search field is empty or showing
        placeholder text. Further investigation is needed.

        Reverted changeset:

        "[iOS] DOM click event may not be dispatched when page has
        :active style and <input type="search">"
        https://bugs.webkit.org/show_bug.cgi?id=144451
        http://trac.webkit.org/changeset/191113

2015-10-22  Simon Fraser  <simon.fraser@apple.com>

        Add ways to log to log channels via a functional syntax, and via a TextStream
        https://bugs.webkit.org/show_bug.cgi?id=150472
 
        Reviewed by Tim Horton.
 
        Make it possible to write to a WTFLogChannel with a std::function that returns
        a const char*, and with stream syntax.
 
        Enhance TextStream to allow it to generate single-line output.

        * platform/Logging.cpp:
        (WebCore::logFunctionResult):
        * platform/Logging.h:
        * platform/text/TextStream.cpp:
        (WebCore::TextStream::startGroup):
        (WebCore::TextStream::endGroup):
        (WebCore::TextStream::nextLine):
        (WebCore::TextStream::writeIndent):
        * platform/text/TextStream.h:
        (WebCore::TextStream::TextStream):

2015-10-22  Alex Christensen  <achristensen@webkit.org>

        Progress towards CMake on Mac
        https://bugs.webkit.org/show_bug.cgi?id=150466

        Reviewed by Chris Dumez.

        * PlatformMac.cmake:
        * crypto/mac/SerializedCryptoKeyWrapMac.mm:
        (WebCore::createAndStoreMasterKey):
        * page/mac/WheelEventDeltaFilterMac.mm:
        * platform/spi/mac/NSImmediateActionGestureRecognizerSPI.h:

2015-10-22  Myles C. Maxfield  <mmaxfield@apple.com>

        [Cocoa] Migrate WKSetPatternPhaseInUserSpace() and WKGetUserToBaseCTM() from WKSI
        https://bugs.webkit.org/show_bug.cgi?id=150460

        Reviewed by Tim Horton.

        No reason to use WKSI for these calls.

        No new tests because there is no behavior change.

        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::GraphicsContext::applyStrokePattern):
        (WebCore::GraphicsContext::applyFillPattern):
        (WebCore::GraphicsContext::setPlatformShadow):
        * platform/graphics/cg/GraphicsContextCG.h:
        (WebCore::getUserToBaseCTM):
        * platform/graphics/cg/ImageBufferCG.cpp:
        (WebCore::ImageBuffer::putByteArray):
        * platform/graphics/mac/GraphicsContextMac.mm:
        (WebCore::setPatternPhaseInUserSpace):
        (WebCore::GraphicsContext::drawLineForDocumentMarker):
        * platform/ios/WebCoreSystemInterfaceIOS.mm:
        * platform/mac/WebCoreSystemInterface.h:
        * platform/mac/WebCoreSystemInterface.mm:

2015-10-22  Brady Eidson  <beidson@apple.com>

        Modern IDB: Basic createObjectStore implementation.
        https://bugs.webkit.org/show_bug.cgi?id=150455

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/createobjectstore-basic.html
               storage/indexeddb/modern/createobjectstore-failures.html

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::createObjectStore):
        (WebCore::IDBClient::IDBConnectionToServer::didCreateObjectStore):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:
        
        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::objectStoreNames):
        (WebCore::IDBClient::IDBDatabase::createObjectStore):
        (WebCore::IDBClient::IDBDatabase::didAbortTransaction):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:
        (WebCore::IDBClient::IDBDatabase::serverConnection):
        
        * Modules/indexeddb/client/IDBObjectStoreImpl.cpp: Added.
        (WebCore::IDBClient::IDBObjectStore::create):
        (WebCore::IDBClient::IDBObjectStore::IDBObjectStore):
        (WebCore::IDBClient::IDBObjectStore::~IDBObjectStore):
        (WebCore::IDBClient::IDBObjectStore::id):
        (WebCore::IDBClient::IDBObjectStore::name):
        (WebCore::IDBClient::IDBObjectStore::keyPathAny):
        (WebCore::IDBClient::IDBObjectStore::keyPath):
        (WebCore::IDBClient::IDBObjectStore::indexNames):
        (WebCore::IDBClient::IDBObjectStore::transaction):
        (WebCore::IDBClient::IDBObjectStore::autoIncrement):
        (WebCore::IDBClient::IDBObjectStore::add):
        (WebCore::IDBClient::IDBObjectStore::put):
        (WebCore::IDBClient::IDBObjectStore::openCursor):
        (WebCore::IDBClient::IDBObjectStore::get):
        (WebCore::IDBClient::IDBObjectStore::deleteFunction):
        (WebCore::IDBClient::IDBObjectStore::clear):
        (WebCore::IDBClient::IDBObjectStore::createIndex):
        (WebCore::IDBClient::IDBObjectStore::index):
        (WebCore::IDBClient::IDBObjectStore::deleteIndex):
        (WebCore::IDBClient::IDBObjectStore::count):
        * Modules/indexeddb/client/IDBObjectStoreImpl.h: Added.

        * Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBOpenDBRequest::requestCompleted):

        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::serverConnection):
        (WebCore::IDBClient::IDBTransaction::objectStore):
        (WebCore::IDBClient::IDBTransaction::scheduleOperation):
        (WebCore::IDBClient::IDBTransaction::operationTimerFired):
        (WebCore::IDBClient::IDBTransaction::finishAbortOrCommit):
        (WebCore::IDBClient::IDBTransaction::didAbort):
        (WebCore::IDBClient::IDBTransaction::didCommit):
        (WebCore::IDBClient::IDBTransaction::createObjectStore):
        (WebCore::IDBClient::IDBTransaction::createObjectStoreOnServer):
        (WebCore::IDBClient::IDBTransaction::didCreateObjectStoreOnServer):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        (WebCore::IDBClient::IDBTransaction::originalDatabaseInfo):
        (WebCore::IDBClient::IDBTransaction::isVersionChange):
        
        * Modules/indexeddb/client/TransactionOperation.h: Added.
        (WebCore::IDBClient::TransactionOperation::perform):
        (WebCore::IDBClient::TransactionOperation::completed):
        (WebCore::IDBClient::TransactionOperation::identifier):
        (WebCore::IDBClient::TransactionOperation::transactionIdentifier):
        (WebCore::IDBClient::TransactionOperation::TransactionOperation):
        (WebCore::IDBClient::createTransactionOperation):
        
        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didCreateObjectStore):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:
        
        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::createObjectStore):
        * Modules/indexeddb/server/IDBServer.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::createObjectStore):
        (WebCore::IDBServer::UniqueIDBDatabase::performCreateObjectStore):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformCreateObjectStore):
        (WebCore::IDBServer::UniqueIDBDatabase::performAbortTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformAbortTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::abortTransaction): Deleted.
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::didCreateObjectStore):
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::isVersionChange):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::createObjectStore):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
        
        * Modules/indexeddb/shared/IDBDatabaseInfo.cpp:
        (WebCore::IDBDatabaseInfo::hasObjectStore):
        (WebCore::IDBDatabaseInfo::createNewObjectStore):
        (WebCore::IDBDatabaseInfo::addExistingObjectStore):
        (WebCore::IDBDatabaseInfo::objectStoreNames):
        * Modules/indexeddb/shared/IDBDatabaseInfo.h:
        
        * Modules/indexeddb/shared/IDBObjectStoreInfo.cpp: Copied from Source/WebCore/Modules/indexeddb/shared/IDBDatabaseInfo.cpp.
        (WebCore::IDBObjectStoreInfo::IDBObjectStoreInfo):
        (WebCore::IDBObjectStoreInfo::isolatedCopy):
        * Modules/indexeddb/shared/IDBObjectStoreInfo.h: Copied from Source/WebCore/Modules/indexeddb/shared/IDBDatabaseInfo.h.
        (WebCore::IDBObjectStoreInfo::identifier):
        (WebCore::IDBObjectStoreInfo::name):
        (WebCore::IDBObjectStoreInfo::keyPath):
        (WebCore::IDBObjectStoreInfo::autoIncrement):

        * Modules/indexeddb/shared/IDBRequestData.cpp:
        (WebCore::IDBRequestData::IDBRequestData):
        (WebCore::IDBRequestData::requestIdentifier):
        (WebCore::IDBRequestData::transactionIdentifier):
        * Modules/indexeddb/shared/IDBRequestData.h:
        (WebCore::IDBRequestData::databaseIdentifier):
        (WebCore::IDBRequestData::requestIdentifier): Deleted.

        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::IDBResultData):
        (WebCore::IDBResultData::createObjectStoreSuccess):
        * Modules/indexeddb/shared/IDBResultData.h:

        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didCreateObjectStore):
        (WebCore::InProcessIDBServer::createObjectStore):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

        * platform/CrossThreadCopier.cpp:
        (WebCore::IDBObjectStoreInfo>::copy):
        * platform/CrossThreadCopier.h:

2015-10-22  Alex Christensen  <achristensen@webkit.org>

        Initial NSURLSession WebResourceLoader implementation
        https://bugs.webkit.org/show_bug.cgi?id=150355

        Reviewed by Antti Koivisto.

        * platform/network/cf/AuthenticationChallenge.h:
        (WebCore::AuthenticationChallenge::AuthenticationChallenge): Export constructor for use in WebKit2.

2015-10-22  Frederic Wang  <fred.wang@free.fr>

        [Mac] Add support for the USE_TYPO_METRICS flag
        https://bugs.webkit.org/show_bug.cgi?id=150394

        Reviewed by Myles C. Maxfield.

        Make the Cocoa backend use the typo metrics for fonts with a MATH table when the OS/2 USE_TYPO_METRICS flag is set.

        No new tests because this is already tested by fonts/use-typo-metrics-1.html

        * platform/graphics/cocoa/FontCocoa.mm:
        (WebCore::fontHasMathTable): Add a function to verify whether a font has a MATH table.
        (WebCore::Font::platformInit): Verify whether the OS/2 USE_TYPO_METRICS flag is set and use the typo metrics if that is the case.

2015-10-22  Wenson Hsieh  <wenson_hsieh@apple.com>

        Implement touch-action: manipulation; for iOS
        https://bugs.webkit.org/show_bug.cgi?id=149854
        <rdar://problem/23017145>

        Reviewed by Benjamin Poulain.

        Implements the manipulation value for the CSS property touch-action. Adds support for
        parsing the touch-action property and two of its values: auto and manipulation.

        Tests: css3/touch-action/touch-action-computed-style.html
               css3/touch-action/touch-action-manipulation-fast-clicks.html
               css3/touch-action/touch-action-parsing.html

        * css/CSSComputedStyleDeclaration.cpp:
        (WebCore::ComputedStyleExtractor::propertyValue):
        * css/CSSParser.cpp:
        (WebCore::isValidKeywordPropertyAndValue):
        (WebCore::isKeywordPropertyID):
        (WebCore::CSSParser::parseValue):
        * css/CSSPrimitiveValueMappings.h:
        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
        (WebCore::CSSPrimitiveValue::operator TouchAction):
        * css/CSSPropertyNames.in:
        * css/CSSValueKeywords.in:
        * dom/Element.cpp:
        (WebCore::Element::allowsDoubleTapGesture): Here, we determine whether an element that resulted from
            hit-testing a touch should allow double-tap gestures. To do this, we walk up the element's parents,
            stopping when we detect an element that disallows double tap gestures by having a touch-action other
            than auto or by hitting the root node.
        * dom/Element.h:
        * dom/Node.h:
        (WebCore::Node::allowsDoubleTapGesture):
        * rendering/style/RenderStyle.h:
        * rendering/style/RenderStyleConstants.h:
        * rendering/style/StyleRareNonInheritedData.cpp:
        (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
        (WebCore::StyleRareNonInheritedData::operator==):
        * rendering/style/StyleRareNonInheritedData.h:

2015-10-22  Ryosuke Niwa  <rniwa@webkit.org>

        REGRESSION (r181972): Scroll position changes to top of youtube page when switching tabs
        https://bugs.webkit.org/show_bug.cgi?id=150428

        Reviewed by Antti Koivisto.

        The bug was caused by updateFocusAppearance in WebPage::restoreSelectionInFocusedEditableElement
        revealing the focused element which was added in r181972. Fixed the bug by adding an option to
        suppress this behavior here.

        * dom/Document.cpp:
        (WebCore::Document::Document):
        (WebCore::Document::updateFocusAppearanceSoon):
        * dom/Document.h:
        * dom/Element.cpp:
        (WebCore::Element::focus):
        (WebCore::Element::updateFocusAppearanceAfterAttachIfNeeded):
        (WebCore::Element::updateFocusAppearance):
        * dom/Element.h:
        * history/CachedPage.cpp:
        (WebCore::CachedPage::restore):
        * html/HTMLAreaElement.cpp:
        (WebCore::HTMLAreaElement::updateFocusAppearance):
        * html/HTMLAreaElement.h:
        * html/HTMLInputElement.cpp:
        (WebCore::HTMLInputElement::updateFocusAppearance):
        (WebCore::HTMLInputElement::runPostTypeUpdateTasks):
        (WebCore::HTMLInputElement::didAttachRenderers):
        * html/HTMLInputElement.h:
        * html/HTMLTextAreaElement.cpp:
        (WebCore::HTMLTextAreaElement::updateFocusAppearance):
        * html/HTMLTextAreaElement.h:

2015-10-22  Joonghun Park  <jh718.park@samsung.com>

        [EFL] Fix build break since r191439
        https://bugs.webkit.org/show_bug.cgi?id=150441

        Reviewed by Csaba Osztrogonác.

        No new tests, no new behaviours.

        * platform/Logging.cpp:
        (WebCore::registerNotifyCallback):

2015-10-22  Carlos Garcia Campos  <cgarcia@igalia.com>

        Unreviewed. Fix GTK+ build after r191423.

        Deprecate removed class WebKitDOMHTMLBaseFontElement.

        * PlatformGTK.cmake:
        * bindings/gobject/WebKitDOMDeprecated.cpp:
        (webkit_dom_html_base_font_element_init):
        (webkit_dom_html_base_font_element_class_init):
        (webkit_dom_html_base_font_element_get_color):
        (webkit_dom_html_base_font_element_set_color):
        (webkit_dom_html_base_font_element_get_face):
        (webkit_dom_html_base_font_element_set_face):
        (webkit_dom_html_base_font_element_get_size):
        (webkit_dom_html_base_font_element_set_size):
        * bindings/gobject/WebKitDOMDeprecated.h:
        * bindings/gobject/WebKitDOMDeprecated.symbols:
        * bindings/gobject/WebKitDOMHTMLPrivate.cpp:
        * html/HTMLBaseFontElement.h:
        * html/HTMLBaseFontElement.idl:

2015-10-22  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Add writable stream attributes
        https://bugs.webkit.org/show_bug.cgi?id=150389

        Reviewed by Darin Adler.

        This patch adds the three writable stream attributes, which are closed, ready and state. They are implemented
        according to the spec.

        Current test set suffices, expectations were adjusted accordingly.

        * Modules/streams/WritableStream.js:
        (initializeWritableStream): Style fix.
        (closed):
        (ready):
        (state): Implemented according to the spec.
        * Modules/streams/WritableStreamInternals.js:
        (isWritableStream): Implemented according to the spec.

2015-10-22  Frederic Wang  <fred.wang@free.fr>

        Rollout r190440 for the moment. It broke the build.

        * platform/graphics/cocoa/FontCocoa.mm:
        (WebCore::Font::platformInit): Deleted.

2015-10-22  Frederic Wang  <fred.wang@free.fr>

        Unreviewed compilation fix on Mac.

        * platform/graphics/cocoa/FontCocoa.mm:
        (WebCore::Font::platformInit): Use a pointer for the third argument of CFArrayContainsValue.

2015-10-21  Frederic Wang  <fred.wang@free.fr>

        Unreviewed compilation fix on Mac.

        * platform/graphics/cocoa/FontCocoa.mm:
        (WebCore::Font::platformInit): Add missing font argument.

2015-10-21  Frederic Wang  <fred.wang@free.fr>

        [Mac] Add support for the USE_TYPO_METRICS flag
        https://bugs.webkit.org/show_bug.cgi?id=150394

        Reviewed by Myles C. Maxfield.

        Make the Cocoa backend use the typo metrics for fonts with a MATH table when the OS/2 USE_TYPO_METRICS flag is set.

        No new tests because this is already tested by fonts/use-typo-metrics-1.html

        * platform/graphics/cocoa/FontCocoa.mm:
        (WebCore::Font::platformInit): Verify whether the OS/2 USE_TYPO_METRICS flag is set and use the typo metrics if that is the case.

2015-10-21  Zalan Bujtas  <zalan@apple.com>

        Print out the render tree from command line.
        https://bugs.webkit.org/show_bug.cgi?id=150416

        Use system-wide notification server (https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man3/notify_register_dispatch.3.html)
        to print out the render tree for the live documents.

        Usage: notifyutil -p com.apple.WebKit.showRenderTree

        Reviewed by Simon Fraser.

        No change in functionality.

        * platform/Logging.cpp:
        (WebCore::registerNotifyCallback):
        * platform/Logging.h:
        * rendering/RenderObject.cpp:
        (WebCore::RenderObject::RenderObject):
        (WebCore::printRenderTreeForLiveDocuments):

2015-10-21  Alex Christensen  <achristensen@webkit.org>

        Fix CMake clean build after r191423.

        * CMakeLists.txt:
        HTMLBaseFontElement.idl no longer generates any JavaScript bindings.

2015-10-21  Brian Burg  <bburg@apple.com>

        Unreviewed, CMake build fix after r191433.

        * CMakeLists.txt: add WritableStreamInternals.js to WebCore_BUILTINS_SOURCES.

2015-10-21  Brian Burg  <bburg@apple.com>

        Restructure generate-js-bindings script to be modular and testable
        https://bugs.webkit.org/show_bug.cgi?id=149929

        Reviewed by Alex Christensen.

        * CMakeLists.txt:

            Define JavaScriptCore_SCRIPTS_DIR explicitly so the add_custom_command and
            shared file lists are identical between JavaScriptCore and WebCore.

            The output files additionally depend on all builtin generator script files.

        * DerivedSources.make:

            Use JavaScriptCore_SCRIPTS_DIR so that the rule for code generation and
            shared file lists are identical between JavaScriptCore and WebCore.

            The output files additionally depend on all builtin generator script files.

        * WebCore.xcodeproj/project.pbxproj:

            Define JavaScriptCore_SCRIPTS_DIR before calling DerivedSources.make.
            This will eventually be merged with the other similar script paths.

        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::JSDOMWindowBase::finishCreation):

            Update the generated builtin macro names.

        * generate-js-builtins: Removed.

2015-10-21  Alex Christensen  <achristensen@webkit.org>

        Recommit r191428.

        I don't think it was supposed to be reverted in r191429, and it really does fix the build.

        * loader/EmptyClients.h:
        (WebCore::EmptyContextMenuClient::~EmptyContextMenuClient):
        Remove customizeMenu again.

2015-10-21  Gyuyoung Kim  <gyuyoung.kim@webkit.org>

        [EFL][GTK][WK2] Fix build break since r191402, r191401
        https://bugs.webkit.org/show_bug.cgi?id=150432

        Unreviewed EFL and GTK build fix.

        * loader/EmptyClients.h:

2015-10-21  Alex Christensen  <achristensen@webkit.org>

        Build fix after r191422.

        * page/ContextMenuClient.h:
        (WebCore::ContextMenuClient::~ContextMenuClient):
        Completely remove customizeMenu.

2015-10-21  Gyuyoung Kim  <gyuyoung.kim@webkit.org>

        Remove unnecessary default quota setting in DatabaseContext::databaseExceededQuota
        https://bugs.webkit.org/show_bug.cgi?id=150356

        Reviewed by Darin Adler.

        All ports have supported DatabaseContext::databaseExceededQuota(). Thus we don't need to
        keep a test code to extend database quota anymore.

        * Modules/webdatabase/DatabaseContext.cpp:
        (WebCore::DatabaseContext::databaseExceededQuota): Deleted.

2015-10-21  Chris Dumez  <cdumez@apple.com>

        Un-expose obsolete HTMLBaseFontElement
        https://bugs.webkit.org/show_bug.cgi?id=150397

        Reviewed by Anders Carlsson.

        Un-expose obsolete HTMLBaseFontElement:
        - https://html.spec.whatwg.org/multipage/obsolete.html#non-conforming-features

        This means that we no longer expose HTMLBaseFontElement on the global
        Window object. Firefox and Chrome do not expose it either.

        Also, document.createElement("basefont") now returns an HTMLUnknownElement
        as per the specification. Firefox and Chrome return a generic HTMLElement
        instead but I don't think this is a big compatibility risk.

        No new tests, already covered by existing tests.

        * html/HTMLBaseFontElement.cpp:
        (WebCore::HTMLBaseFontElement::HTMLBaseFontElement):
        * html/HTMLBaseFontElement.h:
        * html/HTMLBaseFontElement.idl:
        * html/HTMLTagNames.in:

2015-10-21  Anders Carlsson  <andersca@apple.com>

        Get rid of WebContextMenuClient::customizeMenu, it's no longer used
        https://bugs.webkit.org/show_bug.cgi?id=150427

        Reviewed by Tim Horton.
        * loader/EmptyClients.cpp:
        (WebCore::EmptyContextMenuClient::customizeMenu): Deleted.
        * loader/EmptyClients.h:
        * page/ContextMenuController.cpp:
        (WebCore::ContextMenuController::showContextMenu):

2015-10-21  Anders Carlsson  <andersca@apple.com>

        Remove dead MHTML code
        https://bugs.webkit.org/show_bug.cgi?id=150426

        Reviewed by Tim Horton.

        * loader/archive/mhtml/MHTMLArchive.cpp:
        (WebCore::MHTMLArchive::generateMHTMLData):
        (WebCore::MHTMLArchive::generateMHTMLDataUsingBinaryEncoding): Deleted.
        * loader/archive/mhtml/MHTMLArchive.h:

2015-10-21  Dean Jackson  <dino@apple.com>

        Null dereference loading Blink layout test svg/filters/display-none-filter-primitive.html
        https://bugs.webkit.org/show_bug.cgi?id=150212
        <rdar://problem/23137376>

        Reviewed by Brent Fulgham.

        Handle the case where a filter element doesn't have a renderer. Inspired by the Blink
        commit:
        https://chromium.googlesource.com/chromium/src.git/+/fb79f7fc46552d45127acd2959a23662ad8f271e

        Test: svg/filters/display-none-filter-primitive.html

        * rendering/svg/RenderSVGResourceFilter.cpp:
        (WebCore::RenderSVGResourceFilter::buildPrimitives):
        * svg/graphics/filters/SVGFilterBuilder.cpp:
        (WebCore::SVGFilterBuilder::appendEffectToEffectReferences):

2015-10-21  Brady Eidson  <beidson@apple.com>

        Modern IDB: Add basic transaction aborting.
        https://bugs.webkit.org/show_bug.cgi?id=150148

        Reviewed by Alex Christensen.

        Tests: storage/indexeddb/modern/double-abort.html
               storage/indexeddb/modern/versionchange-abort-then-reopen.html

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:
        
        * Modules/indexeddb/IndexedDB.h:
        
        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::abortTransaction):
        (WebCore::IDBClient::IDBConnectionToServer::didAbortTransaction):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:
        
        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::abortTransaction):
        (WebCore::IDBClient::IDBDatabase::didCommitOrAbortTransaction):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::IDBTransaction):
        (WebCore::IDBClient::IDBTransaction::abort):
        (WebCore::IDBClient::IDBTransaction::isFinishedOrFinishing):
        (WebCore::IDBClient::IDBTransaction::activationTimerFired):
        (WebCore::IDBClient::IDBTransaction::didAbort):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        
        * Modules/indexeddb/server/IDBBackingStore.h:
        
        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didAbortTransaction):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:
        
        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::abortTransaction):
        * Modules/indexeddb/server/IDBServer.h:
        
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.cpp:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::create):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::MemoryBackingStoreTransaction):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::~MemoryBackingStoreTransaction):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::abort):
        (WebCore::IDBServer::MemoryBackingStoreTransaction::commit):
        * Modules/indexeddb/server/MemoryBackingStoreTransaction.h:
        (WebCore::IDBServer::MemoryBackingStoreTransaction::isVersionChange):
        
        * Modules/indexeddb/server/MemoryIDBBackingStore.cpp:
        (WebCore::IDBServer::MemoryIDBBackingStore::setDatabaseInfo):
        (WebCore::IDBServer::MemoryIDBBackingStore::beginTransaction):
        (WebCore::IDBServer::MemoryIDBBackingStore::abortTransaction):
        (WebCore::IDBServer::MemoryIDBBackingStore::commitTransaction):
        * Modules/indexeddb/server/MemoryIDBBackingStore.h:

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::startVersionChangeTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::beginTransactionInBackingStore):
        (WebCore::IDBServer::UniqueIDBDatabase::commitTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::performCommitTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformCommitTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::abortTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::performAbortTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformAbortTransaction):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::didAbortTransaction):
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::UniqueIDBDatabaseTransaction):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::originalDatabaseInfo):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::abort):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
        
        * Modules/indexeddb/shared/IDBError.cpp:
        (WebCore::idbErrorName):
        (WebCore::idbErrorDescription):
        * Modules/indexeddb/shared/IDBError.h:

        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didAbortTransaction):
        (WebCore::InProcessIDBServer::abortTransaction):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

2015-10-21  Chris Dumez  <cdumez@apple.com>

        bgsound should use HTMLUnknownElement interface
        https://bugs.webkit.org/show_bug.cgi?id=148857
        <rdar://problem/22589036>

        Reviewed by Sam Weinig.

        The blink, bgsound, isindex, multicol, nextid, and spacer elements must
        use the HTMLUnknownElement interface, as per the HTML specification:
        https://html.spec.whatwg.org/multipage/obsolete.html#other-elements,-attributes-and-apis

        WebKit was using HTMLUnknownElement for all of them except bgsound.
        This patch fixes the issue and aligns our behavior with Chrome and
        Firefox.

        No new tests, already covered by existing tests.

        * html/HTMLTagNames.in:

2015-10-21  Antoine Quint  <graouts@apple.com>

        Support for the SVG `onend` attribute
        https://bugs.webkit.org/show_bug.cgi?id=150393

        Reviewed by Dean Jackson.

        Add support for the SVG `onend` attribute to SVG timing and animation elements, which allow the definition
        of a JS event listener declaratively for the SVG `endEvent` event.

        Tests: svg/animations/end-event-attribute-expected.svg
               svg/animations/end-event-attribute.svg
               svg/animations/end-event-syncbase-expected.svg
               svg/animations/end-event-syncbase.svg

        * dom/EventNames.h:
        * svg/animation/SVGSMILElement.cpp:
        (WebCore::SVGSMILElement::parseAttribute):
        * svg/svgattrs.in:

2015-10-21  Nan Wang  <n_wang@apple.com>

        AX: Expose table size and cell indexes on iOS
        https://bugs.webkit.org/show_bug.cgi?id=150366

        Add support to expose table row/column count and cell indexes on iOS.

        Reviewed by Chris Fleizach.

        Test: accessibility/aria-table-attributes.html

        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
        (-[WebAccessibilityObjectWrapper tableParent]):
        (-[WebAccessibilityObjectWrapper accessibilityElementForRow:andColumn:]):
        (-[WebAccessibilityObjectWrapper accessibilityRowCount]):
        (-[WebAccessibilityObjectWrapper accessibilityColumnCount]):
        (-[WebAccessibilityObjectWrapper accessibilityARIARowCount]):
        (-[WebAccessibilityObjectWrapper accessibilityARIAColumnCount]):
        (-[WebAccessibilityObjectWrapper accessibilityARIARowIndex]):
        (-[WebAccessibilityObjectWrapper accessibilityARIAColumnIndex]):
        (-[WebAccessibilityObjectWrapper accessibilityRowRange]):

2015-10-21  Chris Dumez  <cdumez@apple.com>

        HTMLIFrameElement.sandbox should be a DOMSettableTokenList
        https://bugs.webkit.org/show_bug.cgi?id=150377

        Reviewed by Ryosuke Niwa.

        HTMLIFrameElement.sandbox should be a DOMSettableTokenList as per the
        HTML specification:
        - https://html.spec.whatwg.org/multipage/embedded-content.html#htmliframeelement

        Chrome and Firefox match the specification but Safari/WebKit was uding
        a DOMString.

        Test: fast/frames/sandbox-attribute.html

        * html/HTMLIFrameElement.cpp:
        (WebCore::HTMLIFrameElement::sandbox):
        (WebCore::HTMLIFrameElement::parseAttribute):
        * html/HTMLIFrameElement.h:
        * html/HTMLIFrameElement.idl:

2015-10-21  Carlos Garcia Campos  <cgarcia@igalia.com>

        ASSERTION FAILED: markFontData in FontCascade::emphasisMarkHeight
        https://bugs.webkit.org/show_bug.cgi?id=150171

        Reviewed by Myles C. Maxfield.

        It happens with several tests like fast/ruby/text-emphasis.html in
        the GTK Debug bot. The tests seem to pass in Release and the rendering
        looks correct as well removing the assert. The thing is that
        for some reason we can get an empty GlyphData from
        FontCascade::getEmphasisMarkGlyphData() when it ends up falling
        back to system (FontCascadeFonts::glyphDataForSystemFallback).

        * platform/graphics/FontCascade.cpp:
        (WebCore::FontCascade::getEmphasisMarkGlyphData): Return
        Optional<GlyphData> instead of returning a boolean and an out
        parameter. If we get an invalid GlyphData, Nullopt is
        returned. Also use a SurrogatePairAwareTextIterator to handle
        surrogate pairs.
        (WebCore::FontCascade::emphasisMarkAscent):
        (WebCore::FontCascade::emphasisMarkDescent):
        (WebCore::FontCascade::emphasisMarkHeight):
        (WebCore::FontCascade::drawEmphasisMarks):
        * platform/graphics/FontCascade.h:
        * platform/graphics/GlyphPage.h:
        (WebCore::GlyphData::isValid): Return whether the GlyphData is valid.

2015-10-20  Sergio Villar Senin  <svillar@igalia.com>

        [css-grid] Fix availableLogicalSpace computation with non-zero baseSize flex tracks
        https://bugs.webkit.org/show_bug.cgi?id=150359

        Reviewed by Zalan Bujtas.

        The availableLogicalSpace computation was incorrect whenever
        the flex tracks had a non-zero baseSize before the 1fr unit
        size resolution. That happened because when assigning the new
        baseSize to the flex track, we were unconditionally
        subtracting the whole baseSize to the
        availableLogicalSpace. That's correct if the track is a "pure"
        flex track, i.e. 2fr, but if the track had a non-zero baseSize
        (like minmax(10px, 1fr)) then both the new and the old base
        sizes were incorrectly used to compute the
        availableLogicalSpace.

        We can test the amount of remaining freeSpace by using content
        distribution to align and item place on a non-zero baseSize
        flex track. The content distribution will be accurate if and
        only if the availableLogicalSpace computation is correct.

        Test: fast/css-grid-layout/flex-content-distribution.html

        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::computeUsedBreadthOfGridTracks):

2015-10-21  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Construct a writable stream
        https://bugs.webkit.org/show_bug.cgi?id=150360

        Reviewed by Darin Adler.

        This patch initializes a writable stream according to the spec. To do it we need two internal functions, which
        are syncWritableStreamStateWithQueue and errorWritableStream, which are also implemented as a quite direct
        translation from the spec.

        Current test set suffices, expectations are updated accordingly.

        * CMakeLists.txt:
        * DerivedSources.make:
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/JSDOMWindowBase.cpp:
        * bindings/js/WebCoreBuiltinNames.h:
        * bindings/js/WebCoreJSBuiltinInternals.h:
        * bindings/js/WebCoreJSBuiltins.cpp:
        * bindings/js/WebCoreJSBuiltins.h: Build infrastructure.
        * Modules/streams/WritableStream.js:
        (initializeWritableStream): Function that acts as constructor of WritableStream.
        * Modules/streams/WritableStreamInternals.js:
        (syncWritableStreamStateWithQueue):
        (errorWritableStream): As per spec.

2015-10-21  Carlos Garcia Campos  <cgarcia@igalia.com>

        NetworkProcess: DNS prefetch happens in the Web Process
        https://bugs.webkit.org/show_bug.cgi?id=147824

        Reviewed by Chris Dumez.

        Use FrameLoaderClient to do the DNS prefetch.

        * html/HTMLAnchorElement.cpp:
        (WebCore::HTMLAnchorElement::parseAttribute):
        * loader/EmptyClients.h:
        * loader/FrameLoaderClient.h:
        * loader/LinkLoader.cpp:
        (WebCore::LinkLoader::loadLink):
        * page/Chrome.cpp:
        (WebCore::Chrome::mouseDidMoveOverElement):

2015-10-21  Frederic Wang  <fred.wang@free.fr>

        [FreeType] Add support for the USE_TYPO_METRICS flag
        https://bugs.webkit.org/show_bug.cgi?id=150340

        Reviewed by Martin Robinson.

        Test: fonts/use-typo-metrics-1.html

        Make the FreeType backend use the typo metrics when the OS/2 USE_TYPO_METRICS flag is set.
        Similar work should be done for other backends, see bug 131839.

        * platform/graphics/freetype/SimpleFontDataFreeType.cpp:
        (WebCore::Font::platformInit): Verify whether the OS/2 USE_TYPO_METRICS flag is set and use the typo metrics if that's the case.

2015-10-20  Hunseop Jeong  <hs85.jeong@samsung.com>

        Replace 0 and NULL with nullptr in WebCore/loader.
        https://bugs.webkit.org/show_bug.cgi?id=149657

        Reviewed by Darin Adler.

        No new tests because there is no behavior change.

        * loader/CookieJar.cpp:
        (WebCore::networkingContext):
        * loader/DocumentLoader.cpp:
        (WebCore::DocumentLoader::DocumentLoader):
        (WebCore::DocumentLoader::frameLoader):
        (WebCore::DocumentLoader::popArchiveForSubframe):
        (WebCore::DocumentLoader::clearArchiveResources):
        (WebCore::DocumentLoader::clearMainResource):
        (WebCore::DocumentLoader::subresourceLoaderFinishedLoadingOnePart):
        * loader/DocumentThreadableLoader.cpp:
        (WebCore::DocumentThreadableLoader::cancel):
        (WebCore::DocumentThreadableLoader::setDefersLoading):
        (WebCore::DocumentThreadableLoader::clearResource):
        * loader/EmptyClients.cpp:
        (WebCore::EmptyFrameLoaderClient::createJavaAppletWidget):
        (WebCore::EmptyFrameLoaderClient::createNetworkingContext):
        * loader/EmptyClients.h:
        * loader/FTPDirectoryParser.cpp:
        (WebCore::parseOneFTPLine):
        * loader/FTPDirectoryParser.h:
        (WebCore::ListResult::clear):
        * loader/FormSubmission.cpp:
        (WebCore::FormSubmission::create):
        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::clear):
        (WebCore::FrameLoader::stopAllLoaders):
        (WebCore::FrameLoader::clearProvisionalLoad):
        (WebCore::FrameLoader::transitionToCommitted):
        (WebCore::FrameLoader::closeAndRemoveChild):
        (WebCore::FrameLoader::detachFromParent):
        (WebCore::FrameLoader::detachViewsAndDocumentLoader):
        (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
        (WebCore::FrameLoader::continueLoadAfterNavigationPolicy):
        * loader/FrameLoader.h:
        (WebCore::FrameLoader::stateMachine):
        * loader/FrameNetworkingContext.h:
        (WebCore::FrameNetworkingContext::invalidate):
        * loader/HistoryController.cpp:
        (WebCore::HistoryController::replaceState):
        * loader/ImageLoader.cpp:
        (WebCore::ImageLoader::ImageLoader):
        (WebCore::ImageLoader::updateFromElement):
        * loader/NetscapePlugInStreamLoader.cpp:
        (WebCore::NetscapePlugInStreamLoader::releaseResources):
        * loader/ResourceLoadNotifier.h:
        * loader/ResourceLoadScheduler.cpp:
        (WebCore::resourceLoadScheduler):
        * loader/SubresourceLoader.cpp:
        (WebCore::SubresourceLoader::releaseResources):
        * loader/TextResourceDecoder.cpp:
        (WebCore::TextResourceDecoder::TextResourceDecoder):
        * loader/ThreadableLoaderClientWrapper.h:
        (WebCore::ThreadableLoaderClientWrapper::clearClient):
        (WebCore::ThreadableLoaderClientWrapper::done):
        * loader/appcache/ApplicationCache.cpp:
        (WebCore::fallbackURLLongerThan):
        (WebCore::ApplicationCache::ApplicationCache):
        (WebCore::ApplicationCache::resourceForRequest):
        * loader/appcache/ApplicationCache.h:
        (WebCore::ApplicationCache::fallbackURLs):
        * loader/appcache/ApplicationCacheGroup.cpp:
        (WebCore::ApplicationCacheGroup::ApplicationCacheGroup):
        (WebCore::ApplicationCacheGroup::fallbackCacheForMainRequest):
        (WebCore::ApplicationCacheGroup::selectCache):
        (WebCore::ApplicationCacheGroup::finishedLoadingMainResource):
        (WebCore::ApplicationCacheGroup::failedLoadingMainResource):
        (WebCore::ApplicationCacheGroup::manifestNotFound):
        (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
        * loader/appcache/ApplicationCacheHost.cpp:
        (WebCore::ApplicationCacheHost::ApplicationCacheHost):
        (WebCore::ApplicationCacheHost::setApplicationCache):
        * loader/appcache/ApplicationCacheHost.h:
        (WebCore::ApplicationCacheHost::candidateApplicationCacheGroup):
        * loader/appcache/ApplicationCacheStorage.cpp:
        (WebCore::StorageIDJournal::Record::Record):
        (WebCore::StorageIDJournal::Record::restore):
        (WebCore::ApplicationCacheStorage::loadCacheGroup):
        (WebCore::ApplicationCacheStorage::cacheGroupForURL):
        (WebCore::ApplicationCacheStorage::fallbackCacheGroupForURL):
        (WebCore::ApplicationCacheStorage::cacheGroupDestroyed):
        (WebCore::ApplicationCacheStorage::loadCache):
        * loader/appcache/DOMApplicationCache.cpp:
        (WebCore::DOMApplicationCache::disconnectFrameForPageCache):
        (WebCore::DOMApplicationCache::willDestroyGlobalObjectInFrame):
        (WebCore::DOMApplicationCache::applicationCacheHost):
        (WebCore::DOMApplicationCache::scriptExecutionContext):
        (WebCore::DOMApplicationCache::toEventType):
        * loader/archive/ArchiveFactory.cpp:
        (WebCore::ArchiveFactory::create):
        (WebCore::ArchiveFactory::registerKnownArchiveMIMETypes):
        * loader/archive/ArchiveResourceCollection.cpp:
        (WebCore::ArchiveResourceCollection::archiveResourceForURL):
        * loader/archive/cf/LegacyWebArchive.cpp:
        (WebCore::LegacyWebArchive::createPropertyListRepresentation):
        (WebCore::LegacyWebArchive::createResource):
        (WebCore::LegacyWebArchive::create):
        (WebCore::LegacyWebArchive::rawDataRepresentation):
        * loader/archive/cf/LegacyWebArchiveMac.mm:
        (WebCore::LegacyWebArchive::createPropertyListRepresentation):
        * loader/archive/mhtml/MHTMLArchive.cpp:
        (WebCore::MHTMLArchive::create):
        (WebCore::MHTMLArchive::generateMHTMLData):
        * loader/archive/mhtml/MHTMLParser.cpp:
        (WebCore::MHTMLParser::parseArchiveWithHeader):
        (WebCore::MHTMLParser::parseNextPart):
        * loader/cache/CachedImage.cpp:
        (WebCore::CachedImage::CachedImage):
        * loader/cache/CachedImageClient.h:
        (WebCore::CachedImageClient::imageChanged):
        (WebCore::CachedImageClient::newImageAnimationFrameAvailable):
        * loader/cache/CachedRawResource.cpp:
        (WebCore::CachedRawResource::calculateIncrementalDataChunk):
        * loader/cache/CachedRawResourceClient.h:
        (WebCore::CachedRawResourceClient::dataReceived):
        (WebCore::CachedRawResourceClient::redirectReceived):
        (WebCore::CachedRawResourceClient::getOrCreateReadBuffer):
        * loader/cache/CachedResource.cpp:
        (WebCore::CachedResource::CachedResource):
        (WebCore::CachedResource::clearResourceToRevalidate):
        * loader/cache/CachedResourceClientWalker.h:
        (WebCore::CachedResourceClientWalker::next):
        * loader/cache/CachedResourceHandle.cpp:
        (WebCore::CachedResourceHandleBase::CachedResourceHandleBase):
        * loader/cache/CachedResourceLoader.cpp:
        (WebCore::createResource):
        (WebCore::CachedResourceLoader::CachedResourceLoader):
        (WebCore::CachedResourceLoader::~CachedResourceLoader):
        (WebCore::CachedResourceLoader::canRequest): Return value is bool.
        (WebCore::CachedResourceLoader::requestResource):
        * loader/cache/CachedResourceLoader.h:
        (WebCore::CachedResourceLoader::document):
        (WebCore::CachedResourceLoader::setDocument):
        (WebCore::CachedResourceLoader::clearDocumentLoader):
        * loader/cache/CachedSVGDocumentReference.cpp:
        (WebCore::CachedSVGDocumentReference::CachedSVGDocumentReference):
        * loader/cf/ResourceLoaderCFNet.cpp:
        (WebCore::ResourceLoader::shouldCacheResponse): Return value is bool.
        * loader/icon/IconDatabase.cpp:
        (WebCore::IconDatabase::synchronousIconForPageURL):
        (WebCore::IconDatabase::synchronousNativeIconForPageURL):
        (WebCore::IconDatabase::setIconDataForIconURL):
        (WebCore::IconDatabase::getOrCreatePageURLRecord):
        (WebCore::IconDatabase::cleanupSyncThread):
        * loader/icon/IconDatabaseBase.cpp:
        (WebCore::IconDatabaseBase::open):
        (WebCore::iconDatabase):
        * loader/icon/IconDatabaseBase.h:
        (WebCore::EnumCallback::performCallback):
        (WebCore::EnumCallback::invalidate):
        (WebCore::ObjectCallback::performCallback):
        (WebCore::ObjectCallback::invalidate):
        * loader/icon/PageURLRecord.cpp:
        (WebCore::PageURLRecord::~PageURLRecord):
        (WebCore::PageURLRecord::setIconRecord):
        * loader/mac/ResourceLoaderMac.mm:
        (WebCore::ResourceLoader::willCacheResponse):
        * loader/soup/CachedRawResourceSoup.cpp:
        (WebCore::CachedRawResource::getOrCreateReadBuffer):

2015-10-20  Chris Dumez  <cdumez@apple.com>

        Unreviewed, GTK API test fix after r191351.

        Reverted API change for GTK bindings.

        * html/HTMLOptionsCollection.idl:
        * html/HTMLSelectElement.idl:

2015-10-20  Chris Dumez  <cdumez@apple.com>

        Unreviewed, Another GTK build fix after r191351.

        * html/HTMLCollection.idl:

2015-10-20  Chris Dumez  <cdumez@apple.com>

        Unreviewed, Another GTK build fix after r191351.

        * html/HTMLFieldSetElement.cpp:
        (WebCore::HTMLFieldSetElement::elementsForNativeBindings):
        (WebCore::HTMLFieldSetElement::elementsForObjC): Deleted.
        * html/HTMLFieldSetElement.h:
        * html/HTMLFieldSetElement.idl:

2015-10-20  Chris Fleizach  <cfleizach@apple.com>

        AX: CrashTracer: com.apple.WebKit.WebContent at com.apple.WebCore: WebCore::AccessibilityTable::tableElement const + 116
        https://bugs.webkit.org/show_bug.cgi?id=150349

        Reviewed by Brent Fulgham.

        The crash point for this bug says that the parentElement of the firstBody is garbage when it's accessed. 
        Unfortunately, I could not reproduce this in-situ or with a test. 
        So my speculative solution is to recalculate those body elements to ensure that they're valid before we access.

        * accessibility/AccessibilityTable.cpp:
        (WebCore::AccessibilityTable::tableElement):
        (WebCore::AccessibilityTable::isDataTable):

2015-10-20  Chris Dumez  <cdumez@apple.com>

        Unreviewed, GTK build fix after r191351.

        * html/HTMLFormElement.cpp:
        (WebCore::HTMLFormElement::elementsForNativeBindings):
        (WebCore::HTMLFormElement::elementsForObjC): Deleted.
        * html/HTMLFormElement.h:
        * html/HTMLFormElement.idl:

2015-10-20  Simon Fraser  <simon.fraser@apple.com>

        Add basic TextStream output for Images
        https://bugs.webkit.org/show_bug.cgi?id=150350

        Reviewed by Darin Adler.

        Add a TextStream output operator for Image, and virtual dump() member functions
        that the various image types override to dump their own data.
        
        Add isFoo() functions for each image type (surprising that these didn't already
        exist) so we can print the image type.
        
        Make isAnimated() const, and isBitmapImage() private.

        * platform/graphics/BitmapImage.cpp:
        (WebCore::BitmapImage::dump):
        * platform/graphics/BitmapImage.h:
        * platform/graphics/CrossfadeGeneratedImage.cpp:
        (WebCore::CrossfadeGeneratedImage::dump):
        * platform/graphics/CrossfadeGeneratedImage.h:
        * platform/graphics/GeneratedImage.cpp:
        * platform/graphics/GeneratedImage.h:
        * platform/graphics/GradientImage.cpp:
        (WebCore::GradientImage::dump):
        * platform/graphics/GradientImage.h:
        * platform/graphics/Image.cpp:
        (WebCore::Image::dump):
        (WebCore::operator<<):
        * platform/graphics/Image.h:
        (WebCore::Image::isGeneratedImage):
        (WebCore::Image::isCrossfadeGeneratedImage):
        (WebCore::Image::isNamedImageGeneratedImage):
        (WebCore::Image::isGradientImage):
        (WebCore::Image::isSVGImage):
        (WebCore::Image::isAnimated):
        * platform/graphics/NamedImageGeneratedImage.cpp:
        (WebCore::NamedImageGeneratedImage::dump):
        * platform/graphics/NamedImageGeneratedImage.h:
        * platform/graphics/cg/PDFDocumentImage.cpp:
        (WebCore::PDFDocumentImage::dump):
        * platform/graphics/cg/PDFDocumentImage.h:
        * svg/graphics/SVGImage.cpp:
        (WebCore::SVGImage::dump):
        * svg/graphics/SVGImage.h:

2015-10-20  Chris Dumez  <cdumez@apple.com>

        Use tighter typing for collections / node lists' item() / namedItem() methods
        https://bugs.webkit.org/show_bug.cgi?id=150347

        Reviewed by Darin Adler.

        Use tighter typing for collections / node lists' item() / namedItem() methods.

        * accessibility/AccessibilityRenderObject.cpp:
        (WebCore::AccessibilityRenderObject::getDocumentLinks):
        * dom/LiveNodeList.h:
        * dom/StaticNodeList.cpp:
        (WebCore::StaticElementList::item):
        * dom/StaticNodeList.h:
        * html/CachedHTMLCollection.h:
        * html/HTMLAllCollection.idl:
        * html/HTMLCollection.idl:
        * html/HTMLFieldSetElement.cpp:
        (WebCore::HTMLFieldSetElement::elements):
        (WebCore::HTMLFieldSetElement::elementsForObjC):
        * html/HTMLFieldSetElement.h:
        * html/HTMLFieldSetElement.idl:
        * html/HTMLFormControlsCollection.cpp:
        (WebCore::HTMLFormControlsCollection::customElementAfter):
        * html/HTMLFormControlsCollection.h:
        * html/HTMLFormControlsCollection.idl:
        * html/HTMLFormElement.cpp:
        (WebCore::HTMLFormElement::item):
        (WebCore::HTMLFormElement::elements):
        (WebCore::HTMLFormElement::elementsForObjC):
        * html/HTMLFormElement.h:
        * html/HTMLFormElement.idl:
        * html/HTMLOptionsCollection.cpp:
        (WebCore::HTMLOptionsCollection::add):
        * html/HTMLOptionsCollection.h:
        * html/HTMLOptionsCollection.idl:
        * html/HTMLSelectElement.cpp:
        (WebCore::HTMLSelectElement::namedItem):
        (WebCore::HTMLSelectElement::item):
        (WebCore::HTMLSelectElement::setOption):
        * html/HTMLSelectElement.idl:
        * html/HTMLTableRowElement.cpp:
        (WebCore::HTMLTableRowElement::deleteCell):
        * html/HTMLTableSectionElement.cpp:
        (WebCore::HTMLTableSectionElement::deleteRow):
        * html/RadioNodeList.cpp:
        (WebCore::toRadioButtonInputElement):
        (WebCore::RadioNodeList::value):
        (WebCore::RadioNodeList::setValue):
        * html/RadioNodeList.h:
        * html/RadioNodeList.idl:

2015-10-20  Chris Dumez  <cdumez@apple.com>

        Only HTML spaces should be stripped from a <script>'s 'for' / 'event' attributes
        https://bugs.webkit.org/show_bug.cgi?id=150335

        Reviewed by Darin Adler.

        Only HTML spaces should be stripped from a <script>'s 'for' / 'event' attributes:
        https://html.spec.whatwg.org/multipage/scripting.html#prepare-a-script (step 12.3)
        https://html.spec.whatwg.org/multipage/infrastructure.html#space-character

        Previously, we were uding the wrong stripping function and we were stripping
        some non-HTML spaces.

        Test: fast/dom/script-for-event-spaces.html

        * dom/ScriptElement.cpp:
        (WebCore::ScriptElement::isScriptForEventSupported):

2015-10-20  Csaba Osztrogonác  <ossy@webkit.org>

        Fix the !ENABLE(CSS_GRID_LAYOUT) build after r191128
        https://bugs.webkit.org/show_bug.cgi?id=150321

        Reviewed by Darin Adler.

        * css/CSSGrammar.y.in: Typo fix.

2015-10-20  Tim Horton  <timothy_horton@apple.com>

        Try to fix the build by disabling MAC_GESTURE_EVENTS on 10.9 and 10.10

        * Configurations/FeatureDefines.xcconfig:

2015-10-13  Sergio Villar Senin  <svillar@igalia.com>

        ASSERTION FAILED: computeMainAxisExtentForChild(child, MainOrPreferredSize, mainSize) in WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax
        https://bugs.webkit.org/show_bug.cgi?id=149459

        Reviewed by Darin Adler.

        This was regressed after 189567 where min-height|width:auto
        support was added to flex items. The merge from Blink changes
        was not correctly done for assertions. In particular we were
        asserting if the resolved main size was not strictly greater
        than 0, but 0 is actually a valid value.

        Test: fast/flexbox/crash-resolved-main-size-zero.html

        * rendering/RenderFlexibleBox.cpp:
        (WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax):

2015-10-20  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Rework some readable stream internals that can be common to writable streams
        https://bugs.webkit.org/show_bug.cgi?id=150133

        Reviewed by Darin Adler.

        There are some things in ReadableStream internals that be be used also for Writable Streams so it was necessary
        to move some functions and refactor some code that can be shared by both implementations.

        Queue was written with the functions declared at the implementation and keeping the improvement of having the
        total size calculated instead of having to transverse the whole array.

        The strategy is kept as an object and a common method is used to validate it as per spec.

        Promises are reworked to keep in an internal slot inside the promise object the resolve and reject
        functions. For convinience three functions were written, one to create the promise (and keep internally the
        resolve and reject functions), one to resolve and another to reject. Promises can still be created with
        Promise.resolve or reject as the resolve and rejectStreamsPromise functions operate under the assumption that
        the internal slots might not exist.

        invokeOrNoop and promiseInvokeOrNoop were moved to the common code as they will be also used by WritableStream.

        Current test set suffices.

        * CMakeLists.txt:
        * DerivedSources.make:
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/JSDOMWindowBase.cpp:
        * bindings/js/WebCoreJSBuiltinInternals.h:
        * bindings/js/WebCoreJSBuiltins.cpp:
        * bindings/js/WebCoreJSBuiltins.h: Build infrastructure.
        * Modules/streams/ReadableStream.js:
        (initializeReadableStream): Reworked queue and strategy.
        * Modules/streams/ReadableStreamInternals.js:
        (privateInitializeReadableStreamReader):
        (errorReadableStream):
        (getReadableStreamDesiredSize):
        (cancelReadableStream):
        (closeReadableStream):
        (closeReadableStreamReader):
        (enqueueInReadableStream):
        (readFromReadableStreamReader): Reworked queue, strategy and promises.
        (invokeOrNoop): Deleted.
        (promiseInvokeOrNoop): Deleted.
        * Modules/streams/StreamInternals.js: Added.
        (invokeOrNoop):
        (promiseInvokeOrNoop): Moved from ReadableStreamInternals.js.
        (validateAndNormalizeQueuingStrategy):
        (createNewStreamsPromise):
        (resolveStreamsPromise):
        (rejectStreamsPromise):
        (newQueue):
        (dequeueValue):
        (enqueueValueWithSize): Added according to the spec.
        * bindings/js/WebCoreBuiltinNames.h: Updated private names according to the new slots.

2015-10-20  Yoav Weiss  <yoav@yoav.ws>

        Rename the PICTURE_SIZES flag to CURRENTSRC
        https://bugs.webkit.org/show_bug.cgi?id=150275

        Reviewed by Dean Jackson.

        No new tests, since there is no functional change.

        * Configurations/FeatureDefines.xcconfig:
        * html/HTMLImageElement.cpp:
        * html/HTMLImageElement.h:
        * html/HTMLImageElement.idl:

2015-10-19  Carlos Garcia Campos  <cgarcia@igalia.com>

        ASSERTION FAILED: m_state == Initialized in SubresourceLoader::didReceiveResponse()
        https://bugs.webkit.org/show_bug.cgi?id=150327

        Reviewed by Antti Koivisto.

        This is how it happens:

        1. print() is called while the document is still loading, so
           m_shouldPrintWhenFinishedLoading is set to true
        2. DataURLDecoder::decode() finishes in the work queue thread,
           the completion handler is scheduled in the main thread
        3. The load is cancelled
          3.1. SubresourceLoader::willCancel sets m_state = Finishing
          3.2. DOMWindow::finishedLoading() is called, and since
               m_shouldPrintWhenFinishedLoading is true, it does the print.
          3.3. Cancellation finishes and ResourceLoader::releaseResources()
               is called that sets m_reachedTerminalState = true

        So, between 3.1 and 3.3, the state is Finishing, but
        m_reachedTerminalState is false. What happens, in the GTK+ port at
        least, is that the nested main loop used to make print()
        synchronous, processes the DataURLDecoder::decode() completion
        handler that was pending. The completion handler returns early if
        m_reachedTerminalState is true, but it's not yet in this
        particular case. So, it ends up calling didReceiveResponse,
        because the decode didn't fail, when the subresource loader state
        is Finishing.

        I think there are two things here. One is that we shouldn't start
        a print that was waiting for the load to finish when it
        failed. That would fix the problem. But it's probably a good idea
        to also check for cancellation in the DataURLDecoder::decode()
        completion handler.

        Fixes printing/print-close-crash.html in GTK+ Debug.

        * loader/ResourceLoader.cpp:
        (WebCore::ResourceLoader::loadDataURL): Return early from
        DataURLDecoder::decode() completion handler if the load was cancelled.
        * page/DOMWindow.cpp:
        (WebCore::DOMWindow::finishedLoading): Do not start a print that
        was witing for the load to finish when it failed.

2015-10-19  Myles C. Maxfield  <mmaxfield@apple.com>

        FontCascade::typesettingFeatures() is not privy to font-variant-* nor font-feature-settings
        https://bugs.webkit.org/show_bug.cgi?id=149775

        Reviewed by Darin Adler.

        This patch has two pieces:

        We used to have a boolean, enableLigatures, which affected how we perform shaping in both our
        simple and complex text codepaths. However, in this brave new world of font-feature-settings
        and font-variant-*, there are many properties which may affect shaping (and multiple kinds
        of ligatures). This patch renames this boolean to requiresShaping, and teaches it about all
        the various properties which affect text shaping.

        Similarly, one of the places which used this enableLigatures boolean was to tell CoreText
        if it should disable ligatures. However, we now have much finer-grained control over
        ligatures during font creation. This patch moves the responsibility of dictating which
        font features should be enabled entirely to the Font. Therefore, getCFStringAttributes()
        doesn't know anything about ligatures anymore; the logic inside font creation is used
        instead.

        An added benefit of moving all the font feature logic to one place is that we can implement
        the feature resolution algorithm described in the CSS3 fonts spec. This patch adds a test to
        makes sure that text-rendering, font-feature-settings, and font-variant-* play together
        nicely.

        Test: fast/text/multiple-feature-properties.html

        * platform/graphics/Font.cpp:
        (WebCore::Font::applyTransforms):
        * platform/graphics/Font.h:
        * platform/graphics/FontCascade.cpp:
        (WebCore::FontCascade::FontCascade):
        (WebCore::FontCascade::operator=):
        (WebCore::FontCascade::update):
        (WebCore::FontCascade::drawText):
        (WebCore::FontCascade::drawEmphasisMarks):
        (WebCore::FontCascade::width):
        (WebCore::FontCascade::adjustSelectionRectForText):
        (WebCore::FontCascade::offsetForPosition):
        (WebCore::FontCascade::codePath):
        (WebCore::FontCascade::floatWidthForSimpleText):
        * platform/graphics/FontCascade.h:
        (WebCore::FontCascade::requiresShaping):
        (WebCore::FontCascade::computeRequiresShaping):
        (WebCore::FontCascade::enableLigatures): Deleted.
        (WebCore::FontCascade::computeEnableLigatures): Deleted.
        * platform/graphics/WidthIterator.cpp:
        (WebCore::WidthIterator::WidthIterator):
        (WebCore::WidthIterator::applyFontTransforms):
        * platform/graphics/WidthIterator.h:
        * platform/graphics/cocoa/FontCacheCoreText.cpp:
        (WebCore::preparePlatformFont):
        * platform/graphics/cocoa/FontCocoa.mm:
        (WebCore::Font::canRenderCombiningCharacterSequence):
        * platform/graphics/mac/ComplexTextControllerCoreText.mm:
        (WebCore::ComplexTextController::collectComplexTextRunsForCharacters):
        * platform/graphics/mac/SimpleFontDataCoreText.cpp:
        (WebCore::Font::getCFStringAttributes):
        * svg/SVGFontData.h:

2015-10-19  Myles C. Maxfield  <mmaxfield@apple.com>

        Shadow GraphicsContext's ImageInterpolationQuality inside GraphicsContextState
        https://bugs.webkit.org/show_bug.cgi?id=150306

        Reviewed by Simon Fraser.

        When getting the ImageInterpolationQuality, there is no need to round-trip through
        the platform's graphics context. This patch migrates this piece of state to the
        existing idiom of having a setter in GraphicsContext.cpp which sets the relevent
        state in GraphicsContextState and then calls into a platform-specific setter.

        No new tests because there is no behavior change.

        * platform/graphics/GraphicsContext.cpp:
        (WebCore::GraphicsContext::setImageInterpolationQuality):
        * platform/graphics/GraphicsContext.h:
        (WebCore::GraphicsContext::imageInterpolationQuality):
        * platform/graphics/cairo/GraphicsContextCairo.cpp:
        (WebCore::GraphicsContext::setPlatformImageInterpolationQuality):
        (WebCore::GraphicsContext::setImageInterpolationQuality): Deleted.
        (WebCore::GraphicsContext::imageInterpolationQuality): Deleted.
        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::convertInterpolationQuality):
        (WebCore::GraphicsContext::platformInit):
        (WebCore::GraphicsContext::setPlatformImageInterpolationQuality):
        (WebCore::GraphicsContext::setImageInterpolationQuality): Deleted.
        (WebCore::GraphicsContext::imageInterpolationQuality): Deleted.

2015-10-19  Chris Dumez  <cdumez@apple.com>

        Drop unnecessary Node::toInputElement() virtual function
        https://bugs.webkit.org/show_bug.cgi?id=150341

        Reviewed by Darin Adler.

        Drop unnecessary Node::toInputElement() virtual function and use the
        usual is<HTMLInputElement>() / downcast< HTMLInputElement >() instead.

2015-10-19  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r191324.
        https://bugs.webkit.org/show_bug.cgi?id=150352

        Shadowing CTM's state is not necessary (Requested by litherum
        on #webkit).

        Reverted changeset:

        "Host GraphicsContext's CTM inside GraphicsContextState"
        https://bugs.webkit.org/show_bug.cgi?id=150146
        http://trac.webkit.org/changeset/191324

2015-10-19  Myles C. Maxfield  <mmaxfield@apple.com>

        Host GraphicsContext's CTM inside GraphicsContextState
        https://bugs.webkit.org/show_bug.cgi?id=150146

        There are 6 operations which interact with CTMs:
        - Get
        - Set
        - Concatenate
        - Scale
        - Rotate
        - Translate

        This patch modifies all these operations so that these operations shadow the
        platform's CTM inside GraphicsContextState. This way, we don't have to consult
        with the underlying graphics context in order to know the current CTM.

        There are currently many places in the Core Graphics ports where we will change
        the platform's CTM out from under the GraphicsContext. This patch migrates
        those users to going through GraphicsContext, thereby preserving the integrity
        of the shadowed state.

        No new tests because there is no behavior change.

        * platform/graphics/GraphicsContext.cpp: Setters deletate to platform calls.
        The getter can just consult with the shadowed state.
        (WebCore::GraphicsContext::concatCTM):
        (WebCore::GraphicsContext::scale):
        (WebCore::GraphicsContext::rotate):
        (WebCore::GraphicsContext::translate):
        (WebCore::GraphicsContext::setCTM):
        (WebCore::GraphicsContext::getCTM):
        (WebCore::GraphicsContext::beginTransparencyLayer):
        (WebCore::GraphicsContext::applyDeviceScaleFactor):
        * platform/graphics/GraphicsContext.h:
        (WebCore::GraphicsContext::scale):
        (WebCore::GraphicsContext::checkCTMInvariants): Make sure the shadowed state
        matches the platform graphics context's state.
        * platform/graphics/Image.h:
        (WebCore::Image::nativeImageForCurrentFrame):
        * platform/graphics/cairo/GraphicsContextCairo.cpp: Renaming functions.
        (WebCore::GraphicsContext::resetPlatformCTM):
        (WebCore::GraphicsContext::getPlatformCTM):
        (WebCore::GraphicsContext::translatePlatformCTM):
        (WebCore::GraphicsContext::concatPlatformCTM):
        (WebCore::GraphicsContext::setPlatformCTM):
        (WebCore::GraphicsContext::rotatePlatformCTM):
        (WebCore::GraphicsContext::scalePlatformCTM):
        (WebCore::GraphicsContext::getCTM): Deleted.
        (WebCore::GraphicsContext::translate): Deleted.
        (WebCore::GraphicsContext::concatCTM): Deleted.
        (WebCore::GraphicsContext::setCTM): Deleted.
        (WebCore::GraphicsContext::rotate): Deleted.
        (WebCore::GraphicsContext::scale): Deleted.
        * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
        Renaming functions.
        (WebCore::GraphicsContextPlatformPrivate::save):
        (WebCore::GraphicsContextPlatformPrivate::restore):
        (WebCore::GraphicsContextPlatformPrivate::flush):
        (WebCore::GraphicsContextPlatformPrivate::clip):
        (WebCore::GraphicsContextPlatformPrivate::scalePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::rotatePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::translatePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::concatPlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::setPlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::scale): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::rotate): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::translate): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::concatCTM): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::setCTM): Deleted.
        * platform/graphics/cg/GraphicsContextCG.cpp: Renaming functions. Also,
        migrate CTM setters to go through GraphicsContext.
        (WebCore::GraphicsContext::resetPlatformCTM):
        (WebCore::GraphicsContext::platformInit):
        (WebCore::GraphicsContext::drawNativeImage):
        (WebCore::GraphicsContext::drawPattern):
        (WebCore::GraphicsContext::fillPath):
        (WebCore::GraphicsContext::scalePlatformCTM):
        (WebCore::GraphicsContext::rotatePlatformCTM):
        (WebCore::GraphicsContext::translatePlatformCTM):
        (WebCore::GraphicsContext::concatPlatformCTM):
        (WebCore::GraphicsContext::setPlatformCTM):
        (WebCore::GraphicsContext::getPlatformCTM):
        (WebCore::GraphicsContext::scale): Deleted.
        (WebCore::GraphicsContext::rotate): Deleted.
        (WebCore::GraphicsContext::translate): Deleted.
        (WebCore::GraphicsContext::concatCTM): Deleted.
        (WebCore::GraphicsContext::setCTM): Deleted.
        (WebCore::GraphicsContext::getCTM): Deleted.
        * platform/graphics/cg/GraphicsContextPlatformPrivateCG.h:
        (WebCore::GraphicsContextPlatformPrivate::save):
        (WebCore::GraphicsContextPlatformPrivate::restore):
        (WebCore::GraphicsContextPlatformPrivate::flush):
        (WebCore::GraphicsContextPlatformPrivate::clip):
        (WebCore::GraphicsContextPlatformPrivate::scalePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::rotatePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::translatePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::concatPlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::setPlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::scale): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::rotate): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::translate): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::concatCTM): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::setCTM): Deleted.
        * platform/graphics/transforms/AffineTransform.h:
        (WebCore::AffineTransform::isEssentiallyEqualTo): Equality comparison on floats
        is not a good idea. Instead, this function is more valuable. (However, note that
        it is expected for values in a CTM to hold values close to 0, which means that
        this function might erroneously return false (similar to operator=()).
        * platform/graphics/win/GraphicsContextWin.cpp:
        (WebCore::GraphicsContextPlatformPrivate::scalePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::rotatePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::translatePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::concatPlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::setPlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::scale): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::rotate): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::translate): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::concatCTM): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::setCTM): Deleted.
        * platform/mac/DragImageMac.mm:
        (WebCore::drawAtPoint):
        * platform/spi/cg/CoreGraphicsSPI.h:

2015-10-19  Tim Horton  <timothy_horton@apple.com>

        Remove unused support for long presses from WebKit
        https://bugs.webkit.org/show_bug.cgi?id=150345

        Reviewed by Beth Dakin.

        * page/Chrome.cpp:
        (WebCore::Chrome::didBeginTrackingPotentialLongMousePress): Deleted.
        (WebCore::Chrome::didRecognizeLongMousePress): Deleted.
        (WebCore::Chrome::didCancelTrackingPotentialLongMousePress): Deleted.
        * page/Chrome.h:
        * page/ChromeClient.h:
        * page/EventHandler.cpp:
        (WebCore::EventHandler::EventHandler): Deleted.
        (WebCore::EventHandler::clear): Deleted.
        (WebCore::EventHandler::handleMousePressEvent): Deleted.
        (WebCore::EventHandler::eventMayStartDrag): Deleted.
        (WebCore::EventHandler::handleMouseReleaseEvent): Deleted.
        (WebCore::EventHandler::beginTrackingPotentialLongMousePress): Deleted.
        (WebCore::EventHandler::recognizeLongMousePress): Deleted.
        (WebCore::EventHandler::cancelTrackingPotentialLongMousePress): Deleted.
        (WebCore::EventHandler::clearLongMousePressState): Deleted.
        (WebCore::EventHandler::handleLongMousePressMouseMovedEvent): Deleted.
        (WebCore::EventHandler::handleMouseMoveEvent): Deleted.
        (WebCore::EventHandler::handleDrag): Deleted.
        * page/EventHandler.h:
        * page/Settings.in:

2015-10-19  Tim Horton  <timothy_horton@apple.com>

        WKView being inside WKWebView leads to weird API issues
        https://bugs.webkit.org/show_bug.cgi?id=150174

        Reviewed by Darin Adler.

        No new tests, just moving code around.

        * WebCore.xcodeproj/project.pbxproj:
        * platform/spi/mac/NSWindowSPI.h: Added.

2015-10-19  Simon Fraser  <simon.fraser@apple.com>

        Restore an assertion to the way it was before r191310, which was correct.

        * platform/graphics/GraphicsTypes.cpp:
        (WebCore::compositeOperatorName):

2015-10-19  Beth Dakin  <bdakin@apple.com>

        Build fix.

        * dom/EventNames.in:
        * dom/make_event_factory.pl:
        (generateImplementation):

2015-10-19  Csaba Osztrogonác  <ossy@webkit.org>

        Fix the binding generator after r191176
        https://bugs.webkit.org/show_bug.cgi?id=150320

        Reviewed by Darin Adler.

        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateConstructorHelperMethods):
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        (WebCore::JSTestInterfaceConstructor::getConstructData):

2015-10-19  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r191307.
        https://bugs.webkit.org/show_bug.cgi?id=150338

        broke lots of API tests, need time to figure out whats up
        (Requested by thorton on #webkit).

        Reverted changeset:

        "WKView being inside WKWebView leads to weird API issues"
        https://bugs.webkit.org/show_bug.cgi?id=150174
        http://trac.webkit.org/changeset/191307

2015-10-19  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r191295, r191297, and r191301.
        https://bugs.webkit.org/show_bug.cgi?id=150337

        ASSERTs in 5 tests (Requested by litherum on #webkit).

        Reverted changesets:

        "Host GraphicsContext's CTM inside GraphicsContextState"
        https://bugs.webkit.org/show_bug.cgi?id=150146
        http://trac.webkit.org/changeset/191295

        "[iOS] Build fix after r191295"
        http://trac.webkit.org/changeset/191297

        "Unreviewed build fix after r191295."
        http://trac.webkit.org/changeset/191301

2015-10-16  Brian Burg  <bburg@apple.com>

        Unify handling of JavaScriptCore scripts that are used in WebCore
        https://bugs.webkit.org/show_bug.cgi?id=150245

        Reviewed by Alex Christensen.

        Use the new JavaScriptCore_SCRIPTS_DIR variable.

        * CMakeLists.txt:
        * DerivedSources.make:
        * WebCore.xcodeproj/project.pbxproj:

            No need to export other variables like InspectorScripts anymore.

2015-10-19  Simon Fraser  <simon.fraser@apple.com>

        Add TextStream formatters for FillLayer and all it entails
        https://bugs.webkit.org/show_bug.cgi?id=150312

        Reviewed by Tim Horton.

        Add TextStream output formatters for FillLayer, and all the enum
        types used by it.
        
        Drive-by fixes for CompositeOperator and BlendMode string conversions.
        compositeOperatorNames was missing the "difference" string, and compositeOperatorName()
        would do an OOB memory access if blendOp was zero.

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:
        * platform/Length.cpp:
        (WebCore::operator<<):
        * platform/Length.h:
        * platform/LengthSize.cpp: Added.
        (WebCore::operator<<):
        * platform/LengthSize.h:
        * platform/text/TextStream.h:
        * rendering/style/FillLayer.cpp:
        (WebCore::operator<<):
        * rendering/style/FillLayer.h:
        * rendering/style/RenderStyleConstants.cpp: Added.
        (WebCore::operator<<):
        * rendering/style/RenderStyleConstants.h:

2015-10-19  Tim Horton  <timothy_horton@apple.com>

        WKView being inside WKWebView leads to weird API issues
        https://bugs.webkit.org/show_bug.cgi?id=150174

        Reviewed by Darin Adler.

        No new tests, just moving code around.

        * WebCore.xcodeproj/project.pbxproj:
        * platform/spi/mac/NSWindowSPI.h: Added.

2015-10-19  Tim Horton  <timothy_horton@apple.com>

        Try to fix the iOS build

        * Configurations/FeatureDefines.xcconfig:

2015-10-19  Alex Christensen  <achristensen@webkit.org>

        Unreviewed build fix after r191295.

        * platform/graphics/cairo/GraphicsContextCairo.cpp:
        (WebCore::GraphicsContext::translatePlatformCTM):
        (WebCore::GraphicsContext::setPlatformFillColor):
        (WebCore::GraphicsContext::concatPlatformCTM):
        (WebCore::GraphicsContext::setPlatformCTM):
        (WebCore::GraphicsContext::setPlatformShadow):
        (WebCore::GraphicsContext::rotatePlatformCTM):
        (WebCore::GraphicsContext::scalePlatformCTM):
        (WebCore::GraphicsContext::clipOut):
        * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
        (WebCore::GraphicsContextPlatformPrivate::save):
        (WebCore::GraphicsContextPlatformPrivate::restore):
        (WebCore::GraphicsContextPlatformPrivate::flush):
        (WebCore::GraphicsContextPlatformPrivate::clip):
        (WebCore::GraphicsContextPlatformPrivate::scalePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::rotatePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::translatePlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::concatPlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::setPlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::syncContext):
        (WebCore::GraphicsContextPlatformPrivate::scale): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::rotate): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::translate): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::concatCTM): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::setCTM): Deleted.

2015-10-19  Tim Horton  <timothy_horton@apple.com>

        Add magnify and rotate gesture event support for Mac
        https://bugs.webkit.org/show_bug.cgi?id=150179
        <rdar://problem/8036240>

        Reviewed by Darin Adler.

        No new tests.

        * Configurations/FeatureDefines.xcconfig:
        New feature flag.

        * Configurations/WebCore.xcconfig:
        Don't exclude generated gesture sources; they are already #ifdef-guarded.

        * DerivedSources.make:
        Add GestureEvent.idl for ENABLE_MAC_GESTURE_EVENTS too.

        * WebCore.xcodeproj/project.pbxproj:
        Add GestureEvents.cpp.

        * bindings/objc/DOMEvents.mm:
        (kitClass):
        Support DOMGestureEvent on Mac if the new flag is enabled.

        * dom/mac/GestureEvents.cpp: Added.
        * page/mac/EventHandlerMac.mm:

        * page/EventHandler.cpp:
        (WebCore::EventHandler::clear):
        * page/EventHandler.h:
        Enable some gesture-related code on Mac if the new flag is enabled.

        * platform/PlatformEvent.h:

2015-10-19  Myles C. Maxfield  <mmaxfield@apple.com>

        [iOS] Build fix after r191295

        Unreviewed.

        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::GraphicsContext::resetPlatformCTM):

2015-10-19  Myles C. Maxfield  <mmaxfield@apple.com>

        Host GraphicsContext's CTM inside GraphicsContextState
        https://bugs.webkit.org/show_bug.cgi?id=150146

        Reviewed by Simon Fraser.

        There are 6 operations which interact with CTMs:
        - Get
        - Set
        - Concatenate
        - Scale
        - Rotate
        - Translate

        This patch modifies all these operations so that these operations shadow the
        platform's CTM inside GraphicsContextState. This way, we don't have to consult
        with the underlying graphics context in order to know the current CTM.

        There are currently many places in the Core Graphics ports where we will change
        the platform's CTM out from under the GraphicsContext. This patch migrates
        those users to going through GraphicsContext, thereby preserving the integrity
        of the shadowed state.

        No new tests because there is no behavior change.

        * platform/graphics/GraphicsContext.cpp: Setters deletate to platform calls.
        The getter can just consult with the shadowed state.
        (WebCore::GraphicsContext::concatCTM):
        (WebCore::GraphicsContext::scale):
        (WebCore::GraphicsContext::rotate):
        (WebCore::GraphicsContext::translate):
        (WebCore::GraphicsContext::setCTM):
        (WebCore::GraphicsContext::getCTM):
        (WebCore::GraphicsContext::beginTransparencyLayer):
        (WebCore::GraphicsContext::applyDeviceScaleFactor):
        * platform/graphics/GraphicsContext.h:
        (WebCore::GraphicsContext::scale):
        (WebCore::GraphicsContext::checkCTMInvariants): Make sure the shadowed state
        matches the platform graphics context's state.
        * platform/graphics/cairo/GraphicsContextCairo.cpp: Renaming functions.
        (WebCore::GraphicsContext::resetPlatformCTM):
        (WebCore::GraphicsContext::getPlatformCTM):
        (WebCore::GraphicsContext::translatePlatformCTM):
        (WebCore::GraphicsContext::concatPlatformCTM):
        (WebCore::GraphicsContext::setPlatformCTM):
        (WebCore::GraphicsContext::rotatePlatformCTM):
        (WebCore::GraphicsContext::scalePlatformCTM):
        (WebCore::GraphicsContext::getCTM): Deleted.
        (WebCore::GraphicsContext::translate): Deleted.
        (WebCore::GraphicsContext::concatCTM): Deleted.
        (WebCore::GraphicsContext::setCTM): Deleted.
        (WebCore::GraphicsContext::rotate): Deleted.
        (WebCore::GraphicsContext::scale): Deleted.
        * platform/graphics/cg/GraphicsContextCG.cpp: Renaming functions. Also,
        migrate CTM setters to go through GraphicsContext.
        (WebCore::GraphicsContext::resetPlatformCTM):
        (WebCore::GraphicsContext::platformInit):
        (WebCore::GraphicsContext::drawNativeImage):
        (WebCore::drawPatternCallback):
        (WebCore::GraphicsContext::drawPattern):
        (WebCore::GraphicsContext::fillPath):
        (WebCore::GraphicsContext::strokePath):
        (WebCore::GraphicsContext::fillRect):
        (WebCore::GraphicsContext::strokeRect):
        (WebCore::GraphicsContext::scalePlatformCTM):
        (WebCore::GraphicsContext::rotatePlatformCTM):
        (WebCore::GraphicsContext::translatePlatformCTM):
        (WebCore::GraphicsContext::concatPlatformCTM):
        (WebCore::GraphicsContext::setPlatformCTM):
        (WebCore::GraphicsContext::getPlatformCTM):
        (WebCore::GraphicsContext::scale): Deleted.
        (WebCore::GraphicsContext::rotate): Deleted.
        (WebCore::GraphicsContext::translate): Deleted.
        (WebCore::GraphicsContext::concatCTM): Deleted.
        (WebCore::GraphicsContext::setCTM): Deleted.
        (WebCore::GraphicsContext::getCTM): Deleted.
        * platform/graphics/cg/GraphicsContextPlatformPrivateCG.h:
        (WebCore::GraphicsContextPlatformPrivate::save):
        (WebCore::GraphicsContextPlatformPrivate::restore):
        (WebCore::GraphicsContextPlatformPrivate::flush):
        (WebCore::GraphicsContextPlatformPrivate::clip):
        (WebCore::GraphicsContextPlatformPrivate::scale):
        (WebCore::GraphicsContextPlatformPrivate::rotate):
        (WebCore::GraphicsContextPlatformPrivate::translate):
        (WebCore::GraphicsContextPlatformPrivate::concatCTM):
        (WebCore::GraphicsContextPlatformPrivate::setCTM):
        * platform/graphics/transforms/AffineTransform.h:
        (WebCore::AffineTransform::isEssentiallyEqualTo): Equality comparison on floats
        is not a good idea. Instead, this function is more valuable. (However, note that
        it is expected for values in a CTM to hold values close to 0, which means that
        this function might erroneously return false (similar to operator=()).
        * platform/graphics/win/GraphicsContextWin.cpp:
        (WebCore::GraphicsContextPlatformPrivate::scale):
        (WebCore::GraphicsContextPlatformPrivate::concatPlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::setPlatformCTM):
        (WebCore::GraphicsContextPlatformPrivate::concatCTM): Deleted.
        (WebCore::GraphicsContextPlatformPrivate::setCTM): Deleted.
        * platform/mac/DragImageMac.mm:
        (WebCore::drawAtPoint):

2015-10-19  Chris Dumez  <cdumez@apple.com>

        Null dereference loading Blink layout test fast/forms/color/input-color-onchange-event.html
        https://bugs.webkit.org/show_bug.cgi?id=150192
        <rdar://problem/23135050>

        Reviewed by Darin Adler.

        Calling internals.selectColorInColorChooser() with a non-Element would
        cause a null dereference. This is because in such case, the implementation
        method is passed a null pointer and we would fail to null-check it. This
        patch now does the null-check.

        No new tests, existing test was updated.

        * testing/Internals.cpp:
        (WebCore::Internals::selectColorInColorChooser):

2015-10-19  Csaba Osztrogonác  <ossy@webkit.org>

        Fix the !ENABLE(CSS_GRID_LAYOUT) build after r190840
        https://bugs.webkit.org/show_bug.cgi?id=150322

        Reviewed by Ryosuke Niwa.

        * html/HTMLDetailsElement.cpp:

2015-10-19  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Binding generator should generate names for JSBuiltins partial interface methods using ImplementedBy value
        https://bugs.webkit.org/show_bug.cgi?id=150163

        Reviewed by Darin Adler.

        Covered by updated binding tests.

        Updating generation of JS built-in function/attribute name to use the ImplementedBy value of the interface if any.
        This allows splitting JS built-ins just like is done for IDLs.
        Updated accordingly the JS Builtin header include.

        * bindings/scripts/CodeGeneratorJS.pm:
        (GetAttributeGetterName): Updated to pass function object and not only function name.
        (GetAttributeSetterName): Ditto.
        (GetFunctionName): Removed unneeded code plus updated to pass function object and not only function name.
        (GenerateConstructorHelperMethods): Making direct use of GetJSBuiltinFunctionNameFromString since there is no function object for the constructor.
        (GetJSBuiltinFunctionName): Updated to take into accound ImplementedBy value if any.
        (GetJSBuiltinFunctionNameFromString):
        (GetJSBuiltinScopeName): Returns either the interface name or its ImplementedBy value.
        (AddJSBuiltinIncludesIfNeeded): Updating name of the header in case of partial interface.
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        * bindings/scripts/test/ObjC/DOMTestInterface.h:
        * bindings/scripts/test/ObjC/DOMTestInterface.mm:
        (-[DOMTestInterface builtinAttribute]):
        (-[DOMTestInterface setBuiltinAttribute:]):
        (-[DOMTestInterface builtinFunction]):
        * bindings/scripts/test/TestSupplemental.idl: Added JSBuiltin attribute and function.

2015-10-19  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Binding generator should allow generating private JS functions
        https://bugs.webkit.org/show_bug.cgi?id=150167

        Reviewed by Darin Adler.

        Introducing the "Private" keyword for that purpose.
        Applying it to MediaDevices.getUserMedia which can be used directly or through navigator.webkitGetUserMedia
        which could be implemented as JS builtin based on it.

        "Private" functions are added to the prototype with a corresponding private symbol.
        This symbol must be defined in bindings/js/WebCoreBuiltinNames.h.

        Adding a getUserMediaFromJS function visible from builtins script.
        Implementing MediaDevices.getUserMedia as a JS builtin based on it.

        Adding binding generator test.

        * CMakeLists.txt: Adding MediaDevices.js.
        * DerivedSources.make: Ditto.
        * Modules/mediastream/MediaDevices.h:
        (WebCore::MediaDevices::getUserMediaFromJS):
        * Modules/mediastream/MediaDevices.idl: Marking getUserMediaFromJS private and getUserMedia JSBuiltin.
        * Modules/mediastream/MediaDevices.js: Added.
        (getUserMedia):
        * bindings/js/WebCoreBuiltinNames.h:
        * bindings/js/WebCoreJSBuiltins.cpp:
        * bindings/js/WebCoreJSBuiltins.h:
        (WebCore::JSBuiltinFunctions::JSBuiltinFunctions):
        (WebCore::JSBuiltinFunctions::mediaDevicesBuiltins):
        * bindings/scripts/CodeGeneratorGObject.pm: Skipping generation of Private functions.
        (SkipFunction):
        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateImplementation): Disabling addition of private function in table and adding private member field to the prototype.
        * bindings/scripts/CodeGeneratorObjC.pm: Skipping generation of Private functions.
        (SkipFunction):
        * bindings/scripts/IDLAttributes.txt: Adding Private keyword.
        * bindings/scripts/test/JS/JSTestObj.cpp: Adding Private keyword test.
        (WebCore::JSTestObjPrototype::finishCreation):
        (WebCore::jsTestObjPrototypeFunctionPrivateMethod):
        * bindings/scripts/test/TestObj.idl:

2015-10-19  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        [Streams API] Implement ReadableStream tee
        https://bugs.webkit.org/show_bug.cgi?id=146315

        Reviewed by Darin Adler.

        Covered by rebased test.

        * Modules/streams/ReadableStream.js:
        (tee): Removing not implemented exception throwing.
        * Modules/streams/ReadableStreamInternals.js:
        (teeReadableStream): Implementing as per spec.
        (teeReadableStreamPullFunction): Ditto.
        (teeReadableStreamBranch2CancelFunction): Ditto.

2015-10-19  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        [Streams API] Add skeleton for initial WritableStream support
        https://bugs.webkit.org/show_bug.cgi?id=149951

        Reviewed by Darin Adler.

        This basically adds an empty WritableStream object without initializing the object. It also adds all empty
        methods by raising an exception.

        The reason why the object is not fully initialized is that it requires some other support and some refactorings
        to share more code with ReadableStream and we will make in following patches.

        Tests are covered by current set and their expectations are properly updated.

        * CMakeLists.txt:
        * DerivedSources.cpp:
        * DerivedSources.make:
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/WebCoreJSBuiltins.cpp:
        * bindings/js/WebCoreJSBuiltins.h: Build infrastructure.
        * Modules/streams/WritableStream.idl: Added all methods and attributes.
        * Modules/streams/WritableStream.js:
        (initializeWritableStream):
        (abort):
        (close):
        (write):
        (closed):
        (ready):
        (state): Added all by throwing an EvalError.

2015-10-18  Chris Dumez  <cdumez@apple.com>

        Script element with an empty for or event attributes should not execute
        https://bugs.webkit.org/show_bug.cgi?id=148855
        <rdar://problem/22588156>

        Reviewed by Darin Adler.

        A script element with an empty for or event attributes should not execute
        as per:
        https://html.spec.whatwg.org/multipage/scripting.html#prepare-a-script (step 12)

        Our implementation had a bug where it would not correctly differentiate
        an empty attribute from a missing one. This patch fixes this.

        No new tests, already covered by existing test.

        * dom/ScriptElement.cpp:
        (WebCore::ScriptElement::isScriptForEventSupported):

2015-10-18  Chris Dumez  <cdumez@apple.com>

        WebKit must support all JavaScript MIME types in HTML5 spec
        https://bugs.webkit.org/show_bug.cgi?id=148854
        <rdar://problem/22588195>

        Reviewed by Darin Adler.

        WebKit did not execute certain EcmaScript MIME types although the HTML
        specification says all user agents should support those:
        https://html.spec.whatwg.org/multipage/scripting.html#javascript-mime-type

        In particular, the following MIME types are now recognized as valid and
        executed: "application/x-ecmascript", "text/javascript1.0",
        "text/javascript1.4", "text/javascript1.5", "text/x-javascript",
        "text/x-ecmascript".

        The new behavior is consistent with Firefox.

        No new tests, already covered by existing test.

        * platform/MIMETypeRegistry.cpp:
        (WebCore::initializeSupportedJavaScriptMIMETypes):

2015-10-18  Sungmann Cho  <sungmann.cho@navercorp.com>

        [Win] Fix the Windows builds.
        https://bugs.webkit.org/show_bug.cgi?id=150300

        Reviewed by Darin Adler.

        Add missing files to WebCore.vcxproj.
        Add missing #includes to CSSAllInOne.cpp and HTMLElementsAllInOne.cpp.

        No new tests, no behavior change.

        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * css/CSSAllInOne.cpp:
        * html/HTMLElementsAllInOne.cpp:

2015-10-18  Sungmann Cho  <sungmann.cho@navercorp.com>

        Fix the builds with ENABLE_CONTENT_EXTENSIONS=OFF.
        https://bugs.webkit.org/show_bug.cgi?id=150302

        Reviewed by Darin Adler.

        Add missing #if ENABLE(CONTENT_EXTENSIONS).

        No new tests, no behavior change.

        * page/UserContentController.h:

2015-10-18  Joonghun Park  <jh718.park@samsung.com>

        [EFL] Fix debug build break since r191198
        https://bugs.webkit.org/show_bug.cgi?id=150277

        Reviewed by Darin Adler.

        No new tests, no new behaviours.

        Use the correct %"PRIu64" for uint64_t,
        instead of %llu.

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::fireVersionChangeEvent):
        * Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBOpenDBRequest::onUpgradeNeeded):
        * Modules/indexeddb/legacy/IDBDatabaseBackend.cpp:
        (WebCore::IDBDatabaseBackend::processPendingOpenCalls):
        (WebCore::IDBDatabaseBackend::openConnectionInternal):
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::notifyConnectionsOfVersionChange):

2015-10-18  Sungmann Cho  <sungmann.cho@navercorp.com>

        Fix the builds with ENABLE_INDEX_DATABASE=OFF.
        https://bugs.webkit.org/show_bug.cgi?id=150301

        Reviewed by Darin Adler.

        Add missing #if ENABLE(INDEXED_DATABASE).

        No new tests, no behavior change.

        * page/Page.cpp:

2015-10-18  Myles C. Maxfield  <mmaxfield@apple.com>

        [Cocoa] [Win] Remove unused code from GraphicsContext
        https://bugs.webkit.org/show_bug.cgi?id=150304

        Reviewed by Darin Adler.

        No new tests because there is no behavior change.

        * platform/graphics/GraphicsContext.h:
        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::GraphicsContext::setAllowsFontSmoothing): Deleted.

2015-10-18  Antti Koivisto  <antti@apple.com>

        Computed style should work correctly with slotted elements that have display:none
        https://bugs.webkit.org/show_bug.cgi?id=150237

        Reviewed by Andreas Kling..

        If an element has display:none we don't normally retain or even compute its style (as it is not rendered).
        If getComputedStyle is invoked for such element we resolve the style (along with any ancestors) and cache
        it separately to rare data. This path needs to work with slotted elements in shadow trees.

        This patch also make computedStyle() iterative rather than recursive.

        Test: fast/shadow-dom/computed-style-display-none.html

        * dom/Document.cpp:
        (WebCore::Document::styleForElementIgnoringPendingStylesheets):

            Pass in the parent style instead of invoking computedStyle() recursively.

        * dom/Document.h:
        * dom/Element.cpp:
        (WebCore::beforeOrAfterPseudoElement):
        (WebCore::Element::existingComputedStyle):
        (WebCore::Element::resolveComputedStyle):

            Iterative resolve function that uses composed tree iterator.

        (WebCore::Element::computedStyle):

            Factor into helpers.

        * dom/Element.h:
        * dom/Node.cpp:
        (WebCore::Node::computedStyle):

            Use the composed tree iterator.

        * html/HTMLSelectElement.cpp:
        (WebCore::HTMLSelectElement::selectOption):

            Call updateValidity() before calling renderer->updateFromElement(). Calling updateFromElement()
            may end up in Element::computedStyle() which can asserts if validity is not up to date.

2015-10-18  Myles C. Maxfield  <mmaxfield@apple.com>

        Stop honoring the user default "WebKitKerningAndLigaturesEnabledByDefault"
        https://bugs.webkit.org/show_bug.cgi?id=150287

        Reviewed by Simon Fraser.

        This user default is currently on by default. Therefore, by setting the user default,
        users can only disable kerning / ligatures (rather than enable it).

        There are a few reasons why we should stop honoring it:

        1. In the brave new world of font-feature-settings and font-variant-ligatures, there
        are many different kinds of ligatures which may be enabled at will. The simplistic
        statement of "turn on ligatures" no longer has any meaning.

        2. If a user wants to disable kerning / ligatures, he/she can do it with a user
        stylesheet.

        3. The default isn't able to be tested with DumpRenderTree or WebKitTestRunner.

        4. I have never heard of anyone actually using this user default.

        * platform/graphics/FontCascade.cpp:
        (WebCore::FontCascade::setDefaultKerning): Deleted.
        (WebCore::FontCascade::setDefaultLigatures): Deleted.
        * platform/graphics/FontCascade.h:
        (WebCore::FontCascade::advancedTextRenderingMode):

2015-10-18  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r191250 and r191253.
        https://bugs.webkit.org/show_bug.cgi?id=150296

        Broke all the tests on Windows (Requested by ap on #webkit).

        Reverted changesets:

        "Stop honoring the user default
        "WebKitKerningAndLigaturesEnabledByDefault""
        https://bugs.webkit.org/show_bug.cgi?id=150287
        http://trac.webkit.org/changeset/191250

        "Build fix after r191250"
        http://trac.webkit.org/changeset/191253

2015-10-17  David Hyatt  <hyatt@apple.com>

        Implement the CSS4 'revert' keyword.
        https://bugs.webkit.org/show_bug.cgi?id=149702

        Reviewed by Simon Fraser.

        Added new tests in fast/css and fast/css/variables.

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:
        Add CSSRevertValue to the project and makefiles.

        * css/CSSParser.cpp:
        (WebCore::parseKeywordValue):
        Make sure to handle "revert" in the keyword parsing path (along with inherit/initial/unset).

        (WebCore::CSSParser::parseValue):
        (WebCore::CSSParser::parseCustomPropertyDeclaration):
        At the parser level, "revert" is just like inherit/initial/unset and gets its own special
        singleton value, CSSRevertValue.

        * css/CSSRevertValue.cpp: Added.
        (WebCore::CSSRevertValue::customCSSText):
        * css/CSSRevertValue.h: Added.
        (WebCore::CSSRevertValue::create):
        (WebCore::CSSRevertValue::equals):
        (WebCore::CSSRevertValue::CSSRevertValue):
        This value is identical to the inherit/initial/unset values, i.e., its own special value
        that can be used to indicate a revert when doing style resolution.

        * css/CSSValue.cpp:
        (WebCore::CSSValue::cssValueType):
        (WebCore::CSSValue::equals):
        (WebCore::CSSValue::cssText):
        (WebCore::CSSValue::destroy):
        * css/CSSValue.h:
        (WebCore::CSSValue::isInheritedValue):
        (WebCore::CSSValue::isInitialValue):
        (WebCore::CSSValue::isUnsetValue):
        (WebCore::CSSValue::isRevertValue):
        Add the RevertClass to CSSValue and make sure it is handled in all the appropriate methods.

        * css/CSSValueKeywords.in:
        Add the "revert" keyword to the list of allowed CSS keywords.

        * css/CSSValuePool.cpp:
        (WebCore::CSSValuePool::CSSValuePool):
        * css/CSSValuePool.h:
        (WebCore::CSSValuePool::createRevertValue):
        Add support for a CSSRevertValue singleton, just like inherit/unset/initial.

        * css/FontLoader.cpp:
        (WebCore::FontLoader::resolveFontStyle):
        Add "unset" and "revert" as special keywords to be ignored. This code seems to be turned off,
        but patching it anyway.

        * css/SelectorChecker.h:
        Add a MatchDefault value of 0 to the LinkMatchMask. This enables it to be used as an index
        to the correct value in Property (in the style resolution code).

        * css/StyleResolver.cpp:
        (WebCore::StyleResolver::State::initForStyleResolve):
        Delete any lingering old CascadedProperty rollbacks for UA/user rules.

        (WebCore::StyleResolver::styleForKeyframe):
        (WebCore::StyleResolver::styleForPage):
        (WebCore::StyleResolver::applyMatchedProperties):
        Pass along the MatchResult as an additional parameter, since we need it to lazily compute
        the cascade rollbacks if the "revert" keyword is encountered.

        (WebCore::StyleResolver::cascadedPropertiesForRollback):
        This method will lazily create and return a new CascadedProperties pointer that is cached
        in the StyleResolver's state. This will contain only UA rules (for user reverts) and UA/user
        rules (for author reverts). These will only be computed at most once for a given element
        when doing a reversion, and they will be computed lazily, i.e., only if a revert is
        requested.

        (WebCore::StyleResolver::applyProperty):
        Pass along the LinkMatchMask and the MatchResult to applyProperty. This way we know specifically
        which link type we were computing if we have to revert (so that we roll back and look at the
        same index in the reverted version). The MatchResult is passed along because it is needed
        to build the CascadedProperties rollbacks.

        The basic idea is that if a revert is encountered, the level that the rule came from is
        checked. If it is UA level, just treat as "unset." If it is author or user level, get
        the correct CascadedProperties rollback and repeat the applyProperty using the property
        found in the rollback. If the property is not present in the cascade rollback, then the
        revert becomes an unset.

        (WebCore::StyleResolver::CascadedProperties::hasCustomProperty):
        (WebCore::StyleResolver::CascadedProperties::customProperty):
        Helpers used by applyProperty to check on custom properties, since they can revert too
        just like a regular property can.

        (WebCore::StyleResolver::CascadedProperties::setPropertyInternal):
        (WebCore::StyleResolver::CascadedProperties::set):
        (WebCore::StyleResolver::CascadedProperties::setDeferred):
        Passing along the CascadeLevel (UA, User, Author) so that it can be stored in the Property.
        This way when we do property application, we always know where the rule came from so
        that the reversion can be handled properly.

        (WebCore::StyleResolver::CascadedProperties::addStyleProperties):
        (WebCore::cascadeLevelForIndex):
        (WebCore::StyleResolver::CascadedProperties::addMatches):
        When style properties are added, also figure out the CascadeLevel and pass it along to be
        stored in the Property. We use the MatchResult's ranges to know where a property comes from.

        (WebCore::StyleResolver::CascadedProperties::applyDeferredProperties):
        (WebCore::StyleResolver::CascadedProperties::Property::apply):
        (WebCore::StyleResolver::applyCascadedProperties):
        Pass along the MatchResult so we know how to build the rollback.

        * css/StyleResolver.h:
        (WebCore::StyleResolver::State::cascadeLevel):
        (WebCore::StyleResolver::State::setCascadeLevel):
        (WebCore::StyleResolver::State::authorRollback):
        (WebCore::StyleResolver::State::userRollback):
        (WebCore::StyleResolver::State::setAuthorRollback):
        (WebCore::StyleResolver::State::setUserRollback):
        (WebCore::StyleResolver::state):
        (WebCore::StyleResolver::cascadeLevel):
        (WebCore::StyleResolver::setCascadeLevel):
        Move CascadedProperties into the header. Add CascadeLevel to Property. Add the level and
        rollbacks to the resolver's state.

2015-10-17  Myles C. Maxfield  <mmaxfield@apple.com>

        Delete FontPlatformData::allowsLigatures()
        https://bugs.webkit.org/show_bug.cgi?id=150286

        Reviewed by Dan Bernstein.

        This function is only used to force ligatures on for complex fonts (where "complex"
        means "does not support the letter 'a'"). However, ligatures are turned on for all
        fonts by default, which means that this function is unnecessary.

        Required ligatures, such as those which make these complex scripts legible, are always
        enabled, no matter what.

        Test: fast/text/required-ligatures.html

        * platform/graphics/FontPlatformData.h:
        * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
        (WebCore::FontPlatformData::allowsLigatures): Deleted.
        * platform/graphics/mac/SimpleFontDataCoreText.cpp:
        (WebCore::Font::getCFStringAttributes):

2015-10-17  Myles C. Maxfield  <mmaxfield@apple.com>

        Stop honoring the user default "WebKitKerningAndLigaturesEnabledByDefault"
        https://bugs.webkit.org/show_bug.cgi?id=150287

        Reviewed by Simon Fraser.

        This user default is currently on by default. Therefore, by setting the user default,
        users can only disable kerning / ligatures (rather than enable it).

        There are a few reasons why we should stop honoring it:

        1. In the brave new world of font-feature-settings and font-variant-ligatures, there
        are many different kinds of ligatures which may be enabled at will. The simplistic
        statement of "turn on ligatures" no longer has any meaning.

        2. If a user wants to disable kerning / ligatures, he/she can do it with a user
        stylesheet.

        3. The default isn't able to be tested with DumpRenderTree or WebKitTestRunner.

        4. I have never heard of anyone actually using this user default.

        * platform/graphics/FontCascade.cpp:
        (WebCore::FontCascade::setDefaultKerning): Deleted.
        (WebCore::FontCascade::setDefaultLigatures): Deleted.
        * platform/graphics/FontCascade.h:
        (WebCore::FontCascade::advancedTextRenderingMode):

2015-10-17  Dan Bernstein  <mitz@apple.com>

        [Cocoa] Stop using WKAXRegisterRemoteApp
        https://bugs.webkit.org/show_bug.cgi?id=150283

        Reviewed by Alexey Proskuryakov.

        * platform/spi/ios/GraphicsServicesSPI.h: Added declaration of GSSystemRootDirectory.

2015-10-17  Chris Dumez  <cdumez@apple.com>

        td and th should use HTMLTableDataCellElement and HTMLTableHeaderCellElement interfaces
        https://bugs.webkit.org/show_bug.cgi?id=148859
        <rdar://problem/22588664>

        Reviewed by Ryosuke Niwa.

        td and th should use HTMLTableDataCellElement and HTMLTableHeaderCellElement interfaces
        as per the latest HTML specification:
        https://html.spec.whatwg.org/multipage/tables.html#htmltabledatacellelement
        https://html.spec.whatwg.org/multipage/tables.html#htmltableheadercellelement

        This patch aligns our behavior with the specification and IE. Firefox and Chrome do not
        seem to expose HTMLTableDataCellElement / HTMLTableHeaderCellElement at this time.

        The compatibility risk is low, given that the API stays the same and those new
        interfaces inherit the pre-existing HTMLTableCellElement interface.

        No new tests, already covered by existing tests.

        * CMakeLists.txt:
        * DerivedSources.cpp:
        * DerivedSources.make:
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * WebCore.xcodeproj/project.pbxproj:
        * html/HTMLTableCellElement.cpp:
        (WebCore::HTMLTableCellElement::HTMLTableCellElement):
        (WebCore::HTMLTableCellElement::colSpan): Deleted.
        * html/HTMLTableCellElement.h:
        * html/HTMLTableCellElement.idl:
        * html/HTMLTableDataCellElement.h: Added.
        * html/HTMLTableDataCellElement.idl: Added.
        * html/HTMLTableHeaderCellElement.h: Added.
        * html/HTMLTableHeaderCellElement.idl: Added.
        * html/HTMLTableRowElement.cpp:
        (WebCore::HTMLTableRowElement::insertCell):
        * html/HTMLTagNames.in:

2015-10-17  Zalan Bujtas  <zalan@apple.com>

        RenderBlockFlow::xPositionForFloatIncludingMargin/yPositionForFloatIncludingMargin/flipFloatForWritingModeForChild
        should all take FloatingObject reference.
        https://bugs.webkit.org/show_bug.cgi?id=150267

        Reviewed by Simon Fraser.

        No change in behaviour.

        * rendering/RenderBlockFlow.cpp:
        (WebCore::RenderBlockFlow::addOverflowFromFloats):
        (WebCore::RenderBlockFlow::paintFloats):
        (WebCore::RenderBlockFlow::clipOutFloatingObjects):
        (WebCore::RenderBlockFlow::addOverhangingFloats):
        (WebCore::RenderBlockFlow::flipFloatForWritingModeForChild):
        (WebCore::RenderBlockFlow::hitTestFloats):
        (WebCore::RenderBlockFlow::adjustForBorderFit):
        * rendering/RenderBlockFlow.h:
        (WebCore::RenderBlockFlow::xPositionForFloatIncludingMargin):
        (WebCore::RenderBlockFlow::yPositionForFloatIncludingMargin):

2015-10-17  Simon Fraser  <simon.fraser@apple.com>

        Sort the project file.

        * WebCore.xcodeproj/project.pbxproj:

2015-10-16  Simon Fraser  <simon.fraser@apple.com>

        Enhance TextStream for logging, remove subclasses, log more things
        https://bugs.webkit.org/show_bug.cgi?id=150269

        Reviewed by Zalan Bujtas.

        Remove the various TextStream subclasses that only existed to support indenting,
        and output additional types. Add output for more WebCore and WebKit2 types, and
        just use TextStream everywhere.
        
        TextStream is enhance to support grouping (open paren and intent), with a 
        stack-based class to open/end a group.
        
        Remove some SVG-specific duplicate output functions.
        
        Outdent namespace contents of GraphicsTypes.h.
        
        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:
        * dom/ViewportArguments.cpp:
        (WebCore::operator<<):
        * dom/ViewportArguments.h:
        * page/ViewportConfiguration.cpp:
        (WebCore::operator<<):
        (WebCore::ViewportConfiguration::description):
        (WebCore::ViewportConfigurationTextStream::ViewportConfigurationTextStream): Deleted.
        (WebCore::ViewportConfigurationTextStream::increaseIndent): Deleted.
        (WebCore::ViewportConfigurationTextStream::decreaseIndent): Deleted.
        (WebCore::dumpProperty): Deleted.
        (WebCore::ViewportConfigurationTextStream::writeIndent): Deleted.
        (WebCore::ViewportConfigurationTextStream::operator<<): Deleted.
        * page/ViewportConfiguration.h:
        * page/scrolling/ScrollingConstraints.cpp:
        (WebCore::operator<<):
        * page/scrolling/ScrollingConstraints.h:
        * page/scrolling/ScrollingCoordinator.cpp:
        (WebCore::operator<<):
        * page/scrolling/ScrollingCoordinator.h:
        * platform/animation/TimingFunction.cpp: Added.
        (WebCore::operator<<):
        * platform/animation/TimingFunction.h:
        * platform/graphics/Color.cpp:
        (WebCore::operator<<):
        * platform/graphics/Color.h:
        * platform/graphics/FloatPoint3D.cpp:
        (WebCore::operator<<):
        * platform/graphics/FloatPoint3D.h:
        * platform/graphics/FloatRoundedRect.cpp:
        (WebCore::operator<<):
        * platform/graphics/FloatRoundedRect.h:
        * platform/graphics/GraphicsLayer.cpp:
        (WebCore::operator<<):
        * platform/graphics/GraphicsLayer.h:
        * platform/graphics/GraphicsTypes.cpp:
        (WebCore::operator<<):
        * platform/graphics/GraphicsTypes.h:
        * platform/graphics/ca/PlatformCAAnimation.cpp: Added.
        (WebCore::operator<<):
        * platform/graphics/ca/PlatformCAAnimation.h:
        * platform/graphics/ca/PlatformCALayer.cpp:
        (WebCore::operator<<):
        * platform/graphics/ca/PlatformCALayer.h:
        * platform/graphics/filters/FilterOperation.cpp:
        (WebCore::operator<<):
        * platform/graphics/filters/FilterOperation.h:
        * platform/graphics/filters/FilterOperations.cpp:
        (WebCore::operator<<):
        * platform/graphics/filters/FilterOperations.h:
        * platform/graphics/filters/PointLightSource.cpp:
        (WebCore::operator<<): Deleted.
        * platform/graphics/filters/SpotLightSource.cpp:
        (WebCore::operator<<): Deleted.
        * platform/graphics/transforms/AffineTransform.cpp:
        (WebCore::operator<<):
        * platform/graphics/transforms/AffineTransform.h:
        * platform/graphics/transforms/TransformationMatrix.cpp:
        (WebCore::operator<<):
        * platform/graphics/transforms/TransformationMatrix.h:
        * platform/text/TextStream.cpp:
        (WebCore::TextStream::startGroup):
        (WebCore::TextStream::endGroup):
        (WebCore::TextStream::nextLine):
        (WebCore::TextStream::writeIndent):
        * platform/text/TextStream.h:
        (WebCore::TextStream::operator<<):
        (WebCore::TextStream::dumpProperty):
        (WebCore::TextStream::increaseIndent):
        (WebCore::TextStream::decreaseIndent):
        (WebCore::TextStream::GroupScope::GroupScope):
        (WebCore::TextStream::GroupScope::~GroupScope):
        * rendering/svg/SVGRenderTreeAsText.cpp:
        (WebCore::operator<<): Deleted.
        * rendering/svg/SVGRenderTreeAsText.h:

2015-10-17  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Finalize bug 149952 patch
        https://bugs.webkit.org/show_bug.cgi?id=150238

        Reviewed by Darin Adler.

        No change in behavior.

        * bindings/js/JSDOMConstructor.h:
        (WebCore::JSDOMConstructor<JSClass>::finishCreation): Marked as inline.
        (WebCore::JSDOMConstructor<JSClass>::getConstructData): Marked as inline.

2015-10-16  Zalan Bujtas  <zalan@apple.com>

        RenderBlockFlow::*logical*ForFloat should take FloatingObject reference.
        https://bugs.webkit.org/show_bug.cgi?id=150266

        Reviewed by Simon Fraser.

        No change in behaviour.

        * rendering/FloatingObjects.cpp:
        (WebCore::FindNextFloatLogicalBottomAdapter::collectIfNeeded):
        (WebCore::ComputeFloatOffsetForFloatLayoutAdapter<FloatingObject::FloatLeft>::updateOffsetIfNeeded):
        (WebCore::ComputeFloatOffsetForFloatLayoutAdapter<FloatingObject::FloatRight>::updateOffsetIfNeeded):
        (WebCore::ComputeFloatOffsetForFloatLayoutAdapter<FloatTypeValue>::heightRemaining):
        (WebCore::ComputeFloatOffsetAdapter<FloatTypeValue>::collectIfNeeded):
        (WebCore::ComputeFloatOffsetForLineLayoutAdapter<FloatingObject::FloatLeft>::updateOffsetIfNeeded):
        (WebCore::ComputeFloatOffsetForLineLayoutAdapter<FloatingObject::FloatRight>::updateOffsetIfNeeded):
        * rendering/RenderBlockFlow.cpp:
        (WebCore::RenderBlockFlow::rebuildFloatingObjectSetFromIntrudingFloats):
        (WebCore::RenderBlockFlow::repaintOverhangingFloats):
        (WebCore::RenderBlockFlow::insertFloatingObject):
        (WebCore::RenderBlockFlow::removeFloatingObject):
        (WebCore::RenderBlockFlow::removeFloatingObjectsBelow):
        (WebCore::RenderBlockFlow::computeLogicalLocationForFloat):
        (WebCore::RenderBlockFlow::positionNewFloats):
        (WebCore::RenderBlockFlow::lowestFloatLogicalBottom):
        (WebCore::RenderBlockFlow::lowestInitialLetterLogicalBottom):
        (WebCore::RenderBlockFlow::addOverhangingFloats):
        (WebCore::RenderBlockFlow::hasOverhangingFloat):
        (WebCore::RenderBlockFlow::addIntrudingFloats):
        * rendering/RenderBlockFlow.h:
        (WebCore::RenderBlockFlow::logicalTopForFloat):
        (WebCore::RenderBlockFlow::logicalBottomForFloat):
        (WebCore::RenderBlockFlow::logicalLeftForFloat):
        (WebCore::RenderBlockFlow::logicalRightForFloat):
        (WebCore::RenderBlockFlow::logicalWidthForFloat):
        (WebCore::RenderBlockFlow::logicalHeightForFloat):
        (WebCore::RenderBlockFlow::setLogicalTopForFloat):
        (WebCore::RenderBlockFlow::setLogicalLeftForFloat):
        (WebCore::RenderBlockFlow::setLogicalHeightForFloat):
        (WebCore::RenderBlockFlow::setLogicalWidthForFloat):
        (WebCore::RenderBlockFlow::logicalSizeForFloat): Deleted.
        * rendering/RenderBlockLineLayout.cpp:
        (WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange):
        (WebCore::RenderBlockFlow::checkPaginationAndFloatsAtEndLine):
        (WebCore::RenderBlockFlow::positionNewFloatOnLine):
        * rendering/RenderBox.cpp:
        (WebCore::RenderBox::addOverflowFromChild):
        * rendering/RenderBox.h:
        (WebCore::RenderBox::addOverflowFromChild):
        * rendering/line/BreakingContext.h:
        (WebCore::BreakingContext::handleFloat):
        * rendering/line/LineWidth.cpp:
        (WebCore::newFloatShrinksLine):
        (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
        * rendering/shapes/ShapeOutsideInfo.cpp:
        (WebCore::ShapeOutsideInfo::computeDeltasForContainingBlockLine):

2015-10-16  Jiewen Tan  <jiewen_tan@apple.com>

        Avoid to insert TAB before HTML element.
        https://bugs.webkit.org/show_bug.cgi?id=149295
        <rdar://problem/22746706>

        Reviewed by Ryosuke Niwa.

        This is a merge of Blink r175047:
        https://codereview.chromium.org/306583005

        This patch avoids InsertTextCommand::insertTab before HTML element because
        we can't set Text node as document element.

        Test: editing/execCommand/insert-tab-to-html-element-crash.html

        * editing/InsertTextCommand.cpp:
        (WebCore::InsertTextCommand::insertTab):

2015-10-16  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r191204.
        https://bugs.webkit.org/show_bug.cgi?id=150263

        This change is causing existing tests to fail (Requested by
        ryanhaddad on #webkit).

        Reverted changeset:

        "Computed style should work correctly with slotted elements
        that have display:none"
        https://bugs.webkit.org/show_bug.cgi?id=150237
        http://trac.webkit.org/changeset/191204

2015-10-16  Alex Christensen  <achristensen@webkit.org>

        Disabled content blockers should not block any loads
        https://bugs.webkit.org/show_bug.cgi?id=150261

        Reviewed by Brady Eidson.

        This fix was tested manually by reloading without content blockers
        on websites with iframes and content blockers that block the contents of the iframes.

        * page/UserContentController.cpp:
        (WebCore::UserContentController::removeAllUserContentExtensions):
        (WebCore::contentExtensionsEnabled):
        (WebCore::UserContentController::processContentExtensionRulesForLoad):
        (WebCore::UserContentController::actionsForResourceLoad):
        Check the DocumentLoader of the main frame when checking if content extensions are disabled,
        because that is the DocumentLoader that has the flag from reloading without content blockers.

2015-10-16  Simon Fraser  <simon.fraser@apple.com>

        Make TextStream the canonical way to log classes in WebCore
        https://bugs.webkit.org/show_bug.cgi?id=150256

        Reviewed by Sam Weinig.

        We vacillated between PrintStream and TextStream as being the canonical way
        to stringify WebCore data structures. This patch solidifies TextStream
        as the solution, since it has convenient stream syntax, and is what we
        use for render tree dumps.

        Remove TextStream member functions that output non-simple structs
        (sizes, points and rects), replacing them with free operator<< functions
        in the .cpp file for the relevant class. Formatting is currently consistent
        with RenderTreeAsText output, to avoid breaking tests.

        Remove custom FloatRect outputting in SVG and RemoteLayerTreeTransaction.

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:
        * platform/graphics/FloatPoint.cpp:
        (WebCore::operator<<):
        (WebCore::FloatPoint::dump): Deleted.
        * platform/graphics/FloatPoint.h:
        * platform/graphics/FloatRect.cpp:
        (WebCore::operator<<):
        (WebCore::FloatRect::dump): Deleted.
        * platform/graphics/FloatRect.h:
        * platform/graphics/FloatSize.cpp:
        (WebCore::FloatSize::FloatSize):
        (WebCore::operator<<):
        (WebCore::FloatSize::dump): Deleted.
        * platform/graphics/FloatSize.h:
        * platform/graphics/IntPoint.cpp:
        (WebCore::operator<<):
        (WebCore::IntPoint::dump): Deleted.
        * platform/graphics/IntPoint.h:
        * platform/graphics/IntRect.cpp:
        (WebCore::operator<<):
        (WebCore::IntRect::dump): Deleted.
        * platform/graphics/IntRect.h:
        * platform/graphics/IntSize.cpp:
        (WebCore::operator<<):
        (WebCore::IntSize::dump): Deleted.
        * platform/graphics/IntSize.h:
        * platform/graphics/LayoutPoint.cpp: Copied from Source/WebCore/platform/graphics/IntPoint.cpp.
        (WebCore::operator<<):
        * platform/graphics/LayoutPoint.h:
        * platform/graphics/LayoutRect.cpp:
        (WebCore::operator<<):
        * platform/graphics/LayoutRect.h:
        * platform/graphics/LayoutSize.cpp: Copied from Source/WebCore/platform/graphics/IntPoint.cpp.
        (WebCore::operator<<):
        * platform/graphics/LayoutSize.h:
        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
        (WebCore::MediaSampleAVFObjC::dump):
        * platform/text/TextStream.cpp:
        (WebCore::TextStream::operator<<):
        * platform/text/TextStream.h:
        * rendering/svg/SVGRenderTreeAsText.cpp:
        (WebCore::operator<<): Deleted.

2015-10-16  Brent Fulgham  <bfulgham@apple.com>

        Hide all plugin names except Flash, Java, and QuickTime
        https://bugs.webkit.org/show_bug.cgi?id=149014

        Reviewed by Darin Adler.

        Revise plugin interface so that sites cannot iterate over all plugins to obtain
        a list of installed plugins for fingerprinting purposes. Sites need to ask for
        specific plugins by name, rather than iterating and comparing to avoid making
        this information accessible for fingerprinting purposes.

        * plugins/DOMPluginArray.cpp:
        (WebCore::DOMPluginArray::length): Only return length of the plugins we are
        allowing to be seen.
        (WebCore::DOMPluginArray::item): Only iterate through the plugins we are
        allowing to be seen.
        * plugins/PluginData.cpp:
        (WebCore::PluginData::publiclyVisiblePlugins): Added.
        * plugins/PluginData.h:

2015-10-16  Brady Eidson  <beidson@apple.com>

        "enum class" some IDB enums.
        https://bugs.webkit.org/show_bug.cgi?id=150246

        Reviewed by Alex Christensen.

        No new tests (No change in behavior).

        * Modules/indexeddb/IDBKeyPath.cpp:
        (WebCore::IDBIsValidKeyPath):
        (WebCore::IDBParseKeyPath):
        (WebCore::IDBKeyPath::IDBKeyPath):
        (WebCore::IDBKeyPath::isValid):
        (WebCore::IDBKeyPath::operator==):
        (WebCore::IDBKeyPath::encode):
        (WebCore::IDBKeyPath::decode):
        * Modules/indexeddb/IDBKeyPath.h:
        (WebCore::IDBKeyPath::IDBKeyPath):
        (WebCore::IDBKeyPath::type):
        (WebCore::IDBKeyPath::array):
        (WebCore::IDBKeyPath::string):
        (WebCore::IDBKeyPath::isNull):
        (WebCore::IDBKeyPath::encode):
        (WebCore::IDBKeyPath::decode):
        * Modules/indexeddb/IndexedDB.h:
        * Modules/indexeddb/legacy/LegacyDatabase.cpp:
        (WebCore::LegacyDatabase::createObjectStore):
        * Modules/indexeddb/legacy/LegacyObjectStore.cpp:
        (WebCore::LegacyObjectStore::createIndex):
        * bindings/js/IDBBindingUtilities.cpp:
        (WebCore::internalCreateIDBKeyFromScriptValueAndKeyPath):
        (WebCore::injectIDBKeyIntoScriptValue):
        (WebCore::createIDBKeyFromScriptValueAndKeyPath):
        (WebCore::canInjectIDBKeyIntoScriptValue):
        * bindings/js/JSIDBAnyCustom.cpp:
        (WebCore::toJS):
        * inspector/InspectorIndexedDBAgent.cpp:

2015-10-16  Anders Carlsson  <andersca@apple.com>

        Add indexeddb/shared to the include paths.

        * WebCore.vcxproj/WebCoreIncludeCommon.props:

2015-10-16  Antti Koivisto  <antti@apple.com>

        Computed style should work correctly with slotted elements that have display:none
        https://bugs.webkit.org/show_bug.cgi?id=150237

        Reviewed by Andreas Kling.

        If an element has display:none we don't normally retain or even compute its style (as it is not rendered).
        If getComputedStyle is invoked for such element we resolve the style (along with any ancestors) and cache
        it separately to rare data. This path needs to work with slotted elements in shadow trees.

        This patch also make computedStyle() iterative rather than recursive.

        Test: fast/shadow-dom/computed-style-display-none.html

        * dom/Document.cpp:
        (WebCore::Document::styleForElementIgnoringPendingStylesheets):

            Pass in the parent style instead of invoking computedStyle() recursively.

        * dom/Document.h:
        * dom/Element.cpp:
        (WebCore::beforeOrAfterPseudoElement):
        (WebCore::Element::existingComputedStyle):
        (WebCore::Element::resolveComputedStyle):

            Iterative resolve function that uses composed tree iterator.

        (WebCore::Element::computedStyle):

            Factor into helpers.

        * dom/Element.h:
        * dom/Node.cpp:
        (WebCore::Node::computedStyle):

            Use the composed tree iterator.

2015-10-16  David Hyatt  <hyatt@apple.com>

        ASSERT in imported/blink/fast/block/float/overhanging-float-crashes-when-sibling-becomes-formatting-context.html
        https://bugs.webkit.org/show_bug.cgi?id=150249

        Reviewed by Myles Maxfield.

        Covered by existing tests.

        * css/CSSValue.cpp:
        (WebCore::CSSValue::equals):
        Make sure the "unset" value has an equals implementation.

2015-10-16  Brady Eidson  <beidson@apple.com>

        Modern IDB: Handle versionchange events.
        https://bugs.webkit.org/show_bug.cgi?id=150149

        Reviewed by Alex Christensen.

        Test: storage/indexeddb/modern/versionchange-event.html
        
        - IDBVersionChangeEvents are now dispatched to open connections when a
          version upgrade request comes in.
        - Once all of those open connections have closed, the version upgrade 
          request is handled.

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::fireVersionChangeEvent):
        (WebCore::IDBClient::IDBConnectionToServer::registerDatabaseConnection):
        (WebCore::IDBClient::IDBConnectionToServer::unregisterDatabaseConnection):
        * Modules/indexeddb/client/IDBConnectionToServer.h:

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::fireVersionChangeEvent):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::UniqueIDBDatabase):
        (WebCore::IDBServer::UniqueIDBDatabase::connectionClosedFromClient):
        (WebCore::IDBServer::UniqueIDBDatabase::invokeTransactionScheduler):
        (WebCore::IDBServer::UniqueIDBDatabase::transactionSchedulingTimerFired):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:

2015-10-16  Zalan Bujtas  <zalan@apple.com>

        First line box in paragraph using initial-letter overflows.
        https://bugs.webkit.org/show_bug.cgi?id=147977
        <rdar://problem/22901553>

        Reviewed by David Hyatt.

        When initial-letter float is present, we should shrink the first
        line even if it's not intersected with the block's current height.
        This is because of the sunken behaviour of initial-letter. 

        Test: fast/css-generated-content/initial-letter-first-line-wrapping.html

        * rendering/RenderBlockFlow.h:
        * rendering/RenderBlockLineLayout.cpp:
        (WebCore::RenderBlockFlow::positionNewFloatOnLine):
        * rendering/line/BreakingContext.h:
        (WebCore::BreakingContext::handleFloat):
        * rendering/line/LineBreaker.cpp:
        (WebCore::LineBreaker::skipLeadingWhitespace):
        * rendering/line/LineBreaker.h:
        (WebCore::LineBreaker::positionNewFloatOnLine):
        * rendering/line/LineWidth.cpp:
        (WebCore::newFloatShrinksLine):
        (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
        * rendering/line/LineWidth.h:

2015-10-16  Keith Rollin  <krollin@apple.com>

        The value sanitization algorithm for input[type=url] should strip whitespaces
        https://bugs.webkit.org/show_bug.cgi?id=148864
        rdar://problem/22589358

        Reviewed by Chris Dumez.

        Follow the sanitization algorithm specified in:
        https://html.spec.whatwg.org/multipage/forms.html#url-state-(type=url)

        Chrome also has the same issue with url.html. Firefox passes.  All
        three browsers have multiple issues with type-change-state.html, with
        each browser having a different set of failures. Addressing this in
        WebKit is another issue outside the scope of bz=148864. For now, I'm
        updating that test to capture current WebKit behavior.

        No new tests (covered by existing tests):
        - web-platform-tests/html/semantics/forms/the-input-element/type-change-state.html
        - web-platform-tests/html/semantics/forms/the-input-element/url.html

        * html/TextFieldInputType.h:
        * html/URLInputType.cpp:
        (WebCore::URLInputType::sanitizeValue):
        * html/URLInputType.h:

2015-10-16  Antti Koivisto  <antti@apple.com>

        Remove NodeRenderingTraversal
        https://bugs.webkit.org/show_bug.cgi?id=150226

        Reviewed by Chris Dumez.

        It has been reduced to an implementation detail of FocusController. Move the remaining
        functions there as they have no general utility (and are wrong for focus navigation too).

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:
        * dom/DOMAllInOne.cpp:
        * dom/NodeRenderingTraversal.cpp: Removed.
        * dom/NodeRenderingTraversal.h: Removed.
        * page/FocusController.cpp:
        (WebCore::firstChildInScope):
        (WebCore::lastChildInScope):
        (WebCore::parentInScope):
        (WebCore::nextInScope):
        (WebCore::previousInScope):
        (WebCore::FocusNavigationScope::FocusNavigationScope):
        (WebCore::FocusNavigationScope::focusNavigationScopeOf):
        (WebCore::FocusController::findElementWithExactTabIndex):
        (WebCore::nextElementWithGreaterTabIndex):
        (WebCore::previousElementWithLowerTabIndex):
        (WebCore::FocusController::nextFocusableElement):
        (WebCore::FocusController::previousFocusableElement):

2015-10-16  David Hyatt  <hyatt@apple.com>

        Build fix. "all" keyword introduction exposed a typo bug in the grid-area property definition.

        * css/CSSPropertyNames.in:

2015-10-16  Tim Horton  <timothy_horton@apple.com>

        Hook up autolayout intrinsic sizing for WKWebView
        https://bugs.webkit.org/show_bug.cgi?id=150219
        <rdar://problem/20016905>

        Reviewed by Simon Fraser.

        New API test: WebKit2.AutoLayoutIntegration.

        * page/FrameView.cpp:
        (WebCore::FrameView::autoSizeIfEnabled):
        When autosizing a document in which the body expands to the size of 
        the view (a feature of quirks mode), the first (width-determining)
        autosizing will resize the view to the document height (which is at 
        least the body height), and the second time around, the height will
        not decrease (because it was expanded to the size of the view).

        Instead, the first time around, we should use the computed width,
        but shrink the height back down to the minimum, and then expand
        only as much as needed to fit the content.

2015-10-16  Brady Eidson  <beidson@apple.com>

        Modern IDB: Support IDBDatabase.close().
        https://bugs.webkit.org/show_bug.cgi?id=150150

        Reviewed by Alex Christensen.

        No new tests (Covered by changes to storage/indexeddb/modern/opendatabase-versions.html).

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::databaseConnectionClosed):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::IDBDatabase):
        (WebCore::IDBClient::IDBDatabase::~IDBDatabase):
        (WebCore::IDBClient::IDBDatabase::close):
        (WebCore::IDBClient::IDBDatabase::maybeCloseInServer):
        (WebCore::IDBClient::IDBDatabase::commitTransaction):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:
        (WebCore::IDBClient::IDBDatabase::databaseConnectionIdentifier):

        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::result):

        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::databaseConnectionClosed):
        * Modules/indexeddb/server/IDBServer.h:

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::connectionClosedFromClient):
        (WebCore::IDBServer::UniqueIDBDatabase::handleOpenDatabaseOperations): Deleted.
        * Modules/indexeddb/server/UniqueIDBDatabase.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::UniqueIDBDatabaseConnection):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::~UniqueIDBDatabaseConnection):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::hasNonFinishedTransactions):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::connectionClosedFromClient):
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:

        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::databaseConnectionClosed):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

2015-10-16  Chris Dumez  <cdumez@apple.com>

        HTMLPreloadScanner should preload iframes
        https://bugs.webkit.org/show_bug.cgi?id=150097
        <rdar://problem/23094475>

        Reviewed by Antti Koivisto.

        HTMLPreloadScanner should preload iframes to decrease page load time.

        Tests:
        - fast/preloader/frame-src.html
        - http/tests/loading/preload-no-store-frame-src.html

        * html/parser/HTMLPreloadScanner.cpp:
        (WebCore::TokenPreloadScanner::tagIdFor):
        (WebCore::TokenPreloadScanner::initiatorFor):
        (WebCore::TokenPreloadScanner::StartTagScanner::createPreloadRequest):
        (WebCore::TokenPreloadScanner::StartTagScanner::processAttribute):
        (WebCore::TokenPreloadScanner::StartTagScanner::resourceType):
        (WebCore::TokenPreloadScanner::StartTagScanner::setUrlToLoad): Deleted.
        (WebCore::TokenPreloadScanner::StartTagScanner::charset): Deleted.
        * html/parser/HTMLPreloadScanner.h:

2015-10-16  David Hyatt  <hyatt@apple.com>

        Implement the "all" CSS property.
        https://bugs.webkit.org/show_bug.cgi?id=116966

        Reviewed by Zalan Bujtas.

        Added new tests in fast/css.

        * css/CSSComputedStyleDeclaration.cpp:
        (WebCore::ComputedStyleExtractor::propertyValue):
        Don't support "all" from computed style for now.

        * css/CSSParser.cpp:
        (WebCore::CSSParser::parseValue):
        Make sure to bail after checking inherit/unset/initial for all, since you can't actually
        accept longhand values in the shorthand declarations.

        (WebCore::CSSParser::parseAnimationProperty):
        "all" for animations is a special value and should not be confused with the property. It
        animates everything and does not omit unicode-bidi/direction the way the "all" property does.

        * css/CSSPropertyNames.in:
        Add the "all" property to the list and use a special keyword in the Longhands value, "all",
        that makeprop.pl will look for. This way we don't have to dump every single CSS property
        into the Longhands expression, since that would be nuts.

        * css/StyleProperties.cpp:
        (WebCore::StyleProperties::getPropertyValue):
        Look for a common value across all properties supported by "all". That way you can get
        back inherit/initial/unset from it.

        * css/makeprop.pl:
        Make the perl script look for "all" in the longhand list, and if it sees it, put every
        single CSS property into the list for the all shorthand.

2015-10-16  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Binding generator should use templated JSXXConstructor
        https://bugs.webkit.org/show_bug.cgi?id=149952

        Reviewed by Darin Adler.

        Adding constructor templates:
        - JSDOMConstructor: usual JS constructors
        - JSDOMNamedConstructor: for named constructors
        - JSDOMConstructorNotConstructable: for objects that cannot be constructed directly from JS.

        Binding generator is using these 3 templates and is generating specializations for construct, initializeProperties and s_info.
        These templates may also be used for private or custom constructors as examplified by JSImageConstructor
        and JSReadableStream reader and controller private constructors.

        Updated binding generator to use those templates.
        Updated JSImageConstructor.cpp to use JSDOMNamedConstructor.
        Updated default template implementation of JSBuiltinConstructor::createObject.
        Updated generated helper routines of binding generator to fit with the templates.

        A further patch should remove DOMConstructorWithDocument and DOMConstructorJSBuiltinObject. 

        Covered by binding tests.

        * bindings/js/JSDOMConstructor.h:
        (WebCore::JSDOMConstructorNotConstructable::create):
        (WebCore::JSDOMConstructorNotConstructable::createStructure):
        (WebCore::JSDOMConstructorNotConstructable::JSDOMConstructorNotConstructable):
        (WebCore::JSDOMConstructorNotConstructable::initializeProperties):
        (WebCore::JSDOMConstructorNotConstructable<JSClass>::finishCreation):
        (WebCore::JSDOMConstructor::create):
        (WebCore::JSDOMConstructor::createStructure):
        (WebCore::JSDOMConstructor::JSDOMConstructor):
        (WebCore::JSDOMConstructor::initializeProperties):
        (WebCore::JSDOMConstructor<JSClass>::finishCreation):
        (WebCore::JSDOMConstructor<JSClass>::getConstructData):
        (WebCore::JSDOMNamedConstructor::create):
        (WebCore::JSDOMNamedConstructor::createStructure):
        (WebCore::JSDOMNamedConstructor::JSDOMNamedConstructor):
        (WebCore::JSDOMNamedConstructor::initializeProperties):
        (WebCore::JSDOMNamedConstructor<JSClass>::finishCreation):
        (WebCore::JSDOMNamedConstructor<JSClass>::getConstructData):
        * bindings/js/JSDOMWindowCustom.cpp:
        (WebCore::JSDOMWindow::image):
        * bindings/js/JSImageConstructor.cpp:
        (WebCore::JSImageConstructor::initializeProperties):
        (WebCore::JSImageConstructor::construct):
        (WebCore::createImageConstructor):
        * bindings/js/JSImageConstructor.h:
        * bindings/scripts/CodeGeneratorJS.pm:
        (GetConstructorTemplateClassName):
        (GenerateConstructorDeclaration):
        (GenerateOverloadedConstructorDefinition):
        (GenerateConstructorDefinition):
        (GenerateConstructorHelperMethods):
        (GenerateImplementation): Deleted.
        (GenerateConstructorDefinitions): Deleted.
        (HasCustomSetter): Deleted.
        (HasCustomMethod): Deleted.
        (NeedsConstructorProperty): Deleted.
        (ComputeFunctionSpecial): Deleted.
        (AddJSBuiltinIncludesIfNeeded): Deleted.
        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
        (WebCore::JSTestActiveDOMObjectConstructor::initializeProperties):
        (WebCore::JSTestActiveDOMObjectPrototype::finishCreation): Deleted.
        (WebCore::JSTestActiveDOMObject::JSTestActiveDOMObject): Deleted.
        * bindings/scripts/test/JS/JSTestCallback.cpp:
        (WebCore::JSTestCallbackConstructor::initializeProperties):
        (WebCore::JSTestCallback::callbackWithNoParam): Deleted.
        * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::construct):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::initializeProperties):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectPrototype::finishCreation): Deleted.
        (WebCore::JSTestCustomConstructorWithNoInterfaceObject::JSTestCustomConstructorWithNoInterfaceObject): Deleted.
        (WebCore::JSTestCustomConstructorWithNoInterfaceObject::createPrototype): Deleted.
        (WebCore::JSTestCustomConstructorWithNoInterfaceObject::getPrototype): Deleted.
        (WebCore::JSTestCustomConstructorWithNoInterfaceObject::destroy): Deleted.
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
        (WebCore::JSTestCustomNamedGetterConstructor::initializeProperties):
        (WebCore::JSTestCustomNamedGetterPrototype::finishCreation): Deleted.
        (WebCore::JSTestCustomNamedGetter::JSTestCustomNamedGetter): Deleted.
        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
        (WebCore::JSTestEventConstructorConstructor::construct):
        (WebCore::JSTestEventConstructorConstructor::initializeProperties):
        (WebCore::JSTestEventConstructorPrototype::finishCreation): Deleted.
        (WebCore::JSTestEventConstructor::JSTestEventConstructor): Deleted.
        (WebCore::JSTestEventConstructor::getPrototype): Deleted.
        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
        (WebCore::JSTestEventTargetConstructor::initializeProperties):
        (WebCore::JSTestEventTargetPrototype::finishCreation): Deleted.
        * bindings/scripts/test/JS/JSTestException.cpp:
        (WebCore::JSTestExceptionConstructor::initializeProperties):
        (WebCore::JSTestExceptionPrototype::finishCreation): Deleted.
        (WebCore::JSTestException::JSTestException): Deleted.
        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
        (WebCore::JSTestGenerateIsReachableConstructor::initializeProperties):
        (WebCore::JSTestGenerateIsReachablePrototype::finishCreation): Deleted.
        (WebCore::JSTestGenerateIsReachable::JSTestGenerateIsReachable): Deleted.
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        (WebCore::JSTestInterfaceConstructor::construct):
        (WebCore::JSTestInterfaceConstructor::initializeProperties):
        (WebCore::JSTestInterfaceConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
        (WebCore::JSTestJSBuiltinConstructorConstructor::createJSObject):
        (WebCore::JSTestJSBuiltinConstructorConstructor::initializeProperties):
        (WebCore::JSTestJSBuiltinConstructorPrototype::finishCreation): Deleted.
        (WebCore::JSTestJSBuiltinConstructor::JSTestJSBuiltinConstructor): Deleted.
        (WebCore::JSTestJSBuiltinConstructor::createPrototype): Deleted.
        (WebCore::JSTestJSBuiltinConstructor::getPrototype): Deleted.
        (WebCore::JSTestJSBuiltinConstructor::destroy): Deleted.
        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
        (WebCore::JSTestMediaQueryListListenerConstructor::initializeProperties):
        (WebCore::JSTestMediaQueryListListenerPrototype::finishCreation): Deleted.
        (WebCore::JSTestMediaQueryListListener::JSTestMediaQueryListListener): Deleted.
        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
        (WebCore::JSTestNamedConstructorConstructor::initializeProperties):
        (WebCore::JSTestNamedConstructorNamedConstructor::construct):
        (WebCore::JSTestNamedConstructorNamedConstructor::initializeProperties):
        (WebCore::JSTestNamedConstructorPrototype::finishCreation): Deleted.
        (WebCore::JSTestNamedConstructor::JSTestNamedConstructor): Deleted.
        (WebCore::jsTestNamedConstructorConstructor): Deleted.
        (WebCore::JSTestNamedConstructor::getConstructor): Deleted.
        (WebCore::JSTestNamedConstructorOwner::isReachableFromOpaqueRoots): Deleted.
        * bindings/scripts/test/JS/JSTestNode.cpp:
        (WebCore::JSTestNodeConstructor::construct):
        (WebCore::JSTestNodeConstructor::initializeProperties):
        (WebCore::JSTestNodePrototype::finishCreation): Deleted.
        (WebCore::JSTestNode::JSTestNode): Deleted.
        (WebCore::JSTestNode::getPrototype): Deleted.
        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
        (WebCore::JSTestNondeterministicConstructor::initializeProperties):
        (WebCore::JSTestNondeterministicPrototype::finishCreation): Deleted.
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::JSTestObjConstructor::construct):
        (WebCore::JSTestObjConstructor::initializeProperties):
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
        (WebCore::JSTestOverloadedConstructorsConstructor::construct):
        (WebCore::JSTestOverloadedConstructorsConstructor::initializeProperties):
        (WebCore::constructJSTestOverloadedConstructors1): Deleted.
        (WebCore::constructJSTestOverloadedConstructors2): Deleted.
        (WebCore::JSTestOverloadedConstructorsPrototype::finishCreation): Deleted.
        (WebCore::JSTestOverloadedConstructors::JSTestOverloadedConstructors): Deleted.
        (WebCore::JSTestOverloadedConstructors::createPrototype): Deleted.
        (WebCore::JSTestOverloadedConstructors::getPrototype): Deleted.
        (WebCore::JSTestOverloadedConstructors::destroy): Deleted.
        * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
        (WebCore::JSTestOverrideBuiltinsConstructor::initializeProperties):
        (WebCore::JSTestOverrideBuiltinsPrototype::finishCreation): Deleted.
        (WebCore::JSTestOverrideBuiltins::JSTestOverrideBuiltins): Deleted.
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::initializeProperties):
        (WebCore::JSTestSerializedScriptValueInterfacePrototype::finishCreation): Deleted.
        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
        (WebCore::JSTestTypedefsConstructor::construct):
        (WebCore::JSTestTypedefsConstructor::initializeProperties):
        (WebCore::JSTestTypedefsPrototype::finishCreation): Deleted.
        * bindings/scripts/test/JS/JSattribute.cpp:
        (WebCore::JSattributeConstructor::initializeProperties):
        (WebCore::JSattributePrototype::finishCreation): Deleted.
        (WebCore::JSattribute::JSattribute): Deleted.
        * bindings/scripts/test/JS/JSreadonly.cpp:
        (WebCore::JSreadonlyConstructor::initializeProperties):
        (WebCore::JSreadonlyPrototype::finishCreation): Deleted.
        (WebCore::JSreadonly::JSreadonly): Deleted.

2015-10-16  Carlos Garcia Campos  <cgarcia@igalia.com>

        [GStreamer] ASSERTION FAILED: !m_adoptionIsRequired in MediaSourceGStreamer::addSourceBuffer
        https://bugs.webkit.org/show_bug.cgi?id=150229

        Reviewed by Philippe Normand.

        This happens in the debug bot in all media source tests that run
        that code. The problem is that we are creating a RefPtr without
        adopting the reference.

        * platform/graphics/gstreamer/MediaSourceGStreamer.cpp:
        (WebCore::MediaSourceGStreamer::addSourceBuffer): Use
        SourceBufferPrivateGStreamer::create().
        * platform/graphics/gstreamer/SourceBufferPrivateGStreamer.cpp:
        (WebCore::SourceBufferPrivateGStreamer::create): Added to make
        sure you can't create a SourceBufferPrivateGStreamer without
        adopting the reference.
        (WebCore::SourceBufferPrivateGStreamer::SourceBufferPrivateGStreamer):
        Takes a reference to the client instead of a PassRefPtr.
        * platform/graphics/gstreamer/SourceBufferPrivateGStreamer.h:

2015-10-15  Roopesh Chander  <roop@roopc.net>

        [Content Extensions] Content blocking rules are not consulted for pings
        https://bugs.webkit.org/show_bug.cgi?id=149873

        Reviewed by Alex Christensen.

        This patch makes requests sent through the PingLoader
        respect content blocking rules. Specifically, the following
        are now subject to content blocking rules:
 
         1. <a ping> pings
         2. Images loaded in unload / beforeunload / pagehide handlers
         3. X-XSS-Protection / CSP violation reports

        Tests: http/tests/contentextensions/block-cookies-in-csp-report.html
               http/tests/contentextensions/block-cookies-in-image-load-in-onunload.html
               http/tests/contentextensions/block-cookies-in-ping.html
               http/tests/contentextensions/block-csp-report.html
               http/tests/contentextensions/block-image-load-in-onunload.html
               http/tests/contentextensions/block-ping.html
               http/tests/contentextensions/hide-on-csp-report.html

        * loader/PingLoader.cpp:
        (WebCore::processContentExtensionRulesForLoad):
        (WebCore::PingLoader::loadImage):
        (WebCore::PingLoader::sendPing):
        (WebCore::PingLoader::sendViolationReport):

2015-10-14  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Include Garbage Collection Event in Timeline
        https://bugs.webkit.org/show_bug.cgi?id=142510

        Reviewed by Geoffrey Garen and Brian Burg.

        Tests: inspector/heap/garbageCollected.html
               inspector/heap/gc.html

        * ForwardingHeaders/heap/HeapObserver.h: Added.
        * ForwardingHeaders/inspector/agents/InspectorHeapAgent.h: Added.
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        Forwarding headers.

        * inspector/InspectorController.cpp:
        (WebCore::InspectorController::InspectorController):
        (WebCore::InspectorController::vm):
        * inspector/InspectorController.h:
        * inspector/WorkerInspectorController.cpp:
        (WebCore::WorkerInspectorController::vm):
        * inspector/WorkerInspectorController.h:
        Implement InspectorEnvironment::vm and create a Heap agent for the
        Page inspector controller.

2015-10-15  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r191156.
        https://bugs.webkit.org/show_bug.cgi?id=150215

        Introduced crashing test (Requested by bradee-oh on #webkit).

        Reverted changeset:

        "Modern IDB: Support IDBDatabase.close()."
        https://bugs.webkit.org/show_bug.cgi?id=150150
        http://trac.webkit.org/changeset/191156

2015-10-15  Brady Eidson  <beidson@apple.com>

        Modern IDB: Support IDBDatabase.close().
        https://bugs.webkit.org/show_bug.cgi?id=150150

        Reviewed by Alex Christensen.

        No new tests (Covered by changes to storage/indexeddb/modern/opendatabase-versions.html).

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::databaseConnectionClosed):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::IDBDatabase):
        (WebCore::IDBClient::IDBDatabase::~IDBDatabase):
        (WebCore::IDBClient::IDBDatabase::close):
        (WebCore::IDBClient::IDBDatabase::maybeCloseInServer):
        (WebCore::IDBClient::IDBDatabase::commitTransaction):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:
        (WebCore::IDBClient::IDBDatabase::databaseConnectionIdentifier):

        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::result):

        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::databaseConnectionClosed):
        * Modules/indexeddb/server/IDBServer.h:

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::connectionClosedFromClient):
        (WebCore::IDBServer::UniqueIDBDatabase::handleOpenDatabaseOperations): Deleted.
        * Modules/indexeddb/server/UniqueIDBDatabase.h:

        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::UniqueIDBDatabaseConnection):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::~UniqueIDBDatabaseConnection):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::hasNonFinishedTransactions):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::connectionClosedFromClient):
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:

        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::databaseConnectionClosed):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

2015-10-15  David Hyatt  <hyatt@apple.com>

        Patch parseKeywordValue to accept "unset" so that it goes down the faster parsing path.
        https://bugs.webkit.org/show_bug.cgi?id=150213

        Reviewed by Dean Jackson.

        No new tests as correctness doesn't change (just speed).

        * css/CSSParser.cpp:
        (WebCore::parseKeywordValue):

2015-10-15  David Hyatt  <hyatt@apple.com>

        Add support for the CSS 'unset' keyword.
        https://bugs.webkit.org/show_bug.cgi?id=148614

        Reviewed by Dean Jackson.

        Added new test in fast/css, and existing variables tests also use unset in several tests.

        * WebCore.xcodeproj/project.pbxproj:
        Add CSSUnsetValue.cpp to the project.

        * bindings/objc/DOMCSS.mm:
        (kitClass):
        Make sure UNSET is handled in the switch.

        * css/CSSParser.cpp:
        (WebCore::parseKeywordValue):
        (WebCore::CSSParser::parseValue):
        (WebCore::CSSParser::parseCustomPropertyDeclaration):
        Add cases to create a CSSUnsetValue properly.

        * css/CSSToStyleMap.cpp:
        (WebCore::CSSToStyleMap::styleImage):
        (WebCore::CSSToStyleMap::mapFillAttachment):
        (WebCore::CSSToStyleMap::mapFillClip):
        (WebCore::CSSToStyleMap::mapFillComposite):
        (WebCore::CSSToStyleMap::mapFillBlendMode):
        (WebCore::CSSToStyleMap::mapFillOrigin):
        (WebCore::CSSToStyleMap::mapFillImage):
        (WebCore::CSSToStyleMap::mapFillRepeatX):
        (WebCore::CSSToStyleMap::mapFillRepeatY):
        (WebCore::convertToLengthSize):
        (WebCore::CSSToStyleMap::mapFillSize):
        (WebCore::CSSToStyleMap::mapFillXPosition):
        (WebCore::CSSToStyleMap::mapFillYPosition):
        (WebCore::CSSToStyleMap::mapFillMaskSourceType):
        (WebCore::CSSToStyleMap::mapAnimationDelay):
        (WebCore::CSSToStyleMap::mapAnimationDirection):
        (WebCore::CSSToStyleMap::mapAnimationDuration):
        (WebCore::CSSToStyleMap::mapAnimationFillMode):
        (WebCore::CSSToStyleMap::mapAnimationIterationCount):
        (WebCore::CSSToStyleMap::mapAnimationName):
        (WebCore::CSSToStyleMap::mapAnimationPlayState):
        (WebCore::CSSToStyleMap::mapAnimationProperty):
        (WebCore::CSSToStyleMap::mapAnimationTimingFunction):
        (WebCore::CSSToStyleMap::mapAnimationTrigger):
        The background and animation functions need to check for unset and be able to map it properly to initial. This is done
        with a new treatAsInitial method on CSSValue that can take the property ID and check for both initial
        or unset on a non-inherited property.

        * css/CSSUnsetValue.cpp: Added.
        (WebCore::CSSUnsetValue::customCSSText):
        * css/CSSUnsetValue.h: Added.
        (WebCore::CSSUnsetValue::create):
        (WebCore::CSSUnsetValue::equals):
        (WebCore::CSSUnsetValue::CSSUnsetValue):
        This new value looks exactly like CSSInheritedValue and CSSInitialValue.

        * css/CSSValue.cpp:
        (WebCore::CSSValue::cssValueType):
        (WebCore::CSSValue::cssText):
        (WebCore::CSSValue::destroy):
        (WebCore::CSSValue::isInvalidCustomPropertyValue):
        (WebCore::CSSValue::treatAsInheritedValue):
        (WebCore::CSSValue::treatAsInitialValue):
        * css/CSSValue.h:
        (WebCore::CSSValue::isUnsetValue):
        Add isUnsetValue and the UnsetClass. Add support for treatAsInheritedValue and treatAsInitialValue to have
        a way to query for initial/inherit or the matching unset type.

        * css/CSSValueKeywords.in:
        Add the unset keyword.

        * css/CSSValuePool.cpp:
        (WebCore::CSSValuePool::CSSValuePool):
        * css/CSSValuePool.h:
        (WebCore::CSSValuePool::createUnsetValue):
        Have a singleton model for unset just like we do for inherit/initial.

        * css/StyleResolver.cpp:
        (WebCore::StyleResolver::applyProperty):
        Handle unset correctly. It maps to inherit for inherited properties and initial for non-inherited ones.

2015-10-15  Myles C. Maxfield  <mmaxfield@apple.com>

        Migrate to CGContextSetBaseCTM() and CGContextResetClip() from WKSI
        https://bugs.webkit.org/show_bug.cgi?id=150155

        Reviewed by Tim Horton.

        No new tests because there is no behavior change.

        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::GraphicsContext::drawPattern):
        (WebCore::GraphicsContext::platformApplyDeviceScaleFactor):
        * platform/graphics/cg/ImageBufferCG.cpp:
        (WebCore::ImageBuffer::putByteArray):
        * platform/ios/WebCoreSystemInterfaceIOS.mm:
        * platform/mac/WebCoreSystemInterface.h:
        * platform/mac/WebCoreSystemInterface.mm:

2015-10-15  Dan Bernstein  <mitz@apple.com>

        Fixed the build.

        * platform/network/mac/ResourceHandleMac.mm:

2015-10-15  Dan Bernstein  <mitz@apple.com>

        [Cocoa] Stop using WKSetNSURLConnectionDefersCallbacks
        https://bugs.webkit.org/show_bug.cgi?id=150189

        Reviewed by Anders Carlsson.

        * platform/ios/WebCoreSystemInterfaceIOS.mm: Removed definition.
        * platform/mac/WebCoreSystemInterface.h: Removed declaration.
        * platform/mac/WebCoreSystemInterface.mm: Removed definition.

        * platform/network/mac/ResourceHandleMac.mm:
        (WebCore::ResourceHandle::start): Changed to use -[NSURLConnection setDefersLoading:].
        (WebCore::ResourceHandle::platformSetDefersLoading): Ditto.

        * platform/spi/cocoa/NSURLConnectionSPI.h: Added declaration of
          -[NSURLConnection setDefersLoading:].

2015-10-15  Dean Jackson  <dino@apple.com>

        CSSKeyframesRule::appendRule is deprecated, but is actually the spec
        https://bugs.webkit.org/show_bug.cgi?id=150113

        Reviewed by Simon Fraser.

        I stupidly deprecated the wrong function in
        http://trac.webkit.org/changeset/174469

        * css/CSSKeyframesRule.cpp:
        (WebCore::CSSKeyframesRule::insertRule): Swap the code between these two.
        (WebCore::CSSKeyframesRule::appendRule):

2015-10-14  David Hyatt  <hyatt@apple.com>

        Implement CSS Variables.
        https://bugs.webkit.org/show_bug.cgi?id=19660

        Reviewed by Dean Jackson.

        Added new tests in fast/css/custom-properties and fast/css/variables.

        * CMakeLists.txt:
        * WebCore.xcodeproj/project.pbxproj:
        Add CSSVariableValue.cpp and CSSVariableDependentValue.cpp to builds.

        * css/CSSCalculationValue.cpp:
        (WebCore::hasDoubleValue):
        Handle the new CSS_PARSER_WHITESPACE value.

        * css/CSSComputedStyleDeclaration.cpp:
        (WebCore::ComputedStyleExtractor::customPropertyValue):
        Patched to make sure style is updated so that dynamic changes to custom properties are reflected
        immediately when querying values.

        (WebCore::CSSComputedStyleDeclaration::length):
        (WebCore::CSSComputedStyleDeclaration::item):
        The custom properties table is a reference and not a pointer now.

        * css/CSSCustomPropertyValue.h:
        (WebCore::CSSCustomPropertyValue::create):
        (WebCore::CSSCustomPropertyValue::createInvalid):
        (WebCore::CSSCustomPropertyValue::customCSSText):
        (WebCore::CSSCustomPropertyValue::equals):
        (WebCore::CSSCustomPropertyValue::isInvalid):
        (WebCore::CSSCustomPropertyValue::containsVariables):
        (WebCore::CSSCustomPropertyValue::value):
        (WebCore::CSSCustomPropertyValue::CSSCustomPropertyValue):
        The CSSCustomPropertyValue represents a custom property/value pair in the back end. It holds on
        to both the property name and a CSSValueList that has the original parser terms. This class also
        doubles as the invalid-at-compute-time value for custom properties when they contain cycles, etc.

        * css/CSSFunctionValue.cpp:
        (WebCore::CSSFunctionValue::buildParserValueSubstitutingVariables):
         * css/CSSFunctionValue.h:
        (WebCore::CSSFunctionValue::buildParserValueSubstitutingVariables):
        Hands back a CSSParserValue for a function with variables replaced with their real values (or fallback).

        * css/CSSGrammar.y.in:
        Many changes to support the var() syntax and to handle error conditions and cases.

        * css/CSSParser.cpp:
        (WebCore::filterProperties):
        Null check the value here. Shouldn't happen, but being paranoid.

        (WebCore::CSSParser::parseVariableDependentValue):
        This function converts a CSSValueList back into a CSSParserValueList and then passes
        it off to the parser. If the result parses, successfully, then the parsed CSSValue is handed back.

        (WebCore::CSSParser::parseValue):
        Detect when a property value contains variables and simply make a CSSVariableDependentValue to hold
        a copy of the parser value list (as a CSSValueList). We defer parsing the list until compute-time
        when we know the values of the variables to use.

        (WebCore::CSSParser::parseCustomPropertyDeclaration):
        Add support for inherit, initial and variable references in custom properties.

        (WebCore::CSSParser::detectFunctionTypeToken):
        Add support for detection of the "var" token.

        (WebCore::CSSParser::realLex):
        Fix the parsing of custom properties to allow "--" and to allow them to start with digits, e.g., "--0".

        * css/CSSParser.h:
        Add parseVariableDependentValue function for handling variable substitution and subsequent parsing
        of the resolved parser value list.

        * css/CSSParserValues.cpp:
        (WebCore::CSSParserValueList::containsVariables):
        Get rid of the toString() function (no longer needed) and replace it with containsVariables(). This
        check is used to figure out if a parser value list has variables and thus needs to defer parsing
        until later.

        (WebCore::CSSParserValue::createCSSValue):
        Add support for the creation of values for variables, CSSVariableValues.

        (WebCore::CSSParserValueList::toString): Deleted.
        No longer needed.

        * css/CSSParserValues.h:
        Add CSSParserVariable as a new kind of parser value. This represents a var() that is encountered
        during parsing. It is similar to a function except it has to hold both the reference (custom property name)
        and fallback arguments.

        * css/CSSPrimitiveValue.cpp:
        (WebCore::isValidCSSUnitTypeForDoubleConversion):
        (WebCore::CSSPrimitiveValue::cleanup):
        (WebCore::CSSPrimitiveValue::formatNumberForCustomCSSText):
        (WebCore::CSSPrimitiveValue::cloneForCSSOM):
        (WebCore::CSSPrimitiveValue::equals):
        Add support for CSS_PARSER_WHITESPACE as a way of preserving whitespace as a parsed item (variables can
        be only whitespace, and this has to be retained).

        (WebCore::CSSPrimitiveValue::buildParserValue):
        Conversion from a CSSPrimitiveValue back into a parser value is handled by this function.

        * css/CSSPrimitiveValue.h:
        (WebCore::CSSPrimitiveValue::isParserOperator):
        (WebCore::CSSPrimitiveValue::parserOperator):
        Add ability to get parser operator info. Add the buildParserValue declaration.

        * css/CSSValue.cpp:
        (WebCore::CSSValue::equals):
        (WebCore::CSSValue::cssText):
        (WebCore::CSSValue::destroy):
        (WebCore::CSSValue::cloneForCSSOM):
        (WebCore::CSSValue::isInvalidCustomPropertyValue):
        * css/CSSValue.h:
        Add support for variable values and variable dependent values.

        * css/CSSValueList.cpp:
        (WebCore::CSSValueList::customCSSText):
        Improve serialization to not output extra spaces when a comma operator is a value.

        (WebCore::CSSValueList::containsVariables):
        Whether or not a CSSVariableValue can be found somewhere within the list (or its descendants).

        (WebCore::CSSValueList::checkVariablesForCycles):
        Called to check variables for cycles.

        (WebCore::CSSValueList::buildParserValueSubstitutingVariables):
        (WebCore::CSSValueList::buildParserValueListSubstitutingVariables):
        Functions that handle converting the value list to a parser value list while making
        variable substitutions along the way.

        * css/CSSValueList.h:
        Add the new buildParserXXX functions.

        * css/CSSVariableDependentValue.cpp: Added.
        (WebCore::CSSVariableDependentValue::checkVariablesForCycles):
        * css/CSSVariableDependentValue.h: Added.
        (WebCore::CSSVariableDependentValue::create):
        (WebCore::CSSVariableDependentValue::customCSSText):
        (WebCore::CSSVariableDependentValue::equals):
        (WebCore::CSSVariableDependentValue::propertyID):
        (WebCore::CSSVariableDependentValue::valueList):
        (WebCore::CSSVariableDependentValue::CSSVariableDependentValue):
        This value represents a list of terms that have not had variables substituted yet. The list
        is held by the value so that it can be converted back into a parser value list once the
        variable values are known.

        * css/CSSVariableValue.cpp: Added.
        (WebCore::CSSVariableValue::CSSVariableValue):
        (WebCore::CSSVariableValue::customCSSText):
        (WebCore::CSSVariableValue::equals):
        (WebCore::CSSVariableValue::buildParserValueListSubstitutingVariables):
        * css/CSSVariableValue.h: Added.
        (WebCore::CSSVariableValue::create):
        (WebCore::CSSVariableValue::name):
        (WebCore::CSSVariableValue::fallbackArguments):
        This value represents a var() itself. It knows how to do the substitution of the variable
        value and to apply fallback if that value is not present.

        * css/StyleProperties.cpp:
        (WebCore::StyleProperties::getPropertyValue):
        (WebCore::StyleProperties::borderSpacingValue):
        (WebCore::StyleProperties::getLayeredShorthandValue):
        (WebCore::StyleProperties::getShorthandValue):
        (WebCore::StyleProperties::getCommonValue):
        (WebCore::StyleProperties::getPropertyCSSValue):
        (WebCore::StyleProperties::getPropertyCSSValueInternal):
        (WebCore::StyleProperties::asText):
        (WebCore::StyleProperties::copyPropertiesInSet):
        * css/StyleProperties.h:
        Patched to factor property fetching into an internal method so that variables can work with shorthands
        in the CSS OM.

        * css/StyleResolver.cpp:
        (WebCore::StyleResolver::applyProperty):
        Resolve variable values at compute time. If they fail to resolve, use inherit or initial as the
        value (depending on whether the property inherits by default).

        (WebCore::StyleResolver::resolvedVariableValue):
        Helper function that calls parseVariableDependentValue and gets the resolved result.

        (WebCore::StyleResolver::applyCascadedProperties):
        After custom properties have been collected, we check for cycles and perform variable substitutions.
        This way we get all the variables replaced before we inherit down the style tree.

        * css/StyleResolver.h:
        Add resolvedVariableValue declaration.

        * css/makeprop.pl:
        Make sure custom properties are inherited by default.

        * rendering/style/RenderStyle.cpp:
        (WebCore::RenderStyle::checkVariablesInCustomProperties):
        This function handles updating variables with cycles to be invalid in the RenderStyle. It then also
        handles the replacement of variables found in custom properties with resolved values. All custom
        properties are either invalid or are real non-variable-dependent value lists after this function
        completes.

        * rendering/style/RenderStyle.h:
        Add checkVariablesInCustomProperties declaration.

        * rendering/style/StyleCustomPropertyData.h:
        (WebCore::StyleCustomPropertyData::create):
        (WebCore::StyleCustomPropertyData::copy):
        (WebCore::StyleCustomPropertyData::operator==):
        (WebCore::StyleCustomPropertyData::operator!=):
        (WebCore::StyleCustomPropertyData::setCustomPropertyValue):
        (WebCore::StyleCustomPropertyData::getCustomPropertyValue):
        (WebCore::StyleCustomPropertyData::values):
        (WebCore::StyleCustomPropertyData::hasCustomProperty):
        (WebCore::StyleCustomPropertyData::containsVariables):
        (WebCore::StyleCustomPropertyData::setContainsVariables):
        (WebCore::StyleCustomPropertyData::StyleCustomPropertyData):
        Miscellaneous cleanup, and the addition of whether or not the properties still contain variable
        dependent values that need to be resolved.

2015-10-15  Csaba Osztrogonác  <ossy@webkit.org>

        Fix the !(ENABLE(SHADOW_DOM) || ENABLE(DETAILS_ELEMENT)) build after r191112
        https://bugs.webkit.org/show_bug.cgi?id=150175

        Reviewed by Antti Koivisto.

        * dom/ComposedTreeAncestorIterator.h:
        (WebCore::ComposedTreeAncestorIterator::traverseParent):
        * dom/ComposedTreeIterator.cpp:
        (WebCore::ComposedTreeIterator::initializeShadowStack):
        * dom/Element.cpp:
        (WebCore::Element::childrenChanged):

2015-10-15  Csaba Osztrogonác  <ossy@webkit.org>

        Get rid of the only once used isIntegerArray function
        https://bugs.webkit.org/show_bug.cgi?id=150170

        Reviewed by Geoffrey Garen.

        * page/Crypto.cpp:
        (WebCore::Crypto::getRandomValues):

2015-10-15  Tim Horton  <timothy_horton@apple.com>

        Try to fix the iOS build.

        * page/EventHandler.h:

2015-10-15  Zalan Bujtas  <zalan@apple.com>

        Anonymous table objects: Collapse anonymous table rows.
        https://bugs.webkit.org/show_bug.cgi?id=150154

        Reviewed by David Hyatt.

        Merge anonymous table rows when they are not needed anymore.
        Generated table rows can be collapsed into one when there's no
        non-generated sibling table row left in the tree.

        Import W3C CSS2.1 anonymous table tests.

        * rendering/RenderObject.cpp:
        (WebCore::collapseAnonymousTableRowsIfNeeded):
        (WebCore::RenderObject::destroyAndCleanupAnonymousWrappers):

2015-10-15  Simon Fraser  <simon.fraser@apple.com>

        Un-indent contents of the WebCore namespace
        in GraphicsContext.h. No code changes.

        * platform/graphics/GraphicsContext.h:

2015-10-14  Simon Fraser  <simon.fraser@apple.com>

        Move ImageBuffer:clip() into GraphicsContextCG
        https://bugs.webkit.org/show_bug.cgi?id=150140

        Reviewed by Zalan Bujtas.

        Move the guts of CG's ImageBuffer:clip() into GraphicsContextCG.

        * platform/graphics/GraphicsContext.h:
        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::GraphicsContext::clipToNativeImage):
        * platform/graphics/cg/ImageBufferCG.cpp:
        (WebCore::ImageBuffer::clip):

2015-10-14  Brady Eidson  <beidson@apple.com>

        Modern IDB: Add basic transaction committing.
        https://bugs.webkit.org/show_bug.cgi?id=150147

        Reviewed by Alex Christensen.

        Test: storage/indexeddb/modern/opendatabase-versions.html

        * Modules/indexeddb/IDBTransaction.h:

        * Modules/indexeddb/IndexedDB.h:

        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::commitTransaction):
        (WebCore::IDBClient::IDBConnectionToServer::didCommitTransaction):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBConnectionToServerDelegate.h:

        * Modules/indexeddb/client/IDBDatabaseImpl.cpp:
        (WebCore::IDBClient::IDBDatabase::startVersionChangeTransaction):
        (WebCore::IDBClient::IDBDatabase::commitTransaction):
        (WebCore::IDBClient::IDBDatabase::didCommitTransaction):
        (WebCore::IDBClient::IDBDatabase::didAbortTransaction):
        (WebCore::IDBClient::IDBDatabase::didCommitOrAbortTransaction):
        * Modules/indexeddb/client/IDBDatabaseImpl.h:

        * Modules/indexeddb/client/IDBFactoryImpl.cpp:
        (WebCore::IDBClient::IDBFactory::open):

        * Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBOpenDBRequest::onSuccess):
        * Modules/indexeddb/client/IDBOpenDBRequestImpl.h:

        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::IDBTransaction):
        (WebCore::IDBClient::IDBTransaction::db):
        (WebCore::IDBClient::IDBTransaction::hasPendingActivity):
        (WebCore::IDBClient::IDBTransaction::isActive):
        (WebCore::IDBClient::IDBTransaction::scheduleOperationTimer):
        (WebCore::IDBClient::IDBTransaction::operationTimerFired):
        (WebCore::IDBClient::IDBTransaction::commit):
        (WebCore::IDBClient::IDBTransaction::didCommit):
        (WebCore::IDBClient::IDBTransaction::fireOnComplete):
        (WebCore::IDBClient::IDBTransaction::fireOnAbort):
        (WebCore::IDBClient::IDBTransaction::enqueueEvent):
        (WebCore::IDBClient::IDBTransaction::dispatchEvent):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        (WebCore::IDBClient::IDBTransaction::database):
        
        * Modules/indexeddb/legacy/LegacyTransaction.cpp:
        (WebCore::LegacyTransaction::db):
        * Modules/indexeddb/legacy/LegacyTransaction.h:
        
        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::didCommitTransaction):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:
        
        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::registerTransaction):
        (WebCore::IDBServer::IDBServer::unregisterTransaction):
        (WebCore::IDBServer::IDBServer::commitTransaction):
        * Modules/indexeddb/server/IDBServer.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::generateUniqueCallbackIdentifier):
        (WebCore::IDBServer::UniqueIDBDatabase::storeCallback):
        (WebCore::IDBServer::UniqueIDBDatabase::commitTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::performCommitTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::didPerformCommitTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::performErrorCallback):
        (WebCore::IDBServer::UniqueIDBDatabase::startVersionChangeTransaction): Deleted.
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        (WebCore::IDBServer::UniqueIDBDatabase::server):
        
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::createVersionChangeTransaction):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::didCommitTransaction):
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::UniqueIDBDatabaseTransaction):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::~UniqueIDBDatabaseTransaction):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::commit):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
        
        * Modules/indexeddb/shared/IDBDatabaseInfo.h:
        (WebCore::IDBDatabaseInfo::setVersion):
        
        * Modules/indexeddb/shared/IDBError.cpp:
        (WebCore::IDBError::isolatedCopy):
        * Modules/indexeddb/shared/IDBError.h:

        * Modules/indexeddb/shared/IDBRequestData.h:

        * Modules/indexeddb/shared/IDBResourceIdentifier.cpp:
        (WebCore::IDBResourceIdentifier::isolatedCopy):
        * Modules/indexeddb/shared/IDBResourceIdentifier.h:

        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::didCommitTransaction):
        (WebCore::InProcessIDBServer::commitTransaction):
        * Modules/indexeddb/shared/InProcessIDBServer.h:

        * WebCore.xcodeproj/project.pbxproj:

        * platform/CrossThreadCopier.cpp:
        (WebCore::IDBResourceIdentifier>::copy):
        (WebCore::IDBError>::copy):
        * platform/CrossThreadCopier.h:

2015-10-15  Daniel Bates  <dabates@apple.com>

        [iOS] DOM click event may not be dispatched when page has :active style and <input type="search">
        https://bugs.webkit.org/show_bug.cgi?id=144451
        <rdar://problem/23099482>

        Reviewed by Simon Fraser.

        Fixes an issue where a DOM click event is not dispatched to an element in a subframe on a page
        that has a <input type="search"> and defines a CSS :active pseudo-class for the HTML body element.

        On iOS we only dispatch a DOM click event if the content does not change as part
        of dispatching a DOM mousemove event at the tapped element. In particular, we do not
        dispatch a DOM click event if there is a visibility change to some element on the page
        as part of dispatching a mousemove event at the tapped element. For a web page
        that specifies CSS :active pseudo-class and contains a search field, applying/unapplying
        this pseudo-class as part of dispatching a DOM mousemove event may cause the
        visibility of the search field cancel button to change; => a DOM click event will not
        be dispatched to the tapped element.

        Tests: fast/events/can-click-element-on-page-with-active-pseudo-class-and-search-field.html
               fast/forms/search/search-cancel-button-visible-when-input-becomes-disabled.html
               fast/forms/search/search-cancel-button-visible-when-input-becomes-readonly.html
               fast/forms/search/search-cancel-in-formerly-invisible-element.html
               fast/forms/search/search-cancel-toggle-visibility-initially-hidden.html
               fast/forms/search/search-cancel-toggle-visibility-initially-visible.html

        * rendering/RenderSearchField.cpp:
        (WebCore::RenderSearchField::updateCancelButtonVisibility): Write logic for determining
        whether the visibility of the cancel button changed in terms of m_isCancelButtonVisible
        instead of querying for the current style data as the latter is overwritten on a full
        style recalculation.
        (WebCore::RenderSearchField::RenderSearchField): Deleted.
        (WebCore::RenderSearchField::visibilityForCancelButton): Deleted.
        * rendering/RenderSearchField.h: Define instance variable m_isCancelButtonVisible to
        store the visibility state of the cancel button.

2015-10-15  Antti Koivisto  <antti@apple.com>

        Implement iterator for traversing composed ancestors
        https://bugs.webkit.org/show_bug.cgi?id=150162

        Reviewed by Andreas Kling.

        The existing general purpose ComposedTreeIterator can traverse parent chain but not efficiently
        (since it builds stack). Add a separate stackless iterator for ancestor chain traversal.

        * WebCore.xcodeproj/project.pbxproj:
        * dom/ComposedTreeAncestorIterator.h: Added.
        (WebCore::ComposedTreeAncestorIterator::operator*):
        (WebCore::ComposedTreeAncestorIterator::operator->):
        (WebCore::ComposedTreeAncestorIterator::operator==):
        (WebCore::ComposedTreeAncestorIterator::operator!=):
        (WebCore::ComposedTreeAncestorIterator::operator++):
        (WebCore::ComposedTreeAncestorIterator::get):
        (WebCore::ComposedTreeAncestorIterator::ComposedTreeAncestorIterator):
        (WebCore::ComposedTreeAncestorIterator::traverseParent):
        (WebCore::ComposedTreeAncestorAdapter::ComposedTreeAncestorAdapter):
        (WebCore::ComposedTreeAncestorAdapter::begin):
        (WebCore::ComposedTreeAncestorAdapter::end):
        (WebCore::ComposedTreeAncestorAdapter::first):
        (WebCore::composedTreeAncestors):
        * dom/ComposedTreeIterator.h:
        * dom/ContainerNode.h:
        (WebCore::Node::highestAncestor):
        (WebCore::Node::isTreeScope):
        (WebCore::Node::needsNodeRenderingTraversalSlowPath): Deleted.

            With NodeRenderingTraversal::parent removed this bit is no longer used.

        * dom/Element.cpp:
        (WebCore::Element::shadowRoot):
        (WebCore::Element::addShadowRoot):
        (WebCore::shouldUseNodeRenderingTraversalSlowPath): Deleted.
        (WebCore::Element::resetNeedsNodeRenderingTraversalSlowPath): Deleted.
        * dom/Element.h:
        (WebCore::Element::didAddUserAgentShadowRoot):
        (WebCore::Element::alwaysCreateUserAgentShadowRoot):
        * dom/Node.cpp:
        (WebCore::Node::derefEventTarget):
        (WebCore::Node::updateAncestorsForStyleRecalc):
        (WebCore::traverseStyleParent): Deleted.
        (WebCore::traverseFirstStyleParent): Deleted.

            Switch to iterator interface.

        * dom/Node.h:
        (WebCore::Node::isDocumentFragment):
        (WebCore::Node::isShadowRoot):
        (WebCore::Node::isNamedFlowContentNode):
        (WebCore::Node::hasCustomStyleResolveCallbacks):
        (WebCore::Node::setHasCustomStyleResolveCallbacks):
        (WebCore::Node::setTreeScope):
        (WebCore::Node::setStyleChange):
        (WebCore::Node::setNeedsNodeRenderingTraversalSlowPath): Deleted.
        * dom/NodeRenderingTraversal.cpp:
        (WebCore::NodeRenderingTraversal::traverseParent):
        (WebCore::NodeRenderingTraversal::traverseFirstChild):
        (WebCore::NodeRenderingTraversal::traverseLastChild):
        (WebCore::NodeRenderingTraversal::traversePreviousSibling):
        (WebCore::NodeRenderingTraversal::nextInScope):
        (WebCore::NodeRenderingTraversal::previousInScope):
        (WebCore::NodeRenderingTraversal::parentInScope):
        (WebCore::NodeRenderingTraversal::lastChildInScope):
        (WebCore::NodeRenderingTraversal::parentSlow): Deleted.
        * dom/NodeRenderingTraversal.h:
        (WebCore::NodeRenderingTraversal::parent): Deleted.

            No longer used.

        * html/HTMLSummaryElement.cpp:
        * rendering/RenderNamedFlowThread.cpp:
        (WebCore::RenderNamedFlowThread::isChildAllowed):

            Switch to iterator interface.

        * style/RenderTreePosition.cpp:
        * style/StyleResolveTree.cpp:
        (WebCore::Style::updateTextRendererAfterContentChange):

            Switch to iterator interface.

2015-10-14  Zhuo Li  <zachli@apple.com>

        Augment <input type=search>’s recent search history with the time each entry was added,
        in order to allow time-based clearing of search history.
        https://bugs.webkit.org/show_bug.cgi?id=148388.

        Reviewed by Darin Adler.

        Replace Vector<String> with Vector<RecentSearch>, where RecentSearch is a struct
        that consists search string and time, for recent searches in order to store additional time
        information.

        * WebCore.xcodeproj/project.pbxproj: Added SearchPopupMenuCocoa.h and SearchPopupMenuCocoa.mm
        and sort the project file.
        * loader/EmptyClients.cpp:
        (WebCore::EmptySearchPopupMenu::saveRecentSearches):
        (WebCore::EmptySearchPopupMenu::loadRecentSearches):
        * platform/SearchPopupMenu.h:
        * platform/cocoa/SearchPopupMenuCocoa.h: Added methods for SeachPopupMenuMac in WebKit
        and WebPageProxyCocoa in WebKit2 to call.
        * platform/cocoa/SearchPopupMenuCocoa.mm: Added.
        (WebCore::searchFieldRecentSearchesStorageDirectory): Recent searches with the new structure
        are stored in a new location.
        (WebCore::searchFieldRecentSearchesPlistPath): Get the path for the plist of the recent
        searches entries.
        (WebCore::RetainPtr<NSMutableDictionary> readSearchFieldRecentSearchesPlist): Return the
        recent searches plist as NSMutableDictionary.
        (WebCore::fromNSDatetoSystemClockTime): Convert from NSDate to system_clock::time_point.
        (WebCore::fromSystemClockTimetoNSDate): Convert from system_clock::time_point to NSDate.
        (WebCore::SearchPopupMenuCocoa::saveRecentSearches): Add a dictionary where it has two pairs
        that the first one is the search string and the second one is the time.
        (WebCore::SearchPopupMenuCocoa::loadRecentSearches): We expect the recent search item in the
        plist to be a two-pair dictionary, and convert the dictionary to the struct RecentSearch.
        * platform/win/SearchPopupMenuWin.cpp:
        (WebCore::SearchPopupMenuWin::saveRecentSearches): Only save the RecentSearch's search
        string on Windows platform, which is what we used to do.
        (WebCore::SearchPopupMenuWin::loadRecentSearches): Since we need to construct a
        RecentSearch, we get the string from the app's preferences, and set the time to be
        std::chrono::system_clock::time_point::min().
        * platform/win/SearchPopupMenuWin.h:
        * rendering/RenderSearchField.cpp: Now that m_recentSearches are Vector<RecentSearch>,
        we cannot use -removeAll with a search string. Use -removeAllMatching instead to remove the
        item that has its member search string equal to the search string user inputs.
        (WebCore::RenderSearchField::addSearchResult):
        (WebCore::RenderSearchField::itemText):

2015-10-14  Simon Fraser  <simon.fraser@apple.com>

        Use RefPtr<Image> return type for StyleImage::image()
        https://bugs.webkit.org/show_bug.cgi?id=150112

        Reviewed by Andreas Kling.
        
        Change StyleImage::image() and subclasses to return RefPtr<Image>
        instead of a PassRefPtr<Image>.

        * WebCore.xcodeproj/project.pbxproj:
        * rendering/RenderImageResource.cpp:
        (WebCore::RenderImageResource::image):
        * rendering/RenderImageResource.h:
        * rendering/RenderImageResourceStyleImage.cpp:
        (WebCore::RenderImageResourceStyleImage::image):
        * rendering/RenderImageResourceStyleImage.h:
        * rendering/style/StyleCachedImage.cpp:
        (WebCore::StyleCachedImage::image):
        * rendering/style/StyleCachedImage.h:
        * rendering/style/StyleCachedImageSet.cpp:
        (WebCore::StyleCachedImageSet::image):
        * rendering/style/StyleCachedImageSet.h:
        * rendering/style/StyleGeneratedImage.cpp:
        (WebCore::StyleGeneratedImage::image):
        * rendering/style/StyleGeneratedImage.h:
        * rendering/style/StyleImage.h:
        * rendering/style/StylePendingImage.h:

2015-10-14  Simon Fraser  <simon.fraser@apple.com>

        Give subclasses of CSSImageGeneratorValue a consistent image() return type
        https://bugs.webkit.org/show_bug.cgi?id=150111

        Reviewed by Andreas Kling.
        
        CSSImageGeneratorValue and subclasses had signatures of the non-virtual image() function
        with mistmatched return types; some returned RefPtr<Image>, and others PassRefPtr<Image>. Make
        them all the same.

        * css/CSSImageGeneratorValue.cpp:
        (WebCore::CSSImageGeneratorValue::image):
        * css/CSSImageGeneratorValue.h:
        * css/CSSNamedImageValue.cpp:
        (WebCore::CSSNamedImageValue::image):
        * css/CSSNamedImageValue.h:

2015-10-14  Tim Horton  <timothy_horton@apple.com>

        Move some EventHandler initialization to the header
        https://bugs.webkit.org/show_bug.cgi?id=150139

        Reviewed by Andreas Kling.

        No new tests, just cleanup.

        * page/EventHandler.cpp:
        (WebCore::EventHandler::EventHandler): Deleted.
        * page/EventHandler.h:
        Also found one member which was unused, and a few that were uninitialized.
        It's likely the uninitialized ones didn't actually cause any trouble because
        they are reset in lots of places, but this seems better.

2015-10-14  Alex Christensen  <achristensen@webkit.org>

        [Content Extensions] Make blocked async XHR call onerror
        https://bugs.webkit.org/show_bug.cgi?id=146706

        Reviewed by Brady Eidson.

        Test: http/tests/contentextensions/async-xhr-onerror.html

        * xml/XMLHttpRequest.cpp:
        (WebCore::XMLHttpRequest::XMLHttpRequest):
        (WebCore::XMLHttpRequest::createRequest):
        (WebCore::XMLHttpRequest::networkError):
        (WebCore::XMLHttpRequest::networkErrorTimerFired):
        (WebCore::XMLHttpRequest::abortError):
        * xml/XMLHttpRequest.h:
        Make a timer that calls networkError in 0 time if a content blocker blocks the asynchronous load.
        It is necessary to call setPendingActivity and dropProtection (which calls unsetPendingActivity)
        to keep a reference to the XMLHttpRequest alive.

2015-10-14  Andy Estes  <aestes@apple.com>

        [iOS] QuickLook documents loaded over https do not load their subresources
        https://bugs.webkit.org/show_bug.cgi?id=150145
        <rdar://problem/22884521>

        Reviewed by Alexey Proskuryakov.

        When QuickLook generates an HTML preview of a document, subresources are referenced using the x-apple-ql-id scheme,
        for which QuickLook installs an NSURLProtocol. If a document is loaded over https, then this scheme needs to be
        considered secure in order to avoid mixed content errors.

        Test: http/tests/quicklook/secure-document-with-subresources.html

        * platform/SchemeRegistry.cpp:
        (WebCore::secureSchemes): Registered QLPreviewProtocol() as a secure scheme.

2015-10-14  Jiewen Tan  <jiewen_tan@apple.com>

        Postpone mutation events before invoke Editor::Command command(Document*, const String&, bool).
        https://bugs.webkit.org/show_bug.cgi?id=149299
        <rdar://problem/22746995>

        Reviewed by Andreas Kling.

        Test: editing/inserting/insert-with-mutation-event.html

        This is a merge of a part of Blink r166294:
        https://codereview.chromium.org/141103006

        * dom/Document.cpp:
        (WebCore::Document::execCommand):

2015-10-14  Dean Jackson  <dino@apple.com>

        Implement CanvasRenderingContext2D::commit
        https://bugs.webkit.org/show_bug.cgi?id=150110
        <rdar://problem/23057398>

        Reviewed by Anders Carlsson.

        As part of getting as close as possible to the HTML5 specification,
        implement the commit() method on 2d canvas, even though it doesn't
        do anything.

        Test: fast/canvas/commit.html

        * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
        (WebCore::JSCanvasRenderingContext2D::commit): Intercept it here to
        avoid adding a method to the actual implementation.
        * html/canvas/CanvasRenderingContext2D.idl: Add commit.

2015-10-14  Alex Christensen  <achristensen@webkit.org>

        Add SPI for reloading without content blockers
        https://bugs.webkit.org/show_bug.cgi?id=150058
        rdar://problem/22742222

        Reviewed by Sam Weinig.

        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::reloadWithOverrideEncoding):
        (WebCore::FrameLoader::reload):
        * loader/FrameLoader.h:
        * page/Page.h:
        (WebCore::Page::userContentController):
        (WebCore::Page::userContentExtensionsEnabled): Deleted.
        (WebCore::Page::setUserContentExtensionsEnabled): Deleted.
        * replay/UserInputBridge.cpp:
        (WebCore::UserInputBridge::loadRequest):
        (WebCore::UserInputBridge::reloadFrame):
        (WebCore::UserInputBridge::stopLoadingFrame):
        * replay/UserInputBridge.h:
        Pass a bool from the reloadWithoutContentBlockers call to the DocumentLoader, 
        which stores the state of whether the content blockers are enabled or not.
        Remove the state from the Page and copying the state from the Page to the DocumentLoader
        because that caused issues with the content blockers being re-enabled at the wrong time.

2015-10-14  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Rename JSDOMWrapper to JSDOMObject and JSDOMWrapperWithImplementation to JSDOMWrapper
        https://bugs.webkit.org/show_bug.cgi?id=150120

        Reviewed by Sam Weinig.

        No change in behavior.

        * bindings/js/DOMWrapperWorld.h:
        * bindings/js/JSDOMBinding.h:
        (WebCore::DOMConstructorObject::DOMConstructorObject):
        (WebCore::getInlineCachedWrapper):
        (WebCore::setInlineCachedWrapper):
        (WebCore::clearInlineCachedWrapper):
        (WebCore::createWrapper):
        (WebCore::getStaticValueSlotEntryWithoutCaching<JSDOMObject>):
        * bindings/js/JSDOMWrapper.cpp:
        * bindings/js/JSDOMWrapper.h:
        (WebCore::JSDOMObject::JSDOMObject):
        (WebCore::JSDOMWrapper::~JSDOMWrapper):
        (WebCore::JSDOMWrapper::JSDOMWrapper):
        * bindings/js/JSElementCustom.cpp:
        (WebCore::toJSNewlyCreated):
        * bindings/js/JSNodeCustom.cpp:
        (WebCore::createWrapperInline):
        * bindings/js/ScriptWrappable.h:
        * bindings/js/ScriptWrappableInlines.h:
        (WebCore::ScriptWrappable::wrapper):
        (WebCore::ScriptWrappable::setWrapper):
        (WebCore::ScriptWrappable::clearWrapper):
        * bindings/scripts/CodeGeneratorJS.pm:
        (GetParentClassName):
        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
        (WebCore::JSTestActiveDOMObject::JSTestActiveDOMObject):
        * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
        * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
        (WebCore::JSTestCustomConstructorWithNoInterfaceObject::JSTestCustomConstructorWithNoInterfaceObject):
        * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h:
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
        (WebCore::JSTestCustomNamedGetter::JSTestCustomNamedGetter):
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
        (WebCore::JSTestEventConstructor::JSTestEventConstructor):
        * bindings/scripts/test/JS/JSTestEventConstructor.h:
        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
        (WebCore::JSTestEventTarget::JSTestEventTarget):
        * bindings/scripts/test/JS/JSTestEventTarget.h:
        * bindings/scripts/test/JS/JSTestException.cpp:
        (WebCore::JSTestException::JSTestException):
        * bindings/scripts/test/JS/JSTestException.h:
        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
        (WebCore::JSTestGenerateIsReachable::JSTestGenerateIsReachable):
        * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        (WebCore::JSTestInterface::JSTestInterface):
        * bindings/scripts/test/JS/JSTestInterface.h:
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
        (WebCore::JSTestJSBuiltinConstructor::JSTestJSBuiltinConstructor):
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.h:
        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
        (WebCore::JSTestMediaQueryListListener::JSTestMediaQueryListListener):
        * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
        (WebCore::JSTestNamedConstructor::JSTestNamedConstructor):
        * bindings/scripts/test/JS/JSTestNamedConstructor.h:
        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
        (WebCore::JSTestNondeterministic::JSTestNondeterministic):
        * bindings/scripts/test/JS/JSTestNondeterministic.h:
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::JSTestObj::JSTestObj):
        * bindings/scripts/test/JS/JSTestObj.h:
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
        (WebCore::JSTestOverloadedConstructors::JSTestOverloadedConstructors):
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
        * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
        (WebCore::JSTestOverrideBuiltins::JSTestOverrideBuiltins):
        * bindings/scripts/test/JS/JSTestOverrideBuiltins.h:
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
        (WebCore::JSTestSerializedScriptValueInterface::JSTestSerializedScriptValueInterface):
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
        (WebCore::JSTestTypedefs::JSTestTypedefs):
        * bindings/scripts/test/JS/JSTestTypedefs.h:
        * bindings/scripts/test/JS/JSattribute.cpp:
        (WebCore::JSattribute::JSattribute):
        * bindings/scripts/test/JS/JSattribute.h:
        * bindings/scripts/test/JS/JSreadonly.cpp:
        (WebCore::JSreadonly::JSreadonly):
        * bindings/scripts/test/JS/JSreadonly.h:
        * dom/make_names.pl:
        (printWrapperFunctions):
        (printWrapperFactoryCppFile):
        (printWrapperFactoryHeaderFile):

2015-10-14  Simon Fraser  <simon.fraser@apple.com>

        Change GraphicsContext image-drawing functions to take references
        https://bugs.webkit.org/show_bug.cgi?id=150108

        Reviewed by Tim Horton and Sam Weinig.

        Change GraphicsContext::drawImage(), drawTiledImage(), drawImageBuffer(), clipToImageBuffer()
        and isCompatibleWithBuffer() to take references, and adjust calling code, adding
        null-checks where necessary.

        * css/CSSCrossfadeValue.cpp:
        (WebCore::CSSCrossfadeValue::image):
        * css/CSSFilterImageValue.cpp:
        (WebCore::CSSFilterImageValue::image):
        * html/HTMLCanvasElement.cpp:
        (WebCore::HTMLCanvasElement::paint):
        * html/canvas/CanvasRenderingContext2D.cpp:
        (WebCore::CanvasRenderingContext2D::drawImage):
        (WebCore::CanvasRenderingContext2D::compositeBuffer):
        (WebCore::drawImageToContext):
        (WebCore::CanvasRenderingContext2D::fullCanvasCompositedDrawImage):
        (WebCore::CanvasRenderingContext2D::drawTextInternal):
        * html/canvas/CanvasRenderingContext2D.h:
        * html/canvas/WebGL2RenderingContext.cpp:
        (WebCore::WebGL2RenderingContext::texSubImage2D):
        * html/canvas/WebGLRenderingContext.cpp:
        (WebCore::WebGLRenderingContext::texSubImage2D):
        * html/canvas/WebGLRenderingContextBase.cpp:
        (WebCore::WebGLRenderingContextBase::drawImageIntoBuffer):
        (WebCore::WebGLRenderingContextBase::texImage2D):
        * html/canvas/WebGLRenderingContextBase.h:
        * platform/ScrollView.cpp:
        (WebCore::ScrollView::paintPanScrollIcon):
        * platform/graphics/CrossfadeGeneratedImage.cpp:
        (WebCore::CrossfadeGeneratedImage::CrossfadeGeneratedImage):
        (WebCore::drawCrossfadeSubimage):
        (WebCore::CrossfadeGeneratedImage::drawCrossfade):
        * platform/graphics/CrossfadeGeneratedImage.h:
        * platform/graphics/GradientImage.cpp:
        (WebCore::GradientImage::drawPattern):
        * platform/graphics/GraphicsContext.cpp:
        (WebCore::GraphicsContext::drawImage):
        (WebCore::GraphicsContext::drawTiledImage):
        (WebCore::GraphicsContext::drawImageBuffer):
        (WebCore::GraphicsContext::clipToImageBuffer):
        (WebCore::GraphicsContext::isCompatibleWithBuffer):
        * platform/graphics/GraphicsContext.h:
        * platform/graphics/ShadowBlur.cpp:
        (WebCore::ShadowBlur::drawShadowBuffer):
        (WebCore::ShadowBlur::drawRectShadowWithoutTiling):
        (WebCore::ShadowBlur::drawInsetShadowWithoutTiling):
        (WebCore::ShadowBlur::drawInsetShadowWithTiling):
        (WebCore::ShadowBlur::drawRectShadowWithTiling):
        (WebCore::ShadowBlur::drawLayerPieces):
        (WebCore::ShadowBlur::endShadowLayer):
        * platform/graphics/cairo/ImageBufferCairo.cpp:
        (WebCore::ImageBuffer::draw):
        * platform/graphics/cg/PDFDocumentImage.cpp:
        (WebCore::PDFDocumentImage::draw):
        * platform/graphics/filters/FEBlend.cpp:
        (WebCore::FEBlend::platformApplySoftware):
        * platform/graphics/filters/FEColorMatrix.cpp:
        (WebCore::FEColorMatrix::platformApplySoftware):
        * platform/graphics/filters/FEComposite.cpp:
        (WebCore::FEComposite::platformApplySoftware):
        * platform/graphics/filters/FEDropShadow.cpp:
        (WebCore::FEDropShadow::platformApplySoftware):
        * platform/graphics/filters/FEMerge.cpp:
        (WebCore::FEMerge::platformApplySoftware):
        * platform/graphics/filters/FEOffset.cpp:
        (WebCore::FEOffset::platformApplySoftware):
        * platform/graphics/filters/FETile.cpp:
        (WebCore::FETile::platformApplySoftware):
        * platform/graphics/filters/SourceAlpha.cpp:
        (WebCore::SourceAlpha::platformApplySoftware):
        * platform/graphics/filters/SourceGraphic.cpp:
        (WebCore::SourceGraphic::platformApplySoftware):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
        (WebCore::MediaPlayerPrivateGStreamerBase::paint):
        * platform/graphics/texmap/coordinated/CoordinatedImageBacking.cpp:
        (WebCore::ImageBackingSurfaceClient::ImageBackingSurfaceClient):
        (WebCore::CoordinatedImageBacking::update):
        * platform/mac/ThemeMac.mm:
        (WebCore::ThemeMac::drawCellOrFocusRingWithViewIntoContext):
        * rendering/FilterEffectRenderer.cpp:
        (WebCore::FilterEffectRendererHelper::applyFilterEffect):
        * rendering/ImageQualityController.cpp:
        (WebCore::ImageQualityController::shouldPaintAtLowQuality):
        * rendering/ImageQualityController.h:
        * rendering/RenderBoxModelObject.cpp:
        (WebCore::RenderBoxModelObject::shouldPaintAtLowQuality):
        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
        * rendering/RenderBoxModelObject.h:
        * rendering/RenderEmbeddedObject.cpp:
        (WebCore::RenderEmbeddedObject::paintSnapshotImage):
        (WebCore::RenderEmbeddedObject::paintContents):
        * rendering/RenderEmbeddedObject.h:
        * rendering/RenderImage.cpp:
        (WebCore::RenderImage::paintReplaced):
        (WebCore::RenderImage::paintIntoRect):
        * rendering/RenderImageResourceStyleImage.cpp:
        (WebCore::RenderImageResourceStyleImage::shutdown):
        (WebCore::RenderImageResourceStyleImage::image):
        * rendering/RenderLayer.cpp:
        (WebCore::RenderLayer::drawPlatformResizerImage):
        * rendering/RenderListMarker.cpp:
        (WebCore::RenderListMarker::paint):
        * rendering/RenderSnapshottedPlugIn.cpp:
        (WebCore::RenderSnapshottedPlugIn::paintSnapshot):
        * rendering/RenderThemeMac.mm:
        (WebCore::RenderThemeMac::paintProgressBar):
        (WebCore::RenderThemeMac::paintSnapshottedPluginOverlay):
        * rendering/RenderThemeWin.cpp:
        (WebCore::RenderThemeWin::paintSearchFieldCancelButton):
        (WebCore::RenderThemeWin::paintSearchFieldResultsDecorationPart):
        (WebCore::RenderThemeWin::paintSearchFieldResultsButton):
        * rendering/shapes/Shape.cpp:
        (WebCore::Shape::createRasterShape):
        * rendering/shapes/ShapeOutsideInfo.cpp:
        (WebCore::ShapeOutsideInfo::createShapeForImage): Deleted.
        * rendering/style/NinePieceImage.cpp:
        (WebCore::NinePieceImage::paint):
        * rendering/svg/RenderSVGImage.cpp:
        (WebCore::RenderSVGImage::paintForeground):
        * rendering/svg/RenderSVGResourceFilter.cpp:
        (WebCore::RenderSVGResourceFilter::postApplyResource):
        * rendering/svg/SVGRenderingContext.cpp:
        (WebCore::SVGRenderingContext::clipToImageBuffer):
        (WebCore::SVGRenderingContext::bufferForeground):
        * svg/graphics/filters/SVGFEImage.cpp:
        (WebCore::FEImage::platformApplySoftware):

2015-10-14  Said Abou-Hallawa  <sabouhallawa@apple.com>

        REGRESSION(r53318): background-repeat: space with gradients doesn't render correctly
        https://bugs.webkit.org/show_bug.cgi?id=150068

        Reviewed by Simon Fraser.

        This is a regression of r53318 in which we were trying to make the pattern
        of the gradient image as small as possible: 1-pixel wide or tall. But this
        broke the rendering of the background image when container element has the
        style background-repeat: space. The reason for this is tiling the gradient
        image is done completely by CG. To do the tiling, we start by creating a
        CGPattern by calling CGPatternCreate() which takes the rect of the pattern
        and the step. If the width or the height of the pattern image is adjusted
        to be 1-pixel wide or tall, that will force CG to leave a space after every
        it draws the pattern image which is 1-pixel wide or tall which is wrong.
        
        The fix is to disable this optimization altogether if the container element
        has the style background-repeat: space.

        Test: fast/gradients/background-image-repeat-space.html

        * platform/graphics/Gradient.cpp:
        (WebCore::Gradient::adjustParametersForTiledDrawing):
        * platform/graphics/Gradient.h:
        * platform/graphics/GradientImage.cpp:
        (WebCore::GradientImage::drawPattern):

2015-10-13  Simon Fraser  <simon.fraser@apple.com>

        Add helper funtion for checking pointer equivalency and use it
        https://bugs.webkit.org/show_bug.cgi?id=150022

        Reviewed by Darin Adler.

        A common pattern in WebCore code is to check for equivalency of two pointers,
        either both null, or both non-null and with equal values. This was written in
        several different ways in different places.
        
        Add arePointingToEqualData() to standardize this pattern.

        This obviates the need for StyleImage::imagesEquivalent(), counterDataEquivalent()
        etc.
        
        Also change some comparisons of DataRef<> which checked the pointer and then the
        values to use DataRef<>::operator== which does the same thing. Comparisons of
        m_grid and m_gridItem only checked pointer equality, so this is probably a bug fix there.

        * page/animation/CSSPropertyAnimation.cpp: if ((!a && !b) || a == b) is redundant so fix,
        and add checks for a and b RenderStyle* first.
        (WebCore::PropertyWrapperGetter::equals):
        (WebCore::StyleImagePropertyWrapper::equals):
        (WebCore::PropertyWrapperShadow::equals):
        (WebCore::PropertyWrapperMaybeInvalidColor::equals):
        (WebCore::FillLayerPropertyWrapperGetter::equals):
        (WebCore::FillLayerStyleImagePropertyWrapper::equals):
        (WebCore::FillLayersPropertyWrapper::equals):
        (WebCore::ShorthandPropertyWrapper::equals):
        (WebCore::PropertyWrapperFlex::equals):
        (WebCore::PropertyWrapperSVGPaint::equals):
        * platform/network/ResourceRequestBase.cpp:
        (WebCore::equalIgnoringHeaderFields):
        * rendering/style/FillLayer.cpp:
        (WebCore::FillLayer::operator==):
        * rendering/style/NinePieceImage.cpp:
        (WebCore::NinePieceImageData::operator==):
        * rendering/style/RenderStyle.cpp: Some nullptr cleanup.
        (WebCore::RenderStyle::getCachedPseudoStyle):
        (WebCore::RenderStyle::addCachedPseudoStyle):
        (WebCore::RenderStyle::changeAffectsVisualOverflow):
        (WebCore::RenderStyle::changeRequiresLayout):
        (WebCore::RenderStyle::changeRequiresLayerRepaint):
        (WebCore::RenderStyle::setWillChange):
        * rendering/style/SVGRenderStyleDefs.cpp:
        (WebCore::StyleShadowSVGData::operator==):
        * rendering/style/ShadowData.cpp:
        (WebCore::ShadowData::operator==):
        * rendering/style/StyleImage.h:
        (WebCore::StyleImage::imagesEquivalent): Deleted.
        * rendering/style/StyleRareInheritedData.cpp:
        (WebCore::StyleRareInheritedData::operator==):
        (WebCore::cursorDataEquivalent): Deleted.
        (WebCore::quotesDataEquivalent): Deleted.
        (WebCore::StyleRareInheritedData::shadowDataEquivalent): Deleted.
        * rendering/style/StyleRareInheritedData.h:
        * rendering/style/StyleRareNonInheritedData.cpp:
        (WebCore::StyleRareNonInheritedData::operator==):
        (WebCore::StyleRareNonInheritedData::counterDataEquivalent): Deleted.
        (WebCore::StyleRareNonInheritedData::shadowDataEquivalent): Deleted.
        (WebCore::StyleRareNonInheritedData::willChangeDataEquivalent): Deleted.
        (WebCore::StyleRareNonInheritedData::reflectionDataEquivalent): Deleted.
        (WebCore::StyleRareNonInheritedData::animationDataEquivalent): Deleted.
        (WebCore::StyleRareNonInheritedData::transitionDataEquivalent): Deleted.
        * rendering/style/StyleRareNonInheritedData.h:

2015-10-13  Myles C. Maxfield  <mmaxfield@apple.com>

        Split TypesettingFeatures into kerning and ligatures bools
        https://bugs.webkit.org/show_bug.cgi?id=150074

        Reviewed by Simon Fraser.

        Our TypesettingFeatures type represents whether kerning or ligatures are enabled
        when laying out text. However, now that I have implemented font-feature-settings
        and font-variant-*, this type is wildly inadequate. There are now multiple kinds
        of ligatures, and many other features which are neither kerning nor ligatures.
        Adding tons of information to this type doesn't make sense because 1) We already
        have a FontVariantSettings struct which contains this information, and 2) None
        of the users of TypesettingFeatures care about most of these new features.

        In this new world of font features, the font-kerning property isn't changing.
        Therefore, all the code which relies only on the Kerning value in
        TypesettingFeatures doesn't need to change. The places which rely on Ligatures,
        however, need to be updated to understand that there are many different kinds
        of ligatures.

        Indeed, after inspection, all of the places which inspect ligatures are more
        interested in a high-level concept of whether or not we can trust some simple
        computation. Therefore, we really have two things we care about: Kerning, and
        this high-level concept.

        This patch is the second step to update our view of the world to include
        font-feature-settings and font-variant-*. In particular, this patch simply
        splits TypesettingFeatures into two Booleans, one for Kerning, and one for
        Ligatures (which has no behavior change). Then, once they are separated, I can
        migrate the Ligatures Boolean to take on its new meaning.

        This change is purely mechanical.

        No new tests because there is no behavior change.

        * WebCore.xcodeproj/project.pbxproj:
        * css/CSSPrimitiveValueMappings.h:
        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
        (WebCore::CSSPrimitiveValue::operator FontCascadeDescription::Kerning):
        * platform/graphics/Font.cpp:
        (WebCore::Font::applyTransforms):
        * platform/graphics/Font.h:
        * platform/graphics/FontCascade.cpp:
        (WebCore::FontCascade::FontCascade):
        (WebCore::FontCascade::operator=):
        (WebCore::FontCascade::update):
        (WebCore::FontCascade::drawText):
        (WebCore::FontCascade::drawEmphasisMarks):
        (WebCore::FontCascade::width):
        (WebCore::FontCascade::adjustSelectionRectForText):
        (WebCore::FontCascade::offsetForPosition):
        (WebCore::FontCascade::setDefaultKerning):
        (WebCore::FontCascade::setDefaultLigatures):
        (WebCore::FontCascade::codePath):
        (WebCore::FontCascade::floatWidthForSimpleText):
        (WebCore::FontCascade::setDefaultTypesettingFeatures): Deleted.
        (WebCore::FontCascade::defaultTypesettingFeatures): Deleted.
        * platform/graphics/FontCascade.h:
        (WebCore::FontCascade::enableKerning):
        (WebCore::FontCascade::enableLigatures):
        (WebCore::FontCascade::computeEnableKerning):
        (WebCore::FontCascade::computeEnableLigatures):
        (WebCore::FontCascade::typesettingFeatures): Deleted.
        (WebCore::FontCascade::computeTypesettingFeatures): Deleted.
        * platform/graphics/FontDescription.cpp:
        (WebCore::FontCascadeDescription::FontCascadeDescription):
        * platform/graphics/FontDescription.h:
        (WebCore::FontCascadeDescription::setKerning):
        (WebCore::FontCascadeDescription::initialKerning):
        * platform/graphics/TypesettingFeatures.h: Removed.
        * platform/graphics/WidthIterator.cpp:
        (WebCore::WidthIterator::WidthIterator):
        (WebCore::WidthIterator::applyFontTransforms):
        (WebCore::WidthIterator::advanceInternal):
        * platform/graphics/WidthIterator.h:
        * platform/graphics/cocoa/FontCocoa.mm:
        (WebCore::Font::canRenderCombiningCharacterSequence):
        * platform/graphics/mac/ComplexTextControllerCoreText.mm:
        (WebCore::ComplexTextController::collectComplexTextRunsForCharacters):
        * platform/graphics/mac/SimpleFontDataCoreText.cpp:
        (WebCore::Font::getCFStringAttributes):
        * rendering/RenderBlockLineLayout.cpp:
        (WebCore::setLogicalWidthForTextRun):
        * rendering/line/BreakingContext.h:
        (WebCore::WordTrailingSpace::width):
        * svg/SVGFontData.h:

2015-10-13  Zalan Bujtas  <zalan@apple.com>

        Anonymous table objects: inline parent box requires inline-table child.
        https://bugs.webkit.org/show_bug.cgi?id=150090

        Reviewed by David Hyatt.

        According to the CSS2.1 specification, if a child needs anonymous table wrapper
        and the child's parent is an inline box, the generated table needs to be inline-table.
        (inline-block and block parents generate non-inline table) 

        Import W3C CSS2.1 anonymous table tests.

        * rendering/RenderElement.cpp:
        (WebCore::RenderElement::childRequiresTable):
        (WebCore::RenderElement::addChild):
        * rendering/RenderElement.h:
        * rendering/RenderInline.cpp:
        (WebCore::RenderInline::newChildIsInline):
        (WebCore::RenderInline::addChildIgnoringContinuation):
        (WebCore::RenderInline::addChildToContinuation):
        * rendering/RenderInline.h:
        * rendering/RenderTable.cpp:
        (WebCore::RenderTable::createAnonymousWithParentRenderer):

2015-10-13  Dean Jackson  <dino@apple.com>

        Device motion and orientation should only be visible from the main frame's security origin
        https://bugs.webkit.org/show_bug.cgi?id=150072
        <rdar://problem/23082036>

        Reviewed by Brent Fulgham.

        There are reports that gyroscope and accelerometer information can
        be used to detect keyboard entry. One initial step to reduce the
        risk is to forbid device motion and orientation events from
        being fired in frames that are a different security origin from the main page.

        Manual test: deviceorientation-main-frame-only.html

        * page/DOMWindow.cpp:
        (WebCore::DOMWindow::isSameSecurityOriginAsMainFrame): New helper function.
        (WebCore::DOMWindow::addEventListener): Check if we are the main frame, or the
        same security origin as the main frame. If not, don't add the event
        listeners.

2015-10-12  Dean Jackson  <dino@apple.com>

        ASSERT(m_motionManager) on emgn.com page
        https://bugs.webkit.org/show_bug.cgi?id=150070
        <rdar://problem/18383732>

        Reviewed by Simon Fraser.

        In the WebCoreMotionManager init method, we call
        into another setup method on the main thread.
        However, if a listener was attached before that
        ran, we'd ASSERT. This wasn't actually causing a bug
        because the main thread initialization would
        check the listeners once it got a chance to run.

        The fix is to only check status when we've
        actually initialized.

        * platform/ios/WebCoreMotionManager.h: New m_initialized boolean.
        * platform/ios/WebCoreMotionManager.mm: Check m_initialized before doing real work.
        (-[WebCoreMotionManager init]):
        (-[WebCoreMotionManager addMotionClient:]):
        (-[WebCoreMotionManager removeMotionClient:]):
        (-[WebCoreMotionManager addOrientationClient:]):
        (-[WebCoreMotionManager removeOrientationClient:]):
        (-[WebCoreMotionManager initializeOnMainThread]):

2015-10-13  Chris Dumez  <cdumez@apple.com>

        Avoid useless copies in range-loops that are using 'auto'
        https://bugs.webkit.org/show_bug.cgi?id=150091

        Reviewed by Sam Weinig.

        Avoid useless copies in range-loops that are using 'auto'. Also use
        'auto*' instead of 'auto' when range values are pointers for clarity.

2015-10-13  Simon Fraser  <simon.fraser@apple.com>

        Move Image::drawPattern for CG into GraphicsContext
        https://bugs.webkit.org/show_bug.cgi?id=150077

        Reviewed by Myles C. Maxfield.

        In order to consolidate code that calls into Core Graphics inside
        GraphicsContext, move the body of Image::drawPattern() into
        GraphicsContextCG.cpp, and do the same for Cairo.

        * platform/graphics/GraphicsContext.h:
        * platform/graphics/cairo/GraphicsContextCairo.cpp:
        (WebCore::GraphicsContext::drawPattern):
        * platform/graphics/cairo/ImageCairo.cpp:
        (WebCore::Image::drawPattern):
        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::drawPatternCallback):
        (WebCore::patternReleaseCallback):
        (WebCore::GraphicsContext::drawPattern):
        * platform/graphics/cg/ImageCG.cpp:
        (WebCore::Image::drawPattern):
        (WebCore::drawPatternCallback): Deleted.
        (WebCore::patternReleaseCallback): Deleted.

2015-10-13  Myles C. Maxfield  <mmaxfield@apple.com>

        Unprefix font-kerning
        https://bugs.webkit.org/show_bug.cgi?id=150080

        Reviewed by Sam Weinig.

        This is the last property in CSS3 Fonts which is prefixed.

        Test: fast/text/font-kerning.html

        * css/CSSPropertyNames.in:

2015-10-13  Said Abou-Hallawa  <sabouhallawa@apple.com>

        Add debug settings for using giant tiles (4096x4096)
        https://bugs.webkit.org/show_bug.cgi?id=149977
        <rdar://problem/23017093>

        Reviewed by Tim Horton.

        Instead of creating the GraphicsLayer with a fixed size 512x512, we need
        to read the useGiantTiles setting. If its value is true, we set the layer
        tileSize to 4096x4096.

        * page/Settings.in:
        Define the name of the setting and its default value.
        
        * platform/graphics/GraphicsLayerClient.h:
        (WebCore::GraphicsLayerClient::tileSize):
        Define tileSize() in the base class GraphicsLayerClient. This is going to
        be overridden RenderLayerBacking.
        
        * platform/graphics/TiledBacking.h:
        (WebCore::defaultTileSize):
        Define the default tileSize which will depend on the useGiantTiles
        setting.

        * platform/graphics/ca/GraphicsLayerCA.cpp:
        (WebCore::GraphicsLayerCA::platformCALayerTileSize):
        Implement the virtual function GraphicsLayerCA::platformCALayerTileSize().
        It passes the call to client GraphicsLayerClient which can be RenderLayerBacking
        in our case.

        * platform/graphics/ca/GraphicsLayerCA.h:
        Override base class function PlatformCALayerClient::PlatformCALayerClient().

        * platform/graphics/ca/PlatformCALayerClient.h:
        (WebCore::PlatformCALayerClient::platformCALayerTileSize):
        Define platformCALayerTileSize() in the base class PlatformCALayerClient.
        This is going to be overridden GraphicsLayerCA.

        * platform/graphics/ca/TileController.cpp:
        (WebCore::TileController::TileController):
        No need for the member m_tileSize.
        
        (WebCore::TileController::computeTileCoverageRect):
        Use the function tileSize() instead of using the static values.
        
        (WebCore::TileController::tileSize):
        The tileSize will be retrieved from the owning graphics layer.
        
        * platform/graphics/ca/TileController.h:
        No need for the member m_tileSize. The tileSize will be retrieved from the owning graphics layer.

        * rendering/RenderLayerBacking.cpp:
        (WebCore::RenderLayerBacking::setTiledBackingHasMargins):
        Use the function tileSize() instead of using the static values.
        
        (WebCore::RenderLayerBacking::tileSize):
        Override base class function GraphicsLayerClient::tileSize().
        
        * rendering/RenderLayerBacking.h:
        Define the concrete method RenderLayerBacking::tilSize().

2015-10-13  Antti Koivisto  <antti@apple.com>

        Try to fix ENABLE(DETAILS_ELEMENT) with SHADOW_DOM disabled.

        * dom/Element.cpp:
        (WebCore::Element::attributeChanged):
        * dom/Node.cpp:
        (WebCore::traverseStyleParent):

2015-10-13  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Fix license and copyrights of WebCore js binding builtin files
        https://bugs.webkit.org/show_bug.cgi?id=150027

        Reviewed by Darin Adler.

        Fixing copyright on all three files.
        Moving to BSD-like license as they should have been in the first place.
        Ordering lexicographically the builtin names in WebCoreBuiltinNames.h.

        No change in behaviour.

        * bindings/js/WebCoreBuiltinNames.h:
        * bindings/js/WebCoreJSBuiltins.cpp:
        * bindings/js/WebCoreJSBuiltins.h:
        * bindings/js/WebCoreJSBuiltinInternals.h:

2015-10-12  Antti Koivisto  <antti@apple.com>

        Implement iterator for traversing composed DOM
        https://bugs.webkit.org/show_bug.cgi?id=149997

        Reviewed by Ryosuke Niwa.

        ComposedTreeIterator traverses the DOM in composed tree order. This means it enters
        shadow trees and follows slots created by Shadow DOM API correctly.

        auto children = composedTreeChildren(containerNode);
        for (auto& composedChild : children)
            ...

        auto descendants = composedTreeDescendants(containerNode);
        for (auto& composedDescendant : descendants)
            ...

        * WebCore.xcodeproj/project.pbxproj:
        * dom/ComposedTreeIterator.cpp: Added.
        (WebCore::ComposedTreeIterator::initializeShadowStack):
        (WebCore::ComposedTreeIterator::traverseNextInShadowTree):
        (WebCore::ComposedTreeIterator::traverseNextSiblingSlot):
        (WebCore::ComposedTreeIterator::traversePreviousSiblingSlot):
        (WebCore::ComposedTreeIterator::traverseParentInShadowTree):
        * dom/ComposedTreeIterator.h: Added.
        (WebCore::ComposedTreeIterator::operator*):
        (WebCore::ComposedTreeIterator::operator->):
        (WebCore::ComposedTreeIterator::operator==):
        (WebCore::ComposedTreeIterator::operator!=):
        (WebCore::ComposedTreeIterator::ShadowContext::ShadowContext):
        (WebCore::ComposedTreeIterator::ComposedTreeIterator):
        (WebCore::ComposedTreeIterator::traverseNext):
        (WebCore::ComposedTreeIterator::traverseNextSibling):
        (WebCore::ComposedTreeIterator::traversePreviousSibling):
        (WebCore::ComposedTreeIterator::traverseParent):
        (WebCore::ComposedTreeChildAdapter::Iterator::Iterator):
        (WebCore::ComposedTreeChildAdapter::Iterator::operator++):
        (WebCore::ComposedTreeChildAdapter::Iterator::operator--):
        (WebCore::ComposedTreeChildAdapter::ComposedTreeChildAdapter):
        (WebCore::ComposedTreeChildAdapter::begin):
        (WebCore::ComposedTreeChildAdapter::end):
        (WebCore::ComposedTreeChildAdapter::at):
        (WebCore::composedTreeChildren):
        * dom/NodeRenderingTraversal.cpp:
        (WebCore::NodeRenderingTraversal::parentSlow):
        (WebCore::NodeRenderingTraversal::nextInScope):
        (WebCore::NodeRenderingTraversal::firstChildSlow): Deleted.
        (WebCore::NodeRenderingTraversal::nextSiblingSlow): Deleted.
        (WebCore::NodeRenderingTraversal::previousSiblingSlow): Deleted.
        * dom/NodeRenderingTraversal.h:
        (WebCore::NodeRenderingTraversal::parent):
        (WebCore::NodeRenderingTraversal::firstChild): Deleted.
        (WebCore::NodeRenderingTraversal::nextSibling): Deleted.
        (WebCore::NodeRenderingTraversal::previousSibling): Deleted.
        * style/RenderTreePosition.cpp:
        (WebCore::RenderTreePosition::computeNextSibling):

            Restore the full assert.

        (WebCore::RenderTreePosition::invalidateNextSibling):
        (WebCore::RenderTreePosition::previousSiblingRenderer):
        (WebCore::RenderTreePosition::nextSiblingRenderer):

            Make these member functions.
            Use the iterator. This is fixes some bugs and allows enabling a test case.

        * style/RenderTreePosition.h:
        * style/StyleResolveTree.cpp:
        (WebCore::Style::textRendererIsNeeded):

2015-10-13  ChangSeok Oh  <changseok.oh@collabora.com>

        [GTK] Use GUniquePtr for GtkIconInfo
        https://bugs.webkit.org/show_bug.cgi?id=150082

        Reviewed by Carlos Garcia Campos.

        GtkIconInfo cab be wrapped by a smart pointer, GUniqueptr.

        No new test required since no functionality changed.

        * rendering/RenderThemeGtk.cpp:
        (WebCore::getStockSymbolicIconForWidgetType):

2015-10-12  Jaehun Lim  <ljaehun.lim@samsung.com>

        Unreviewed, fix debug build warning.

        %llu needs 'long long unsigned int'.

        Type casting unit64_t to long long unsigned int.

        * Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBOpenDBRequest::onUpgradeNeeded):
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::notifyConnectionsOfVersionChange):

2015-10-12  Simon Fraser  <simon.fraser@apple.com>

        Speculative Cairo build fixes after r190910.

        * platform/graphics/cairo/ImageBufferCairo.cpp:
        (WebCore::ImageBuffer::drawPattern):
        * platform/graphics/cairo/ImageCairo.cpp:
        (WebCore::Image::drawPattern):

2015-10-12  Simon Fraser  <simon.fraser@apple.com>

        Fix iOS and Efl builds.

        * platform/graphics/NamedImageGeneratedImage.cpp:
        (WebCore::NamedImageGeneratedImage::drawPattern):

2015-10-12  Simon Fraser  <simon.fraser@apple.com>

        Remove Image::spaceSize() and ImageBuffer::spaceSize()
        https://bugs.webkit.org/show_bug.cgi?id=150064

        Reviewed by Tim Horton.

        Image spacing when tiled should not be a property of the image; but a description
        of how it's drawn, like tile size. So remove spacing from Image and ImageBuffer,
        and pass it in as an argument.

        * platform/graphics/BitmapImage.cpp:
        (WebCore::BitmapImage::drawPattern):
        * platform/graphics/BitmapImage.h:
        * platform/graphics/CrossfadeGeneratedImage.cpp:
        (WebCore::CrossfadeGeneratedImage::drawPattern):
        * platform/graphics/CrossfadeGeneratedImage.h:
        * platform/graphics/GeneratedImage.h:
        * platform/graphics/GradientImage.cpp:
        (WebCore::GradientImage::drawPattern):
        * platform/graphics/GradientImage.h:
        * platform/graphics/GraphicsContext.cpp:
        (WebCore::GraphicsContext::drawTiledImage):
        * platform/graphics/GraphicsContext.h:
        * platform/graphics/Image.cpp:
        (WebCore::Image::drawTiled):
        * platform/graphics/Image.h:
        (WebCore::Image::spaceSize): Deleted.
        (WebCore::Image::setSpaceSize): Deleted.
        * platform/graphics/ImageBuffer.h:
        (WebCore::ImageBuffer::spaceSize): Deleted.
        (WebCore::ImageBuffer::setSpaceSize): Deleted.
        * platform/graphics/NamedImageGeneratedImage.cpp:
        (WebCore::NamedImageGeneratedImage::drawPattern):
        * platform/graphics/NamedImageGeneratedImage.h:
        * platform/graphics/cg/ImageBufferCG.cpp:
        (WebCore::ImageBuffer::copyImage):
        (WebCore::ImageBuffer::drawPattern):
        * platform/graphics/cg/ImageCG.cpp:
        (WebCore::Image::drawPattern):
        * rendering/RenderBoxModelObject.cpp:
        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
        * svg/graphics/SVGImage.cpp:
        (WebCore::SVGImage::drawPatternForContainer):
        * svg/graphics/SVGImage.h:
        * svg/graphics/SVGImageForContainer.cpp:
        (WebCore::SVGImageForContainer::drawPattern):
        * svg/graphics/SVGImageForContainer.h:

2015-10-12  Andreas Kling  <akling@apple.com>

        Have TransformState::mappedSecondaryQuad() return an Optional<FloatQuad>.
        <https://webkit.org/b/150057>

        Reviewed by Simon Fraser.

        Using Optional instead of std::unique_ptr allows us to signal the absence of a
        secondary quad without incurring a heap allocation in cases where one is present.

        This dodges ~132000 malloc/free pairs on loading thelocal.se

        * platform/graphics/ca/GraphicsLayerCA.cpp:
        (WebCore::GraphicsLayerCA::computeVisibleAndCoverageRect):
        * platform/graphics/transforms/TransformState.cpp:
        (WebCore::TransformState::mappedSecondaryQuad):
        * platform/graphics/transforms/TransformState.h:

2015-10-12  Brady Eidson  <beidson@apple.com>

        Followup to:
        Modern IDB: Start version change transaction for connections to new database.
        https://bugs.webkit.org/show_bug.cgi?id=150033

        Reviewed by NOBODY (Fixing existing test flakiness)

        No new tests (Covered by existing tests)

        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::handleOpenDatabaseOperations): Early return if a version change transaction
          is already in progress.

2015-10-12  Myles C. Maxfield  <mmaxfield@apple.com>

        [Font Features] Tiny cleanup regarding FontCascade::typesettingFeatures()
        https://bugs.webkit.org/show_bug.cgi?id=150051

        Reviewed by Simon Fraser.

        There are no typesetting features which aren't kerning nor ligatures.

        No new tests because there is no behavior difference.

        * platform/graphics/FontCascade.cpp:
        (WebCore::FontCascade::codePath):
        * platform/graphics/WidthIterator.h:
        (WebCore::WidthIterator::supportsTypesettingFeatures): Deleted.

2015-10-12  Simon Fraser  <simon.fraser@apple.com>

        Add a CGContextStateSaver and use it
        https://bugs.webkit.org/show_bug.cgi?id=150049

        Reviewed by Tim Horton.

        Add a stack-based graphics state save/restore class for CGContext,
        like the one we have for GraphicsContext, and use it in GraphicsContextCG.
        
        * platform/graphics/cg/GraphicsContextCG.cpp:
        (WebCore::GraphicsContext::drawNativeImage):
        (WebCore::GraphicsContext::drawLine):
        (WebCore::GraphicsContext::drawJoinedLines):
        (WebCore::GraphicsContext::fillPath):
        (WebCore::GraphicsContext::strokePath):
        (WebCore::GraphicsContext::fillRect):
        (WebCore::GraphicsContext::platformFillRoundedRect):
        (WebCore::GraphicsContext::fillRectWithRoundedHole):
        (WebCore::GraphicsContext::strokeRect):
        * platform/graphics/cg/GraphicsContextCG.h:
        (WebCore::CGContextStateSaver::CGContextStateSaver):
        (WebCore::CGContextStateSaver::~CGContextStateSaver):
        (WebCore::CGContextStateSaver::save):
        (WebCore::CGContextStateSaver::restore):

2015-10-12  Zalan Bujtas  <zalan@apple.com>

        display: table-cell; bug when resizing window
        https://bugs.webkit.org/show_bug.cgi?id=138167

        Reviewed by David Hyatt.

        Clean up anonymous table wrappers all the way up to RenderTable.
        This patch ensures that we don't keep the generated RenderTable/RenderSection/RenderCaption/RenderRow
        objects around in the tree anymore when the last child is destroyed.

        Import W3C CSS2.1 anonymous table tests.

        * rendering/RenderObject.cpp:
        (WebCore::RenderObject::destroyAndCleanupAnonymousWrappers):

2015-10-12  Myles C. Maxfield  <mmaxfield@apple.com>

        REGRESSION(r182192): Ligatures do not interact correctly with SHY in some fonts
        https://bugs.webkit.org/show_bug.cgi?id=150006

        Reviewed by Simon Fraser.

        When performing font transforms and we encounter kCGFontIndexInvalid, we filter it out of the
        GlyphBuffer. However, this filter was only interacting with part of the GlyphBuffer instead
        of the whole thing. This causes glyph IDs from one font to be rendered with other fonts,
        thereby showing garbage glyphs.

        However, now that <rdar://problem/20230073> is fixed, we don't need to perform this filter in
        the first place.

        Test: fast/text/undefined-glyph-with-ligature.html

        * platform/graphics/GlyphBuffer.h:
        (WebCore::GlyphBuffer::copyItem):
        (WebCore::GlyphBuffer::swap):
        * platform/graphics/WidthIterator.cpp:
        (WebCore::WidthIterator::applyFontTransforms):

2015-10-12  Antoine Quint  <graouts@apple.com>

        [SVG] Handle endEvent for svg animations
        https://bugs.webkit.org/show_bug.cgi?id=121587

        Reviewed by Dean Jackson.

        Add support for the "endEvent" SVG event triggered when an animation completes, as
        specified in http://www.w3.org/TR/SMIL3/smil-timing.html#q135. This event doesn't
        bubble and can't be canceled. Added test coverage for the event through the DOM
        Events API as well as the declarative SMIL Animation syntax.

        Adapted from a Chromium patch by pavan.e@samsung.com
        https://chromium.googlesource.com/chromium/blink/+/4d415ca0268231aa80e3552fe21bf3480a6978f8

        Tests: svg/animations/end-event-declarative-expected.svg
               svg/animations/end-event-declarative.svg
               svg/animations/end-event-script-expected.svg
               svg/animations/end-event-script.svg

        * svg/animation/SMILTimeContainer.cpp:
        (WebCore::SMILTimeContainer::updateAnimations):
        * svg/animation/SVGSMILElement.cpp:
        (WebCore::smilEndEventSender):
        (WebCore::SVGSMILElement::~SVGSMILElement):
        (WebCore::SVGSMILElement::progress):
        (WebCore::SVGSMILElement::dispatchPendingEvent):
        * svg/animation/SVGSMILElement.h:
        (WebCore::SVGSMILElement::hasConditionsConnected):

2015-10-12  Per Arne Vollan  <peavo@outlook.com>

        [Curl] Increase limit of parallel network requests.
        https://bugs.webkit.org/show_bug.cgi?id=150035

        Reviewed by Alex Christensen.

        If the limit is too low, other network requests will often be blocked until
        active requests finishes. This can affect performance in a negative way.

        * platform/network/curl/ResourceHandleManager.cpp:

2015-10-12  Brady Eidson  <beidson@apple.com>

        Modern IDB: Start version change transaction for connections to new database.
        https://bugs.webkit.org/show_bug.cgi?id=150033

        Reviewed by Alex Christensen.

        No new tests (Covered by changes to existing tests).

        * CMakeLists.txt:
        * Modules/indexeddb/IDBDatabase.h:
        
        * Modules/indexeddb/client/IDBAnyImpl.cpp:
        (WebCore::IDBClient::IDBAny::IDBAny):
        (WebCore::IDBClient::IDBAny::~IDBAny):
        (WebCore::IDBClient::IDBAny::idbDatabase):
        (WebCore::IDBClient::IDBAny::domStringList):
        (WebCore::IDBClient::IDBAny::idbCursor):
        (WebCore::IDBClient::IDBAny::idbCursorWithValue):
        (WebCore::IDBClient::IDBAny::idbFactory):
        (WebCore::IDBClient::IDBAny::idbIndex):
        (WebCore::IDBClient::IDBAny::idbObjectStore):
        (WebCore::IDBClient::IDBAny::idbTransaction):
        (WebCore::IDBClient::IDBAny::scriptValue):
        (WebCore::IDBClient::IDBAny::integer):
        (WebCore::IDBClient::IDBAny::string):
        (WebCore::IDBClient::IDBAny::keyPath):
        * Modules/indexeddb/client/IDBAnyImpl.h:
        (WebCore::IDBClient::IDBAny::create):
        
        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::fireVersionChangeEvent):
        (WebCore::IDBClient::IDBConnectionToServer::registerDatabaseConnection):
        (WebCore::IDBClient::IDBConnectionToServer::unregisterDatabaseConnection):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        
        * Modules/indexeddb/client/IDBDatabaseImpl.cpp: Added.
        (WebCore::IDBClient::IDBDatabase::create):
        (WebCore::IDBClient::IDBDatabase::IDBDatabase):
        (WebCore::IDBClient::IDBDatabase::~IDBDatabase):
        (WebCore::IDBClient::IDBDatabase::name):
        (WebCore::IDBClient::IDBDatabase::version):
        (WebCore::IDBClient::IDBDatabase::objectStoreNames):
        (WebCore::IDBClient::IDBDatabase::createObjectStore):
        (WebCore::IDBClient::IDBDatabase::transaction):
        (WebCore::IDBClient::IDBDatabase::deleteObjectStore):
        (WebCore::IDBClient::IDBDatabase::close):
        (WebCore::IDBClient::IDBDatabase::activeDOMObjectName):
        (WebCore::IDBClient::IDBDatabase::canSuspendForPageCache):
        (WebCore::IDBClient::IDBDatabase::startVersionChangeTransaction):
        * Modules/indexeddb/client/IDBDatabaseImpl.h: Added.
        (WebCore::IDBClient::IDBDatabase::info):
        
        * Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBOpenDBRequest::onError):
        (WebCore::IDBClient::IDBOpenDBRequest::onSuccess):
        (WebCore::IDBClient::IDBOpenDBRequest::onUpgradeNeeded):
        (WebCore::IDBClient::IDBOpenDBRequest::requestCompleted):
        * Modules/indexeddb/client/IDBOpenDBRequestImpl.h:
        
        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::IDBRequest):
        (WebCore::IDBClient::IDBRequest::result):
        (WebCore::IDBClient::IDBRequest::source):
        (WebCore::IDBClient::IDBRequest::transaction):
        * Modules/indexeddb/client/IDBRequestImpl.h:
        (WebCore::IDBClient::IDBRequest::connection):
        
        * Modules/indexeddb/client/IDBTransactionImpl.cpp:
        (WebCore::IDBClient::IDBTransaction::create):
        (WebCore::IDBClient::IDBTransaction::IDBTransaction):
        (WebCore::IDBClient::IDBTransaction::~IDBTransaction):
        (WebCore::IDBClient::IDBTransaction::mode):
        (WebCore::IDBClient::IDBTransaction::db):
        (WebCore::IDBClient::IDBTransaction::error):
        (WebCore::IDBClient::IDBTransaction::objectStore):
        (WebCore::IDBClient::IDBTransaction::abort):
        (WebCore::IDBClient::IDBTransaction::activeDOMObjectName):
        (WebCore::IDBClient::IDBTransaction::canSuspendForPageCache):
        * Modules/indexeddb/client/IDBTransactionImpl.h:
        (WebCore::IDBClient::IDBTransaction::info):
        
        * Modules/indexeddb/client/IDBVersionChangeEventImpl.cpp:
        (WebCore::IDBClient::IDBVersionChangeEvent::IDBVersionChangeEvent):
        (WebCore::IDBClient::IDBVersionChangeEvent::eventInterface):
        * Modules/indexeddb/client/IDBVersionChangeEventImpl.h:
        (WebCore::IDBClient::IDBVersionChangeEvent::create):
        
        * Modules/indexeddb/legacy/LegacyDatabase.h:
        
        * Modules/indexeddb/server/IDBConnectionToClient.cpp:
        (WebCore::IDBServer::IDBConnectionToClient::fireVersionChangeEvent):
        * Modules/indexeddb/server/IDBConnectionToClient.h:
        * Modules/indexeddb/server/IDBConnectionToClientDelegate.h:
        
        * Modules/indexeddb/server/IDBServer.cpp:
        (WebCore::IDBServer::IDBServer::registerDatabaseConnection):
        (WebCore::IDBServer::IDBServer::unregisterDatabaseConnection):
        (WebCore::IDBServer::IDBServer::deleteDatabase):
        * Modules/indexeddb/server/IDBServer.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabase.cpp:
        (WebCore::IDBServer::UniqueIDBDatabase::info):
        (WebCore::IDBServer::UniqueIDBDatabase::handleOpenDatabaseOperations):
        (WebCore::IDBServer::UniqueIDBDatabase::hasAnyOpenConnections):
        (WebCore::IDBServer::UniqueIDBDatabase::startVersionChangeTransaction):
        (WebCore::IDBServer::UniqueIDBDatabase::notifyConnectionsOfVersionChange):
        (WebCore::IDBServer::UniqueIDBDatabase::addOpenDatabaseConnection):
        * Modules/indexeddb/server/UniqueIDBDatabase.h:
        
        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.cpp: 
        (WebCore::IDBServer::nextDatabaseConnectionIdentifier):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::create):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::UniqueIDBDatabaseConnection):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::fireVersionChangeEvent):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::createVersionChangeTransaction):

        * Modules/indexeddb/server/UniqueIDBDatabaseConnection.h:
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::identifier):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::database):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::connectionToClient):
        (WebCore::IDBServer::UniqueIDBDatabaseConnection::closePending):
        
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.cpp:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::create):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::UniqueIDBDatabaseTransaction):
        * Modules/indexeddb/server/UniqueIDBDatabaseTransaction.h:
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::databaseConnection):
        (WebCore::IDBServer::UniqueIDBDatabaseTransaction::info):
        
        * Modules/indexeddb/shared/IDBDatabaseInfo.cpp:
        (WebCore::IDBDatabaseInfo::IDBDatabaseInfo):
        * Modules/indexeddb/shared/IDBDatabaseInfo.h:
        (WebCore::IDBDatabaseInfo::name):
        (WebCore::IDBDatabaseInfo::version):
        (WebCore::IDBDatabaseInfo::IDBDatabaseInfo): Deleted.
        
        * Modules/indexeddb/shared/IDBError.h:
        
        * Modules/indexeddb/shared/IDBRequestData.cpp:
        (WebCore::IDBRequestData::IDBRequestData):
        (WebCore::IDBRequestData::requestedVersion):
        * Modules/indexeddb/shared/IDBRequestData.h:
        
        * Modules/indexeddb/shared/IDBResourceIdentifier.cpp:
        (WebCore::nextClientResourceNumber):
        (WebCore::nextServerResourceNumber):
        (WebCore::IDBResourceIdentifier::IDBResourceIdentifier):
        (WebCore::IDBResourceIdentifier::emptyValue):
        (WebCore::IDBResourceIdentifier::deletedValue):
        (WebCore::nextResourceNumber): Deleted.
        * Modules/indexeddb/shared/IDBResourceIdentifier.h:
        
        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::IDBResultData):
        (WebCore::IDBResultData::error):
        (WebCore::IDBResultData::openDatabaseSuccess):
        (WebCore::IDBResultData::openDatabaseUpgradeNeeded):
        (WebCore::IDBResultData::databaseInfo):
        (WebCore::IDBResultData::transactionInfo):
        * Modules/indexeddb/shared/IDBResultData.h:
        (WebCore::IDBResultData::type):
        (WebCore::IDBResultData::databaseConnectionIdentifier):
        
        * Modules/indexeddb/shared/IDBTransactionInfo.cpp:
        (WebCore::IDBTransactionInfo::IDBTransactionInfo):
        (WebCore::IDBTransactionInfo::versionChange):
        (WebCore::IDBTransactionInfo::isolatedCopy):
        * Modules/indexeddb/shared/IDBTransactionInfo.h:
        (WebCore::IDBTransactionInfo::identifier):
        (WebCore::IDBTransactionInfo::mode):
        (WebCore::IDBTransactionInfo::newVersion):
        
        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
        (WebCore::InProcessIDBServer::fireVersionChangeEvent):
        * Modules/indexeddb/shared/InProcessIDBServer.h:
        
        * WebCore.xcodeproj/project.pbxproj:
        
        * platform/CrossThreadCopier.cpp:
        (WebCore::IDBTransactionInfo>::copy):
        * platform/CrossThreadCopier.h:

2015-10-12  Said Abou-Hallawa  <sabouhallawa@apple.com>

        REGRESSION(r184895): border-image should always slice the SVG image to nine pieces when drawing it in the container element
        https://bugs.webkit.org/show_bug.cgi?id=149901
        <rdar://problem/21995596>

        Reviewed by Darin Adler.

        The nine-pieces algorithm should be applied to the border-image regardless
        whether the image has an intrinsic size or not. It is not guaranteed to have
        a meaningful border-image in all the cases of non-intrinsic size images. But
        it should work as expected in most of the cases. 

        * rendering/RenderBoxModelObject.cpp:
        * rendering/RenderBoxModelObject.h:
        (WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions):
        Revert the changes which were added to return whether the image has
        intrinsic size or not.
        
        (WebCore::RenderBoxModelObject::calculateFillTileSize):
        (WebCore::RenderBoxModelObject::paintNinePieceImage):
        Size of the image is now the return value of calculateImageIntrinsicDimensions().
        
        * rendering/RenderListMarker.cpp:
        (WebCore::RenderListMarker::updateContent):
        * rendering/shapes/ShapeOutsideInfo.cpp:
        (WebCore::ShapeOutsideInfo::createShapeForImage):
        Size of the image is now the return value of calculateImageIntrinsicDimensions().
        
        * rendering/style/NinePieceImage.cpp:
        * rendering/style/NinePieceImage.h:
        (WebCore::NinePieceImage::paint):
        Delete the logic for the non-intrinsic case. Both intrinsic and non-intrinsic
        cases will be treated the same.

        (WebCore::NinePieceImage::computeNineRects):
        (WebCore::NinePieceImage::computeSideTileScale):
        (WebCore::NinePieceImage::computeMiddleTileScale):
        (WebCore::NinePieceImage::computeTileScales):
        (WebCore::NinePieceImage::computeIntrinsicRects): Deleted.
        (WebCore::NinePieceImage::computeIntrinsicSideTileScale): Deleted.
        (WebCore::NinePieceImage::computeIntrinsicMiddleTileScale): Deleted.
        (WebCore::NinePieceImage::computeIntrinsicTileScales): Deleted.
        Remove *Intrinsic* from the name of the functions.

        (WebCore::NinePieceImage::computeNonIntrinsicRects): Deleted.
        (WebCore::NinePieceImage::computeNonIntrinsicTileScales): Deleted.
        Delete the *NonIntrinsic* functions.

2015-10-12  Simon Fraser  <simon.fraser@apple.com>

        Clip-path transitions sometimes trigger endless animation timers
        https://bugs.webkit.org/show_bug.cgi?id=150018

        Reviewed by Tim Horton.
        
        Transitioning -webkit-clip-path could trigger endless animation
        timers, because when CompositeAnimation::updateTransitions() calls
        isTargetPropertyEqual(), a false negative answer triggers canceling the
        current transition and starting a new one over and over.
        
        This happened because StyleRareNonInheritedData simply tested pointer
        equality for m_clipPath and m_shapeOutside. Both of these need to do deep
        equality testing, requiring the implementation of operator== in BasicShapes
        classes.
        
        In addition, the PropertyWrappers in CSSPropertyAnimation need equals()
        implementations that also do more than pointer equality testing.

        Tests: transitions/clip-path-transitions.html
               transitions/shape-outside-transitions.html

        * page/animation/CSSPropertyAnimation.cpp:
        (WebCore::PropertyWrapperClipPath::equals):
        (WebCore::PropertyWrapperShape::equals):
        * rendering/ClipPathOperation.h:
        * rendering/style/BasicShapes.cpp:
        (WebCore::BasicShapeCircle::operator==):
        (WebCore::BasicShapeEllipse::operator==):
        (WebCore::BasicShapePolygon::operator==):
        (WebCore::BasicShapeInset::operator==):
        * rendering/style/BasicShapes.h:
        (WebCore::BasicShapeCenterCoordinate::operator==):
        (WebCore::BasicShapeRadius::operator==):
        * rendering/style/ShapeValue.cpp:
        (WebCore::pointersOrValuesEqual):
        (WebCore::ShapeValue::operator==):
        * rendering/style/ShapeValue.h:
        (WebCore::ShapeValue::operator!=):
        (WebCore::ShapeValue::operator==): Deleted.
        (WebCore::ShapeValue::ShapeValue): Deleted.
        * rendering/style/StyleRareNonInheritedData.cpp:
        (WebCore::StyleRareNonInheritedData::operator==):
        (WebCore::StyleRareNonInheritedData::clipPathOperationsEquivalent):
        (WebCore::StyleRareNonInheritedData::shapeOutsideDataEquivalent):
        * rendering/style/StyleRareNonInheritedData.h:

2015-10-12  Myles C. Maxfield  <mmaxfield@apple.com>

        Test font-variant-* and font-feature-settings on Yosemite and Mavericks
        https://bugs.webkit.org/show_bug.cgi?id=149778

        Reviewed by Simon Fraser.

        We can simply call the function which enables features on Yosemite and Mavericks.

        * platform/graphics/cocoa/FontCacheCoreText.cpp:
        (WebCore::platformFontLookupWithFamily):
        (WebCore::fontWithFamily):

2015-10-09  Anders Carlsson  <andersca@apple.com>

        Don't allow plug-ins to override image types for <embed> elements
        https://bugs.webkit.org/show_bug.cgi?id=149979

        Reviewed by Tim Horton.

        Stop allowing plug-ins to take over image types for <embed> elements. We already do this
        for <object> elements, but had to make <embed> elements exempt because of webkit.org/b/49016.
        The QuickTime plug-in hasn't supported image types since Lion, so there's no point in keeping this code around.

        * html/HTMLAppletElement.cpp:
        (WebCore::HTMLAppletElement::HTMLAppletElement):
        * html/HTMLEmbedElement.cpp:
        (WebCore::HTMLEmbedElement::HTMLEmbedElement):
        * html/HTMLObjectElement.cpp:
        (WebCore::HTMLObjectElement::HTMLObjectElement):
        (WebCore::HTMLObjectElement::parametersForPlugin):
        * html/HTMLPlugInImageElement.cpp:
        (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
        (WebCore::HTMLPlugInImageElement::isImageType):
        (WebCore::HTMLPlugInImageElement::wouldLoadAsNetscapePlugin):
        * html/HTMLPlugInImageElement.h:
        (WebCore::HTMLPlugInImageElement::shouldPreferPlugInsForImages): Deleted.
        * loader/EmptyClients.h:
        * loader/FrameLoaderClient.h:
        * loader/SubframeLoader.cpp:
        (WebCore::SubframeLoader::resourceWillUsePlugin):
        (WebCore::SubframeLoader::requestObject):
        (WebCore::SubframeLoader::shouldUsePlugin):
        * loader/SubframeLoader.h:

2015-10-12  Zan Dobersek  <zdobersek@igalia.com>

        Unreviewed, fixing debug builds with Clang on Linux
        by including the stdio.h header where it's required
        under a debug configuration.

        * page/scrolling/ScrollingStateTree.cpp:
        (WebCore::ScrollingStateTree::ScrollingStateTree):
        * rendering/SimpleLineLayoutFunctions.cpp:

2015-10-12  Zan Dobersek  <zdobersek@igalia.com>

        Unreviewed, followup to r190643.

        Inline the std::function<> constructor wrappings around lambdas
        into a single line, instead of spanning it across four lines.

        * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
        (WebCore::InbandTextTrackPrivateGStreamer::handleSample):
        (WebCore::InbandTextTrackPrivateGStreamer::streamChanged):
        (WebCore::InbandTextTrackPrivateGStreamer::notifyTrackOfSample):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
        (WebCore::MediaPlayerPrivateGStreamer::videoChanged):
        (WebCore::MediaPlayerPrivateGStreamer::videoCapsChanged):
        (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideo):
        (WebCore::MediaPlayerPrivateGStreamer::audioChanged):
        (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfAudio):
        (WebCore::MediaPlayerPrivateGStreamer::textChanged):
        (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfText):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
        (WebCore::MediaPlayerPrivateGStreamerBase::volumeChanged):
        (WebCore::MediaPlayerPrivateGStreamerBase::networkState):
        (WebCore::MediaPlayerPrivateGStreamerBase::muteChanged):
        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
        (WebCore::TrackPrivateBaseGStreamer::activeChanged):
        (WebCore::TrackPrivateBaseGStreamer::tagsChanged):
        (WebCore::TrackPrivateBaseGStreamer::notifyTrackOfActiveChanged):
        * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
        (webkitVideoSinkRender):
        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
        (webKitWebSrcChangeState):
        (webKitWebSrcNeedDataCb):
        (webKitWebSrcEnoughDataMainCb):
        (webKitWebSrcEnoughDataCb):
        (webKitWebSrcSeekMainCb):
        (webKitWebSrcSeekDataCb):

2015-10-11  Brian Burg  <bburg@apple.com>

        Add missing builtins files to the Xcode projects
        https://bugs.webkit.org/show_bug.cgi?id=150015

        Reviewed by Yusuke Suzuki.

        * WebCore.xcodeproj/project.pbxproj:

2015-10-11  Simon Fraser  <simon.fraser@apple.com>

        Cleanup and simplification of SVG path-related classes
        https://bugs.webkit.org/show_bug.cgi?id=150011

        Reviewed by Zalan Bujtas.

        Many SVG path-related subclasses were stateful, but only because code in
        SVGPathUtilities kept global copies around for no reason. A microbenchmark
        showed that there was no benefit to keeping global singletons of SVGPathBuilder,
        SVGPathSegListBuilder, SVGPathByteStreamBuilder, SVGPathStringBuilder,
        SVGPathTraversalStateBuilder, SVGPathParser and SVGPathBlender.
        
        Making these classes not be re-usable makes the code much simpler, allowing
        their SVGPathSources, SVGPathConsumers, SVGPathByteStream etc. to be stored
        by reference, and eliminating the cleanup() function which created annoying
        ordering issues.
        
        Code that uses SVGPathParser and SVGPathBlender is further simplified by having
        these classes expose only static functions, hiding any internal statefulness.

        * svg/SVGPathBlender.cpp: Remove the m_progress member variable and instead
        pass progress to the various blend functions, as we do for other blend functions.
        Expose two only static functions. Pointers to references.
        (WebCore::SVGPathBlender::addAnimatedPath):
        (WebCore::SVGPathBlender::blendAnimatedPath):
        (WebCore::SVGPathBlender::SVGPathBlender):
        (WebCore::SVGPathBlender::blendAnimatedDimensonalFloat):
        (WebCore::SVGPathBlender::blendAnimatedFloatPoint):
        (WebCore::SVGPathBlender::blendMoveToSegment):
        (WebCore::SVGPathBlender::blendLineToSegment):
        (WebCore::SVGPathBlender::blendLineToHorizontalSegment):
        (WebCore::SVGPathBlender::blendLineToVerticalSegment):
        (WebCore::SVGPathBlender::blendCurveToCubicSegment):
        (WebCore::SVGPathBlender::blendCurveToCubicSmoothSegment):
        (WebCore::SVGPathBlender::blendCurveToQuadraticSegment):
        (WebCore::SVGPathBlender::blendCurveToQuadraticSmoothSegment):
        (WebCore::SVGPathBlender::blendArcToSegment):
        (WebCore::SVGPathBlender::cleanup): Deleted.
        * svg/SVGPathBlender.h: Make the constructor take a ref to the destination Path,
        which is stored by reference.
        * svg/SVGPathBuilder.cpp:
        (WebCore::SVGPathBuilder::SVGPathBuilder):
        (WebCore::SVGPathBuilder::moveTo):
        (WebCore::SVGPathBuilder::lineTo):
        (WebCore::SVGPathBuilder::curveToCubic):
        (WebCore::SVGPathBuilder::closePath):
        * svg/SVGPathBuilder.h:
        (WebCore::SVGPathBuilder::setCurrentPath): Deleted.
        * svg/SVGPathByteStreamBuilder.cpp: References, assertions removed.
        (WebCore::SVGPathByteStreamBuilder::SVGPathByteStreamBuilder):
        * svg/SVGPathByteStreamBuilder.h:
        (WebCore::SVGPathByteStreamBuilder::writeType):
        (WebCore::SVGPathByteStreamBuilder::setCurrentByteStream): Deleted.
        * svg/SVGPathConsumer.h:
        * svg/SVGPathElement.cpp:
        * svg/SVGPathParser.cpp: Expose some static helper functions for parsing
        to byte streams and strings. References.
        (WebCore::SVGPathParser::parse):
        (WebCore::SVGPathParser::parseToByteStream):
        (WebCore::SVGPathParser::parseToString):
        (WebCore::SVGPathParser::SVGPathParser):
        (WebCore::SVGPathParser::parseClosePathSegment):
        (WebCore::SVGPathParser::parseMoveToSegment):
        (WebCore::SVGPathParser::parseLineToSegment):
        (WebCore::SVGPathParser::parseLineToHorizontalSegment):
        (WebCore::SVGPathParser::parseLineToVerticalSegment):
        (WebCore::SVGPathParser::parseCurveToCubicSegment):
        (WebCore::SVGPathParser::parseCurveToCubicSmoothSegment):
        (WebCore::SVGPathParser::parseCurveToQuadraticSegment):
        (WebCore::SVGPathParser::parseCurveToQuadraticSmoothSegment):
        (WebCore::SVGPathParser::parseArcToSegment):
        (WebCore::SVGPathParser::parsePathData):
        (WebCore::SVGPathParser::decomposeArcToCubic):
        (WebCore::SVGPathParser::parsePathDataFromSource): Deleted.
        (WebCore::SVGPathParser::cleanup): Deleted.
        * svg/SVGPathParser.h:
        (WebCore::SVGPathParser::setCurrentConsumer): Deleted.
        (WebCore::SVGPathParser::setCurrentSource): Deleted.
        * svg/SVGPathSegListBuilder.cpp:
        (WebCore::SVGPathSegListBuilder::SVGPathSegListBuilder):
        (WebCore::SVGPathSegListBuilder::moveTo):
        (WebCore::SVGPathSegListBuilder::lineTo):
        (WebCore::SVGPathSegListBuilder::lineToHorizontal):
        (WebCore::SVGPathSegListBuilder::lineToVertical):
        (WebCore::SVGPathSegListBuilder::curveToCubic):
        (WebCore::SVGPathSegListBuilder::curveToCubicSmooth):
        (WebCore::SVGPathSegListBuilder::curveToQuadratic):
        (WebCore::SVGPathSegListBuilder::curveToQuadraticSmooth):
        (WebCore::SVGPathSegListBuilder::arcTo):
        (WebCore::SVGPathSegListBuilder::closePath):
        * svg/SVGPathSegListBuilder.h:
        (WebCore::SVGPathSegListBuilder::setCurrentSVGPathElement): Deleted.
        (WebCore::SVGPathSegListBuilder::setCurrentSVGPathSegList): Deleted.
        (WebCore::SVGPathSegListBuilder::setCurrentSVGPathSegRole): Deleted.
        * svg/SVGPathStringBuilder.cpp:
        (WebCore::SVGPathStringBuilder::cleanup): Deleted.
        * svg/SVGPathStringBuilder.h:
        * svg/SVGPathTraversalStateBuilder.cpp:
        (WebCore::SVGPathTraversalStateBuilder::SVGPathTraversalStateBuilder):
        (WebCore::SVGPathTraversalStateBuilder::moveTo):
        (WebCore::SVGPathTraversalStateBuilder::lineTo):
        (WebCore::SVGPathTraversalStateBuilder::curveToCubic):
        (WebCore::SVGPathTraversalStateBuilder::closePath):
        (WebCore::SVGPathTraversalStateBuilder::continueConsuming):
        (WebCore::SVGPathTraversalStateBuilder::totalLength):
        (WebCore::SVGPathTraversalStateBuilder::currentPoint):
        (WebCore::SVGPathTraversalStateBuilder::setDesiredLength): Deleted.
        * svg/SVGPathTraversalStateBuilder.h:
        (WebCore::SVGPathTraversalStateBuilder::pathSegmentIndex):
        (WebCore::SVGPathTraversalStateBuilder::setCurrentTraversalState): Deleted.
        * svg/SVGPathUtilities.cpp: Remove globals accessors, making things on the stack
        instead. Use SVGPathParser helper functions where possible.
        (WebCore::buildPathFromString):
        (WebCore::buildSVGPathByteStreamFromSVGPathSegList):
        (WebCore::appendSVGPathByteStreamFromSVGPathSeg):
        (WebCore::buildPathFromByteStream):
        (WebCore::buildSVGPathSegListFromByteStream):
        (WebCore::buildStringFromByteStream):
        (WebCore::buildStringFromSVGPathSegList):
        (WebCore::buildSVGPathByteStreamFromString):
        (WebCore::buildAnimatedSVGPathByteStream):
        (WebCore::addToSVGPathByteStream):
        (WebCore::getSVGPathSegAtLengthFromSVGPathByteStream):
        (WebCore::getTotalLengthOfSVGPathByteStream):
        (WebCore::getPointAtLengthOfSVGPathByteStream):
        (WebCore::buildStringFromPath):
        (WebCore::globalSVGPathBuilder): Deleted.
        (WebCore::globalSVGPathSegListBuilder): Deleted.
        (WebCore::globalSVGPathByteStreamBuilder): Deleted.
        (WebCore::globalSVGPathStringBuilder): Deleted.
        (WebCore::globalSVGPathTraversalStateBuilder): Deleted.
        (WebCore::globalSVGPathParser): Deleted.
        (WebCore::globalSVGPathBlender): Deleted.
        * svg/SVGPathUtilities.h:
        * svg/SVGToOTFFontConversion.cpp: CFFBuilder no longer inherits from SVGPathBuilder.
        It did nothing with the Path, re-implemented all the functions, and only made use of
        the m_current member var, so just make it inherit from SVGPathConsumer, and have
        its own m_current.
        (WebCore::SVGToOTFFontConverter::transcodeGlyphPaths):

2015-10-10  Antti Koivisto  <antti@apple.com>

        Remove InsertionPoint and ContentDistributor
        https://bugs.webkit.org/show_bug.cgi?id=150004

        Rubber-stamped by Sam Weinig.

        Now that <details> is on top of the modern Shadow DOM remove the last vestiges of the V0 Shadow DOM API.

        * CMakeLists.txt:
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.xcodeproj/project.pbxproj:
        * css/SelectorChecker.cpp:
        * css/StyleResolver.cpp:
        * dom/ContainerNode.cpp:
        * dom/Element.cpp:
        (WebCore::shouldUseNodeRenderingTraversalSlowPath):
        (WebCore::Element::resetNeedsNodeRenderingTraversalSlowPath):
        * dom/Node.cpp:
        (WebCore::Node::parentOrShadowHostElement):
        (WebCore::Node::insertedInto):
        (WebCore::Node::insertionParentForBinding): Deleted.
        * dom/Node.h:
        (WebCore::Node::isCharacterDataNode):
        (WebCore::Node::isFrameOwnerElement):
        (WebCore::Node::isPluginElement):
        (WebCore::Node::isImageControlsRootElement):
        (WebCore::Node::isImageControlsButtonElement):
        (WebCore::Node::isDocumentFragment):
        (WebCore::Node::isShadowRoot):
        (WebCore::Node::isInsertionPointNode): Deleted.
        (WebCore::Node::isInsertionPoint): Deleted.
        * dom/NodeRenderingTraversal.cpp:
        (WebCore::NodeRenderingTraversal::traverseParent):
        (WebCore::NodeRenderingTraversal::traverseFirstChild):
        (WebCore::NodeRenderingTraversal::traverseLastChild):
        (WebCore::NodeRenderingTraversal::traverseNextSibling):
        (WebCore::NodeRenderingTraversal::traversePreviousSibling):
        (WebCore::NodeRenderingTraversal::parentSlow):
        (WebCore::NodeRenderingTraversal::nextInScope):
        (WebCore::NodeRenderingTraversal::previousInScope):
        (WebCore::NodeRenderingTraversal::parentInScope):
        (WebCore::NodeRenderingTraversal::lastChildInScope):
        (WebCore::NodeRenderingTraversal::nodeCanBeDistributed): Deleted.
        (WebCore::NodeRenderingTraversal::findFirstSiblingEnteringInsertionPoints): Deleted.
        (WebCore::NodeRenderingTraversal::findFirstEnteringInsertionPoints): Deleted.
        (WebCore::NodeRenderingTraversal::findFirstFromDistributedNode): Deleted.
        (WebCore::NodeRenderingTraversal::findLastSiblingEnteringInsertionPoints): Deleted.
        (WebCore::NodeRenderingTraversal::findLastEnteringInsertionPoints): Deleted.
        (WebCore::NodeRenderingTraversal::findLastFromDistributedNode): Deleted.
        * dom/ShadowRoot.h:
        (WebCore::ShadowRoot::distributor): Deleted.
        * html/HTMLInputElement.cpp:
        * html/HTMLSlotElement.cpp:
        * html/HTMLSlotElement.h:
        * html/shadow/ContentDistributor.cpp: Removed.
        * html/shadow/ContentDistributor.h: Removed.
        * html/shadow/InsertionPoint.cpp: Removed.
        * html/shadow/InsertionPoint.h: Removed.
        * page/FocusController.cpp:
        (WebCore::FocusController::previousFocusableElement):
        * testing/Internals.cpp:

2015-10-10  Simon Fraser  <simon.fraser@apple.com>

        Use references and more const in SVGPathUtilities
        https://bugs.webkit.org/show_bug.cgi?id=150007

        Reviewed by Zalan Bujtas.
        
        SVGPathUtilities had lots of pointers whose non-nullness was asserted,
        little const, and was very trigger-happy with stack allocations. Clean
        that all up.

        * svg/SVGAnimatedPath.cpp:
        (WebCore::SVGAnimatedPathAnimator::constructFromString):
        (WebCore::SVGAnimatedPathAnimator::resetAnimValToBaseVal):
        (WebCore::SVGAnimatedPathAnimator::addAnimatedTypes):
        (WebCore::SVGAnimatedPathAnimator::calculateAnimatedValue):
        * svg/SVGPathByteStream.h:
        (WebCore::SVGPathByteStream::begin):
        (WebCore::SVGPathByteStream::end):
        (WebCore::SVGPathByteStream::append):
        * svg/SVGPathByteStreamSource.cpp:
        (WebCore::SVGPathByteStreamSource::SVGPathByteStreamSource):
        * svg/SVGPathByteStreamSource.h:
        * svg/SVGPathElement.cpp:
        (WebCore::SVGPathElement::getTotalLength):
        (WebCore::SVGPathElement::getPointAtLength):
        (WebCore::SVGPathElement::getPathSegAtLength):
        (WebCore::SVGPathElement::parseAttribute):
        (WebCore::SVGPathElement::svgAttributeChanged):
        (WebCore::SVGPathElement::pathByteStream):
        (WebCore::SVGPathElement::lookupOrCreateDWrapper):
        (WebCore::SVGPathElement::pathSegListChanged):
        (WebCore::SVGPathElement::SVGPathElement): Deleted.
        * svg/SVGPathElement.h:
        * svg/SVGPathUtilities.cpp:
        (WebCore::globalSVGPathBuilder):
        (WebCore::globalSVGPathSegListBuilder):
        (WebCore::globalSVGPathByteStreamBuilder):
        (WebCore::globalSVGPathStringBuilder):
        (WebCore::globalSVGPathTraversalStateBuilder):
        (WebCore::globalSVGPathParser):
        (WebCore::globalSVGPathBlender):
        (WebCore::buildPathFromString):
        (WebCore::buildSVGPathByteStreamFromSVGPathSegList):
        (WebCore::appendSVGPathByteStreamFromSVGPathSeg):
        (WebCore::buildPathFromByteStream):
        (WebCore::buildSVGPathSegListFromByteStream):
        (WebCore::buildStringFromByteStream):
        (WebCore::buildStringFromSVGPathSegList):
        (WebCore::buildSVGPathByteStreamFromString):
        (WebCore::buildAnimatedSVGPathByteStream):
        (WebCore::addToSVGPathByteStream):
        (WebCore::getSVGPathSegAtLengthFromSVGPathByteStream):
        (WebCore::getTotalLengthOfSVGPathByteStream):
        (WebCore::getPointAtLengthOfSVGPathByteStream):
        (WebCore::buildStringFromPath):
        * svg/SVGPathUtilities.h:
        * svg/properties/SVGAnimatedPathSegListPropertyTearOff.h:
        (WebCore::SVGAnimatedPathSegListPropertyTearOff::animValDidChange):

2015-10-10  Andreas Kling  <akling@apple.com>

        Reduce pointless malloc traffic in ElementRuleCollector.
        <https://webkit.org/b/150003>

        Reviewed by Antti Koivisto.

        Don't use a unique_ptr for the m_matchedRules vector in ElementRuleCollector.
        This is one of our heaviest sources of transient allocations, with ~88000
        malloc/free pairs on loading theverge.com.

        * css/ElementRuleCollector.cpp:
        (WebCore::ElementRuleCollector::addMatchedRule):
        (WebCore::ElementRuleCollector::clearMatchedRules):
        (WebCore::ElementRuleCollector::sortAndTransferMatchedRules):
        (WebCore::ElementRuleCollector::sortMatchedRules):
        (WebCore::ElementRuleCollector::hasAnyMatchingRules):
        * css/ElementRuleCollector.h:
        (WebCore::ElementRuleCollector::hasMatchedRules):

2015-10-10  Dan Bernstein  <mitz@apple.com>

        [iOS] Remove unnecessary iOS version checks
        https://bugs.webkit.org/show_bug.cgi?id=150002

        Reviewed by Alexey Proskuryakov.

        * loader/cache/CachedFont.cpp:
        (WebCore::CachedFont::ensureCustomFontData):
        * loader/cocoa/DiskCacheMonitorCocoa.h:
        (WebCore::DiskCacheMonitor::monitorFileBackingStoreCreation):
        * page/mac/SettingsMac.mm:
        (WebCore::sansSerifTraditionalHanFontFamily):
        (WebCore::sansSerifSimplifiedHanFontFamily):
        * platform/graphics/cocoa/FontCacheCoreText.cpp:
        (WebCore::appendOpenTypeFeature):
        * platform/graphics/ios/FontCacheIOS.mm:
        (WebCore::getSystemFontFallbackForCharacters):
        (WebCore::platformLookupFallbackFont):
        * platform/ios/PlatformSpeechSynthesizerIOS.mm:
        (WebCore::PlatformSpeechSynthesizer::initializeVoiceList):
        * platform/ios/WebCoreSystemInterfaceIOS.h:
        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
        * platform/ios/wak/WAKWindow.mm:
        (+[WAKWindow hasLandscapeOrientation]):
        (-[WAKWindow hostLayer]):
        * platform/network/cf/CookieJarCFNet.cpp:
        (WebCore::copyCookiesForURLWithFirstPartyURL):
        (WebCore::createCookies):
        * platform/network/mac/CertificateInfoMac.mm:
        (WebCore::CertificateInfo::containsNonRootSHA1SignedCertificate):
        * platform/spi/cf/CFNetworkSPI.h:
        * platform/spi/cocoa/AVKitSPI.h:
        * platform/spi/cocoa/CoreTextSPI.h:
        * platform/spi/cocoa/NEFilterSourceSPI.h:
        * platform/spi/cocoa/QuartzCoreSPI.h:
        * platform/spi/cocoa/SecuritySPI.h:
        * platform/spi/ios/LaunchServicesSPI.h:
        * platform/spi/mac/AVFoundationSPI.h:
        * platform/text/TextBreakIterator.cpp:
        * platform/text/TextFlags.h:
        * platform/text/ios/LocalizedDateCache.mm:
        (WebCore::LocalizedDateCache::calculateMaximumWidth):
        * platform/text/mac/LocaleMac.mm:
        (WebCore::LocaleMac::LocaleMac):
        * rendering/RenderThemeIOS.mm:
        (WebCore::RenderThemeIOS::cachedSystemFontDescription):
        (WebCore::RenderThemeIOS::updateCachedSystemFontDescription):
        * svg/SVGToOTFFontConversion.cpp:
        (WebCore::SVGToOTFFontConverter::appendKERNTable):
        (WebCore::SVGToOTFFontConverter::SVGToOTFFontConverter):

2015-10-10  Antti Koivisto  <antti@apple.com>

        Rewrite HTMLDetailsElement using HTMLSlotElement
        https://bugs.webkit.org/show_bug.cgi?id=149698

        Reviewed by Andreas Kling.

        Use the modern Shadow DOM to implement <details> element. After this the legacy InsertionPoint and
        related code can be removed.

        Based on a patch by Ryosuke.

        * dom/Element.cpp:
        (WebCore::Element::childrenChanged):
        * dom/EventDispatcher.cpp:
        (WebCore::EventPath::EventPath):
        * dom/ShadowRoot.cpp:
        (WebCore::ShadowRoot::ShadowRoot):
        (WebCore::ShadowRoot::~ShadowRoot):
        (WebCore::ShadowRoot::removeAllEventListeners):
        (WebCore::ShadowRoot::findAssignedSlot):
        (WebCore::ShadowRoot::addSlotElementByName):
        (WebCore::ShadowRoot::removeSlotElementByName):
        (WebCore::ShadowRoot::invalidateSlotAssignments):
        (WebCore::ShadowRoot::invalidateDefaultSlotAssignments):
        (WebCore::ShadowRoot::assignedNodesForSlot):
        * dom/ShadowRoot.h:
        (WebCore::ShadowRoot::create):
        (WebCore::ShadowRoot::distributor):
        (WebCore::ShadowRoot::isOrphan):
        * dom/SlotAssignment.cpp:
        (WebCore::slotNameFromAttributeValue):

            Rename for clarity.

        (WebCore::slotNameFromSlotAttribute):

            SlotAssignment can now be specialized by providing function that maps from node to slot name.
            This is the default function that gets the name from the slot attribute.

        (WebCore::SlotAssignment::SlotAssignment):
        (WebCore::SlotAssignment::findAssignedSlot):

            Use the name mapping function.
            Ensure that the slots are assigned.

        (WebCore::SlotAssignment::addSlotElementByName):
        (WebCore::SlotAssignment::removeSlotElementByName):
        (WebCore::SlotAssignment::assignedNodesForSlot):
        (WebCore::SlotAssignment::invalidate):
        (WebCore::SlotAssignment::invalidateDefaultSlot):
        (WebCore::SlotAssignment::resolveAllSlotElements):
        (WebCore::SlotAssignment::assignSlots):

            Use the name mapping function.

        (WebCore::SlotAssignment::assignToSlot):

            Factor into function.

        (WebCore::treatNullAsEmpty): Deleted.
        * dom/SlotAssignment.h:
        (WebCore::SlotAssignment::~SlotAssignment):
        (WebCore::SlotAssignment::defaultSlotName):

            Add static getter for emptyAtom for clarity.

        (WebCore::SlotAssignment::SlotAssignment): Deleted.
        * html/HTMLDetailsElement.cpp:
        (WebCore::summarySlotName):
        (WebCore::slotNameFunction):

            Slot name function for <details>. It assigns the first <summary> child to the summary slot and others
            to the default content slot if the element is open.

        (WebCore::HTMLDetailsElement::create):
        (WebCore::HTMLDetailsElement::didAddUserAgentShadowRoot):
        (WebCore::HTMLDetailsElement::isActiveSummary):
        (WebCore::HTMLDetailsElement::parseAttribute):
        (WebCore::HTMLDetailsElement::toggleOpen):
        (WebCore::summaryQuerySelector): Deleted.
        (WebCore::DetailsContentElement::create): Deleted.
        (WebCore::DetailsSummaryElement::create): Deleted.
        (WebCore::HTMLDetailsElement::findMainSummary): Deleted.
        (WebCore::HTMLDetailsElement::childShouldCreateRenderer): Deleted.
        * html/HTMLDetailsElement.h:
        * html/HTMLSummaryElement.cpp:
        (WebCore::HTMLSummaryElement::create):
        (WebCore::HTMLSummaryElement::createElementRenderer):
        (WebCore::HTMLSummaryElement::didAddUserAgentShadowRoot):
        (WebCore::HTMLSummaryElement::detailsElement):
        (WebCore::HTMLSummaryElement::isActiveSummary):
        (WebCore::isClickableControl):
        (WebCore::HTMLSummaryElement::supportsFocus):
        (WebCore::HTMLSummaryElement::defaultEventHandler):
        (WebCore::HTMLSummaryElement::willRespondToMouseClickEvents):
        (WebCore::SummaryContentElement::create): Deleted.
        (WebCore::HTMLSummaryElement::childShouldCreateRenderer): Deleted.
        (WebCore::HTMLSummaryElement::isMainSummary): Deleted.
        * html/HTMLSummaryElement.h:
        * html/shadow/DetailsMarkerControl.cpp:
        (WebCore::DetailsMarkerControl::rendererIsNeeded):
        * style/RenderTreePosition.cpp:
        (WebCore::RenderTreePosition::computeNextSibling):

            Skip the verification assert for shadow host children. Getting this right requires
            better shadow-aware traversal code.

        * style/StyleResolveTree.cpp:
        (WebCore::Style::invalidateWhitespaceOnlyTextSiblingsAfterAttachIfNeeded):
        (WebCore::Style::attachChildren):
        (WebCore::Style::attachShadowRoot):
        (WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded):
        (WebCore::Style::attachSlotAssignees):
        (WebCore::Style::attachRenderTree):
        (WebCore::Style::detachChildren):
        (WebCore::Style::detachShadowRoot):
        (WebCore::Style::detachSlotAssignees):
        (WebCore::Style::detachRenderTree):
        (WebCore::Style::resolveChildren):
        (WebCore::Style::resolveSlotAssignees):
        (WebCore::Style::resolveTree):
        (WebCore::Style::attachDistributedChildren): Deleted.
        (WebCore::Style::detachDistributedChildren): Deleted.

            Remove InsertionPoint related code paths.

2015-10-10  Andreas Kling  <akling@apple.com>

        SerializedScriptValue should use a compact encoding for 8-bit strings.
        <https://webkit.org/b/149934>

        Reviewed by Antti Koivisto.

        We were encoding known 8-bit strings in a 16-bit format when serializing script values.

        Extend the format to support 8-bit strings. The 8-bittiness is encoded in the highest bit
        of the string length. This is possible while supporting all older formats due to string
        lengths >= 0x7FFFFFFF being disallowed.

        This patch knocks ~1 MB off of theverge.com, where some ad or tracker or whatever likes to
        do a ton of postMessage() business.

        * bindings/js/SerializedScriptValue.cpp:
        (WebCore::CurrentVersion): Bump the serialization format version. Also updated the grammar
        comment to describe the new format. Artistic license applied in description of bitfield.

        (WebCore::writeLittleEndianUInt16): Deleted.

        (WebCore::CloneSerializer::serialize):
        (WebCore::CloneSerializer::write):
        (WebCore::CloneDeserializer::deserializeString):
        (WebCore::CloneDeserializer::readString):
        (WebCore::CloneDeserializer::readStringData): Support 8-bit strings. I kept the string
        length limit at UINT_MAX/sizeof(UChar) since the highest bit of the length is no longer
        available. Besides, it seems flimsy to support longer strings if they happen to have all
        8-bit characters.

2015-10-10  Dan Bernstein  <mitz@apple.com>

        [iOS] Remove project support for iOS 8
        https://bugs.webkit.org/show_bug.cgi?id=149993

        Reviewed by Alexey Proskuryakov.

        * Configurations/WebCore.xcconfig:
        * Configurations/WebCoreTestSupport.xcconfig:

2015-10-09  Zalan Bujtas  <zalan@apple.com>

        Check if start and end positions are still valid after updating them through VisibleSelection.
        https://bugs.webkit.org/show_bug.cgi?id=149982

        Reviewed by Ryosuke Niwa.

        This patch is required to be able to clean up anonymous tables structure.
        In certain edge cases, start/end positions could become nullptr after various text splitting
        operations. 

        Covered by editing/execCommand/crash-137961.html

        * editing/ApplyStyleCommand.cpp:
        (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
        (WebCore::ApplyStyleCommand::applyInlineStyle):

2015-10-09  Simon Fraser  <simon.fraser@apple.com>

        Rename RenderObject::isRoot() to isDocumentElementRenderer()
        https://bugs.webkit.org/show_bug.cgi?id=149976

        Reviewed by Zalan Bujtas.

        RenderObject::isRoot() was confusingly named, because it returns true for
        the document element's renderer, not for the actual root (the RenderView).
        In this way it mismatched RenderLayer::isRootLayer(), which returned true
        for the RenderView's layer.
        
        Rename it to the more accurate isDocumentElementRenderer().

        * dom/Node.cpp:
        (WebCore::Node::renderRect):
        * page/ios/FrameIOS.mm:
        (WebCore::Frame::renderRectForPoint):
        * rendering/RenderBlock.cpp:
        (WebCore::RenderBlock::paint):
        (WebCore::RenderBlock::isSelectionRoot):
        (WebCore::RenderBlock::selectionGaps):
        * rendering/RenderBlockFlow.cpp:
        (WebCore::RenderBlockFlow::rebuildFloatingObjectSetFromIntrudingFloats):
        (WebCore::RenderBlockFlow::layoutBlock):
        (WebCore::RenderBlockFlow::requiresColumns):
        * rendering/RenderBox.cpp:
        (WebCore::RenderBox::styleWillChange):
        (WebCore::RenderBox::styleDidChange):
        (WebCore::RenderBox::updateFromStyle):
        (WebCore::RenderBox::paintBackground):
        (WebCore::RenderBox::computeBackgroundIsKnownToBeObscured):
        (WebCore::RenderBox::repaintLayerRectsForImage):
        (WebCore::RenderBox::computeLogicalHeight):
        (WebCore::RenderBox::computePercentageLogicalHeight):
        (WebCore::RenderBox::createsNewFormattingContext):
        (WebCore::RenderBox::percentageLogicalHeightIsResolvableFromBlock):
        * rendering/RenderBox.h:
        (WebCore::RenderBox::stretchesToViewport):
        * rendering/RenderBoxModelObject.cpp:
        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
        (WebCore::RenderBoxModelObject::fixedBackgroundPaintsInLocalCoordinates):
        (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
        * rendering/RenderBoxModelObject.h:
        * rendering/RenderDeprecatedFlexibleBox.cpp:
        (WebCore::RenderDeprecatedFlexibleBox::layoutBlock):
        * rendering/RenderElement.cpp:
        (WebCore::RenderElement::styleWillChange):
        (WebCore::RenderElement::rendererForRootBackground):
        (WebCore::shouldRepaintForImageAnimation):
        * rendering/RenderElement.h:
        * rendering/RenderFlexibleBox.cpp:
        (WebCore::RenderFlexibleBox::layoutBlock):
        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::layoutBlock):
        * rendering/RenderLayer.cpp:
        (WebCore::shouldSuppressPaintingLayer):
        (WebCore::paintForFixedRootBackground):
        (WebCore::RenderLayer::paintLayerContents):
        (WebCore::RenderLayer::calculateClipRects):
        * rendering/RenderLayer.h:
        * rendering/RenderLayerBacking.cpp:
        (WebCore::RenderLayerBacking::rendererBackgroundColor):
        (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
        * rendering/RenderLayerModelObject.cpp:
        (WebCore::RenderLayerModelObject::styleDidChange):
        * rendering/RenderObject.cpp:
        (WebCore::RenderObject::repaintSlowRepaintObject):
        (WebCore::RenderObject::offsetParent):
        * rendering/RenderObject.h:
        (WebCore::RenderObject::isDocumentElementRenderer):
        (WebCore::RenderObject::isRoot): Deleted.
        * rendering/RenderTable.cpp:
        (WebCore::RenderTable::paint):
        * rendering/svg/RenderSVGRoot.cpp:
        (WebCore::RenderSVGRoot::layout):
        (WebCore::RenderSVGRoot::shouldApplyViewportClip):
        * rendering/svg/SVGRenderSupport.cpp:
        (WebCore::SVGRenderSupport::isOverflowHidden):

2015-10-09  Nan Wang  <n_wang@apple.com>

        AX: ARIA 1.1 implement aria-colcount, aria-colindex, aria-colspan, aria-rowcount, aria-rowindex and aria-rowspan
        https://bugs.webkit.org/show_bug.cgi?id=148967

        Reviewed by Chris Fleizach.

        Added support for ARIA 1.1 table/grid related attributes. Created new attributes for mac, so
        VoiceOver can pick up the information and speak accordingly.

        Test: accessibility/mac/aria-table-attributes.html

        * accessibility/AccessibilityARIAGridCell.cpp:
        (WebCore::AccessibilityARIAGridCell::AccessibilityARIAGridCell):
        (WebCore::AccessibilityARIAGridCell::rowIndexRange):
        (WebCore::AccessibilityARIAGridCell::columnIndexRange):
        (WebCore::AccessibilityARIAGridCell::parentRowGroup):
        * accessibility/AccessibilityARIAGridCell.h:
        * accessibility/AccessibilityObject.cpp:
        (WebCore::initializeRoleMap):
        * accessibility/AccessibilityObject.h:
        * accessibility/AccessibilityTable.cpp:
        (WebCore::AccessibilityTable::title):
        (WebCore::AccessibilityTable::ariaColumnCount):
        (WebCore::AccessibilityTable::ariaRowCount):
        * accessibility/AccessibilityTable.h:
        * accessibility/AccessibilityTableCell.cpp:
        (WebCore::AccessibilityTableCell::AccessibilityTableCell):
        (WebCore::AccessibilityTableCell::titleUIElement):
        (WebCore::AccessibilityTableCell::ariaColumnIndex):
        (WebCore::AccessibilityTableCell::ariaRowIndex):
        (WebCore::AccessibilityTableCell::ariaColumnSpan):
        (WebCore::AccessibilityTableCell::ariaRowSpan):
        * accessibility/AccessibilityTableCell.h:
        (WebCore::AccessibilityTableCell::setARIAColIndexFromRow):
        * accessibility/AccessibilityTableRow.cpp:
        (WebCore::AccessibilityTableRow::headerObject):
        (WebCore::AccessibilityTableRow::addChildren):
        (WebCore::AccessibilityTableRow::ariaColumnIndex):
        (WebCore::AccessibilityTableRow::ariaRowIndex):
        * accessibility/AccessibilityTableRow.h:
        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
        (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
        (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
        * html/HTMLAttributeNames.in:

2015-10-09  Anders Carlsson  <andersca@apple.com>

        Remove hack that allowed plug-ins to always take over certain image formats
        https://bugs.webkit.org/show_bug.cgi?id=149972

        Reviewed by Tim Horton.

        This hack was added 8 years ago to allow a certain plug-in to show multi-page TIFF images on uspto.gov. 
        We now support said TIFFs natively, and the plug-in has been discontinued so it's safe to get rid of this.

        * loader/SubframeLoader.cpp:
        (WebCore::SubframeLoader::shouldUsePlugin): Deleted.

2015-10-09  Simon Fraser  <simon.fraser@apple.com>

        Garbage texture data with composited table row
        https://bugs.webkit.org/show_bug.cgi?id=148984

        Reviewed by Zalan Bujtas.
        
        Don't pretend to know if the layer for a table header, section or cell is
        opaque, since table painting is special.

        Test: compositing/contents-opaque/table-parts.html

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

2015-10-09  Simon Fraser  <simon.fraser@apple.com>

        Garbage pixels on enphaseenergy.com site
        https://bugs.webkit.org/show_bug.cgi?id=149915
        rdar://problem/22976184

        Reviewed by Darin Adler.
        
        When the <html> gets a composited RenderLayer, and we ask whether its background
        is opaque, return false, since the document element's background propagates
        to the root, and is painted by the RenderView.
        
        Also improve the compositing logging to indicate when fore- and background layers
        are present.

        Test: compositing/contents-opaque/negative-z-before-html.html

        * rendering/RenderLayerBacking.cpp:
        (WebCore::RenderLayerBacking::updateGeometry):
        * rendering/RenderLayerCompositor.cpp:
        (WebCore::RenderLayerCompositor::logLayerInfo):

2015-10-09  Antoine Quint  <graouts@apple.com>

        Dynamic background color changes do not update until a layout is forced
        https://bugs.webkit.org/show_bug.cgi?id=131623

        Compute correct repaint rect for decorated RenderSVGRoots.

        The current implementation of clippedOverflowRectForRepaint() uses the
        generic repaint-rect calculations in SVGRenderSupport. Those in turn make
        use of repaintRectInLocalCoordinates(), which for RenderSVGRoot is the
        union of the painted children (w/ some expansion). If there're no children,
        or they do not fill the entire content box, then a repaint would not
        repaint the correct parts.
        Fix by calculating the union of the border-box and the SVG content
        when the SVG root is decorated (has background/border/etc.)

        Adapted from a Chromium patch by fs@opera.com
        https://src.chromium.org/viewvc/blink?revision=170890&view=revision

        Reviewed by Darin Adler.

        Tests: svg/repaint/add-background-property-on-root.html
               svg/repaint/add-border-property-on-root.html
               svg/repaint/add-outline-property-on-root.html
               svg/repaint/change-background-color.html
               svg/repaint/remove-background-property-on-root.html
               svg/repaint/remove-border-property-on-root.html
               svg/repaint/remove-outline-property-on-root.html

        * rendering/svg/RenderSVGRoot.cpp:
        (WebCore::RenderSVGRoot::layout):
        (WebCore::RenderSVGRoot::styleDidChange):
        (WebCore::RenderSVGRoot::clippedOverflowRectForRepaint):

2015-10-09  Simon Fraser  <simon.fraser@apple.com>

        [iOS WK2] Fix assertion in ViewportConfiguration::setDefaultConfiguration seen in testing
        https://bugs.webkit.org/show_bug.cgi?id=149959

        Reviewed by Tim Horton.

        When loading tests which set a flexible viewport, ViewportConfiguration::setDefaultConfiguration()
        is called first with testingParameters() and then with webpageParameters(). This
        would trigger the assertion that m_defaultConfiguration.initialScaleIsSet but
        the new initial scale is zero.
        
        The assertion seems wrong anyway; it's consulting m_defaultConfiguration.initialScaleIsSet
        but defaultConfiguration.initialScale, so fix it to test defaultConfiguration.initialScaleIsSet.

        * page/ViewportConfiguration.cpp:
        (WebCore::ViewportConfiguration::setDefaultConfiguration):

2015-10-09  Csaba Osztrogonác  <ossy@webkit.org>

        Fix the !ENABLE(STREAM_API) build after r190794
        https://bugs.webkit.org/show_bug.cgi?id=149955

        Reviewed by Darin Adler.

        * bindings/js/WebCoreJSBuiltinInternals.h:
        (WebCore::JSBuiltinInternalFunctions::visit):
        (WebCore::JSBuiltinInternalFunctions::init):

2015-10-09  Csaba Osztrogonác  <ossy@webkit.org>

        Fix the binding generator after r190785
        https://bugs.webkit.org/show_bug.cgi?id=149956

        Reviewed by Darin Adler.

        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateConstructorHelperMethods):
        * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
        (WebCore::JSTestEventConstructorConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        (WebCore::JSTestInterfaceConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
        (WebCore::JSTestJSBuiltinConstructorConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
        (WebCore::JSTestNamedConstructorNamedConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestNode.cpp:
        (WebCore::JSTestNodeConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::JSTestObjConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
        (WebCore::JSTestOverloadedConstructorsConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
        (WebCore::JSTestTypedefsConstructor::getConstructData):

2015-10-08  Wenson Hsieh  <wenson_hsieh@apple.com>

        Backgrounds bleed out of natively rendered text fields
        https://bugs.webkit.org/show_bug.cgi?id=149843
        <rdar://problem/22896977>

        Reviewed by Darin Adler.

        When natively rendering a text field with a background on Mac, the background bleeds out
        of the text field's border when the graphics context is scaled (as a result of a retina
        display or zoom/scale effects). This is because when we render the text field in bezeled
        style within a certain frame, AppKit adds 1 device pixel insets on all sides of the frame,
        which renders a text field that is slightly smaller than the frame. To adjust for this, we
        inflate the paint rect.

        Test: fast/forms/hidpi-textfield-background-bleeding.html

        * rendering/RenderThemeMac.mm:
        (WebCore::RenderThemeMac::paintTextField):

2015-10-09  Xabier Rodriguez Calvar  <calvaris@igalia.com> and Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Refactor WebCore JS builtins to prepare for automatic generation
        https://bugs.webkit.org/show_bug.cgi?id=149751

        Reviewed by Darin Adler.

        Adding annotations to JS files to know whether they should be under a compilation flag and
        whether they are JS internals or JS tied to WebIDL.
        If a file is said as JS internals, all function names should be exported automatically.
        Added WebCoreJSBuiltins.h to simplify handling of builtins in JSVMClientData.
        Added WebCoreJSInternals.h to simplify handling of builtin private function in JSDOMWindowBase.
        Renamed WebCoreJSClientData to JSVMClientData.

        Covered by existing tests.

        * CMakeLists.txt:
        * Modules/streams/ByteLengthQueuingStrategy.js:
        * Modules/streams/CountQueuingStrategy.js:
        * Modules/streams/ReadableStream.js:
        * Modules/streams/ReadableStreamController.js:
        * Modules/streams/ReadableStreamInternals.js:
        * Modules/streams/ReadableStreamReader.js:
        * WebCore.order:
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/DOMWrapperWorld.cpp:
        (WebCore::DOMWrapperWorld::DOMWrapperWorld):
        (WebCore::DOMWrapperWorld::~DOMWrapperWorld):
        (WebCore::normalWorld):
        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::JSDOMWindowBase::JSDOMWindowBase):
        (WebCore::JSDOMWindowBase::finishCreation):
        (WebCore::JSDOMWindowBase::visitChildren):
        (WebCore::JSDOMWindowBase::fireFrameClearedWatchpointsForWindow):
        (WebCore::JSDOMWindowBase::destroy): Deleted.
        * bindings/js/JSDOMWindowBase.h:
        * bindings/js/ScriptController.cpp:
        (WebCore::ScriptController::getAllWorlds):
        * bindings/js/SerializedScriptValue.cpp:
        (WebCore::SerializedScriptValue::transferArrayBuffers):
        * bindings/js/WebCoreJSBuiltinInternals.h: Added.
        (WebCore::JSBuiltinInternalFunctions::JSBuiltinInternalFunctions):
        (WebCore::JSBuiltinInternalFunctions::readableStreamInternals):
        (WebCore::JSBuiltinInternalFunctions::visit):
        (WebCore::JSBuiltinInternalFunctions::init):
        * bindings/js/WebCoreJSBuiltins.cpp:
        * bindings/js/WebCoreJSBuiltins.h: Added.
        (WebCore::JSBuiltinFunctions::JSBuiltinFunctions):
        (WebCore::JSBuiltinFunctions::byteLengthQueuingStrategyBuiltins):
        (WebCore::JSBuiltinFunctions::countQueuingStrategyBuiltins):
        (WebCore::JSBuiltinFunctions::readableStreamBuiltins):
        (WebCore::JSBuiltinFunctions::readableStreamControllerBuiltins):
        (WebCore::JSBuiltinFunctions::readableStreamInternalsBuiltins):
        (WebCore::JSBuiltinFunctions::readableStreamReaderBuiltins):
        * bindings/js/WebCoreJSClientData.h:
        (WebCore::JSVMClientData::JSVMClientData):
        (WebCore::JSVMClientData::~JSVMClientData):
        (WebCore::JSVMClientData::builtinFunctions):
        (WebCore::initNormalWorldClientData):
        (WebCore::JSVMClientData::normalWorld): Deleted.
        (WebCore::JSVMClientData::getAllWorlds): Deleted.

2015-10-09  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Rationalize JSXXConstructor class definition
        https://bugs.webkit.org/show_bug.cgi?id=149923

        Reviewed by Darin Adler.

        Declaration of JSXXConstructor::construct and JSXXConstructor::getConstructData
        as long as JSXX is constructable from JavaScript.

        Previously, JSXXConstructor::construct was not generated in case of CustomConstructor.
        It is now generated and directly calls the custom constructor function.

        getConstructData was declared conditionally with #if in case of ConstructorConditional.
        The #if are now within getConstructData body.

        Covered by binding tests.

        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateConstructorDeclaration):
        (GenerateOverloadedConstructorDefinition):
        (GenerateConstructorDefinition):
        (GenerateConstructorHelperMethods):
        (GenerateConstructorDefinitions):.
        * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::construct):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::getConstructData):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::finishCreation):.
        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
        (WebCore::JSTestEventConstructorConstructor::construct):
        (WebCore::JSTestEventConstructorConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        (WebCore::JSTestInterfaceConstructor::construct):
        (WebCore::JSTestInterfaceConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
        (WebCore::JSTestJSBuiltinConstructorConstructor::construct):
        (WebCore::JSTestJSBuiltinConstructorConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
        (WebCore::JSTestNamedConstructorNamedConstructor::construct):
        (WebCore::JSTestNamedConstructorNamedConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestNode.cpp:
        (WebCore::JSTestNodeConstructor::construct):
        (WebCore::JSTestNodeConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::JSTestObjConstructor::construct):
        (WebCore::JSTestObjConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
        (WebCore::constructJSTestOverloadedConstructors1):
        (WebCore::constructJSTestOverloadedConstructors2):
        (WebCore::constructJSTestOverloadedConstructors3):
        (WebCore::constructJSTestOverloadedConstructors4):
        (WebCore::constructJSTestOverloadedConstructors5):
        (WebCore::JSTestOverloadedConstructorsConstructor::construct):
        (WebCore::JSTestOverloadedConstructorsConstructor::getConstructData):
        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
        (WebCore::JSTestTypedefsConstructor::construct):
        (WebCore::JSTestTypedefsConstructor::getConstructData):

2015-10-07  Sergio Villar Senin  <svillar@igalia.com>

        [css-grid] Include freeSpace in GridSizingData struct
        https://bugs.webkit.org/show_bug.cgi?id=149876

        Reviewed by Darin Adler.

        During the layout process we keep the free space for rows and
        columns in two variables that are passed to a few methods
        along with the GridSizingData struct. Those two variables
        should clearly be part of GridSizingData as they're temporary
        values used just for the sake of the layout.

        No new tests required as this is just a refactoring.

        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::GridSizingData::GridSizingData):
        (WebCore::RenderGrid::GridSizingData::freeSpaceForDirection):
        (WebCore::RenderGrid::computeIntrinsicLogicalWidths):
        (WebCore::RenderGrid::computeUsedBreadthOfGridTracks):
        (WebCore::RenderGrid::applyStretchAlignmentToTracksIfNeeded):
        (WebCore::RenderGrid::layoutGridItems):
        (WebCore::RenderGrid::populateGridPositions):
        (WebCore::contentDistributionOffset):
        (WebCore::RenderGrid::computeContentPositionAndDistributionOffset):
        * rendering/RenderGrid.h:

2015-10-08  Sergio Villar Senin  <svillar@igalia.com>

        [css-grid] Remove unneeded calls to compute(Content)LogicalWidth(Height)
        https://bugs.webkit.org/show_bug.cgi?id=149926

        Reviewed by Darin Adler.

        In order to resolve a Length to a LayoutUnit we need to
        provide a maximum value so that i.e. percentages are correctly
        computed. That maximum value was computeLogicalWidth() for
        columns and computeContentLogicalHeight() for rows. We were
        calling it for every single track with a definite size instead
        of computing it once and reusing it multiple times.

        This brings some nice performance improvements:
        - 2.9%  in /Layout/fixed-grid-lots-of-data
        - 2.95% in /Layout/fixed-grid-lots-of-stretched-data

        No new tests required as there is no change in functionality.

        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::computeUsedBreadthOfGridTracks):
        (WebCore::RenderGrid::computeUsedBreadthOfMinLength):
        (WebCore::RenderGrid::computeUsedBreadthOfMaxLength):
        (WebCore::RenderGrid::tracksAreWiderThanMinTrackBreadth):
        * rendering/RenderGrid.h:

2015-10-08  Chris Dumez  <cdumez@apple.com>

        Unreviewed, build fix for ENABLE(MEDIA_SESSION) after r190030.

        * dom/Document.cpp:
        (WebCore::Document::updateIsPlayingMedia):

2015-10-08  Chris Dumez  <cdumez@apple.com>

        Unreviewed, build fixes for ENABLE(MEDIA_SESSION) after r190030.

        * Modules/mediasession/HTMLMediaElementMediaSession.cpp:
        (WebCore::HTMLMediaElementMediaSession::session):
        * Modules/mediasession/HTMLMediaElementMediaSession.h:
        * Modules/mediasession/MediaSession.cpp:
        (WebCore::MediaSession::controls):
        * Modules/mediasession/MediaSession.h:

2015-10-08  Jiewen Tan  <jiewen_tan@apple.com>

        Gracefully handle XMLDocumentParser being detached by mutation events.
        https://bugs.webkit.org/show_bug.cgi?id=149485
        <rdar://problem/22811489>

        This is a merge of Blink change 200026,
        https://codereview.chromium.org/1267283002

        Reviewed by Darin Adler.

        Test: fast/parser/xhtml-dom-character-data-modified-crash.html

        * xml/parser/XMLDocumentParser.cpp:
        (WebCore::XMLDocumentParser::createLeafTextNode):
        Renamed from enterText() to make it more descriptive. 

        (WebCore::XMLDocumentParser::updateLeafTextNode):
        Renamed from exitText to firm up this stage.

        (WebCore::XMLDocumentParser::end):
        Gracefully handle stopped states.

        (WebCore::XMLDocumentParser::enterText): Deleted.
        (WebCore::XMLDocumentParser::exitText): Deleted.

        * xml/parser/XMLDocumentParser.h:
        Rename enterText to createLeafTextNode.
        Rename exitText to updateLeafTextNode.

        * xml/parser/XMLDocumentParserLibxml2.cpp:
        (WebCore::XMLDocumentParser::startElementNs):
        (WebCore::XMLDocumentParser::endElementNs):
        (WebCore::XMLDocumentParser::characters):
        (WebCore::XMLDocumentParser::processingInstruction):
        (WebCore::XMLDocumentParser::cdataBlock):
        (WebCore::XMLDocumentParser::comment):
        (WebCore::XMLDocumentParser::endDocument):
        Rename function calls and firm up updateLeafTextNode stage accordingly.

2015-10-08  Chris Dumez  <cdumez@apple.com>

        data: URLs should not be preloaded
        https://bugs.webkit.org/show_bug.cgi?id=149829

        Reviewed by Darin Adler.

        Fix review comments after r190605:
        Use protocolIs() instead of String::startsWith().

        * html/parser/HTMLPreloadScanner.cpp:
        (WebCore::TokenPreloadScanner::StartTagScanner::shouldPreload):

2015-10-08  Chris Dumez  <cdumez@apple.com>

        Revert r187626 (and r188025) as it caused a PLT regression
        https://bugs.webkit.org/show_bug.cgi?id=149898
        <rdar://problem/22657123>

        Reviewed by Myles Maxfield.

        * css/CSSPropertyNames.in:
        * css/StyleBuilderCustom.h:
        (WebCore::StyleBuilderCustom::applyValueWebkitLocale):
        * platform/graphics/Font.cpp:
        (WebCore::CharacterFallbackMapKey::CharacterFallbackMapKey):
        (WebCore::CharacterFallbackMapKey::operator==):
        (WebCore::CharacterFallbackMapKeyHash::hash):
        (WebCore::Font::systemFallbackFontForCharacter):
        * platform/graphics/FontCache.h:
        (WebCore::FontDescriptionKey::operator==):
        (WebCore::FontDescriptionKey::FontDescriptionKey): Deleted.
        (WebCore::FontDescriptionKey::computeHash): Deleted.
        * platform/graphics/FontDescription.cpp:
        (WebCore::FontDescription::FontDescription):
        (WebCore::FontDescription::traitsMask): Deleted.
        (WebCore::FontCascadeDescription::FontCascadeDescription): Deleted.
        * platform/graphics/FontDescription.h:
        (WebCore::FontDescription::setScript):
        (WebCore::FontDescription::operator==):
        (WebCore::FontDescription::setFeatureSettings): Deleted.
        (WebCore::FontCascadeDescription::initialVariantAlternates): Deleted.
        * platform/graphics/cocoa/FontCacheCoreText.cpp:
        (WebCore::FontCache::systemFallbackForCharacters):
        * rendering/style/RenderStyle.cpp:
        (WebCore::RenderStyle::changeRequiresLayout):
        * rendering/style/RenderStyle.h:
        * rendering/style/StyleRareInheritedData.cpp:
        (WebCore::StyleRareInheritedData::StyleRareInheritedData):
        (WebCore::StyleRareInheritedData::operator==):
        * rendering/style/StyleRareInheritedData.h:
        * style/StyleResolveForDocument.cpp:
        (WebCore::Style::resolveForDocument):

2015-10-08  Andreas Kling  <akling@apple.com>

        Generated frame tree names should be kept reasonably long.
        <https://webkit.org/b/149874>

        Reviewed by Darin Adler.

        Some clumsy advertising script is going around assigning JavaScript source code
        to the "name" attribute of iframes. This is causing WebKit to generate way too huge
        names for anonymous descendants of such iframes.

        Previously, the generated name of an anonymous subframe would be its slash-separated
        path from the root frame, with the "name" attribute of each ancestor between the
        slashes, or "<!--frame${index in parent}-->" for anonymous ancestors.

        These ad scripts are often over 100kB in size, with multiple subframes, so we'd end
        up with frame names looking like this:

        "<!--framePath //<MONSTER BLOB OF JAVASCRIPT FROM HELL>/<!--frame0--><!--frame0-->-->"

        While this is worth fixing for the memory usage alone, we've been making it way
        worse by also using these paths when recording the back/forward history parts of
        WebKit session state.

        This patch makes generated paths always use index-in-parent as the "directory name"
        for ancestors of anonymous subframes. The above example path will now instead be:

        "<!--framePath //<!--frame0-->/<!--frame0-->/<!--frame0-->-->"

        Test: fast/frames/long-names-in-nested-subframes.html

        * page/FrameTree.cpp:
        (WebCore::FrameTree::indexInParent):
        (WebCore::FrameTree::uniqueChildName):
        * page/FrameTree.h:

2015-10-08  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r190701.
        https://bugs.webkit.org/show_bug.cgi?id=149937

        "It did not help, will try a full roll out instead" (Requested
        by cdumez on #webkit).

        Reverted changeset:

        "Partial revert of r187626 as it caused a PLT regression"
        https://bugs.webkit.org/show_bug.cgi?id=149898
        http://trac.webkit.org/changeset/190701

2015-10-08  Zalan Bujtas  <zalan@apple.com>

        Fallback to the RenderView when repaint container is null.
        https://bugs.webkit.org/show_bug.cgi?id=149903

        Reviewed by Simon Fraser.

        Reduces code complexity at the calling sites.

        No change in functionality.

        * rendering/RenderObject.cpp:
        (WebCore::RenderObject::repaintUsingContainer):
        (WebCore::RenderObject::repaint):
        (WebCore::RenderObject::repaintRectangle):

2015-10-08  Jiewen Tan  <jiewen_tan@apple.com>

        Add NULL check for renderBox::layer() on applying zoom level change
        https://bugs.webkit.org/show_bug.cgi?id=149302
        <rdar://problem/22747292>

        Reviewed by Darin Adler.

        Test: fast/css/zoom-on-nested-scroll-crash.html

        This is a merge of Blink r158238:
        https://chromiumcodereview.appspot.com/23526081

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

2015-10-08  Brady Eidson  <beidson@apple.com>

        Update Inspector to only work with Legacy IDB (for now).
        https://bugs.webkit.org/show_bug.cgi?id=149928.

        Reviewed by Tim Horton.

        * Modules/indexeddb/IDBAny.h:
        (WebCore::IDBAny::isLegacy):
        
        * Modules/indexeddb/legacy/LegacyAny.h:
        * inspector/InspectorIndexedDBAgent.cpp:

2015-10-08  Antti Koivisto  <antti@apple.com>

        CrashTracer: [USER] com.apple.WebKit.WebContent at …Core::SelectorChecker::checkScrollbarPseudoClass const + 217
        https://bugs.webkit.org/show_bug.cgi?id=149921
        rdar://problem/22731359

        Reviewed by Andreas Kling.

        Test: svg/css/use-window-inactive-crash.html

        * css/SelectorCheckerTestFunctions.h:
        (WebCore::isWindowInactive):

            Null check page.

2015-10-08  Michael Catanzaro  <mcatanzaro@igalia.com>

        Format string issues in LegacyRequest.cpp
        https://bugs.webkit.org/show_bug.cgi?id=149866

        Reviewed by Csaba Osztrogonác.

        Cast enums to ints before printing them to placate GCC's -Wformat.

        * Modules/indexeddb/legacy/LegacyRequest.cpp:
        (WebCore::LegacyRequest::dispatchEvent):
        (WebCore::LegacyRequest::enqueueEvent):

2015-10-08  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r190716.
        https://bugs.webkit.org/show_bug.cgi?id=149924

        broke mac build from time to time (Requested by youenn on
        #webkit).

        Reverted changeset:

        "Automate WebCore JS builtins generation and build system"
        https://bugs.webkit.org/show_bug.cgi?id=149751
        http://trac.webkit.org/changeset/190716

2015-10-08  Sergio Villar Senin  <svillar@igalia.com>

        [css-grid] Percentages of indefinite sizes to be resolved as auto
        https://bugs.webkit.org/show_bug.cgi?id=149810

        Reviewed by Darin Adler.

        Specs mention that percentages in grid track sizes must be
        resolved as 'auto' if the grid container has an indefinite
        size in the corresponding axis.

        The 'auto' keyword used to be resolved as
        minmax(min-content,max-content) but since r189911 it's
        resolved as minmax(auto,auto). Updated the implementation so
        we properly resolve those percentages.

        No new tests as the behavior does not change at all. That's
        because 'auto' as min-track sizing function is the same as
        min-content (unless we have a specified value for
        min-{width|height}, but those cases were already handled in the
        code), and as a max sizing function is works as max-content.

        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::gridTrackSize):

2015-10-08  Xabier Rodriguez Calvar  <calvaris@igalia.com> and Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Automate WebCore JS builtins generation and build system
        https://bugs.webkit.org/show_bug.cgi?id=149751

        Reviewed by Darin Adler.

        Adding annotations to JS files to know whether they should be under a compilation flag and
        whether they are JS internals or JS tied to WebIDL.
        If a file is said as JS internals, all function names are exported automatically.
        Added auto generation of WebCoreJSBuiltins.cpp
        Added auto generation of JSBuiltinFunctions class inside WebCoreJSBuiltins that takes the role of
        WebCoreJSClientData as wrapper for builtins.
        Added auto generation of WebCoreJSBuiltinInternals.h which contain a wrapper around all private functions, used by
        JSDOMWindowBase. The class is named JSBuiltinInternalFunctions.
        Renamed WebCoreJSClientData to JSVMClientData.

        The remaining manual part for private functions is the pairing between private identifiers and
        the private JS functions within JSDOMWindowBase::finishCreation.

        Covered by existing tests.

        * CMakeLists.txt:
        * DerivedSources.make:
        * Modules/streams/ByteLengthQueuingStrategy.js:
        * Modules/streams/CountQueuingStrategy.js:
        * Modules/streams/ReadableStream.js:
        * Modules/streams/ReadableStreamInternals.js:
        * WebCore.order:
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/DOMWrapperWorld.cpp:
        (WebCore::DOMWrapperWorld::DOMWrapperWorld):
        (WebCore::DOMWrapperWorld::~DOMWrapperWorld):
        (WebCore::normalWorld):
        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::JSDOMWindowBase::JSDOMWindowBase):
        (WebCore::JSDOMWindowBase::finishCreation):
        (WebCore::JSDOMWindowBase::visitChildren):
        (WebCore::JSDOMWindowBase::fireFrameClearedWatchpointsForWindow):
        * bindings/js/JSDOMWindowBase.h:
        * bindings/js/ScriptController.cpp:
        (WebCore::ScriptController::getAllWorlds):
        * bindings/js/SerializedScriptValue.cpp:
        (WebCore::SerializedScriptValue::transferArrayBuffers):
        * bindings/js/WebCoreJSClientData.h:
        (WebCore::JSClientData::JSClientData):
        (WebCore::JSClientData::~JSClientData):
        (WebCore::JSClientData::builtinFunctions):
        (WebCore::initNormalWorldClientData):
        (WebCore::WebCoreJSClientData::WebCoreJSClientData): Deleted.
        (WebCore::WebCoreJSClientData::~WebCoreJSClientData): Deleted.
        (WebCore::WebCoreJSClientData::readableStreamBuiltins): Deleted.
        (WebCore::WebCoreJSClientData::readableStreamControllerBuiltins): Deleted.
        (WebCore::WebCoreJSClientData::readableStreamInternalsBuiltins): Deleted.
        (WebCore::WebCoreJSClientData::readableStreamReaderBuiltins): Deleted.
        (WebCore::WebCoreJSClientData::byteLengthQueuingStrategyBuiltins): Deleted.
        (WebCore::WebCoreJSClientData::countQueuingStrategyBuiltins): Deleted.
        * generate-js-builtins-allinone: Added.
        (retrieveGenerationParameters):
        (retrieveFilesWithParameters):
        (retrieveFilesWithParameters.FileInput):
        (writeConditional):
        (JSBuiltinFunctions):
        (Private):
        (JSBuiltinInternalFunctions):
        (copytempfile):

2015-10-08  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Binding generated JS constructors should use GlobalObject references
        https://bugs.webkit.org/show_bug.cgi?id=149872

        Reviewed by Darin Adler.

        Updated binding generator to generate JS DOM constructors code with JSDOMGlobalOBject references.
        Updated WebCore JS binding layer accordingly.

        Covered by updated binding tests.

        * bindings/js/DOMConstructorWithDocument.h:
        (WebCore::DOMConstructorWithDocument::DOMConstructorWithDocument):
        (WebCore::DOMConstructorWithDocument::finishCreation):
        * bindings/js/JSDOMBinding.cpp:
        (WebCore::getCachedDOMStructure):
        (WebCore::cacheDOMStructure):
        * bindings/js/JSDOMBinding.h:
        (WebCore::DOMConstructorObject::DOMConstructorObject):
        (WebCore::DOMConstructorJSBuiltinObject::DOMConstructorJSBuiltinObject):
        (WebCore::getDOMStructure):
        (WebCore::deprecatedGetDOMStructure):
        (WebCore::getDOMPrototype):
        (WebCore::createJSBuiltin):
        (WebCore::createWrapper):
        * bindings/js/JSDOMConstructor.h:
        (WebCore::JSBuiltinConstructor::JSBuiltinConstructor):
        * bindings/js/JSDOMGlobalObject.h:
        (WebCore::getDOMConstructor):
        * bindings/js/JSDOMWindowCustom.cpp:
        (WebCore::JSDOMWindow::image):
        (WebCore::JSDOMWindow::touch):
        (WebCore::JSDOMWindow::touchList):
        * bindings/js/JSDOMWrapper.h:
        (WebCore::JSDOMWrapper::JSDOMWrapper):
        (WebCore::JSDOMWrapperWithImplementation::JSDOMWrapperWithImplementation):
        * bindings/js/JSImageConstructor.cpp:
        (WebCore::JSImageConstructor::JSImageConstructor):
        (WebCore::JSImageConstructor::finishCreation):
        * bindings/js/JSImageConstructor.h:
        (WebCore::JSImageConstructor::create):
        (WebCore::JSImageConstructor::createStructure):
        * bindings/js/JSReadableStreamPrivateConstructors.cpp:
        (WebCore::JSBuiltinReadableStreamReaderPrivateConstructor::createJSObject):
        (WebCore::JSBuiltinReadableStreamControllerPrivateConstructor::createJSObject):
        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateHeader):
        (GenerateImplementation):
        (GenerateCallbackImplementation):
        (GenerateConstructorDeclaration):
        (GenerateConstructorHelperMethods):
        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
        (WebCore::JSTestActiveDOMObjectConstructor::create):
        (WebCore::JSTestActiveDOMObjectConstructor::createStructure):
        (WebCore::JSTestActiveDOMObjectConstructor::JSTestActiveDOMObjectConstructor):
        (WebCore::JSTestActiveDOMObjectConstructor::finishCreation):
        (WebCore::JSTestActiveDOMObject::JSTestActiveDOMObject):
        (WebCore::JSTestActiveDOMObject::getConstructor):
        * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
        (WebCore::JSTestActiveDOMObject::create):
        * bindings/scripts/test/JS/JSTestCallback.cpp:
        (WebCore::JSTestCallbackConstructor::create):
        (WebCore::JSTestCallbackConstructor::createStructure):
        (WebCore::JSTestCallbackConstructor::JSTestCallbackConstructor):
        (WebCore::JSTestCallback::getConstructor):
        * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::create):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::createStructure):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::JSTestCustomConstructorWithNoInterfaceObjectConstructor):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::finishCreation):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObject::JSTestCustomConstructorWithNoInterfaceObject):
        (WebCore::jsTestCustomConstructorWithNoInterfaceObjectConstructor):
        * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h:
        (WebCore::JSTestCustomConstructorWithNoInterfaceObject::create):
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
        (WebCore::JSTestCustomNamedGetterConstructor::create):
        (WebCore::JSTestCustomNamedGetterConstructor::createStructure):
        (WebCore::JSTestCustomNamedGetterConstructor::JSTestCustomNamedGetterConstructor):
        (WebCore::JSTestCustomNamedGetterConstructor::finishCreation):
        (WebCore::JSTestCustomNamedGetter::JSTestCustomNamedGetter):
        (WebCore::JSTestCustomNamedGetter::getConstructor):
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
        (WebCore::JSTestCustomNamedGetter::create):
        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
        (WebCore::JSTestEventConstructorConstructor::create):
        (WebCore::JSTestEventConstructorConstructor::createStructure):
        (WebCore::JSTestEventConstructorConstructor::JSTestEventConstructorConstructor):
        (WebCore::JSTestEventConstructorConstructor::finishCreation):
        (WebCore::JSTestEventConstructor::JSTestEventConstructor):
        (WebCore::JSTestEventConstructor::getConstructor):
        * bindings/scripts/test/JS/JSTestEventConstructor.h:
        (WebCore::JSTestEventConstructor::create):
        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
        (WebCore::JSTestEventTargetConstructor::create):
        (WebCore::JSTestEventTargetConstructor::createStructure):
        (WebCore::JSTestEventTargetConstructor::JSTestEventTargetConstructor):
        (WebCore::JSTestEventTargetConstructor::finishCreation):
        (WebCore::JSTestEventTarget::JSTestEventTarget):
        (WebCore::JSTestEventTarget::getConstructor):
        * bindings/scripts/test/JS/JSTestEventTarget.h:
        (WebCore::JSTestEventTarget::create):
        * bindings/scripts/test/JS/JSTestException.cpp:
        (WebCore::JSTestExceptionConstructor::create):
        (WebCore::JSTestExceptionConstructor::createStructure):
        (WebCore::JSTestExceptionConstructor::JSTestExceptionConstructor):
        (WebCore::JSTestExceptionConstructor::finishCreation):
        (WebCore::JSTestException::JSTestException):
        (WebCore::JSTestException::getConstructor):
        * bindings/scripts/test/JS/JSTestException.h:
        (WebCore::JSTestException::create):
        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
        (WebCore::JSTestGenerateIsReachableConstructor::create):
        (WebCore::JSTestGenerateIsReachableConstructor::createStructure):
        (WebCore::JSTestGenerateIsReachableConstructor::JSTestGenerateIsReachableConstructor):
        (WebCore::JSTestGenerateIsReachableConstructor::finishCreation):
        (WebCore::JSTestGenerateIsReachable::JSTestGenerateIsReachable):
        (WebCore::JSTestGenerateIsReachable::getConstructor):
        * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
        (WebCore::JSTestGenerateIsReachable::create):
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        (WebCore::JSTestInterfaceConstructor::create):
        (WebCore::JSTestInterfaceConstructor::createStructure):
        (WebCore::JSTestInterfaceConstructor::JSTestInterfaceConstructor):
        (WebCore::JSTestInterfaceConstructor::finishCreation):
        (WebCore::JSTestInterface::JSTestInterface):
        (WebCore::JSTestInterface::getConstructor):
        * bindings/scripts/test/JS/JSTestInterface.h:
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
        (WebCore::JSTestJSBuiltinConstructorConstructor::create):
        (WebCore::JSTestJSBuiltinConstructorConstructor::createStructure):
        (WebCore::JSTestJSBuiltinConstructorConstructor::JSTestJSBuiltinConstructorConstructor):
        (WebCore::JSTestJSBuiltinConstructorConstructor::finishCreation):
        (WebCore::JSTestJSBuiltinConstructor::JSTestJSBuiltinConstructor):
        (WebCore::JSTestJSBuiltinConstructor::getConstructor):
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.h:
        (WebCore::JSTestJSBuiltinConstructor::create):
        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
        (WebCore::JSTestMediaQueryListListenerConstructor::create):
        (WebCore::JSTestMediaQueryListListenerConstructor::createStructure):
        (WebCore::JSTestMediaQueryListListenerConstructor::JSTestMediaQueryListListenerConstructor):
        (WebCore::JSTestMediaQueryListListenerConstructor::finishCreation):
        (WebCore::JSTestMediaQueryListListener::JSTestMediaQueryListListener):
        (WebCore::JSTestMediaQueryListListener::getConstructor):
        * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
        (WebCore::JSTestMediaQueryListListener::create):
        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
        (WebCore::JSTestNamedConstructorConstructor::create):
        (WebCore::JSTestNamedConstructorConstructor::createStructure):
        (WebCore::JSTestNamedConstructorNamedConstructor::create):
        (WebCore::JSTestNamedConstructorNamedConstructor::createStructure):
        (WebCore::JSTestNamedConstructorConstructor::JSTestNamedConstructorConstructor):
        (WebCore::JSTestNamedConstructorConstructor::finishCreation):
        (WebCore::JSTestNamedConstructorNamedConstructor::JSTestNamedConstructorNamedConstructor):
        (WebCore::JSTestNamedConstructorNamedConstructor::finishCreation):
        (WebCore::JSTestNamedConstructor::JSTestNamedConstructor):
        (WebCore::JSTestNamedConstructor::getConstructor):
        (WebCore::JSTestNamedConstructor::getNamedConstructor):
        * bindings/scripts/test/JS/JSTestNamedConstructor.h:
        (WebCore::JSTestNamedConstructor::create):
        * bindings/scripts/test/JS/JSTestNode.cpp:
        (WebCore::JSTestNodeConstructor::create):
        (WebCore::JSTestNodeConstructor::createStructure):
        (WebCore::JSTestNodeConstructor::JSTestNodeConstructor):
        (WebCore::JSTestNodeConstructor::finishCreation):
        (WebCore::JSTestNode::JSTestNode):
        (WebCore::JSTestNode::getConstructor):
        * bindings/scripts/test/JS/JSTestNode.h:
        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
        (WebCore::JSTestNondeterministicConstructor::create):
        (WebCore::JSTestNondeterministicConstructor::createStructure):
        (WebCore::JSTestNondeterministicConstructor::JSTestNondeterministicConstructor):
        (WebCore::JSTestNondeterministicConstructor::finishCreation):
        (WebCore::JSTestNondeterministic::JSTestNondeterministic):
        (WebCore::JSTestNondeterministic::getConstructor):
        * bindings/scripts/test/JS/JSTestNondeterministic.h:
        (WebCore::JSTestNondeterministic::create):
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::JSTestObjConstructor::create):
        (WebCore::JSTestObjConstructor::createStructure):
        (WebCore::JSTestObjConstructor::JSTestObjConstructor):
        (WebCore::JSTestObjConstructor::finishCreation):
        (WebCore::JSTestObj::JSTestObj):
        (WebCore::JSTestObj::getConstructor):
        * bindings/scripts/test/JS/JSTestObj.h:
        (WebCore::JSTestObj::create):
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
        (WebCore::JSTestOverloadedConstructorsConstructor::create):
        (WebCore::JSTestOverloadedConstructorsConstructor::createStructure):
        (WebCore::JSTestOverloadedConstructorsConstructor::JSTestOverloadedConstructorsConstructor):
        (WebCore::JSTestOverloadedConstructorsConstructor::finishCreation):
        (WebCore::JSTestOverloadedConstructors::JSTestOverloadedConstructors):
        (WebCore::JSTestOverloadedConstructors::getConstructor):
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
        (WebCore::JSTestOverloadedConstructors::create):
        * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
        (WebCore::JSTestOverrideBuiltinsConstructor::create):
        (WebCore::JSTestOverrideBuiltinsConstructor::createStructure):
        (WebCore::JSTestOverrideBuiltinsConstructor::JSTestOverrideBuiltinsConstructor):
        (WebCore::JSTestOverrideBuiltinsConstructor::finishCreation):
        (WebCore::JSTestOverrideBuiltins::JSTestOverrideBuiltins):
        (WebCore::JSTestOverrideBuiltins::getConstructor):
        * bindings/scripts/test/JS/JSTestOverrideBuiltins.h:
        (WebCore::JSTestOverrideBuiltins::create):
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::create):
        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::createStructure):
        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::JSTestSerializedScriptValueInterfaceConstructor):
        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::finishCreation):
        (WebCore::JSTestSerializedScriptValueInterface::JSTestSerializedScriptValueInterface):
        (WebCore::JSTestSerializedScriptValueInterface::getConstructor):
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
        (WebCore::JSTestSerializedScriptValueInterface::create):
        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
        (WebCore::JSTestTypedefsConstructor::create):
        (WebCore::JSTestTypedefsConstructor::createStructure):
        (WebCore::JSTestTypedefsConstructor::JSTestTypedefsConstructor):
        (WebCore::JSTestTypedefsConstructor::finishCreation):
        (WebCore::JSTestTypedefs::JSTestTypedefs):
        (WebCore::JSTestTypedefs::getConstructor):
        * bindings/scripts/test/JS/JSTestTypedefs.h:
        (WebCore::JSTestTypedefs::create):
        * bindings/scripts/test/JS/JSattribute.cpp:
        (WebCore::JSattributeConstructor::create):
        (WebCore::JSattributeConstructor::createStructure):
        (WebCore::JSattributeConstructor::JSattributeConstructor):
        (WebCore::JSattributeConstructor::finishCreation):
        (WebCore::JSattribute::JSattribute):
        (WebCore::JSattribute::getConstructor):
        * bindings/scripts/test/JS/JSattribute.h:
        (WebCore::JSattribute::create):
        * bindings/scripts/test/JS/JSreadonly.cpp:
        (WebCore::JSreadonlyConstructor::create):
        (WebCore::JSreadonlyConstructor::createStructure):
        (WebCore::JSreadonlyConstructor::JSreadonlyConstructor):
        (WebCore::JSreadonlyConstructor::finishCreation):
        (WebCore::JSreadonly::JSreadonly):
        (WebCore::JSreadonly::getConstructor):
        * bindings/scripts/test/JS/JSreadonly.h:
        (WebCore::JSreadonly::create):

2015-10-08  Philippe Normand  <pnormand@igalia.com>

        WebRTC: Add event names needed by updated RTCPeerConnection
        https://bugs.webkit.org/show_bug.cgi?id=149875

        Reviewed by Eric Carlson.

        The track event name was recently added in the WebRTC spec. The
        icegatheringstatechange event has been part of the spec for a while but
        was not registered in our DOM events.

        * dom/EventNames.h: Add track and icegatheringstatechange even names.

2015-10-07  Keith Rollin  <krollin@apple.com>

        script.text shouldn't include text from non-direct children of the script element
        https://bugs.webkit.org/show_bug.cgi?id=148851
        <rdar://problem/22587759>

        Reviewed by Chris Dumez.

        Don't include text from non-direct children in script.text. Per:
        https://html.spec.whatwg.org/multipage/scripting.html#dom-script-text
        Chrome and Firefox behavior match the spec.

        Test: fast/dom/script-subtext-in-script-elements.html

        * dom/ScriptElement.cpp:
        (WebCore::ScriptElement::scriptContent):

2015-10-07  Chris Dumez  <cdumez@apple.com>

        Partial revert of r187626 as it caused a PLT regression
        https://bugs.webkit.org/show_bug.cgi?id=149898

        Reviewed by Myles C. Maxfield.

        Do a partial revert of r187626 as it caused a regression on PLT.

        * platform/graphics/FontCache.h:
        (WebCore::FontDescriptionKey::operator==):
        (WebCore::FontDescriptionKey::FontDescriptionKey): Deleted.
        (WebCore::FontDescriptionKey::computeHash): Deleted.

2015-10-07  Zalan Bujtas  <zalan@apple.com>

        RenderObject::computeRectForRepaint/computeFloatRectForRepaint should return the computed rectangle.
        https://bugs.webkit.org/show_bug.cgi?id=149883

        Reviewed by Simon Fraser.

        Reduces code complexity at the calling sites.
 
        No change in functionality.

        * rendering/RenderBox.cpp:
        (WebCore::RenderBox::clippedOverflowRectForRepaint):
        (WebCore::RenderBox::computeRectForRepaint):
        * rendering/RenderBox.h:
        * rendering/RenderInline.cpp:
        (WebCore::RenderInline::clippedOverflowRectForRepaint):
        (WebCore::RenderInline::computeRectForRepaint):
        * rendering/RenderInline.h:
        * rendering/RenderListMarker.cpp:
        (WebCore::RenderListMarker::selectionRectForRepaint):
        * rendering/RenderObject.cpp:
        (WebCore::RenderObject::repaintRectangle):
        (WebCore::RenderObject::computeRectForRepaint):
        (WebCore::RenderObject::computeFloatRectForRepaint):
        * rendering/RenderObject.h:
        (WebCore::RenderObject::computeAbsoluteRepaintRect):
        * rendering/RenderReplaced.cpp:
        (WebCore::RenderReplaced::selectionRectForRepaint):
        (WebCore::RenderReplaced::clippedOverflowRectForRepaint):
        * rendering/RenderTableCell.cpp:
        (WebCore::RenderTableCell::clippedOverflowRectForRepaint):
        (WebCore::RenderTableCell::computeRectForRepaint):
        * rendering/RenderTableCell.h:
        * rendering/RenderText.cpp:
        (WebCore::RenderText::collectSelectionRectsForLineBoxes):
        * rendering/RenderView.cpp:
        (WebCore::RenderView::computeRectForRepaint):
        * rendering/RenderView.h:
        * rendering/svg/RenderSVGForeignObject.cpp:
        (WebCore::RenderSVGForeignObject::computeFloatRectForRepaint):
        (WebCore::RenderSVGForeignObject::computeRectForRepaint):
        * rendering/svg/RenderSVGForeignObject.h:
        * rendering/svg/RenderSVGInline.cpp:
        (WebCore::RenderSVGInline::computeFloatRectForRepaint):
        * rendering/svg/RenderSVGInline.h:
        * rendering/svg/RenderSVGModelObject.cpp:
        (WebCore::RenderSVGModelObject::computeFloatRectForRepaint):
        * rendering/svg/RenderSVGModelObject.h:
        * rendering/svg/RenderSVGRoot.cpp:
        (WebCore::RenderSVGRoot::computeFloatRectForRepaint):
        * rendering/svg/RenderSVGRoot.h:
        * rendering/svg/RenderSVGText.cpp:
        (WebCore::RenderSVGText::computeRectForRepaint):
        (WebCore::RenderSVGText::computeFloatRectForRepaint):
        * rendering/svg/RenderSVGText.h:
        * rendering/svg/SVGRenderSupport.cpp:
        (WebCore::SVGRenderSupport::clippedOverflowRectForRepaint):
        (WebCore::SVGRenderSupport::computeFloatRectForRepaint):
        * rendering/svg/SVGRenderSupport.h:

2015-10-07  Antti Koivisto  <antti@apple.com>

        Implement :host pseudo class
        https://bugs.webkit.org/show_bug.cgi?id=149440
        rdar://problem/22731953

        Reviewed by Ryosuke Niwa.

        This implements the basic non-function :host syntax.

        * css/CSSSelector.cpp:
        (WebCore::CSSSelector::selectorText):
        * css/CSSSelector.h:
        * css/ElementRuleCollector.cpp:
        (WebCore::ElementRuleCollector::matchAuthorRules):
        (WebCore::ElementRuleCollector::matchHostPseudoClassRules):
        (WebCore::ElementRuleCollector::matchUserRules):
        * css/ElementRuleCollector.h:
        * css/RuleSet.cpp:
        (WebCore::computeMatchBasedOnRuleHash):
        (WebCore::RuleSet::addRule):
        * css/RuleSet.h:
        (WebCore::RuleSet::cuePseudoRules):
        (WebCore::RuleSet::hostPseudoClassRules):
        (WebCore::RuleSet::focusPseudoClassRules):
        (WebCore::RuleSet::universalRules):
        * css/SelectorChecker.cpp:
        (WebCore::SelectorChecker::checkOne):
        * css/SelectorPseudoClassAndCompatibilityElementMap.in:
        * cssjit/SelectorCompiler.cpp:
        (WebCore::SelectorCompiler::addPseudoClassType):

2015-10-07  Nan Wang  <n_wang@apple.com>

        AX: ARIA 1.1 @aria-placeholder
        https://bugs.webkit.org/show_bug.cgi?id=148970

        Reviewed by Chris Fleizach.

        Added support for aria-placeholder attribute.

        Modified accessibility/placeholder.html test.

        * accessibility/AccessibilityObject.cpp:
        (WebCore::AccessibilityObject::placeholderValue):
        * html/HTMLAttributeNames.in:

2015-10-07  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r190664.
        https://bugs.webkit.org/show_bug.cgi?id=149877

        mac build is sometimes borken due to missing generated header
        file (Requested by youenn on #webkit).

        Reverted changeset:

        "Automate WebCore JS builtins generation and build system"
        https://bugs.webkit.org/show_bug.cgi?id=149751
        http://trac.webkit.org/changeset/190664

2015-10-06  Simon Fraser  <simon.fraser@apple.com>

        will-change should trigger stacking context based purely on properties
        https://bugs.webkit.org/show_bug.cgi?id=148068

        Reviewed by Zalan Bujtas.

        Previously, our will-change implementation didn't trigger stacking context
        on an inline if the will-change property didn't apply to inlines (like 'transform').
        However, this doesn't agree with the CSS-WG consensus (https://lists.w3.org/Archives/Public/www-style/2015Sep/0112.html).
        
        Change behavior to have stacking context creation behavior for will-change be
        identical for inlines and blocks.

        Test: fast/css/will-change/will-change-creates-stacking-context-inline.html

        * rendering/RenderInline.cpp:
        (WebCore::inFlowPositionedInlineAncestor):
        * rendering/RenderInline.h:
        (WebCore::RenderInline::willChangeCreatesStackingContext):
        * rendering/style/WillChangeData.cpp:
        (WebCore::propertyCreatesStackingContext):
        (WebCore::WillChangeData::addFeature):
        (WebCore::propertyCreatesStackingContextOnBoxesOnly): Deleted.
        * rendering/style/WillChangeData.h:
        (WebCore::WillChangeData::canCreateStackingContextOnInline): Deleted.

2015-10-07  Javier Fernandez  <jfernandez@igalia.com>

        [CSS Grid Layout] Modify grid item height doesn't work
        https://bugs.webkit.org/show_bug.cgi?id=149840

        Reviewed by Sergio Villar Senin.

        When computing the logical height of content-sized grid tracks we
        need to clear grid item's override height if it needs to be laid
        out again.

        Currently we are doing so only in the case of percentage heights
        or when the grid track's width has changed; these situations would
        obviously mark grid items as needing layout.

        However, there are other situations, like the one defined in this
        bug, which would imply a new layout of the grid items; hence we
        need to clear its override value if we want the layout logic to be
        computed correctly.

        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::logicalContentHeightForChild):

2015-10-07  Xabier Rodriguez Calvar  <calvaris@igalia.com> and Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Automate WebCore JS builtins generation and build system
        https://bugs.webkit.org/show_bug.cgi?id=149751

        Reviewed by Darin Adler.

        Adding annotations to JS files to know whether they should be under a compilation flag and
        whether they are JS internals or JS tied to WebIDL.
        If a file is said as JS internals, all function names are exported automatically.
        Added auto generation of WebCoreJSBuiltins.cpp
        Added auto generation of JSBuiltinFunctions class inside WebCoreJSBuiltins that takes the role of
        WebCoreJSClientData as wrapper for builtins. Renamed WebCoreJSClientData to JSClientData.
        Added auto generation of PrivateWebCoreJSBuiltins that is a wrapper around all private functions, used by
        JSDOMWindowBase. The class is named JSBuiltinInternalFunctions.

        The remaining manual part for private functions is the pairing between private identifiers and
        the private JS functions within JSDOMWindowBase::finishCreation.

        Covered by existing tests.

        * CMakeLists.txt:
        * DerivedSources.make:
        * Modules/streams/ByteLengthQueuingStrategy.js:
        * Modules/streams/CountQueuingStrategy.js:
        * Modules/streams/ReadableStream.js:
        * Modules/streams/ReadableStreamInternals.js:
        * WebCore.order:
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/DOMWrapperWorld.cpp:
        (WebCore::DOMWrapperWorld::DOMWrapperWorld):
        (WebCore::DOMWrapperWorld::~DOMWrapperWorld):
        (WebCore::normalWorld):
        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::JSDOMWindowBase::JSDOMWindowBase):
        (WebCore::JSDOMWindowBase::finishCreation):
        (WebCore::JSDOMWindowBase::visitChildren):
        (WebCore::JSDOMWindowBase::fireFrameClearedWatchpointsForWindow):
        * bindings/js/JSDOMWindowBase.h:
        * bindings/js/ScriptController.cpp:
        (WebCore::ScriptController::getAllWorlds):
        * bindings/js/SerializedScriptValue.cpp:
        (WebCore::SerializedScriptValue::transferArrayBuffers):
        * bindings/js/WebCoreJSClientData.h:
        (WebCore::JSClientData::JSClientData):
        (WebCore::JSClientData::~JSClientData):
        (WebCore::JSClientData::builtinFunctions):
        (WebCore::initNormalWorldClientData):
        (WebCore::WebCoreJSClientData::WebCoreJSClientData): Deleted.
        (WebCore::WebCoreJSClientData::~WebCoreJSClientData): Deleted.
        (WebCore::WebCoreJSClientData::readableStreamBuiltins): Deleted.
        (WebCore::WebCoreJSClientData::readableStreamControllerBuiltins): Deleted.
        (WebCore::WebCoreJSClientData::readableStreamInternalsBuiltins): Deleted.
        (WebCore::WebCoreJSClientData::readableStreamReaderBuiltins): Deleted.
        (WebCore::WebCoreJSClientData::byteLengthQueuingStrategyBuiltins): Deleted.
        (WebCore::WebCoreJSClientData::countQueuingStrategyBuiltins): Deleted.
        * generate-js-builtins-allinone: Added.
        (retrieveGenerationParameters):
        (retrieveFilesWithParameters):
        (retrieveFilesWithParameters.FileInput):
        (writeConditional):
        (JSBuiltinFunctions):
        (Private):
        (JSBuiltinInternalFunctions):
        (copytempfile):

2015-10-05  Sergio Villar Senin  <svillar@igalia.com>

        [css-grid] Implement grid gutters
        https://bugs.webkit.org/show_bug.cgi?id=149800

        Reviewed by Darin Adler.

        Authors can now specify the gutters between grid lines, i.e.,
        the space between two consecutive grid lines. This can be done
        using the new '-webkit-grid-column-gap 'and
        '-webkit-grid-row-gap' properties (or the '-webkit-grid-gap'
        shorthand).

        From the track sizing algorithm POV, gutters are treated as
        fixed size columns. The primary consequence is that grids are
        enlarged (depending on the number of tracks). Gutters also
        affect the sizing of content-sized tracks and fr tracks as
        long as the grid have spanning items. Those tracks will become
        smaller as gutters will consume part of the item's size, so
        the tracks won't need to grow as much as they used to.

        Tests: fast/css-grid-layout/grid-gutters-and-alignment.html
               fast/css-grid-layout/grid-gutters-and-flex-content.html
               fast/css-grid-layout/grid-gutters-and-tracks.html
               fast/css-grid-layout/grid-gutters-get-set.html

        * css/CSSComputedStyleDeclaration.cpp:
        (WebCore::valueForGridTrackList):
        (WebCore::ComputedStyleExtractor::propertyValue):
        * css/CSSParser.cpp:
        (WebCore::isSimpleLengthPropertyID):
        (WebCore::CSSParser::parseValue):
        (WebCore::CSSParser::parseGridGapShorthand):
        * css/CSSParser.h:
        * css/CSSPropertyNames.in:
        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::guttersSize):
        (WebCore::RenderGrid::computeIntrinsicLogicalWidths):
        (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctionsForItems):
        (WebCore::RenderGrid::layoutGridItems):
        (WebCore::RenderGrid::gridAreaBreadthForChild):
        (WebCore::RenderGrid::populateGridPositions):
        (WebCore::RenderGrid::columnAxisOffsetForChild):
        (WebCore::RenderGrid::rowAxisOffsetForChild):
        * rendering/RenderGrid.h:
        * rendering/style/RenderStyle.h:
        * rendering/style/StyleGridData.cpp:
        (WebCore::StyleGridData::StyleGridData):
        * rendering/style/StyleGridData.h:
        (WebCore::StyleGridData::operator==):

2015-10-07  ChangSeok Oh  <changseok.oh@collabora.com>

        [GTK] Progress bar is broken on recent GTK+
        https://bugs.webkit.org/show_bug.cgi?id=149831

        Reviewed by Carlos Garcia Campos.

        The gtk progress bar has been broken after bumping up to Gtk+-3.16. This is because
        the way of rendering progress bar changed after gtk+-3.13.7. See more
        https://mail.gnome.org/archives/commits-list/2014-August/msg03865.html
        gtk_render_activity is no longer valid to paint a progress bar on a newer gtk+.
        It should be done with gtk_render_background and gtk_render_frame.

        Test: fast/dom/HTMLProgressElement/native-progress-bar.html

        * rendering/RenderThemeGtk.cpp:
        (WebCore::RenderThemeGtk::paintProgressBar):

2015-10-06  Michael Catanzaro  <mcatanzaro@igalia.com>

        [GTK] Add autocleanups
        https://bugs.webkit.org/show_bug.cgi?id=149588

        Reviewed by Darin Adler.

        * PlatformGTK.cmake:
        * bindings/scripts/gobject-generate-headers.pl:

2015-10-06  Zalan Bujtas  <zalan@apple.com>

        Paint artifacts when hovering on http://jsfiddle.net/Sherbrow/T87Mn/
        https://bugs.webkit.org/show_bug.cgi?id=149535
        rdar://problem/22874920

        Reviewed by Simon Fraser.

        When due to some style change, a renderer's self-painting layer is getting destroyed 
        and the parent's overflow is no longer set to visible, we don't clean up the overflow part.

        When a renderer has a self-painting layer, the parent stops tracking the child's 
        visual overflow rect. All overflow painting is delegated to the self-painting layer.
        However when this layer gets destroyed, no-one issues repaint to clean up
        the overflow bits.
        This patch ensures that we issue a repaint when the self-painting layer is destroyed
        and the triggering style change requires full repaint.

        Test: fast/repaint/overflow-hidden-with-self-painting-child-layer.html

        * rendering/RenderLayer.h:
        * rendering/RenderLayerModelObject.cpp:
        (WebCore::RenderLayerModelObject::styleDidChange):

2015-10-06  Jer Noble  <jer.noble@apple.com>

        [Mac] REGRESSION(r173318): Seeks never complete for media loaded with QTKit.
        https://bugs.webkit.org/show_bug.cgi?id=149845

        Reviewed by Darin Adler.

        When converting from time-as-double to MediaTime, a regression was introduced
        when checking whether m_seekTo was set to a valid value or not. The clause
        `time != -1` should be translated to `time.isValid()`, not `!time.isValid()`.

        * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
        (WebCore::MediaPlayerPrivateQTKit::timeChanged):

2015-10-06  Brady Eidson  <beidson@apple.com>

        Rename IDBRequestIdentifier to IDBResourceIdentifier.
        https://bugs.webkit.org/show_bug.cgi?id=149861

        Reviewed by Alex Christensen.

        No new tests (No change in behavior).

        Turns out having an object representing a (connection ID + unique ID pair) is useful for more than just IDBRequests.

        * CMakeLists.txt:
        * Modules/indexeddb/client/IDBConnectionToServer.cpp:
        (WebCore::IDBClient::IDBConnectionToServer::deleteDatabase):
        (WebCore::IDBClient::IDBConnectionToServer::openDatabase):
        * Modules/indexeddb/client/IDBConnectionToServer.h:
        * Modules/indexeddb/client/IDBRequestImpl.cpp:
        (WebCore::IDBClient::IDBRequest::IDBRequest):
        * Modules/indexeddb/client/IDBRequestImpl.h:
        (WebCore::IDBClient::IDBRequest::resourceIdentifier):
        (WebCore::IDBClient::IDBRequest::requestIdentifier): Deleted.
        * Modules/indexeddb/shared/IDBRequestData.h:
        (WebCore::IDBRequestData::requestIdentifier):
        * Modules/indexeddb/shared/IDBResourceIdentifier.cpp: Renamed from Source/WebCore/Modules/indexeddb/shared/IDBRequestIdentifier.cpp.
        (WebCore::nextResourceNumber):
        (WebCore::IDBResourceIdentifier::IDBResourceIdentifier):
        (WebCore::IDBResourceIdentifier::emptyValue):
        (WebCore::IDBResourceIdentifier::deletedValue):
        (WebCore::IDBResourceIdentifier::isHashTableDeletedValue):
        * Modules/indexeddb/shared/IDBResourceIdentifier.h: Renamed from Source/WebCore/Modules/indexeddb/shared/IDBRequestIdentifier.h.
        (WebCore::IDBResourceIdentifier::isEmpty):
        (WebCore::IDBResourceIdentifier::hash):
        (WebCore::IDBResourceIdentifier::operator==):
        (WebCore::IDBResourceIdentifier::connectionIdentifier):
        (WebCore::IDBResourceIdentifierHash::hash):
        (WebCore::IDBResourceIdentifierHash::equal):
        (WebCore::IDBResourceIdentifierHashTraits::emptyValue):
        (WebCore::IDBResourceIdentifierHashTraits::isEmptyValue):
        (WebCore::IDBResourceIdentifierHashTraits::constructDeletedValue):
        (WebCore::IDBResourceIdentifierHashTraits::isDeletedValue):
        * Modules/indexeddb/shared/IDBResultData.cpp:
        (WebCore::IDBResultData::IDBResultData):
        * Modules/indexeddb/shared/IDBResultData.h:
        (WebCore::IDBResultData::requestIdentifier):
        * WebCore.xcodeproj/project.pbxproj:

2015-10-06  Nan Wang  <n_wang@apple.com>

        AX: ARIA 1.1: aria-orientation now defaults to undefined, supported on more elements, and role-specific defaults are defined.
        https://bugs.webkit.org/show_bug.cgi?id=132177

        Reviewed by Chris Fleizach.

        Added role-specific defaults and changed general default to undefined.
        Also added more elements to support aria-orientation on Mac.

        Test: accessibility/mac/aria-orientation.html

        * accessibility/AccessibilityObject.cpp:
        (WebCore::AccessibilityObject::orientation):
        (WebCore::AccessibilityObject::isDescendantOfObject):
        * accessibility/AccessibilityObject.h:
        (WebCore::AccessibilityObject::isColorWell):
        (WebCore::AccessibilityObject::isSplitter):
        (WebCore::AccessibilityObject::isToolbar):
        (WebCore::AccessibilityObject::isChecked):
        (WebCore::AccessibilityObject::isEnabled):
        * accessibility/AccessibilityRenderObject.cpp:
        (WebCore::AccessibilityRenderObject::orientation):
        * accessibility/AccessibilityScrollView.cpp:
        (WebCore::AccessibilityScrollView::scrollBar):
        * accessibility/AccessibilityScrollbar.cpp:
        (WebCore::AccessibilityScrollbar::orientation):
        (WebCore::AccessibilityScrollbar::isEnabled):
        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
        (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
        (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):

2015-10-06  Per Arne Vollan  <peavo@outlook.com>

        [WinCairo] GStreamer compile errors.
        https://bugs.webkit.org/show_bug.cgi?id=149839

        Reviewed by Alex Christensen.

        Help MSVC to resolve ambiguous calls.

        * platform/graphics/MediaPlayer.h:
        * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
        (WebCore::InbandTextTrackPrivateGStreamer::handleSample):
        (WebCore::InbandTextTrackPrivateGStreamer::streamChanged):
        (WebCore::InbandTextTrackPrivateGStreamer::notifyTrackOfSample):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
        (WebCore::MediaPlayerPrivateGStreamer::videoChanged):
        (WebCore::MediaPlayerPrivateGStreamer::videoCapsChanged):
        (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideo):
        (WebCore::MediaPlayerPrivateGStreamer::audioChanged):
        (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfAudio):
        (WebCore::MediaPlayerPrivateGStreamer::textChanged):
        (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfText):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
        (WebCore::MediaPlayerPrivateGStreamerBase::volumeChanged):
        (WebCore::MediaPlayerPrivateGStreamerBase::networkState):
        (WebCore::MediaPlayerPrivateGStreamerBase::muteChanged):
        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
        (WebCore::TrackPrivateBaseGStreamer::activeChanged):
        (WebCore::TrackPrivateBaseGStreamer::tagsChanged):
        (WebCore::TrackPrivateBaseGStreamer::notifyTrackOfActiveChanged):
        * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
        (webkitVideoSinkRender):
        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
        (webKitWebSrcChangeState):
        (webKitWebSrcNeedDataCb):
        (webKitWebSrcEnoughDataMainCb):
        (webKitWebSrcEnoughDataCb):
        (webKitWebSrcSeekMainCb):
        (webKitWebSrcSeekDataCb):

2015-10-06  Chris Dumez  <cdumez@apple.com>

        Refactor TokenPreloadScanner::StartTagScanner::processAttribute()
        https://bugs.webkit.org/show_bug.cgi?id=149847

        Reviewed by Antti Koivisto.

        Refactor TokenPreloadScanner::StartTagScanner::processAttribute() to only
        process attributes that make sense given the current tagId. In particular,
        - We only process the charset parameter if the tag is a link or a script.
        - We only process the sizes / srcset attributes if the tag is an img.

        * html/parser/HTMLPreloadScanner.cpp:
        (WebCore::TokenPreloadScanner::StartTagScanner::processAttribute):
        (WebCore::TokenPreloadScanner::StartTagScanner::setUrlToLoad): Deleted.

2015-10-06  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Binding generator XXConstructor::finishCreation should take references as parameters
        https://bugs.webkit.org/show_bug.cgi?id=149838

        Reviewed by Darin Adler.

        Updated the binding generator so that XXConstructor::finishCreation
        takes a JSDOMGlobalObject& in lieu of a JSDOMGlobalObject*.

        Covered by rebased binding tests.

        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateConstructorDeclaration):
        (GenerateConstructorHelperMethods):
        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
        (WebCore::JSTestActiveDOMObjectConstructor::create):
        (WebCore::JSTestActiveDOMObjectConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestCallback.cpp:
        (WebCore::JSTestCallbackConstructor::create):
        (WebCore::JSTestCallbackConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::create):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
        (WebCore::JSTestCustomNamedGetterConstructor::create):
        (WebCore::JSTestCustomNamedGetterConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
        (WebCore::JSTestEventConstructorConstructor::create):
        (WebCore::JSTestEventConstructorConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
        (WebCore::JSTestEventTargetConstructor::create):
        (WebCore::JSTestEventTargetConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestException.cpp:
        (WebCore::JSTestExceptionConstructor::create):
        (WebCore::JSTestExceptionConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
        (WebCore::JSTestGenerateIsReachableConstructor::create):
        (WebCore::JSTestGenerateIsReachableConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        (WebCore::JSTestInterfaceConstructor::create):
        (WebCore::JSTestInterfaceConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
        (WebCore::JSTestJSBuiltinConstructorConstructor::create):
        (WebCore::JSTestJSBuiltinConstructorConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
        (WebCore::JSTestMediaQueryListListenerConstructor::create):
        (WebCore::JSTestMediaQueryListListenerConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
        (WebCore::JSTestNamedConstructorConstructor::create):
        (WebCore::JSTestNamedConstructorNamedConstructor::create):
        (WebCore::JSTestNamedConstructorConstructor::finishCreation):
        (WebCore::JSTestNamedConstructorNamedConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestNode.cpp:
        (WebCore::JSTestNodeConstructor::create):
        (WebCore::JSTestNodeConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
        (WebCore::JSTestNondeterministicConstructor::create):
        (WebCore::JSTestNondeterministicConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::JSTestObjConstructor::create):
        (WebCore::JSTestObjConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
        (WebCore::JSTestOverloadedConstructorsConstructor::create):
        (WebCore::JSTestOverloadedConstructorsConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
        (WebCore::JSTestOverrideBuiltinsConstructor::create):
        (WebCore::JSTestOverrideBuiltinsConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::create):
        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
        (WebCore::JSTestTypedefsConstructor::create):
        (WebCore::JSTestTypedefsConstructor::finishCreation):
        * bindings/scripts/test/JS/JSattribute.cpp:
        (WebCore::JSattributeConstructor::create):
        (WebCore::JSattributeConstructor::finishCreation):
        * bindings/scripts/test/JS/JSreadonly.cpp:
        (WebCore::JSreadonlyConstructor::create):
        (WebCore::JSreadonlyConstructor::finishCreation):

2015-10-06  Jiewen Tan  <jiewen_tan@apple.com>

        Fix crash in ApplyStyleCommand::applyRelativeFontStyleChange()
        https://bugs.webkit.org/show_bug.cgi?id=149300
        <rdar://problem/22747046>

        Reviewed by Chris Dumez.

        This is a merge of Blink r167845 and r194944:
        https://codereview.chromium.org/177093016
        https://codereview.chromium.org/1124863003

        Test: editing/style/apply-style-crash2.html
              editing/style/apply-style-crash3.html

        * editing/ApplyStyleCommand.cpp:
        (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
        The issue was that we would traverse the DOM tree past the beyondEnd 
        under some circumstances and thus NodeTraversal::next() would return 
        null unexpectedly. This CL adds a check to make sure startNode != beyondEnd 
        before traversing to avoid the problem.

        Besides that, this CL hardens changing font style over unknown elements.
        When adjusting the start node position of where to apply a font style
        command, check that we haven't stepped off the end.

        This CL also adds a few more assertions to catch similar issues 
        more easily in the future.

2015-10-06  Javier Fernandez  <jfernandez@igalia.com>

        [CSS Grid Layout] Don't need to reset auto-margins during grid items layout
        https://bugs.webkit.org/show_bug.cgi?id=149764

        Reviewed by Darin Adler.

        This patch implements a refactoring of the auto-margin alignment code for grid
        items so it uses start/end and before/after margin logic terms.

        I addition, it avoids resetting the auto-margin values, which requires an extra
        layout, before applying the alignment logic.

        No new tests because there is no behavior change.

        * rendering/RenderGrid.cpp:
        (WebCore::RenderGrid::computeMarginLogicalHeightForChild): Computing margins if child needs layout.
        (WebCore::RenderGrid::availableAlignmentSpaceForChildBeforeStretching):
        (WebCore::RenderGrid::updateAutoMarginsInRowAxisIfNeeded): Using start/end logical margins.
        (WebCore::RenderGrid::updateAutoMarginsInColumnAxisIfNeeded): Using before/after logical margins.
        (WebCore::RenderGrid::columnAxisOffsetForChild): Just added comment.
        (WebCore::RenderGrid::rowAxisOffsetForChild): Just added comment.

2015-10-06  Tim Horton  <timothy_horton@apple.com>

        Tile map shows a green rect when threaded scrolling is disabled
        https://bugs.webkit.org/show_bug.cgi?id=149716

        Reviewed by Darin Adler.

        Green is supposed to indicate that we're using the fast path; if threaded
        scrolling is disabled, we're definitely not doing that.

        * platform/graphics/TiledBacking.h:
        * platform/graphics/ca/TileController.cpp:
        (WebCore::TileController::TileController):
        * platform/graphics/ca/TileCoverageMap.cpp:
        (WebCore::TileCoverageMap::update):
        Default to the "we have no ScrollingCoordinator" purple indication;
        if a ScrollingCoordinator comes along it will setScrollingModeIndication
        and change it from this default.

2015-10-06  Zalan Bujtas  <zalan@apple.com>

        Remove redundant isComposited() function and replace
        hasLayer() && layer()->isComposited() with RenderObject::isComposited().
        https://bugs.webkit.org/show_bug.cgi?id=149846

        Reviewed by Simon Fraser.

        No change in functionality.

        * rendering/RenderLayerCompositor.cpp:
        (WebCore::RenderLayerCompositor::requiresCompositingForPlugin):
        (WebCore::RenderLayerCompositor::requiresCompositingForFrame):
        * rendering/RenderObject.cpp:
        (WebCore::RenderObject::repaintUsingContainer):
        * rendering/RenderThemeMac.mm:
        (WebCore::RenderThemeMac::paintSnapshottedPluginOverlay):
        * rendering/RenderView.cpp:
        (WebCore::rendererObscuresBackground):
        (WebCore::isComposited): Deleted.
        * rendering/RenderWidget.cpp:
        (WebCore::RenderWidget::setWidgetGeometry):

2015-10-06  Commit Queue  <commit-queue@webkit.org>

        Unreviewed, rolling out r190619.
        https://bugs.webkit.org/show_bug.cgi?id=149849

        borke the binding tests on iOS at least (Requested by youenn
        on #webkit).

        Reverted changeset:

        "Binding generator XXConstructor::finishCreation should take
        references as parameters"
        https://bugs.webkit.org/show_bug.cgi?id=149838
        http://trac.webkit.org/changeset/190619

2015-10-05  Wenson Hsieh  <wenson_hsieh@apple.com>

        Slider knobs should scale when rendering while zoomed
        https://bugs.webkit.org/show_bug.cgi?id=149835
        <rdar://problem/22897080>

        Reviewed by Darin Adler.

        Make slider knobs follow suit with the rest of the unscaled form controls
        by rendering to an offscreen buffer when the page is zoomed or scaled and
        then rendering a scaled version of the offscreen buffer onto the page.

        * platform/mac/ThemeMac.mm:
        (WebCore::drawCellOrFocusRingIntoRectWithView): Helper function for drawing
            cells and/or focus rings.
        (WebCore::ThemeMac::drawCellOrFocusRingWithViewIntoContext): Refactored to
            handle drawing slider knobs as well.
        * rendering/RenderThemeMac.mm:
        (WebCore::RenderThemeMac::paintSliderThumb): Use scaled rendering when necessary.

2015-10-06  Chris Dumez  <cdumez@apple.com>

        [Web IDL] 'length' property is wrong for variadic operations
        https://bugs.webkit.org/show_bug.cgi?id=149714

        Reviewed by Darin Adler.

        The value of the 'length' property was wrong for variadic operations:
        - https://heycam.github.io/webidl/#dfn-optional-argument

        The final argument of a variadic operation is considered to be an
        optional argument. Therefore, we should not account for it when
        computing the value of the 'length' property. This patch fixes WebKit's
        behavior to match the specification.

        Test: fast/dom/variadic-operations-length.html

        * bindings/scripts/CodeGeneratorJS.pm:
        (GetFunctionLength):
        * bindings/scripts/test/JS/JSTestObj.cpp:
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
        (WebCore::JSTestOverloadedConstructorsConstructor::finishCreation):

2015-10-06  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Binding generator should add builtin header for JSBuiltin attributes
        https://bugs.webkit.org/show_bug.cgi?id=149837

        Reviewed by Darin Adler.

        Ensured XXBuiltins.h header is included for builtin attributes.
        Renamed AddIncludesForJSBuiltinMethods as AddJSBuiltinIncludesIfNeeded.
        Test loop is done through all functions and attributes to handle conditional correctly.

        Covered by existing and added binding tests.

        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateImplementation):
        (AddJSBuiltinIncludesIfNeeded):
        * bindings/scripts/test/JS/JSTestObj.cpp:
        * bindings/scripts/test/ObjC/DOMTestObj.h:
        * bindings/scripts/test/ObjC/DOMTestObj.mm:
        * bindings/scripts/test/TestObj.idl:

2015-10-06  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Binding generator XXConstructor::finishCreation should take references as parameters
        https://bugs.webkit.org/show_bug.cgi?id=149838

        Reviewed by Darin Adler.

        Updated the binding generator so that XXConstructor::finishCreation
        takes a JSDOMGlobalObject& in lieu of a JSDOMGlobalObject*.

        Covered by rebased binding tests.

        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateConstructorDeclaration):
        (GenerateConstructorHelperMethods):
        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
        (WebCore::JSTestActiveDOMObjectConstructor::create):
        (WebCore::JSTestActiveDOMObjectConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestCallback.cpp:
        (WebCore::JSTestCallbackConstructor::create):
        (WebCore::JSTestCallbackConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::create):
        (WebCore::JSTestCustomConstructorWithNoInterfaceObjectConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
        (WebCore::JSTestCustomNamedGetterConstructor::create):
        (WebCore::JSTestCustomNamedGetterConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
        (WebCore::JSTestEventConstructorConstructor::create):
        (WebCore::JSTestEventConstructorConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
        (WebCore::JSTestEventTargetConstructor::create):
        (WebCore::JSTestEventTargetConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestException.cpp:
        (WebCore::JSTestExceptionConstructor::create):
        (WebCore::JSTestExceptionConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
        (WebCore::JSTestGenerateIsReachableConstructor::create):
        (WebCore::JSTestGenerateIsReachableConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        (WebCore::JSTestInterfaceConstructor::create):
        (WebCore::JSTestInterfaceConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
        (WebCore::JSTestJSBuiltinConstructorConstructor::create):
        (WebCore::JSTestJSBuiltinConstructorConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
        (WebCore::JSTestMediaQueryListListenerConstructor::create):
        (WebCore::JSTestMediaQueryListListenerConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
        (WebCore::JSTestNamedConstructorConstructor::create):
        (WebCore::JSTestNamedConstructorNamedConstructor::create):
        (WebCore::JSTestNamedConstructorConstructor::finishCreation):
        (WebCore::JSTestNamedConstructorNamedConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestNode.cpp:
        (WebCore::JSTestNodeConstructor::create):
        (WebCore::JSTestNodeConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
        (WebCore::JSTestNondeterministicConstructor::create):
        (WebCore::JSTestNondeterministicConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::JSTestObjConstructor::create):
        (WebCore::JSTestObjConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
        (WebCore::JSTestOverloadedConstructorsConstructor::create):
        (WebCore::JSTestOverloadedConstructorsConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
        (WebCore::JSTestOverrideBuiltinsConstructor::create):
        (WebCore::JSTestOverrideBuiltinsConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::create):
        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::finishCreation):
        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
        (WebCore::JSTestTypedefsConstructor::create):
        (WebCore::JSTestTypedefsConstructor::finishCreation):
        * bindings/scripts/test/JS/JSattribute.cpp:
        (WebCore::JSattributeConstructor::create):
        (WebCore::JSattributeConstructor::finishCreation):
        * bindings/scripts/test/JS/JSreadonly.cpp:
        (WebCore::JSreadonlyConstructor::create):
        (WebCore::JSreadonlyConstructor::finishCreation):

2015-10-06  Hunseop Jeong  <hs85.jeong@samsung.com>

        [Cairo] fast/canvas/canvas-imageSmoothingFoo tests failed after r190383.
        https://bugs.webkit.org/show_bug.cgi?id=149752

        Reviewed by Carlos Garcia Campos.

        CG's low interpolation quality setting is equivalent to most other browsers default or high settings.

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

2015-10-06  Daniel Bates  <dbates@webkit.org>

        Enable XSLT when building WebKit for iOS using the public iOS SDK
        https://bugs.webkit.org/show_bug.cgi?id=149827

        Reviewed by Alexey Proskuryakov.

        * Configurations/FeatureDefines.xcconfig:

2015-10-06  Brent Fulgham  <bfulgham@apple.com>

        [Win] Correct positioning error introduced in r190235
        https://bugs.webkit.org/show_bug.cgi?id=149631
        <rdar://problem/22635080>

        Reviewed by Simon Fraser.

        Covered by existing compositing tests:
          css3/filters/clipping-overflow-scroll-with-pixel-moving-effect-on.html
          fast/layers/no-clipping-overflow-hidden-added-after-transform.html
          fast/layers/no-clipping-overflow-hidden-added-after-transition.html
          fast/layers/no-clipping-overflow-hidden-hardware-acceleration.html
          transforms/2d/preserve3d-not-fixed-container.html

        * platform/graphics/ca/TileGrid.cpp:
        (TileGrid::platformCALayerPaintContents): No need to do this extra flipping step
        on Windows.
        * platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
        (PlatformCALayerWinInternal::displayCallback): We should always flip the
        coordinate system when drawing these layers on Windows.
        (shouldInvertBeforeDrawingContent): Deleted.
        * platform/graphics/ca/win/WebTiledBackingLayerWin.cpp:
        (WebTiledBackingLayerWin::displayCallback): We do not need to flip coordinates
        for these tiled layers; that's already accounted for in common tile drawing code.

2015-10-06  Emanuele Aina  <emanuele.aina@collabora.com>

        Fix ENABLE_OPENGL=OFF builds
        https://bugs.webkit.org/show_bug.cgi?id=146511

        Reviewed by Darin Adler.

        * platform/graphics/texmap/BitmapTextureGL.h:
        * platform/graphics/texmap/BitmapTextureGL.cpp:
        * platform/graphics/texmap/TextureMapperGL.h:
        * platform/graphics/texmap/TextureMapperGL.cpp:
        * platform/graphics/texmap/TextureMapperShaderProgram.h:
        * platform/graphics/texmap/TextureMapperShaderProgram.cpp:
        Fix TEXTURE_MAPPER_GL vs. TEXTURE_MAPPER guards to make sure that
        ENABLE_OPENGL=OFF only disables the GL-related parts.

2015-10-06  Alex Christensen  <achristensen@webkit.org>

        Fix Windows build after r190611.

        * PlatformWin.cmake:
        Forward headers from contentextensions.

2015-10-06  Hunseop Jeong  <hs85.jeong@samsung.com>

        Use modern for-loops in WebCore/html.
        https://bugs.webkit.org/show_bug.cgi?id=149662

        Reviewed by Darin Adler.

        No new tests because there is no behavior change.

        * html/DOMFormData.cpp:
        (WebCore::DOMFormData::DOMFormData):
        * html/EmailInputType.cpp:
        (WebCore::EmailInputType::typeMismatchFor):
        * html/FileInputType.cpp:
        (WebCore::FileInputType::receiveDroppedFiles):
        * html/FormController.cpp:
        (WebCore::FormControlState::serializeTo):
        (WebCore::FormControlState::deserialize):
        (WebCore::SavedFormState::serializeTo):
        (WebCore::SavedFormState::getReferencedFilePaths):
        (WebCore::FormController::createSavedFormStateMap):
        (WebCore::FormController::formElementsState):
        (WebCore::FormController::restoreControlStateIn):
        (WebCore::FormController::getReferencedFilePaths):
        * html/HTMLAnchorElement.cpp:
        (WebCore::hasNonEmptyBox):
        * html/HTMLCanvasElement.cpp:
        (WebCore::HTMLCanvasElement::~HTMLCanvasElement):
        (WebCore::HTMLCanvasElement::notifyObserversCanvasChanged):
        (WebCore::HTMLCanvasElement::reset):
        (WebCore::HTMLCanvasElement::paintsIntoCanvasBuffer):
        * html/HTMLFieldSetElement.cpp:
        (WebCore::HTMLFieldSetElement::length):
        * html/HTMLFormControlsCollection.cpp:
        (WebCore::firstNamedItem):
        * html/HTMLFormElement.cpp:
        (WebCore::HTMLFormElement::~HTMLFormElement):
        (WebCore::HTMLFormElement::formWouldHaveSecureSubmission):
        (WebCore::HTMLFormElement::removedFrom):
        (WebCore::HTMLFormElement::length):
        (WebCore::HTMLFormElement::submitImplicitly):
        (WebCore::HTMLFormElement::validateInteractively):
        (WebCore::HTMLFormElement::getTextFieldValues):
        (WebCore::HTMLFormElement::submit):
        (WebCore::HTMLFormElement::reset):
        (WebCore::HTMLFormElement::defaultButton):
        (WebCore::HTMLFormElement::checkInvalidControlsAndCollectUnhandled):
        (WebCore::HTMLFormElement::removeFromPastNamesMap):
        (WebCore::HTMLFormElement::documentDidResumeFromPageCache):
        * html/HTMLInputElement.cpp:
        (WebCore::parseAcceptAttribute):
        * html/HTMLKeygenElement.cpp:
        (WebCore::HTMLKeygenElement::HTMLKeygenElement):
        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::setMediaGroup):
        * html/HTMLOptionElement.cpp:
        (WebCore::HTMLOptionElement::index):
        * html/HTMLSelectElement.cpp:
        (WebCore::HTMLSelectElement::saveLastSelection):
        (WebCore::HTMLSelectElement::setActiveSelectionAnchorIndex):
        (WebCore::HTMLSelectElement::setActiveSelectionEndIndex):
        (WebCore::HTMLSelectElement::selectedIndex):
        (WebCore::HTMLSelectElement::deselectItemsWithoutValidation):
        (WebCore::HTMLSelectElement::saveFormControlState):
        (WebCore::HTMLSelectElement::restoreFormControlState):
        (WebCore::HTMLSelectElement::appendFormData):
        (WebCore::HTMLSelectElement::reset):
        * html/HTMLTextAreaElement.cpp:
        (WebCore::HTMLTextAreaElement::setDefaultValue):
        * html/InputType.cpp:
        (WebCore::populateInputTypeFactoryMap):
        * html/MediaController.cpp:
        (MediaController::duration):
        (MediaController::setCurrentTime):
        (MediaController::play):
        (MediaController::setPlaybackRate):
        (MediaController::setVolume):
        (MediaController::setMuted):
        (playbackStateWaiting):
        (MediaController::updateMediaElements):
        (MediaController::bringElementUpToSpeed):
        (MediaController::isBlocked):
        (MediaController::hasEnded):
        (MediaController::asyncEventTimerFired):
        (MediaController::clearPositionTimerFired):
        (MediaController::hasAudio):
        (MediaController::hasVideo):
        (MediaController::hasClosedCaptions):
        (MediaController::setClosedCaptionsVisible):
        (MediaController::supportsScanning):
        (MediaController::beginScrubbing):
        (MediaController::endScrubbing):
        (MediaController::canPlay):
        (MediaController::isLiveStream):
        (MediaController::hasCurrentSrc):
        (MediaController::returnToRealtime):
        * html/MediaFragmentURIParser.cpp:
        (WebCore::MediaFragmentURIParser::parseTimeFragment):
        * html/PublicURLManager.cpp:
        (WebCore::PublicURLManager::revoke):
        (WebCore::PublicURLManager::stop):
        * html/canvas/WebGLBuffer.cpp:
        (WebCore::WebGLBuffer::getCachedMaxIndex):
        (WebCore::WebGLBuffer::setCachedMaxIndex):
        (WebCore::WebGLBuffer::setTarget):
        * html/canvas/WebGLContextGroup.cpp:
        (WebCore::WebGLContextGroup::loseContextGroup):
        * html/canvas/WebGLDrawBuffers.cpp:
        (WebCore::WebGLDrawBuffers::satisfiesWebGLRequirements):
        * html/canvas/WebGLFramebuffer.cpp:
        (WebCore::WebGLFramebuffer::removeAttachmentFromBoundFramebuffer):
        (WebCore::WebGLFramebuffer::checkStatus):
        (WebCore::WebGLFramebuffer::deleteObjectImpl):
        (WebCore::WebGLFramebuffer::initializeAttachments):
        (WebCore::WebGLFramebuffer::drawBuffers):
        * html/canvas/WebGLRenderingContextBase.cpp:
        (WebCore::WebGLRenderingContextBase::~WebGLRenderingContextBase):
        (WebCore::WebGLRenderingContextBase::deleteTexture):
        * html/canvas/WebGLVertexArrayObject.cpp:
        (WebCore::WebGLVertexArrayObject::deleteObjectImpl):
        * html/canvas/WebGLVertexArrayObjectOES.cpp:
        (WebCore::WebGLVertexArrayObjectOES::deleteObjectImpl):
        * html/parser/AtomicHTMLToken.h:
        (WebCore::AtomicHTMLToken::initializeAttributes):
        * html/parser/HTMLConstructionSite.cpp:
        (WebCore::HTMLConstructionSite::mergeAttributesFromTokenIntoElement):
        * html/parser/HTMLFormattingElementList.cpp:
        (WebCore::HTMLFormattingElementList::ensureNoahsArkCondition):
        * html/parser/HTMLPreloadScanner.cpp:
        (WebCore::TokenPreloadScanner::StartTagScanner::processAttributes):
        * html/parser/XSSAuditor.cpp:
        (WebCore::semicolonSeparatedValueContainsJavaScriptURL):
        * html/shadow/ContentDistributor.cpp:
        (WebCore::ContentDistributor::distribute):
        (WebCore::ContentDistributor::invalidate):
        * html/shadow/MediaControlElements.cpp:
        (WebCore::MediaControlClosedCaptionsTrackListElement::updateDisplay):
        (WebCore::MediaControlClosedCaptionsTrackListElement::rebuildTrackListMenu):
        (WebCore::MediaControlTextTrackContainerElement::updateActiveCuesFontSize):
        * html/track/AudioTrackList.cpp:
        (AudioTrackList::getTrackById):
        * html/track/LoadableTextTrack.cpp:
        (WebCore::LoadableTextTrack::newCuesAvailable):
        (WebCore::LoadableTextTrack::newRegionsAvailable):
        * html/track/TextTrackCueList.cpp:
        (WebCore::TextTrackCueList::getCueById):
        (WebCore::TextTrackCueList::activeCues):
        * html/track/TextTrackList.cpp:
        (TextTrackList::getTrackIndexRelativeToRenderedTracks):
        (TextTrackList::invalidateTrackIndexesAfterTrack):
        * html/track/TrackListBase.cpp:
        (TrackListBase::isAnyTrackEnabled):
        * html/track/VideoTrackList.cpp:
        (VideoTrackList::getTrackById):

2015-10-06  Alex Christensen  <achristensen@webkit.org>

        Report error when main resource is blocked by content blocker
        https://bugs.webkit.org/show_bug.cgi?id=149719
        rdar://problem/21970595

        Reviewed by Brady Eidson.

        Test: http/tests/contentextensions/main-resource.html

        * English.lproj/Localizable.strings:
        * contentextensions/ContentExtensionActions.h:
        * contentextensions/ContentExtensionError.h:
        (WebCore::ContentExtensions::make_error_code):
        * contentextensions/ContentExtensionsBackend.cpp:
        (WebCore::ContentExtensions::ContentExtensionsBackend::globalDisplayNoneStyleSheet):
        (WebCore::ContentExtensions::ContentExtensionsBackend::processContentExtensionRulesForLoad):
        Instead of nulling out the ResourceRequest, processContentExtensionRulesForLoad 
        now returns a status indicating whether the request should be blocked.
        This is needed because the DocumentLoader needs a CachedResource with an error representing the blocking
        (WebCore::ContentExtensions::ContentExtensionsBackend::displayNoneCSSRule):
        * contentextensions/ContentExtensionsBackend.h:
        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::loadResource):
        * loader/DocumentLoader.cpp:
        (WebCore::DocumentLoader::startLoadingMainResource):
        Dispatch an error if the resource is blocked by a content blocker.
        * loader/EmptyClients.h:
        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::loadResourceSynchronously):
        (WebCore::FrameLoader::cancelledError):
        (WebCore::FrameLoader::blockedByContentBlockerError):
        (WebCore::FrameLoader::connectionProperties):
        * loader/FrameLoader.h:
        * loader/FrameLoaderClient.h:
        * loader/ResourceLoader.cpp:
        (WebCore::ResourceLoader::willSendRequestInternal):
        * loader/cache/CachedResourceLoader.cpp:
        (WebCore::CachedResourceLoader::requestResource):
        * page/UserContentController.cpp:
        (WebCore::UserContentController::removeAllUserContentExtensions):
        (WebCore::UserContentController::processContentExtensionRulesForLoad):
        (WebCore::UserContentController::actionsForResourceLoad):
        * page/UserContentController.h:
        * platform/efl/ErrorsEfl.cpp:
        (WebCore::blockedError):
        (WebCore::blockedByContentBlockerError):
        (WebCore::cannotShowURLError):
        * platform/efl/ErrorsEfl.h:
        * platform/gtk/ErrorsGtk.cpp:
        (WebCore::blockedError):
        (WebCore::blockedByContentBlockerError):
        (WebCore::cannotShowURLError):
        * platform/gtk/ErrorsGtk.h:

2015-10-06  Xabier Rodriguez Calvar  <calvaris@igalia.com>

        JSBuiltinConstructor must always add builtin header
        https://bugs.webkit.org/show_bug.cgi?id=149759

        Reviewed by Darin Adler.

        Covered by TestJSBuiltinConstructor.idl.

        * bindings/scripts/CodeGeneratorJS.pm:
        (AddIncludesForJSBuiltinMethods): Forces adding the builtin header when the JSBuiltinConstructor is present.
        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp: Expectation.

2015-10-05  Youenn Fablet  <youenn.fablet@crf.canon.fr>

        Migrate streams API to JS Builtins
        https://bugs.webkit.org/show_bug.cgi?id=147092

        Reviewed by Darin Adler.

        Moved ReadableStream implementation from C++ to JS Builtins.
        Created specific private constructors for ReadableStreamReader and ReadableStreamController.
        Added these constructors to  JSDOMWindowBase.
        Constructors are based on a template found in JSDOMConstructor which might serve to webidl-generated classes as well.

        Covered by existing tests.

        * CMakeLists.txt:
        * DerivedSources.make:
        * Modules/streams/ReadableStream.cpp: Removed.
        * Modules/streams/ReadableStream.h: Removed.
        * Modules/streams/ReadableStream.idl:
        * Modules/streams/ReadableStream.js:
        (strategy.size):
        (initializeReadableStream):
        (cancel):
        (getReader):
        (pipeTo):
        (tee):
        (locked):
        * Modules/streams/ReadableStreamController.h:
        * Modules/streams/ReadableStreamController.idl:
        * Modules/streams/ReadableStreamController.js: Added.
        (enqueue):
        (error):
        (close):
        (desiredSize):
        * Modules/streams/ReadableStreamInternals.js:
        (privateInitializeReadableStreamReader):
        (privateInitializeReadableStreamController):
        (isReadableStream):
        (isReadableStreamReader):
        (isReadableStreamController):
        (errorReadableStream):
        (requestReadableStreamPull):
        (getReadableStreamDesiredSize):
        (releaseReadableStreamReader):
        (cancelReadableStream):
        (finishClosingReadableStream):
        (closeReadableStream):
        (closeReadableStreamReader):
        (enqueueInReadableStream):
        (readFromReadableStreamReader):
        (invokeOrNoop):
        (promiseInvokeOrNoop):
        * Modules/streams/ReadableStreamReader.cpp: Removed.
        * Modules/streams/ReadableStreamReader.h:
        * Modules/streams/ReadableStreamReader.idl:
        * Modules/streams/ReadableStreamReader.js: Copied from Source/WebCore/Modules/streams/ReadableStream.js.
        (cancel):
        (read):
        (releaseLock):
        (closed):
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/JSBindingsAllInOne.cpp:
        * bindings/js/JSDOMConstructor.h: Added.
        (WebCore::JSBuiltinConstructor::create):
        (WebCore::JSBuiltinConstructor::createStructure):
        (WebCore::JSBuiltinConstructor::JSBuiltinConstructor):
        (WebCore::JSBuiltinConstructor::initializeProperties):
        (WebCore::JSBuiltinConstructor<JSClass>::finishCreation):
        (WebCore::JSBuiltinConstructor<JSClass>::construct):
        (WebCore::JSBuiltinConstructor<JSClass>::getConstructData):
        * bindings/js/JSDOMWindowBase.cpp:
        (WebCore::JSDOMWindowBase::finishCreation):
        * bindings/js/JSReadableStreamControllerCustom.cpp: Removed.
        * bindings/js/JSReadableStreamCustom.cpp: Removed.
        * bindings/js/JSReadableStreamPrivateConstructors.cpp: Added.
        (WebCore::constructJSReadableStreamController):
        (WebCore::constructJSReadableStreamReader):
        (WebCore::JSBuiltinConstructor<JSReadableStreamReader>::createJSObject):
        (WebCore::JSBuiltinConstructor<JSReadableStreamController>::createJSObject):
        (WebCore::JSBuiltinReadableStreamReaderPrivateConstructor::createInitializeFunction):
        (WebCore::JSBuiltinReadableStreamControllerPrivateConstructor::createInitializeFunction):
        (WebCore::createReadableStreamReaderPrivateConstructor):
        (WebCore::createReadableStreamControllerPrivateConstructor):
        * bindings/js/JSReadableStreamPrivateConstructors.h: Added.
        * bindings/js/JSReadableStreamReaderCustom.cpp: Removed.
        * bindings/js/ReadableJSStream.cpp: Removed.
        * bindings/js/ReadableJSStream.h: Removed.
        * bindings/js/WebCoreBuiltinNames.h: Added.
        (WebCore::WebCoreBuiltinNames::WebCoreBuiltinNames):
        * bindings/js/WebCoreJSBuiltins.cpp:
        * bindings/js/WebCoreJSClientData.h:
        (WebCore::WebCoreJSClientData::WebCoreJSClientData):
        (WebCore::WebCoreJSClientData::builtinNames):
        (WebCore::WebCoreJSClientData::readableStreamControllerBuiltins):
        (WebCore::WebCoreJSClientData::readableStreamReaderBuiltins):

2015-10-05  Chris Dumez  <cdumez@apple.com>

        data: URLs should not be preloaded
        https://bugs.webkit.org/show_bug.cgi?id=149829

        Reviewed by Ryosuke Niwa.

        Update the HTMLPreloadScanner so that data: URLs do not get preloaded.
        There is no need as the data is already available.

        Test: fast/preloader/image-data-url.html

        * html/parser/HTMLPreloadScanner.cpp:
        (WebCore::TokenPreloadScanner::StartTagScanner::shouldPreload):

2015-10-05  Jer Noble  <jer.noble@apple.com>

        [iOS] REGRESSION(r190434): Media continues to play when locking screen
        https://bugs.webkit.org/show_bug.cgi?id=149822

        Reviewed by Brent Fulgham.

        In MediaSessionManagerIOS.mm, both -applicationWillEnterForeground: and
        -applicationDidBecomeActive: called
        PlatformMediaSessionManager::applicationWillEnterForeground(), leading to the
        PlatformMediaSession's m_interruptionCount becoming increasingly unbalanced.

        Rename PlatformMediaSessionManager::applicationWillEnterForeground() to
        applicationDidEnterForeground() to more correctly reflect when this notification will be
        called. Add a new method, MediaSessionManagerIOS::applicationWillEnterForeground(bool),
        whose paramater is whether the screen was locked. This allows the beginInterruption() and
        endInterruption() methods to be correctly balanced.

        Drive-by fix: remove the unimplemented declarations for application{will,did}Enter{Fore,Back}ground()
        from PlatformMediaSession.h.

        * platform/audio/PlatformMediaSession.h:
        * platform/audio/PlatformMediaSessionManager.cpp:
        (WebCore::PlatformMediaSessionManager::applicationDidEnterForeground):
        (WebCore::PlatformMediaSessionManager::applicationWillEnterForeground): Deleted.
        * platform/audio/PlatformMediaSessionManager.h:
        * platform/audio/ios/MediaSessionManagerIOS.h:
        * platform/audio/ios/MediaSessionManagerIOS.mm:
        (WebCore::MediaSessionManageriOS::applicationDidEnterBackground):
        (WebCore::MediaSessionManageriOS::applicationWillEnterForeground):
        (-[WebMediaSessionHelper applicationWillEnterForeground:]):
        (-[WebMediaSessionHelper applicationDidBecomeActive:]):
        * testing/Internals.cpp:
        (WebCore::Internals::applicationDidEnterForeground):
        (WebCore::Internals::applicationWillEnterForeground): Deleted.
        * testing/Internals.h:
        * testing/Internals.idl:

2015-10-05  Alex Christensen  <achristensen@webkit.org>

        Invalid CSS Selector for Content Blockers invalidates others
        https://bugs.webkit.org/show_bug.cgi?id=148446
        rdar://problem/22918235

        Reviewed by Benjamin Poulain.

        Test: http/tests/contentextensions/invalid-selector.html

        * contentextensions/ContentExtensionParser.cpp:
        (WebCore::ContentExtensions::loadTrigger):
        (WebCore::ContentExtensions::isValidSelector):
        (WebCore::ContentExtensions::loadAction):
        (WebCore::ContentExtensions::loadRule):
        Add a check to see if a selector is valid before adding it.

2015-10-05  Jiewen Tan  <jiewen_tan@apple.com>

        CSSGradientValue should check whether gradientLength is zero or not.
        https://bugs.webkit.org/show_bug.cgi?id=149373
        <rdar://problem/22771418>

        Reviewed by Darin Adler.

        This is a merge of Blink r158220,
        https://chromiumcodereview.appspot.com/24350008

        Test: fast/gradients/css3-repeating-radial-gradients-crash.html

        * css/CSSGradientValue.cpp:
        (WebCore::CSSGradientValue::addStops):
        Check whether gradientLength > 0 before using it as denominator.

2015-10-05  Dean Jackson  <dino@apple.com>

        EXT_texture_filter_anisotropic extension exposed with WEBKIT_ prefix
        https://bugs.webkit.org/show_bug.cgi?id=149765
        <rdar://problem/22983722>

        Reviewed by Beth Dakin.

        We can now remove the WEBKIT_ prefix from this extension.

        Test: fast/canvas/webgl/unprefixed-anisotropic-extension.html

        * html/canvas/WebGL2RenderingContext.cpp: Support the prefixed and unprefixed form.
        (WebCore::WebGL2RenderingContext::getExtension):
        * html/canvas/WebGLRenderingContext.cpp:
        (WebCore::WebGLRenderingContext::getExtension):
        (WebCore::WebGLRenderingContext::getSupportedExtensions):

2015-10-05  Dean Jackson  <dino@apple.com>

        Reference cycles during SVG dependency invalidation
        https://bugs.webkit.org/show_bug.cgi?id=149824
        <rdar://problem/22771412>

        Reviewed by Tim Horton.

        Detect any reference cycles as we are invalidating.

        This is mostly a merge of the following Blink commit:
        https://chromium.googlesource.com/chromium/blink/+/a4bc83453bda89823b672877dc02247652a02d51

        Test: svg/custom/reference-cycle.svg

        * rendering/svg/RenderSVGResource.cpp:
        (WebCore::removeFromCacheAndInvalidateDependencies): Keep around a hash
        table of dependencies, so that we can detect if an element is already
        present before marking it.

2015-10-05  Jiewen Tan  <jiewen_tan@apple.com>

        Fix null pointer dereference in WebSocket::connect()        
        https://bugs.webkit.org/show_bug.cgi?id=149311
        <rdar://problem/22748858>

        Reviewed by Chris Dumez.

        This is a merge of Blink r187441,
        https://codereview.chromium.org/785933005

        Test: http/tests/websocket/construct-in-detached-frame.html

        * Modules/websockets/WebSocket.cpp:
        (WebCore::WebSocket::connect):
        Call function implemented below instead of duplicating the code.
        * page/ContentSecurityPolicy.cpp:
        (WebCore::ContentSecurityPolicy::shouldBypassMainWorldContentSecurityPolicy):
        * page/ContentSecurityPolicy.h:
        Factor the logic to check shouldBypassMainWorldContentSecurityPolicy into 
        a function in this class. Check Frame pointers are not null before getting 
        shouldBypassMainWorldContentSecurityPolicy via those pointers.
        * page/EventSource.cpp:
        (WebCore::EventSource::create):
        This got fixed as a bonus.
        * xml/XMLHttpRequest.cpp:
        (WebCore::XMLHttpRequest::open):
        This got fixed as a bonus too.

2015-10-05  Beth Dakin  <bdakin@apple.com>

        WebCore::IOSurface should ask the IOSurface for the pixel format instead of 
        caching it
        https://bugs.webkit.org/show_bug.cgi?id=149820
        -and corresponding-
        rdar://problem/22976230

        Reviewed by Tim Horton.

        Also there is no reason to make YUV be iOS only, so this patch removes those 
        PLATFORM checks.

        * platform/graphics/cocoa/IOSurface.h:
        * platform/graphics/cocoa/IOSurface.mm:
        (IOSurface::IOSurface):
        (IOSurface::format):
        * platform/spi/cocoa/IOSurfaceSPI.h:

2015-10-02  Ryosuke Niwa  <rniwa@webkit.org>

        ShadowRoot with leading or trailing white space cause a crash
        https://bugs.webkit.org/show_bug.cgi?id=149782

        Reviewed by Chris Dumez.

        Fixed the crash by adding a null pointer check since a TextNode that appears as a direct child
        of a ShadowRoot doesn't have a parent element.

        Test: fast/shadow-dom/shadow-root-with-child-whitespace-text-crash.html

        * style/RenderTreePosition.cpp:
        (WebCore::RenderTreePosition::previousSiblingRenderer):

2015-10-05  Beth Dakin  <bdakin@apple.com>

        Build fix. 

        * platform/spi/cocoa/IOSurfaceSPI.h:

2015-10-05  Beth Dakin  <bdakin@apple.com>

        Unreviewed build fix.

        * platform/spi/cocoa/IOSurfaceSPI.h:

2015-10-05  Brady Eidson  <beidson@apple.com>

        Modernize IDBRequest::ReadyState into an enum class.
        https://bugs.webkit.org/show_bug.cgi?id=149817

        Reviewed by Alex Christensen.

        No new tests (Refactor, no behavior change).

        * Modules/indexeddb/IDBRequest.h:
        
        * Modules/indexeddb/legacy/LegacyOpenDBRequest.cpp:
        (WebCore::LegacyOpenDBRequest::shouldEnqueueEvent):
        
        * Modules/indexeddb/legacy/LegacyRequest.cpp:
        (WebCore::LegacyRequest::LegacyRequest):
        (WebCore::LegacyRequest::result):
        (WebCore::LegacyRequest::error):
        (WebCore::LegacyRequest::errorCode):
        (WebCore::LegacyRequest::readyState):
        (WebCore::LegacyRequest::markEarlyDeath):
        (WebCore::LegacyRequest::abort):
        (WebCore::LegacyRequest::setCursorDetails):
        (WebCore::LegacyRequest::setPendingCursor):
        (WebCore::LegacyRequest::setResultCursor):
        (WebCore::LegacyRequest::finishCursor):
        (WebCore::LegacyRequest::shouldEnqueueEvent):
        (WebCore::LegacyRequest::stop):
        (WebCore::LegacyRequest::dispatchEvent):
        (WebCore::LegacyRequest::transactionDidFinishAndDispatch):
        (WebCore::LegacyRequest::enqueueEvent):
        * Modules/indexeddb/legacy/LegacyRequest.h:

2015-10-05  Jiewen Tan  <jiewen_tan@apple.com>

        Cleaning up after revision 190339
        https://bugs.webkit.org/show_bug.cgi?id=149732

        Reviewed by Myles C. Maxfield.

        * xml/XSLStyleSheet.h:
        * xml/XSLStyleSheetLibxslt.cpp:
        (WebCore::XSLStyleSheet::compileStyleSheet):

2015-10-05  Beth Dakin  <bdakin@apple.com>

        Errant space!!
        * platform/graphics/cocoa/IOSurface.mm:
        (IOSurface::releaseGraphicsContext):
        (IOSurface::convertToFormat):

2015-10-05  Beth Dakin  <bdakin@apple.com>

        Compress snapshots on iOS
        https://bugs.webkit.org/show_bug.cgi?id=149814
        -and corresponding-
        rdar://problem/22976230

        Reviewed by Simon Fraser.

        Though the default is still RGBA, it is now possible to create an IOSurface 
        that uses the YUV422 pixel format.
        * platform/graphics/cocoa/IOSurface.h:
        * platform/graphics/cocoa/IOSurface.mm:
        (IOSurface::surfaceFromPool):
        (IOSurface::create):
        (IOSurface::createFromImage):
        (IOSurface::IOSurface):
        (IOSurface::releaseGraphicsContext):

        In order to have a YUV IOSurface, we actually have to create an RGBA surface 
        first and then convert it to YUV, so this class method will handle that.
        (IOSurface::convertToFormat):

        Necessary SPI.
        * platform/spi/cocoa/IOSurfaceSPI.h:

2015-10-05  Zalan Bujtas  <zalan@apple.com>

        Mark the line dirty when RenderQuote's text changes.
        https://bugs.webkit.org/show_bug.cgi?id=149784
        rdar://problem/22558169

        Reviewed by Antti Koivisto.

        When quotation mark changes ( " -> ' or empty string), we
        need to mark the line dirty to ensure its content gets laid out properly.

        Test: fast/inline/quotation-text-changes-dynamically.html

        * rendering/RenderQuote.cpp:
        (WebCore::quoteTextRenderer):
        (WebCore::RenderQuote::updateText):
        (WebCore::fragmentChild): Deleted.

2015-10-03  Filip Pizlo  <fpizlo@apple.com>

        Allow an object's marking state to track The Three Colors
        https://bugs.webkit.org/show_bug.cgi?id=149654

        Reviewed by Geoffrey Garen.

        No new tests because no new behavior.

        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateImplementation):

2015-10-05  Katlyn Graff  <kgraff@apple.com>

        Update setImageSmoothingQuality for additional reviews.
        https://bugs.webkit.org/show_bug.cgi?id=149541

        Reviewed by Chris Dumez.

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

2015-10-05  Andreas Kling  <akling@apple.com>

        Remove unused HistoryItem::targetItem()
        <https://webkit.org/b/149803>

        Reviewed by Anders Carlsson.

        This is ancient code with no remaining clients since 2010 (r53650)

        * history/HistoryItem.cpp:
        (WebCore::HistoryItem::findTargetItem): Deleted.
        (WebCore::HistoryItem::targetItem): Deleted.
        * history/HistoryItem.h:

2015-10-05  Myles C. Maxfield  <mmaxfield@apple.com>

        Unprefix -webkit-font-feature-settings
        https://bugs.webkit.org/show_bug.cgi?id=149722

        Reviewed by Sam Weinig.

        * css/CSSComputedStyleDeclaration.cpp:
        (WebCore::ComputedStyleExtractor::propertyValue):
        * css/CSSParser.cpp:
        (WebCore::CSSParser::parseValue):
        (WebCore::CSSParser::parseFontFeatureSettings):
        * css/CSSPropertyNames.in:
        * css/CSSValueKeywords.in:
        * css/StyleBuilderCustom.h:
        (WebCore::StyleBuilderCustom::applyInitialFontFeatureSettings):
        (WebCore::StyleBuilderCustom::applyInheritFontFeatureSettings):
        (WebCore::StyleBuilderCustom::applyInitialWebkitFontFeatureSettings): Deleted.
        (WebCore::StyleBuilderCustom::applyInheritWebkitFontFeatureSettings): Deleted.

2015-10-05  Zan Dobersek  <zdobersek@igalia.com>

        [GStreamer] Replace uses of std::bind() with lambdas
        https://bugs.webkit.org/show_bug.cgi?id=149802

        Reviewed by Carlos Garcia Campos.

        Instead of std::bind(), use C++ lambdas to create std::function<>
        wrappers in GStreamer-related class implementations.

        Ref-counted classes are protected by capturing a RefPtr object.
        GstObject-derived objects are protected by capturing a GRefPtr object.
        Necessary specializations for WebKitVideoSink and WebKitWebSrc are added.

        * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
        (WebCore::AudioFileReader::createBus):
        * platform/graphics/gstreamer/GRefPtrGStreamer.cpp:
        (WTF::adoptGRef):
        (WTF::refGPtr<WebKitVideoSink>):
        (WTF::derefGPtr<WebKitVideoSink>):
        (WTF::refGPtr<WebKitWebSrc>):
        (WTF::derefGPtr<WebKitWebSrc>):
        * platform/graphics/gstreamer/GRefPtrGStreamer.h:
        * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
        (WebCore::InbandTextTrackPrivateGStreamer::handleSample):
        (WebCore::InbandTextTrackPrivateGStreamer::streamChanged):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
        (WebCore::MediaPlayerPrivateGStreamer::videoChanged):
        (WebCore::MediaPlayerPrivateGStreamer::videoCapsChanged):
        (WebCore::MediaPlayerPrivateGStreamer::audioChanged):
        (WebCore::MediaPlayerPrivateGStreamer::textChanged):
        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
        (WebCore::MediaPlayerPrivateGStreamerBase::volumeChanged):
        (WebCore::MediaPlayerPrivateGStreamerBase::muteChanged):
        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
        (WebCore::TrackPrivateBaseGStreamer::activeChanged):
        (WebCore::TrackPrivateBaseGStreamer::tagsChanged):
        * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
        (webkitVideoSinkRender):
        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
        (webKitWebSrcChangeState):
        (webKitWebSrcNeedDataCb):
        (webKitWebSrcEnoughDataCb):
        (webKitWebSrcSeekDataCb):

2015-10-05  Andreas Kling  <akling@apple.com>

        Remove unused HistoryItem::parent
        <https://webkit.org/b/149803>

        Reviewed by Anders Carlsson.

        Remove the effectively-unused "parent" field from HistoryItem.
        This also allows us to get rid of a HistoryItem constructor.

        * history/HistoryItem.cpp:
        (WebCore::HistoryItem::HistoryItem): Deleted.
        (WebCore::HistoryItem::reset): Deleted.
        (WebCore::HistoryItem::parent): Deleted.
        (WebCore::HistoryItem::setParent): Deleted.
        * history/HistoryItem.h:
        (WebCore::HistoryItem::create): Deleted.
        * loader/HistoryController.cpp:
        (WebCore::HistoryController::initializeItem): Deleted.

2015-10-05  Zan Dobersek  <zdobersek@igalia.com>

        GLContext should control ownership of context-related objects
        https://bugs.webkit.org/show_bug.cgi?id=149794

        Reviewed by Martin Robinson.

        Creation of GLContext objects can depend on various platform-specific
        objects like native window representations. Since these objects are
        used solely for the GLContext purposes, it would make sense to allow
        GLContext to provide an extensible way to impose ownership on these
        objects and control their lifetime.

        GLContext::Data is declared with a defaulted virtual destructor.
        Users of these implementations can declare classes that derive from
        GLContext::Data and store context-related objects in instances of the
        derived class, and ensure that these objects are properly cleaned up
        when GLContext destroys the Data object.

        The GLContext::Data object is managed through a protected
        std::unique_ptr<> member in the GLContext class. For now the member
        is only set in GLContextEGL::createWindowContext() and is destroyed
        during the GLContext destruction.

        The local OffscreenContextData class in
        PlatformDisplayWayland::createSharingGLContext() derives from
        GLContext::Data and is used to store the wl_surface and
        EGLNativeWindowType (aka wl_egl_window) objects for offscreen
        GLContexts under the Wayland platform that are used for the sharing
        context and WebGL, effectively avoiding the leak that would further
        propagate problems into the compositor and the graphics library.
        (Such offscreen contexts are actually mimicked via a 1x1px
        wl_egl_window object that acts as a dummy base for the related
        wl_surface object).

        * platform/graphics/GLContext.h:
        * platform/graphics/egl/GLContextEGL.cpp:
        (WebCore::GLContextEGL::createWindowContext):
        * platform/graphics/egl/GLContextEGL.h:
        * platform/graphics/wayland/PlatformDisplayWayland.cpp:
        (WebCore::PlatformDisplayWayland::createSharingGLContext):

2015-10-05  Zan Dobersek  <zdobersek@igalia.com>

        Make gdk.h inclusion in FontPlatformDataFreeType.cpp properly GTK-specific
        https://bugs.webkit.org/show_bug.cgi?id=149793

        Reviewed by Carlos Garcia Campos.

        * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
        Instead of including <gdk/gdk.h> header for all platforms but EFL, only
        include it for the GTK platform, since no other platform depends on the
        GDK library.

2015-10-03  Ricky Mondello  <rmondello@apple.com>

        "Plug-in is blocked" message doesn't draw correctly
        https://bugs.webkit.org/show_bug.cgi?id=149741
        <rdar://problem/22920949>

        Patch by Conrad Shultz and Ricky Mondello.

        Reviewed by Anders Carlsson.

        No new tests are added.

        Add PluginData API to check whether a MIME type is supported, regardless of plug-in visibility.

        * plugins/PluginData.cpp:
        (WebCore::PluginData::getWebVisibleMimesAndPluginIndices): Adopt getMimesAndPluginIndiciesForPlugins.
        (WebCore::PluginData::getMimesAndPluginIndices): Added.
        (WebCore::PluginData::getMimesAndPluginIndiciesForPlugins): Essentially factored out of
            getWebVisibleMimesAndPluginIndices.
        (WebCore::PluginData::supportsMimeType): Added. Somewhat similar to preexisting supportsWebVisibleMimeType.
        * plugins/PluginData.h: Declare supportsMimeType.

2015-10-02  Antti Koivisto  <antti@apple.com>

        Inserting a child to a slot assigned node doesn't trigger repaint
        https://bugs.webkit.org/show_bug.cgi?id=149739

        Reviewed by Ryosuke Niwa.

        Test: fast/shadow-dom/insert-child-to-assigned-node.html

        * dom/Node.cpp:
        (WebCore::Node::derefEventTarget):
        (WebCore::traverseStyleParent):
        (WebCore::traverseFirstStyleParent):
        (WebCore::Node::updateAncestorsForStyleRecalc):

            Traverse in style parent order.

2015-10-02  Joseph Pecoraro  <pecoraro@apple.com>

        Unreviewed, rolling out r190520, some tests assert / crash.

        * ForwardingHeaders/heap/HeapObserver.h: Removed.
        * ForwardingHeaders/inspector/agents/InspectorHeapAgent.h: Removed.
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * inspector/InspectorController.cpp:
        (WebCore::InspectorController::InspectorController): Deleted.
        (WebCore::InspectorController::vm): Deleted.
        * inspector/InspectorController.h:
        * inspector/WorkerInspectorController.cpp:
        (WebCore::WorkerInspectorController::vm): Deleted.
        * inspector/WorkerInspectorController.h:

2015-10-02  Joseph Pecoraro  <pecoraro@apple.com>

        Web Inspector: Include Garbage Collection Event in Timeline
        https://bugs.webkit.org/show_bug.cgi?id=142510

        Reviewed by Geoffrey Garen.

        Tests: inspector/heap/garbageCollected.html
               inspector/heap/gc.html

        * ForwardingHeaders/heap/HeapObserver.h: Added.
        * ForwardingHeaders/inspector/agents/InspectorHeapAgent.h: Added.
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        Forwarding headers.

        * inspector/InspectorController.cpp:
        (WebCore::InspectorController::InspectorController):
        (WebCore::InspectorController::vm):
        * inspector/InspectorController.h:
        * inspector/WorkerInspectorController.cpp:
        (WebCore::WorkerInspectorController::vm):
        * inspector/WorkerInspectorController.h:
        Implement InspectorEnvironment::vm and create a Heap agent for the
        Page inspector controller.

2015-10-02  Jer Noble  <jer.noble@apple.com>

        [MSE] Browser crashes when appending invalid data to MSE source buffer
        https://bugs.webkit.org/show_bug.cgi?id=149689

        Reviewed by Darin Adler.

        Test: media/media-source/media-source-stpp-crash.html

        Bail out early (as specced) after disconnecting the SourceBuffer from its MediaSource.

        * Modules/mediasource/SourceBuffer.cpp:
        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment):

2015-10-02  Simon Fraser  <simon.fraser@apple.com>

        ASSERTION FAILED: param >= 0 in AnimationBase::updateStateMachine()
        https://bugs.webkit.org/show_bug.cgi?id=149737
        rdar://problem/19017465

        Reviewed by Dean Jackson.

        CoreAnimation can give us an animation beginTime that is slightly into the future,
        which results in 'param' here being < 0, so relax the assertion slightly.
        
        Fixes lots of assertions running iOS WK2 layout tests.

        * page/animation/AnimationBase.cpp:
        (WebCore::AnimationBase::updateStateMachine):

2015-10-02  Per Arne Vollan  <peavo@outlook.com>

        [WinCairo] Fix linker warnings.
        https://bugs.webkit.org/show_bug.cgi?id=149754

        Reviewed by Alex Christensen.

        Avoid compiling these files twice, they are already included in
        RenderingAllInOne.cpp.

        * PlatformWinCairo.cmake:

2015-10-02  Alex Christensen  <achristensen@webkit.org>

        Reloading without content blockers doesn't apply to res