WebKit-https.git
6 years agoWeb Inspector: Expanding event objects in console shows undefined for most values...
commit-queue@webkit.org [Wed, 21 Jan 2015 00:34:57 +0000 (00:34 +0000)]
Web Inspector: Expanding event objects in console shows undefined for most values, it should have real values
https://bugs.webkit.org/show_bug.cgi?id=137306

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-01-20
Reviewed by Timothy Hatcher.

Source/JavaScriptCore:

Provide another optional parameter to getProperties, to gather a list
of all own and getter properties.

* inspector/InjectedScript.cpp:
(Inspector::InjectedScript::getProperties):
* inspector/InjectedScript.h:
* inspector/InjectedScriptSource.js:
* inspector/agents/InspectorRuntimeAgent.cpp:
(Inspector::InspectorRuntimeAgent::getProperties):
* inspector/agents/InspectorRuntimeAgent.h:
* inspector/protocol/Runtime.json:

Source/WebInspectorUI:

When first expanding an object, show all the object's own properties and any
getter properties that may be on its prototype chain. Now, we only fetch
own properties, for __proto__ properties.

* UserInterface/Protocol/RemoteObject.js:
(WebInspector.RemoteObject.prototype.getOwnProperties):
(WebInspector.RemoteObject.prototype.getOwnAndGetterProperties):
(WebInspector.RemoteObject.prototype.getAllProperties):
(WebInspector.RemoteObject.prototype.get hasChildren): Deleted.
* UserInterface/Views/ObjectPropertiesSection.js:
(WebInspector.ObjectPropertiesSection):
(WebInspector.ObjectPropertiesSection.prototype.update):
(WebInspector.ObjectPropertyTreeElement.prototype.onpopulate):

LayoutTests:

* inspector/model/remote-object-get-properties-expected.txt: Added.
* inspector/model/remote-object-get-properties.html: Added.

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

6 years agoWeb Inspector: Should show dynamic specificity values
commit-queue@webkit.org [Wed, 21 Jan 2015 00:30:36 +0000 (00:30 +0000)]
Web Inspector: Should show dynamic specificity values
https://bugs.webkit.org/show_bug.cgi?id=140647

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2015-01-20
Reviewed by Benjamin Poulain.

Source/JavaScriptCore:

* inspector/protocol/CSS.json:
Clarify CSSSelector optional values and add "dynamic" property indicating
if the selector can be dynamic based on the element it is matched against.

Source/WebCore:

Test: inspector/css/selector-dynamic-specificity.html

* inspector/InspectorCSSAgent.h:
* inspector/InspectorCSSAgent.cpp:
(WebCore::InspectorCSSAgent::setRuleSelector):
(WebCore::InspectorCSSAgent::addRule):
(WebCore::InspectorCSSAgent::buildObjectForRule):
(WebCore::InspectorCSSAgent::buildArrayForMatchedRuleList):
When building a response for a particular element, pass the element along.

* inspector/InspectorStyleSheet.h:
* inspector/InspectorStyleSheet.cpp:
(WebCore::hasDynamicSpecificity):
(WebCore::buildObjectForSelectorHelper):
(WebCore::selectorsFromSource):
(WebCore::InspectorStyleSheet::buildObjectForSelector):
(WebCore::InspectorStyleSheet::buildObjectForSelectorList):
(WebCore::InspectorStyleSheet::buildObjectForRule):
(WebCore::InspectorStyleSheet::buildArrayForRuleList):
(WebCore::InspectorStyleSheetForInlineStyle::InspectorStyleSheetForInlineStyle):
When building a response for a Selector, include the specificity if we know
the element in context.

Source/WebInspectorUI:

For dynamic selectors, provide text in the tooltip describing that the
specificity is dynamic and may change, and pointing out the element
the current value was calculated against.

* Localizations/en.lproj/localizedStrings.js:
* UserInterface/Models/CSSSelector.js:
(WebInspector.CSSSelector):
(WebInspector.CSSSelector.prototype.get specificity):
(WebInspector.CSSSelector.prototype.get dynamic):
* UserInterface/Models/DOMNodeStyles.js:
(WebInspector.DOMNodeStyles.prototype._parseSelectorListPayload.return):
(WebInspector.DOMNodeStyles.prototype._parseSelectorListPayload):
* UserInterface/Views/CSSStyleDeclarationSection.js:
(WebInspector.CSSStyleDeclarationSection.prototype.refresh.appendSelector):

LayoutTests:

* inspector/css/selector-dynamic-specificity-expected.txt: Added.
* inspector/css/selector-dynamic-specificity.html: Added.

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

6 years agohttp/tests/xmlhttprequest/xmlhttprequest-responseURL.html uses an incorrect resource...
ap@apple.com [Wed, 21 Jan 2015 00:28:33 +0000 (00:28 +0000)]
http/tests/xmlhttprequest/xmlhttprequest-responseURL.html uses an incorrect resource path
https://bugs.webkit.org/show_bug.cgi?id=140689

Reviewed by Tim Horton.

* http/tests/xmlhttprequest/xmlhttprequest-responseURL-expected.txt:
* http/tests/xmlhttprequest/xmlhttprequest-responseURL.html:

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

6 years agoNoise about undefined $ENV{"HTTP_ORIGIN"} in Apache logs on several tests
ap@apple.com [Wed, 21 Jan 2015 00:26:56 +0000 (00:26 +0000)]
Noise about undefined $ENV{"HTTP_ORIGIN"} in Apache logs on several tests
https://bugs.webkit.org/show_bug.cgi?id=140690

Reviewed by Tim Horton.

* http/tests/xmlhttprequest/resources/access-control-basic-allow-access-control-origin-header.cgi:

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

6 years agomalformed header from script 'noContentLength.asis': Bad header
ap@apple.com [Wed, 21 Jan 2015 00:25:28 +0000 (00:25 +0000)]
malformed header from script 'noContentLength.asis': Bad header
https://bugs.webkit.org/show_bug.cgi?id=140693

Reviewed by Tim Horton.

Changed the resource to actually have no Content-Length, and adjusted incorrect test
expectations.

* http/tests/xmlhttprequest/resources/noContentLength.asis: Removed.
* http/tests/xmlhttprequest/resources/noContentLength.cgi: Copied from LayoutTests/http/tests/xmlhttprequest/resources/noContentLength.asis.
* http/tests/xmlhttprequest/xmlhttprequest-no-content-length-onProgress.html:

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

6 years agoApache logs a warning in http/tests/resources/post-and-verify-hybrid.cgi
ap@apple.com [Wed, 21 Jan 2015 00:21:57 +0000 (00:21 +0000)]
Apache logs a warning in http/tests/resources/post-and-verify-hybrid.cgi
https://bugs.webkit.org/show_bug.cgi?id=140680

Reviewed by Tim Horton.

* http/tests/resources/post-and-verify-hybrid.cgi: Fix a "useless use of a variable
in void context".

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

6 years ago[Win] Build fix after r178760.
bfulgham@apple.com [Wed, 21 Jan 2015 00:13:17 +0000 (00:13 +0000)]
[Win] Build fix after r178760.

Windows will not accept a variable as the size declaration for an array.

* svg/SVGToOTFFontConversion.cpp:
(WebCore::SVGToOTFFontConverter::appendGSUBTable): Make size argument a const.

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

6 years ago[Win] Unreviewed Windows project file gardening.
bfulgham@apple.com [Wed, 21 Jan 2015 00:05:10 +0000 (00:05 +0000)]
[Win] Unreviewed Windows project file gardening.

* WebCore.vcxproj/WebCore.vcxproj: Add missing SVG files and put things in their proper
folders.
* WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.

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

6 years ago[Win] Unreviewed gardening.
bfulgham@apple.com [Tue, 20 Jan 2015 23:32:26 +0000 (23:32 +0000)]
[Win] Unreviewed gardening.

* win/tools/vsprops/FeatureDefines.props: Add feature definition for SVG converter,
but do NOT turn it on.
* win/tools/vsprops/FeatureDefinesCairo.props: Ditto.

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

6 years agoURLFilterParser dismisses the last atom when parsing a builtin character class
benjamin@webkit.org [Tue, 20 Jan 2015 23:11:17 +0000 (23:11 +0000)]
URLFilterParser dismisses the last atom when parsing a builtin character class
https://bugs.webkit.org/show_bug.cgi?id=140695

Reviewed by Andreas Kling.

The pending atom was not sunk before creating the new atom.

* contentextensions/URLFilterParser.cpp:
(WebCore::ContentExtensions::GraphBuilder::atomBuiltInCharacterClass):

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

6 years agoFast path for casting JSValue to JSDocument*.
akling@apple.com [Tue, 20 Jan 2015 23:10:12 +0000 (23:10 +0000)]
Fast path for casting JSValue to JSDocument*.
<https://webkit.org/b/134655>

Add a custom JSType bit for JSDocument so we can quickly cast to it
from JSValue in the DocumentPrototype functions. This removes a bunch
of grunt work and branches from common functions like getElementById.

Also removed GetCastingHelperForBaseObject and replace it with
simple jsCasts since we don't need dynamic type checks for the base.

Reviewed by Darin Adler.

* WebCore.xcodeproj/project.pbxproj:
* bindings/js/JSDOMWrapper.h:
* bindings/js/JSDocumentCustom.h:
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateHeader):
(GetCastingHelperForThisObject):
(GenerateImplementation):
(GetCastingHelperForBaseObject): Deleted.
* dom/Document.idl:

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

6 years agoFix EWS python unit tests and address code comments as per 140476
commit-queue@webkit.org [Tue, 20 Jan 2015 22:43:36 +0000 (22:43 +0000)]
Fix EWS python unit tests and address code comments as per 140476
https://bugs.webkit.org/show_bug.cgi?id=140637

Patch by Jake Nielsen <jacob_nielsen@apple.com> on 2015-01-20
Reviewed by David Kilzer.

* Scripts/webkitpy/port/base.py:
(Port):
(Port.__init__):
Adds DEFAULT_ARCHITECTURE member.
(Port.architecture):
Removes architecture member and instead uses
self.get_option('architecture'). Also removes redundant architecture
method.
(Port.set_architecture):
Adds a setter for the architecture variable to be able to set a flag
upon modification.
(Port.test_configuration):
Uses self.architecture() instead of self._architecture.
* Scripts/webkitpy/port/ios.py:
Overrides DEFAULT_ARCHITECTURE.
(IOSPort):
(IOSPort.determine_full_port_name):
Uses subprocess.check_output instead of Popen. Uses rstrip instead of
strip. Fixes regex to not match arbitrary characters after the
relevent digits are matched.
(IOSPort.__init__):
Removes old _architecture defaulting strategy.
(IOSPort._build_driver_flags):
Uses self.architecture() instead of self._architecture.
(IOSSimulatorPort):
Overrides DEFAULT_ARCHITECTURE.
(IOSSimulatorPort.__init__):
Removes old _architecture defaulting strategy.
* Scripts/webkitpy/port/mac.py:
(MacPort):
Overrides DEFAULT_ARCHITECTURE.
(MacPort.__init__):
Removes old _architecture defaulting strategy.
* Scripts/webkitpy/tool/commands/earlywarningsystem.py:
(AbstractEarlyWarningSystem.run_command):
Checks the did_override_architecture flag to determine whether to add
the --architecture option.
* Scripts/webkitpy/tool/commands/earlywarningsystem_unittest.py:
Uses ews.architecture rather than trying to discern the correct
architecture using a port object.
(EarlyWarningSystemTest._default_expected_logs):
* Scripts/webkitpy/tool/commands/queues.py:
Removes use of optparse, and removes the import statement.
(AbstractQueue.__init__):
(PatchProcessingQueue.begin_work_queue):

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

6 years agoUnreviewed, rolling out r178751.
commit-queue@webkit.org [Tue, 20 Jan 2015 22:43:06 +0000 (22:43 +0000)]
Unreviewed, rolling out r178751.
https://bugs.webkit.org/show_bug.cgi?id=140694

Caused 32-bit JSC test failures (Requested by JoePeck on
#webkit).

Reverted changeset:

"put_by_val_direct need to check the property is index or not
for using putDirect / putDirectIndex"
https://bugs.webkit.org/show_bug.cgi?id=140426
http://trac.webkit.org/changeset/178751

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

6 years ago[iOS][WK2] Redraw find-in-page indicator on rotation
mhock@apple.com [Tue, 20 Jan 2015 22:21:26 +0000 (22:21 +0000)]
[iOS][WK2] Redraw find-in-page indicator on rotation
https://bugs.webkit.org/show_bug.cgi?id=140632
<rdar://problem/18858394>

Reviewed by Tim Horton.

* WebProcess/WebPage/FindController.cpp:
(WebKit::FindController::redraw): Add method to redraw find indicator (only used by iOS).
* WebProcess/WebPage/FindController.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::mainFrameDidLayout):
* WebProcess/WebPage/ios/FindControllerIOS.mm:
(WebKit::FindController::updateFindIndicator): Redraw should not trigger zoom.

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

6 years agoSimple line layout: Use FlowContents::Segment::text instead of renderer when possible.
zalan@apple.com [Tue, 20 Jan 2015 22:07:17 +0000 (22:07 +0000)]
Simple line layout: Use FlowContents::Segment::text instead of renderer when possible.
https://bugs.webkit.org/show_bug.cgi?id=140692

Reviewed by Myles C. Maxfield.

No change in functionality.

* rendering/SimpleLineLayoutResolver.cpp:
(WebCore::SimpleLineLayout::RunResolver::Run::text):

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

6 years agoSwitch to comparing PLATFORM_NAME in terms of macosx
ddkilzer@apple.com [Tue, 20 Jan 2015 21:49:47 +0000 (21:49 +0000)]
Switch to comparing PLATFORM_NAME in terms of macosx
<http://webkit.org/b/139516>

Reviewed by Timothy Hatcher.

Source/WebCore:

* bindings/scripts/preprocessor.pm:
(applyPreprocessor):
* generate-export-file:
(preprocessorMacros):

Source/WebKit:

* WebKit.xcodeproj/project.pbxproj:

Source/WebKit/mac:

* MigrateHeaders.make:
* postprocess-headers.sh:

Source/WebKit2:

* WebKit2.xcodeproj/project.pbxproj:
* mac/rewrite-availability-macros.sh: Remove the else block that
checked for an unknown PLATFORM_NAME.

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

6 years agoAttempt to fix 32bits builds after r178743
benjamin@webkit.org [Tue, 20 Jan 2015 21:46:42 +0000 (21:46 +0000)]
Attempt to fix 32bits builds after r178743

* contentextensions/ContentExtensionsBackend.cpp:
(WebCore::ContentExtensions::ContentExtensionsBackend::shouldBlockURL):

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

6 years agoput_by_val_direct need to check the property is index or not for using putDirect...
utatane.tea@gmail.com [Tue, 20 Jan 2015 21:14:48 +0000 (21:14 +0000)]
put_by_val_direct need to check the property is index or not for using putDirect / putDirectIndex
https://bugs.webkit.org/show_bug.cgi?id=140426

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

In the put_by_val_direct operation, we use JSObject::putDirect.
However, it only accepts non-index property. For index property, we need to use JSObject::putDirectIndex.
This patch changes Identifier::asIndex() to return Optional<uint32_t>.
It forces callers to check the value is index or not explicitly.
Additionally, it checks toString-ed Identifier is index or not to choose putDirect / putDirectIndex.

* bytecode/GetByIdStatus.cpp:
(JSC::GetByIdStatus::computeFor):
* bytecode/PutByIdStatus.cpp:
(JSC::PutByIdStatus::computeFor):
* bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::emitDirectPutById):
* dfg/DFGOperations.cpp:
(JSC::DFG::operationPutByValInternal):
* jit/JITOperations.cpp:
* jit/Repatch.cpp:
(JSC::emitPutTransitionStubAndGetOldStructure):
* jsc.cpp:
* llint/LLIntSlowPaths.cpp:
(JSC::LLInt::LLINT_SLOW_PATH_DECL):
* runtime/Arguments.cpp:
(JSC::Arguments::getOwnPropertySlot):
(JSC::Arguments::put):
(JSC::Arguments::deleteProperty):
(JSC::Arguments::defineOwnProperty):
* runtime/ArrayPrototype.cpp:
(JSC::arrayProtoFuncSort):
* runtime/JSArray.cpp:
(JSC::JSArray::defineOwnProperty):
* runtime/JSCJSValue.cpp:
(JSC::JSValue::putToPrimitive):
* runtime/JSGenericTypedArrayViewInlines.h:
(JSC::JSGenericTypedArrayView<Adaptor>::getOwnPropertySlot):
(JSC::JSGenericTypedArrayView<Adaptor>::put):
(JSC::JSGenericTypedArrayView<Adaptor>::defineOwnProperty):
(JSC::JSGenericTypedArrayView<Adaptor>::deleteProperty):
* runtime/JSObject.cpp:
(JSC::JSObject::put):
(JSC::JSObject::putDirectAccessor):
(JSC::JSObject::putDirectCustomAccessor):
(JSC::JSObject::deleteProperty):
(JSC::JSObject::putDirectMayBeIndex):
(JSC::JSObject::defineOwnProperty):
* runtime/JSObject.h:
(JSC::JSObject::getOwnPropertySlot):
(JSC::JSObject::getPropertySlot):
(JSC::JSObject::putDirectInternal):
* runtime/JSString.cpp:
(JSC::JSString::getStringPropertyDescriptor):
* runtime/JSString.h:
(JSC::JSString::getStringPropertySlot):
* runtime/LiteralParser.cpp:
(JSC::LiteralParser<CharType>::parse):
* runtime/PropertyName.h:
(JSC::toUInt32FromCharacters):
(JSC::toUInt32FromStringImpl):
(JSC::PropertyName::asIndex):
* runtime/PropertyNameArray.cpp:
(JSC::PropertyNameArray::add):
* runtime/StringObject.cpp:
(JSC::StringObject::deleteProperty):
* runtime/Structure.cpp:
(JSC::Structure::prototypeChainMayInterceptStoreTo):

