WebKit-https.git
4 years agoMove ImageBuffer:clip() into GraphicsContextCG
simon.fraser@apple.com [Thu, 15 Oct 2015 17:20:10 +0000 (17:20 +0000)]
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):

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

4 years ago[Win] Unreviewed gardenining after r190816.
bfulgham@apple.com [Thu, 15 Oct 2015 16:54:49 +0000 (16:54 +0000)]
[Win] Unreviewed gardenining after r190816.

Update Windows expectation to match new mac test expectation.

* platform/win/svg/custom/simple-text-double-shadow-expected.txt:

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

4 years agoUnreviewed fix of a test after r190687.
rniwa@webkit.org [Thu, 15 Oct 2015 16:44:33 +0000 (16:44 +0000)]
Unreviewed fix of a test after r190687.

* tests/admin-regenerate-manifest.js:

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

4 years agoModern IDB: Add basic transaction committing.
beidson@apple.com [Thu, 15 Oct 2015 16:41:30 +0000 (16:41 +0000)]
Modern IDB: Add basic transaction committing.
https://bugs.webkit.org/show_bug.cgi?id=150147

Reviewed by Alex Christensen.

Source/WebCore:

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:

LayoutTests:

* storage/indexeddb/modern/opendatabase-versions-expected.txt: Added.
* storage/indexeddb/modern/opendatabase-versions.html: Added.

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

4 years ago[iOS] DOM click event may not be dispatched when page has :active style and <input...
dbates@webkit.org [Thu, 15 Oct 2015 16:08:24 +0000 (16:08 +0000)]
[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.

Source/WebCore:

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.

LayoutTests:

Add a test to ensure that a DOM click event is dispatched to an element in a subframe on a page
with a search field and that specifies a CSS :active pseudo-class that changes the tap highlight
color.

Additionally, add tests to ensure we update the cancel button visibility whenever the visibility
of the search field changes.

* fast/events/can-click-element-on-page-with-active-pseudo-class-and-search-field-expected.txt: Added.
* fast/events/can-click-element-on-page-with-active-pseudo-class-and-search-field.html: Added.
* fast/forms/search/search-cancel-button-visible-when-input-becomes-disabled-expected.html: Added.
* fast/forms/search/search-cancel-button-visible-when-input-becomes-disabled.html: Added.
* fast/forms/search/search-cancel-button-visible-when-input-becomes-readonly-expected.html: Added.
* fast/forms/search/search-cancel-button-visible-when-input-becomes-readonly.html: Added.
* fast/forms/search/search-cancel-in-formerly-invisible-element-expected.html: Added.
* fast/forms/search/search-cancel-in-formerly-invisible-element.html: Added.
* fast/forms/search/search-cancel-toggle-visibility-initially-hidden-expected.html: Added.
* fast/forms/search/search-cancel-toggle-visibility-initially-hidden.html: Added.
* fast/forms/search/search-cancel-toggle-visibility-initially-visible-expected.html: Added.
* fast/forms/search/search-cancel-toggle-visibility-initially-visible.html: Added.

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

4 years agoImplement iterator for traversing composed ancestors
antti@apple.com [Thu, 15 Oct 2015 15:12:39 +0000 (15:12 +0000)]
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.

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

4 years agoUnreviewed, Update my email address.
eunmi15.lee@samsung.com [Thu, 15 Oct 2015 14:54:52 +0000 (14:54 +0000)]
Unreviewed, Update my email address.

* Scripts/webkitpy/common/config/contributors.json:

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

4 years ago[ES6] Class expression should have lexical environment that has itself as an imutable...
utatane.tea@gmail.com [Thu, 15 Oct 2015 14:35:12 +0000 (14:35 +0000)]
[ES6] Class expression should have lexical environment that has itself as an imutable binding
https://bugs.webkit.org/show_bug.cgi?id=150089

Reviewed by Geoffrey Garen.

According to ES6 spec, class expression has its own lexical environment that holds itself
as an immutable binding[1] (section 14.5.14 step 2, 3, 4, 23)

As a result, even if the binding declared in the outer scope is overridden, methods inside
class expression can refer its class by the class name.

[1]: http://ecma-international.org/ecma-262/6.0/#sec-runtime-semantics-classdefinitionevaluation

* bytecompiler/NodesCodegen.cpp:
(JSC::ClassExprNode::emitBytecode):
* parser/ASTBuilder.h:
(JSC::ASTBuilder::createClassExpr):
* parser/NodeConstructors.h:
(JSC::ClassExprNode::ClassExprNode):
* parser/Nodes.h:
* parser/Parser.cpp:
(JSC::Parser<LexerType>::parseClass):
* parser/SyntaxChecker.h:
(JSC::SyntaxChecker::createClassExpr):
* tests/es6.yaml:
* tests/stress/class-expression-generates-environment.js: Added.
(shouldBe):
(shouldThrow):
(prototype.method):
(staticMethod):
(A.prototype.method):
(A.staticMethod):
(A):
* tests/stress/class-expression-should-be-tdz-in-heritage.js: Added.
(shouldThrow):
(shouldThrow.A):

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

4 years ago[GTK] Test WebKit2.RestoreSessionStateContainingFormData fails
carlosgc@webkit.org [Thu, 15 Oct 2015 08:18:58 +0000 (08:18 +0000)]
[GTK] Test WebKit2.RestoreSessionStateContainingFormData fails
https://bugs.webkit.org/show_bug.cgi?id=84960

Reviewed by Žan Doberšek.

Source/WebKit2:

Add a cross-platform implementation to LegacySessionStateCodingNone
using the new SessionState, so that non mac ports can make unit
tests that use the legacy session state coding pass.

* UIProcess/LegacySessionStateCodingNone.cpp:
(WebKit::encodeLegacySessionState):
(WebKit::decodeLegacySessionState):
(WebKit::encodeLegacySessionHistoryEntryData): Deleted.
(WebKit::decodeLegacySessionHistoryEntryData): Deleted.

Tools:

* Scripts/run-gtk-tests:
(TestRunner): Unskip tests using SessionState.
* TestWebKitAPI/PlatformGTK.cmake: Add
WKPageCopySessionStateWithFiltering test.

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

4 years agoUnreviewed. Fix wrong #ifdef added in r190615.
carlosgc@webkit.org [Thu, 15 Oct 2015 08:16:53 +0000 (08:16 +0000)]
Unreviewed. Fix wrong #ifdef added in r190615.

This disabled accelerated compositing unconditionally.

* UIProcess/gtk/WebPreferencesGtk.cpp:
(WebKit::WebPreferences::platformInitializeStore):

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

4 years agoUnreviewed GTK+ gardening. Unskip several tests that are passing now.
carlosgc@webkit.org [Thu, 15 Oct 2015 07:53:16 +0000 (07:53 +0000)]
Unreviewed GTK+ gardening. Unskip several tests that are passing now.

* platform/gtk/TestExpectations:

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

4 years ago[GTK] Missing return value on TestWebExtensions.cpp:193
carlosgc@webkit.org [Thu, 15 Oct 2015 07:51:17 +0000 (07:51 +0000)]
[GTK] Missing return value on TestWebExtensions.cpp:193
https://bugs.webkit.org/show_bug.cgi?id=149755

Unreviewed. Add missing return value.

* TestWebKitAPI/Tests/WebKit2Gtk/TestWebExtensions.cpp:
(permissionRequestCallback):

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

4 years ago[ES6] Class method should not declare any variables to upper scope.
utatane.tea@gmail.com [Thu, 15 Oct 2015 05:30:43 +0000 (05:30 +0000)]
[ES6] Class method should not declare any variables to upper scope.
https://bugs.webkit.org/show_bug.cgi?id=150115

Reviewed by Geoffrey Garen.

In the current implementation, class methods attempt to declare variables to an upper scope with their method names.
But this is not specified behavior in the ES6 spec.

And as a result, previously, we attempted to declare variables with invalid identifiers.
For example, `class A { 1() { } }` attempt to declare a variable with name `1`.
This (declaring variables with incorrect names) is not allowed in the lexical environment.
And it fires assertions in https://bugs.webkit.org/show_bug.cgi?id=150089.

* parser/Parser.cpp:
(JSC::Parser<LexerType>::parseClass): Deleted.
* tests/stress/class-method-does-not-declare-variable-to-upper-scope.js: Added.
(shouldBe):
(A.prototype.method):
(A.staticMethod):
(A):

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

4 years ago[Win] Layout Test http/tests/multipart/multipart-replace-non-html-content.php has...
ap@apple.com [Thu, 15 Oct 2015 05:27:46 +0000 (05:27 +0000)]
[Win] Layout Test http/tests/multipart/multipart-replace-non-html-content.php has extra whitespace
https://bugs.webkit.org/show_bug.cgi?id=150130

Landing a custom expectation. The test still passes, although it surprisingly gets
the extra newline.

* platform/win/http/tests/multipart/multipart-replace-non-html-content-expected.txt: Copied from LayoutTests/http/tests/multipart/multipart-replace-non-html-content-expected.txt.

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

4 years agoAugment <input type=search>’s recent search history with the time each entry was...
commit-queue@webkit.org [Thu, 15 Oct 2015 05:19:02 +0000 (05:19 +0000)]
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.

Patch by Zhuo Li <zachli@apple.com> on 2015-10-14
Reviewed by Darin Adler.

Replace Vector<String> with Vector<RecentSearch>, where RecentSearch is a struct
Source/WebCore:

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):

Source/WebKit/ios:

that consists search string and time, for recent searches in order to store additional time information.

* WebCoreSupport/SearchPopupMenuIOS.cpp:
(SearchPopupMenuIOS::saveRecentSearches):
(SearchPopupMenuIOS::loadRecentSearches):
* WebCoreSupport/SearchPopupMenuIOS.h:

Source/WebKit/mac:

that consists search string and time, for recent searches in order to store additional time information.

All these new RecentSearches are stored in a plist in which the structure looks like:
Root {
    "items": {
        autosave name: {
            "searches": [
                { "searchString": searchString, "date": date },
                ...
            ]
        }
    }
}

* WebCoreSupport/SearchPopupMenuMac.h:
* WebCoreSupport/SearchPopupMenuMac.mm:
(SearchPopupMenuMac::saveRecentSearches): Call saveRecentSearches in WebCore::SearchPopupMenuCocoa.
(SearchPopupMenuMac::loadRecentSearches): Call loadRecentSearches in WebCore::SearchPopupMenuCocoa.
(autosaveKey): Deleted.

Source/WebKit2:

that consists search string and time, for recent searches in order to store additional time
information.

All these new RecentSearches are stored in a plist in which the structure looks like:
Root {
    "items": {
        autosave name: {
            "searches": [
                { "searchString": searchString, "date": date },
                ...
            ]
        }
    }
}