Source/WebCore:

Test: js/dfg-put-by-val-direct-with-edge-numbers.html

* bindings/js/JSDOMWindowCustom.cpp:
(WebCore::JSDOMWindow::getOwnPropertySlot):
* bindings/js/JSHTMLAllCollectionCustom.cpp:
(WebCore::callHTMLAllCollection):
(WebCore::JSHTMLAllCollection::item):
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateGetOwnPropertySlotBody):
(GenerateImplementation):
* bindings/scripts/test/JS/JSFloat64Array.cpp:
(WebCore::JSFloat64Array::getOwnPropertySlot):
(WebCore::JSFloat64Array::getOwnPropertyDescriptor):
(WebCore::JSFloat64Array::put):
* bindings/scripts/test/JS/JSTestEventTarget.cpp:
(WebCore::JSTestEventTarget::getOwnPropertySlot):
* bridge/runtime_array.cpp:
(JSC::RuntimeArray::getOwnPropertySlot):
(JSC::RuntimeArray::put):

LayoutTests:

* js/dfg-put-by-val-direct-with-edge-numbers-expected.txt: Added.
* js/dfg-put-by-val-direct-with-edge-numbers.html: Added.
* js/script-tests/dfg-put-by-val-direct-with-edge-numbers.js: Added.
(lookupWithKey):
(lookupWithKey2):
(toStringThrowsError.toString):
* resources/js-test-pre.js:

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

6 years agoDrop width / height shorthands code from StylePropertyShorthand.*
cdumez@apple.com [Tue, 20 Jan 2015 20:54:19 +0000 (20:54 +0000)]
Drop width / height shorthands code from StylePropertyShorthand.*
https://bugs.webkit.org/show_bug.cgi?id=140686

Reviewed by Andreas Kling.

Drop width / height shorthands code from StylePropertyShorthand.*.
width / height are not shorthands for min-width/max-width and
min-height/max-height. Also, only matchingCustomShorthandsForLonghand()
treats these as shorthands. For e.g, the reverse method
(indexOfShorthandForLonghand()) does not.

* css/StylePropertyShorthand.cpp:
(WebCore::widthShorthand): Deleted.
(WebCore::heightShorthand): Deleted.
* css/StylePropertyShorthand.h:
(WebCore::matchingCustomShorthandsForLonghand):

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

6 years agoAdd a mechanism to ignore previous content extension rules
benjamin@webkit.org [Tue, 20 Jan 2015 20:46:16 +0000 (20:46 +0000)]
Add a mechanism to ignore previous content extension rules
https://bugs.webkit.org/show_bug.cgi?id=140663

Reviewed by Andreas Kling.

* contentextensions/ContentExtensionRule.h:
* contentextensions/ContentExtensionsBackend.cpp:
(WebCore::ContentExtensions::ContentExtensionsBackend::shouldBlockURL):
* contentextensions/ContentExtensionsManager.cpp:
(WebCore::ContentExtensions::ExtensionsManager::loadAction):

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

6 years agoResolve the epsilon transitions for each state upfront instead of dynamically
benjamin@webkit.org [Tue, 20 Jan 2015 20:43:33 +0000 (20:43 +0000)]
Resolve the epsilon transitions for each state upfront instead of dynamically
https://bugs.webkit.org/show_bug.cgi?id=140654

Reviewed by Andreas Kling.

Instead of recomputing the epsilon-closure for each set, we compute the closure
of every element at the beginning of the transformation.

We then remove the epsilon transitions from the NFA to simplify populateTransitions().
The epsilon transitions are still there, but they are now in a separate graph we use
in parallel.

* contentextensions/NFAToDFA.cpp:
(WebCore::ContentExtensions::epsilonClosureExcludingSelf):
(WebCore::ContentExtensions::resolveEpsilonClosures):
(WebCore::ContentExtensions::extendSetWithClosure):
(WebCore::ContentExtensions::populateTransitions):
(WebCore::ContentExtensions::NFAToDFA::convert):
(WebCore::ContentExtensions::epsilonClosure): Deleted.
(WebCore::ContentExtensions::populateTransitionsExcludingEpsilon): Deleted.
* contentextensions/NFAToDFA.h:

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

6 years agoLog types of resources being loaded using DiagnosticLoggingClient
cdumez@apple.com [Tue, 20 Jan 2015 20:37:20 +0000 (20:37 +0000)]
Log types of resources being loaded using DiagnosticLoggingClient
https://bugs.webkit.org/show_bug.cgi?id=140682

Reviewed by Andreas Kling.

Log types of resources being loaded using DiagnosticLoggingClient
instead of the legacy FeatureCounter.

* loader/SubresourceLoader.cpp:
(WebCore::logResourceLoaded):
(WebCore::SubresourceLoader::didFinishLoading):
(WebCore::logResourceLoadedUsingFeatureCounter): Deleted.
* page/DiagnosticLoggingKeys.cpp:
(WebCore::DiagnosticLoggingKeys::otherKey):
(WebCore::DiagnosticLoggingKeys::mainResourceKey):
(WebCore::DiagnosticLoggingKeys::loadedKey):
(WebCore::DiagnosticLoggingKeys::imageKey):
(WebCore::DiagnosticLoggingKeys::rawKey):
(WebCore::DiagnosticLoggingKeys::resourceKey):
(WebCore::DiagnosticLoggingKeys::scriptKey):
(WebCore::DiagnosticLoggingKeys::styleSheetKey):
(WebCore::DiagnosticLoggingKeys::svgDocumentKey):
(WebCore::DiagnosticLoggingKeys::fontKey):
* page/DiagnosticLoggingKeys.h:
* platform/FeatureCounterKeys.h:

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

6 years agoSimple line layout: Remove redundant style.preserveNewline check when collapsing...
zalan@apple.com [Tue, 20 Jan 2015 20:29:44 +0000 (20:29 +0000)]
Simple line layout: Remove redundant style.preserveNewline check when collapsing trailing whitespace.
https://bugs.webkit.org/show_bug.cgi?id=140684

Reviewed by Antti Koivisto.

FlowContents::isLineBreak() checks whether we are at a hard newline.

No change in functionality.

* rendering/SimpleLineLayout.cpp:
(WebCore::SimpleLineLayout::removeTrailingWhitespace):

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

6 years agoREGRESSION(178696): Sporadic crashes while garbage collecting
msaboff@apple.com [Tue, 20 Jan 2015 19:35:29 +0000 (19:35 +0000)]
REGRESSION(178696): Sporadic crashes while garbage collecting
https://bugs.webkit.org/show_bug.cgi?id=140688

Reviewed by Geoffrey Garen.

Added missing visitor.append(&thisObject->m_nullSetterFunction).

* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::visitChildren):

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

6 years agobmalloc: a little bit of cleanup
ggaren@apple.com [Tue, 20 Jan 2015 19:29:46 +0000 (19:29 +0000)]
bmalloc: a little bit of cleanup
https://bugs.webkit.org/show_bug.cgi?id=140687

Reviewed by Anders Carlsson.

* bmalloc/Algorithm.h:
(bmalloc::isPowerOfTwo): Added a check for 0, since 0 would break a lot
of code.

* bmalloc/BoundaryTag.h:
* bmalloc/BoundaryTagInlines.h:
(bmalloc::BoundaryTag::mergeLeft):
(bmalloc::BoundaryTag::mergeRight):
(bmalloc::BoundaryTag::merge):
(bmalloc::BoundaryTag::deallocate):
(bmalloc::BoundaryTag::split):
(bmalloc::BoundaryTag::allocate):
(bmalloc::BoundaryTag::mergeLargeLeft): Deleted.
(bmalloc::BoundaryTag::mergeLargeRight): Deleted.
(bmalloc::BoundaryTag::mergeLarge): Deleted.
(bmalloc::BoundaryTag::splitLarge): Deleted. Removed the word "Large"
from all these functions, since boundary tags always pertain to large
objects, and putting the word "Large" everywhere wasn't helping to
explain that.

* bmalloc/Heap.cpp:
(bmalloc::Heap::allocateXLarge):
(bmalloc::Heap::findXLarge):
(bmalloc::Heap::deallocateXLarge):
* bmalloc/Heap.h:
* bmalloc/VMHeap.h:
(bmalloc::VMHeap::allocateXLarge): Deleted.
(bmalloc::VMHeap::findXLarge): Deleted.
(bmalloc::VMHeap::deallocateXLarge): Deleted. Moved XLarge allocation
from VMHeap to Heap. Since the purpose of the VMHeap is to cache VM
ranges, and the VMHeap never caches any XLarge ranges, it doesn't
really make sense for the VMHeap to be involved.

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

6 years ago[mac] Fix test expectations after r178188
commit-queue@webkit.org [Tue, 20 Jan 2015 19:28:13 +0000 (19:28 +0000)]
[mac] Fix test expectations after r178188
https://bugs.webkit.org/show_bug.cgi?id=140641

Patch by Jeremy Jones <jeremyj@apple.com> on 2015-01-20
Reviewed by Alexey Proskuryakov.

Remove references to removed tests.

* platform/mac/TestExpectations:
removed reference to fast/workers/storage/use-same-database-in-page-and-workers.html

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

6 years agoFix failed to build for Linux/MIPS64EL
berto@igalia.com [Tue, 20 Jan 2015 19:12:24 +0000 (19:12 +0000)]
Fix failed to build for Linux/MIPS64EL
https://bugs.webkit.org/show_bug.cgi?id=124370

Patch by YunQiang Su <wzssyqa@gmail.com> on 2015-01-20
Reviewed by Darin Adler.

Add MIPS64EL support.

* wtf/Platform.h:
* wtf/dtoa/utils.h:

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

6 years agoAdd a way to collect scrolling performance data (viewport tile coverage) with UI...
simon.fraser@apple.com [Tue, 20 Jan 2015 18:40:33 +0000 (18:40 +0000)]
Add a way to collect scrolling performance data (viewport tile coverage) with UI-side compositing
https://bugs.webkit.org/show_bug.cgi?id=140474

Reviewed by Tim Horton.
Source/WebCore:

Add accessors for standard names for container CALayer for each of the tile grids,
and when tile grids are swapped, update those names as appropriate.

* WebCore.exp.in:
* platform/graphics/ca/TileController.cpp:
(WebCore::TileController::tileGridContainerLayerName):
(WebCore::TileController::zoomedOutTileGridContainerLayerName):
(WebCore::TileController::setContentsScale):
* platform/graphics/ca/TileController.h:
* platform/graphics/ca/TileGrid.cpp:
(WebCore::TileGrid::TileGrid):
(WebCore::TileGrid::setIsZoomedOutTileGrid):
* platform/graphics/ca/TileGrid.h:

Source/WebKit2:

Add a private method to enable scrolling data collection to WKWebView. When enabled, create
a RemoteLayerTreeScrollingPerformanceData object that collects "blank pixel" data on
every layer tree commit and scroll, and stores them in a vector. A second SPI call
allows retrieval of an NSArray of this data.

To allow RemoteLayerTreeScrollingPerformanceData to find the correct layer which
contains the main tile grid, we set a layer name on the appropriate layer (even
in release builds).

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView visibleRectInScreenCoordinates]):
(-[WKWebView _didCommitLayerTree:]):
(-[WKWebView scrollViewDidScroll:]):
(-[WKWebView _setScrollPerformanceDataCollectionEnabled:]):
(-[WKWebView _scrollPerformanceDataCollectionEnabled]):
(-[WKWebView _scrollPerformanceData]):
* UIProcess/API/Cocoa/WKWebViewPrivate.h:
* UIProcess/Cocoa/RemoteLayerTreeScrollingPerformanceData.h: Added.
(WebKit::RemoteLayerTreeScrollingPerformanceData::BlankPixelCount::BlankPixelCount):
* UIProcess/Cocoa/RemoteLayerTreeScrollingPerformanceData.mm: Added.
(WebKit::RemoteLayerTreeScrollingPerformanceData::RemoteLayerTreeScrollingPerformanceData):
(WebKit::RemoteLayerTreeScrollingPerformanceData::~RemoteLayerTreeScrollingPerformanceData):
(WebKit::RemoteLayerTreeScrollingPerformanceData::didCommitLayerTree):
(WebKit::RemoteLayerTreeScrollingPerformanceData::didScroll):
(WebKit::RemoteLayerTreeScrollingPerformanceData::BlankPixelCount::canCoalesce):
(WebKit::RemoteLayerTreeScrollingPerformanceData::appendBlankPixelCount):
(WebKit::RemoteLayerTreeScrollingPerformanceData::data):
(WebKit::findTileGridContainerLayer):
(WebKit::RemoteLayerTreeScrollingPerformanceData::blankPixelCount):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::WebPageProxy):
(WebKit::WebPageProxy::setScrollPerformanceDataCollectionEnabled):
* UIProcess/WebPageProxy.h:
(WebKit::WebPageProxy::scrollPerformanceDataCollectionEnabled):
(WebKit::WebPageProxy::scrollingPerformanceData):
* WebKit2.xcodeproj/project.pbxproj:

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

6 years agoMake ASan do bounds checks for WTF::Vector
ap@apple.com [Tue, 20 Jan 2015 18:27:48 +0000 (18:27 +0000)]
Make ASan do bounds checks for WTF::Vector
https://bugs.webkit.org/show_bug.cgi?id=140631
rdar://problem/19437718

Reviewed by Darin Adler.

* wtf/SizeLimits.cpp: Disable Vector object size checks for ASan enabled builds.

* wtf/Vector.h:
(WTF::VectorBuffer::endOfBuffer):
(WTF::Vector::Vector):
(WTF::Vector::~Vector):
(WTF::Vector::swap):
(WTF::OverflowHandler>::Vector):
(WTF::=):
(WTF::OverflowHandler>::fill):
(WTF::OverflowHandler>::resize):
(WTF::OverflowHandler>::shrink):
(WTF::OverflowHandler>::grow):
(WTF::OverflowHandler>::asanSetInitialBufferSizeTo):
(WTF::OverflowHandler>::asanSetBufferSizeToFullCapacity):
(WTF::OverflowHandler>::asanBufferSizeWillChangeTo):
(WTF::OverflowHandler>::reserveCapacity):
(WTF::OverflowHandler>::tryReserveCapacity):
(WTF::OverflowHandler>::shrinkCapacity):
(WTF::OverflowHandler>::append):
(WTF::OverflowHandler>::tryAppend):
(WTF::OverflowHandler>::appendSlowCase):
(WTF::OverflowHandler>::uncheckedAppend):
(WTF::OverflowHandler>::insert):
(WTF::OverflowHandler>::remove):
(WTF::OverflowHandler>::releaseBuffer):

* wtf/Compiler.h: Changed ASAN_ENABLED macro fallback value from false to 0,
MSVC was not happy with false.

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

6 years agofast/hidpi/image-srcset-change-dynamically-from-js-2x.html is flaky
ap@apple.com [Tue, 20 Jan 2015 18:26:00 +0000 (18:26 +0000)]
fast/hidpi/image-srcset-change-dynamically-from-js-2x.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=140649

fast/dom/HTMLImageElement/sizes/image-sizes-js-change.html is failing on some bots
https://bugs.webkit.org/show_bug.cgi?id=134769

Reviewed by Darin Adler.

Streamline resources/srcset-helper.js and remove races.

* TestExpectations: Unskip fast/dom/HTMLImageElement/sizes/image-sizes-js-change.html.

* fast/hidpi/resources/srcset-helper.js: Deleted. We aleady had a copy in /resources,
no need for two copies.

* resources/srcset-helper.js: This script used to depend on setBackingScaleFactor
invoke its callback really fast, which is not guaranteed. Also, it had broken logic
that used non-existent window.deviceScaleFactor.

* fast/dom/HTMLImageElement/sizes/image-sizes-2x.html:
* fast/dom/HTMLImageElement/sizes/image-sizes-js-change-expected.txt:
* fast/dom/HTMLImageElement/sizes/image-sizes-js-change.html:
* fast/dom/HTMLImageElement/sizes/image-sizes-js-innerhtml-expected.txt:
* fast/dom/HTMLImageElement/sizes/image-sizes-js-innerhtml.html:
Updated to run the tests from runTest() function, not a load event handler.
Where appropriate, changed from testRunner.dumpResourceLoadCallbacks() to
testRunner.dumpResourceResponseMIMETypes(), because the latter doesn't unnecessarily
include reloaded scripts. It feels somewhat hacky, but the hack is already used in
fast/hidpi, and it improves output.

* fast/hidpi/image-srcset-change-dynamically-from-js-1x.html:
* fast/hidpi/image-srcset-change-dynamically-from-js-2x.html:
* fast/hidpi/image-srcset-fraction-1.5x.html:
* fast/hidpi/image-srcset-fraction.html:
* fast/hidpi/image-srcset-intrinsic-size.html:
* fast/hidpi/image-srcset-invalid-descriptor.html:
* fast/hidpi/image-srcset-invalid-inputs-except-one.html:
* fast/hidpi/image-srcset-nomodifier.html:
* fast/hidpi/image-srcset-only-src-attribute.html:
* fast/hidpi/image-srcset-remove-dynamically-from-js.html:
* fast/hidpi/image-srcset-same-alternative-for-both-attributes.html:
* fast/hidpi/image-srcset-simple-1x.html:
* fast/hidpi/image-srcset-simple-2x.html:
* fast/hidpi/image-srcset-space-left-nomodifier.html:
* fast/hidpi/image-srcset-space-prefix-nomodifier.html:
* fast/hidpi/image-srcset-space-suffix-nomodifier.html:
* fast/hidpi/image-srcset-space-surrounded-nomodifier.html:
* fast/hidpi/image-srcset-src-selection-1x-both.html:
* fast/hidpi/image-srcset-src-selection-1x.html:
* fast/hidpi/image-srcset-src-selection-2x.html:
* fast/hidpi/image-srcset-viewport-modifiers.html:
Updated to run the tests from runTest() function, not a load event handler.