* Scripts/webkit/messages.py:
(headers_for_type):
* Shared/WebCoreArgumentCoders.cpp:
(IPC::ArgumentCoder<RecentSearch>::encode): Encode the new struct RecentSearch
(IPC::ArgumentCoder<RecentSearch>::decode): Decode the new struct RecentSearch
* Shared/WebCoreArgumentCoders.h:
* UIProcess/Cocoa/WebPageProxyCocoa.mm:
(WebKit::WebPageProxy::saveRecentSearches): Call saveRecentSearches in WebCore::SearchPopupMenuCocoa.
(WebKit::WebPageProxy::loadRecentSearches): Call loadRecentSearches in WebCore::SearchPopupMenuCocoa.
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* UIProcess/efl/WebPageProxyEfl.cpp:
(WebKit::WebPageProxy::saveRecentSearches):
(WebKit::WebPageProxy::loadRecentSearches):
* UIProcess/gtk/WebPageProxyGtk.cpp:
(WebKit::WebPageProxy::saveRecentSearches):
(WebKit::WebPageProxy::loadRecentSearches):
* WebProcess/WebCoreSupport/WebSearchPopupMenu.cpp:
(WebKit::WebSearchPopupMenu::saveRecentSearches):
(WebKit::WebSearchPopupMenu::loadRecentSearches):
* WebProcess/WebCoreSupport/WebSearchPopupMenu.h:

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

4 years agoUse RefPtr<Image> return type for StyleImage::image()
simon.fraser@apple.com [Thu, 15 Oct 2015 04:55:08 +0000 (04:55 +0000)]
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:

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

4 years agoGive subclasses of CSSImageGeneratorValue a consistent image() return type
simon.fraser@apple.com [Thu, 15 Oct 2015 04:47:44 +0000 (04:47 +0000)]
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:

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

4 years agoREGRESSION: Web Inspector hangs for many seconds when trying to reload page
commit-queue@webkit.org [Thu, 15 Oct 2015 03:53:49 +0000 (03:53 +0000)]
REGRESSION: Web Inspector hangs for many seconds when trying to reload page
https://bugs.webkit.org/show_bug.cgi?id=150065

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-10-14
Reviewed by Mark Lam.

When debugging Web Pages, the same Debugger (PageScriptDebugServer) is
attached to each of the different JSGlobalObjects on the page. This could
mean multiple frames or isolated scripting contexts. Therefore we should
only need to send sourceParsed events to the frontend for scripts within
this new JSGlobalObject, not any JSGlobalObject that has this debugger.

* debugger/Debugger.cpp:
(JSC::Debugger::attach):
Only send sourceParsed events for Scripts in this JSGlobalObject.

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

4 years agoMove some EventHandler initialization to the header
timothy_horton@apple.com [Thu, 15 Oct 2015 01:21:19 +0000 (01:21 +0000)]
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.

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

4 years agoRemove unimplemented methods in CopiedSpace
commit-queue@webkit.org [Thu, 15 Oct 2015 01:06:39 +0000 (01:06 +0000)]
Remove unimplemented methods in CopiedSpace
https://bugs.webkit.org/show_bug.cgi?id=150143

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-10-14
Reviewed by Andreas Kling.

* heap/CopiedSpace.h:

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

4 years ago[iOS] build-dumprendertree does not build ImageDiff
aestes@apple.com [Thu, 15 Oct 2015 00:57:38 +0000 (00:57 +0000)]
[iOS] build-dumprendertree does not build ImageDiff
https://bugs.webkit.org/show_bug.cgi?id=150152

Reviewed by Tim Horton.

run-webkit-tests attempts to build the tools it requires by calling build-dumprendertree and build-webkittestrunner.
On iOS, build-dumprendertree builds the DumpRenderTree.app target, which does not contain the ImageDiff target
as a dependent. If you haven't built ImageDiff by other means (say, because you built the 'All Source' scheme in
WebKit.xcworkspace), tests that rely on image diffing won't work properly.

There's actually no reason to build the DumpRenderTree.app target on iOS; the default aggregate target works
fine on that platform, and results in ImageDiff being built.

* Scripts/build-dumprendertree:

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

4 years ago[Content Extensions] Make blocked async XHR call onerror
commit-queue@webkit.org [Thu, 15 Oct 2015 00:52:23 +0000 (00:52 +0000)]
[Content Extensions] Make blocked async XHR call onerror
https://bugs.webkit.org/show_bug.cgi?id=146706

Patch by Alex Christensen <achristensen@webkit.org> on 2015-10-14
Reviewed by Brady Eidson.

Source/WebCore:

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.

LayoutTests:

* http/tests/contentextensions/async-xhr-onerror-expected.txt: Added.
* http/tests/contentextensions/async-xhr-onerror.html: Added.
* http/tests/contentextensions/async-xhr-onerror.html.json: Added.

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

4 years ago[iOS] QuickLook documents loaded over https do not load their subresources
aestes@apple.com [Thu, 15 Oct 2015 00:21:27 +0000 (00:21 +0000)]
[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.

Source/WebCore:

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.

LayoutTests:

* TestExpectations: Skipped http/tests/quicklook on all platforms.
* http/tests/quicklook/resources/secure-document-with-subresources-expected/index.css: Added.
* http/tests/quicklook/resources/secure-document-with-subresources-expected/index.html: Added.
* http/tests/quicklook/resources/secure-document-with-subresources.pages: Added.
* http/tests/quicklook/resources/webkit-icon.tiff: Added.
* http/tests/quicklook/secure-document-with-subresources-expected.html: Added.
* http/tests/quicklook/secure-document-with-subresources.html: Added.
* platform/ios-simulator/TestExpectations: Expected http/tests/quicklook to pass on iOS.

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

4 years ago[Win] Enforce launcher/library naming scheme
bfulgham@apple.com [Thu, 15 Oct 2015 00:11:54 +0000 (00:11 +0000)]
[Win] Enforce launcher/library naming scheme
https://bugs.webkit.org/show_bug.cgi?id=150124

Reviewed by Alex Christensen.

Source/JavaScriptCore:

* JavaScriptCore.vcxproj/jsc/DLLLauncherMain.cpp: Look for
{name}Lib.dll instead of {name}.dll.
(wWinMain):
* shell/PlatformWin.cmake: Add 'Lib' suffix to DLLs.

Tools:

* DumpRenderTree/PlatformWin.cmake: Use 'Lib' suffix for DLLs.
* MiniBrowser/win/CMakeLists.txt: Ditto.
* TestWebKitAPI/PlatformWin.cmake: Ditto.
* win/DLLLauncher/DLLLauncherMain.cpp:
(wWinMain): Look for a DLL named {name}Lib.dll, rather than the
original {name}.dll.

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

4 years agoFixing expectations for imported/w3c/web-platform-tests/html/dom/interfaces.html
commit-queue@webkit.org [Wed, 14 Oct 2015 23:19:20 +0000 (23:19 +0000)]
Fixing expectations for imported/w3c/web-platform-tests/html/dom/interfaces.html
https://bugs.webkit.org/show_bug.cgi?id=150144.

Patch by Ryan Haddad <ryanhaddad@apple.com> on 2015-10-14
Reviewed by Dean Jackson.

* web-platform-tests/html/dom/interfaces-expected.txt:

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

4 years agoWeb pages with unscalable viewports shouldn't have a single tap delay
wenson_hsieh@apple.com [Wed, 14 Oct 2015 21:20:50 +0000 (21:20 +0000)]
Web pages with unscalable viewports shouldn't have a single tap delay
https://bugs.webkit.org/show_bug.cgi?id=149968
<rdar://problem/23054453>

Reviewed by Simon Fraser.

Source/WebKit2:

When a viewport is unscalable (specified through the meta viewport tag) we
do not add a delay to our single tap gesture recognizer. We do this by
disabling or reinitializing the WKContentView's double tap gesture recognizer
when the viewport becomes unscalable or scalable, respectively. A viewport is
deemed unscalable when it has user-scalable = no, or when the minimum scale is
greater than or equal to the maximum scale.

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _didCommitLayerTree:]):
* UIProcess/ios/WKContentViewInteraction.h:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _createAndConfigureDoubleTapGestureRecognizer]): Pulled logic
        for initializing a double tap gesture recognizer out into a helper function.
(-[WKContentView setupInteraction]):
(-[WKContentView _setDoubleTapGesturesEnabled:]): Turns gesture recognition for double
        taps on or off.

LayoutTests:

Add a layout test to check that when a viewport is unscalable (specified through
the meta viewport tag) we do not add a delay to our single tap gesture recognizer.

* fast/events/ios/unscalable-viewport-clicks-on-doubletap-expected.txt: Added.
* fast/events/ios/unscalable-viewport-clicks-on-doubletap.html: Added.

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

4 years agoWeb Inspector: Console SearchBar should work more like ContentBrowser FindBanner
joepeck@webkit.org [Wed, 14 Oct 2015 21:03:05 +0000 (21:03 +0000)]
Web Inspector: Console SearchBar should work more like ContentBrowser FindBanner
https://bugs.webkit.org/show_bug.cgi?id=149505

Patch by João Oliveira <hello@jxs.pt> on 2015-10-13
Reviewed by Joseph Pecoraro.

Console tab now uses findBanner, adapted LogContentView to use findBanner,
and findBanner to be more agnostic to both usecases, either as fixed, on console tab,
and hideable on other inspector tabs.

* UserInterface/Views/FindBanner.css:
(.find-banner.console-find-banner):
(.find-banner.console-findbanner input[type="search"]):
* UserInterface/Views/FindBanner.js:
(WebInspector.FindBanner):
(WebInspector.FindBanner.set targetElement.delayedWork):
(WebInspector.FindBanner.prototype.set targetElement):
(WebInspector.FindBanner.prototype.get showing):
(WebInspector.FindBanner.prototype.focus):
(WebInspector.FindBanner.prototype._clearAndBlur):
(WebInspector.FindBanner.prototype.show.delayedWork):
(WebInspector.FindBanner.prototype.show):
(WebInspector.FindBanner.prototype.hide):
(WebInspector.FindBanner.prototype.get element): Deleted.
(WebInspector.FindBanner.prototype._inputFieldSearch): Deleted.
* UserInterface/Views/LogContentView.js:
(WebInspector.LogContentView):
(WebInspector.LogContentView.prototype.get navigationItems):
(WebInspector.LogContentView.prototype.handleFindEvent):
(WebInspector.LogContentView.prototype.findBannerRevealPreviousResult):
(WebInspector.LogContentView.prototype.findBannerRevealNextResult):
(WebInspector.LogContentView.prototype._filterMessageElements):
(WebInspector.LogContentView.prototype.findBannerPerformSearch):
(WebInspector.LogContentView.prototype.findBannerSearchCleared):
(WebInspector.LogContentView.prototype.revealNextSearchResult):
(WebInspector.LogContentView.prototype.revealPreviousSearchResult):
(WebInspector.LogContentView.prototype._performSearch):
(WebInspector.LogContentView.prototype.searchBarDidActivate): Deleted.
(WebInspector.LogContentView.prototype._searchTextDidChange): Deleted.

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

4 years agoUpdate test result for Canvas2DRenderingContext::commit.
dino@apple.com [Wed, 14 Oct 2015 20:52:04 +0000 (20:52 +0000)]
Update test result for Canvas2DRenderingContext::commit.

* web-platform-tests/html/dom/interfaces-expected.txt:

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

4 years agoREGRESSION(r190882): Concatenating a character array and an empty string is broken.
akling@apple.com [Wed, 14 Oct 2015 20:45:12 +0000 (20:45 +0000)]
REGRESSION(r190882): Concatenating a character array and an empty string is broken.
<https://webkit.org/b/150135>

Reviewed by Geoffrey Garen.

Source/WTF:

StringAdapter templates for raw character arrays were always using 1 as the array length
in toString().

* wtf/text/StringConcatenate.h:

Tools:

Add a new WTF API test that covers this issue.

* TestWebKitAPI/Tests/WTF/StringOperators.cpp:
(TestWebKitAPI::build):
(TestWebKitAPI::TEST):

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

4 years agoVersioning.
bshafiei@apple.com [Wed, 14 Oct 2015 20:24:33 +0000 (20:24 +0000)]
Versioning.

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

4 years agoPostpone mutation events before invoke Editor::Command command(Document*, const Strin...
commit-queue@webkit.org [Wed, 14 Oct 2015 20:11:19 +0000 (20:11 +0000)]
Postpone mutation events before invoke Editor::Command command(Document*, const String&, bool).
https://bugs.webkit.org/show_bug.cgi?id=149299
<rdar://problem/22746995>

Patch by Jiewen Tan <jiewen_tan@apple.com> on 2015-10-14
Reviewed by Andreas Kling.

Source/WebCore:

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):

LayoutTests:

* editing/inserting/insert-with-mutation-event-expected.txt: Added.
* editing/inserting/insert-with-mutation-event.html: Added.

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

4 years agoRemove a message that isn't used by anyone
andersca@apple.com [Wed, 14 Oct 2015 20:10:11 +0000 (20:10 +0000)]
Remove a message that isn't used by anyone
https://bugs.webkit.org/show_bug.cgi?id=150136

Reviewed by Andreas Kling.

* UIProcess/API/APILoaderClient.h:
(API::LoaderClient::didRemoveFrameFromHierarchy): Deleted.
* UIProcess/API/C/WKPage.cpp:
(WKPageSetPageLoaderClient): Deleted.
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::didRemoveFrameFromHierarchy): Deleted.
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::detachedFromParent2): Deleted.

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

4 years agoImplement CanvasRenderingContext2D::commit
dino@apple.com [Wed, 14 Oct 2015 20:05:02 +0000 (20:05 +0000)]
Implement CanvasRenderingContext2D::commit
https://bugs.webkit.org/show_bug.cgi?id=150110
<rdar://problem/23057398>

Reviewed by Anders Carlsson.

Source/WebCore:

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.

LayoutTests:

* fast/canvas/commit-expected.txt: Added.
* fast/canvas/commit.html: Added.

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

4 years agoAdd SPI for reloading without content blockers
achristensen@apple.com [Wed, 14 Oct 2015 20:03:14 +0000 (20:03 +0000)]
Add SPI for reloading without content blockers
https://bugs.webkit.org/show_bug.cgi?id=150058
rdar://problem/22742222

Reviewed by Sam Weinig.

Source/WebCore:

* 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.

Source/WebKit2:

* Shared/WebPageCreationParameters.cpp:
(WebKit::WebPageCreationParameters::encode):
(WebKit::WebPageCreationParameters::decode):
* Shared/WebPageCreationParameters.h:
* UIProcess/API/C/WKPage.cpp:
(WKPageReload):
(WKPageReloadWithoutContentBlockers):
(WKPageReloadFromOrigin):
(WKPageTryClose):
(WKPageSetUserContentExtensionsEnabled):
(WKPageSupportsTextEncoding):
* UIProcess/API/C/WKPage.h:
* UIProcess/API/Cocoa/WKBrowsingContextController.mm:
(-[WKBrowsingContextController reload]):
(-[WKBrowsingContextController reloadFromOrigin]):
(-[WKBrowsingContextController applicationNameForUserAgent]):
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView reload]):
(-[WKWebView reloadFromOrigin]):
(-[WKWebView _setUserContentExtensionsEnabled:]):
(-[WKWebView _userContentExtensionsEnabled]):
(-[WKWebView _webProcessIdentifier]):
(-[WKWebView _killWebContentProcess]):
(-[WKWebView _reloadWithoutContentBlockers]):
(-[WKWebView _killWebContentProcessAndResetState]):
* UIProcess/API/Cocoa/WKWebViewPrivate.h:
* UIProcess/API/gtk/WebKitWebView.cpp:
(webkit_web_view_reload):
(webkit_web_view_reload_bypass_cache):
* UIProcess/WebFrameProxy.cpp:
(WebKit::WebFrameProxy::didHandleContentFilterUnblockNavigation):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::stopLoading):
(WebKit::WebPageProxy::reload):
(WebKit::WebPageProxy::creationParameters):
(WebKit::WebPageProxy::setShouldScaleViewToFitDocument):
(WebKit::WebPageProxy::setUserContentExtensionsEnabled): Deleted.
* UIProcess/WebPageProxy.h:
(WebKit::WebPageProxy::userContentExtensionsEnabled): Deleted.
* WebProcess/WebPage/WebPage.cpp:
(WebKit::m_shouldDispatchFakeMouseMoveEvents):
(WebKit::WebPage::setDefersLoading):
(WebKit::WebPage::reload):
(WebKit::WebPage::goForward):
(WebKit::WebPage::createDocumentLoader):
(WebKit::WebPage::setShouldScaleViewToFitDocument):
(WebKit::WebPage::imageOrMediaDocumentSizeChanged):
(WebKit::WebPage::setUserContentExtensionsEnabled): Deleted.
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in:

Tools:

* WebKitTestRunner/cocoa/TestControllerCocoa.mm:
(WTR::TestController::cocoaResetStateToConsistentValues):
* WebKitTestRunner/mac/TestControllerMac.mm:
(WTR::TestController::platformConfigureViewForTest):

LayoutTests:

* http/tests/contentextensions/disable-blocker-expected.txt: Removed.
* http/tests/contentextensions/disable-blocker.html: Removed.
* http/tests/contentextensions/disable-blocker.html.json: Removed.
_userContentExtensionsEnabled is going to be removed, and its functionality is what this test tested.

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

4 years agoRename JSDOMWrapper to JSDOMObject and JSDOMWrapperWithImplementation to JSDOMWrapper
youenn.fablet@crf.canon.fr [Wed, 14 Oct 2015 19:18:36 +0000 (19:18 +0000)]
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):

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

4 years agoES6 Fix TypedArray constructors.
keith_miller@apple.com [Wed, 14 Oct 2015 19:07:12 +0000 (19:07 +0000)]
ES6 Fix TypedArray constructors.
https://bugs.webkit.org/show_bug.cgi?id=149975

Reviewed by Geoffrey Garen.

The ES6 spec requires that any object argument passed to a TypedArray constructor that is not a TypedArray
and has an iterator should use the iterator to construct the TypedArray. To avoid performance regressions related
to iterating we check if the iterator attached to the object points to the generic array iterator and length is a value.
If so, we do not use the iterator since there should be no observable difference. Another other interesting note is
that the ES6 spec has the of and from functions on a shared constructor between all the TypedArray constructors.
When the TypedArray is constructed the expectation is to crawl the prototype chain of the this value
passed to the function. If the function finds a known TypedArray constructor (Int32Array, Float64Array,...) then
it creates a TypedArray of that type. This is implemented by adding a private function (@allocateTypedArray) to each
of the constructors that can be called in order to construct the array. By using the private functions the JIT should
hopefully be able to optimize this to a direct call.

* CMakeLists.txt:
* JavaScriptCore.xcodeproj/project.pbxproj:
* builtins/TypedArrayConstructor.js: Added.
(of):
(from):
(allocateInt8Array):
(allocateInt16Array):
(allocateInt32Array):
(allocateUint32Array):
(allocateUint16Array):
(allocateUint8Array):
(allocateUint8ClampedArray):
(allocateFloat32Array):
(allocateFloat64Array):
* runtime/CommonIdentifiers.h:
* runtime/JSDataView.cpp:
(JSC::JSDataView::setIndex):
* runtime/JSDataView.h:
* runtime/JSGenericTypedArrayView.h:
(JSC::JSGenericTypedArrayView::toAdaptorNativeFromValue):
* runtime/JSGenericTypedArrayViewConstructor.h:
* runtime/JSGenericTypedArrayViewConstructorInlines.h:
(JSC::JSGenericTypedArrayViewConstructor<ViewClass>::finishCreation):
(JSC::JSGenericTypedArrayViewConstructor<ViewClass>::create):
(JSC::constructGenericTypedArrayViewFromIterator):
(JSC::constructGenericTypedArrayView):
* runtime/JSGenericTypedArrayViewPrototypeFunctions.h:
(JSC::genericTypedArrayViewProtoFuncIndexOf):
(JSC::genericTypedArrayViewProtoFuncLastIndexOf):
* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
* runtime/JSTypedArrayViewConstructor.cpp: Added.
(JSC::JSTypedArrayViewConstructor::JSTypedArrayViewConstructor):
(JSC::JSTypedArrayViewConstructor::finishCreation):
(JSC::JSTypedArrayViewConstructor::create):
(JSC::JSTypedArrayViewConstructor::createStructure):
(JSC::constructTypedArrayView):
(JSC::JSTypedArrayViewConstructor::getConstructData):
(JSC::JSTypedArrayViewConstructor::getCallData):
* runtime/JSTypedArrayViewConstructor.h: Copied from Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructor.h.
* runtime/JSTypedArrayViewPrototype.cpp:
(JSC::JSTypedArrayViewPrototype::create):
* tests/es6.yaml:
* tests/stress/resources/typedarray-constructor-helper-functions.js: Added.
(forEachTypedArray):
(hasSameValues):
(foo):
(testConstructorFunction):
(testConstructor):
* tests/stress/typedarray-constructor.js: Added.
(A):
(iterator.return.next):
(iterator):
(obj.valueOf):
(iterator2.return.next):
(iterator2):
* tests/stress/typedarray-from.js: Added.
(even):
(isBigEnoughAndException):
* tests/stress/typedarray-of.js: Added.

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

4 years agoRename some JSC option names to be more uniform.
mark.lam@apple.com [Wed, 14 Oct 2015 18:57:07 +0000 (18:57 +0000)]
Rename some JSC option names to be more uniform.
https://bugs.webkit.org/show_bug.cgi?id=150127

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

Renaming JSC_enableXXX options to JSC_useXXX, and JSC_showXXX options to JSC_dumpXXX.
Also will renaming a few other miscellaneous to options, to abide by this scheme.

Also renaming some functions to match the option names where relevant.