* http/tests/loading/sizes/preload-image-sizes-2x-expected.txt: Updated results
for srcset-helper.js now always starting the redirect after the load is fully finished.

* svg/css/svg-resource-fragment-identifier-img-src.html: Updated for the unified
location of the script.

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

6 years agoAttempt to fix Mountain Lion and EFL tests.
weinig@apple.com [Tue, 20 Jan 2015 17:51:29 +0000 (17:51 +0000)]
Attempt to fix Mountain Lion and EFL tests.

* WebKitTestRunner/TestController.cpp:
(WTR::TestController::initialize):
Disable Process-per-tab and network process on Mountain Lion and EFL.

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

6 years agoRemove non-Windows cruft from WebKit/win/Plugins
ossy@webkit.org [Tue, 20 Jan 2015 17:34:15 +0000 (17:34 +0000)]
Remove non-Windows cruft from WebKit/win/Plugins
https://bugs.webkit.org/show_bug.cgi?id=140675

Reviewed by Anders Carlsson.

Source/WebKit/win:

* Plugins/PluginDatabase.cpp:
(WebCore::PluginDatabase::defaultPluginDirectories):
(WebCore::PluginDatabase::isPreferredPluginDirectory):
(WebCore::PluginDatabase::getPluginPathsInDirectories):
* Plugins/PluginDebug.cpp:
(WebCore::prettyNameForNPNVariable):
(WebCore::prettyNameForNPPVariable):
(WebCore::prettyNameForDrawingModel): Deleted.
(WebCore::prettyNameForEventModel): Deleted.
* Plugins/PluginDebug.h:
* Plugins/PluginPackage.cpp:
(WebCore::PluginPackage::compareFileVersion):
(WebCore::PluginPackage::determineQuirks): Deleted.
(WebCore::PluginPackage::determineModuleVersionFromDescription): Deleted.
(WebCore::PluginPackage::hash): Deleted.
(WebCore::PluginPackage::equal): Deleted.
* Plugins/PluginView.cpp:
(WebCore::PluginView::setFrameRect):
(WebCore::PluginView::handleEvent):
(WebCore::PluginView::stop):
(WebCore::PluginView::setValue):
(WebCore::PluginView::PluginView):
* Plugins/PluginView.h:
(WebCore::PluginView::platformPluginWidget): Deleted.
(WebCore::PluginView::setPlatformPluginWidget): Deleted.
* Plugins/PluginViewWin.cpp:
(windowHandleForPageClient):
(WebCore::PluginView::hookedBeginPaint):
(WebCore::PluginView::hookedEndPaint):
(WebCore::hook):
(WebCore::registerPluginView):
(WebCore::PluginView::paint):
(WebCore::PluginView::handleMouseEvent):
(WebCore::PluginView::setNPWindowRect):
(WebCore::PluginView::platformStart):
(WebCore::PluginView::snapshot):
* Plugins/npapi.cpp:
(NPN_InvalidateRect):

Source/WTF:

* wtf/FeatureDefines.h:

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

6 years agoFix unused-private-field warning in IconEfl.cpp
ossy@webkit.org [Tue, 20 Jan 2015 17:25:13 +0000 (17:25 +0000)]
Fix unused-private-field warning in IconEfl.cpp
https://bugs.webkit.org/show_bug.cgi?id=140676

Reviewed by Darin Adler.

* platform/graphics/Icon.h:
* platform/graphics/efl/IconEfl.cpp:
(WebCore::Icon::Icon): Deleted.

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

6 years agoFix unused-private-field warning in FontCustomPlatformDataFreeType.cpp
ossy@webkit.org [Tue, 20 Jan 2015 17:23:16 +0000 (17:23 +0000)]
Fix unused-private-field warning in FontCustomPlatformDataFreeType.cpp
https://bugs.webkit.org/show_bug.cgi?id=140677

Reviewed by Martin Robinson.

* platform/graphics/cairo/FontCustomPlatformData.h:
* platform/graphics/freetype/FontCustomPlatformDataFreeType.cpp:
(WebCore::FontCustomPlatformData::FontCustomPlatformData):
(WebCore::FontCustomPlatformData::~FontCustomPlatformData):

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

6 years agoPlugin content not loaded.
commit-queue@webkit.org [Tue, 20 Jan 2015 17:21:32 +0000 (17:21 +0000)]
Plugin content not loaded.
https://bugs.webkit.org/show_bug.cgi?id=140672

Patch by peavo@outlook.com <peavo@outlook.com> on 2015-01-20
Reviewed by Brent Fulgham.

It seems this is caused by a std::unique_ptr in CClass::methodNamed being moved,
resetting its raw pointer. The raw pointer, which now is null, is then returned
from the method.

* bridge/c/c_class.cpp:
(JSC::Bindings::CClass::methodNamed):
(JSC::Bindings::CClass::fieldNamed):

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

6 years agoRemove SVGElementInstanceList, m_instanceUnderMouse, DUMP_INSTANCE_TREE, DUMP_SHADOW_TREE
darin@apple.com [Tue, 20 Jan 2015 17:11:30 +0000 (17:11 +0000)]
Remove SVGElementInstanceList, m_instanceUnderMouse, DUMP_INSTANCE_TREE, DUMP_SHADOW_TREE
https://bugs.webkit.org/show_bug.cgi?id=140679

Reviewed by Anders Carlsson.

Source/WebCore:

First step in removing the SVG instance tree.
All based on redoing the same excellent work Rob Buis did to remove this in Blink in crbug.com/313438.

* CMakeLists.txt: Removed the source files.
* DerivedSources.cpp: Ditto.
* DerivedSources.make: Ditto.
* WebCore.vcxproj/WebCore.vcxproj: Ditto.
* WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
* WebCore.xcodeproj/project.pbxproj: Ditto.

* page/EventHandler.cpp:
(WebCore::EventHandler::clear): Removed code to set unused m_instanceUnderMouse.
(WebCore::EventHandler::updateMouseEventTargetNode): Ditto.
* page/EventHandler.h: Removed m_instanceUnderMouse.

* svg/SVGAllInOne.cpp: Removed the source files.
* svg/SVGElementInstance.cpp:
(WebCore::SVGElementInstance::childNodes): Deleted.
* svg/SVGElementInstance.h: Removed childNodes.
* svg/SVGElementInstance.idl: Ditto.
* svg/SVGElementInstanceList.cpp: Removed.
* svg/SVGElementInstanceList.h: Removed.
* svg/SVGElementInstanceList.idl: Removed.
* svg/SVGUseElement.cpp:
(WebCore::dumpInstanceTree): Deleted.
(WebCore::SVGUseElement::buildShadowAndInstanceTree): Removed DUMP_INSTANCE_TREE and
DUMP_SHADOW_TREE code.

Tools:

* Scripts/webkitperl/filter-build-webkit_unittest/shouldIgnoreLine_unittests.pl:
Removed a reference to SVGElementInstanceList.

LayoutTests:

* fast/dom/script-tests/non-numeric-values-numeric-parameters.js:
* js/dom/global-constructors-attributes-expected.txt:
* platform/efl/js/dom/global-constructors-attributes-expected.txt:
* platform/gtk/js/dom/global-constructors-attributes-expected.txt:
* platform/ios-sim-deprecated/fast/dom/Window/window-property-descriptors-expected.txt:
* platform/ios-sim-deprecated/fast/js/global-constructors-expected.txt:
* platform/ios-sim-deprecated/js/dom/global-constructors-attributes-expected.txt:
* platform/mac-mavericks/js/dom/global-constructors-attributes-expected.txt:
* platform/mac-mountainlion/js/dom/global-constructors-attributes-expected.txt:
* platform/mac/js/dom/global-constructors-attributes-expected.txt:
* platform/win/js/dom/global-constructors-attributes-expected.txt:
* svg/custom/global-constructors-expected.txt:
* svg/custom/script-tests/global-constructors.js:
* svg/dom/svg2-inheritance-expected.txt:
* svg/dom/svg2-inheritance.html:
Removed all tests and results referencing SVGElementInstanceList.

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

6 years agoWeb Replay: code generator should take supplemental specifications and allow cross...
burg@cs.washington.edu [Tue, 20 Jan 2015 16:52:18 +0000 (16:52 +0000)]
Web Replay: code generator should take supplemental specifications and allow cross-framework references
https://bugs.webkit.org/show_bug.cgi?id=136312

Reviewed by Joseph Pecoraro.

Source/JavaScriptCore:

Some types are shared between replay inputs from different frameworks.
Previously, these type declarations were duplicated in every input
specification file in which they were used. This caused some type encoding
traits to be emitted twice if used from WebCore inputs and WebKit2 inputs.

This patch teaches the replay inputs code generator to accept multiple
input specification files. Inputs can freely reference types from other
frameworks without duplicating declarations.

On the code generation side, the model could contain types and inputs from
frameworks that are not the target framework. Only generate code for the
target framework.

To properly generate cross-framework type encoding traits, use
Type.encoding_type_argument in more places, and add the export macro for WebCore
and the Test framework.

Adjust some tests so that enum coverage is preserved by moving the enum types
into "Test" (the target framework for tests).

* JavaScriptCore.vcxproj/copy-files.cmd:
For Windows, copy over JSInputs.json as if it were a private header.

* JavaScriptCore.xcodeproj/project.pbxproj: Make JSInputs.json a private header.
* replay/JSInputs.json:
Put all primitive types and WTF types in this specification file.

* replay/scripts/CodeGeneratorReplayInputs.py:
(Input.__init__):
(InputsModel.__init__): Keep track of the input's framework.
(InputsModel.parse_specification): Parse the framework here. Adjust to new format,
and allow either types or inputs to be missing from a single file.

(InputsModel.parse_type_with_framework):
(InputsModel.parse_input_with_framework):
(Generator.should_generate_item): Added helper method.
(Generator.generate_header): Filter inputs to generate.
(Generator.generate_implementation): Filter inputs to generate.
(Generator.generate_enum_trait_declaration): Filter enums to generate.
Add WEBCORE_EXPORT macro to enum encoding traits.

(Generator.generate_for_each_macro): Filter inputs to generate.
(Generator.generate_enum_trait_implementation): Filter enums to generate.
(generate_from_specifications): Added.
(generate_from_specifications.parse_json_from_file):
(InputsModel.parse_toplevel): Deleted.
(InputsModel.parse_type_with_framework_name): Deleted.
(InputsModel.parse_input): Deleted.
(generate_from_specification): Deleted.
* replay/scripts/CodeGeneratorReplayInputsTemplates.py:
* replay/scripts/tests/expected/fail-on-no-inputs.json-error: Removed.
* replay/scripts/tests/expected/fail-on-no-types.json-error: Removed.
* replay/scripts/tests/expected/generate-enum-encoding-helpers-with-guarded-values.json-TestReplayInputs.cpp:
* replay/scripts/tests/expected/generate-enum-encoding-helpers-with-guarded-values.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-enum-encoding-helpers.json-TestReplayInputs.cpp:
* replay/scripts/tests/expected/generate-enum-encoding-helpers.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-enum-with-guard.json-TestReplayInputs.cpp:
* replay/scripts/tests/expected/generate-enum-with-guard.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-enums-with-same-base-name.json-TestReplayInputs.cpp:
* replay/scripts/tests/expected/generate-enums-with-same-base-name.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-input-with-guard.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-input-with-vector-members.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-inputs-with-flags.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-memoized-type-modes.json-TestReplayInputs.h:
* replay/scripts/tests/fail-on-c-style-enum-no-storage.json:
* replay/scripts/tests/fail-on-duplicate-enum-type.json:
* replay/scripts/tests/fail-on-duplicate-input-names.json:
* replay/scripts/tests/fail-on-duplicate-type-names.json:
* replay/scripts/tests/fail-on-enum-type-missing-values.json:
* replay/scripts/tests/fail-on-missing-input-member-name.json:
* replay/scripts/tests/fail-on-missing-input-name.json:
* replay/scripts/tests/fail-on-missing-input-queue.json:
* replay/scripts/tests/fail-on-missing-type-mode.json:
* replay/scripts/tests/fail-on-missing-type-name.json:
* replay/scripts/tests/fail-on-no-inputs.json:
Removed, no longer required to be in a single file.

* replay/scripts/tests/fail-on-no-types.json:
Removed, no longer required to be in a single file.

* replay/scripts/tests/fail-on-unknown-input-queue.json:
* replay/scripts/tests/fail-on-unknown-member-type.json:
* replay/scripts/tests/fail-on-unknown-type-mode.json:
* replay/scripts/tests/generate-enum-encoding-helpers-with-guarded-values.json:
* replay/scripts/tests/generate-enum-encoding-helpers.json:
* replay/scripts/tests/generate-enum-with-guard.json:
Include enums that are and are not generated.

* replay/scripts/tests/generate-enums-with-same-base-name.json:
* replay/scripts/tests/generate-event-loop-shape-types.json:
* replay/scripts/tests/generate-input-with-guard.json:
* replay/scripts/tests/generate-input-with-vector-members.json:
* replay/scripts/tests/generate-inputs-with-flags.json:
* replay/scripts/tests/generate-memoized-type-modes.json:

Source/WebCore:

Changes covered by existing input generator tests.

* DerivedSources.make: Add JSInputs.json as supplemental specification.
* replay/WebInputs.json: Moved common types to JSInputs.json.

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

6 years ago[GTK] WebViewTest should prohibit overriding initializeWebExtensions()
commit-queue@webkit.org [Tue, 20 Jan 2015 16:49:33 +0000 (16:49 +0000)]
[GTK] WebViewTest should prohibit overriding initializeWebExtensions()
https://bugs.webkit.org/show_bug.cgi?id=140028

Patch by Michael Catanzaro <mcatanzaro@igalia.com> on 2015-01-20
Reviewed by Carlos Garcia Campos.

This won't work as expected, since this function is called before the
WebViewTest constructor completes.

* TestWebKitAPI/gtk/WebKit2Gtk/WebViewTest.h:

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

6 years agoFix unused-const-variable warning in RenderLayerCompositor.cpp
ossy@webkit.org [Tue, 20 Jan 2015 16:48:46 +0000 (16:48 +0000)]
Fix unused-const-variable warning in RenderLayerCompositor.cpp
https://bugs.webkit.org/show_bug.cgi?id=140678

Reviewed by Simon Fraser.

* rendering/RenderLayerCompositor.cpp:

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

6 years ago[gstreamer] Fix expression result unused warning in GRefPtrGStreamer.cpp
ossy@webkit.org [Tue, 20 Jan 2015 16:24:08 +0000 (16:24 +0000)]
[gstreamer] Fix expression result unused warning in GRefPtrGStreamer.cpp
https://bugs.webkit.org/show_bug.cgi?id=140671

Reviewed by Philippe Normand.

* platform/graphics/gstreamer/GRefPtrGStreamer.cpp:
(WTF::refGPtr<GstToc>):

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

6 years agoSupport "plus-darker" in mix-blend mode
dino@apple.com [Tue, 20 Jan 2015 16:03:53 +0000 (16:03 +0000)]
Support "plus-darker" in mix-blend mode
https://bugs.webkit.org/show_bug.cgi?id=140646
<rdar://problem/19523370>

Reviewed by Simon Fraser.

Source/WebCore:

Support the "plus-darker" blending mode to CSS.
See: https://lists.w3.org/Archives/Public/public-fx/2015JanMar/0021.html

Test: css3/blending/svg-blend-plus-darker.html

* css/CSSParser.cpp:
(WebCore::isValidKeywordPropertyAndValue): mix-blend-mode can now accept
the new keyword.
* css/CSSPrimitiveValueMappings.h: Add the mappings.
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
(WebCore::CSSPrimitiveValue::operator BlendMode):
* platform/graphics/GraphicsTypes.cpp: Add the new GraphicsType.
* platform/graphics/GraphicsTypes.h:
* platform/graphics/ca/mac/PlatformCAFiltersMac.mm: Map to the CA compositing filter.
(PlatformCAFilters::setBlendingFiltersOnLayer):
* platform/graphics/cg/GraphicsContextCG.cpp:
(WebCore::GraphicsContext::setPlatformCompositeOperation): Map to the CG blending flag.

Source/WebKit2:

Output the appropriate blending type when logging.

* Shared/mac/RemoteLayerTreeTransaction.mm:
(WebKit::RemoteLayerTreeTextStream::operator<<):

LayoutTests:

Add tests and new expected results for plus-darker.

* css3/blending/blend-mode-property-parsing-expected.txt:
* css3/blending/blend-mode-simple-composited.html:
* css3/blending/blend-mode-simple.html:
* css3/blending/script-tests/blend-mode-property-parsing.js:
* css3/blending/svg-blend-plus-darker.html: Added.
* platform/mac/css3/blending/blend-mode-simple-composited-expected.png:
* platform/mac/css3/blending/blend-mode-simple-composited-expected.txt:
* platform/mac/css3/blending/blend-mode-simple-expected.png:
* platform/mac/css3/blending/blend-mode-simple-expected.txt:
* platform/mac/css3/blending/svg-blend-plus-darker-expected.txt: Added.

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

6 years agoconfigure-xcode-for-ios-development needs to update iPhoneOS SDK
ddkilzer@apple.com [Tue, 20 Jan 2015 15:51:58 +0000 (15:51 +0000)]
configure-xcode-for-ios-development needs to update iPhoneOS SDK
<http://webkit.org/b/140661>

Reviewed by Daniel Bates.

* Scripts/configure-xcode-for-ios-development: Add for() loop to
run createXcodeSpecificationFilesForSDKIfNeeded() for both
"iphoneos" and "iphonesimulator" SDKs.
(createXcodeSpecificationFilesForSDKIfNeeded): Extracted from
the main body of the script.

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