* API/tests/ExecutionTimeLimitTest.cpp:
(testExecutionTimeLimit):
* assembler/AbstractMacroAssembler.h:
(JSC::optimizeForARMv7IDIVSupported):
(JSC::optimizeForARM64):
(JSC::optimizeForX86):
* assembler/LinkBuffer.cpp:
(JSC::shouldDumpDisassemblyFor):
(JSC::LinkBuffer::finalizeCodeWithoutDisassembly):
(JSC::shouldShowDisassemblyFor): Deleted.
* assembler/LinkBuffer.h:
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::jettison):
* bytecode/CodeBlockJettisoningWatchpoint.cpp:
(JSC::CodeBlockJettisoningWatchpoint::fireInternal):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::BytecodeGenerator):
* dfg/DFGAdaptiveInferredPropertyValueWatchpoint.cpp:
(JSC::DFG::AdaptiveInferredPropertyValueWatchpoint::fire):
* dfg/DFGAdaptiveStructureWatchpoint.cpp:
(JSC::DFG::AdaptiveStructureWatchpoint::fireInternal):
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::handleInlining):
(JSC::DFG::ByteCodeParser::handleGetById):
(JSC::DFG::ByteCodeParser::handlePutById):
(JSC::DFG::ByteCodeParser::parse):
* dfg/DFGCommon.h:
(JSC::DFG::leastUpperBound):
(JSC::DFG::shouldDumpDisassembly):
(JSC::DFG::shouldShowDisassembly): Deleted.
* dfg/DFGDriver.cpp:
(JSC::DFG::compileImpl):
* dfg/DFGJITCompiler.cpp:
(JSC::DFG::JITCompiler::JITCompiler):
(JSC::DFG::JITCompiler::disassemble):
* dfg/DFGJumpReplacement.cpp:
(JSC::DFG::JumpReplacement::fire):
* dfg/DFGOSREntry.cpp:
(JSC::DFG::prepareOSREntry):
* dfg/DFGOSRExitCompiler.cpp:
* dfg/DFGOSRExitFuzz.h:
(JSC::DFG::doOSRExitFuzzing):
* dfg/DFGPlan.cpp:
(JSC::DFG::Plan::compileInThreadImpl):
* dfg/DFGSpeculativeJIT.cpp:
(JSC::DFG::SpeculativeJIT::compileArithSqrt):
* dfg/DFGTierUpCheckInjectionPhase.cpp:
(JSC::DFG::TierUpCheckInjectionPhase::run):
* ftl/FTLCompile.cpp:
(JSC::FTL::mmAllocateDataSection):
* ftl/FTLJITCode.cpp:
(JSC::FTL::JITCode::~JITCode):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::DFG::LowerDFGToLLVM::callCheck):
* ftl/FTLOSRExitCompiler.cpp:
(JSC::FTL::compileStub):
(JSC::FTL::compileFTLOSRExit):
* ftl/FTLState.h:
(JSC::FTL::verboseCompilationEnabled):
(JSC::FTL::shouldDumpDisassembly):
(JSC::FTL::shouldShowDisassembly): Deleted.
* heap/Heap.cpp:
(JSC::Heap::addToRememberedSet):
(JSC::Heap::didFinishCollection):
(JSC::Heap::shouldDoFullCollection):
* heap/Heap.h:
(JSC::Heap::isDeferred):
(JSC::Heap::structureIDTable):
* heap/HeapStatistics.cpp:
(JSC::StorageStatistics::storageCapacity):
(JSC::HeapStatistics::dumpObjectStatistics):
(JSC::HeapStatistics::showObjectStatistics): Deleted.
* heap/HeapStatistics.h:
* interpreter/StackVisitor.cpp:
(JSC::StackVisitor::Frame::createArguments):
* jit/AssemblyHelpers.cpp:
(JSC::AssemblyHelpers::callExceptionFuzz):
* jit/ExecutableAllocationFuzz.cpp:
(JSC::doExecutableAllocationFuzzing):
* jit/ExecutableAllocationFuzz.h:
(JSC::doExecutableAllocationFuzzingIfEnabled):
* jit/JIT.cpp:
(JSC::JIT::privateCompile):
* jit/JITCode.cpp:
(JSC::JITCodeWithCodeRef::~JITCodeWithCodeRef):
* jit/PolymorphicCallStubRoutine.cpp:
(JSC::PolymorphicCallNode::unlink):
(JSC::PolymorphicCallNode::clearCallLinkInfo):
(JSC::PolymorphicCallStubRoutine::PolymorphicCallStubRoutine):
* jit/Repatch.cpp:
(JSC::linkFor):
(JSC::unlinkFor):
(JSC::linkVirtualFor):
* jsc.cpp:
(functionEnableExceptionFuzz):
(jscmain):
* llvm/InitializeLLVM.cpp:
(JSC::initializeLLVMImpl):
* runtime/ExceptionFuzz.cpp:
(JSC::doExceptionFuzzing):
* runtime/ExceptionFuzz.h:
(JSC::doExceptionFuzzingIfEnabled):
* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
* runtime/Options.cpp:
(JSC::recomputeDependentOptions):
(JSC::Options::initialize):
(JSC::Options::dumpOptionsIfNeeded):
(JSC::Options::setOption):
(JSC::Options::dumpAllOptions):
(JSC::Options::dumpAllOptionsInALine):
(JSC::Options::dumpOption):
* runtime/Options.h:
* runtime/VM.cpp:
(JSC::VM::VM):
* runtime/VM.h:
(JSC::VM::exceptionFuzzingBuffer):
* runtime/WriteBarrierInlines.h:
(JSC::WriteBarrierBase<T>::set):
(JSC::WriteBarrierBase<Unknown>::set):
* tests/executableAllocationFuzz.yaml:
* tests/stress/arrowfunction-typeof.js:
* tests/stress/disable-function-dot-arguments.js:
(foo):
* tests/stress/math-sqrt-basics-disable-architecture-specific-optimizations.js:
(sqrtOnInteger):
* tests/stress/regress-148564.js:

Tools:

* Scripts/jsc-stress-test-helpers/js-executable-allocation-fuzz:
* Scripts/run-jsc-stress-tests:

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

4 years agoChange GraphicsContext image-drawing functions to take references
simon.fraser@apple.com [Wed, 14 Oct 2015 18:10:32 +0000 (18:10 +0000)]
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.

Source/WebCore:

* 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):

Source/WebKit/win:

* FullscreenVideoController.cpp:
(HUDButton::draw):
* Plugins/PluginView.cpp:
(WebCore::PluginView::paintMissingPluginIcon):

Source/WebKit2:

* Shared/ContextMenuContextData.cpp:
(WebKit::ContextMenuContextData::ContextMenuContextData):
* Shared/WebCoreArgumentCoders.cpp:
(IPC::encodeImage):
(IPC::encodeOptionalImage):
(IPC::ArgumentCoder<Cursor>::encode):
* WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::createSelectionSnapshot):

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

4 years agoREGRESSION(r53318): background-repeat: space with gradients doesn't render correctly
commit-queue@webkit.org [Wed, 14 Oct 2015 17:29:18 +0000 (17:29 +0000)]
REGRESSION(r53318): background-repeat: space with gradients doesn't render correctly
https://bugs.webkit.org/show_bug.cgi?id=150068

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2015-10-14
Reviewed by Simon Fraser.

Source/WebCore:

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):

LayoutTests:

Ensure the gradient background-image is drawn correctly when it is repeated
with spaces.

* fast/gradients/background-image-repeat-space-expected.html: Added.
* fast/gradients/background-image-repeat-space.html: Added.

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

4 years agoChange the bundle app cache APIs to take a page
andersca@apple.com [Wed, 14 Oct 2015 17:23:12 +0000 (17:23 +0000)]
Change the bundle app cache APIs to take a page
https://bugs.webkit.org/show_bug.cgi?id=150123

Reviewed by Sam Weinig.

Source/WebKit2:

This is another step towards getting rid of ApplicationCacheStorage::singleton().
Ideally the WKTR tests that use this should be converted to API tests.

* WebProcess/InjectedBundle/API/c/WKBundle.cpp:
(WKBundleClearApplicationCache): Deleted.
(WKBundleClearApplicationCacheForOrigin): Deleted.
(WKBundleSetAppCacheMaximumSize): Deleted.
(WKBundleGetAppCacheUsageForOrigin): Deleted.
(WKBundleSetApplicationCacheOriginQuota): Deleted.
(WKBundleResetApplicationCacheOriginQuota): Deleted.
(WKBundleCopyOriginsWithApplicationCache): Deleted.
* WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
(WKBundlePageClearApplicationCache):
(WKBundlePageClearApplicationCacheForOrigin):
(WKBundlePageSetAppCacheMaximumSize):
(WKBundlePageGetAppCacheUsageForOrigin):
(WKBundlePageSetApplicationCacheOriginQuota):
(WKBundlePageResetApplicationCacheOriginQuota):
(WKBundlePageCopyOriginsWithApplicationCache):
* WebProcess/InjectedBundle/API/c/WKBundlePagePrivate.h:
* WebProcess/InjectedBundle/API/c/WKBundlePrivate.h:
* WebProcess/InjectedBundle/InjectedBundle.cpp:
(WebKit::InjectedBundle::clearApplicationCache): Deleted.
(WebKit::InjectedBundle::clearApplicationCacheForOrigin): Deleted.
(WebKit::InjectedBundle::setAppCacheMaximumSize): Deleted.
(WebKit::InjectedBundle::appCacheUsageForOrigin): Deleted.
(WebKit::InjectedBundle::setApplicationCacheOriginQuota): Deleted.
(WebKit::InjectedBundle::resetApplicationCacheOriginQuota): Deleted.
(WebKit::InjectedBundle::originsWithApplicationCache): Deleted.
* WebProcess/InjectedBundle/InjectedBundle.h:

Tools:

Update APIs.

* WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
(WTR::InjectedBundle::beginTesting):
* WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
(WTR::InjectedBundlePage::didReachApplicationCacheOriginQuota):
* WebKitTestRunner/InjectedBundle/TestRunner.cpp:
(WTR::TestRunner::clearAllApplicationCaches):
(WTR::TestRunner::clearApplicationCacheForOrigin):
(WTR::TestRunner::setAppCacheMaximumSize):
(WTR::TestRunner::applicationCacheDiskUsageForOrigin):
(WTR::TestRunner::originsWithApplicationCache):

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

4 years agoSpeculative build fix: the CallSiteIndex constructor is explicit and requires an...
mark.lam@apple.com [Wed, 14 Oct 2015 16:23:16 +0000 (16:23 +0000)]
Speculative build fix: the CallSiteIndex constructor is explicit and requires an uint32_t.

Not Reviewed.

* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::newExceptionHandlingCallSiteIndex):

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

4 years ago[Win64] Enable concurrent JIT.
peavo@outlook.com [Wed, 14 Oct 2015 12:59:11 +0000 (12:59 +0000)]
[Win64] Enable concurrent JIT.
https://bugs.webkit.org/show_bug.cgi?id=150098

Reviewed by Csaba Osztrogonác.

* wtf/Platform.h:

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

4 years agoUpdating LayoutTests/imported/w3c/web-platform-tests svn:ignore property as done...
youenn.fablet@crf.canon.fr [Wed, 14 Oct 2015 12:46:36 +0000 (12:46 +0000)]
Updating LayoutTests/imported/w3c/web-platform-tests svn:ignore property as done in LayoutTests/imported/w3c/web-platform-tests/.gitignore in revision 191043

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

4 years agoUpdate web-platform-tests tools to the latest revision
youenn.fablet@crf.canon.fr [Wed, 14 Oct 2015 12:37:14 +0000 (12:37 +0000)]
Update web-platform-tests tools to the latest revision
https://bugs.webkit.org/show_bug.cgi?id=149645

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Removed tools folder.
Updated ImportExpectations and TestRepositories files to match latest wpt repo revision.
Updated web-platform-tests using the import tool.

* resources/ImportExpectations: Skipping new test suites.
* resources/TestRepositories: Updating revision of default imported web-platform-tests. Disabled conversion of git submodules information.
* resources/web-platform-tests-modules.json: Updated by hand the modules description to align with wpt repo.
* web-platform-tests/.gitignore: Marking tools folder as ignored.
* web-platform-tests/README.md:
* web-platform-tests/common/w3c-import.log:
* web-platform-tests/config.default.json:
* web-platform-tests/domparsing/w3c-import.log:
* web-platform-tests/lint: Added.
* web-platform-tests/lint.whitelist: Renamed from LayoutTests/imported/w3c/web-platform-tests/tools/scripts/lint.whitelist.
* web-platform-tests/manifest: Added.
* web-platform-tests/serve: Added.
* web-platform-tests/serve.py:
(main):
* web-platform-tests/tools/__init__.py: Removed.
* web-platform-tests/tools/runner/css/bootstrap-theme.min.css: Removed.
* web-platform-tests/tools/runner/css/bootstrap.min.css: Removed.
* web-platform-tests/tools/runner/css/w3c-import.log: Removed.
* web-platform-tests/tools/runner/fonts/glyphicons-halflings-regular.eot: Removed.
* web-platform-tests/tools/runner/fonts/glyphicons-halflings-regular.svg: Removed.
* web-platform-tests/tools/runner/fonts/glyphicons-halflings-regular.ttf: Removed.
* web-platform-tests/tools/runner/fonts/glyphicons-halflings-regular.woff: Removed.
* web-platform-tests/tools/runner/fonts/w3c-import.log: Removed.
* web-platform-tests/tools/runner/logo.svg: Removed.
* web-platform-tests/tools/runner/report.css: Removed.
* web-platform-tests/tools/runner/report.py: Removed.
* web-platform-tests/tools/runner/runner.css: Removed.
* web-platform-tests/tools/runner/runner.js: Removed.
* web-platform-tests/tools/runner/update_manifest.py: Removed.
* web-platform-tests/tools/runner/w3c-import.log: Removed.
* web-platform-tests/tools/scripts/__init__.py: Removed.
* web-platform-tests/tools/scripts/_env.py: Removed.
* web-platform-tests/tools/scripts/html5lib_test.xml: Removed.
* web-platform-tests/tools/scripts/html5lib_test_fragment.xml: Removed.
* web-platform-tests/tools/scripts/id2path.js: Removed.
* web-platform-tests/tools/scripts/id2path.json: Removed.
* web-platform-tests/tools/scripts/lint.py: Removed.
* web-platform-tests/tools/scripts/manifest.js: Removed.
* web-platform-tests/tools/scripts/manifest.py: Removed.
* web-platform-tests/tools/scripts/package.json: Removed.
* web-platform-tests/tools/scripts/toc.js: Removed.
* web-platform-tests/tools/scripts/update-directory-structure.js: Removed.
* web-platform-tests/tools/scripts/update_html5lib_tests.py: Removed.
* web-platform-tests/tools/scripts/w3c-import.log: Removed.
* web-platform-tests/tools/sslutils/__init__.py: Removed.
* web-platform-tests/tools/sslutils/base.py: Removed.
* web-platform-tests/tools/sslutils/openssl.py: Removed.
* web-platform-tests/tools/sslutils/pregenerated.py: Removed.
* web-platform-tests/tools/sslutils/w3c-import.log: Removed.
* web-platform-tests/tools/w3c-import.log: Removed.
* web-platform-tests/tools/webdriver/webdriver/__init__.py: Removed.
* web-platform-tests/tools/webdriver/webdriver/alert.py: Removed.
* web-platform-tests/tools/webdriver/webdriver/capabilities.py: Removed.
* web-platform-tests/tools/webdriver/webdriver/command.py: Removed.
* web-platform-tests/tools/webdriver/webdriver/driver.py: Removed.
* web-platform-tests/tools/webdriver/webdriver/exceptions.py: Removed.
* web-platform-tests/tools/webdriver/webdriver/keys.py: Removed.
* web-platform-tests/tools/webdriver/webdriver/searchcontext.py: Removed.
* web-platform-tests/tools/webdriver/webdriver/w3c-import.log: Removed.
* web-platform-tests/tools/webdriver/webdriver/wait.py: Removed.
* web-platform-tests/tools/webdriver/webdriver/webelement.py: Removed.
* web-platform-tests/w3c-import.log:

Tools:

Disabling git submodules information conversion to json install file for web-platform-tests.
Disabling related python unit tests.
The tools submodules contain submodules and the conversion tool does not support that yet.

Updating wpt launcher script to aling it with web-platform-test main script.

* Scripts/webkitpy/layout_tests/servers/web_platform_test_launcher.py:
(main):
* Scripts/webkitpy/layout_tests/servers/web_platform_test_server_unittest.py:
(TestWebPlatformTestServer.test_corrupted_subserver_files): Deleted.
* Scripts/webkitpy/w3c/test_importer_unittest.py:
(TestImporterTest.test_submodules_generation):

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

4 years ago[GTK][EFL] Fix build with cmake 3.4
commit-queue@webkit.org [Wed, 14 Oct 2015 10:57:49 +0000 (10:57 +0000)]
[GTK][EFL] Fix build with cmake 3.4
https://bugs.webkit.org/show_bug.cgi?id=150117

Explicitely include the CheckIncludeFiles module before using
the CHECK_INCLUDE_FILES command.

Patch by Tomas Popela <tpopela@redhat.com> on 2015-10-14
Reviewed by Žan Doberšek.

* Source/cmake/FindOpenGL.cmake:
* Source/cmake/FindWebP.cmake:
* Source/cmake/OptionsEfl.cmake:

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

4 years ago[EFL] Fix the problem in which environment variable included in webprocess-cmd-prefix...
commit-queue@webkit.org [Wed, 14 Oct 2015 10:34:09 +0000 (10:34 +0000)]
[EFL] Fix the problem in which environment variable included in webprocess-cmd-prefix can't be parsed
https://bugs.webkit.org/show_bug.cgi?id=148616

Patch by Joonghun Park <jh718.park@samsung.com> on 2015-10-14
Reviewed by Gyuyoung Kim.

This patch fixes the problem in which environment variable in web process-cmd-prefix can't be parsed.
process-cmd-prefix option doesn't work in two cases.
1. When executing run-layout-tests,
2. When executing MiniBrowser with web process-cmd-prefix environment variable.

* UIProcess/Launcher/efl/ProcessLauncherEfl.cpp:
(WebKit::parseAndRemoveEnvironments):
(WebKit::ProcessLauncher::launchProcess):

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

4 years agohttp/tests/xmlhttprequest/xmlhttprequest-overridemimetype-invalidstaterror.html flaki...
commit-queue@webkit.org [Wed, 14 Oct 2015 07:59:03 +0000 (07:59 +0000)]
http/tests/xmlhttprequest/xmlhttprequest-overridemimetype-invalidstaterror.html flakily times out during Mac-WK2 tests
https://bugs.webkit.org/show_bug.cgi?id=150095

Patch by Ryan Haddad <ryanhaddad@apple.com> on 2015-10-14
Reviewed by Alexey Proskuryakov.

* platform/mac-wk2/TestExpectations:

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

4 years agoUnreviewed, rolling out r191030.
commit-queue@webkit.org [Wed, 14 Oct 2015 07:08:54 +0000 (07:08 +0000)]
Unreviewed, rolling out r191030.
https://bugs.webkit.org/show_bug.cgi?id=150116