6 years ago[GTK] Cannot compile 2.7.3 on PowerPC machines
carlosgc@webkit.org [Tue, 20 Jan 2015 14:01:31 +0000 (14:01 +0000)]
[GTK] Cannot compile 2.7.3 on PowerPC machines
https://bugs.webkit.org/show_bug.cgi?id=140616

Include climits for INT_MAX and wtf/DataLog.h for dataLogF

Patch by Tomas Popela <tpopela@redhat.com> on 2015-01-20
Reviewed by Csaba Osztrogonác.

* runtime/BasicBlockLocation.cpp:

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

6 years agoUnreviewed. Update OptionsGTK.cmake and NEWS for 2.7.4 release.
carlosgc@webkit.org [Tue, 20 Jan 2015 13:43:46 +0000 (13:43 +0000)]
Unreviewed. Update OptionsGTK.cmake and NEWS for 2.7.4 release.

.:

* Source/cmake/OptionsGTK.cmake: Bump version numbers.

Source/WebKit2:

* gtk/NEWS: Add release notes for 2.7.4.

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

6 years ago[EFL] [GTK] Change/supplement expectations for two accessibility layout tests.
commit-queue@webkit.org [Tue, 20 Jan 2015 13:00:15 +0000 (13:00 +0000)]
[EFL] [GTK] Change/supplement expectations for two accessibility layout tests.
https://bugs.webkit.org/show_bug.cgi?id=140620

Unreviewed EFL gardening.

Patch by Andrzej Badowski <a.badowski@samsung.com> on 2015-01-20

* platform/efl/TestExpectations:
* platform/efl/accessibility/media-element-expected.txt:
  Currently, accessibility/media-element.html is positive for EFL with a new, richer description.
* platform/efl/accessibility/render-counter-text-expected.txt: Added.
  Omitted file by r178508.
* platform/gtk/accessibility/render-counter-text-expected.txt: Added.
  Omitted file by r178508.

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

6 years agoFix 'register' storage class specifier is deprecated warning
ossy@webkit.org [Tue, 20 Jan 2015 12:33:38 +0000 (12:33 +0000)]
Fix 'register' storage class specifier is deprecated warning
https://bugs.webkit.org/show_bug.cgi?id=140669

Reviewed by Carlos Garcia Campos.

* platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp:
(webKitWebAudioSrcLoop):

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

6 years ago[GTK] Add API to set the web view editable into WebKit2 GTK+ API
commit-queue@webkit.org [Tue, 20 Jan 2015 11:22:03 +0000 (11:22 +0000)]
[GTK] Add API to set the web view editable into WebKit2 GTK+ API
https://bugs.webkit.org/show_bug.cgi?id=139443

Patch by Tomas Popela <tpopela@redhat.com> on 2015-01-20
Reviewed by Carlos Garcia Campos.

Source/WebKit2:

Provide a way to set the web view editable, without accessing the DOM
and setting the contenteditable attribute to elements.

* UIProcess/API/gtk/WebKitWebView.cpp:
(webkitWebViewSetProperty):
(webkitWebViewGetProperty):
(webkit_web_view_class_init):
(webkit_web_view_is_editable):
(webkit_web_view_set_editable):
* UIProcess/API/gtk/WebKitWebView.h:
* UIProcess/API/gtk/docs/webkit2gtk-sections.txt:

Tools:

Create the new test cases for setting the editable property on the web
view and on the contenteditable enabled document. Also rework the
current tests that are expecting that the web view is editable.

* TestWebKitAPI/Tests/WebKit2Gtk/TestWebViewEditor.cpp:
(loadTestHtml):
(testWebViewEditorCutCopyPasteNonEditable):
(testWebViewEditorCutCopyPasteEditable):
(testWebViewEditorSelectAllNonEditable):
(testWebViewEditorSelectAllEditable):
(runEditorEditableCutTests):
(testWebViewEditorEditableOnNonEditable):
(testWebViewEditorEditableOnContentEditable):
(testWebViewEditorNonEditable):
(beforeAll):
* TestWebKitAPI/gtk/WebKit2Gtk/WebViewTest.cpp:
(WebViewTest::isEditable):
(WebViewTest::setEditable):

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

6 years agoUse DiagnosticLoggingClient to log page cache failures
cdumez@apple.com [Tue, 20 Jan 2015 10:07:21 +0000 (10:07 +0000)]
Use DiagnosticLoggingClient to log page cache failures
https://bugs.webkit.org/show_bug.cgi?id=140650

Reviewed by Andreas Kling.

Use DiagnosticLoggingClient to log page cache failures instead of the
legacy FeatureCounter.

* history/PageCache.cpp:
(WebCore::logPageCacheFailureDiagnosticMessage):
(WebCore::logCanCacheFrameDecision):
(WebCore::logCanCachePageDecision):
(WebCore::PageCache::canCache):
(WebCore::pruningReasonToDiagnosticLoggingKey):
(WebCore::PageCache::take):
(WebCore::PageCache::get):
(WebCore::pruningReasonToFeatureCounterKey): Deleted.
* page/DiagnosticLoggingKeys.cpp:
(WebCore::DiagnosticLoggingKeys::successKey):
(WebCore::DiagnosticLoggingKeys::failureKey):
(WebCore::DiagnosticLoggingKeys::pageLoadedKey):
(WebCore::DiagnosticLoggingKeys::engineFailedToLoadKey):
(WebCore::DiagnosticLoggingKeys::navigationKey):
(WebCore::DiagnosticLoggingKeys::pageCacheKey):
(WebCore::DiagnosticLoggingKeys::noDocumentLoaderKey):
(WebCore::DiagnosticLoggingKeys::mainDocumentErrorKey):
(WebCore::DiagnosticLoggingKeys::isErrorPageKey):
(WebCore::DiagnosticLoggingKeys::hasPluginsKey):
(WebCore::DiagnosticLoggingKeys::httpsNoStoreKey):
(WebCore::DiagnosticLoggingKeys::hasOpenDatabasesKey):
(WebCore::DiagnosticLoggingKeys::noCurrentHistoryItemKey):
(WebCore::DiagnosticLoggingKeys::quirkRedirectComingKey):
(WebCore::DiagnosticLoggingKeys::loadingAPISenseKey):
(WebCore::DiagnosticLoggingKeys::documentLoaderStoppingKey):
(WebCore::DiagnosticLoggingKeys::cannotSuspendActiveDOMObjectsKey):
(WebCore::DiagnosticLoggingKeys::applicationCacheKey):
(WebCore::DiagnosticLoggingKeys::deniedByClientKey):
(WebCore::DiagnosticLoggingKeys::deviceMotionKey):
(WebCore::DiagnosticLoggingKeys::deviceOrientationKey):
(WebCore::DiagnosticLoggingKeys::deviceProximityKey):
(WebCore::DiagnosticLoggingKeys::reloadKey):
(WebCore::DiagnosticLoggingKeys::reloadFromOriginKey):
(WebCore::DiagnosticLoggingKeys::sameLoadKey):
(WebCore::DiagnosticLoggingKeys::expiredKey):
(WebCore::DiagnosticLoggingKeys::prunedDueToMemoryPressureKey):
(WebCore::DiagnosticLoggingKeys::prunedDueToCapacityReached):
(WebCore::DiagnosticLoggingKeys::prunedDueToProcessSuspended):
(WebCore::DiagnosticLoggingKeys::passKey): Deleted.
(WebCore::DiagnosticLoggingKeys::failKey): Deleted.
(WebCore::DiagnosticLoggingKeys::noopKey): Deleted.
* page/DiagnosticLoggingKeys.h:
* platform/FeatureCounterKeys.h:

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

6 years ago[CSS Grid Layout] Wrong arguments passed to computeNormalizedFractionBreadth
svillar@igalia.com [Tue, 20 Jan 2015 09:19:48 +0000 (09:19 +0000)]
[CSS Grid Layout] Wrong arguments passed to computeNormalizedFractionBreadth
https://bugs.webkit.org/show_bug.cgi?id=139058

Reviewed by Andreas Kling.

Source/WebCore:

The method RenderGrid::computeNormalizedFractionBreadth() is
supposed to get as fourth argument either the grid element's
content box size or the max-size of a particular grid item. For
the former we were incorrectly passing the free space after
distributing the available space to tracks.

Apart from that, that method has a bug in its implementation. As
we were using the free space instead of the grid element's content
box size, we didn't have to subtract the usedBreadth of grid
tracks from the passed in value. That did not work for the case of
the caller passing the max-size of a particular item.

* rendering/RenderGrid.cpp:
(WebCore::RenderGrid::computeUsedBreadthOfGridTracks):
(WebCore::RenderGrid::computeNormalizedFractionBreadth):

LayoutTests:

* TestExpectations: Removed the test added in r148643 (missing
from r148642) as the test works as expected now.
* fast/css-grid-layout/flex-and-minmax-content-resolution-rows.html:

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

6 years ago[GTK] Add an option to create WebKitWebView snapshots with transparent background
carlosgc@webkit.org [Tue, 20 Jan 2015 08:29:23 +0000 (08:29 +0000)]
[GTK] Add an option to create WebKitWebView snapshots with transparent background
https://bugs.webkit.org/show_bug.cgi?id=140617

Reviewed by Gustavo Noronha Silva.

Source/WebKit2:

Add WEBKIT_SNAPSHOT_OPTIONS_TRANSPARENT_BACKGROUND flag to not
fill with white the background before rendering the snapshot.

* UIProcess/API/gtk/WebKitWebView.cpp:
(webkit_web_view_get_snapshot): Pass a TransparentBackground
boolean argument to the WEbProcess.
* UIProcess/API/gtk/WebKitWebView.h:
* WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp:
(webkitWebPageDidReceiveMessage): Set the FrameView background as
transparent when TransparentBackground option is True before
rendering the snapshot.

Tools:

* TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitWebView.cpp:
(testWebViewSnapshot): Check that the same snapshot with
transparent background is different than the default one filled
with white.

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

6 years ago[GTK] Add API to change the WebKitWebView background color
carlosgc@webkit.org [Tue, 20 Jan 2015 08:25:55 +0000 (08:25 +0000)]
[GTK] Add API to change the WebKitWebView background color
https://bugs.webkit.org/show_bug.cgi?id=140610

Reviewed by Gustavo Noronha Silva.

Source/WebKit2:

When a color different than the default one (opaque white) is
used, the SetDrawsBackground message is sent to the WebProcess with
a False value to indicate WebCore to not render backgrounds. The
background color passed is saved in the WebPageProxy and used by
the backing store to fill the background before the actual
contents are rendered in the WebView.

* UIProcess/API/gtk/WebKitWebView.cpp:
(webkit_web_view_set_background_color):
(webkit_web_view_get_background_color):
* UIProcess/API/gtk/WebKitWebView.h:
* UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbols.
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::WebPageProxy): Initialize m_backgroundColor member.
* UIProcess/WebPageProxy.h:
(WebKit::WebPageProxy::backgroundColor): Return m_backgroundColor.
(WebKit::WebPageProxy::setBackgroundColor): Set m_backgroundColor.
* UIProcess/cairo/BackingStoreCairo.cpp:
(WebKit::BackingStore::incorporateUpdate): Fill the damage region
with the WebPageProxy background color when the WebProcess is not
rendering backgrounds. If the background color is not fully opaque
we need to clear the region before filling it with the color.

Tools:

Add --bg-color command line option to MiniBrowser to be able to
manually test the API passing any RGBA color to MiniBrowser.
Also add a simple unit test to check that getting and setting
colors from the API point of view.

* MiniBrowser/gtk/BrowserWindow.c:
(browser_window_set_background_color):
* MiniBrowser/gtk/BrowserWindow.h:
* MiniBrowser/gtk/main.c:
(createBrowserWindow):
(parseBackgroundColor):
* TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitWebView.cpp:
(testWebViewBackgroundColor):
(beforeAll):

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

6 years agoRe-enable js/dom/string-replace-exception-crash.html as root problem is fixed.
msaboff@apple.com [Tue, 20 Jan 2015 05:58:26 +0000 (05:58 +0000)]
Re-enable js/dom/string-replace-exception-crash.html as root problem is fixed.
https://bugs.webkit.org/show_bug.cgi?id=140666

Rubber Stamped by Filip Pizlo.

* platform/mac/TestExpectations:
Re-enabled js/dom/string-replace-exception-crash.html.

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

6 years ago[Win] Layout Test fast/xmlhttprequest/xmlhttprequest-no-file-access.html is failing
bfulgham@apple.com [Tue, 20 Jan 2015 05:55:43 +0000 (05:55 +0000)]
[Win] Layout Test fast/xmlhttprequest/xmlhttprequest-no-file-access.html is failing
https://bugs.webkit.org/show_bug.cgi?id=140665

Reviewed by Brian Burg.

* DumpRenderTree/win/UIDelegate.cpp:
(UIDelegate::webViewAddMessageToConsole): Correct string search and concatenation to
match expected test output.

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

6 years agoA "cached" null setter should throw a TypeException when called in strict mode and...
msaboff@apple.com [Tue, 20 Jan 2015 05:28:04 +0000 (05:28 +0000)]
A "cached" null setter should throw a TypeException when called in strict mode and doesn't
https://bugs.webkit.org/show_bug.cgi?id=139418

Reviewed by Filip Pizlo.

Source/JavaScriptCore:

Made a new NullSetterFunction class similar to NullGetterFunction.  The difference is that
NullSetterFunction will throw a TypeError per the ECMA262 spec for a strict mode caller.

* CMakeLists.txt:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj.filters:
* JavaScriptCore.xcodeproj/project.pbxproj:
Added new files NullSetterFunction.cpp and NullSetterFunction.h.

* runtime/GetterSetter.h:
(JSC::GetterSetter::GetterSetter):
(JSC::GetterSetter::isSetterNull):
(JSC::GetterSetter::setSetter):
Change setter instances from using NullGetterFunction to using NullSetterFunction.

* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
* runtime/JSGlobalObject.h:
(JSC::JSGlobalObject::nullSetterFunction):
Added m_nullSetterFunction and accessor.

* runtime/NullSetterFunction.cpp: Added.
(JSC::GetCallerStrictnessFunctor::GetCallerStrictnessFunctor):
(JSC::GetCallerStrictnessFunctor::operator()):
(JSC::GetCallerStrictnessFunctor::callerIsStrict):
(JSC::callerIsStrict):
Method to determine if the caller is in strict mode.

(JSC::callReturnUndefined):
(JSC::constructReturnUndefined):
(JSC::NullSetterFunction::getCallData):
(JSC::NullSetterFunction::getConstructData):
* runtime/NullSetterFunction.h: Added.
(JSC::NullSetterFunction::create):
(JSC::NullSetterFunction::createStructure):
(JSC::NullSetterFunction::NullSetterFunction):
Class with handlers for a null setter.

LayoutTests:

New regression test.

* js/regress-139418-expected.txt: Added.
* js/regress-139418.html: Added.
* js/script-tests/regress-139418.js: Added.
(InnerObjectNoSetter):
(InnerObjectNoSetter.prototype.get enabled):
(StrictOuterObject):
(StrictOuterObject.prototype.get enabled):
(StrictOuterObject.prototype.set enabled):

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

6 years agoWeb Inspector: Provide a front end for JSC's Control Flow Profiler
saambarati1@gmail.com [Tue, 20 Jan 2015 05:17:07 +0000 (05:17 +0000)]
Web Inspector: Provide a front end for JSC's Control Flow Profiler
https://bugs.webkit.org/show_bug.cgi?id=138454

Reviewed by Timothy Hatcher.

Source/JavaScriptCore:

This patch puts the final touches on what JSC needs to provide
for the Web Inspector to show a UI for the control flow profiler.

* inspector/agents/InspectorRuntimeAgent.cpp:
(Inspector::recompileAllJSFunctionsForTypeProfiling):
* runtime/ControlFlowProfiler.cpp:
(JSC::ControlFlowProfiler::getBasicBlocksForSourceID):
* runtime/FunctionHasExecutedCache.cpp:
(JSC::FunctionHasExecutedCache::getFunctionRanges):
(JSC::FunctionHasExecutedCache::getUnexecutedFunctionRanges): Deleted.
* runtime/FunctionHasExecutedCache.h:

Source/WebInspectorUI:

This patch creates a user interface for JSC's control flow profiler.
The Web Inspector gets basic block ranges from JSC, and displays
basic blocks that have not executed as having a gray background.

BasicBlockAnnotator is the class responsible for this UI logic.
It also does a few nifty things when presenting a UI for this gray
background color: if an entire line of code is within the basic
block's boundary, the annotator will not just highlight the background
behind the text, but the background of the entire line itself. This
provides a nicer experience when glancing through large JavaScript files.

This patch also adds some necessary wrapper methods inside TextEditor
for accessing CodeMirror's text highlighting functionality. It also
creates a way for TextEditor and SourceCodeTextEditor to listen
for focus events inside CodeMirror.