caused js/class-syntax-method-names.html to crash on debug
builds (Requested by alexchristensen_ on #webkit).

Reverted changeset:

"[ES6] Class expression should have lexical environment that
has itself as an imutable binding"
https://bugs.webkit.org/show_bug.cgi?id=150089
http://trac.webkit.org/changeset/191030

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

4 years agoMore debug queue build fixing.
ap@apple.com [Wed, 14 Oct 2015 06:26:11 +0000 (06:26 +0000)]
More debug queue build fixing.

Preserve the build style in one more place. Changed mock build_style from "both"
to "release", as we don't support testing both debug and release.

* Scripts/webkitpy/tool/bot/commitqueuetask_unittest.py:
(MockCommitQueue.archive_last_test_results):
(MockCommitQueue):
(MockCommitQueue.build_style):
(MockCommitQueue.did_pass_testing_ews):
* Scripts/webkitpy/tool/bot/patchanalysistask.py:
(PatchAnalysisTask._test):
(PatchAnalysisTask._build_and_test_without_patch):
* Scripts/webkitpy/tool/commands/earlywarningsystem_unittest.py:
(EarlyWarningSystemTest._default_expected_logs):
* Scripts/webkitpy/tool/commands/queues_unittest.py:

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

4 years agoMore debug queue build fixing.
ap@apple.com [Wed, 14 Oct 2015 05:11:55 +0000 (05:11 +0000)]
More debug queue build fixing.

Add build_style argument to derived classes as well.

* Scripts/webkitpy/common/config/ports.py:
(MacPort):
(MacPort.run_webkit_tests_command):
(WinPort.run_bindings_tests_command):
(WinPort):
(WinPort.run_webkit_tests_command):
(GtkWK2Port.build_webkit_command):
(GtkWK2Port):
(GtkWK2Port.run_webkit_tests_command):

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

4 years ago[iOS] Build fix
mmaxfield@apple.com [Wed, 14 Oct 2015 05:10:51 +0000 (05:10 +0000)]
[iOS] Build fix

Unreviewed.

Mach-O section names are limited to 16 characters.

* DumpRenderTree/mac/Configurations/DumpRenderTreeApp.xcconfig:
* DumpRenderTree/mac/DumpRenderTree.mm:
(activateFontsIOS):

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

4 years agoBuild fix for mac-debug EWS queue.
ap@apple.com [Wed, 14 Oct 2015 04:54:37 +0000 (04:54 +0000)]
Build fix for mac-debug EWS queue.

Unreviewed.

Pass --debug to run-webkit-tests.

While at it, removed unsupported run_webkit_unit_tests_command. All the test steps
will need to be substantially modified to work in EWS, so the dummy implementation
was not helpful.

* Scripts/webkitpy/common/config/ports.py:
(DeprecatedPort.run_javascriptcore_tests_command):
(DeprecatedPort):
(DeprecatedPort.run_webkit_tests_command):
(DeprecatedPort.run_python_unittests_command):
(DeprecatedPort.run_webkit_unit_tests_command): Deleted.
* Scripts/webkitpy/common/config/ports_mock.py:
(MockPort.run_javascriptcore_tests_command):
(MockPort):
(MockPort.run_webkit_tests_command):
(MockPort.run_bindings_tests_command):
(MockPort.run_webkit_unit_tests_command): Deleted.
* Scripts/webkitpy/tool/commands/download_unittest.py:
* Scripts/webkitpy/tool/steps/runtests.py:
(RunTests.run):
* Scripts/webkitpy/tool/steps/runtests_unittest.py:
(RunTestsTest.test_webkit_run_unit_tests):
* Scripts/webkitpy/tool/steps/steps_unittest.py:
(StepsTest.test_runtests_args):

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

4 years ago[ES6] Class expression should have lexical environment that has itself as an imutable...
utatane.tea@gmail.com [Wed, 14 Oct 2015 03:56:53 +0000 (03:56 +0000)]
[ES6] Class expression should have lexical environment that has itself as an imutable binding
https://bugs.webkit.org/show_bug.cgi?id=150089

Reviewed by Geoffrey Garen.

According to ES6 spec, class expression has its own lexical environment that holds itself
as an immutable binding[1] (section 14.5.14 step 2, 3, 4, 23)

As a result, even if the binding declared in the outer scope is overridden, methods inside
class expression can refer its class by the class name.

[1]: http://ecma-international.org/ecma-262/6.0/#sec-runtime-semantics-classdefinitionevaluation

* bytecompiler/NodesCodegen.cpp:
(JSC::ClassExprNode::emitBytecode):
* parser/ASTBuilder.h:
(JSC::ASTBuilder::createClassExpr):
* parser/NodeConstructors.h:
(JSC::ClassExprNode::ClassExprNode):
* parser/Nodes.h:
* parser/Parser.cpp:
(JSC::Parser<LexerType>::parseClass):
* parser/SyntaxChecker.h:
(JSC::SyntaxChecker::createClassExpr):
* tests/es6.yaml:
* tests/stress/class-expression-generates-environment.js: Added.
(shouldBe):
(shouldThrow):
(prototype.method):
(staticMethod):
(A.prototype.method):
(A.staticMethod):
(A):
* tests/stress/class-expression-should-be-tdz-in-heritage.js: Added.
(shouldThrow):
(shouldThrow.A):

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

4 years ago[iOS] Update anonymous table results for iOS port.
zalan@apple.com [Wed, 14 Oct 2015 03:05:30 +0000 (03:05 +0000)]
[iOS] Update anonymous table results for iOS port.

Unreviewed gardening.

* platform/ios-simulator/css2.1/tables/table-anonymous-objects-177-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-178-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-179-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-180-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-181-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-189-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-190-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-191-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-192-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-193-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-194-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-195-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-196-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-205-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-206-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-207-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-208-expected.txt: Added.

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

4 years agoUnreviewed EFL Gardening on 13th Oct.
commit-queue@webkit.org [Wed, 14 Oct 2015 02:38:05 +0000 (02:38 +0000)]
Unreviewed EFL Gardening on 13th Oct.
https://bugs.webkit.org/show_bug.cgi?id=150084

Patch by Hunseop Jeong <hs85.jeong@samsung.com> on 2015-10-13

* platform/efl/TestExpectations:

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

4 years ago[Win] Update anonymous table results for Windows port.
zalan@apple.com [Wed, 14 Oct 2015 02:14:25 +0000 (02:14 +0000)]
[Win] Update anonymous table results for Windows port.

Unreviewed gardening.

* platform/win/css2.1/tables/table-anonymous-objects-177-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-178-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-179-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-180-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-189-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-190-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-191-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-192-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-193-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-194-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-195-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-196-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-205-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-206-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-207-expected.txt: Added.
* platform/win/css2.1/tables/table-anonymous-objects-208-expected.txt: Added.

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

4 years agoUse the correct notification strings for view service applications state change.
barraclough@apple.com [Wed, 14 Oct 2015 00:25:34 +0000 (00:25 +0000)]
Use the correct notification strings for view service applications state change.
https://bugs.webkit.org/show_bug.cgi?id=150107

Use the correct notification names "_UIViewServiceHostDidEnterBackgroundNotification" and
"_UIViewServiceHostWillEnterForegroundNotification" to listen to view service application state changes.

Patch by Yongjun Zhang <yongjun_zhang@apple.com> on 2015-10-13
Reviewed by Gavin Barraclough.

* UIProcess/ApplicationStateTracker.mm:
(WebKit::ApplicationStateTracker::ApplicationStateTracker):

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

4 years ago[Win] Generate Crash Traces
bfulgham@apple.com [Wed, 14 Oct 2015 00:15:38 +0000 (00:15 +0000)]
[Win] Generate Crash Traces
https://bugs.webkit.org/show_bug.cgi?id=150103

Reviewed by Daniel Bates.

We were using an exception filter to try to emit "#CRASHED" to stderr
when a test program crashed. However, the modern Python implementation
seems capable of recognizing crashes on its own. Furthermore, registering
the exception handler was preventing the JIT debugger (NTSD) from
automatically attaching to the crashing program, so we were not getting
crash traces.

* DumpRenderTree/win/DumpRenderTree.cpp:
(main): Don't register an exception filter.
(exceptionFilter): Deleted.
* Scripts/webkitpy/common/system/crashlogs.py:
(CrashLogs): Add another regular expression to handle a second crash trace
syntax I encountered during testing.
(CrashLogs._find_newest_log_win): If the old regular expression doesn't match,
try the new one. The PID found by the new expression is in hexadecimal, so
convert it to an integer before returning it.
* Scripts/webkitpy/port/driver.py:
(Driver._check_for_driver_crash_or_unresponsiveness): Windows was not recognizing
the "#CRASHED" state because it was appending '\r\n', rather than just '\r'. Instead,
check for "#CRASHED" after stripping off the EOL characters.
* Scripts/webkitpy/port/win.py:
(WinPort.setup_crash_log_saving): Put back the '-e %ld' flag in the debugger
invocation. This is apparently used to signal an event when the debugger is finished.

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

4 years agoAdd helper funtion for checking pointer equivalency and use it
simon.fraser@apple.com [Wed, 14 Oct 2015 00:14:29 +0000 (00:14 +0000)]
Add helper funtion for checking pointer equivalency and use it
https://bugs.webkit.org/show_bug.cgi?id=150022

Reviewed by Darin Adler.
Source/WebCore:

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:

Source/WTF:

Add PointerComparison.h which contains the templated pointer comparison
function.

* WTF.xcodeproj/project.pbxproj:
* wtf/PointerComparison.h: Added.
(WTF::arePointingToEqualData):

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

4 years agoWe were creating a GCAwareJITStubRoutineWithExceptionHandler when we didn't actually...
sbarati@apple.com [Wed, 14 Oct 2015 00:12:18 +0000 (00:12 +0000)]
We were creating a GCAwareJITStubRoutineWithExceptionHandler when we didn't actually have an exception handler in the CodeBlock's exception handler table
https://bugs.webkit.org/show_bug.cgi?id=150016

Reviewed by Geoffrey Garen.

There was a bug where we created a GCAwareJITStubRoutineWithExceptionHandler
for inline caches that were custom setters/getters (but not JS getters/setters).
This is wrong; we only create GCAwareJITStubRoutineWithExceptionHandler when we have
an inline cache with a JS getter/setter call which causes the inline cache to add itself
to the CodeBlock's exception handling table. The problem was that we created
a GCAwareJITStubRoutineWithExceptionHandler that tried to remove itself from
the exception handler table only to find out that it didn't have an entry in the table.

* bytecode/PolymorphicAccess.cpp:
(JSC::PolymorphicAccess::regenerate):

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

4 years agoSimplify WeakBlock visit and reap phases
commit-queue@webkit.org [Wed, 14 Oct 2015 00:10:07 +0000 (00:10 +0000)]
Simplify WeakBlock visit and reap phases
https://bugs.webkit.org/show_bug.cgi?id=150045

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-10-13
Reviewed by Geoffrey Garen.

WeakBlock visiting and reaping both happen after MarkedBlock marking.
All the MarkedBlocks we encounter should be either Marked or Retired.

* heap/MarkedBlock.h:
(JSC::MarkedBlock::isMarkedOrRetired):
* heap/WeakBlock.cpp:
(JSC::WeakBlock::visit):
(JSC::WeakBlock::reap):
* heap/WeakBlock.h:

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

4 years agoSplit TypesettingFeatures into kerning and ligatures bools
mmaxfield@apple.com [Tue, 13 Oct 2015 23:40:38 +0000 (23:40 +0000)]
Split TypesettingFeatures into kerning and ligatures bools
https://bugs.webkit.org/show_bug.cgi?id=150074

Reviewed by Simon Fraser.

Source/WebCore:

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:

Source/WebKit/mac:

* WebView/WebView.mm:
(+[WebView initialize]):

Source/WebKit2:

* Shared/WebProcessCreationParameters.cpp:
(WebKit::WebProcessCreationParameters::WebProcessCreationParameters):
(WebKit::WebProcessCreationParameters::encode):
(WebKit::WebProcessCreationParameters::decode):
* Shared/WebProcessCreationParameters.h:
* UIProcess/Cocoa/WebProcessPoolCocoa.mm:
(WebKit::WebProcessPool::platformInitializeWebProcess):
* WebProcess/cocoa/WebProcessCocoa.mm:
(WebKit::WebProcess::platformInitializeWebProcess):

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

4 years agoFix iOS-family builds.
dino@apple.com [Tue, 13 Oct 2015 23:28:03 +0000 (23:28 +0000)]
Fix iOS-family builds.

* UIProcess/API/C/mac/WKPagePrivateMac.mm:
(WKPageGetObjectRegistry):
* UIProcess/API/Cocoa/WKBrowsingContextController.mm:
(-[WKBrowsingContextController _remoteObjectRegistry]):
* UIProcess/API/mac/WKViewInternal.h:

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

4 years ago[Win] Unreviewed test gardening after r190995.
bfulgham@apple.com [Tue, 13 Oct 2015 23:01:14 +0000 (23:01 +0000)]
[Win] Unreviewed test gardening after r190995.

Update to correct test output, based on similar changes to Mac expectations.

* platform/win/fast/html/details-add-child-2-expected.txt:
* platform/win/fast/html/details-open2-expected.txt:

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

4 years agoAnonymous table objects: inline parent box requires inline-table child.
zalan@apple.com [Tue, 13 Oct 2015 22:53:46 +0000 (22:53 +0000)]
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.

Source/WebCore:

* 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):

LayoutTests:

* css2.1/tables/table-anonymous-objects-177.xht: Added.
* css2.1/tables/table-anonymous-objects-178.xht: Added.
* css2.1/tables/table-anonymous-objects-179.xht: Added.
* css2.1/tables/table-anonymous-objects-180.xht: Added.
* css2.1/tables/table-anonymous-objects-181.xht: Added.
* css2.1/tables/table-anonymous-objects-189.xht: Added.
* css2.1/tables/table-anonymous-objects-190.xht: Added.
* css2.1/tables/table-anonymous-objects-191.xht: Added.
* css2.1/tables/table-anonymous-objects-192.xht: Added.
* css2.1/tables/table-anonymous-objects-193.xht: Added.
* css2.1/tables/table-anonymous-objects-194.xht: Added.
* css2.1/tables/table-anonymous-objects-195.xht: Added.
* css2.1/tables/table-anonymous-objects-196.xht: Added.
* css2.1/tables/table-anonymous-objects-205.xht: Added.
* css2.1/tables/table-anonymous-objects-206.xht: Added.
* css2.1/tables/table-anonymous-objects-207.xht: Added.
* css2.1/tables/table-anonymous-objects-208.xht: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-177-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-178-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-179-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-180-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-181-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-189-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-190-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-191-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-192-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-193-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-194-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-195-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-196-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-205-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-206-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-207-expected.txt: Added.
* platform/mac/css2.1/tables/table-anonymous-objects-208-expected.txt: Added.

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