* UserInterface/Controllers/AnnotatorManager.js: Removed.
* UserInterface/Controllers/BasicBlockAnnotator.js: Added.
(WebInspector.BasicBlockAnnotator):
(WebInspector.BasicBlockAnnotator.prototype.clearAnnotations):
(WebInspector.BasicBlockAnnotator.prototype.insertAnnotations):
(WebInspector.BasicBlockAnnotator.prototype._annotateBasicBlockExecutionRanges.):
(WebInspector.BasicBlockAnnotator.prototype._annotateBasicBlockExecutionRanges):
(WebInspector.BasicBlockAnnotator.prototype.set _highlightTextForBasicBlock):
(WebInspector.BasicBlockAnnotator.prototype._isTextRangeOnlyWhitespace):
(WebInspector.BasicBlockAnnotator.prototype._canGrayOutEntireLine):
(WebInspector.BasicBlockAnnotator.prototype._grayOutLine):
(WebInspector.BasicBlockAnnotator.prototype._clearRangeForBasicBlockMarker.get marker):
(WebInspector.BasicBlockAnnotator.prototype._clearRangeForBasicBlockMarker):
* UserInterface/Main.html:
* UserInterface/Views/SourceCodeTextEditor.css:
(.basic-block-has-not-executed):
(.basic-block-has-not-executed-prepend::before):
* UserInterface/Views/SourceCodeTextEditor.js:
(WebInspector.SourceCodeTextEditor):
(WebInspector.SourceCodeTextEditor.prototype.shown):
(WebInspector.SourceCodeTextEditor.prototype.hidden):
(WebInspector.SourceCodeTextEditor.prototype.canShowTypeAnnotations):
(WebInspector.SourceCodeTextEditor.prototype.contentDidChange):
(WebInspector.SourceCodeTextEditor.prototype.gainedFocus):
(WebInspector.SourceCodeTextEditor.prototype.lostFocus):
(WebInspector.SourceCodeTextEditor.prototype.toggleTypeAnnotations):
(WebInspector.SourceCodeTextEditor.prototype.prettyPrint):
(WebInspector.SourceCodeTextEditor.prototype._populateWithContent):
(WebInspector.SourceCodeTextEditor.prototype._debuggerDidPause):
(WebInspector.SourceCodeTextEditor.prototype._debuggerDidResume):
(WebInspector.SourceCodeTextEditor.prototype._updateTokenTrackingControllerState):
(WebInspector.SourceCodeTextEditor.prototype._makeTypeTokenAnnotator):
(WebInspector.SourceCodeTextEditor.prototype._makeBasicBlockAnnotator):
(WebInspector.SourceCodeTextEditor.prototype._makeTypeTokenScrollEventHandler.scrollHandler):
(WebInspector.SourceCodeTextEditor.prototype._makeTypeTokenScrollEventHandler):
* UserInterface/Views/TextEditor.js:
(WebInspector.TextEditor):
(WebInspector.TextEditor.prototype.getTextInRange):
(WebInspector.TextEditor.prototype.addStyleToTextRange):
(WebInspector.TextEditor.prototype.gainedFocus):
(WebInspector.TextEditor.prototype.lostFocus):

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

6 years ago[iOS] Only use LLVM static library arguments on 64-bit builds of libllvmForJSC.dylib
ddkilzer@apple.com [Tue, 20 Jan 2015 05:09:03 +0000 (05:09 +0000)]
[iOS] Only use LLVM static library arguments on 64-bit builds of libllvmForJSC.dylib
<http://webkit.org/b/140658>

Reviewed by Filip Pizlo.

* Configurations/LLVMForJSC.xcconfig: Set OTHER_LDFLAGS_LLVM
only when building for 64-bit architectures.

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

6 years agoClosureCallStubRoutine no longer needs codeOrigin
fpizlo@apple.com [Tue, 20 Jan 2015 05:01:26 +0000 (05:01 +0000)]
ClosureCallStubRoutine no longer needs codeOrigin
https://bugs.webkit.org/show_bug.cgi?id=140659

Reviewed by Michael Saboff.

Once upon a time, we would look for the CodeOrigin associated with a return PC. This search
would start with the CodeBlock according to the caller frame's call frame header. But if the
call was a closure call, the return PC would be inside some closure call stub. So if the
CodeBlock search failed, we would search *all* closure call stub routines to see which one
encompasses the return PC. Then, we would use the CodeOrigin stored in the stub routine
object. This was all a bunch of madness, and we actually got rid of it - we now determine
the CodeOrigin for a call frame using the encoded code origin bits inside the tag of the
argument count.

This patch removes the final vestiges of the madness:

- Remove the totally unused method declaration for the thing that did the closure call stub
  search.

- Remove the CodeOrigin field from the ClosureCallStubRoutine. Except for that crazy search
  that we no longer do, everyone else who finds a ClosureCallStubRoutine will find it via
  the CallLinkInfo. The CallLinkInfo also has the CodeOrigin, so we don't need this field
  anymore.

* bytecode/CodeBlock.h:
* jit/ClosureCallStubRoutine.cpp:
(JSC::ClosureCallStubRoutine::ClosureCallStubRoutine):
* jit/ClosureCallStubRoutine.h:
(JSC::ClosureCallStubRoutine::executable):
(JSC::ClosureCallStubRoutine::codeOrigin): Deleted.
* jit/Repatch.cpp:
(JSC::linkClosureCall):

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

6 years agoBasic block start offsets should never be larger than end offsets in the control...
saambarati1@gmail.com [Tue, 20 Jan 2015 04:47:55 +0000 (04:47 +0000)]
Basic block start offsets should never be larger than end offsets in the control flow profiler
https://bugs.webkit.org/show_bug.cgi?id=140377

Reviewed by Filip Pizlo.

The bytecode generator will emit code more than once for some AST nodes. For instance,
the finally block of TryNode will emit two code paths for its finally block: one for
the normal path, and another for the path where an exception is thrown in the catch block.

This repeated code emission of the same AST node previously broke how the control
flow profiler computed text ranges of basic blocks because when the same AST node
is emitted multiple times, there is a good chance that there are ranges that span
from the end offset of one of these duplicated nodes back to the start offset of
the same duplicated node. This caused a basic block range to report a larger start
offset than end offset. This was incorrect. Now, when this situation is encountered
while linking a CodeBlock, the faulty range in question is ignored.

* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::CodeBlock):
(JSC::CodeBlock::insertBasicBlockBoundariesForControlFlowProfiler):
* bytecode/CodeBlock.h:
* bytecompiler/NodesCodegen.cpp:
(JSC::ForInNode::emitMultiLoopBytecode):
(JSC::ForOfNode::emitBytecode):
(JSC::TryNode::emitBytecode):
* parser/Parser.cpp:
(JSC::Parser<LexerType>::parseConditionalExpression):
* runtime/ControlFlowProfiler.cpp:
(JSC::ControlFlowProfiler::ControlFlowProfiler):
* runtime/ControlFlowProfiler.h:
(JSC::ControlFlowProfiler::dummyBasicBlock):

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

6 years ago[SVG -> OTF Converter] Flip the switch on
mmaxfield@apple.com [Tue, 20 Jan 2015 04:04:13 +0000 (04:04 +0000)]
[SVG -> OTF Converter] Flip the switch on
https://bugs.webkit.org/show_bug.cgi?id=140592

Source/JavaScriptCore:

Reviewed by Antti Koivisto.

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

Reviewed by Antti Koivisto.

* Configurations/FeatureDefines.xcconfig:

Source/WebKit/mac:

Reviewed by Antti Koivisto.

* Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

Reviewed by Antti Koivisto.

* Configurations/FeatureDefines.xcconfig:

LayoutTests:

Updating test expected results.

svg/W3C-SVG-1.1/fonts-glyph-04-t.svg tests something which isn't spec'ed
and is impossible to perform with the converter, so I have deleted that
test.

svg/custom/skip-underline-missing-glyph-expected.html was testing
incorrect behavior, so I have updated the test.

The getStartPositionOfChar() calls in svg/text/kerning.svg and
svg/text/multichar-glyph.svg are currently impossible to be implemented
correctly with the converter, so I have updated the expected results to
test for the updated results of those calls.

Reviewed by Antti Koivisto.

* platform/mac/TestExpectations:
* platform/mac/svg/W3C-SVG-1.1-SE/color-prop-05-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/coords-dom-01-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/coords-dom-02-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/coords-dom-03-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/coords-dom-04-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/coords-units-03-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/filters-felem-01-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/filters-image-03-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/interact-pointer-03-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/linking-uri-01-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/painting-marker-07-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/paths-dom-02-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/pservers-grad-17-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/pservers-grad-20-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/pservers-pattern-03-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/pservers-pattern-04-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/struct-use-14-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/styling-css-04-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/styling-pres-02-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/svgdom-over-01-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/text-intro-02-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/text-intro-09-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/text-tref-03-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/text-tspan-02-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-01-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-02-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-03-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-04-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-05-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-06-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-07-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/filters-light-04-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/filters-turb-02-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/fonts-elem-05-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/fonts-elem-06-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/fonts-glyph-04-t-expected.png: Removed.
* platform/mac/svg/W3C-SVG-1.1/fonts-glyph-04-t-expected.txt: Removed.
* platform/mac/svg/W3C-SVG-1.1/fonts-kern-01-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/masking-mask-01-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/render-elems-06-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/render-elems-07-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/render-elems-08-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/render-groups-01-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/render-groups-03-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/text-align-08-b-expected.txt:
* platform/mac/svg/custom/glyph-setting-d-attribute-expected.txt:
* platform/mac/svg/custom/scrolling-embedded-svg-file-image-repaint-problem-expected.txt:
* platform/mac/svg/custom/svg-fonts-fallback-expected.txt:
* platform/mac/svg/foreignObject/text-tref-02-b-expected.txt:
* platform/mac/svg/text/kerning-expected.txt:
* platform/mac/svg/text/multichar-glyph-expected.txt:
* platform/mac/svg/transforms/text-with-mask-with-svg-transform-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1-SE/coords-units-03-b-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1-SE/styling-css-04-f-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1-SE/text-intro-02-b-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1-SE/text-intro-05-t-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1-SE/text-intro-09-b-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/filters-light-04-f-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/fonts-elem-05-t-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/fonts-elem-06-t-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/fonts-kern-01-t-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/masking-mask-01-b-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/render-elems-06-t-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/render-elems-07-t-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/render-elems-08-t-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/render-groups-01-b-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/render-groups-03-t-expected.txt:
* platform/mac-mountainlion/svg/W3C-SVG-1.1/text-align-08-b-expected.txt:
* platform/mac-mountainlion/svg/custom/scrolling-embedded-svg-file-image-repaint-problem-expected.txt:
* platform/mac-mountainlion/svg/custom/svg-fonts-fallback-expected.txt:
* platform/mac-mountainlion/svg/text/kerning-expected.txt:
* platform/mac-mountainlion/svg/text/multichar-glyph-expected.txt:
* platform/mac-mountainlion/svg/transforms/text-with-mask-with-svg-transform-expected.txt:
* svg/W3C-SVG-1.1/fonts-glyph-04-t-expected.txt: Removed.
* svg/W3C-SVG-1.1/fonts-glyph-04-t-w3c.png: Removed.
* svg/W3C-SVG-1.1/fonts-glyph-04-t.svg: Removed.
* svg/custom/skip-underline-missing-glyph-expected.html: Removed.
* svg/custom/skip-underline-missing-glyph-expected.txt: Added.
* svg/custom/skip-underline-missing-glyph.html:

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

6 years ago<https://webkit.org/b/140504> REGRESSION (r178452): Visited link coloring only appear...
mrowe@apple.com [Tue, 20 Jan 2015 03:46:02 +0000 (03:46 +0000)]
<https://webkit.org/b/140504> REGRESSION (r178452): Visited link coloring only appears to work in the first web process

Roll out r178452 since it broke visited link coloring.

Reviewed by Anders Carlsson.

* UIProcess/VisitedLinkProvider.cpp:
(WebKit::VisitedLinkProvider::~VisitedLinkProvider):
(WebKit::VisitedLinkProvider::addProcess):
(WebKit::VisitedLinkProvider::removeProcess):
(WebKit::VisitedLinkProvider::removeAll):
(WebKit::VisitedLinkProvider::webProcessWillOpenConnection):
(WebKit::VisitedLinkProvider::webProcessDidCloseConnection):
(WebKit::VisitedLinkProvider::pendingVisitedLinksTimerFired):
(WebKit::VisitedLinkProvider::resizeTable):
* UIProcess/VisitedLinkProvider.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::WebPageProxy):
(WebKit::WebPageProxy::processDidFinishLaunching):
* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::disconnect):
(WebKit::WebProcessProxy::addVisitedLinkProvider):
(WebKit::WebProcessProxy::didDestroyVisitedLinkProvider):
* UIProcess/WebProcessProxy.h:

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

6 years agoUnreviewed, rolling out r178683.
commit-queue@webkit.org [Tue, 20 Jan 2015 03:43:00 +0000 (03:43 +0000)]
Unreviewed, rolling out r178683.
https://bugs.webkit.org/show_bug.cgi?id=140657

Lots of asserts in tests. (Requested by JoePeck on #webkit).

Reverted changeset:

"LayoutState and subtree layout code should use
RenderElement."
https://bugs.webkit.org/show_bug.cgi?id=126878
http://trac.webkit.org/changeset/178683

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

6 years agoSprinkle some CTTE on API::PolicyClient and API::FormClient
weinig@apple.com [Tue, 20 Jan 2015 03:38:56 +0000 (03:38 +0000)]
Sprinkle some CTTE on API::PolicyClient and API::FormClient
https://bugs.webkit.org/show_bug.cgi?id=140656

Reviewed by Tim Horton.

- Use references rather than pointers where possible.
- Store and pass the listeners as Refs.
- Make API::FormClient more like API::PolicyClient by making it the
  responsibility of the client implementation to call the default policy.

* UIProcess/API/APIFormClient.h:
(API::FormClient::willSubmitForm):
* UIProcess/API/APIPolicyClient.h:
(API::PolicyClient::decidePolicyForNavigationAction):
(API::PolicyClient::decidePolicyForNewWindowAction):
(API::PolicyClient::decidePolicyForResponse):
(API::PolicyClient::unableToImplementPolicy):
* UIProcess/API/C/WKPage.cpp:
(WKPageSetPagePolicyClient):
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _setFormDelegate:]):
* UIProcess/API/gtk/WebKitPolicyClient.cpp:
* UIProcess/Cocoa/NavigationState.h:
* UIProcess/Cocoa/NavigationState.mm:
(WebKit::NavigationState::PolicyClient::decidePolicyForNavigationAction):
(WebKit::NavigationState::PolicyClient::decidePolicyForNewWindowAction):
(WebKit::NavigationState::PolicyClient::decidePolicyForResponse):
* UIProcess/WebFormClient.cpp:
(WebKit::WebFormClient::willSubmitForm):
* UIProcess/WebFormClient.h:
* UIProcess/WebFrameProxy.cpp:
(WebKit::WebFrameProxy::setUpPolicyListenerProxy):
(WebKit::WebFrameProxy::setUpFormSubmissionListenerProxy):
* UIProcess/WebFrameProxy.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::decidePolicyForNavigationAction):
(WebKit::WebPageProxy::decidePolicyForNewWindowAction):
(WebKit::WebPageProxy::decidePolicyForResponse):
(WebKit::WebPageProxy::unableToImplementPolicy):
(WebKit::WebPageProxy::willSubmitForm):

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

6 years ago[Win] Unreviewed gardening.
bfulgham@apple.com [Tue, 20 Jan 2015 02:10:30 +0000 (02:10 +0000)]
[Win] Unreviewed gardening.

Avoid compiling files twice when they are included in an 'AllInOne.cpp' file.

* WebCore.vcxproj/WebCore.vcxproj: Mark several files as 'not to be built', since
they are also build as part of an 'AllInOne.cpp' file.

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

6 years agoRemove the support for custom suffixes on ChangeLog
benjamin@webkit.org [Tue, 20 Jan 2015 02:06:03 +0000 (02:06 +0000)]
Remove the support for custom suffixes on ChangeLog
https://bugs.webkit.org/show_bug.cgi?id=140648

Patch by Benjamin Poulain <bpoulain@apple.com> on 2015-01-19
Reviewed by David Kilzer.

Custom suffixes were used for the iOS branch of WebKit.
Now that everything is opensource, there is no need for it.

* Scripts/VCSUtils.pm:
(changeLogSuffix): Deleted.
(changeLogFileName): Deleted.
* Scripts/commit-log-editor:
* Scripts/prepare-ChangeLog:
(getLatestChangeLogs):
(generateNewChangeLogs):
(generateFileList):
* Scripts/resolve-ChangeLogs:
(findChangeLog):

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

6 years agoMerge API::ProcessPoolConfiguration and _WKProcessPoolConfiguration
weinig@apple.com [Tue, 20 Jan 2015 01:35:47 +0000 (01:35 +0000)]
Merge API::ProcessPoolConfiguration and _WKProcessPoolConfiguration
https://bugs.webkit.org/show_bug.cgi?id=140601

Reviewed by Anders Carlsson.

- Converts _WKProcessPoolConfiguration to be backed via API::ProcessPoolConfiguration.
- Expands API::ProcessPoolConfiguration to add all the parameters necessary to fully
  initialize a WebProcessPool. This allows -[WKProcessPool _initWithConfiguration:] to
  be a simple pass through initializer, which in turn allows us to consider WebProcessPools
  created on the C++ and Objective-C sides as equivalent.
- Makes WebProcessPool own the reference to the API::ProcessPoolConfiguration (rather than
  the WKProcessPool wrapper).

* Shared/Cocoa/APIObject.mm:
(API::Object::newObject):
Create the API::ProcessPoolConfigurations using [_WKProcessPoolConfiguration alloc] as its
storage..

* UIProcess/API/APIProcessPoolConfiguration.cpp:
(API::ProcessPoolConfiguration::create):
(API::ProcessPoolConfiguration::createWithLegacyOptions):
(API::ProcessPoolConfiguration::ProcessPoolConfiguration):
(API::ProcessPoolConfiguration::~ProcessPoolConfiguration):
(API::ProcessPoolConfiguration::copy):
(API::ProcessPoolConfiguration::webProcessPoolConfiguration): Deleted.
* UIProcess/API/APIProcessPoolConfiguration.h:
Add the remaining initialization parameters and add a convenience create function
for configuring legacy WebProcessPools (for use by the C-SPI).

* UIProcess/API/APIWebsiteDataStore.cpp:
(API::WebsiteDataStore::websiteDataDirectoryFileSystemRepresentation):
* UIProcess/API/APIWebsiteDataStore.h:
* UIProcess/API/Cocoa/APIWebsiteDataStoreCocoa.mm:
(API::WebsiteDataStore::websiteDataDirectoryFileSystemRepresentation):
(API::WebsiteDataStore::defaultDataStoreConfiguration):
Expose helper for getting the website data directories for use in the ProcessPoolConfiguration.