4 years agoFix 32-bit build.
andersca@apple.com [Tue, 13 Oct 2015 22:17:50 +0000 (22:17 +0000)]
Fix 32-bit build.

* UIProcess/API/C/mac/WKPagePrivateMac.mm:
(WKPageGetObjectRegistry):

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

4 years agoAdd and implement WKPageGetObjectRegistry
andersca@apple.com [Tue, 13 Oct 2015 21:56:59 +0000 (21:56 +0000)]
Add and implement WKPageGetObjectRegistry
https://bugs.webkit.org/show_bug.cgi?id=150102

Reviewed by Tim Horton.

Put the _WKObjectRegistry used by WKPageRef and WKBrowsingContextController on the WKView for now.
If we decide to share more code between WKView and WKWebView, the object registry could live in an object that would be shared
between WKView and WKWebView.

* UIProcess/API/C/mac/WKPagePrivateMac.h:
* UIProcess/API/C/mac/WKPagePrivateMac.mm:
(WKPageGetObjectRegistry):
* UIProcess/API/Cocoa/WKBrowsingContextController.mm:
(-[WKBrowsingContextController _remoteObjectRegistry]):
(-[WKBrowsingContextController dealloc]): Deleted.
* UIProcess/API/mac/WKView.mm:
(-[WKView dealloc]):
(-[WKView _remoteObjectRegistry]):
* UIProcess/API/mac/WKViewInternal.h:

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

4 years agoDevice motion and orientation should only be visible from the main frame's security...
dino@apple.com [Tue, 13 Oct 2015 21:46:10 +0000 (21:46 +0000)]
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.

.:

Add a manual test for cross-origin device orientation events, while
we're waiting on the mock client to be supported everywhere.

* ManualTests/deviceorientation-child-frame.html: Added.
* ManualTests/deviceorientation-main-frame-only.html: Added.

Source/WebCore:

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.

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

4 years agoASSERT(m_motionManager) on emgn.com page
dino@apple.com [Tue, 13 Oct 2015 21:45:43 +0000 (21:45 +0000)]
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]):

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

4 years agoA lot of the http/tests/cache/disk-cache/ tests are flaky on mac-wk2, marking them...
commit-queue@webkit.org [Tue, 13 Oct 2015 21:28:21 +0000 (21:28 +0000)]
A lot of the http/tests/cache/disk-cache/ tests are flaky on mac-wk2, marking them as such.
https://bugs.webkit.org/show_bug.cgi?id=149087

Patch by Ryan Haddad <ryanhaddad@apple.com> on 2015-10-13
Reviewed by Alexey Proskuryakov.

* platform/mac-wk2/TestExpectations:

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

4 years agoMac Debug and 32-bit queues should be separate
ap@apple.com [Tue, 13 Oct 2015 20:30:41 +0000 (20:30 +0000)]
Mac Debug and 32-bit queues should be separate
https://bugs.webkit.org/show_bug.cgi?id=150092

Reviewed by Lucas Forschler.

* QueueStatusServer/config/queues.py:
* QueueStatusServer/model/queues.py:
(Queue._capitalize_after_dash):
(Queue._caplitalize_after_dash): Deleted.
* Scripts/webkitpy/common/config/ews.json:

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

4 years agoREGRESSION(r189567): Web Inspector: Clipped filter icons when debugger sidebar is...
nvasilyev@apple.com [Tue, 13 Oct 2015 20:23:10 +0000 (20:23 +0000)]
REGRESSION(r189567): Web Inspector: Clipped filter icons when debugger sidebar is narrow
https://bugs.webkit.org/show_bug.cgi?id=150023

r189567 changed flexbox items' default min-width from 0 to auto.
Explicitly set it to 0 in CSS.

Reviewed by Brian Burg.

* UserInterface/Views/FilterBar.css:
(.filter-bar > input[type="search"]):

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

4 years agoCodeBlock write barriers should be precise
ggaren@apple.com [Tue, 13 Oct 2015 20:08:54 +0000 (20:08 +0000)]
CodeBlock write barriers should be precise
https://bugs.webkit.org/show_bug.cgi?id=150042

Reviewed by Saam Barati.

CodeBlock performs lots of unnecessary write barriers. This wastes
performance and makes the code a bit harder to follow, and it might mask
important bugs. Now is a good time to unmask important bugs.

* bytecode/CodeBlock.h:
(JSC::CodeBlockSet::mark): Don't write barrier all CodeBlocks on the
stack. Only CodeBlocks that do value profiling need write barriers, and
they do those themselves.

In steady state, when most of our CodeBlocks are old and FTL-compiled,
and we're doing eden GC's, we should almost never visit a CodeBlock.

* dfg/DFGOSRExitCompilerCommon.cpp:
(JSC::DFG::osrWriteBarrier):
(JSC::DFG::adjustAndJumpToTarget): Don't write barrier all inlined
CodeBlocks on exit. That's not necessary. Instead, write barrier the
CodeBlock(s) we will exit to, along with the one we will write a value
profile to.

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

4 years agoAvoid useless copies in range-loops that are using 'auto'
cdumez@apple.com [Tue, 13 Oct 2015 19:15:55 +0000 (19:15 +0000)]
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.
Source/bmalloc:

* bmalloc/Deallocator.cpp:
(bmalloc::Deallocator::processObjectLog):

Source/WebKit/mac:

* WebView/WebFrame.mm:
(-[WebFrame getDictationResultRanges:andMetadatas:]):

Source/WebKit2:

* UIProcess/VisitedLinkStore.cpp:
(WebKit::VisitedLinkStore::pendingVisitedLinksTimerFired):
(WebKit::VisitedLinkStore::resizeTable):
* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::releaseRemainingIconsForPageURLs):
* UIProcess/WebsiteData/WebsiteDataStore.cpp:
(WebKit::WebsiteDataStore::fetchData):
(WebKit::WebsiteDataStore::removeData):
(WebKit::WebsiteDataStore::plugins):

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

4 years agoWeb Inspector: Don't shadow global Object constructor in WebInspector.Object class...
utatane.tea@gmail.com [Tue, 13 Oct 2015 19:03:46 +0000 (19:03 +0000)]
Web Inspector: Don't shadow global Object constructor in WebInspector.Object class definition
https://bugs.webkit.org/show_bug.cgi?id=150093

Reviewed by Joseph Pecoraro.

Currently, class expression does not define any variables. So even in `class Object { }`,
we were able to touch the global Object constructor (like `Object.keys`).
However, that is a bug. After https://bugs.webkit.org/show_bug.cgi?id=150089 fixes that bug,
the global `Object` is shadowed by the user-defined `class Object` name.

To solve this issue, we changed the `class Object` to `class WebInspectorObject`.
And we expose this class as a `WebInspector.Object`.

* UserInterface/Base/Object.js:

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

4 years agoMove Image::drawPattern for CG into GraphicsContext
simon.fraser@apple.com [Tue, 13 Oct 2015 19:03:37 +0000 (19:03 +0000)]
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.

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

4 years agoUnprefix font-kerning
mmaxfield@apple.com [Tue, 13 Oct 2015 18:49:58 +0000 (18:49 +0000)]
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.

Source/WebCore:

Test: fast/text/font-kerning.html

* css/CSSPropertyNames.in:

LayoutTests:

* fast/text/font-kerning-expected.html:
* fast/text/font-kerning.html:

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

4 years agoAdd debug settings for using giant tiles (4096x4096)
commit-queue@webkit.org [Tue, 13 Oct 2015 18:46:53 +0000 (18:46 +0000)]
Add debug settings for using giant tiles (4096x4096)
https://bugs.webkit.org/show_bug.cgi?id=149977
<rdar://problem/23017093>

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2015-10-13
Reviewed by Tim Horton.

Source/WebCore:

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().

Source/WebKit2:

* Shared/WebPreferencesDefinitions.h:
* UIProcess/API/C/WKPreferences.cpp:
(WKPreferencesSetUseGiantTiles):
(WKPreferencesGetUseGiantTiles):
* UIProcess/API/C/WKPreferencesRefPrivate.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::updatePreferences):

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

4 years agoTry to fix ENABLE(DETAILS_ELEMENT) with SHADOW_DOM disabled.
antti@apple.com [Tue, 13 Oct 2015 18:34:22 +0000 (18:34 +0000)]
Try to fix ENABLE(DETAILS_ELEMENT) with SHADOW_DOM disabled.

* dom/Element.cpp:
(WebCore::Element::attributeChanged):
* dom/Node.cpp:
(WebCore::traverseStyleParent):

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

4 years agohttp/tests/multipart/multipart-replace-non-html-content.php shouldn't exercise
ap@apple.com [Tue, 13 Oct 2015 18:05:17 +0000 (18:05 +0000)]
http/tests/multipart/multipart-replace-non-html-content.php shouldn't exercise
edge cases of multipart parsing
https://bugs.webkit.org/show_bug.cgi?id=149978
rdar://problem/22981062

Reviewed by Anders Carlsson.

This test is not about HTTP edge cases, but about handling of multipart content in WebKit.

* http/tests/multipart/multipart-replace-non-html-content.php:
* platform/mac/http/tests/multipart/multipart-replace-non-html-content-expected.txt: Removed.
* platform/win/TestExpectations:

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

4 years agoFix license and copyrights of WebCore js binding builtin files
youenn.fablet@crf.canon.fr [Tue, 13 Oct 2015 17:44:18 +0000 (17:44 +0000)]
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:

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

4 years ago[iOS] Avoid crash due to invalid screen bounds
bfulgham@apple.com [Tue, 13 Oct 2015 16:54:16 +0000 (16:54 +0000)]
[iOS] Avoid crash due to invalid screen bounds
https://bugs.webkit.org/show_bug.cgi?id=150048
<rdar://problem/22112664>

Reviewed by Jer Noble.

Check for an invalid bounds, and reset it to a known state before
attempting to use it.

* WebProcess/ios/WebVideoFullscreenManager.mm:
(WebKit::WebVideoFullscreenManager::setVideoLayerFrameFenced):

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

4 years agoREGRESSION: ASSERT (impl->isAtomic()) @ facebook.com
utatane.tea@gmail.com [Tue, 13 Oct 2015 16:03:22 +0000 (16:03 +0000)]
REGRESSION: ASSERT (impl->isAtomic()) @ facebook.com
https://bugs.webkit.org/show_bug.cgi?id=149965

Reviewed by Geoffrey Garen.

Edge filtering for CheckIdent ensures that a given value is either Symbol or StringIdent.
However, this filtering is not applied to CheckIdent when propagating a constant value in
the constant folding phase. As a result, it is not guaranteeed that a constant value
propagated in constant folding is Symbol or StringIdent.