* UIProcess/API/C/WKContext.cpp:
(WKContextCreate):
(WKContextCreateWithInjectedBundlePath):
(WKContextCreateWithConfiguration):
Use ProcessPoolConfiguration::createWithLegacyOptions() to keep backwards compatibility.

* UIProcess/API/C/WKContextConfigurationRef.cpp:
(WKContextConfigurationCreate):
Update for ProcessPoolConfiguration::create() returning a Ref. Note, this function
was not changed to call ProcessPoolConfiguration::createWithLegacyOptions() since
it has not been around long enough to warrant it.

* UIProcess/API/Cocoa/WKProcessGroup.mm:
(-[WKProcessGroup initWithInjectedBundleURL:]):
Use ProcessPoolConfiguration::createWithLegacyOptions() to keep backwards compatibility.

* UIProcess/API/Cocoa/WKProcessPool.mm:
(-[WKProcessPool description]):
Change to pull the configuration from the underlying API::Object.

(-[WKProcessPool _configuration]):
Change to pull the configuration from the underlying API::Object and call the new
copy() helper on it.

(-[WKProcessPool _initWithConfiguration:]):
Convert to be a simple pass through to API::Object::constructInWrapper.

(websiteDataDirectoryURL): Deleted.
Moved to APIWebsiteDataStore.h

* UIProcess/API/Cocoa/WKProcessPoolInternal.h:
Removes the _WKProcessPoolConfiguration member, now that it is stored on the WebProcessPool.

* UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm:
(-[_WKProcessPoolConfiguration init]):
(-[_WKProcessPoolConfiguration dealloc]):
Added to support API::Object bridging.

(-[_WKProcessPoolConfiguration injectedBundleURL]):
(-[_WKProcessPoolConfiguration setInjectedBundleURL:]):
Convert to getting the URL from the underlying object. Moved the exception
that used to be on creation of the WKProcessPool.

(-[_WKProcessPoolConfiguration maximumProcessCount]):
(-[_WKProcessPoolConfiguration setMaximumProcessCount:]):
Convert to getting the count from the underlying object.

(-[_WKProcessPoolConfiguration cachePartitionedURLSchemes]):
Convert to constructing the NSArray on demand from the underlying Vector.

(-[_WKProcessPoolConfiguration setCachePartitionedURLSchemes:]):
Converts the NSArray to a Vector rather than storing the array.

* UIProcess/API/Cocoa/_WKProcessPoolConfigurationInternal.h: Added.
(API::wrapper):
Add boilerplate for API::Object bridging.

* UIProcess/API/gtk/WebKitWebContext.cpp:
(webkitWebContextConstructed):
Update to use API::ProcessPoolConfiguration::createWithLegacyOptions() to keep backwards compatibility.

* UIProcess/WebInspectorProxy.cpp:
(WebKit::WebInspectorProxy::inspectorProcessPool):
Update to call API::ProcessPoolConfiguration::createWithLegacyOptions().

* UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::create):
(WebKit::websiteDataStoreConfiguration):
(WebKit::WebProcessPool::WebProcessPool):
(WebKit::WebProcessPool::applyPlatformSpecificConfigurationDefaults): Deleted.
This functionality was moved to the constructor of the API::ProcessPoolConfiguration.
* UIProcess/WebProcessPool.h:
Changed to take (and store) a API::ProcessPoolConfiguration rather than the WebProcessPoolConfiguration.

* UIProcess/Cocoa/WebProcessPoolCocoa.mm:
(WebKit::WebProcessPool::legacyPlatformDefaultWebSQLDatabaseDirectory):
(WebKit::WebProcessPool::legacyPlatformDefaultIndexedDBDatabaseDirectory):
(WebKit::WebProcessPool::legacyPlatformDefaultLocalStorageDirectory):
(WebKit::WebProcessPool::legacyPlatformDefaultMediaKeysStorageDirectory):
(WebKit::WebProcessPool::platformDefaultWebSQLDatabaseDirectory): Deleted.
(WebKit::WebProcessPool::platformDefaultIndexedDBDatabaseDirectory): Deleted.
(WebKit::WebProcessPool::platformDefaultLocalStorageDirectory): Deleted.
(WebKit::WebProcessPool::platformDefaultMediaKeysStorageDirectory): Deleted.
* UIProcess/efl/WebContextEfl.cpp:
(WebKit::WebProcessPool::legacyPlatformDefaultWebSQLDatabaseDirectory):
(WebKit::WebProcessPool::legacyPlatformDefaultIndexedDBDatabaseDirectory):
(WebKit::WebProcessPool::legacyPlatformDefaultLocalStorageDirectory):
(WebKit::WebProcessPool::legacyPlatformDefaultMediaKeysStorageDirectory):
(WebKit::WebProcessPool::platformDefaultWebSQLDatabaseDirectory): Deleted.
(WebKit::WebProcessPool::platformDefaultIndexedDBDatabaseDirectory): Deleted.
(WebKit::WebProcessPool::platformDefaultLocalStorageDirectory): Deleted.
(WebKit::WebProcessPool::platformDefaultMediaKeysStorageDirectory): Deleted.
* UIProcess/gtk/WebProcessPoolGtk.cpp:
(WebKit::WebProcessPool::legacyPlatformDefaultWebSQLDatabaseDirectory):
(WebKit::WebProcessPool::legacyPlatformDefaultIndexedDBDatabaseDirectory):
(WebKit::WebProcessPool::legacyPlatformDefaultLocalStorageDirectory):
(WebKit::WebProcessPool::legacyPlatformDefaultMediaKeysStorageDirectory):
(WebKit::WebProcessPool::platformDefaultWebSQLDatabaseDirectory): Deleted.
(WebKit::WebProcessPool::platformDefaultIndexedDBDatabaseDirectory): Deleted.
(WebKit::WebProcessPool::platformDefaultLocalStorageDirectory): Deleted.
(WebKit::WebProcessPool::platformDefaultMediaKeysStorageDirectory): Deleted.
Renamed to make it clear these were the legacy locations for these directories.

* WebKit2.xcodeproj/project.pbxproj:
Added new files.

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

6 years agoStop using FeatureCounter to log navigation types
cdumez@apple.com [Tue, 20 Jan 2015 00:58:42 +0000 (00:58 +0000)]
Stop using FeatureCounter to log navigation types
https://bugs.webkit.org/show_bug.cgi?id=140642

Reviewed by Andreas Kling.

Stop using FeatureCounter to log navigation types now that
DiagnosticLoggingClient is working on iOS.

* loader/FrameLoader.cpp:
(WebCore::logNavigation):
* platform/FeatureCounterKeys.h:

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

6 years agoLayoutState and subtree layout code should use RenderElement.
akling@apple.com [Tue, 20 Jan 2015 00:39:36 +0000 (00:39 +0000)]
LayoutState and subtree layout code should use RenderElement.
<https://webkit.org/b/126878>

Subtree layout will never begin at a RenderText, so tighten up
the code to operate on RenderElements instead of RenderObjects.

Reviewed by Antti Koivisto.

* inspector/InspectorTimelineAgent.cpp:
(WebCore::InspectorTimelineAgent::willLayout):
* page/FrameView.cpp:
(WebCore::FrameView::layoutRoot):
(WebCore::FrameView::layout):
* page/FrameView.h:

    Make FrameView::layoutRoot() return RenderElement*.

* rendering/RenderElement.cpp:
(WebCore::RenderElement::willBeDestroyed):
* rendering/RenderObject.cpp:
(WebCore::RenderObject::willBeDestroyed):
* rendering/RenderObject.h:

    Move subtree layout root clearing logic in willBeDestroyed()
    from RenderObject to RenderElement.

* rendering/LayoutState.cpp:
(WebCore::LayoutState::LayoutState):
* rendering/LayoutState.h:
* rendering/RenderView.h:
* rendering/RenderView.cpp:
(WebCore::RenderView::pushLayoutState):
(WebCore::RenderView::pushLayoutStateForCurrentFlowThread):

    Make all of these functions take RenderElement instead of
    RenderObject since layout never starts from a RenderText.

(WebCore::RenderView::shouldDisableLayoutStateForSubtree):

    Tweak loop since it's never null on first iteration.

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

6 years ago[CMAKE] Fix cmake warning
gyuyoung.kim@samsung.com [Tue, 20 Jan 2015 00:36:36 +0000 (00:36 +0000)]
[CMAKE] Fix cmake warning
https://bugs.webkit.org/show_bug.cgi?id=140497

Reviewed by Gustavo Noronha Silva.

r173155 already tried to fix cmake warning though, the warning is still exist.
CMAKE_LINK_INTERFACE_LIBRARIES seems to cause this warning. Individual target is
already set for their libraries though, INTERFACE_LINK_LIBRARIES contains the list
of transitive link dependencies, and CMAKE_LINK_INTERFACE_LIBRARIES can override
the INTERFACE_LINK_LIBRARIES property when CMP0022 is not set. CMake warns this override.
To avoid it, EFL port doesn't set CMAKE_LINK_INTERFACE_LIBRARIES.

* CMakeLists.txt:

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

6 years agoSource/WebCore:
bdakin@apple.com [Tue, 20 Jan 2015 00:24:09 +0000 (00:24 +0000)]
Source/WebCore:
Speculative build fix.

* platform/spi/mac/NSViewSPI.h:

Source/WebKit/mac:
Speculative build fix.

* WebView/WebView.mm:
(-[WebView _commonInitializationWithFrameName:groupName:]):

Source/WebKit2:
 Speculative build fix.

* UIProcess/API/mac/WKView.mm:
(-[WKView initWithFrame:processPool:configuration:webView:]):

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

6 years agoSpeculative build fix.
bdakin@apple.com [Tue, 20 Jan 2015 00:17:42 +0000 (00:17 +0000)]
Speculative build fix.

* WebView/WebView.mm:
(-[WebView _convertRectFromRootView:]):

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

6 years agoAdjust naming of action menu SPI
timothy_horton@apple.com [Mon, 19 Jan 2015 23:46:06 +0000 (23:46 +0000)]
Adjust naming of action menu SPI
https://bugs.webkit.org/show_bug.cgi?id=140644
<rdar://problem/19448129>

Reviewed by Brian Weinstein.

* platform/spi/mac/NSViewSPI.h:
Add an underscore.

* WebView/WebActionMenuController.mm:
(-[WebActionMenuController prepareForMenu:withEvent:]):
(-[WebActionMenuController willOpenMenu:withEvent:]):
(-[WebActionMenuController didCloseMenu:withEvent:]):
* WebView/WebView.mm:
(-[WebView _commonInitializationWithFrameName:groupName:]):
(-[WebView prepareForMenu:withEvent:]):
(-[WebView willOpenMenu:withEvent:]):
(-[WebView didCloseMenu:withEvent:]):

* UIProcess/API/mac/WKView.mm:
(-[WKView initWithFrame:processPool:configuration:webView:]):
* UIProcess/mac/WKActionMenuController.mm:
(-[WKActionMenuController prepareForMenu:withEvent:]):
(-[WKActionMenuController willOpenMenu:withEvent:]):
(-[WKActionMenuController didCloseMenu:withEvent:]):
(-[WKActionMenuController menuNeedsUpdate:]):
(-[WKActionMenuController _updateActionMenuItems]):

* TestWebKitAPI/Tests/WebKit2ObjC/ActionMenus.mm:
(-[ActionMenusTestWKView runMenuSequenceAtPoint:preDidCloseMenuHandler:]):
(TestWebKitAPI::TEST):

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

6 years ago[Win] Unreviewed Windows gardening.
bfulgham@apple.com [Mon, 19 Jan 2015 23:43:42 +0000 (23:43 +0000)]
[Win] Unreviewed Windows gardening.

Rebaseline a few tests based on current bot output.

* platform/win/fast/regions/multiple-directionality-changes-in-variable-width-regions-expected.txt:
* platform/win/fast/regions/region-dynamic-after-before-expected.txt:
* platform/win/fast/regions/region-generated-content-before-after-expected.txt:
* platform/win/fast/regions/text-region-split-small-pagination-expected.txt:
* platform/win/fast/text/international/thai-baht-space-expected.txt:

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

6 years ago[Mac] Test fix after r178674.
roger_fong@apple.com [Mon, 19 Jan 2015 23:25:02 +0000 (23:25 +0000)]
[Mac] Test fix after r178674.
* platform/mac-mavericks/js/dom/global-constructors-attributes-expected.txt:
* platform/mac-mountainlion/js/dom/global-constructors-attributes-expected.txt:

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

6 years agoREGRESSION (r178290): Yellow highlight from context menu Lookup in Dictionary is
bdakin@apple.com [Mon, 19 Jan 2015 23:24:38 +0000 (23:24 +0000)]
REGRESSION (r178290): Yellow highlight from context menu Lookup in Dictionary is
offset by flipped-ness
https://bugs.webkit.org/show_bug.cgi?id=140643
-and corresponding-
rdar://problem/19489593

Reviewed by Tim Horton.

We universally flipped because we assumed that the root view was flipped and the
WebView was not. However, in Dictionary, the WebView is flipped! So this patch
fixes that assumption by checking the WebView’s flipped-ness.
* WebView/WebView.mm:
(-[WebView _convertRectFromRootView:]):

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

6 years agoCanonicalization of :lang() should preserve the :lang()'s arguments representations
commit-queue@webkit.org [Mon, 19 Jan 2015 23:09:36 +0000 (23:09 +0000)]
Canonicalization of :lang() should preserve the :lang()'s arguments representations
https://bugs.webkit.org/show_bug.cgi?id=139928

Patch by Dhi Aurrahman <diorahman@rockybars.com> on 2015-01-19
Reviewed by Benjamin Poulain.

Source/WebCore:

Preserve the representation of IDENT and STRING when serializing the
:lang(). For example, :lang(foo,"bar", baz) should be serialize as
:lang(foo, "bar", baz) instead of :lang(foo, bar, baz).

Rename CSSParserSelector::setArgumentList, CSSSelector::setArgumentList
and CSSSelector::argumentList to CSSParserSelector::setLangArgumentList,
CSSSelector::setLangArgumentList and CSSSelector::langArgumentList
respectively, since those methods are being exclusively used in respect
with :lang().

Update the test of serializing :lang() with IDENT and STRING arguments.

* css/CSSGrammar.y.in:
* css/CSSParserValues.cpp:
(WebCore::CSSParserSelector::setLangArgumentList):
(WebCore::CSSParserSelector::setArgumentList): Deleted.
* css/CSSParserValues.h:
(WebCore::CSSParserString::tokenType):
(WebCore::CSSParserString::setTokenType):
* css/CSSSelector.cpp:
(WebCore::appendLangArgumentList):
(WebCore::CSSSelector::selectorText):
(WebCore::CSSSelector::setLangArgumentList):
(WebCore::appendArgumentList): Deleted.
(WebCore::CSSSelector::setArgumentList): Deleted.
* css/CSSSelector.h:
(WebCore::CSSSelector::langArgumentList):
(WebCore::CSSSelector::argumentList): Deleted.
* css/SelectorChecker.cpp:
(WebCore::SelectorChecker::checkOne):
* css/SelectorCheckerTestFunctions.h:
(WebCore::matchesLangPseudoClass):

LayoutTests:

* fast/css/css-lang-selector-with-string-arguments-text-expected.txt:
* fast/css/css-lang-selector-with-string-arguments-text.html:

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

6 years agoWebGL2: Support webgl2 context creation.
roger_fong@apple.com [Mon, 19 Jan 2015 22:15:16 +0000 (22:15 +0000)]
WebGL2: Support webgl2 context creation.
https://bugs.webkit.org/show_bug.cgi?id=126408
<rdar://problem/15002170>

Reviewed by Dean Jackson.

Tests covered by existing Khronos tests for WebGL 1.0 conformance.

Create a WebGLRenderingContextBase class that extends to a WebGLRenderingContext and WebGL2RenderingContext.
Replace all previous instances of WebGLRenderingContext usages with WebGLRenderingContextBase usages for now.
As the first step, the WebGL1 and WebGL2 contexts will have the exact same functionality.

* CMakeLists.txt:
* DerivedSources.cpp:
* DerivedSources.make:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
* bindings/js/JSBindingsAllInOne.cpp:
* bindings/js/JSCanvasRenderingContextCustom.cpp:
(WebCore::toJS):
* bindings/js/JSDocumentCustom.cpp:
* bindings/js/JSHTMLCanvasElementCustom.cpp:
* bindings/js/JSWebGL2RenderingContextCustom.cpp: Added.
(WebCore::JSWebGL2RenderingContext::visitAdditionalChildren):
* bindings/js/JSWebGLRenderingContextBaseCustom.cpp: Added.
* bindings/js/JSWebGLRenderingContextCustom.cpp: Move code to JSWebGLRenderingContextBaseCustom.cpp.
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateImplementation):
* html/HTMLCanvasElement.cpp:
(WebCore::HTMLCanvasElement::getContext):
(WebCore::HTMLCanvasElement::reset):
(WebCore::HTMLCanvasElement::paint):
(WebCore::HTMLCanvasElement::getImageData):
* html/canvas/ANGLEInstancedArrays.cpp:
(WebCore::ANGLEInstancedArrays::ANGLEInstancedArrays):
(WebCore::ANGLEInstancedArrays::supported):
* html/canvas/ANGLEInstancedArrays.h:
* html/canvas/CanvasRenderingContext.h:
(WebCore::CanvasRenderingContext::isWebGL1):
(WebCore::CanvasRenderingContext::isWebGL2):
(WebCore::CanvasRenderingContext::is3d):
* html/canvas/EXTBlendMinMax.cpp:
(WebCore::EXTBlendMinMax::EXTBlendMinMax):
* html/canvas/EXTBlendMinMax.h:
* html/canvas/EXTFragDepth.cpp:
(WebCore::EXTFragDepth::EXTFragDepth):
* html/canvas/EXTFragDepth.h:
* html/canvas/EXTShaderTextureLOD.cpp:
(WebCore::EXTShaderTextureLOD::EXTShaderTextureLOD):
* html/canvas/EXTShaderTextureLOD.h:
* html/canvas/EXTTextureFilterAnisotropic.cpp:
(WebCore::EXTTextureFilterAnisotropic::EXTTextureFilterAnisotropic):
* html/canvas/EXTTextureFilterAnisotropic.h:
* html/canvas/EXTsRGB.cpp:
(WebCore::EXTsRGB::EXTsRGB):
* html/canvas/EXTsRGB.h:
* html/canvas/OESElementIndexUint.cpp:
(WebCore::OESElementIndexUint::OESElementIndexUint):
* html/canvas/OESElementIndexUint.h:
* html/canvas/OESStandardDerivatives.cpp:
(WebCore::OESStandardDerivatives::OESStandardDerivatives):
* html/canvas/OESStandardDerivatives.h:
* html/canvas/OESTextureFloat.cpp:
(WebCore::OESTextureFloat::OESTextureFloat):
* html/canvas/OESTextureFloat.h:
* html/canvas/OESTextureFloatLinear.cpp:
(WebCore::OESTextureFloatLinear::OESTextureFloatLinear):
* html/canvas/OESTextureFloatLinear.h:
* html/canvas/OESTextureHalfFloat.cpp:
(WebCore::OESTextureHalfFloat::OESTextureHalfFloat):
* html/canvas/OESTextureHalfFloat.h:
* html/canvas/OESTextureHalfFloatLinear.cpp:
(WebCore::OESTextureHalfFloatLinear::OESTextureHalfFloatLinear):
* html/canvas/OESTextureHalfFloatLinear.h:
* html/canvas/OESVertexArrayObject.cpp:
(WebCore::OESVertexArrayObject::OESVertexArrayObject):
* html/canvas/OESVertexArrayObject.h:
* html/canvas/WebGL2RenderingContext.cpp: Added.
(WebCore::WebGL2RenderingContext::WebGL2RenderingContext):
* html/canvas/WebGL2RenderingContext.h: Added.
* html/canvas/WebGL2RenderingContext.idl: Added.
* html/canvas/WebGLBuffer.cpp:
(WebCore::WebGLBuffer::create):
(WebCore::WebGLBuffer::WebGLBuffer):
* html/canvas/WebGLBuffer.h:
* html/canvas/WebGLCompressedTextureATC.cpp:
(WebCore::WebGLCompressedTextureATC::WebGLCompressedTextureATC):
(WebCore::WebGLCompressedTextureATC::supported):
* html/canvas/WebGLCompressedTextureATC.h:
* html/canvas/WebGLCompressedTexturePVRTC.cpp:
(WebCore::WebGLCompressedTexturePVRTC::WebGLCompressedTexturePVRTC):
(WebCore::WebGLCompressedTexturePVRTC::supported):
* html/canvas/WebGLCompressedTexturePVRTC.h:
* html/canvas/WebGLCompressedTextureS3TC.cpp:
(WebCore::WebGLCompressedTextureS3TC::WebGLCompressedTextureS3TC):
(WebCore::WebGLCompressedTextureS3TC::supported):
* html/canvas/WebGLCompressedTextureS3TC.h:
* html/canvas/WebGLContextGroup.cpp:
(WebCore::WebGLContextGroup::getAGraphicsContext3D):
(WebCore::WebGLContextGroup::addContext):
(WebCore::WebGLContextGroup::removeContext):
(WebCore::WebGLContextGroup::loseContextGroup):
* html/canvas/WebGLContextGroup.h:
* html/canvas/WebGLContextObject.cpp:
(WebCore::WebGLContextObject::WebGLContextObject):
* html/canvas/WebGLContextObject.h:
(WebCore::WebGLContextObject::context):
* html/canvas/WebGLDebugRendererInfo.cpp:
(WebCore::WebGLDebugRendererInfo::WebGLDebugRendererInfo):
* html/canvas/WebGLDebugRendererInfo.h:
* html/canvas/WebGLDebugShaders.cpp:
(WebCore::WebGLDebugShaders::WebGLDebugShaders):
* html/canvas/WebGLDebugShaders.h:
* html/canvas/WebGLDepthTexture.cpp:
(WebCore::WebGLDepthTexture::WebGLDepthTexture):
* html/canvas/WebGLDepthTexture.h:
* html/canvas/WebGLDrawBuffers.cpp:
(WebCore::WebGLDrawBuffers::WebGLDrawBuffers):
(WebCore::WebGLDrawBuffers::supported):
(WebCore::WebGLDrawBuffers::satisfiesWebGLRequirements):
* html/canvas/WebGLDrawBuffers.h:
* html/canvas/WebGLExtension.cpp:
(WebCore::WebGLExtension::WebGLExtension):
* html/canvas/WebGLExtension.h:
(WebCore::WebGLExtension::context):
* html/canvas/WebGLFramebuffer.cpp:
(WebCore::WebGLFramebuffer::create):
(WebCore::WebGLFramebuffer::WebGLFramebuffer):
* html/canvas/WebGLFramebuffer.h:
* html/canvas/WebGLLoseContext.cpp:
(WebCore::WebGLLoseContext::WebGLLoseContext):
(WebCore::WebGLLoseContext::loseContext):
* html/canvas/WebGLLoseContext.h:
* html/canvas/WebGLObject.cpp:
(WebCore::WebGLObject::WebGLObject):
* html/canvas/WebGLObject.h:
* html/canvas/WebGLProgram.cpp:
(WebCore::WebGLProgram::create):
(WebCore::WebGLProgram::WebGLProgram):
* html/canvas/WebGLProgram.h:
* html/canvas/WebGLRenderbuffer.cpp:
(WebCore::WebGLRenderbuffer::create):
(WebCore::WebGLRenderbuffer::WebGLRenderbuffer):
* html/canvas/WebGLRenderbuffer.h:
* html/canvas/WebGLRenderingContext.cpp: Move implementation to WebGLRenderingContextBase.cpp.
* html/canvas/WebGLRenderingContext.h:  Move implementation to WebGLRenderingContextBase.h.
* html/canvas/WebGLRenderingContext.idl:  Move implementation to WebGLRenderingContextBase.idl.
* html/canvas/WebGLRenderingContextBase.cpp: Added.
* html/canvas/WebGLRenderingContextBase.h: Added.
* html/canvas/WebGLRenderingContextBase.idl: Added.
* html/canvas/WebGLShader.cpp:
(WebCore::WebGLShader::create):
(WebCore::WebGLShader::WebGLShader):
* html/canvas/WebGLShader.h:
* html/canvas/WebGLSharedObject.cpp:
(WebCore::WebGLSharedObject::WebGLSharedObject):
* html/canvas/WebGLSharedObject.h:
* html/canvas/WebGLTexture.cpp:
(WebCore::WebGLTexture::create):
(WebCore::WebGLTexture::WebGLTexture):
* html/canvas/WebGLTexture.h:
* html/canvas/WebGLVertexArrayObjectOES.cpp:
(WebCore::WebGLVertexArrayObjectOES::create):
(WebCore::WebGLVertexArrayObjectOES::WebGLVertexArrayObjectOES):
* html/canvas/WebGLVertexArrayObjectOES.h:

Layout test fixes:
* fast/canvas/webgl/bad-arguments-test-expected.txt:
* fast/canvas/webgl/null-object-behaviour-expected.txt:
* platform/mac/js/dom/global-constructors-attributes-expected.txt:

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

6 years agoREGRESSION(r178250): ~2% PLT regression
antti@apple.com [Mon, 19 Jan 2015 22:02:48 +0000 (22:02 +0000)]
REGRESSION(r178250): ~2% PLT regression
https://bugs.webkit.org/show_bug.cgi?id=140640

Reviewed by Andreas Kling.

* platform/graphics/FontCache.cpp:

The patch accidentally contained a change to reduce the size of the cache (to verify that purgin works).
Restore it back to the original value.

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

6 years ago[GTK] Generate the make dist manifest from a CMake template file
commit-queue@webkit.org [Mon, 19 Jan 2015 21:58:05 +0000 (21:58 +0000)]
[GTK] Generate the make dist manifest from a CMake template file
https://bugs.webkit.org/show_bug.cgi?id=139387

Patch by Michael Catanzaro <mcatanzaro@igalia.com> on 2015-01-19
Reviewed by Martin Robinson.

.:

Generate manifest.txt from manifest.txt.in. Only expose the dist and
distcheck targets for developer builds, as they won't work when
building from a tarball because the manifest is not distributed.

* Source/PlatformGTK.cmake:

Tools:

Remove the code that performs variable substitution on manifest.txt.
Replace the custom variables used in that file with CMake variables.

* gtk/make-dist.py:
(Manifest.add_directory):
(Manifest.get_full_source_path):
(Manifest.process_line):
(Manifest.resolve_variables): Deleted.
(Manifest.get_full_tarball_path): Deleted.
* gtk/manifest.txt.in: Renamed from Tools/gtk/manifest.txt.

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

6 years ago[WinCairo][Video] Windows Media Foundation implementation is not completed.
commit-queue@webkit.org [Mon, 19 Jan 2015 21:03:02 +0000 (21:03 +0000)]
[WinCairo][Video] Windows Media Foundation implementation is not completed.
https://bugs.webkit.org/show_bug.cgi?id=140337

Patch by peavo@outlook.com <peavo@outlook.com> on 2015-01-19
Reviewed by Alex Christensen.

Source/WebCore:

This patch aims to complete some of the methods which are not implemented.
Currently, only MP4 is supported.
Video is rendered in a child window of the main window.
We should eventually render the video directly in the main window,
by reading and painting individual video frames from the stream.

* platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp:
(WebCore::MediaPlayerPrivateMediaFoundation::MediaPlayerPrivateMediaFoundation):
(WebCore::MediaPlayerPrivateMediaFoundation::~MediaPlayerPrivateMediaFoundation):
(WebCore::MediaPlayerPrivateMediaFoundation::getSupportedTypes):
(WebCore::MediaPlayerPrivateMediaFoundation::supportsType):
(WebCore::MediaPlayerPrivateMediaFoundation::load):
(WebCore::MediaPlayerPrivateMediaFoundation::play):
(WebCore::MediaPlayerPrivateMediaFoundation::pause):
(WebCore::MediaPlayerPrivateMediaFoundation::naturalSize):
(WebCore::MediaPlayerPrivateMediaFoundation::hasVideo):
(WebCore::MediaPlayerPrivateMediaFoundation::hasAudio):
(WebCore::MediaPlayerPrivateMediaFoundation::setVisible):
(WebCore::MediaPlayerPrivateMediaFoundation::paused):
(WebCore::MediaPlayerPrivateMediaFoundation::readyState):
(WebCore::MediaPlayerPrivateMediaFoundation::didLoadingProgress):
(WebCore::MediaPlayerPrivateMediaFoundation::setSize):
(WebCore::MediaPlayerPrivateMediaFoundation::paint):
(WebCore::MediaPlayerPrivateMediaFoundation::createSession):
(WebCore::MediaPlayerPrivateMediaFoundation::endSession):
(WebCore::MediaPlayerPrivateMediaFoundation::startCreateMediaSource):
(WebCore::MediaPlayerPrivateMediaFoundation::endCreatedMediaSource):
(WebCore::MediaPlayerPrivateMediaFoundation::endGetEvent):
(WebCore::MediaPlayerPrivateMediaFoundation::createTopologyFromSource):
(WebCore::MediaPlayerPrivateMediaFoundation::addBranchToPartialTopology):
(WebCore::MediaPlayerPrivateMediaFoundation::VideoViewWndProc):
(WebCore::MediaPlayerPrivateMediaFoundation::registerVideoWindowClass):
(WebCore::MediaPlayerPrivateMediaFoundation::createVideoWindow):
(WebCore::MediaPlayerPrivateMediaFoundation::destroyVideoWindow):
(WebCore::MediaPlayerPrivateMediaFoundation::createOutputNode):
(WebCore::MediaPlayerPrivateMediaFoundation::createSourceStreamNode):
(WebCore::MediaPlayerPrivateMediaFoundation::onCreatedMediaSource):
(WebCore::MediaPlayerPrivateMediaFoundation::onTopologySet):
(WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::AsyncCallback):
(WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::~AsyncCallback):
(WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::QueryInterface):
(WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::AddRef):
(WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::Release):
(WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::GetParameters):
(WebCore::MediaPlayerPrivateMediaFoundation::AsyncCallback::Invoke):
* platform/graphics/win/MediaPlayerPrivateMediaFoundation.h:

WebKitLibraries:

Link with Media Foundation libraries.

* win/tools/vsprops/WinCairo.props:

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

6 years ago[Win] Correct merge error in last commit.
bfulgham@apple.com [Mon, 19 Jan 2015 21:01:14 +0000 (21:01 +0000)]
[Win] Correct merge error in last commit.

* DumpRenderTree/win/AccessibilityControllerWin.cpp:
(findAccessibleObjectById): Undo accidental paste made during landing.

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

6 years ago[Win] Periodic failure in DumpRenderTree related to WebActionPropertyBag::Read
bfulgham@apple.com [Mon, 19 Jan 2015 20:58:09 +0000 (20:58 +0000)]
[Win] Periodic failure in DumpRenderTree related to WebActionPropertyBag::Read
https://bugs.webkit.org/show_bug.cgi?id=139906

Reviewed by Dean Jackson.

WebKit on Windows was creating uninitialized VARIANT structures, then attempting
to use them. This patch fixes that.

Source/WebKit/win:

Identified by dom/html/level2/html/HTMLIFrameElement03.html (and others)

* COMEnumVariant.h:
(COMEnumVariant<ContainerType>::Next):
* COMPropertyBag.h:
(HashType>::Read):
* DefaultPolicyDelegate.cpp:
(DefaultPolicyDelegate::decidePolicyForNavigationAction):
* WebActionPropertyBag.cpp:
(WebActionPropertyBag::Read):
* WebDatabaseManager.cpp:
(DatabaseDetailsPropertyBag::Read):
* WebElementPropertyBag.cpp:
(WebElementPropertyBag::Read):
* WebFrame.cpp:
(EnumChildFrames::Next):
* WebView.cpp:
(WebView::notifyDidAddIcon):

Tools:

* DumpRenderTree/win/AccessibilityControllerWin.cpp:
(findAccessibleObjectById):
(AccessibilityController::focusedElement):
(logEventProc):
(notificationListenerProc):
* DumpRenderTree/win/AccessibilityUIElementWin.cpp:
(AccessibilityUIElement::getChildAtIndex):
(AccessibilityUIElement::titleUIElement):
(self):
(AccessibilityUIElement::role):
(AccessibilityUIElement::valueDescription):
(accessibilityState):
(AccessibilityUIElement::isChecked):
* DumpRenderTree/win/DumpRenderTree.cpp:
(dumpFrameScrollPosition):
(dumpFramesAsText):
* DumpRenderTree/win/PolicyDelegate.cpp:
(PolicyDelegate::decidePolicyForNavigationAction):
* DumpRenderTree/win/UIDelegate.cpp:
(UIDelegate::exceededDatabaseQuota):
* WinLauncher/Common.cpp:
(setWindowText):

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

6 years agoWeb Replay: convert to is<T> and downcast<T> for decoding replay inputs
burg@cs.washington.edu [Mon, 19 Jan 2015 20:49:31 +0000 (20:49 +0000)]
Web Replay: convert to is<T> and downcast<T> for decoding replay inputs
https://bugs.webkit.org/show_bug.cgi?id=140512

Reviewed by Chris Dumez.

Source/JavaScriptCore:

Generate a SPECIALIZE_TYPE_TRAITS_* chunk of code for each input. This cannot
be done using REPLAY_INPUT_NAMES_FOR_EACH macro since that doesn't fully qualify
input types, and the type traits macro is defined in namespace WTF.

* replay/NondeterministicInput.h: Make overridden methods public.
* replay/scripts/CodeGeneratorReplayInputs.py:
(Generator.generate_header):
(Generator.qualified_input_name): Allow forcing qualification. WTF is never a target framework.
(Generator.generate_input_type_trait_declaration): Added.
* replay/scripts/CodeGeneratorReplayInputsTemplates.py: Add a template.
* replay/scripts/tests/expected/generate-enum-encoding-helpers-with-guarded-values.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-enum-encoding-helpers.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-enum-with-guard.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-enums-with-same-base-name.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-input-with-guard.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-input-with-vector-members.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-inputs-with-flags.json-TestReplayInputs.h:
* replay/scripts/tests/expected/generate-memoized-type-modes.json-TestReplayInputs.h:

Source/WebCore:

No new tests, no behavior changed.

* replay/EventLoopInput.h: Make overridden methods public.
* replay/MemoizedDOMResult.h: Add type trait specialization here. It is
special-cased because the input type parameter doesn't work with macros.
* replay/SerializationMethods.cpp:
(JSC::EncodingTraits<NondeterministicInputBase>::encodeValue):
Use is() and downcast() when dispatching to encoders based on type.

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

6 years agoReplace use of WTF::bind() in MemoryPressureHandlerLinux.cpp with a C++ lambda
zandobersek@gmail.com [Mon, 19 Jan 2015 20:34:02 +0000 (20:34 +0000)]
Replace use of WTF::bind() in MemoryPressureHandlerLinux.cpp with a C++ lambda
https://bugs.webkit.org/show_bug.cgi?id=140614

Reviewed by Carlos Garcia Campos.

Use a C++ lambda instead of WTF::bind() in the MemoryPressureHandler
implementation for Linux.

* platform/linux/MemoryPressureHandlerLinux.cpp:
(WebCore::MemoryPressureHandler::waitForMemoryPressureEvent):

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