* dfg/DFGConstantFoldingPhase.cpp:
(JSC::DFG::ConstantFoldingPhase::foldConstants):

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

4 years ago[iOS] Update anonymous table results for iOS port.
zalan@apple.com [Tue, 13 Oct 2015 15:42:50 +0000 (15:42 +0000)]
[iOS] Update anonymous table results for iOS port.

Unreviewed gardening.

* platform/ios-simulator/css2.1/tables/table-anonymous-objects-015-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-016-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-023-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-024-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-035-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-036-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-037-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-038-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-045-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-046-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-047-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-048-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-049-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-050-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-055-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-056-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-091-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-092-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-099-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-100-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-105-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-106-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-107-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-108-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-109-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-110-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-111-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-112-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-113-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-114-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-115-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-116-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-121-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-122-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-123-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-124-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-139-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-140-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-149-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-150-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-155-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-156-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-159-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-160-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-165-expected.txt: Added.
* platform/ios-simulator/css2.1/tables/table-anonymous-objects-166-expected.txt: Added.

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

4 years ago[GTK] Fix build for ENABLE_TOUCH_EVENTS=OFF
svillar@igalia.com [Tue, 13 Oct 2015 14:42:23 +0000 (14:42 +0000)]
[GTK] Fix build for ENABLE_TOUCH_EVENTS=OFF
https://bugs.webkit.org/show_bug.cgi?id=150085

Reviewed by Carlos Garcia Campos.

Source/WebKit2:

* Shared/gtk/NativeWebTouchEventGtk.cpp:
* Shared/gtk/WebEventFactory.cpp:
* Shared/gtk/WebEventFactory.h:
* UIProcess/API/gtk/PageClientImpl.cpp:
* UIProcess/API/gtk/PageClientImpl.h:
* UIProcess/API/gtk/WebKitWebViewBase.cpp:
(webkit_web_view_base_class_init):

Tools:

* WebKitTestRunner/gtk/EventSenderProxyGtk.cpp:

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

4 years agoImplement iterator for traversing composed DOM
antti@apple.com [Tue, 13 Oct 2015 13:12:25 +0000 (13:12 +0000)]
Implement iterator for traversing composed DOM
https://bugs.webkit.org/show_bug.cgi?id=149997

Reviewed by Ryosuke Niwa.

Source/WebCore:

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):

LayoutTests:

* TestExpectations:

    Re-enable fast/html/details-replace-text.html which is fixed by this change.

* fast/forms/select-listbox-focus-displaynone-expected.txt:
* fast/repaint/text-in-relative-positioned-inline-expected.txt:
* fullscreen/full-screen-fixed-pos-parent-expected.txt:
* platform/mac-mavericks/fast/html/details-open2-expected.txt:
* platform/mac/fast/html/details-add-child-2-expected.txt:
* platform/mac/fast/html/details-open2-expected.txt:

    Non-visual whitespace changes.

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

4 years ago[GTK] Use GUniquePtr for GtkIconInfo
changseok.oh@collabora.com [Tue, 13 Oct 2015 11:30:48 +0000 (11:30 +0000)]
[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):

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

4 years agoUnreviewed, add myself to the committers list.
slomo@coaxion.net [Tue, 13 Oct 2015 10:53:47 +0000 (10:53 +0000)]
Unreviewed, add myself to the committers list.

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

4 years agoAvoid useless copying of Key::HashType in loops in NetworkCache::Storage::synchronize()
cdumez@apple.com [Tue, 13 Oct 2015 08:53:21 +0000 (08:53 +0000)]
Avoid useless copying of Key::HashType in loops in NetworkCache::Storage::synchronize()
https://bugs.webkit.org/show_bug.cgi?id=150061

Reviewed by Carlos Garcia Campos.

Avoid useless copying of Key::HashType in loops in NetworkCache::Storage::synchronize().
Key::HashType is currently a SHA1::Digest, which is a std::array<uint8_t, 20>.

* NetworkProcess/cache/NetworkCacheStorage.cpp:
(WebKit::NetworkCache::Storage::synchronize):

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

4 years agoUnreviewed, register symbol structure to fix Debug build
utatane.tea@gmail.com [Tue, 13 Oct 2015 06:30:02 +0000 (06:30 +0000)]
Unreviewed, register symbol structure to fix Debug build
https://bugs.webkit.org/show_bug.cgi?id=149622

Since InferredTypes for String or Symbol claim that they don't have any structure,
`registerInferredType` does not register the structure for Symbol.
We take the similar way to String to fix this issue; Registering Symbol structure
explicitly in DFGStructureRegisterationPhase. Because,

1. InferredType::structure is only allowed for ObjectWithStructure / ObjectWithStructureOrOther.
   It looks clear to me that only ObjectWithStructure has structure.
2. Symbol is similar primitive value to String. So handling its structure in similar way to String is nice.

* dfg/DFGStructureRegistrationPhase.cpp:
(JSC::DFG::StructureRegistrationPhase::run):

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

4 years agoUnreviewed, fix debug build warning.
ljaehun.lim@samsung.com [Tue, 13 Oct 2015 06:00:00 +0000 (06:00 +0000)]
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):

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

4 years agoUpdate bot watcher's dashboard to reflect that EWS is on iOS 9 now
ap@apple.com [Tue, 13 Oct 2015 05:13:05 +0000 (05:13 +0000)]
Update bot watcher's dashboard to reflect that EWS is on iOS 9 now
https://bugs.webkit.org/show_bug.cgi?id=149983

Reviewed by Dan Bates.

* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/BubbleQueueServer.js:
(BubbleQueueServer):
* BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/Dashboard.js:

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

4 years agoFix webkitpy tests after r190922.
ap@apple.com [Tue, 13 Oct 2015 05:08:52 +0000 (05:08 +0000)]
Fix webkitpy tests after r190922.

* Scripts/webkitpy/common/config/ews.json:
* Scripts/webkitpy/tool/commands/earlywarningsystem.py:
* Scripts/webkitpy/tool/commands/earlywarningsystem_unittest.py:

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

4 years agoIterator loops over key twice after delete
utatane.tea@gmail.com [Tue, 13 Oct 2015 03:24:02 +0000 (03:24 +0000)]
Iterator loops over key twice after delete
https://bugs.webkit.org/show_bug.cgi?id=149811

Reviewed by Geoffrey Garen.

When an object is the dictionary mode, JSPropertyNameEnumerator collects property names through generic property name enumeration `getPropertyNames`.
The result vector contains indexed property names. But in this case, `publicLength()` may not be 0.
So without disabling indexed names enumeration phase explicitly, JSPropertyNameEnumerator produces indexed property names twice.
One in indexed name enumeration phase, and another in generic property name enumeration phase.
This patch disables indexed names enumeration by setting `indexedLength` to 0 when collecting names through generic property name enumeration.

* runtime/JSPropertyNameEnumerator.h:
(JSC::propertyNameEnumerator):
* tests/stress/property-name-enumerator-should-not-look-into-indexed-values-when-it-is-a-dictionary.js: Added.
(shouldBe):
(col2.of.Reflect.enumerate):

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

4 years agoAdd a Mac debug EWS queue
ap@apple.com [Tue, 13 Oct 2015 02:49:33 +0000 (02:49 +0000)]
Add a Mac debug EWS queue
https://bugs.webkit.org/show_bug.cgi?id=150069

Reviewed by Geoffrey Garen.

* QueueStatusServer/config/queues.py:
* Scripts/webkitpy/common/config/ews.json:
* Scripts/webkitpy/tool/commands/earlywarningsystem.py:
(AbstractEarlyWarningSystem):
(AbstractEarlyWarningSystem.archive_last_test_results):
(AbstractEarlyWarningSystem.build_style):
(AbstractEarlyWarningSystem.refetch_patch):
(AbstractEarlyWarningSystem.load_ews_classes):

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

4 years agoAdd canvas line dash test
jonlee@apple.com [Tue, 13 Oct 2015 02:12:11 +0000 (02:12 +0000)]
Add canvas line dash test
https://bugs.webkit.org/show_bug.cgi?id=150078
<rdar://problem/23082347>

Reviewed by Dean Jackson.

* Animometer/runner/resources/tests.js: Add line dash test.
* Animometer/tests/simple/resources/simple-canvas-paths.js:
(CanvasLineDashStage): Create a new stage with a default dash pattern and stroke style.
Maintain a step which will animate the dash.
(CanvasLineDashStage.prototype.animate): Render the line path with the dash. Increment
the dash offset to animate.
(CanvasPathBenchmark.prototype.createStage): Add the test.

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

4 years agoAdd canvas line path tests
jonlee@apple.com [Tue, 13 Oct 2015 02:11:44 +0000 (02:11 +0000)]
Add canvas line path tests
https://bugs.webkit.org/show_bug.cgi?id=150076
<rdar://problem/23082285>

Reviewed by Dean Jackson.

* Animometer/runner/resources/tests.js: Add new line path tests, with different
line joins.
* Animometer/tests/simple/resources/simple-canvas-paths.js:
(CanvasLinePathStage): The stage is the same as the SimpleCanvasPathStrokeStage
but sets the lineJoin on the context.
(CanvasPathBenchmark.prototype.createStage): Add the tests.

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

4 years agoAdd missing paint objects for arc and arcTo fills
jonlee@apple.com [Tue, 13 Oct 2015 02:11:06 +0000 (02:11 +0000)]
Add missing paint objects for arc and arcTo fills
https://bugs.webkit.org/show_bug.cgi?id=150075
<rdar://problem/23082233>

Reviewed by Dean Jackson.

* Animometer/tests/simple/resources/simple-canvas-paths.js: Add missing paint objects
for arcTo and arc segment fills.
(CanvasArcToSegmentFill):
(CanvasArcToSegmentFill.prototype.draw):
(CanvasArcSegmentFill):
(CanvasArcSegmentFill.prototype.draw):

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

4 years agoAdd canvas line segment tests
jonlee@apple.com [Tue, 13 Oct 2015 02:10:42 +0000 (02:10 +0000)]
Add canvas line segment tests
https://bugs.webkit.org/show_bug.cgi?id=150073
<rdar://problem/23082138>

Reviewed by Dean Jackson.

* Animometer/runner/resources/tests.js: Add new line segment tests, with different
line caps.
* Animometer/tests/simple/resources/simple-canvas-paths.js:
(CanvasLineSegment): Add new line segment paint object.
(CanvasLineSegmentStage): Create a new stage that sets the lineCap.

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

4 years agoAdd canvas path fill tests
jonlee@apple.com [Tue, 13 Oct 2015 02:10:08 +0000 (02:10 +0000)]
Add canvas path fill tests
https://bugs.webkit.org/show_bug.cgi?id=150071
<rdar://problem/23082001>

Reviewed by Dean Jackson.

* Animometer/runner/resources/tests.js: Add new pathTypes for path fills.
* Animometer/tests/simple/resources/simple-canvas-paths.js:
(CanvasLinePoint): Add basic point for a line, and call lineTo.
(SimpleCanvasPathFillStage): Add a new stage similar to SimpleCanvasPathStrokeStage.
(CanvasPathBenchmark.prototype.createStage): Add the tests.

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