6 years agoUpdate expectations for media/track/track-forced-subtitles-in-band.html.
ap@apple.com [Mon, 19 Jan 2015 20:32:26 +0000 (20:32 +0000)]
Update expectations for media/track/track-forced-subtitles-in-band.html.

This test was marked as flaky on Yosemite, but the bug that tracked that was already
fixed. The test is flaky on Mavericks and above for some other reason.

* platform/mac/TestExpectations:

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

6 years ago[CoordinatedGraphics] Use C++ lambda instead of WTF::bind() in ThreadedCompositor...
zandobersek@gmail.com [Mon, 19 Jan 2015 20:31:44 +0000 (20:31 +0000)]
[CoordinatedGraphics] Use C++ lambda instead of WTF::bind() in ThreadedCompositor::updateSceneState()
https://bugs.webkit.org/show_bug.cgi?id=140613

Reviewed by Carlos Garcia Campos.

* Shared/CoordinatedGraphics/threadedcompositor/ThreadedCompositor.cpp:
(WebKit::ThreadedCompositor::updateSceneState): Replace the use of WTF::bind() with a C++ lambda.

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

6 years agoReplace uses of WTF::bind() in MockMediaPlayerMediaSource with C++ lambdas
zandobersek@gmail.com [Mon, 19 Jan 2015 20:30:03 +0000 (20:30 +0000)]
Replace uses of WTF::bind() in MockMediaPlayerMediaSource with C++ lambdas
https://bugs.webkit.org/show_bug.cgi?id=140612

Reviewed by Philippe Normand.

Use C++ lambdas in place of WTF::bind() in the MockMediaPlayerMediaSource class.

* platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
(WebCore::MockMediaPlayerMediaSource::play):
(WebCore::MockMediaPlayerMediaSource::seekWithTolerance):
(WebCore::MockMediaPlayerMediaSource::seekCompleted):

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

6 years agoUnreviewed, rolling out r178653.
commit-queue@webkit.org [Mon, 19 Jan 2015 20:17:16 +0000 (20:17 +0000)]
Unreviewed, rolling out r178653.
https://bugs.webkit.org/show_bug.cgi?id=140634

Broke multiple SVG tests on Mountain Lion (Requested by ap on
#webkit).

Reverted changeset:

"[SVG -> OTF Converter] Flip the switch on"
https://bugs.webkit.org/show_bug.cgi?id=140592
http://trac.webkit.org/changeset/178653

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

6 years agoES6: Support Array.of construction
dino@apple.com [Mon, 19 Jan 2015 20:03:00 +0000 (20:03 +0000)]
ES6: Support Array.of construction
https://bugs.webkit.org/show_bug.cgi?id=140605
<rdar://problem/19513655>

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

Add and implementation of Array.of, described in 22.1.2.3 of the ES6
specification (15 Jan 2015). The Array.of() method creates a new Array
instance with a variable number of arguments, regardless of number or type
of the arguments.

* runtime/ArrayConstructor.cpp:
(JSC::arrayConstructorOf): Create a new empty Array, then iterate
over the arguments, setting them to the appropriate index.

LayoutTests:

Add 'of' to the Array properties, and a
test for Array.of().

* js/Object-getOwnPropertyNames-expected.txt:
* js/array-of-expected.txt: Added.
* js/array-of.html: Added.
* js/script-tests/Object-getOwnPropertyNames.js:
* js/script-tests/array-of.js: Added.

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

6 years agoLayers need to be already updated before we call adjustViewSize
bfulgham@apple.com [Mon, 19 Jan 2015 20:02:01 +0000 (20:02 +0000)]
Layers need to be already updated before we call adjustViewSize
https://bugs.webkit.org/show_bug.cgi?id=135514

Reviewed by Simon Fraser.

Tested by 'fast/dynamic/layer-no-longer-paginated.html'

Defer painting operations until we have finished layout. This
has a couple of benefits:
(1) We do not attempt to modify render layers during layout.
(2) In WK1 we do not attempt to paint during layout.

Add a new virtual predicate to ScrollView indicating when we are in
layout so that calls to setContentsSize do not attempt
to adjust scrollbars.

Modify FrameView to set its ScrollView state to block paint
operations during layout. Also add a post-layout handler to
complete the scrollbar updates after layout is finished.

* WebCore.exp.in: Move linker symbol to ScrollView (from FrameView).
* page/FrameView.cpp:
(WebCore::FrameView::layout):
(WebCore::FrameView::shouldDeferScrollUpdateAfterContentSizeChange): Added.
(WebCore::FrameView::scrollPositionChangedViaPlatformWidget): Removed (Renamed).
(WebCore::FrameView::scrollPositionChangedViaPlatformWidgetImpl): Added (Renamed)
(WebCore::FrameView::paintContents): Do not paint if we are inside view size adjustment.
* page/FrameView.h:
* platform/ScrollView.cpp:
(WebCore::ScrollView::scrollPositionChangedViaPlatformWidget): Added. Checks whether we need to defer
painting, and calls virtual scrollPositionChangedViaPlatformWidgetImpl if we do not.
(WebCore::FrameView::scrollPositionChangedViaPlatformWidgetImpl): Added.
(WebCore::ScrollView::handleDeferredScrollUpdateAfterContentSizeChange): Added.
(WebCore::ScrollView::scrollTo): If we should defer painting, cache the
the scroll delta and apply it after the layout is complete.
(WebCore::ScrollView::completeUpdatesAfterScrollTo): Split off part of 'scrollTo' into its own method
so we can reuse it in handleDeferredScrollUpdateAfterContentSizeChange.
* platform/ScrollView.h:
(WebCore::ScrollView::shouldDeferScrollUpdateAfterContentSizeChange): Added.

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

6 years agoAdd "override" to fix the build with newer clangs.
dino@apple.com [Mon, 19 Jan 2015 19:45:24 +0000 (19:45 +0000)]
Add "override" to fix the build with newer clangs.

Source/WebKit2:

* UIProcess/Cocoa/WebProcessProxyCocoa.mm:
(WebKit::WebProcessProxy::transformHandlesToObjects):
(WebKit::WebProcessProxy::transformObjectsToHandles):
* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::transformObjectsToHandles):
* UIProcess/ios/WebVideoFullscreenManagerProxy.h:
* WebProcess/cocoa/WebProcessCocoa.mm:
(WebKit::WebProcess::transformHandlesToObjects):
(WebKit::WebProcess::transformObjectsToHandles):

Tools:

* TestWebKitAPI/Tests/WebCore/CalculationValue.cpp:
(TestWebKitAPI::CalculationDeletionTestNode::operator==):

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

6 years ago[iOS] Do not hard-code iphoneos.internal SDK in buildXCodeProject()
ddkilzer@apple.com [Mon, 19 Jan 2015 19:04:53 +0000 (19:04 +0000)]
[iOS] Do not hard-code iphoneos.internal SDK in buildXCodeProject()
<http://webkit.org/b/140623>

Reviewed by Daniel Bates.

* Scripts/build-webkit: Update help for --device switch.
* Scripts/webkitdirs.pm:
(determineXcodeSDK): When passing --device, prefer the internal
iOS SDK if it exists, else fall back to the external iOS SDK.
(buildXCodeProject): Use xcodeSDK() as -sdk argument for
xcodebuild instead of trying to sanitize values.

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

6 years agoHTMLMediaElement::isPlayingAudio() should return false if the element is explicitly...
adachan@apple.com [Mon, 19 Jan 2015 18:50:55 +0000 (18:50 +0000)]
HTMLMediaElement::isPlayingAudio() should return false if the element is explicitly muted by script.
https://bugs.webkit.org/show_bug.cgi?id=140524

Reviewed by Andreas Kling.

Source/WebCore:

Test: media/muted-video-is-playing-audio.html

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::setMuted):
Call Document::updateIsPlayingAudio() to recalculate the overall audio playing state.
(WebCore::HTMLMediaElement::isPlayingAudio):
HTMLMediaElement::isPlayingAudio() should return false if the media element is explicitly muted.

LayoutTests:

The test contains a looping video. It makes sure initially Page::isPlayingAudio() returns true.
It should return false after the video is muted, and true again after the video is unmuted.

* media/muted-video-is-playing-audio-expected.txt: Added.
* media/muted-video-is-playing-audio.html: Added.

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

6 years agoTry to fix build warnings with newer versions of clang.
andersca@apple.com [Mon, 19 Jan 2015 18:40:47 +0000 (18:40 +0000)]
Try to fix build warnings with newer versions of clang.

* Storage/StorageAreaImpl.h:

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

6 years ago[SVG -> OTF Converter] Flip the switch on
mmaxfield@apple.com [Mon, 19 Jan 2015 18:37:19 +0000 (18:37 +0000)]
[SVG -> OTF Converter] Flip the switch on
https://bugs.webkit.org/show_bug.cgi?id=140592

Source/JavaScriptCore:

Reviewed by Antti Koivisto.

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

Reviewed by Antti Koivisto.

* Configurations/FeatureDefines.xcconfig:

Source/WebKit/mac:

Reviewed by Antti Koivisto.

* Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

Reviewed by Antti Koivisto.

* Configurations/FeatureDefines.xcconfig:

LayoutTests:

Updating test expected results.

svg/W3C-SVG-1.1/fonts-glyph-04-t.svg tests something which isn't spec'ed
and is impossible to perform with the converter, so I have deleted that
test.

svg/custom/skip-underline-missing-glyph-expected.html was testing
incorrect behavior, so I have updated the test.

The getStartPositionOfChar() calls in svg/text/kerning.svg and
svg/text/multichar-glyph.svg are currently impossible to be implemented
correctly with the converter, so I have updated the expected results to
test for the updated results of those calls.

Reviewed by Antti Koivisto.

* platform/mac/TestExpectations:
* platform/mac/svg/W3C-SVG-1.1-SE/color-prop-05-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/coords-dom-01-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/coords-dom-02-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/coords-dom-03-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/coords-dom-04-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/coords-units-03-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/filters-felem-01-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/filters-image-03-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/interact-pointer-03-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/linking-uri-01-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/painting-marker-07-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/paths-dom-02-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/pservers-grad-17-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/pservers-grad-20-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/pservers-pattern-03-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/pservers-pattern-04-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/struct-use-14-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/styling-css-04-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/styling-pres-02-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/svgdom-over-01-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/text-intro-02-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/text-intro-09-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/text-tref-03-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/text-tspan-02-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-01-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-02-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-03-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-04-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-05-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-06-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1-SE/types-dom-07-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/filters-light-04-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/filters-turb-02-f-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/fonts-elem-05-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/fonts-elem-06-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/fonts-glyph-04-t-expected.png: Removed.
* platform/mac/svg/W3C-SVG-1.1/fonts-glyph-04-t-expected.txt: Removed.
* platform/mac/svg/W3C-SVG-1.1/fonts-kern-01-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/masking-mask-01-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/render-elems-06-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/render-elems-07-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/render-elems-08-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/render-groups-01-b-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/render-groups-03-t-expected.txt:
* platform/mac/svg/W3C-SVG-1.1/text-align-08-b-expected.txt:
* platform/mac/svg/custom/glyph-setting-d-attribute-expected.txt:
* platform/mac/svg/custom/scrolling-embedded-svg-file-image-repaint-problem-expected.txt:
* platform/mac/svg/custom/svg-fonts-fallback-expected.txt:
* platform/mac/svg/foreignObject/text-tref-02-b-expected.txt:
* platform/mac/svg/text/kerning-expected.txt:
* platform/mac/svg/text/multichar-glyph-expected.txt:
* platform/mac/svg/transforms/text-with-mask-with-svg-transform-expected.txt:
* svg/W3C-SVG-1.1/fonts-glyph-04-t-expected.txt: Removed.
* svg/W3C-SVG-1.1/fonts-glyph-04-t-w3c.png: Removed.
* svg/W3C-SVG-1.1/fonts-glyph-04-t.svg: Removed.
* svg/custom/skip-underline-missing-glyph-expected.html: Removed.
* svg/custom/skip-underline-missing-glyph-expected.txt: Added.
* svg/custom/skip-underline-missing-glyph.html:

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

6 years agoMark a couple slow tests as such.
ap@apple.com [Mon, 19 Jan 2015 18:32:16 +0000 (18:32 +0000)]
Mark a couple slow tests as such.

* TestExpectations:

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

6 years ago"Unknown option: sharedworkerglobalscopeconstructorsfile" when running bindings tests.
ap@apple.com [Mon, 19 Jan 2015 18:05:00 +0000 (18:05 +0000)]
"Unknown option: sharedworkerglobalscopeconstructorsfile" when running bindings tests.
https://bugs.webkit.org/show_bug.cgi?id=140606

Reviewed by Csaba Osztrogonác.

* Scripts/webkitpy/bindings/main.py:
(BindingsTests.generate_supplemental_dependency):
(BindingsTests.main):

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

6 years ago[Win] Unreviewed gardening: Remove unneeded win-specific result.
bfulgham@apple.com [Mon, 19 Jan 2015 17:43:18 +0000 (17:43 +0000)]
[Win] Unreviewed gardening: Remove unneeded win-specific result.

At one point, Windows error messages did not include line numbers and needed its own results.
This is no longer the case, and any such results should be removed

* platform/win/fast/xmlhttprequest/xmlhttprequest-no-file-access-expected.txt: Removed.

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

6 years ago[Win] Unreviewed gardening: Mark some passing tests appropriately.
bfulgham@apple.com [Mon, 19 Jan 2015 17:35:08 +0000 (17:35 +0000)]
[Win] Unreviewed gardening: Mark some passing tests appropriately.

* platform/win/TestExpectations:

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

6 years agoConsole log sometimes prefixed with line number
ap@apple.com [Mon, 19 Jan 2015 17:25:23 +0000 (17:25 +0000)]
Console log sometimes prefixed with line number
https://bugs.webkit.org/show_bug.cgi?id=105280

Reviewed by Darin Adler.

Source/WebCore:

Improve the logic for determining whether a console message should be associated
with a source code location.

* dom/ScriptableDocumentParser.h:
* html/parser/HTMLDocumentParser.cpp:
(WebCore::HTMLDocumentParser::shouldAssociateConsoleMessagesWithTextPosition):
* html/parser/HTMLDocumentParser.h:
* page/PageConsoleClient.cpp:
(WebCore::getParserLocationForConsoleMessage):
(WebCore::PageConsoleClient::addMessage):
* xml/parser/XMLDocumentParser.cpp:
(WebCore::XMLDocumentParser::pauseParsing):
* xml/parser/XMLDocumentParser.h:
* xml/parser/XMLDocumentParserLibxml2.cpp:
(WebCore::XMLDocumentParser::shouldAssociateConsoleMessagesWithTextPosition):

LayoutTests:

Some messages lost line numbers now. Some of these were definitely wrong, others
were roughly right. Unfortunately, it is not currently possible to figure out whether
ScriptController actually executes a script after passing control to it. So the cases
where it refuses to execute the script and logs a message are handled like those
where it does.

I think that it shouldn't be a big obstacle in practice, it is easy enough to find
a script in a page when Web Inspector tells you that scripts were not allowed.

* fast/frames/sandboxed-iframe-attribute-parsing-06-expected.txt:
* fast/frames/sandboxed-iframe-attribute-parsing-07-expected.txt:
* fast/frames/sandboxed-iframe-attribute-parsing-08-expected.txt:
* fast/frames/sandboxed-iframe-attribute-parsing-09-expected.txt:
* fast/frames/sandboxed-iframe-attribute-parsing-10-expected.txt:
* fast/frames/sandboxed-iframe-attribute-parsing-11-expected.txt:
* fast/frames/sandboxed-iframe-attribute-parsing-12-expected.txt:
* fast/frames/sandboxed-iframe-attribute-parsing-13-expected.txt:
* fast/frames/sandboxed-iframe-attribute-parsing-14-expected.txt:
* fast/frames/sandboxed-iframe-parsing-space-characters-expected.txt:
* fast/frames/sandboxed-iframe-scripting-04-expected.txt:
* http/tests/security/contentSecurityPolicy/sandbox-empty-expected.txt:
* http/tests/security/contentSecurityPolicy/sandbox-empty-subframe-expected.txt:
* http/tests/security/contentSecurityPolicy/sandbox-in-http-header-control-expected.txt:
* http/tests/security/contentSecurityPolicy/sandbox-in-http-header-expected.txt:
* http/tests/security/contentSecurityPolicy/sandbox-invalid-header-expected.txt:
* http/tests/security/isolatedWorld/sandboxed-iframe-expected.txt:
* http/tests/security/mixedContent/insecure-script-in-iframe-expected.txt:
* http/tests/security/mixedContent/redirect-http-to-https-script-in-iframe-expected.txt:
* http/tests/security/no-javascript-refresh-expected.txt:
* http/tests/security/no-javascript-refresh-spaces-expected.txt:

* platform/efl/TestExpectations:
* platform/gtk/TestExpectations:
Unmark tests that were broken by this.

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

6 years ago[SVG -> OTF Converter] Glyphs get clipped weirdly
mmaxfield@apple.com [Mon, 19 Jan 2015 16:32:26 +0000 (16:32 +0000)]
[SVG -> OTF Converter] Glyphs get clipped weirdly
https://bugs.webkit.org/show_bug.cgi?id=137095

Reviewed by Antti Koivisto.

The Adobe CFF spec doesn't actually tell you how to serialize a
"FontBBox." After trial and error, it seems to be (x, y, width,
height).

Test: svg/text/kerning.svg
      svg/W3C-SVG-1.1/fonts-kern-01-t.svg

* svg/SVGToOTFFontConversion.cpp:
(WebCore::SVGToOTFFontConverter::appendHEADTable):
(WebCore::SVGToOTFFontConverter::appendCFFTable):
(WebCore::SVGToOTFFontConverter::appendVHEATable):
(WebCore::CFFBuilder::CFFBuilder):
(WebCore::SVGToOTFFontConverter::transcodeGlyphPaths):
(WebCore::SVGToOTFFontConverter::processGlyphElement):

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