⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Timeline



Jun 9, 2020:

9:16 PM Changeset in webkit [262835] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Release Assert @ WebCore::RenderTreeBuilder::RenderTreeBuilder
https://bugs.webkit.org/show_bug.cgi?id=212714

Patch by Pinki Gyanchandani <pgyanchandani@apple.com> on 2020-06-09
Reviewed by Geoffrey Garen.

Made change in the WidgetHierarchyUpdatesSuspensionScope::moveWidgets() to handle all widgets scheduled to move,
including new widgets scheduled during moveWidgets().

Test would be added later.

  • rendering/RenderWidget.cpp:

(WebCore::WidgetHierarchyUpdatesSuspensionScope::moveWidgets):

9:10 PM Changeset in webkit [262834] by Fujii Hironori
  • 17 edits in trunk

Unreviewed, reverting r262791.

WinCairo WebKit1 is crashing.

Reverted changeset:

"[Curl] Implement functions to use ResourceLoadStatistics."
https://bugs.webkit.org/show_bug.cgi?id=207692
https://trac.webkit.org/changeset/262791

8:44 PM Changeset in webkit [262833] by Simon Fraser
  • 6 edits in trunk

Minor overflow layers cleanup
https://bugs.webkit.org/show_bug.cgi?id=213002

Reviewed by Zalan Bujtas.

Source/WebCore:

Now that we parent scrollbar and scroll corner layers into the overflowControlsContainer
layer, we no need to parent these layers in RenderLayerCompositor::updateBackingAndHierarchy().

Also rename overflowControlsHostLayerBox to overflowControlsHostLayerRect to avoid
ambiguity with RenderBox.

  • rendering/RenderLayerBacking.cpp:

(WebCore::RenderLayerBacking::updateDebugIndicators):
(WebCore::overflowControlsHostLayerRect):
(WebCore::RenderLayerBacking::updateGeometry):
(WebCore::overflowControlsHostLayerBox): Deleted.

  • rendering/RenderLayerBacking.h:
  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::updateBackingAndHierarchy):

LayoutTests:

New results now now that the scrollbar layers aren't reparented.

  • compositing/overflow/overflow-scrollbar-layer-positions-expected.txt:
7:16 PM Changeset in webkit [262832] by timothy_horton@apple.com
  • 4 edits in trunk/Source

Stop using the wrong LaunchServices SPI for getting an app's localized name
https://bugs.webkit.org/show_bug.cgi?id=213003
<rdar://problem/64169000>

Reviewed by Sam Weinig.

Source/WebCore/PAL:

  • pal/spi/cocoa/LaunchServicesSPI.h:

Source/WebKit:

  • UIProcess/ios/WKActionSheetAssistant.mm:

(-[WKActionSheetAssistant _appendAppLinkOpenActionsForURL:actions:elementInfo:]):

7:04 PM Changeset in webkit [262831] by timothy_horton@apple.com
  • 3 edits
    1 add in trunk/Source/WTF

Use os_log instead of asl_log
https://bugs.webkit.org/show_bug.cgi?id=213001

Reviewed by Saam Barati.

  • WTF.xcodeproj/project.pbxproj:
  • wtf/Assertions.cpp:
7:04 PM Changeset in webkit [262830] by mark.lam@apple.com
  • 3 edits
    1 add in trunk

Stringifier::appendStringifiedValue() should not assume it is always safe to recurse.
https://bugs.webkit.org/show_bug.cgi?id=213006
<rdar://problem/64154840>

Reviewed by Keith Miller.

JSTests:

  • stress/json-stringify-executing-in-reserved-zone.js: Added.

Source/JavaScriptCore:

In r262727, I suggested that Alexey Shvayka add an assertion in
Stringifier::appendStringifiedValue() to assert that it is safe to recurse because
we don't expect it to recurse into itself. Turns out this is a bad idea because
a client may be doing the recursing before calling Stringifier::appendStringifiedValue().
As a result, Stringifier::appendStringifiedValue() ends up being executed with
the stack pointer already in the reserved zone. This is legal, and is what the
reserved zone is intended for as long as we don't recurse from here. However,
this also means that asserting vm.isSafeToRecurseSoft() here will surely fail
because we are already in the reserved zone area. The fix is simply to remove
this faulty assertion.

  • runtime/JSONObject.cpp:

(JSC::Stringifier::appendStringifiedValue):

6:57 PM Changeset in webkit [262829] by Russell Epstein
  • 8 edits in branches/safari-610.1.15.50-branch/Source

Versioning.

6:44 PM Changeset in webkit [262828] by jfernandez@igalia.com
  • 2 edits in trunk/LayoutTests

[GTK] Unreviewed test gardening
https://bugs.webkit.org/show_bug.cgi?id=212997

Unreviewed test gardening

  • platform/gtk/TestExpectations:
5:21 PM Changeset in webkit [262827] by mark.lam@apple.com
  • 64 edits
    1 add in trunk

Disambiguate the OverridesGetPropertyNames structure flag
https://bugs.webkit.org/show_bug.cgi?id=212909
<rdar://problem/63823557>

Reviewed by Saam Barati.

JSTests:

  • stress/unexpected-stack-overflow-below-JSObject-getPropertyNames.js: Added.

Source/JavaScriptCore:

Previously, the OverridesGetPropertyNames structure flag could mean 2 different
things:

  1. the getPropertyNames() method is overridden, or
  2. any of the forms of getPropertyName() is overridden: getPropertyName, getOwnPropertyNames, getOwnNonIndexPropertyNames

Some parts of the code expects one definition while other parts expect the other.
This patch disambiguates between the 2 by introducing OverridesAnyFormOfGetPropertyNames
for definition (2). OverridesGetPropertyNames now only means definition (1).

Note: we could have implemented overridesGetPropertyNames() by doing a comparison
of the getPropertyNames pointer in the MethodTable. This is a little slower than
checking a TypeInfo flag, but probably doesn't matter a lot in the code paths
where overridesGetPropertyNames() is called. However, we have bits in TypeInfo
left. So, we'll might as well use it.

This ambiguity resulted in JSObject::getPropertyNames() recursing infinitely
when it didn't think it could recurse. This is demonstrated in
JSTests/stress/unexpected-stack-overflow-below-JSObject-getPropertyNames.js as
follows:

  1. The test case invokes JSObject::getPropertyNames on a JSArray.
  1. In the while loop at the bottom of JSObject::getPropertynames(), we check if (prototype->structure(vm)->typeInfo().overridesGetPropertyNames()) {.
  1. The test overrides proto as follows: arg0.__proto__ = arr1 where both arg0 and arr1 are JArrays.
  1. In the old code, JSArray sets OverridesGetPropertyNames but does not override getPropertyNames(). It actually meant to set OverridesAnyFormOfGetPropertyNames (after we disambiguated it) because JSArray overrides getOwnNonIndexPropertyNames().
  1. When we get to the check at (2), we ask if the prototype overridesGetPropertyNames(). Since JSArray sets OverridesGetPropertyNames, the answer is yes / true.

JSObject::getPropertynames() then proceeds to invoke
prototype->methodTable(vm)->getPropertyNames(prototype, globalObject, propertyNames, mode);

But because JSArray does not actually overrides getPropertyNames(), we're
actually invoking JSObject::getPropertyNames() here. Viola! Infinite loop.

With this patch, JSArray is disambiguated to set OverridesAnyFormOfGetPropertyNames
instead of OverridesGetPropertyNames, and this infinite loop no longer exists.

This patch also made the following changes:

  1. Templatized TypeInfo::isSetOnFlags1() and TypeInfo::isSetOnFlags2() so that we can used static_asserts instead of a debug ASSERT to verify the integrity of the flag we're checking against.
  1. Added a Structure::validateFlags() called from the Structure constructor. validateFlags() will verify the following:
    1. OverridesGetOwnPropertySlot must be set in the flags if getOwnPropertySlot is overridden in the MethodTable.
    2. InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero must be set in the flags if getOwnPropertySlotByIndex is overridden in the MethodTable.
    3. HasPutPropertySecurityCheck must be set in the flags if doPutPropertySecurityCheck is overridden in the MethodTable.
    4. OverridesGetPropertyNames must be set in the flags if getPropertyNames is overridden in the MethodTable.
    5. OverridesAnyFormOfGetPropertyNames must be set in the flags if any of getPropertyNames, getOwnPropertyNames, or getOwnNonIndexPropertyNames are overridden in the MethodTable.

An alternate solution would be to automatically set these flags if we detect
their corresponding methods are overridden. However, this alternate solution
requires this laundry list to be checked every time a structure is constructed.
The current implementation of having the required flags already pre-determined
as a constant is more efficient in terms of performance and code space.

Also, it only takes one instantiation of the structure to verify that the flags
are valid. Since we only write JSCell / JSObject classes when we need them
and we always write tests to exercise new code (especially such classes), we're
guaranteed the flags validation will be exercised.

  1. Made JSObject::getOwnPropertySlot() and JSObject::doPutPropertySecurityCheck() not inlined when ASSERT_ENABLED. This is needed in order for Structure::validateFlags() to do its checks using function pointer comparisons. Otherwise, the inline functions can result in multiple instantiations of these functions. For example, WebCore can get its own copy of JSObject::getOwnPropertySlot() and the comparisons will think the function is overridden even when it's not.
  1. Structure::validateFlags() found the following problems which are now fixed:

GetterSetter was not using its StructureFlags. As a result, it was missing the
OverridesGetOwnPropertySlot flag.

JSDataView did not define its StructureFlags. It was missing the
OverridesGetOwnPropertySlot and OverridesAnyFormOfGetPropertyNames flags.

  1. Changed a TypeInfo constructor to not have a default argument for the flags value. Also grepped for all uses of this constructor to make sure that it is passed the StructureFlags field. This exercise found the following issue:

JSAPIValueWrapper was not using its StructureFlags when creating its structure.
Previously, it was just ignoring the StructureIsImmortal flag in StructureFlags.

  1. Hardened the assertions for hasReadOnlyOrGetterSetterPropertiesExcludingProto() and hasGetterSetterProperties() in the Structure constructor.

Previously, if the flag is set, it verifies that the ClassInfo has the
appropriate data expected by the flag. However, it does not assert the reverse
i.e. that if the ClassInfo data exists, then the flag must also be set.
The new assertions now checks both.

Moved the overridesGetCallData() assertion into Structure::validateFlags()
because it concerns the OverridesGetCallData flag. This assertion has also
ben hardened.

  • API/JSAPIValueWrapper.h:
  • API/JSCallbackObject.h:
  • debugger/DebuggerScope.h:
  • inspector/JSInjectedScriptHostPrototype.h:
  • inspector/JSJavaScriptCallFramePrototype.h:
  • runtime/ClonedArguments.h:
  • runtime/ErrorInstance.h:
  • runtime/GenericArguments.h:
  • runtime/GetterSetter.h:
  • runtime/JSArray.h:
  • runtime/JSDataView.h:
  • runtime/JSFunction.h:
  • runtime/JSGenericTypedArrayView.h:
  • runtime/JSGlobalObject.h:
  • runtime/JSLexicalEnvironment.h:
  • runtime/JSModuleEnvironment.h:
  • runtime/JSModuleNamespaceObject.h:
  • runtime/JSObject.cpp:

(JSC::JSObject::doPutPropertySecurityCheck):
(JSC::JSObject::getOwnPropertySlot):

  • runtime/JSObject.h:

(JSC::JSObject::getOwnPropertySlotImpl):
(JSC::JSObject::getOwnPropertySlot):

  • runtime/JSProxy.h:
  • runtime/JSString.h:
  • runtime/JSSymbolTableObject.h:
  • runtime/JSTypeInfo.h:

(JSC::TypeInfo::TypeInfo):
(JSC::TypeInfo::masqueradesAsUndefined const):
(JSC::TypeInfo::implementsHasInstance const):
(JSC::TypeInfo::implementsDefaultHasInstance const):
(JSC::TypeInfo::overridesGetCallData const):
(JSC::TypeInfo::overridesToThis const):
(JSC::TypeInfo::structureIsImmortal const):
(JSC::TypeInfo::overridesGetPropertyNames const):
(JSC::TypeInfo::overridesAnyFormOfGetPropertyNames const):
(JSC::TypeInfo::prohibitsPropertyCaching const):
(JSC::TypeInfo::getOwnPropertySlotIsImpure const):
(JSC::TypeInfo::getOwnPropertySlotIsImpureForPropertyAbsence const):
(JSC::TypeInfo::hasPutPropertySecurityCheck const):
(JSC::TypeInfo::newImpurePropertyFiresWatchpoints const):
(JSC::TypeInfo::isImmutablePrototypeExoticObject const):
(JSC::TypeInfo::interceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero const):
(JSC::TypeInfo::isSetOnFlags1 const):
(JSC::TypeInfo::isSetOnFlags2 const):

  • runtime/ObjectConstructor.cpp:

(JSC::objectConstructorAssign):

  • runtime/ProxyObject.h:
  • runtime/RegExpObject.h:
  • runtime/StringObject.h:
  • runtime/Structure.cpp:

(JSC::Structure::validateFlags):
(JSC::Structure::Structure):

  • runtime/Structure.h:
  • runtime/StructureInlines.h:

(JSC::Structure::canCacheOwnKeys const):

  • tools/JSDollarVM.cpp:

Source/WebCore:

  1. JSDOMWindowProperties was not defining its Base. As a result, its StructureFlags was inheriting from JSDOMObject's Base instead of from JSDOMObject as one would expect. This turns out to be harmless because JSDOMObject did not define any StructureFlags. Regardless, this is not fixed so that if JSDOMObject adds any StructureFlags, it will be inherited properly by JSDOMWindowProperties.
  1. Updated CodeGeneratorJS.pm and rebased the binding test results.
  • bindings/js/JSDOMWindowProperties.h:
  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateHeader):

  • bindings/scripts/test/JS/JSTestEventTarget.h:
  • bindings/scripts/test/JS/JSTestIndexedSetterNoIdentifier.h:
  • bindings/scripts/test/JS/JSTestIndexedSetterThrowingException.h:
  • bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterNoIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterThrowingException.h:
  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedDeleterNoIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedDeleterThrowingException.h:
  • bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedDeleterWithIndexedGetter.h:
  • bindings/scripts/test/JS/JSTestNamedGetterCallWith.h:
  • bindings/scripts/test/JS/JSTestNamedGetterNoIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedGetterWithIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedSetterNoIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedSetterThrowingException.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithOverrideBuiltins.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithUnforgableProperties.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithUnforgablePropertiesAndOverrideBuiltins.h:
  • bindings/scripts/test/JS/JSTestObj.h:
  • bindings/scripts/test/JS/JSTestOverrideBuiltins.h:
  • bridge/runtime_array.h:
  • bridge/runtime_object.h:

Source/WebKit:

  • WebProcess/Plugins/Netscape/JSNPObject.h:
5:05 PM Changeset in webkit [262826] by dino@apple.com
  • 9 edits
    6 moves in trunk/Source

Stop using discriminatory names for WebGL and Plugin blocking
https://bugs.webkit.org/show_bug.cgi?id=213000

Reviewed by Simon Fraser.

Source/WebCore:

  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/mac/BlocklistUpdater.h: Renamed from Source/WebCore/platform/mac/BlacklistUpdater.h.

(WebCore::BlocklistUpdater::pluginBlocklist):
(WebCore::BlocklistUpdater::webGLBlocklist):

  • platform/mac/BlocklistUpdater.mm: Renamed from Source/WebCore/platform/mac/BlacklistUpdater.mm.

(WebCore::BlocklistUpdater::readBlocklistData):
(WebCore::BlocklistUpdater::reloadIfNecessary):
(WebCore::BlocklistUpdater::initializeQueue):

  • platform/mac/PluginBlocklist.h: Renamed from Source/WebCore/platform/mac/PluginBlacklist.h.
  • platform/mac/PluginBlocklist.mm: Renamed from Source/WebCore/platform/mac/PluginBlacklist.mm.

(WebCore::PluginBlocklist::loadPolicyForPluginVersion):
(WebCore::PluginBlocklist::isPluginUpdateAvailable):
(WebCore::PluginBlocklist::create):
(WebCore::PluginBlocklist::~PluginBlocklist):
(WebCore::PluginBlocklist::splitOSVersion):
(WebCore::PluginBlocklist::loadPolicyForPlugin const):
(WebCore::PluginBlocklist::isUpdateAvailable const):
(WebCore::PluginBlocklist::PluginBlocklist):

  • platform/mac/WebGLBlocklist.h: Renamed from Source/WebCore/platform/mac/WebGLBlacklist.h.
  • platform/mac/WebGLBlocklist.mm: Renamed from Source/WebCore/platform/mac/WebGLBlacklist.mm.

(WebCore::buildInfoFromOSBuildString):
(WebCore::WebGLBlocklist::shouldBlockWebGL):
(WebCore::WebGLBlocklist::shouldSuggestBlockingWebGL):
(WebCore::matchesBuildInfo):
(WebCore::WebGLBlocklist::create):
(WebCore::WebGLBlocklist::shouldBlock const):
(WebCore::WebGLBlocklist::shouldSuggestBlocking const):
(WebCore::WebGLBlocklist::WebGLBlocklist):
(WebCore::WebGLBlocklist::~WebGLBlocklist):

Source/WebKit:

  • Shared/Plugins/Netscape/mac/PluginInformationMac.mm:

(WebKit::getPlatformPluginModuleInformation):

  • UIProcess/API/C/mac/WKContextPrivateMac.mm:

(WKContextIsPlugInUpdateAvailable):
(WKContextShouldBlockWebGL):
(WKContextShouldSuggestBlockWebGL):

  • UIProcess/Plugins/mac/PluginInfoStoreMac.mm:

(WebKit::PluginInfoStore::defaultLoadPolicyForPlugin):

Source/WebKitLegacy/mac:

  • WebCoreSupport/WebFrameLoaderClient.mm:

(shouldBlockPlugin):
(shouldBlockWebGL):

4:32 PM Changeset in webkit [262825] by Simon Fraser
  • 3 edits in trunk/Source/WebCore

Logging and tree dumping crash fix
https://bugs.webkit.org/show_bug.cgi?id=212988

Reviewed by Zalan Bujtas.

Add scrolling logging to RenderLayer::requestScrollPositionUpdate().

Null-check the scrollerImp in ScrollbarThemeMac::isLayoutDirectionRTL, because this is
called from renderTreeAsText() which can be invoked from the debugger, and should not crash.

  • platform/mac/ScrollbarThemeMac.mm:

(WebCore::ScrollbarThemeMac::isLayoutDirectionRTL):

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::requestScrollPositionUpdate):

4:27 PM Changeset in webkit [262824] by aestes@apple.com
  • 2 edits in trunk/Source/WebCore

Unreviewed change for post-commit feedback after r262682.

  • DerivedSources.make: Replaced tabs with spaces.
4:16 PM Changeset in webkit [262823] by Russell Epstein
  • 1 copy in tags/Safari-610.1.15.50.2

Tag Safari-610.1.15.50.2.

4:11 PM Changeset in webkit [262822] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

[GTK] Gardening, update results of flaky timeout failures
https://bugs.webkit.org/show_bug.cgi?id=212993

Unreviewed gardening.

For those flaky timeout failures, update expected results to the actual results obtained in the
last 4000 revisions for each test.

  • platform/gtk/TestExpectations:
4:10 PM Changeset in webkit [262821] by Russell Epstein
  • 8 edits in branches/safari-610.1.15.50-branch/Source

Versioning.

3:36 PM Changeset in webkit [262820] by Alan Coon
  • 1 copy in tags/Safari-610.1.16.3

Tag Safari-610.1.16.3.

3:33 PM Changeset in webkit [262819] by Alan Coon
  • 2 edits in branches/safari-610.1.16-branch/Source/WebCore

Cherry-pick r262687. rdar://problem/64044841

REGRESSION (r262364): Disney Plus crashes playing videos
https://bugs.webkit.org/show_bug.cgi?id=212862
<rdar://problem/64044841>

Reviewed by Eric Carlson.

In r262364, we specified an incorrect number size for CFNumberGetValue, which nevertheless
worked fine in debug builds, but overwrote stack data in release builds, leading to a crash when
the returned pointer was ref()d. The correct size for a FourCharCode is a
kCFNumberSInt32Type, not a kCFNumberLongType.

  • platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:

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

3:31 PM Changeset in webkit [262818] by Alan Coon
  • 8 edits in branches/safari-610.1.16-branch/Source

Versioning.

3:26 PM Changeset in webkit [262817] by Russell Epstein
  • 1 copy in tags/Safari-610.1.15.52.1

Tag Safari-610.1.15.52.1.

3:25 PM Changeset in webkit [262816] by Russell Epstein
  • 1 copy in tags/Safari-610.1.15.50.1

Tag Safari-610.1.15.50.1.

3:06 PM Changeset in webkit [262815] by BJ Burg
  • 2 edits in trunk/Source/WebKit

[Cocoa] Element Send Keys can hang when an automation window becomes unfocused
https://bugs.webkit.org/show_bug.cgi?id=212985
<rdar://problem/56354471>

Reviewed by Devin Rousso.

  • UIProcess/Automation/mac/WebAutomationSessionMac.mm:

(WebKit::WebAutomationSession::sendSynthesizedEventsToPage):
Make sure to focus the window and set first responder so sending keys doesn't hang.

3:04 PM Changeset in webkit [262814] by Chris Dumez
  • 2 edits in trunk/Source/WTF

Use bridge cast in String(NSString *) constructor
https://bugs.webkit.org/show_bug.cgi?id=212989

Reviewed by Darin Adler.

Use bridge cast in String(NSString *) constructor instead of a reinterpret_cast as this
is the preferred way of converting a NS Type to a CF one.

  • wtf/text/cocoa/StringCocoa.mm:

(WTF::String::String):

2:47 PM Changeset in webkit [262813] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebCore

WebKit Crashes when SVG Filter Logging is Turned On
https://bugs.webkit.org/show_bug.cgi?id=212415

Patch by Frank Yang <guowei_yang@apple.com> on 2020-06-09
Reviewed by Darin Adler.

No new tests are required because this is just
fixing a simple pointer access inside logging code

  • html/ImageData.cpp:

(WebCore::operator<<): Overloaded << operator to print the

address of pixel data it stores

  • html/ImageData.h: Declare overloaded << operator
  • platform/graphics/filters/FilterEffect.cpp:

(WebCore::FilterEffect::imageBufferResult): Modified logging code

so that it does a null check by calling ValueOrNull on
m_premultipliedImageResult and m_unmultipliedImageResult

(WebCore::FilterEffect::copyUnmultipliedResult): Modified logging code

so that it does a null check by calling ValueOrNull on
m_premultipliedImageResult and m_unmultipliedImageResult

(WebCore::FilterEffect::copyPremultipliedResult): Modified logging code

so that it does a null check by calling ValueOrNull on
m_premultipliedImageResult and m_unmultipliedImageResult

2:43 PM Changeset in webkit [262812] by Jonathan Bedard
  • 2 edits in trunk/Source/WebKit

WebKit: Import NSURLConnectionSPI.h instead of CFNSURLConnection.h
https://bugs.webkit.org/show_bug.cgi?id=212980
<rdar://problem/64172694>

Unreviewed build fix.

No new tests, behavior unchanged.

  • NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:
2:19 PM Changeset in webkit [262811] by dino@apple.com
  • 6 edits in trunk/Source

REGRESSION: [Safari Mojave for High Sierra] Accessing some of the featured pages on apple.com causes the webpage to crash
https://bugs.webkit.org/show_bug.cgi?id=212940
Source/WebCore:

rdar://63839405

Reviewed by Tim Horton.

The code to use the singleton for a SwitchingGPUClient was assuming it
has always been set, which was not the case when
ENABLE(WEBPROCESS_WINDOWSERVER_BLOCKING) was not true.

  • platform/graphics/opengl/GraphicsContextGLOpenGLManager.cpp: Check the state of the

singleton before calling it.
(WebCore::GraphicsContextGLOpenGLManager::updateHighPerformanceState):
(WebCore::GraphicsContextGLOpenGLManager::disableHighPerformanceGPUTimerFired):

  • platform/graphics/mac/SwitchingGPUClient.h: Return a pointer to the singleton which

will allow the code to check for its existence.
(WebCore::SwitchingGPUClient::singletonIfExists):

Source/WebKit:

Reviewed by Tim Horton.

The code to use the singleton for a SwitchingGPUClient was assuming it
has always been set, which was not the case when
ENABLE(WEBPROCESS_WINDOWSERVER_BLOCKING) was not true.

  • WebProcess/cocoa/WebProcessCocoa.mm: Set the singleton unconditionally.

(WebKit::WebProcess::platformInitializeProcess):

2:05 PM Changeset in webkit [262810] by weinig@apple.com
  • 7 edits in trunk/Source/WebCore

Extended Color: Streamline SimpleColor premulitply/unpremultiply code
https://bugs.webkit.org/show_bug.cgi?id=212945

Reviewed by Darin Adler.

Simplify / streamline the premulitply/unpremultiply code by:

  • Removing the overloads that didn't take individual components, keeping only the ones taking a SimpleColor.
  • Replacing the "ceiling" bool in makePremultipliedSimpleColor and converting it into two functions.
  • Simplifying the names from makePremultipliedSimpleColor/makeUnpremultipliedSimpleColor to premultiplyFlooring/premultiplyCeiling/unpremultiply.
  • Where component order is important, use valueAsARGB() explicitly to show what the resulting value's format will be.
  • platform/graphics/Color.cpp:

(WebCore::blend):
Update to call premultiplyCeiling/unpremultiply.

  • platform/graphics/ImageBackingStore.h:

(WebCore::ImageBackingStore::blendPixel):
(WebCore::ImageBackingStore::pixelValue const):
Update to call premultiplyFlooring/unpremultiply and valueAsARGB().

  • platform/graphics/SimpleColor.h:
  • platform/graphics/SimpleColor.cpp:

(WebCore::premultiplyFlooring):
(WebCore::premultiplyCeiling):
(WebCore::unpremultiplyChannel):
(WebCore::unpremultiply):
(WebCore::premultipliedChannel): Deleted.
(WebCore::unpremultipliedChannel): Deleted.
(WebCore::makePremultipliedSimpleColor): Deleted.
(WebCore::makeUnpremultipliedSimpleColor): Deleted.
Simplify premulitply/unpremultiply interfaces. Use structured bindings to make
the code a bit easier to follow as well.

  • platform/graphics/cairo/ImageBufferCairoImageSurfaceBackend.cpp:

(WebCore::ImageBufferCairoImageSurfaceBackend::platformTransformColorSpace):
Update to call premultiplyFlooring/unpremultiply and valueAsARGB().

  • platform/graphics/cairo/NativeImageCairo.cpp:

(WebCore::nativeImageSinglePixelSolidColor):
Update to call premultiplyFlooring/unpremultiply and valueAsARGB(). Also removes
reinterpret cast to SimpleColor, instead following the model in ImageBufferCairoImageSurfaceBackend
and casting to unsigned, and building the SimpleColor from that. This will allow
SimpleColor to change its underlying representation in the future without breaking things.

2:04 PM Changeset in webkit [262809] by commit-queue@webkit.org
  • 18 edits
    50 deletes in trunk

Unreviewed, reverting r261841.
https://bugs.webkit.org/show_bug.cgi?id=212991

Caused spotify pages to scroll to the top
(<http://webkit.org/b/212983|webkit.org/b/212983>)

Reverted changeset:

"[css-grid] Clear the override width for computing percent
margins"
https://bugs.webkit.org/show_bug.cgi?id=209461
https://trac.webkit.org/changeset/261841

1:59 PM Changeset in webkit [262808] by Jonathan Bedard
  • 3 edits in trunk/Source/JavaScriptCore

JavaScriptCore: Support tvOS and watchOS builds with the public SDK
https://bugs.webkit.org/show_bug.cgi?id=212788
<rdar://problem/64000087>

Reviewed by Tim Horton.

  • Configurations/Base.xcconfig: Link to tvOS and watchOS framework stubs.
  • Configurations/JavaScriptCore.xcconfig: Use iOS flags for all embedded platforms.
1:52 PM Changeset in webkit [262807] by zhifei_fang@apple.com
  • 2 edits in trunk/Tools

Add a timeout monitor for JSC stress test
https://bugs.webkit.org/show_bug.cgi?id=211978

Reviewed by Jonathan Bedard.

  • Scripts/webkitruby/jsc-stress-test-writer-default.rb: Add timeout monitor inside the jsc stress test runner, it will kill the process in case of jsc timeout handler not working
1:44 PM Changeset in webkit [262806] by Devin Rousso
  • 20 edits in trunk

Web Inspector: allow multiple resources for a given URL
https://bugs.webkit.org/show_bug.cgi?id=212852

Reviewed by Brian Burg.

Source/WebInspectorUI:

Previously, when a new resource is added with a URL that matches an existing resource, any
resourceForURL call with that URL will return the new resource instead of the old one. Now
that there is a Multimap of URL to resource, it is possible to pick which resource is used
instead of always using the newest one.

  • UserInterface/Models/ResourceCollection.js:

(WI.ResourceCollection):
(WI.ResourceCollection.prototype.resourcesForURL): Added.
(WI.ResourceCollection.prototype._associateWithResource):
(WI.ResourceCollection.prototype._disassociateWithResource):
(WI.ResourceCollection.prototype._resourceURLDidChange):
(WI.ResourceCollection.prototype.resourceForURL): Deleted.

  • UserInterface/Models/Frame.js:

(WI.Frame.prototype.resourcesForURL): Added.
(WI.Frame.prototype.resourceForURL): Deleted.

  • UserInterface/Controllers/NetworkManager.js:

(WI.NetworkManager.prototype.resourcesForURL): Added.
(WI.NetworkManager.prototype.resourceRequestDidReceiveResponse):
(WI.NetworkManager.prototype._initiatorSourceCodeLocationFromPayload):
(WI.NetworkManager.prototype.resourceForURL): Deleted.

  • UserInterface/Models/Script.js:

(WI.Script.prototype._resolveResource):
(WI.Script.prototype._resolveResource.isScriptResource): Added.

  • UserInterface/Controllers/CSSManager.js:

(WI.CSSManager.prototype._updateResourceContent.fetchedStyleSheetContent):

  • UserInterface/Base/Utilities.js:

(Set.prototype.find): Added.
Add utility for finding an item in a Set to avoid having to Array.from.

  • UserInterface/Base/Main.js:

(WI.openURL):
(WI.sourceCodeForURL):

  • UserInterface/Controllers/TimelineManager.js:

(WI.TimelineManager.prototype._processRecord):

  • UserInterface/Models/CallFrame.js:

(WI.CallFrame.fromPayload):

  • UserInterface/Models/ConsoleMessage.js:

(WI.ConsoleMessage.prototype.get sourceCodeLocation):

  • UserInterface/Models/DOMNodeStyles.js:

(WI.DOMNodeStyles.prototype.createSourceCodeLocation):

  • UserInterface/Models/ScriptTimelineRecord.js:

(WI.ScriptTimelineRecord.prototype._initializeProfileFromPayload.profileNodeFromPayload):

  • UserInterface/Views/ContextMenuUtilities.js:

(WI.appendContextMenuItemsForURL):

  • UserInterface/Views/DOMDetailsSidebarPanel.js:

(WI.DOMDetailsSidebarPanel.prototype._mouseWasClicked):

  • UserInterface/Views/SearchSidebarPanel.js:

(WI.SearchSidebarPanel.prototype.performSearch):
Use the firstValue instead of the implicit lastValue to match existing nearby usage of
WI.DebuggerManager.prototype.scriptsForURL, which explicitly chooses the first script.

LayoutTests:

  • inspector/unit-tests/set-utilities.html:
  • inspector/unit-tests/set-utilities-expected.txt:

Add test for Set.prototype.find.

  • http/tests/websocket/tests/hybi/inspector/resolveWebSocket.html:

Update usage of resourceForURL to resourcesForURL with Set.prototype.firstValue.

12:57 PM Changeset in webkit [262805] by pvollan@apple.com
  • 2 edits in trunk/Source/WTF

All platforms should enable CFPrefs read only mode in the WebContent process
https://bugs.webkit.org/show_bug.cgi?id=212910

Reviewed by Tim Horton.

In https://bugs.webkit.org/show_bug.cgi?id=212411, CFPrefs read only mode was adopted, but not all platforms were included.

  • wtf/PlatformHave.h:
12:53 PM Changeset in webkit [262804] by Fujii Hironori
  • 2 edits in trunk/Source/WebCore

[Win] ComplexTextControllerUniscribe: Retry ScriptShape with SCRIPT_UNDEFINED if it failed as USP_E_SCRIPT_NOT_IN_FONT
https://bugs.webkit.org/show_bug.cgi?id=212947

Reviewed by Don Olmstead.

If the given font doesn't support the givin text, ScriptShape API
fails as USP_E_SCRIPT_NOT_IN_FONT. In the case, the complex run
was simply ignored and nothing was drawn for the text.

According to Uniscribe document, We should retry ScriptShape with
SCRIPT_UNDEFINED to get missing glyphs.
<https://docs.microsoft.com/en-us/windows/win32/intl/displaying-text-with-uniscribe>

  • platform/graphics/win/ComplexTextControllerUniscribe.cpp:

(WebCore::shapeByUniscribe):

12:39 PM Changeset in webkit [262803] by Fujii Hironori
  • 2 edits in trunk/Source/WebCore

ComplexTextController: Use std::sort to calculate m_runIndices
https://bugs.webkit.org/show_bug.cgi?id=212944

Reviewed by Myles C. Maxfield.

ComplexTextController was using O(n²) sort to lazily calculate
m_runIndices. And, exact matching stringBegin and stringEnd can
cause infinite loop (Bug 212670 and Bug 108877).

Use std::sort instead.

  • platform/graphics/ComplexTextController.cpp:

(WebCore::ComplexTextController::finishConstruction):
(WebCore::ComplexTextController::indexOfCurrentRun):

12:08 PM Changeset in webkit [262802] by Wenson Hsieh
  • 5 edits in trunk/Source

REGRESSION (r260820): [macCatalyst] Web process crashes when uploading a file
https://bugs.webkit.org/show_bug.cgi?id=212976
<rdar://problem/64033186>

Reviewed by Tim Horton.

Source/WebKit:

On Mac Catalyst, we attempt to take a sandbox extension for com.apple.frontboard.systemappservices when
uploading a file; this service does not exist in Catalyst, and we consequently encounter a release assertion
under WebPage::didChooseFilesForOpenPanelWithDisplayStringAndIcon.

Fix this by introducing HAVE(FRONTBOARD_SYSTEM_APP_SERVICES), and using it to guard codepaths that attempt to
grab a mach extension to this service. (As a followup, we should consider adopting this in other places that
currently reference com.apple.frontboard.systemappservices).

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::didChooseFilesForOpenPanelWithDisplayStringAndIcon):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::didChooseFilesForOpenPanelWithDisplayStringAndIcon):

Source/WTF:

Add HAVE(FRONTBOARD_SYSTEM_APP_SERVICES).

  • wtf/PlatformHave.h:
11:53 AM Changeset in webkit [262801] by Jonathan Bedard
  • 7 edits in trunk/Source/WebKit

WebKit: Support watchOS and tvOS in xcconfigs
https://bugs.webkit.org/show_bug.cgi?id=212977
<rdar://problem/64170532>

Reviewed by Tim Horton.

No new tests, behavior unchanged.

  • Configurations/Base.xcconfig: Add tvOS and watchOS major version macros.
  • Configurations/BaseTarget.xcconfig: Include tvOS and watchOS framework stubs.
  • Configurations/BaseXPCService.xcconfig: Generalize excluded files for all embedded platforms.
  • Configurations/GPUService.xcconfig: Generalize INFOPLIST for embedded platforms.
  • Configurations/NetworkService.xcconfig: Ditto.
  • Configurations/WebContentService.xcconfig: Ditto.
11:46 AM Changeset in webkit [262800] by timothy_horton@apple.com
  • 5 edits in trunk/Tools

WebKit.ShrinkToFit is failing on some bots
https://bugs.webkit.org/show_bug.cgi?id=212932
<rdar://problem/60972407>

Reviewed by Simon Fraser.

TestWebKitAPI was failing to stabilize the overlay scrollbar preference,
because the only stabilization attempt was in the injected bundle
initialization code, and most tests (including ShrinkToFit) do not have
an injected bundle.

Because this preference is manually propagated to the Web Content process,
we can set the default in the volatile domain in the UI process at startup.

We can't move other preferences yet, because they are not manually propagated,
and WebKit's NSUserDefault synchronization mechanism ignores defaults in the
volatile domain (and the initial preference load reads from disk, not
from the UI process, so it wouldn't find them anyway).

  • TestWebKitAPI/Tests/WebKitCocoa/ShrinkToFit.mm:

(TEST):
Explain why the final value of the test is different than the starting value.

  • TestWebKitAPI/mac/InjectedBundleControllerMac.mm:

(TestWebKitAPI::InjectedBundleController::platformInitialize):
Leave a FIXME for future generations.

  • TestWebKitAPI/mac/mainMac.mm:

(main):
Override overlay scrollbar preferences in the UI process, so it affects all tests.

  • TestWebKitAPI/Tests/WebKit/ResizeReversePaginatedWebView.cpp:

This test is also affected by using non-overlay scrollbars; we now have less space, so take up more pages.

11:38 AM Changeset in webkit [262799] by commit-queue@webkit.org
  • 6 edits in trunk/Source/WebKit

Expose PDF file URL in shouldAllowPDFToOpenFromFrame SPI
https://bugs.webkit.org/show_bug.cgi?id=212974

Patch by Alex Christensen <achristensen@webkit.org> on 2020-06-09
Reviewed by Tim Horton.

  • UIProcess/API/APIUIClient.h:

(API::UIClient::confirmPDFOpening):

  • UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
  • UIProcess/Cocoa/UIDelegate.h:
  • UIProcess/Cocoa/UIDelegate.mm:

(WebKit::UIDelegate::setDelegate):
(WebKit::UIDelegate::UIClient::confirmPDFOpening):

  • UIProcess/mac/WebPageProxyMac.mm:

(WebKit::WebPageProxy::savePDFToTemporaryFolderAndOpenWithNativeApplication):
(WebKit::WebPageProxy::openPDFFromTemporaryFolderWithNativeApplication):

11:16 AM Changeset in webkit [262798] by youenn@apple.com
  • 14 edits in trunk

BaseAudioSharedUnit should unmute its clients in case of suspension even if not having any audio unit
https://bugs.webkit.org/show_bug.cgi?id=212970

Reviewed by Eric Carlson.

Source/WebCore:

CoreAudioCaptureSource(s), when muted, are now calling stopProducingData.
This will, in turn, make the BaseAudioSharedUnit stop and no longer have any audio unit.
In that case, when resume is called on the BaseAudioSharedUnit, it will exit early as the audio unit is null.
This will prevent to unmute the CoreAudioCaptureSource(s).

Fix this by removing the audio unit check in BaseAudioSharedUnit::resume.
Add infrastructure testing to be able to write a test.

Covered by added test.

  • platform/mediastream/RealtimeMediaSource.h:
  • platform/mediastream/mac/BaseAudioSharedUnit.cpp:

(WebCore::BaseAudioSharedUnit::resume):

  • platform/mediastream/mac/CoreAudioCaptureSource.cpp:

(WebCore::CoreAudioCaptureSource::setInterruptedForTesting):

  • platform/mediastream/mac/CoreAudioCaptureSource.h:
  • testing/Internals.cpp:

(WebCore::Internals::isMediaStreamSourceInterrupted const):

  • testing/Internals.h:
  • testing/Internals.idl:

Tools:

Add an option to capture in UI process so that the same test can run on both MacOS and iOS.
This eases the testing infra to be able to get audio capture unit state in WebProcess as is the case in iOS.

  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetPreferencesToConsistentValues):
(WTR::updateTestOptionsFromTestHeader):

  • WebKitTestRunner/TestOptions.h:

(WTR::TestOptions::hasSameInitializationOptions const):

LayoutTests:

  • fast/mediastream/media-stream-track-interrupted-expected.txt:
  • fast/mediastream/media-stream-track-interrupted.html:
11:15 AM Changeset in webkit [262797] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

[GTK] Gardening, remove flaky timeout failures after r262789
https://bugs.webkit.org/show_bug.cgi?id=212979

Unreviewed gardening.

Removed flaky timeout failures that have been constantly passing in the last 4000 revisions.

  • platform/gtk/TestExpectations:
10:15 AM Changeset in webkit [262796] by mmaxfield@apple.com
  • 26 edits
    2 adds in trunk

lang=zh needs to defer to system preferences to know whether it should be simplified or traditional
https://bugs.webkit.org/show_bug.cgi?id=212626
<rdar://problem/60227623>

Reviewed by Darin Adler.

Source/WebCore:

If the content says lang="zh" font-family: sans-serif, we have no signal for whether
the content should be traditional or simplified. In this case, we should pick based
on system preferences to make it more likely that we get the right answer.

This is actually what some Cocoa platform text functions were doing, but not all of them.
We need to do it at our level in WebKit to make sure that all our calls to the platform
have consistent behavior. Also, we can cache the result at our level, which is more
performant than if the platform cached it at each platform entry point.

We already started consulting with system preferences to make this decision in r189038.
This patch extends that and fixes it to throughout WebKit.

This doesn't expose any new fingerprinting data, because this information was already
exposed (e.g. by drawing fallback fonts to the canvas and then reading back the pixels).

Tests: fast/text/locale-getComputedStyle.html

fast/text/international/generic-font-family-language-traditional.html

  • css/CSSComputedStyleDeclaration.cpp:

(WebCore::ComputedStyleExtractor::valueForPropertyInStyle):

  • css/CSSFontSelector.cpp:

(WebCore::resolveGenericFamily):

  • css/CSSProperties.json:
  • layout/inlineformatting/InlineLineBreaker.cpp:

(WebCore::Layout::LineBreaker::wordBreakBehavior const):
(WebCore::Layout::LineBreaker::tryBreakingTextRun const):

  • platform/graphics/Font.cpp:

(WebCore::Font::systemFallbackFontForCharacter const):

  • platform/graphics/FontCache.h:

(WebCore::FontDescriptionKey::FontDescriptionKey):

  • platform/graphics/FontCascade.cpp:

(WebCore::FontCascade::widthForSimpleText const):

  • platform/graphics/FontCascadeDescription.cpp:
  • platform/graphics/FontCascadeDescription.h:

(WebCore::FontCascadeDescription::initialSpecifiedLocale):
(WebCore::FontCascadeDescription::initialLocale): Deleted.

  • platform/graphics/FontDescription.cpp:

(WebCore::computeSpecializedChineseLocale):
(WebCore::cachedSpecializedChineseLocale):
(WebCore::fontDescriptionLanguageChanged):
(WebCore::specializedChineseLocale):
(WebCore::FontDescription::setSpecifiedLocale):
(WebCore::FontDescription::setLocale): Deleted.

  • platform/graphics/FontDescription.h:

(WebCore::FontDescription::computedLocale const):
(WebCore::FontDescription::specifiedLocale const):
(WebCore::FontDescription::operator== const):
(WebCore::FontDescription::encode const):
(WebCore::FontDescription::decode):
(WebCore::FontDescription::locale const): Deleted.

  • platform/graphics/WidthIterator.cpp:

(WebCore::WidthIterator::applyFontTransforms):

  • platform/graphics/cocoa/FontCacheCoreText.cpp:

(WebCore::FontCache::systemFallbackForCharacters):

  • platform/graphics/cocoa/FontDescriptionCocoa.cpp:

(WebCore::FontDescription::platformResolveGenericFamily):
(WebCore::computeSpecializedChineseLocale): Deleted.
(WebCore::cachedSpecializedChineseLocale): Deleted.
(WebCore::languageChanged): Deleted.

  • platform/graphics/cocoa/SystemFontDatabaseCoreText.cpp:

(WebCore::SystemFontDatabaseCoreText::systemFontParameters):

  • platform/graphics/mac/ComplexTextControllerCoreText.mm:

(WebCore::ComplexTextController::collectComplexTextRunsForCharacters):

  • rendering/RenderQuote.cpp:

(WebCore::RenderQuote::computeText const):

  • rendering/RenderText.cpp:

(WebCore::maxWordFragmentWidth):
(WebCore::RenderText::computePreferredLogicalWidths):
(WebCore::applyTextTransform):

  • rendering/RenderThemeCocoa.mm:

(WebCore::RenderThemeCocoa::paintApplePayButton):

  • rendering/SimpleLineLayoutTextFragmentIterator.cpp:

(WebCore::SimpleLineLayout::TextFragmentIterator::Style::Style):
(WebCore::SimpleLineLayout::TextFragmentIterator::TextFragmentIterator):

  • rendering/line/BreakingContext.h:

(WebCore::BreakingContext::handleText):

  • rendering/style/RenderStyle.h:

(WebCore::RenderStyle::computedLocale const):
(WebCore::RenderStyle::specifiedLocale const):
(WebCore::RenderStyle::locale const): Deleted.

  • style/StyleBuilderCustom.h:

(WebCore::Style::BuilderCustom::applyValueWebkitLocale):

  • style/StyleResolveForDocument.cpp:

(WebCore::Style::resolveForDocument):

LayoutTests:

Make sure the new locale isn't exposed.

  • fast/text/locale-getComputedStyle-expected.txt: Added.
  • fast/text/locale-getComputedStyle.html: Added.
8:59 AM Changeset in webkit [262795] by Alan Bujtas
  • 5 edits
    2 adds in trunk

[LFC][TFC] Add support for empty table
https://bugs.webkit.org/show_bug.cgi?id=212971

Reviewed by Antti Koivisto.

Source/WebCore:

No need to run formatting context layout when the table box has no descendant.

Test: fast/layoutformattingcontext/empty-table-box.html

  • layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContext.cpp:

(WebCore::Layout::TableWrapperBlockFormattingContext::layoutTableBox):
(WebCore::Layout::TableWrapperBlockFormattingContext::computeBorderAndPaddingForTableBox):
(WebCore::Layout::TableWrapperBlockFormattingContext::computeWidthAndMarginForTableBox):

  • layout/tableformatting/TableFormattingContext.cpp:

(WebCore::Layout::TableFormattingContext::ensureTableGrid):

  • layout/tableformatting/TableGrid.h:

(WebCore::Layout::TableGrid::isEmpty const):

LayoutTests:

  • fast/layoutformattingcontext/empty-table-box-expected.html: Added.
  • fast/layoutformattingcontext/empty-table-box.html: Added.
8:45 AM Changeset in webkit [262794] by youenn@apple.com
  • 3 edits in trunk/Source/WebCore

Forward declare MediaKeys/MediaKeySession in Internals.h
https://bugs.webkit.org/show_bug.cgi?id=212965

Reviewed by Xabier Rodriguez-Calvar.

No change of behavior.

  • testing/Internals.cpp:
  • testing/Internals.h:
8:35 AM Changeset in webkit [262793] by youenn@apple.com
  • 10 edits in trunk

Fix two MediaStream tests
https://bugs.webkit.org/show_bug.cgi?id=208926
<rdar://problem/60329008>

Reviewed by Eric Carlson.

Source/WebCore:

Previously, the mock capture sample rate was the one of the mock audio shared unit, which is the sample rate of the audio session by default.
This sample rate may change according the bots.
For that reason, explicitly set the mock shared unit sample rate to the default sample rate of the device, just before creating the source.
MediaConstraints may still apply after this step.

Fix an issue where we would use the real core audio unit in CoreAudioCaptureSource constructor.
We now pass the unit override if any in constructor.

Covered by unflaked tests.

  • platform/mediastream/mac/BaseAudioSharedUnit.cpp:

(WebCore::BaseAudioSharedUnit::BaseAudioSharedUnit):

  • platform/mediastream/mac/BaseAudioSharedUnit.h:
  • platform/mediastream/mac/CoreAudioCaptureSource.cpp:

(WebCore::initializeCoreAudioCaptureSource):
(WebCore::CoreAudioSharedUnit::CoreAudioSharedUnit):
(WebCore::CoreAudioCaptureSource::create):
(WebCore::CoreAudioCaptureSource::createForTesting):
(WebCore::CoreAudioCaptureSource::CoreAudioCaptureSource):

  • platform/mediastream/mac/CoreAudioCaptureSource.h:
  • platform/mediastream/mac/MockAudioSharedUnit.mm:

(WebCore::MockRealtimeAudioSource::create):
(WebCore::MockAudioSharedUnit::MockAudioSharedUnit):
Do not disable echo cancellation to mimick what the real unit is doing.

LayoutTests:

  • fast/mediastream/MediaStreamTrack-getSettings-expected.txt:
  • fast/mediastream/MediaStreamTrack-getSettings.html:
  • platform/mac-wk2/TestExpectations:

Unskip tests.

8:17 AM Changeset in webkit [262792] by Alan Bujtas
  • 6 edits
    2 adds in trunk

[LFC][Table][Floats] Multi-pass table layout needs clean floating state
https://bugs.webkit.org/show_bug.cgi?id=212889

Reviewed by Antti Koivisto.

Source/WebCore:

When laying out the cell content multiple times to accommodate flex table layout,
the float state needs be cleared to avoid having redundant float content.

Test: fast/layoutformattingcontext/float-inside-table-cell-simple.html

  • layout/floats/FloatingState.cpp:

(WebCore::Layout::FloatingState::append):

  • layout/floats/FloatingState.h:

(WebCore::Layout::FloatingState::FloatItem::floatBox const):

  • layout/layouttree/LayoutTreeBuilder.cpp:

(WebCore::Layout::TreeBuilder::createLayoutBox):

  • layout/tableformatting/TableFormattingContext.cpp:

(WebCore::Layout::TableFormattingContext::layoutCell):

LayoutTests:

  • fast/layoutformattingcontext/float-inside-table-cell-simple-expected.html: Added.
  • fast/layoutformattingcontext/float-inside-table-cell-simple.html: Added.
7:50 AM Changeset in webkit [262791] by commit-queue@webkit.org
  • 17 edits in trunk

[Curl] Implement functions to use ResourceLoadStatistics.
https://bugs.webkit.org/show_bug.cgi?id=207692

Source/WebCore:

Patch by Takashi Komori <Takashi.Komori@sony.com> on 2020-06-09
Reviewed by Don Olmstead.

Implement functions which are required to implement ResourceLoadStatistics for Curl port.

Tests: http/tests/resourceLoadStatistics/

  • CMakeLists.txt:
  • platform/network/curl/CookieJarDB.cpp:

(WebCore::CookieJarDB::openDatabase):
(WebCore::CookieJarDB::setCookie):
(WebCore::CookieJarDB::allDomains):
(WebCore::CookieJarDB::deleteCookiesForHostname):

  • platform/network/curl/CookieJarDB.h:
  • platform/network/curl/NetworkStorageSessionCurl.cpp:

(WebCore::NetworkStorageSession::setCookiesFromDOM const):
(WebCore::NetworkStorageSession::setCookies):
(WebCore::NetworkStorageSession::deleteCookiesForHostnames):
(WebCore::NetworkStorageSession::getHostnamesWithCookies):

Source/WebKit:

Patch by Takashi Komori <Takashi.Komori@sony.com> on 2020-06-09
Reviewed by Don Olmstead.

Implement functions which are required to implement ResourceLoadStatistics for Curl port.

In NetworkDataTaskCurl.cpp we check if we should block cookies and block if needed.

Tests: http/tests/resourceLoadStatistics/

  • NetworkProcess/NetworkDataTask.cpp:

(WebKit::NetworkDataTask::create):

  • NetworkProcess/curl/NetworkDataTaskCurl.cpp:

(WebKit::NetworkDataTaskCurl::NetworkDataTaskCurl):
(WebKit::NetworkDataTaskCurl::createCurlRequest):
(WebKit::NetworkDataTaskCurl::willPerformHTTPRedirection):
(WebKit::NetworkDataTaskCurl::blockCookies):
(WebKit::NetworkDataTaskCurl::unblockCookies):
(WebKit::NetworkDataTaskCurl::shouldBlockCookies):
(WebKit::NetworkDataTaskCurl::isThirdPartyRequest):

  • NetworkProcess/curl/NetworkDataTaskCurl.h:
  • NetworkProcess/curl/NetworkSessionCurl.cpp:

(WebKit::NetworkSessionCurl::NetworkSessionCurl):

  • UIProcess/API/C/WKWebsiteDataStoreRef.cpp:

(WKWebsiteDataStoreGetAllStorageAccessEntries):

  • UIProcess/API/C/WKWebsiteDataStoreRef.h:
  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::parameters):

Tools:

Implement functions which are required to implement ResourceLoadStatistics for Curl port.

Tests: http/tests/resourceLoadStatistics/

Patch by Takashi Komori <Takashi.Komori@sony.com> on 2020-06-09
Reviewed by Don Olmstead.

  • WebKitTestRunner/TestController.cpp:

(WTR::GetAllStorageAccessEntriesCallbackContext::GetAllStorageAccessEntriesCallbackContext):
(WTR::getAllStorageAccessEntriesCallback):
(WTR::TestController::getAllStorageAccessEntries):

LayoutTests:

Patch by Takashi Komori <Takashi.Komori@sony.com> on 2020-06-09
Reviewed by Don Olmstead.

Implement functions which are required to implement ResourceLoadStatistics for Curl port.

Tests: http/tests/resourceLoadStatistics/

  • platform/wincairo/TestExpectations:
7:13 AM Changeset in webkit [262790] by weinig@apple.com
  • 5 edits in trunk/Source/WebCore

Extended Color: Switch ColorMac.mm's nsColor() function over to using TinyLRUCache
https://bugs.webkit.org/show_bug.cgi?id=212918

Reviewed by Darin Adler.

  • platform/graphics/Color.h:

(WebCore::Color::isExtended const):
Make asSimple() public, so nsColor() can use it. This also allows us to unfriend cachedCGColor().

  • platform/graphics/mac/ColorMac.mm:

(WTF::RetainPtr<NSColor>>::createValueForKey):
(WebCore::nsColor):
Mimic the structure of cachedCGColor() by switching over simpleColor values for common
colors and using a 32 value TinyLRUCache for the rest.

5:57 AM Changeset in webkit [262789] by Antti Koivisto
  • 3 edits in trunk/LayoutTests

scrollingcoordinator/ios/scroll-position-after-reattach.html is a flaky image failure
https://bugs.webkit.org/show_bug.cgi?id=212967
<rdar://problem/52961406>

Reviewed by Antoine Quint.

  • platform/ios-wk2/TestExpectations:
  • scrollingcoordinator/ios/scroll-position-after-reattach.html:

Ensure the element is re-added before test finishes.

5:11 AM Changeset in webkit [262788] by jfernandez@igalia.com
  • 5 edits
    12 adds in trunk/LayoutTests

[css-grid] Import some grid tests from WPT
https://bugs.webkit.org/show_bug.cgi?id=212920

Reviewed by Manuel Rego Casasnovas.

LayoutTests/imported/w3c:

Imported some grid related tests from WPT to check how baseline
alignment affects the grid's intrinsic size computation.

  • resources/import-expectations.json:
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-001-expected.txt: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-001.html: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-002-expected.txt: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-002.html: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-003-expected.txt: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-003.html: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-004-expected.txt: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-004.html: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-005-expected.txt: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-005.html: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-006-expected.txt: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/baseline-alignment-affects-intrinsic-size-006.html: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/w3c-import.log:

LayoutTests:

The imported tests fail only for WebKitGtk+ platform.

  • platform/gtk/TestExpectations: Added Failure entries,
4:54 AM Changeset in webkit [262787] by Diego Pino Garcia
  • 4 edits in trunk/LayoutTests

[GLIB] Gardening, clean up failures filed under bug 186638
https://bugs.webkit.org/show_bug.cgi?id=212968

Unreviewed gardening.

Most of the the failures were flaky but many tests have been
consistently passing, so they were removed from expectations. Adjust
other failure entries to their corresponding state inferred from the
latest test bot results.

  • platform/glib/TestExpectations:
  • platform/gtk/TestExpectations:
  • platform/wpe/TestExpectations:
2:20 AM Changeset in webkit [262786] by ysuzuki@apple.com
  • 9 edits in trunk/Source/JavaScriptCore

[JSC] Shrink DATA,(data,bss,common) more
https://bugs.webkit.org/show_bug.cgi?id=212863

Reviewed by Sam Weinig.

  1. Use unsigned instead of size_t in GC size-class array. We know that this number never exceeds largeCutoff, which must be much maller than UINT32_MAX.
  2. Add missing const to various variables to put them DATA,const instead of DATA,data etc.
  • heap/MarkedSpace.cpp:

(JSC::MarkedSpace::initializeSizeClassForStepSize):

  • heap/MarkedSpace.h:
  • heap/VisitRaceKey.cpp:
  • heap/VisitRaceKey.h:
  • inspector/agents/InspectorDebuggerAgent.cpp:
  • inspector/agents/InspectorDebuggerAgent.h:
  • runtime/PropertyDescriptor.cpp:
  • runtime/PropertyDescriptor.h:
2:13 AM Changeset in webkit [262785] by Diego Pino Garcia
  • 4 edits in trunk/LayoutTests

[WPE] Gardening, update test expectations after r262775
https://bugs.webkit.org/show_bug.cgi?id=212966

Unreviewed gardening.

Gardened several WPT flaky failures that were already gardening in
GTK. Moved common failures to GLIB.

  • platform/glib/TestExpectations:
  • platform/gtk/TestExpectations:
  • platform/wpe/TestExpectations:
1:51 AM Changeset in webkit [262784] by Diego Pino Garcia
  • 3 edits
    1 copy
    3 adds in trunk/LayoutTests

[GTK][WPE] Gardening, update baselines for mediaElementAudioSourceToScriptProcessorTest.html
https://bugs.webkit.org/show_bug.cgi?id=184777

Unreviewed gardening.

The expected result for GTK and WPE is the same as the general baseline, it only changes an expected value.
ios-wk2 also has its own baseline for the same reason.

  • platform/gtk/TestExpectations:
  • platform/gtk/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-mediaelementaudiosourcenode-interface/mediaElementAudioSourceToScriptProcessorTest-expected.txt: Added.
  • platform/wpe/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-mediaelementaudiosourcenode-interface/mediaElementAudioSourceToScriptProcessorTest-expected.txt:
1:50 AM Changeset in webkit [262783] by dino@apple.com
  • 5 edits in branches/safari-609-branch/Source

REGRESSION: [Safari Mojave for High Sierra] Accessing some of the featured pages on apple.com causes the webpage to crash
https://bugs.webkit.org/show_bug.cgi?id=212940

Reviewed by Tim Horton.

The code to use the singleton for a SwitchingGPUClient was assuming it
has always been set, which was not the case when
ENABLE(WEBPROCESS_WINDOWSERVER_BLOCKING) was not true.

Source/WebCore:

  • platform/graphics/GraphicsContext3DManager.cpp: Check the state of the

singleton before calling it.
(WebCore::GraphicsContext3DManager::updateHighPerformanceState):
(WebCore::GraphicsContext3DManager::disableHighPerformanceGPUTimerFired):

  • platform/graphics/mac/SwitchingGPUClient.h: Add a method to check if the

singleton has been set.
(WebCore::SwitchingGPUClient::hasSingleton):

Source/WebKit:

  • WebProcess/cocoa/WebProcessCocoa.mm: Set the singleton unconditionally.

(WebKit::WebProcess::platformInitializeProcess):

1:33 AM Changeset in webkit [262782] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

[Flatpak][GStreamer] enhance GST_ environment variable passing
https://bugs.webkit.org/show_bug.cgi?id=212905

Patch by Víctor Manuel Jáquez Leal <vjaquez@igalia.com> on 2020-06-09
Reviewed by Philippe Normand.

Handle the passing of several GST environment variables,
particularly GST_DEBUG, which, when using * symbol, python adds
quotes, but they break the parsing in GStreamer.

Also the variables are handled by gst-env.py when using
GST_BUILD_PATH, so they are filtered out when it's exported,
avoiding duplication. But it GST_BUILD_PATH is not defined, the
variables are passed to flatpak.

  • flatpak/flatpakutils.py:

(WebkitFlatpak.setup_gstbuild):
(WebkitFlatpak.run_in_sandbox):

1:23 AM Changeset in webkit [262781] by calvaris@igalia.com
  • 13 edits
    2 adds in trunk

[EME] CDMProxyInstance should not keep CDMInstanceSessions hard referenced
https://bugs.webkit.org/show_bug.cgi?id=212689

Reviewed by Youenn Fablet.

Source/WebCore:

Sessions are now tracked as WeakPtr inside the CDMInstanceProxy
instead of RefPtr because this creates referencing issues as the
internal objects should be released when the backing JS object is
garbage collected.

Test: media/encrypted-media/clearKey/clearKey-session-life-cycle.html

  • Modules/encryptedmedia/MediaKeySession.h:
  • Modules/encryptedmedia/MediaKeySession.idl:
  • Modules/encryptedmedia/MediaKeys.h:
  • Modules/encryptedmedia/MediaKeys.idl:
  • platform/encryptedmedia/CDMProxy.cpp:

(WebCore::CDMInstanceProxy::trackSession):

  • platform/encryptedmedia/CDMProxy.h:

(WebCore::CDMInstanceProxy::trackSession):

  • platform/encryptedmedia/clearkey/CDMClearKey.cpp:

(WebCore::CDMInstanceClearKey::createSession):

  • platform/encryptedmedia/clearkey/CDMClearKey.h:
  • testing/Internals.cpp:

(WebCore::Internals::mediaKeysInternalInstanceObjectRefCount const):
(WebCore::Internals::mediaKeySessionInternalInstanceSessionObjectRefCount const):

  • testing/Internals.h:
  • testing/Internals.idl:

LayoutTests:

  • media/encrypted-media/clearKey/clearKey-session-life-cycle-expected.txt: Added.
  • media/encrypted-media/clearKey/clearKey-session-life-cycle.html: Added.
12:11 AM Changeset in webkit [262780] by sihui_liu@apple.com
  • 4 edits in trunk

TextManipulationController range of paragraph may be wrong after r262601
https://bugs.webkit.org/show_bug.cgi?id=212874

Reviewed by Wenson Hsieh.

Source/WebCore:

Start and end position of item are not properly set in r262601.

Test: TextManipulation.CompleteTextManipulationSuccedsWhenContentOutOfParagraphIsAdded

  • editing/TextManipulationController.cpp:

(WebCore::TextManipulationController::addItemIfPossible):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/TextManipulation.mm:

(TestWebKitAPI::TEST):

12:06 AM Changeset in webkit [262779] by Lauro Moura
  • 2 edits in trunk/Source/WebKit

[WebDriver][WPE] Follow up WPE fix after r262703
https://bugs.webkit.org/show_bug.cgi?id=212948

Reviewed by Carlos Garcia Campos.

Covered by existing tests.

  • UIProcess/Automation/wpe/WebAutomationSessionWPE.cpp:

(WebKit::WebAutomationSession::platformWebModifiersFromRaw):

Jun 8, 2020:

11:54 PM Changeset in webkit [262778] by sihui_liu@apple.com
  • 5 edits in trunk

TextManipulation should only convert text from Node's text content to tokens
https://bugs.webkit.org/show_bug.cgi?id=212928

Reviewed by Wenson Hsieh.

Source/WebCore:

TextIterator may emit text like line breaks between nodes. This kind of text is generated based on the range of
TextIterator and style of node. We need this text for splitting tokens or splitting paragraphs, but we should
not convert it to normal tokens. This is because tokens should be created from content of node and text
manipulation fails if content does not match. The change of this kind of text does not indicate change in
content and we may still be able to finish text manipulation.

Test: TextManipulation.CompleteTextManipulationReplaceTwoSimpleParagraphs

  • editing/TextManipulationController.cpp:

(WebCore::isInPrivateUseArea):
(WebCore::isTokenDelimiter):
(WebCore::ParagraphContentIterator::currentContent):
(WebCore::ParagraphContentIterator::appendToText):
(WebCore::ParagraphContentIterator::advanceIteratorNodeAndUpdateText):
(WebCore::TextManipulationController::createUnit):
(WebCore::TextManipulationController::parse):
(WebCore::TextManipulationController::observeParagraphs):
(WebCore::TextManipulationController::replace):

  • editing/TextManipulationController.h:

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/TextManipulation.mm:

(TestWebKitAPI::TEST):

11:50 PM Changeset in webkit [262777] by Diego Pino Garcia
  • 4 edits in trunk/LayoutTests

[WPE] Gardening, update test expectations after r262763
https://bugs.webkit.org/show_bug.cgi?id=212961

Unreviewed gardening.

  • platform/glib/TestExpectations: Moved several bugs that were also hapenning in WPE from GTK to GLIB.
  • platform/gtk/TestExpectations:
  • platform/wpe/TestExpectations: Removed test passing and filed a few new bugs.
11:44 PM Changeset in webkit [262776] by commit-queue@webkit.org
  • 6 edits
    2 deletes in trunk

XMLHTTPRequest.send should not send Content-Type headers when Blob has no type
https://bugs.webkit.org/show_bug.cgi?id=211999

Patch by Rob Buis <rbuis@igalia.com> on 2020-06-08
Reviewed by Alex Christensen.

LayoutTests/imported/w3c:

Update improved test expectation.

  • web-platform-tests/xhr/send-blob-with-no-mime-type-expected.txt:

Source/WebCore:

XMLHTTPRequest.send should not send Content-Type headers when Blob has no type [1, 2].
This behavior overrides the behavior of the File API spec [3].

Behavior matches Firefox and Chrome.

Test: imported/w3c/web-platform-tests/xhr/send-blob-with-no-mime-type.html

[1] https://xhr.spec.whatwg.org/#dom-xmlhttprequest-send
[2] https://fetch.spec.whatwg.org/#concept-bodyinit-extract
[3] http://dev.w3.org/2006/webapi/FileAPI/#dfn-type

  • platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:

(-[WebCoreResourceHandleAsOperationQueueDelegate connection:willSendRequest:redirectResponse:]):

  • xml/XMLHttpRequest.cpp:

(WebCore::XMLHttpRequest::send):

LayoutTests:

Remove unneeded expectations.

  • platform/ios/imported/w3c/web-platform-tests/xhr/send-blob-with-no-mime-type-expected.txt: Removed.
  • platform/mac/imported/w3c/web-platform-tests/xhr/send-blob-with-no-mime-type-expected.txt: Removed.
10:37 PM Changeset in webkit [262775] by Diego Pino Garcia
  • 3 edits in trunk/Tools

[webkitpy] Check 'bug-search' returns a non null result before parsing
https://bugs.webkit.org/show_bug.cgi?id=212906

Reviewed by Jonathan Bedard.

  • Scripts/webkitpy/common/net/bugzilla/bugzilla.py:

(BugzillaQueries._parse_result_count): Check quick-search query
response is non-null and a non-empty text.

10:29 PM Changeset in webkit [262774] by Simon Fraser
  • 4 edits
    3 adds in trunk

Horizontally scrolling elements are broken when revealed by toggling visibility
https://bugs.webkit.org/show_bug.cgi?id=212439
<rdar://problem/63739559>

Reviewed by Zalan Bujtas.

Source/WebCore:

When revealing an overflow:scroll by toggling the visibility property, make sure that
we use composited scrolling.

computeScrollDimensions() is only updated on layout, so we need to recompute m_hasCompositedScrollableOverflow
on style change as well.

Test: compositing/scrolling/async-overflow-scrolling/toggle-visibility-on-scroller.html

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::computeScrollDimensions):
(WebCore::RenderLayer::computeHasCompositedScrollableOverflow):
(WebCore::RenderLayer::calculateClipRects const):

  • rendering/RenderLayer.h:

LayoutTests:

  • compositing/scrolling/async-overflow-scrolling/toggle-visibility-on-scroller-expected.txt: Added.
  • compositing/scrolling/async-overflow-scrolling/toggle-visibility-on-scroller.html: Added.
  • platform/ios-wk2/compositing/scrolling/async-overflow-scrolling/toggle-visibility-on-scroller-expected.txt: Added.
10:21 PM Changeset in webkit [262773] by Russell Epstein
  • 8 edits in branches/safari-610.1.15.52-branch/Source

Versioning.

10:19 PM Changeset in webkit [262772] by Russell Epstein
  • 8 edits in branches/safari-610.1.15.51-branch/Source

Versioning.

10:18 PM Changeset in webkit [262771] by Russell Epstein
  • 8 edits in branches/safari-610.1.15.50-branch/Source

Versioning.

10:10 PM Changeset in webkit [262770] by Russell Epstein
  • 1 copy in branches/safari-610.1.15.52-branch

New branch.

10:10 PM Changeset in webkit [262769] by Russell Epstein
  • 1 copy in branches/safari-610.1.15.51-branch

New branch.

10:09 PM Changeset in webkit [262768] by Russell Epstein
  • 1 copy in branches/safari-610.1.15.50-branch

New branch.

9:58 PM Changeset in webkit [262767] by Diego Pino Garcia
  • 3 edits in trunk/LayoutTests

[GTK] Gardening, update test expectations after r262763
https://bugs.webkit.org/show_bug.cgi?id=212957

Unreviewed gardening.

  • platform/glib/TestExpectations: Mark one test as flaky.
  • platform/gtk/TestExpectations: Remove two tests passing after r262740.
9:48 PM Changeset in webkit [262766] by Lauro Moura
  • 2 edits in trunk/WebDriverTests

[WebDriver][WPE] Gardening most of the remaining WPE failures.

Unreviewed test gardening.

9:34 PM Changeset in webkit [262765] by Chris Fleizach
  • 2 edits in trunk/Source/WTF

HAVE(ACCESSIBILITY_BUNDLES_PATH) is defined in terms of PLATFORM(IOS_FAMILY) but only checks the version of IPHONE_OS_VERSION_MIN_REQUIRED
https://bugs.webkit.org/show_bug.cgi?id=212704
<rdar://problem/63931340>

Reviewed by Darin Adler.

Ensure that this works for all iOS familes.

  • wtf/PlatformHave.h:
8:24 PM Changeset in webkit [262764] by Jonathan Bedard
  • 2 edits in trunk/Source/WebKitLegacy/mac

WebKitLegacy: Exclude NSURLConnectionSPI.h from watchOS
https://bugs.webkit.org/show_bug.cgi?id=212942
<rdar://problem/64141877>

Reviewed by Alexey Proskuryakov.

  • Misc/WebDownload.h: Exclude NSURLConnectionSPI.h from watchOS, replace

CFNSURLConnection.h with NSURLConnectionSPI.h.

7:19 PM Changeset in webkit [262763] by Ross Kirsling
  • 8 edits in trunk/JSTests

[Intl] Update tests to support ICU 67
https://bugs.webkit.org/show_bug.cgi?id=212943

Reviewed by Yusuke Suzuki.

Our tests have been assuming ICU 60-64 results but WinCairo and PlayStation are now on ICU 67,
which includes fixes for variant alphabetization and non-explicit "-true" values in locale strings.

  • stress/intl-collator.js:

(explicitTrueBeforeICU67):
(shouldBe.testCollator.Intl.Collator):

  • stress/intl-datetimeformat.js:
  • stress/intl-locale.js:
  • stress/intl-numberformat.js:
  • stress/intl-object.js:
  • stress/intl-pluralrules.js:
  • stress/intl-relativetimeformat.js:
6:26 PM Changeset in webkit [262762] by ddkilzer@apple.com
  • 5 edits in trunk/Source/WebKit

[IPC] Adopt enum class for IPC::CFType
<https://webkit.org/b/212921>
<rdar://problem/64134506>

Reviewed by Darin Adler.

Summary:

  • Convert IPC::CFType to enum class.
  • Rule for new enum names is to remove "Ref" suffix from the actual type name.
  • Special enum CFType::Null renamed to CFType::Nullptr to differentiate from CFType::CFNull objects.
  • Shared/cf/ArgumentCodersCF.cpp:

(IPC::tokenNullTypeRef): Delete.
(IPC::tokenNullptrTypeRef): Add.

  • Rename tokenNullTypeRef() to tokenNullptrTypeRef().

(IPC::CFType):

  • Convert to enum class.

(IPC::typeFromCFTypeRef):
(IPC::encode):

  • Switch from encodeEnum() to operator<<().

(IPC::decode):

  • Switch from decodeEnum() to decode().

(WTF::EnumTraits<IPC::CFType>): Add.

  • Shared/cf/ArgumentCodersCF.h:

(IPC::tokenNullTypeRef): Delete.
(IPC::tokenNullptrTypeRef): Add.

  • Rename tokenNullTypeRef() to tokenNullptrTypeRef().
  • Shared/mac/WebCoreArgumentCodersMac.mm:

(IPC::ArgumentCoder<WebCore::ResourceRequest>::encodePlatformData):
(IPC::ArgumentCoder<WebCore::ResourceRequest>::decodePlatformData):

  • Switch to use tokenNullptrTypeRef().
  • mac/WebKit2.order:
  • Update symbol name after renaming tokenNullTypeRef().
6:11 PM Changeset in webkit [262761] by Russell Epstein
  • 2 edits in branches/safari-610.1.15.5.0-branch/Source/WebKit

Cherry-pick r262644. rdar://problem/64127898

[iOS] Remove message filtering telemetry for expected case
https://bugs.webkit.org/show_bug.cgi?id=212841
<rdar://problem/63893460>

Reviewed by Per Arne Vollan.

Remove unintentional telemetry being captured for expected behavior.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:

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

6:11 PM Changeset in webkit [262760] by Russell Epstein
  • 2 edits in branches/safari-610.1.15.5.0-branch/Source/WebKit

Cherry-pick r262636. rdar://problem/64136089

[iOS] Fix message filter sandbox violation
https://bugs.webkit.org/show_bug.cgi?id=212837
<rdar://problem/63830368>

Reviewed by Darin Adler.

Add required message to message filter in the iOS WebContent sandbox.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:

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

6:08 PM Changeset in webkit [262759] by Russell Epstein
  • 8 edits in branches/safari-610.1.15.5.0-branch/Source

Versioning.

5:59 PM Changeset in webkit [262758] by Russell Epstein
  • 2 edits in branches/safari-610.1.15.5.2-branch/Source/WebKit

Cherry-pick r262636. rdar://problem/64127485

[iOS] Fix message filter sandbox violation
https://bugs.webkit.org/show_bug.cgi?id=212837
<rdar://problem/63830368>

Reviewed by Darin Adler.

Add required message to message filter in the iOS WebContent sandbox.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:

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

5:49 PM Changeset in webkit [262757] by Russell Epstein
  • 8 edits in branches/safari-610.1.15.5.2-branch/Source

Versioning.

5:35 PM Changeset in webkit [262756] by Jonathan Bedard
  • 2 edits in trunk/Source/WebCore/PAL

WebCore: Guard _preconnect declaration with ENABLE(SERVER_PRECONNECT)
https://bugs.webkit.org/show_bug.cgi?id=212935
<rdar://problem/64139060>

Reviewed by Alexey Proskuryakov.

  • pal/spi/cf/CFNetworkSPI.h:
5:22 PM Changeset in webkit [262755] by Alan Coon
  • 1 copy in tags/Safari-610.1.16.2

Tag Safari-610.1.16.2.

5:16 PM Changeset in webkit [262754] by Alan Coon
  • 8 edits in branches/safari-610.1.16-branch/Source

Versioning.

5:10 PM Changeset in webkit [262753] by weinig@apple.com
  • 8 edits in trunk

Extended Color: Rename Color::lighten() and Color::darken() to Color::lightened() and Color::darkened()
https://bugs.webkit.org/show_bug.cgi?id=212917

Reviewed by Darin Adler.

Addresses feedback from Darin.

Source/WebCore:

  • platform/graphics/Color.cpp:

(WebCore::Color::lightened const):
(WebCore::Color::darkened const):
(WebCore::Color::lighten const): Deleted.
(WebCore::Color::darken const): Deleted.

  • platform/graphics/Color.h:
  • rendering/RenderObject.cpp:

(WebCore::RenderObject::calculateBorderStyleColor):

  • rendering/RenderTheme.cpp:

(WebCore::RenderTheme::disabledTextColor const):

  • rendering/TextPaintStyle.cpp:

(WebCore::adjustColorForVisibilityOnBackground):

Tools:

  • TestWebKitAPI/Tests/WebCore/ColorTests.cpp:

(TestWebKitAPI::TEST):

4:47 PM Changeset in webkit [262752] by Kate Cheney
  • 2 edits in trunk/Source/WebKit

ResourceLoadStatisticsDatabaseStore::domainIDFromString failed, error message: bad parameter or other API misuse
https://bugs.webkit.org/show_bug.cgi?id=212916
<rdar://problem/64127238>

Reviewed by Sihui Liu.

Make sure m_domainIDFromStringStatement is accessed in a separate
scope in ensureResourceStatisticsForRegistrableDomain() so it will be
reset before being used again.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:

(WebKit::ResourceLoadStatisticsDatabaseStore::domainID const):
Add debug assert to ensure that tests catch this case.

(WebKit::ResourceLoadStatisticsDatabaseStore::ensureResourceStatisticsForRegistrableDomain const):

4:22 PM Changeset in webkit [262751] by Devin Rousso
  • 2 edits in trunk/Source/WebCore

Remove unnecessary variable in WindowProxy::createJSWindowProxy
https://bugs.webkit.org/show_bug.cgi?id=212929

Reviewed by Darin Adler.

  • bindings/js/WindowProxy.cpp:

(WebCore::WindowProxy::createJSWindowProxy):

4:03 PM Changeset in webkit [262750] by Alan Coon
  • 1 copy in branches/safari-610.1.15.5.2-branch

New branch.

4:03 PM Changeset in webkit [262749] by Alan Coon
  • 1 copy in branches/safari-610.1.15.5.1-branch

New branch.

4:02 PM Changeset in webkit [262748] by Alan Coon
  • 1 copy in branches/safari-610.1.15.5.0-branch

New branch.

3:48 PM Changeset in webkit [262747] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Turn some WebPageProxy logging into error logging
https://bugs.webkit.org/show_bug.cgi?id=212922
<rdar://problem/63894722>

Reviewed by Geoffrey Garen.

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::didFailProvisionalLoadForFrameShared):
(WebKit::WebPageProxy::didFailLoadForFrame):
(WebKit::WebPageProxy::processDidTerminate):
(WebKit::WebPageProxy::dispatchProcessDidTerminate):
(WebKit::WebPageProxy::tryReloadAfterProcessTermination):
(WebKit::WebPageProxy::didExceedInactiveMemoryLimitWhileActive):
(WebKit::WebPageProxy::didExceedBackgroundCPULimitWhileInForeground):

3:46 PM Changeset in webkit [262746] by keith_miller@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

Removed unneeded POINTER_WIDTH macro from b3
https://bugs.webkit.org/show_bug.cgi?id=212927

Reviewed by Yusuke Suzuki.

C++20 has real constexpr functions so we don't need the
POINTER_WIDTH macro anymore.

  • b3/B3Width.h:

(JSC::B3::pointerWidth):

  • b3/air/opcode_generator.rb:
3:38 PM Changeset in webkit [262745] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

Gardening, remove tests passing after r262716
https://bugs.webkit.org/show_bug.cgi?id=212923

Unreviewed gardening.

Several css-grid tests marked as failure are passing in all platforms after r262716.

3:29 PM Changeset in webkit [262744] by Alan Coon
  • 1 copy in tags/Safari-610.1.15.5

Tag Safari-610.1.15.5.

3:14 PM Changeset in webkit [262743] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebCore

Release Assert @ WebCore::RenderTreeBuilder::RenderTreeBuilder
https://bugs.webkit.org/show_bug.cgi?id=212714

Patch by Pinki Gyanchandani <pgyanchandani@apple.com> on 2020-06-08
Reviewed by Geoffrey Garen.

Widget removal in the middle of building a Render Tree causes side effects, leading to Release Assert. Moved the scope for suspension of widgets
update to RenderTreeBuilder instead of having it in RenderTreeUpdater.

Test would be added later.

  • rendering/updating/RenderTreeBuilder.h:
  • rendering/updating/RenderTreeUpdater.cpp:

(WebCore::RenderTreeUpdater::tearDownRenderers):

3:03 PM Changeset in webkit [262742] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

[GTK] Gardening, update expectations after 262724
https://bugs.webkit.org/show_bug.cgi?id=212926

Unreviewed gardening.

Add failure to test expectationd and remove failing test that is
passing since r262466.

  • platform/gtk/TestExpectations:
2:44 PM Changeset in webkit [262741] by Diego Pino Garcia
  • 3 edits in trunk/LayoutTests

[GTK][WPE] Remove test failures passing after r262707
https://bugs.webkit.org/show_bug.cgi?id=212924

Unreviewed gardening.

  • platform/gtk/TestExpectations:
  • platform/wpe/TestExpectations:
2:34 PM Changeset in webkit [262740] by weinig@apple.com
  • 2 edits in trunk/Tools

Fix test results after r262733.

  • TestWebKitAPI/Tests/WebCore/ColorTests.cpp:

(TestWebKitAPI::TEST):

2:07 PM Changeset in webkit [262739] by ysuzuki@apple.com
  • 4 edits in trunk/Source/WebCore

Use usual promise in readableStreamTee
https://bugs.webkit.org/show_bug.cgi?id=212715

Reviewed by Mark Lam.

The spec[1] is organized to be OK to use usual promises here. This patch uses usual promises instead of internal ones.

[1]: https://streams.spec.whatwg.org/#readable-stream-tee

  • Modules/streams/ReadableStreamInternals.js:

(readableStreamTee):

1:43 PM Changeset in webkit [262738] by keith_miller@apple.com
  • 9 edits in trunk/JSTests

Fix tests that time out on Series 4 Watch
https://bugs.webkit.org/show_bug.cgi?id=212911

Reviewed by Saam Barati.

Simplify some logic about when to skip microbenchmarks to $jitTests.
Also reduce iteration count for
dont-range-based-iterate-vector-that-is-mutated.js

Also, mark wasm tests as not run on watch.

  • microbenchmarks/bit-test-constant.js:
  • microbenchmarks/bit-test-nonconstant.js:
  • microbenchmarks/interpreter-wasm.js:
  • microbenchmarks/memcpy-typed-loop-large.js:
  • microbenchmarks/memcpy-typed-loop-small.js:
  • microbenchmarks/mul-immediate-sub.js:
  • stress/dont-range-based-iterate-vector-that-is-mutated.js:
  • stress/sampling-profiler-richards.js:
1:36 PM Changeset in webkit [262737] by achristensen@apple.com
  • 2 edits in branches/safari-609-branch/Tools

Fix branch build after r262552

  • TestWebKitAPI/Tests/WTF/cocoa/URLExtras.mm:

(TestWebKitAPI::TEST):
The branch WTF::URL has an operator NSURL * and an operator NSString *, so we need to specify which to use.

1:30 PM Changeset in webkit [262736] by Lauro Moura
  • 2 edits in trunk/WebDriverTests

[WebDriver][GTK][WPE] Fix overwritten expectations.

WPE's set_window_rect/set.py expectations were in a block after the
existing ones from other ports, overwriting them. This commit now
merges them to be in a single block.

Unreviewed test gardening.

1:07 PM Changeset in webkit [262735] by ddkilzer@apple.com
  • 22 edits in trunk

[IPC] Adopt enum class for DragOperation
<https://webkit.org/b/212870>
<rdar://problem/64069940>

Reviewed by Darin Adler.

Source/WebCore:

  • dom/DataTransfer.cpp:

(WebCore::dragOpFromIEOp):
(WebCore::IEOpFromDragOp):
(WebCore::DataTransfer::sourceOperationMask const):
(WebCore::DataTransfer::destinationOperationMask const):
(WebCore::DataTransfer::setSourceOperationMask):
(WebCore::DataTransfer::setDestinationOperationMask):
(WebCore::DataTransfer::setEffectAllowed):

  • page/DragActions.h:

(WebCore::DragOperation):

  • Convert to enum class.

(WebCore::anyDragOperation):

  • page/DragController.cpp:

(WebCore::DragController::platformGenericDragOperation):
(WebCore::DragController::dragEnteredOrUpdated):
(WebCore::DragController::tryDocumentDrag):
(WebCore::defaultOperationForDrag):
(WebCore::DragController::startDrag):

  • page/EventHandler.cpp:

(WebCore::convertDropZoneOperationToDragOperation):
(WebCore::convertDragOperationToDropZoneOperation):

  • page/gtk/DragControllerGtk.cpp:

(WebCore::DragController::dragOperation):

  • page/mac/DragControllerMac.mm:

(WebCore::DragController::dragOperation):
(WebCore::DragController::platformGenericDragOperation):

  • page/win/DragControllerWin.cpp:

(WebCore::DragController::dragOperation):

  • platform/gtk/GtkUtilities.cpp:

(WebCore::gdkDragActionToDragOperation):
(WebCore::dragOperationToGdkDragActions):
(WebCore::dragOperationToSingleGdkDragAction):

Source/WebKit:

  • Scripts/webkit/messages.py:
  • Remove FIXME now that it's not needed.
  • Shared/API/Cocoa/_WKDragActionsInternal.h:

(WebKit::coreDragOperationMask):

  • UIProcess/Cocoa/WebViewImpl.mm:

(WebKit::kit):

  • UIProcess/ios/WKContentViewInteraction.mm:

(dropOperationForWebCoreDragOperation):
(coreDragOperationForUIDropOperation):
(-[WKContentView dragDataForDropSession:dragDestinationAction:]):

Source/WebKitLegacy/mac:

  • WebView/WebHTMLView.mm:

(kit):

  • WebView/WebView.mm:

(coreDragOperationMask):
(kit):

Source/WebKitLegacy/win:

  • WebCoreSupport/WebDragClient.cpp:

(draggingSourceOperationMaskToDragCursors):
(WebDragClient::startDrag):

  • WebView.cpp:

(dragOperationToDragCursor):
(WebView::keyStateToDragOperation const):

Tools:

  • Scripts/do-webcore-rename:
  • Do DragOperation renames.
1:04 PM Changeset in webkit [262734] by commit-queue@webkit.org
  • 7 edits in trunk

Unreviewed, reverting r262685.
https://bugs.webkit.org/show_bug.cgi?id=212914

caused flakey crashes in an iOS test

Reverted changeset:

"Clear WebPageProxy event state between tests"
https://bugs.webkit.org/show_bug.cgi?id=212864
https://trac.webkit.org/changeset/262685

12:37 PM Changeset in webkit [262733] by weinig@apple.com
  • 27 edits in trunk

Extended Color: Unify rounding / clamping conversions between 0-1 float components and 0-255 byte components
https://bugs.webkit.org/show_bug.cgi?id=212871

Reviewed by Simon Fraser.
Source/WebCore:

Unify all conversions of 0.0f - 1.0f float based color components to 0-255 int based color components
to use the new convertToComponentByte() function which scales, rounds (using lroundf) and clamps the
value. For consistency, a convertToComponentFloat() function, which just scales down an int based value
to a float based value, is also added.

  • Removes *UsingAlternativeRounding variants (actually, we now only have this variant) for color functions which allowed callers to pick from truncation vs. rounding when overriding alpha.
  • Replaces all uses of scaleRoundAndClampColorChannel() with convertToComponentByte() (really just a rename).
  • Replaces uses of nextafter(256, 0) based conversions with convertToComponentByte().

Also:

  • Moves roundAndClampColorChannel() functions to SVGAnimationAdditiveValueFunctionImpl.h, which was the only places they were used.
  • Removes areEssentiallyEqual() overload taking ColorComponents<float>. It was ununsed.
  • Removes makeSimpleColorFromHSLA(...) and just inlines makeSimpleColor(hslToSRGB(...)) which now does the same thing.
  • css/parser/CSSPropertyParserHelpers.cpp:

(WebCore::CSSPropertyParserHelpers::clampRGBComponent):
Use convertPrescaledToComponentByte() to round and clamp the components.

(WebCore::CSSPropertyParserHelpers::parseRGBParameters):
Use uint8_t more consistently now that helpers ensure that is the return type
of conversion functions.

(WebCore::CSSPropertyParserHelpers::parseHSLParameters):
Switch to using makeSimpleColor(hslToSRGB(...)) directly.

  • editing/cocoa/DataDetection.mm:

(WebCore::DataDetection::detectContentInRange):
Switch to using makeSimpleColor(hslToSRGB(...)) directly.

  • html/HTMLElement.cpp:

(WebCore::parseLegacyColorValue):
Use uint8_t since that is what toASCIIHexValue() returns.

  • html/canvas/CanvasRenderingContext2DBase.cpp:

(WebCore::CanvasRenderingContext2DBase::setStrokeStyle):
(WebCore::CanvasRenderingContext2DBase::setFillStyle):
(WebCore::CanvasRenderingContext2DBase::setShadow):

  • html/canvas/CanvasStyle.cpp:

(WebCore::CanvasStyle::createFromStringWithOverrideAlpha):
Replaces uses of colorWithAlphaUsingAlternativeRounding() with colorWithAlpha().

  • inspector/agents/InspectorDOMAgent.cpp:

(WebCore::parseColor):
Use convertToComponentByte() rather than a simple truncating cast.

  • platform/graphics/Color.cpp:

(WebCore::Color::light const):
(WebCore::Color::dark const):
Use makeSimpleColorFromFloats() rather than nextafterf(256.0f, 0.0f) conversion.

(WebCore::Color::colorWithAlpha const):
(WebCore::Color::invertedColorWithAlpha const):
Use convertToComponentByte() for alpha conversion.

(WebCore::Color::toSRGBASimpleColorLossy const):
Call asExtended().toSRGBAComponentsLossy() directly to avoid unnecessary branch.

(WebCore::Color::colorWithAlphaMultipliedBy const): Deleted.
(WebCore::Color::colorWithAlphaMultipliedByUsingAlternativeRounding const): Deleted.
(WebCore::Color::colorWithAlphaUsingAlternativeRounding const): Deleted.
Remove UsingAlternativeRounding variants.

  • platform/graphics/Color.h:

(WebCore::Color::alpha const):
Use convertToComponentByte() for alpha conversion.

(WebCore::Color::invertedColorWithAlpha const):
Add an overload taking an Optional<float> for consistency.

(WebCore::Color::colorWithAlphaMultipliedBy const):
(WebCore::Color::colorWithAlpha const):
Simplify by inlining all variants except the main colorWithAlpha().

  • platform/graphics/ColorUtilities.cpp:

(WebCore::areEssentiallyEqual): Deleted.
Remove unused function.

  • platform/graphics/ColorUtilities.h:

(WebCore::convertPrescaledToComponentByte):
Added. Useful for callers who already have prescaled values but need rounding/clamping.

(WebCore::convertToComponentByte):
Added. Bottleneck for float to byte based color component conversions.
(WebCore::convertToComponentFloat):
Added. Bottleneck for byte to float based color component conversions.

  • platform/graphics/SimpleColor.cpp:

(WebCore::makeSimpleColorFromCMYKA):
Use makeSimpleColorFromFloats() rather than nextafterf(256.0f, 0.0f) conversion. Eventually,
when we probably want this to go away and store CMYKA colors as ExtendedColors with their own
color space.

(WebCore::makeSimpleColorFromFloats):
Moved to header.

  • platform/graphics/SimpleColor.h:

(WebCore::SimpleColor::alphaComponentAsFloat const):
Use convertToComponentFloat().

(WebCore::SimpleColor::asSRGBFloatComponents const):
Use convertToComponentFloat().

(WebCore::makeSimpleColor):
Avoid unncessary clamping of the alpha component by calling constructor directly.

(WebCore::makeSimpleColorFromFloats):
Inlined. Calls convertToComponentByte now rather than the older (identical) scaleRoundAndClampColorChannel().

  • platform/graphics/cairo/CairoOperations.cpp:

(WebCore::Cairo::prepareCairoContextSource):
Replaces use of colorWithAlphaMultipliedByUsingAlternativeRounding with colorWithAlphaMultipliedBy().

  • platform/graphics/cg/ColorCG.cpp:

(WebCore::makeSimpleColorFromCGColor):
Use makeSimpleColorFromFloats() rather than nextafter(256.0, 0.0) conversion.

  • platform/graphics/filters/FEFlood.cpp:

(WebCore::FEFlood::platformApplySoftware):
Replaces use of colorWithAlphaMultipliedByUsingAlternativeRounding with colorWithAlphaMultipliedBy().

  • platform/graphics/mac/ColorMac.mm:

(WebCore::makeSimpleColorFromNSColor):
Use makeSimpleColorFromFloats() rather than nextafter(256.0, 0.0) conversion.

  • platform/ios/ColorIOS.mm:

(WebCore::colorFromUIColor):
Use makeSimpleColorFromFloats() rather than nextafter(256.0, 0.0) conversion.

  • svg/SVGStopElement.cpp:

(WebCore::SVGStopElement::stopColorIncludingOpacity const):
Replaces use of colorWithAlphaMultipliedByUsingAlternativeRounding with colorWithAlphaMultipliedBy().

  • svg/properties/SVGAnimationAdditiveValueFunctionImpl.h:

(WebCore::SVGAnimationColorFunction::roundAndClampColorChannel):
Moved from ColorUtilities.h as this was the only use.

Source/WebKit:

  • UIProcess/API/ios/WKWebViewIOS.mm:

(scrollViewBackgroundColor):
Replaces uses of colorWithAlphaUsingAlternativeRounding() with colorWithAlpha().

Tools:

  • TestWebKitAPI/Tests/WebCore/ColorTests.cpp:

(TestWebKitAPI::TEST):
Switch to using makeSimpleColor(hslToSRGB(...)) directly.

LayoutTests:

  • fast/css/ios/system-color-for-css-value-expected.txt:
  • fast/css/ios/system-color-for-css-value.html:

Update test to account for slightly differnt rounding (alpha goes from 0.298 to 0.3).

12:09 PM Changeset in webkit [262732] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebKit

Links in NSAttributedString passed to -[WKWebView _showSafeBrowsingWarningWithURL:title:warning:details:completionHandler:] are ignored
https://bugs.webkit.org/show_bug.cgi?id=212801
<rdar://problem/63027631>

Patch by Richard Houle <rhoule@apple.com> on 2020-06-08
Reviewed by Alex Christensen.

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _showSafeBrowsingWarningWithTitle:warning:details:completionHandler:]): Call the new detailsWithLinks
implementation, asserting if an URL is non nil.
(-[WKWebView _showSafeBrowsingWarningWithURL:title:warning:details:completionHandler:]): Ditto.
(-[WKWebView _showSafeBrowsingWarningWithURL:title:warning:detailsWithLinks:completionHandler:]): Pass the URL to
the completion handler when appropriate.

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
11:54 AM Changeset in webkit [262731] by Russell Epstein
  • 8 edits in branches/safari-610.1.15-branch/Source

Versioning.

11:44 AM Changeset in webkit [262730] by pvollan@apple.com
  • 4 edits in trunk/Source

[Cocoa] Adopt read-only mode for preferences in the WebContent process
https://bugs.webkit.org/show_bug.cgi?id=212411

Reviewed by Darin Adler.

Change name of HAVE define to match SPI name.

Source/WebKit:

  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm:

(WebKit::XPCServiceMain):

Source/WTF:

  • wtf/PlatformHave.h:
11:38 AM Changeset in webkit [262729] by weinig@apple.com
  • 9 edits in trunk

Extended Color: Replace uses of differenceSquared() with luminance based computations
https://bugs.webkit.org/show_bug.cgi?id=212872

Reviewed by Darin Adler.

Source/WebCore:

Replace all uses of differenceSquared() with luminance based comparisons. This is
possible because all of the uses of differenceSquared() were about identifying a
distance from black or white to determine relative brightness. It is more accurate
to do this in terms of luminance, and has the added benefit of being something that
is expressible in all colorspaces (since luminance is defined as the Y-component
of the XYZ colorspace which all colorspaces are convertable to).

  • platform/graphics/Color.cpp:

(WebCore::Color::lighten const):
Renamed Color::light() to Color::lighten(), which makes more sense. The algorithm
used should be updated at some point to also use luminance, but is unchanged for
now.

(WebCore::Color::darken const):
Renamed Color::dark() to Color::darken(), which makes more sense. The algorithm
used should be updated at some point to also use luminance, but is unchanged for
now.

(WebCore::Color::luminance const):
Added. Converts to sRGB for now, but can be updated to work with other color spaces
when needed.

  • platform/graphics/Color.h:

Removed differenceSquared.

  • platform/graphics/ColorUtilities.cpp:

(WebCore::luminance):
Updated to use the standard conversion to linear-sRGB. While there are certainly
some places that specify a 0.03928 cutoff, the much more accepted value (and value
specified by the IEC) is 0.04045, which we use for all other gamma correction.
(See https://entropymine.com/imageworsener/srgbformula/ or https://en.wikipedia.org/wiki/SRGB#The_forward_transformation_(CIE_XYZ_to_sRGB)
for more information on this).

Also added a FIXME about how in the future we can avoid hardcoding the specific values
multiple times by extracting them from the linear-sRGB to XYZ matrix.

  • rendering/RenderObject.cpp:

(WebCore::RenderObject::calculateBorderStyleColor):
Use luminance, rather than distance as a better comparison for whether the color
is too dark or too light for modification.

  • rendering/RenderTheme.cpp:

(WebCore::RenderTheme::disabledTextColor const):
Use luminance, rather than distance as a better comparison for whether the color
is too dark or too light for modification. Also us the contrastRatio utility
function to determine illegibility issues due to contrast, picking a new minimum
that roughly matches the old one based fast/forms/input-disabled-color.html

  • rendering/TextPaintStyle.cpp:

(WebCore::adjustColorForVisibilityOnBackground):
Use luminance, rather than distance as a better comparison for whether the color
is too dark or too light for modification.

Tools:

  • TestWebKitAPI/Tests/WebCore/ColorTests.cpp:

(TestWebKitAPI::TEST):
Add basic tests for Color::luminance(), ensuring white == 1, black == 0, and
darken() and lighten() creat colors with less than / greater than luminance.

11:14 AM Changeset in webkit [262728] by youenn@apple.com
  • 7 edits in trunk

Missing WebRTC Metrics in iOS Safari
https://bugs.webkit.org/show_bug.cgi?id=212668
<rdar://problem/63902458>

Reviewed by Eric Carlson.

Source/WebCore:

Expose more transports related stats.
Covered by updated test.

  • Modules/mediastream/RTCStatsReport.h:
  • Modules/mediastream/RTCStatsReport.idl:
  • Modules/mediastream/libwebrtc/LibWebRTCStatsCollector.cpp:

(WebCore::fillRTCTransportStats):

LayoutTests:

  • webrtc/video-stats-expected.txt:
  • webrtc/video-stats.html:
11:11 AM Changeset in webkit [262727] by Alexey Shvayka
  • 4 edits
    1 add in trunk

JSON.stringify should throw stack overflow error
https://bugs.webkit.org/show_bug.cgi?id=143511

Reviewed by Ross Kirsling and Mark Lam.

JSTests:

  • stress/json-stringify-stack-overflow.js: Added.
  • stress/json-stringify-string-builder-overflow.js:

Source/JavaScriptCore:

This change adds m_holderStack.size() check, reusing the limit of JSON.parse,
and throws StackOverflowError if exceeded, aligning JSC with V8 and SpiderMonkey.
Even with all the cyclic structure checks in place, excess is possible due to
very deeply nested object, user-provided "toJSON" method or functional replacer.

While Stringifier::appendStringifiedValue() and Holder::appendNextProperty()
mutually call each other, recursion is avoided by !holderStackWasEmpty check and
do/while loop at the end of appendStringifiedValue(), as well as cyclic structure
check as per spec [1].

[1]: https://tc39.es/ecma262/#sec-serializejsonobject (step 1)

  • runtime/JSONObject.cpp:

(JSC::Stringifier::appendStringifiedValue):
(JSC::Walker::walk):

11:10 AM Changeset in webkit [262726] by youenn@apple.com
  • 10 edits in trunk

Add missed WebRTC media-source and remote-inbound-rtp stats
https://bugs.webkit.org/show_bug.cgi?id=206645
<rdar://problem/58833958>

Reviewed by Eric Carlson.

Source/ThirdParty/libwebrtc:

  • Configurations/libwebrtc.iOS.exp:
  • Configurations/libwebrtc.iOSsim.exp:
  • Configurations/libwebrtc.mac.exp:

Source/WebCore:

Update stats according latest spec and webrtc backend.
We still expose obsolete trackId for consistency with existing WPT tests.
Covered by existing and updated tests.

  • Modules/mediastream/RTCStatsReport.h:

(WebCore::RTCStatsReport::InboundRtpStreamStats::InboundRtpStreamStats):
(WebCore::RTCStatsReport::RemoteInboundRtpStreamStats::RemoteInboundRtpStreamStats):
(WebCore::RTCStatsReport::OutboundRtpStreamStats::OutboundRtpStreamStats):
(WebCore::RTCStatsReport::InboundRTPStreamStats::InboundRTPStreamStats): Deleted.
(WebCore::RTCStatsReport::OutboundRTPStreamStats::OutboundRTPStreamStats): Deleted.

  • Modules/mediastream/RTCStatsReport.idl:
  • Modules/mediastream/libwebrtc/LibWebRTCStatsCollector.cpp:

(WebCore::fillRtpStreamStats):
(WebCore::fillReceivedRtpStreamStats):
(WebCore::fillInboundRtpStreamStats):
(WebCore::fillRemoteInboundRtpStreamStats):
(WebCore::fillSentRtpStreamStats):
(WebCore::fillOutboundRtpStreamStats):
(WebCore::initializeRTCStatsReportBackingMap):
(WebCore::fillRTCRTPStreamStats): Deleted.
(WebCore::fillInboundRTPStreamStats): Deleted.
(WebCore::fillOutboundRTPStreamStats): Deleted.

LayoutTests:

  • webrtc/video-stats.html:

qpSum is no longer guaranteed to be there.
Also, we loop over stats to ensure we get all of them.

10:52 AM Changeset in webkit [262725] by Jonathan Bedard
  • 5 edits
    1 add in trunk/Source/WebCore

WebCore: Add tvOS and watchOS SPI headers
https://bugs.webkit.org/show_bug.cgi?id=212853
<rdar://problem/64048485>

Reviewed by Andy Estes.

Source/WebCore:

No new tests, no behavior changed.

  • platform/ios/WebCoreMotionManager.h: Forward-declare CMMotionManager.
  • platform/ios/WebCoreMotionManager.mm: Include CoreMotionSPI.h.

Source/WebCore/PAL:

  • PAL.xcodeproj/project.pbxproj: Add CoreMotionSPI.h.
  • pal/spi/cf/CFNetworkSPI.h: CFNetwork SPI should be available on watchOS and tvOS.
  • pal/spi/cocoa/CoreMotionSPI.h: Added.
10:40 AM Changeset in webkit [262724] by pvollan@apple.com
  • 5 edits in trunk

[Cocoa] CFPrefs synchronization does not always work for global preference changes
https://bugs.webkit.org/show_bug.cgi?id=212783

Reviewed by Tim Horton.

Source/WebKit:

In CFPrefs direct mode, synchronization of global preference changes from the UI process to the WebContent process does not always work.
This is caused by the KVO notification being sent to all or some of the NSUserDefault objects, which leads us to believe a non-global
preference was changed. Since a global preference change always leads to some NSUserDefaults object receiving the notification, we can
work around this by checking if the preference being changed really belongs to the domain of the NSUserDefaults object, or if it is a
global preference. Also, stop creating NSUserDefaults object for the global domain, since this is an error according to the docs.

API test: WebKit.GlobalPreferenceChangesUsingDefaultsWrite

  • UIProcess/Cocoa/PreferenceObserver.mm:

(-[WKUserDefaults _notifyObserversOfChangeFromValuesForKeys:toValuesForKeys:]):

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):
(WebKit::WebProcess::notifyPreferencesChanged):

Tools:

Add API test, and add some synchronization to avoid flakiness.

  • TestWebKitAPI/Tests/WebKit/PreferenceChanges.mm:

(-[WKTestPreferenceObserver preferenceDidChange:key:encodedValue:]):
(TEST):
(sharedInstanceMethodOverride):

10:08 AM Changeset in webkit [262723] by Lauro Moura
  • 2 edits in trunk/WebDriverTests

[WebDriver][GTK] Update test expectations after modifier fix

Unreviewed test gardening.

9:55 AM Changeset in webkit [262722] by Alan Bujtas
  • 4 edits
    2 adds in trunk

[LFC][IFC] Add support for min/max-width/height
https://bugs.webkit.org/show_bug.cgi?id=212904

Reviewed by Antti Koivisto.

Source/WebCore:

Test: fast/layoutformattingcontext/inline-max-width-height-simple.html

  • layout/FormattingContextGeometry.cpp:

(WebCore::Layout::FormattingContext::Geometry::computedWidthValue): Adjust assert to check inline, non-replaced boxes only (inline-block is an
inline level element but not an inline element)

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::computeWidthAndMargin):
(WebCore::Layout::InlineFormattingContext::computeHeightAndMargin):

LayoutTests:

  • fast/layoutformattingcontext/inline-max-width-height-simple-expected.html: Added.
  • fast/layoutformattingcontext/inline-max-width-height-simple.html: Added.
9:47 AM Changeset in webkit [262721] by Wenson Hsieh
  • 7 edits
    1 add in trunk

[iOS] Hit-testing on icloud.com is offset after closing a tab
https://bugs.webkit.org/show_bug.cgi?id=212890
<rdar://problem/58775297>

Reviewed by Simon Fraser.

Source/WebKit:

After tapping to create a new tab on the icloud.com settings page (with no other tabs open) and then closing the
new tab, all hit-testing on the page is offset by -33px until the page is reloaded. This bug appears to be a
corner case triggered by a combination of the following three changes:

We start on icloud.com's settings page. When closing the newly created tab, Safari hides the tab bar, causing
both the top content inset and top obscured inset to decrease by 33 points. When applying the top content inset
change, Safari (after <rdar://problem/53660458>) temporarily sets _automaticContentOffsetAdjustmentEnabled on
WKScrollView to NO, which means that the scroll view doesn't automatically adjust its content offset to -70;
instead, it remains at -103 (the content offset when the tab bar is shown).

Because of this, during the next remote layer tree commit where the content size changes,
-_setContentSizePreservingContentOffsetDuringRubberband: will believe that we're currently rubber-banding by
33px, and therefore try to adjust the content offset of the scroll view to be -103 instead of allowing it to be
adjusted back to -70 (see r170463 and -_restoreContentOffsetWithRubberbandAmount:).

This results in the scroll position on the page (document.scrollingElement.scrollTop) reporting -33, even
though the top of the page is flush with the bottom of Safari's browser chrome. Finally, because WKScrollView
is made unscrollable due to overflow: hidden; (r245006), we end up permanently stuck in this state until the
next page load, rather than the next remote layer tree commit that causes any scrolling.

To fix this, add an additional restriction on the rubberbanding offset restoration code in
-_setContentSizePreservingContentOffsetDuringRubberband:, such that we only try to preserve the current
rubberbanded offset if we're actually rubberbanding (that is, dragging or bouncing against the edge of the
scroll view). Note that when rubberbanding against the top of the scroll view on iPad using a trackpad, the
-isDragging property is also true, which matches behavior when panning via touch.

Test: ScrollViewInsetTests.ChangeInsetWithoutAutomaticAdjustmentWhileWebProcessIsUnresponsive

  • Platform/spi/ios/UIKitSPI.h:
  • UIProcess/ios/WKScrollView.mm:

(-[WKScrollView _setContentSizePreservingContentOffsetDuringRubberband:]):

Also, split out the CGSizeEqualToSize(currentContentSize, contentSize) case into a separate early return that
skips the call to -setContentSize: altogether.

Tools:

Add a new API test to verify that the scroll position doesn't get stuck at -30px after shifting both the top
content inset and top obscured inset by 30px. See WebKit ChangeLog for more details.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKitCocoa/overflow-hidden.html: Added.
  • TestWebKitAPI/Tests/ios/ScrollViewInsetTests.mm:

(-[ScrollViewDelegate scrollViewDidScroll:]):
(TestWebKitAPI::TEST):

  • TestWebKitAPI/ios/UIKitSPI.h:
9:17 AM Changeset in webkit [262720] by svillar@igalia.com
  • 11 edits
    2 copies
    3 adds in trunk

[WebXR] Add missing interfaces from the AR module
https://bugs.webkit.org/show_bug.cgi?id=212826

Reviewed by Youenn Fablet.

LayoutTests/imported/w3c:

Added expectations.

  • web-platform-tests/webxr/ar-module/idlharness.https.window-expected.txt: Added.
  • web-platform-tests/webxr/ar-module/xrDevice_isSessionSupported_immersive-ar.https-expected.txt: Added.
  • web-platform-tests/webxr/ar-module/xrDevice_requestSession_immersive-ar.https-expected.txt: Added.

Source/WebCore:

Added the XRInteractionMode partial interface from the WebXR AR module spec. This spec
https://immersive-web.github.io/webxr-ar-module/ expands the WebXR Device API with
functionality available in AR hardware.

Some WebXR wpt tests are now passing.

  • CMakeLists.txt: Added new files.
  • DerivedSources.make: Ditto.
  • Modules/webxr/WebXRSession.cpp:

(WebCore::WebXRSession::interactionMode const): Added.

  • Modules/webxr/WebXRSession.h: Added interactionMode attribute and getter;
  • Modules/webxr/WebXRSession.idl: Added interactionMode attribute;
  • Modules/webxr/XRInteractionMode.h: Added.
  • Modules/webxr/XRInteractionMode.idl: Added.
  • Sources.txt: Added new files.
  • WebCore.xcodeproj/project.pbxproj: Ditto.

LayoutTests:

  • platform/wpe/TestExpectations: Unskipped 3 tests which are passing now.
9:11 AM Changeset in webkit [262719] by Jonathan Bedard
  • 2 edits in trunk/Source/JavaScriptCore

JavaScriptCore: Fix PLATFORM(TVOS) macro
https://bugs.webkit.org/show_bug.cgi?id=212900
<rdar://problem/64118879>

Unreviewed build fix.

  • tools/JSDollarVM.cpp:

(JSC::functionIsMemoryLimited): PLATFORM(TVOS) should be PLATFORM(APPLETV).

8:59 AM Changeset in webkit [262718] by svillar@igalia.com
  • 5 edits in trunk/Source/WebCore

[WebXR] Pass an unsigned long to cancelAnimationCallback() as handle
https://bugs.webkit.org/show_bug.cgi?id=212529

Reviewed by Youenn Fablet.

The type of the handle returned by XRSession::requestAnimationFrame() was recently changed
to unsigned long from long as there was no point in using signed integers for that. However
we forgot to update the cancelAnimationFrame() in the specs as well as it receives the handle
returned by requestAnimationFrame().

We landed https://github.com/immersive-web/webxr/pull/1069 in the WebXR specs so we can now
safely also replace signed by unsigned integers in our implementation.

No new tests as there is no change in functionality.

  • Modules/webxr/WebXRSession.cpp:

(WebCore::WebXRSession::cancelAnimationFrame): Use unsigned ids.

  • Modules/webxr/WebXRSession.h: Ditto.
  • Modules/webxr/WebXRSession.idl: Ditto.
8:56 AM Changeset in webkit [262717] by commit-queue@webkit.org
  • 1 edit
    1 add in trunk/Tools

[Flatpak SDK] Add flatpak-run-nightly
https://bugs.webkit.org/show_bug.cgi?id=212882

Patch by Philippe Normand <pnormand@igalia.com> on 2020-06-08
Reviewed by Carlos Alberto Lopez Perez.

This new script is able to download WPE and GTK builds from the Igalia servers and run the
corresponding binaries (like MiniBrowser, jsc) within the Flatpak SDK.

Unzipped builds will be saved in /tmp and can be reused in further runs (by providing the
path with the -p argument).

Example:
$ webkit-flatpak-run-nightly --wpe MiniBrowser https://webkit.org
<SDK installs to ~/.cache/wk-nightly>
Downloading build release_r262699_b33885.zip from https://wpewebkit-release.igalia.com/built-products/
Extracting build to /tmp/wpewebkit-release-b33885
<MiniBrowser starts>

$ webkit-flatpak-run-nightly --wpe -p /tmp/wpewebkit-release-b33885 jsc
Looking for updates…
Nothing to do.

2+2

4

  • Scripts/webkit-flatpak-run-nightly: Added.
8:52 AM Changeset in webkit [262716] by svillar@igalia.com
  • 9 edits
    6 deletes in trunk

[css-flexbox] align-content should apply even when there's just a single line
https://bugs.webkit.org/show_bug.cgi?id=209871

Reviewed by Manuel Rego Casasnovas.

LayoutTests/imported/w3c:

Mark as PASSing 15 subtests that are now working as expected.

  • web-platform-tests/css/css-flexbox/align-content-wrap-001-expected.txt: Remove FAIL results.
  • web-platform-tests/css/css-flexbox/align-content-wrap-002-expected.txt: Ditto.
  • web-platform-tests/css/css-flexbox/align-content-wrap-003-expected.txt: Ditto.

Source/WebCore:

The 'align-content' property should have no effect on single line flex containers according to
the specs https://drafts.csswg.org/css-flexbox/#propdef-align-content. The current code was not
differentiating between single-line containers and multi-line containers with just 1 line.

Also in order not to introduce regressions and properly support replaced elements as flex items
we replaced the computation of child's width for 'flex-direction:column' by a direct call to
computeLogicalWidthForFragment() which already properly handles all the cases. It used to be
just the shrink-to-fit computation but that was not enough for replaced elements for example or
elements with min/max-size restrictions.

Several align-content-wrap-* subtests are working now. Updated expectations.

  • rendering/RenderFlexibleBox.cpp:

(WebCore::initialAlignContentOffset): Removed check for #lines <= 1, as it is incorrect because it
is true for multi-line containers with just 1 line.
(WebCore::RenderFlexibleBox::alignFlexLines): Use isMultiline() instead of "#lines == 1".
(WebCore::RenderFlexibleBox::childIntrinsicLogicalWidth const): Replace shrink-to-fit computation
by a call computeLogicalWidthForFragment().
(WebCore::RenderFlexibleBox::repositionLogicalHeightDependentFlexItems): Use the whole crossAxisExtent
for single line containers. Moved from alignFlexLines() as it fits much better here.

LayoutTests:

  • TestExpectations:
  • css3/flexbox/alignContent-applies-with-flexWrap-wrap-with-single-line-expected.txt: Removed.
  • css3/flexbox/alignContent-applies-with-flexWrap-wrap-with-single-line.html: Replaced by

WPT's align-content-wrap-001.html.

  • css3/flexbox/flexbox-wordwrap-expected.txt: Removed.
  • css3/flexbox/flexbox-wordwrap.html: Replaced by WPT's align-content-wrap-002.html.
  • css3/flexbox/multiline-align-content-expected.txt: Removed.
  • css3/flexbox/multiline-align-content.html: Replaced by WPT's align-content-wrap-003.html.
  • platform/ios/fast/forms/auto-fill-button/input-strong-password-auto-fill-button-expected.txt:

Updated expectations.

8:34 AM Changeset in webkit [262715] by aestes@apple.com
  • 4 edits in trunk/Source

[Apple Pay] Remove -respondsToSelector: check before calling -[PKPaymentRequest setBoundInterfaceIdentifier:]
https://bugs.webkit.org/show_bug.cgi?id=212884
<rdar://problem/64090963>

Reviewed by Youenn Fablet.

Source/WebKit:

  • Shared/ApplePay/cocoa/WebPaymentCoordinatorProxyCocoa.mm:

(WebKit::WebPaymentCoordinatorProxy::platformPaymentRequest): Relied on the definition of
HAVE_PASSKIT_BOUND_INTERFACE_IDENTIFIER to ensure that PKPaymentRequest will respond to
-setBoundInterfaceIdentifier:.

Source/WTF:

  • wtf/PlatformHave.h: On macOS, HAVE_PASSKIT_BOUND_INTERFACE_IDENTIFIER should be defined

starting in Catalina.

8:32 AM Changeset in webkit [262714] by aestes@apple.com
  • 37 edits in trunk/Source

[Apple Pay] Remove ENABLE_APPLE_PAY_SETUP, ENABLE_APPLE_PAY_SESSION_V7, and HAVE_PASSKIT_PAYMENT_SETUP
https://bugs.webkit.org/show_bug.cgi?id=212883
<rdar://problem/64090763>

Reviewed by Youenn Fablet.

These macros evaluate to true whenever ENABLE(APPLE_PAY) is true on platforms supported by
trunk WebKit, so we can either remove them or replace them with ENABLE(APPLE_PAY).

Source/WebCore:

  • Modules/applepay/ApplePaySetup.cpp:
  • Modules/applepay/ApplePaySetup.idl:
  • Modules/applepay/ApplePaySetupConfiguration.h:
  • Modules/applepay/ApplePaySetupConfiguration.idl:
  • Modules/applepay/ApplePaySetupFeature.idl:
  • Modules/applepay/ApplePaySetupFeature.mm:
  • Modules/applepay/ApplePaySetupFeatureState.h:
  • Modules/applepay/ApplePaySetupFeatureState.idl:
  • Modules/applepay/ApplePaySetupFeatureType.idl:
  • Modules/applepay/ApplePaySetupFeatureTypeWebCore.h:
  • Modules/applepay/ApplePaySetupFeatureWebCore.h:
  • Modules/applepay/ApplePaySetupWebCore.h:
  • Modules/applepay/PaymentCoordinator.cpp:
  • Modules/applepay/PaymentCoordinator.h:
  • Modules/applepay/PaymentCoordinatorClient.cpp:

(WebCore::PaymentCoordinatorClient::supportsVersion):

  • Modules/applepay/PaymentCoordinatorClient.h:

(WebCore::PaymentCoordinatorClient::endApplePaySetup):

  • testing/MockApplePaySetupFeature.cpp:
  • testing/MockApplePaySetupFeature.h:
  • testing/MockPaymentCoordinator.cpp:
  • testing/MockPaymentCoordinator.h:
  • testing/MockPaymentCoordinator.idl:

Source/WebCore/PAL:

  • pal/spi/cocoa/PassKitSPI.h:

Source/WebKit:

  • Shared/ApplePay/ApplePayPaymentSetupFeatures.mm:
  • Shared/ApplePay/ApplePayPaymentSetupFeaturesWebKit.h:
  • Shared/ApplePay/PaymentSetupConfiguration.mm:
  • Shared/ApplePay/PaymentSetupConfigurationWebKit.h:
  • Shared/ApplePay/WebPaymentCoordinatorProxy.h:
  • Shared/ApplePay/WebPaymentCoordinatorProxy.messages.in:
  • Shared/ApplePay/cocoa/WebPaymentCoordinatorProxyCocoa.mm:
  • WebProcess/ApplePay/WebPaymentCoordinator.cpp:
  • WebProcess/ApplePay/WebPaymentCoordinator.h:

Source/WTF:

  • wtf/PlatformEnableCocoa.h:
  • wtf/PlatformHave.h:
7:52 AM Changeset in webkit [262713] by Diego Pino Garcia
  • 2 edits
    1 copy
    2 deletes in trunk/LayoutTests

[WPE] Gardening, update test expectations after r262708
https://bugs.webkit.org/show_bug.cgi?id=212901

Unreviewed gardening.

  • Moved common baseline to glib.
  • Removed redudant WPE baseline.
  • Added flaky failure to test expectations.
  • platform/glib/imported/w3c/web-platform-tests/encoding/single-byte-decoder-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/encoding/single-byte-decoder-expected.txt.
  • platform/wpe/TestExpectations:
  • platform/wpe/imported/w3c/web-platform-tests/html/semantics/selectors/pseudo-classes/inrange-outofrange-expected.txt: Removed.
7:40 AM Changeset in webkit [262712] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

(r261056) [ Mac WK2 ] fast/scrolling/mac/scrollbars/overlay-scrollbar-reveal.html is a flaky timeout
https://bugs.webkit.org/show_bug.cgi?id=212042

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
7:24 AM Changeset in webkit [262711] by Antti Koivisto
  • 3 edits
    2 adds in trunk

Pseudo-elements (::after) in shadow roots don't animate
https://bugs.webkit.org/show_bug.cgi?id=173027
<rdar://problem/42842994>

Reviewed by Antoine Quint.

Source/WebCore:

Test: animations/keyframe-pseudo-shadow.html

  • animation/AnimationTimeline.cpp:

(WebCore::shouldConsiderAnimation):

We should use the actual element instead of the PseudoElement when calling Style::Scope::forOrdinal.
The keyframe code that computes the style already does this correctly.

LayoutTests:

  • animations/keyframe-pseudo-shadow-expected.html: Added.
  • animations/keyframe-pseudo-shadow.html: Added.
7:00 AM Changeset in webkit [262710] by youenn@apple.com
  • 10 edits
    1 copy
    3 adds in trunk

Source/WebCore:
Use one audio unit for all tracks of a given process
https://bugs.webkit.org/show_bug.cgi?id=212406

Reviewed by Eric Carlson.

Before the patch, we were creating one audio unit per track to render.
This is potentially inefficient as this requires to IPC on iOS each audio data.
Instead, we could have one single remote unit that will receive the mixed content of all tracks.
For that purpose, introduce AudioMediaStreamTrackRendererUnit as a singleton.

AudioMediaStreamTrackRendererCocoa will just register/unregister sources to AudioMediaStreamTrackRendererUnit.
AudioMediaStreamTrackRendererUnit will then start/stop as needed and do the mixing.

This requires a change in AudioSampleDataSource to support mixing in case track volumes are different.
If we have to mix and with different volumes, we first pull the samples in a scratch buffer, apply volume and then mix it with the other tracks.

In the future, we might also do the audio rendering with the CoreAudioSharedUnit directly so as to improve as much as possible echo cancellation.

Interruption is handled by the fact that all tracks should stop playing, thus stop their renderer, thus unregister themselves from the renderer unit.
it might be more future proof to add the unit as an interruption observer as a follow-up.

Manually tested plus LayoutTests/webrtc/multi-audio.html

  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/audio/mac/AudioSampleBufferList.cpp:

(WebCore::mixBuffers):
(WebCore::AudioSampleBufferList::mixFrom):

  • platform/audio/mac/AudioSampleBufferList.h:
  • platform/audio/mac/AudioSampleDataSource.mm:

(WebCore::AudioSampleDataSource::pullSamplesInternal):

  • platform/mediastream/mac/AudioMediaStreamTrackRendererCocoa.cpp:

(WebCore::AudioMediaStreamTrackRendererCocoa::start):
(WebCore::AudioMediaStreamTrackRendererCocoa::stop):
(WebCore::AudioMediaStreamTrackRendererCocoa::clear):
(WebCore::AudioMediaStreamTrackRendererCocoa::setVolume):
(WebCore::AudioMediaStreamTrackRendererCocoa::pushSamples):
(WebCore::AudioMediaStreamTrackRendererCocoa::createAudioUnit): Deleted.
(WebCore::AudioMediaStreamTrackRendererCocoa::render): Deleted.
(WebCore::AudioMediaStreamTrackRendererCocoa::inputProc): Deleted.

  • platform/mediastream/mac/AudioMediaStreamTrackRendererCocoa.h:

(): Deleted.

  • platform/mediastream/mac/AudioMediaStreamTrackRendererUnit.cpp: Added.

(WebCore::AudioMediaStreamTrackRendererUnit::singleton):
(WebCore::AudioMediaStreamTrackRendererUnit::~AudioMediaStreamTrackRendererUnit):
(WebCore::AudioMediaStreamTrackRendererUnit::addSource):
(WebCore::AudioMediaStreamTrackRendererUnit::removeSource):
(WebCore::AudioMediaStreamTrackRendererUnit::createAudioUnitIfNeeded):
(WebCore::AudioMediaStreamTrackRendererUnit::start):
(WebCore::AudioMediaStreamTrackRendererUnit::stop):
(WebCore::AudioMediaStreamTrackRendererUnit::formatDescription):
(WebCore::AudioMediaStreamTrackRendererUnit::createAudioUnit):
(WebCore::AudioMediaStreamTrackRendererUnit::render):
(WebCore::AudioMediaStreamTrackRendererUnit::inputProc):

  • platform/mediastream/mac/AudioMediaStreamTrackRendererUnit.h: Copied from Source/WebCore/platform/mediastream/mac/AudioMediaStreamTrackRendererCocoa.h.

LayoutTests:
Use one audio unit for all MediaStreamTracks of a given process
https://bugs.webkit.org/show_bug.cgi?id=212406

Reviewed by Eric Carlson.

  • webrtc/multi-audio-expected.txt: Added.
  • webrtc/multi-audio.html: Added.
5:58 AM Changeset in webkit [262709] by Diego Pino Garcia
  • 3 edits in trunk/Tools

[webkitpy] Make 'webkit-path rebaseline' to not update expectations file by default
https://bugs.webkit.org/show_bug.cgi?id=212835

Reviewed by Carlos Alberto Lopez Perez.

webkit-patch rebaseline let us add or update a test baseline
from a test bot. By default, the command also updates the
corresponding expectations file. This update is actually a brand-new
generation of an expectations file based on the results of the bot,
which in most cases messes up the current contents of the file.

This patch makes the default to not update the expectations file and
adds a new option '--update-expectations' to explicitly request an
update.

  • Scripts/webkitpy/tool/commands/rebaseline.py:

(AbstractRebaseliningCommand):
(RebaselineTest.init):
(RebaselineTest._rebaseline_tests):
(RebaselineTest.execute):
(AbstractParallelRebaselineCommand._rebaseline_commands):
(RebaselineExpectations.init):
(RebaselineExpectations.execute):
(Rebaseline.init):
(RebaselineTest._rebaseline_test_and_update_expectations): Deleted.

  • Scripts/webkitpy/tool/commands/rebaseline_unittest.py:

(TestRebaselineTest.setUp):

4:49 AM Changeset in webkit [262708] by youenn@apple.com
  • 33 edits
    1 copy
    7 adds in trunk

[Cocoa] Use AVAssetWriterDelegate to implement MediaRecorder
https://bugs.webkit.org/show_bug.cgi?id=206582
Source/WebCore:

<rdar://problem/58985368>

Reviewed by Eric Carlson.

AVAssetWriterDelegate allows to grab recorded data whenever wanted.
This delegate requires passing compressed samples to AVAssetWriter.
Implement video encoding and audio encoding in dedicated classes and use these classes before adding buffers to AVAssetWriter.
These classes are AudioSampleBufferCompressor and VideoSampleBufferCompressor.
They support AAC and H264 so far and should be further improved to support more encoding options.

Instantiate real writer only for platforms supporting AVAssetWriterDelegate, since it is not supported everywhere.
The writer, doing the pacakging, is receiving compressed buffer from the audio/video compressors.
It then sends data when being request to flush to its delegate, which will send data to the MediaRecorderPrivateWriter.
The MediaRecorderPrivateWriter stores the data in a SharedBuffer until MediaRecorder asks for data.

Note that, whenever we request data, we flush the writer and insert an end of video sample to make sure video data gets flushed.
Therefore data should not be requested too fast to get adequate video compression.

Covered by existing tests.

  • Modules/mediarecorder/MediaRecorderProvider.cpp:

(WebCore::MediaRecorderProvider::createMediaRecorderPrivate):

  • WebCore.xcodeproj/project.pbxproj:
  • platform/mediarecorder/MediaRecorderPrivateAVFImpl.cpp:

(WebCore::MediaRecorderPrivateAVFImpl::create):

  • platform/mediarecorder/MediaRecorderPrivateAVFImpl.h:
  • platform/mediarecorder/cocoa/AudioSampleBufferCompressor.h: Added.
  • platform/mediarecorder/cocoa/AudioSampleBufferCompressor.mm: Added.

(WebCore::AudioSampleBufferCompressor::create):
(WebCore::AudioSampleBufferCompressor::AudioSampleBufferCompressor):
(WebCore::AudioSampleBufferCompressor::~AudioSampleBufferCompressor):
(WebCore::AudioSampleBufferCompressor::initialize):
(WebCore::AudioSampleBufferCompressor::finish):
(WebCore::AudioSampleBufferCompressor::initAudioConverterForSourceFormatDescription):
(WebCore::AudioSampleBufferCompressor::computeBufferSizeForAudioFormat):
(WebCore::AudioSampleBufferCompressor::attachPrimingTrimsIfNeeded):
(WebCore::AudioSampleBufferCompressor::gradualDecoderRefreshCount):
(WebCore::AudioSampleBufferCompressor::sampleBufferWithNumPackets):
(WebCore::AudioSampleBufferCompressor::audioConverterComplexInputDataProc):
(WebCore::AudioSampleBufferCompressor::provideSourceDataNumOutputPackets):
(WebCore::AudioSampleBufferCompressor::processSampleBuffersUntilLowWaterTime):
(WebCore::AudioSampleBufferCompressor::processSampleBuffer):
(WebCore::AudioSampleBufferCompressor::addSampleBuffer):
(WebCore::AudioSampleBufferCompressor::getOutputSampleBuffer):
(WebCore::AudioSampleBufferCompressor::takeOutputSampleBuffer):

  • platform/mediarecorder/cocoa/MediaRecorderPrivateWriterCocoa.h:
  • platform/mediarecorder/cocoa/MediaRecorderPrivateWriterCocoa.mm:

(-[WebAVAssetWriterDelegate initWithWriter:]):
(-[WebAVAssetWriterDelegate assetWriter:didProduceFragmentedHeaderData:]):
(-[WebAVAssetWriterDelegate assetWriter:didProduceFragmentedMediaData:fragmentedMediaDataReport:]):
(-[WebAVAssetWriterDelegate close]):
(WebCore::MediaRecorderPrivateWriter::create):
(WebCore::MediaRecorderPrivateWriter::compressedVideoOutputBufferCallback):
(WebCore::MediaRecorderPrivateWriter::compressedAudioOutputBufferCallback):
(WebCore::MediaRecorderPrivateWriter::MediaRecorderPrivateWriter):
(WebCore::MediaRecorderPrivateWriter::~MediaRecorderPrivateWriter):
(WebCore::MediaRecorderPrivateWriter::initialize):
(WebCore::MediaRecorderPrivateWriter::processNewCompressedVideoSampleBuffers):
(WebCore::MediaRecorderPrivateWriter::processNewCompressedAudioSampleBuffers):
(WebCore::MediaRecorderPrivateWriter::startAssetWriter):
(WebCore::MediaRecorderPrivateWriter::appendCompressedAudioSampleBuffer):
(WebCore::MediaRecorderPrivateWriter::appendCompressedVideoSampleBuffer):
(WebCore::MediaRecorderPrivateWriter::appendCompressedSampleBuffers):
(WebCore::appendEndsPreviousSampleDurationMarker):
(WebCore::MediaRecorderPrivateWriter::appendEndOfVideoSampleDurationIfNeeded):
(WebCore::MediaRecorderPrivateWriter::flushCompressedSampleBuffers):
(WebCore::MediaRecorderPrivateWriter::clear):
(WebCore::copySampleBufferWithCurrentTimeStamp):
(WebCore::MediaRecorderPrivateWriter::appendVideoSampleBuffer):
(WebCore::createAudioFormatDescription):
(WebCore::createAudioSampleBuffer):
(WebCore::MediaRecorderPrivateWriter::appendAudioSampleBuffer):
(WebCore::MediaRecorderPrivateWriter::stopRecording):
(WebCore::MediaRecorderPrivateWriter::appendData):

  • platform/mediarecorder/cocoa/VideoSampleBufferCompressor.h: Copied from Source/WebCore/platform/mediarecorder/MediaRecorderPrivateAVFImpl.h.
  • platform/mediarecorder/cocoa/VideoSampleBufferCompressor.mm: Added.

(WebCore::VideoSampleBufferCompressor::create):
(WebCore::VideoSampleBufferCompressor::VideoSampleBufferCompressor):
(WebCore::VideoSampleBufferCompressor::~VideoSampleBufferCompressor):
(WebCore::VideoSampleBufferCompressor::initialize):
(WebCore::VideoSampleBufferCompressor::finish):
(WebCore::VideoSampleBufferCompressor::videoCompressionCallback):
(WebCore::VideoSampleBufferCompressor::initCompressionSession):
(WebCore::VideoSampleBufferCompressor::processSampleBuffer):
(WebCore::VideoSampleBufferCompressor::addSampleBuffer):
(WebCore::VideoSampleBufferCompressor::getOutputSampleBuffer):
(WebCore::VideoSampleBufferCompressor::takeOutputSampleBuffer):

Source/WebCore/PAL:

<rdar://problem/58985368>

Reviewed by Eric Carlson.

Add soft link macros for VideoToolbox and AudioToolbox.

  • PAL.xcodeproj/project.pbxproj:
  • pal/cf/AudioToolboxSoftLink.cpp: Added.
  • pal/cf/AudioToolboxSoftLink.h: Added.
  • pal/cf/CoreMediaSoftLink.cpp:
  • pal/cf/CoreMediaSoftLink.h:
  • pal/cf/VideoToolboxSoftLink.cpp: Added.
  • pal/cf/VideoToolboxSoftLink.h: Added.

Source/WebKit:

<rdar://problem/58985368>

Reviewed by Eric Carlson.

Enable RemoteMediaRecorder only for systems supporting AVAssetWriterDelegate.

  • GPUProcess/GPUConnectionToWebProcess.cpp:

(WebKit::GPUConnectionToWebProcess::didReceiveMessage):

  • GPUProcess/GPUConnectionToWebProcess.h:
  • GPUProcess/webrtc/RemoteMediaRecorder.cpp:
  • GPUProcess/webrtc/RemoteMediaRecorder.h:
  • GPUProcess/webrtc/RemoteMediaRecorder.messages.in:
  • GPUProcess/webrtc/RemoteMediaRecorderManager.cpp:
  • GPUProcess/webrtc/RemoteMediaRecorderManager.h:
  • GPUProcess/webrtc/RemoteMediaRecorderManager.messages.in:
  • GPUProcess/webrtc/RemoteSampleBufferDisplayLayerManager.h:
  • WebProcess/GPU/webrtc/MediaRecorderPrivate.cpp:
  • WebProcess/GPU/webrtc/MediaRecorderPrivate.h:
  • WebProcess/GPU/webrtc/MediaRecorderProvider.cpp:

(WebKit::MediaRecorderProvider::createMediaRecorderPrivate):

Source/WTF:

Reviewed by Eric Carlson.

  • wtf/PlatformHave.h:

LayoutTests:

Reviewed by Eric Carlson.

Disable tests on all platforms except the ones supporting AVAssetWriterDelegate.

  • TestExpectations:
  • http/wpt/mediarecorder/MediaRecorder-AV-audio-video-dataavailable-gpuprocess.html:

Remove web audio generation since there seems to be some unstability in web audio -> stream -> media recorder.
which should be fixed as follow-up specific patches.

  • platform/mac/TestExpectations:

Enable running tests.

4:33 AM Changeset in webkit [262707] by youenn@apple.com
  • 5 edits
    1 add in trunk

File URLs with hostnames are misleading
https://bugs.webkit.org/show_bug.cgi?id=212739
<rdar://problem/63754917>

Reviewed by Alex Christensen.

Source/WebCore:

Showing a file URL like file://example.org/test is misleading to users.
To prevent this, we just do a redirection to the same file URL with an empty host.
Remove the port at the same time.
Covered by added API test.

  • loader/DocumentLoader.cpp:

(WebCore::DocumentLoader::willSendRequest):

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKit/open-window-with-file-url-with-host.html: Added.
  • TestWebKitAPI/Tests/WebKitCocoa/OpenAndCloseWindow.mm:

(TEST):

4:10 AM Changeset in webkit [262706] by Diego Pino Garcia
  • 1 edit
    1 move
    2 deletes in trunk/LayoutTests

[WPE] Gardening, remove redundant baselines
https://bugs.webkit.org/show_bug.cgi?id=212896

Unreviewed gardening.

  • platform/glib/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-playback-temporary-multikey-sequential.https-expected.txt: Renamed from LayoutTests/platform/gtk/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-playback-temporary-multikey-sequential.https-expected.txt.
  • platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-playback-temporary-clear-encrypted.https-expected.txt: Removed.
  • platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-playback-temporary-multikey-sequential.https-expected.txt: Removed.
2:19 AM Changeset in webkit [262705] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

[GTK] Gardening, update test expectations after r262703
https://bugs.webkit.org/show_bug.cgi?id=212895

Unreviewed gardening.

Garden several flaky failures.

  • platform/gtk/TestExpectations:
2:04 AM Changeset in webkit [262704] by commit-queue@webkit.org
  • 5 edits in trunk/Source/WebCore

Simplify fallback content handling in FrameLoader
https://bugs.webkit.org/show_bug.cgi?id=212880

Patch by Rob Buis <rbuis@igalia.com> on 2020-06-08
Reviewed by Youenn Fablet.

Simplify fallback content handling in FrameLoader, this can be inlined
and some HTMLObjectElement checks can be combined.

  • loader/DocumentLoader.cpp:

(WebCore::DocumentLoader::continueAfterContentPolicy):

  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::receivedMainResourceError):
(WebCore::FrameLoader::handleFallbackContent): Deleted.
(WebCore::FrameLoader::isHostedByObjectElement const): Deleted.

  • loader/FrameLoader.h:
  • loader/HistoryController.cpp:

(WebCore::FrameLoader::HistoryController::createItemTree):

Jun 7, 2020:

5:34 PM Changeset in webkit [262703] by Lauro Moura
  • 6 edits in trunk/Source/WebKit

[WebDriver] Allow platform-dependent modifier keys conversion to WebEvent::Modifier
https://bugs.webkit.org/show_bug.cgi?id=212848

Reviewed by Brian Burg.

WebEvent::Modifier flags does not map directly to the platform flags,
so we can't directly convert the modifier flags to the OptionSet.

Covered by existing WebDriver tests.

  • UIProcess/Automation/WebAutomationSession.cpp:

(WebKit::WebAutomationSession::simulateMouseInteraction): Use
platform-specific method to convert the modifiers.

  • UIProcess/Automation/WebAutomationSession.h:
  • UIProcess/Automation/gtk/WebAutomationSessionGtk.cpp: Added

conversion from GDK modifier mask to WebEvent::Modifier.
(WebKit::WebAutomationSession::platformWebModifiersFromRaw):

  • UIProcess/Automation/mac/WebAutomationSessionMac.mm: Added

conversion from NSModifierFlag to WebEvent::Modifier.
(WebKit::WebAutomationSession::platformWebModifiersFromRaw):

  • UIProcess/Automation/wpe/WebAutomationSessionWPE.cpp: Added

conversion from wpe_input_keyboard_modifier to WebEvent::Modifier.
(WebKit::WebAutomationSession::platformWebModifiersFromRaw):

5:16 PM Changeset in webkit [262702] by Lauro Moura
  • 2 edits in trunk/Source/WebKit

[WPE] Behave like GDK_CURRENT_TIME when the timestamp is zero
https://bugs.webkit.org/show_bug.cgi?id=212797

WebDriver tests come with zero timestamp. So behave like
GDK_CURRENT_TIME and assume zero timestamp == WallTime::now().

Reviewed by Carlos Garcia Campos.

Covered by existing tests.

  • Shared/libwpe/WebEventFactory.cpp:

(WebKit::wallTimeForEventTime):

2:07 PM Changeset in webkit [262701] by commit-queue@webkit.org
  • 12 edits in trunk/Source/ThirdParty/ANGLE

[ANGLE - iOS] fast/canvas/webgl/uninitialized-test.html is still failing
https://bugs.webkit.org/show_bug.cgi?id=212249

Patch by James Darpinian <James Darpinian> on 2020-06-07
Reviewed by Dean Jackson.

copyTexImage2D is broken in some way on iOS. Work around it by reimplementing
it with ANGLE's BlitGL class.

  • include/platform/FeaturesGL.h:
  • src/libANGLE/renderer/gl/BlitGL.cpp:

(rx::BlitGL::blitColorBufferWithShader):

  • src/libANGLE/renderer/gl/BlitGL.h:
  • src/libANGLE/renderer/gl/TextureGL.cpp:

(rx::TextureGL::copyImage):
(rx::TextureGL::copySubImage):

  • src/libANGLE/renderer/gl/renderergl_utils.cpp:

(rx::nativegl_gl::InitializeFeatures):

  • src/tests/gl_tests/CopyTexImageTest.cpp:
  • src/tests/gl_tests/TextureTest.cpp:
  • src/tests/test_utils/angle_test_configs.cpp:

(angle::operator<<):

  • src/tests/test_utils/angle_test_configs.h:

(angle::WithEmulateCopyTexImage2DFromRenderbuffers):

  • util/EGLPlatformParameters.h:

(EGLPlatformParameters::tie const):

  • util/EGLWindow.cpp:

(EGLWindow::initializeDisplay):

9:56 AM Changeset in webkit [262700] by aestes@apple.com
  • 4 edits in trunk

[Apple Pay] HAVE(PAYMENT_METHOD_BILLING_ADDRESS) should be true on iOS
https://bugs.webkit.org/show_bug.cgi?id=212877
<rdar://problem/64080998>

Reviewed by Sam Weinig.

Source/WTF:

  • wtf/PlatformHave.h:

LayoutTests:

  • platform/ios-wk2/TestExpectations: Unskipped

http/tests/ssl/applepay/ApplePayBillingAddress.html on iOS.

8:56 AM Changeset in webkit [262699] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[LFC][Height percentage] Skip anonymous wrappers when searching for fixed height
https://bugs.webkit.org/show_bug.cgi?id=212881

Reviewed by Antti Koivisto.

Source/WebCore:

When the block level box is a direct child of an inline level box (<span><div></div></span>) and we wrap it into a continuation,
the containing block (anonymous wrapper) is not the box we need to check for fixed height.

Test: fast/layoutformattingcontext/height-precentage-with-anonymous-wrapper.html

  • layout/FormattingContextGeometry.cpp:

(WebCore::Layout::FormattingContext::Geometry::computedHeightValue const):

LayoutTests:

  • fast/layoutformattingcontext/height-precentage-with-anonymous-wrapper-expected.html: Added.
  • fast/layoutformattingcontext/height-precentage-with-anonymous-wrapper.html: Added.
8:00 AM Changeset in webkit [262698] by Alan Bujtas
  • 4 edits
    2 adds in trunk

[LFC][BFC] Intrinsic width computation should take min/max-width into account.
https://bugs.webkit.org/show_bug.cgi?id=212876

Reviewed by Antti Koivisto.

Source/WebCore:

Test: fast/layoutformattingcontext/min-max-content-width-simple2.html

  • layout/FormattingContextGeometry.cpp:

(WebCore::Layout::FormattingContext::Geometry::computedWidthValue): Address Sam's post-landing comment.

  • layout/blockformatting/BlockFormattingContextGeometry.cpp:

(WebCore::Layout::BlockFormattingContext::Geometry::intrinsicWidthConstraints):

LayoutTests:

  • fast/layoutformattingcontext/min-max-content-width-simple2-expected.html: Added.
  • fast/layoutformattingcontext/min-max-content-width-simple2.html: Added.
7:56 AM Changeset in webkit [262697] by Alan Bujtas
  • 5 edits in trunk/Source/WebCore

[LFC] Pass in the element attributes to Layout::ReplacedBox
https://bugs.webkit.org/show_bug.cgi?id=212879

Reviewed by Antti Koivisto.

The information whether the replace box is an image box is required to see if the box has intrinsic ratio (used for sizing inflow replaced content).

  • layout/layouttree/LayoutReplacedBox.cpp:

(WebCore::Layout::ReplacedBox::ReplacedBox):
(): Deleted.

  • layout/layouttree/LayoutReplacedBox.h:
  • layout/layouttree/LayoutTreeBuilder.cpp:

(WebCore::Layout::TreeBuilder::createReplacedBox):
(WebCore::Layout::TreeBuilder::createLayoutBox):

  • layout/layouttree/LayoutTreeBuilder.h:
7:35 AM Changeset in webkit [262696] by Caio Lima
  • 2 edits in trunk/Tools

Allow run-jsc-stress-tests still run if some of the remote hosts are not available
https://bugs.webkit.org/show_bug.cgi?id=201426

Reviewed by Saam Barati.

This patch allows run-jsc-stress-tests to keep on running if some of
the remote hosts are not available. To do this, we created a new
function checkAndPrepareRemoteHosts that is responsible to check the
connection and read/write permissions of given remote hosts list. It
filters out every unavailable remote host.
These checks and filter happen in the beginning of the script and is
excuted only once, in the beggining of the script. It means that if
some remote device becomes unavailable after the check and preparation
is done, the script execution will be interupted.

  • Scripts/run-jsc-stress-tests:
2:55 AM Changeset in webkit [262695] by Philippe Normand
  • 271 edits in trunk

Remove ENABLE_VIDEO_TRACK ifdef guards
https://bugs.webkit.org/show_bug.cgi?id=212568

Reviewed by Youenn Fablet.

.:

VIDEO_TRACK has been enabled by default on all ports for a long time. As the spec is stable,
the feature can unconditionally be enabled and is now guarded under ENABLE(VIDEO).

  • Source/cmake/OptionsFTW.cmake:
  • Source/cmake/OptionsMac.cmake:
  • Source/cmake/OptionsWin.cmake:
  • Source/cmake/WebKitFeatures.cmake:
  • Source/cmake/tools/vsprops/FeatureDefines.props:
  • Source/cmake/tools/vsprops/FeatureDefinesCairo.props:

Source/JavaScriptCore:

  • Configurations/FeatureDefines.xcconfig: Remove ENABLE_VIDEO_TRACK, which is now enabled by

default under the ENABLE_VIDEO guard.

Source/WebCore:

  • CMakeLists.txt:
  • Configurations/FeatureDefines.xcconfig:
  • Modules/mediacontrols/MediaControlsHost.cpp:
  • Modules/mediasource/AudioTrackMediaSource.h:
  • Modules/mediasource/AudioTrackMediaSource.idl:
  • Modules/mediasource/SourceBuffer.h:
  • Modules/mediasource/SourceBuffer.idl:
  • Modules/mediasource/TextTrackMediaSource.h:
  • Modules/mediasource/TextTrackMediaSource.idl:
  • Modules/mediasource/VideoTrackMediaSource.h:
  • Modules/mediasource/VideoTrackMediaSource.idl:
  • Modules/pictureinpicture/HTMLVideoElementPictureInPicture.cpp:

(WebCore::HTMLVideoElementPictureInPicture::requestPictureInPicture):

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • bindings/js/JSAudioTrackCustom.cpp:
  • bindings/js/JSAudioTrackListCustom.cpp:
  • bindings/js/JSTextTrackCueCustom.cpp:
  • bindings/js/JSTextTrackCustom.cpp:
  • bindings/js/JSTextTrackListCustom.cpp:
  • bindings/js/JSTrackCustom.cpp:
  • bindings/js/JSTrackCustom.h:
  • bindings/js/JSVideoTrackCustom.cpp:
  • bindings/js/JSVideoTrackListCustom.cpp:
  • css/CSSSelector.cpp:

(WebCore::CSSSelector::pseudoId):
(WebCore::CSSSelector::selectorText const):

  • css/CSSSelector.h:
  • css/SelectorChecker.cpp:

(WebCore::SelectorChecker::checkOne const):

  • css/SelectorCheckerTestFunctions.h:

(WebCore::matchesLangPseudoClass):

  • css/SelectorPseudoClassAndCompatibilityElementMap.in:
  • css/SelectorPseudoElementTypeMap.in:
  • css/parser/CSSParserSelector.h:

(WebCore::CSSParserSelector::needsImplicitShadowCombinatorForMatching const):
(WebCore::CSSParserSelector::isPseudoElementCueFunction const):

  • css/parser/CSSSelectorParser.cpp:

(WebCore::CSSSelectorParser::consumePseudo):

  • cssjit/SelectorCompiler.cpp:

(WebCore::SelectorCompiler::addPseudoClassType):

  • dom/Document.cpp:
  • dom/Document.h:
  • dom/EventNames.in:
  • dom/EventTargetFactory.in:
  • dom/Node.h:
  • history/BackForwardCache.cpp:
  • history/BackForwardCache.h:
  • history/CachedPage.cpp:

(WebCore::CachedPage::restore):
(WebCore::CachedPage::clear):

  • history/CachedPage.h:
  • html/HTMLLinkElement.cpp:

(WebCore::HTMLLinkElement::as const):

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::HTMLMediaElement):
(WebCore::HTMLMediaElement::~HTMLMediaElement):
(WebCore::HTMLMediaElement::registerWithDocument):
(WebCore::HTMLMediaElement::unregisterWithDocument):
(WebCore::HTMLMediaElement::finishParsingChildren):
(WebCore::HTMLMediaElement::prepareForLoad):
(WebCore::HTMLMediaElement::selectMediaResource):
(WebCore::HTMLMediaElement::canTransitionFromAutoplayToPlay const):
(WebCore::HTMLMediaElement::setReadyState):
(WebCore::HTMLMediaElement::mediaPlayerKeyNeeded):
(WebCore::HTMLMediaElement::playInternal):
(WebCore::HTMLMediaElement::setVolume):
(WebCore::HTMLMediaElement::playbackProgressTimerFired):
(WebCore::HTMLMediaElement::configureTextTracks):
(WebCore::HTMLMediaElement::mediaPlayerTimeChanged):
(WebCore::HTMLMediaElement::mediaPlayerCharacteristicChanged):
(WebCore::HTMLMediaElement::userCancelledLoad):
(WebCore::HTMLMediaElement::clearMediaPlayer):
(WebCore::HTMLMediaElement::syncTextTrackBounds):
(WebCore::HTMLMediaElement::setVideoFullscreenStandby):
(WebCore::HTMLMediaElement::setVideoFullscreenLayer):
(WebCore::HTMLMediaElement::hasClosedCaptions const):
(WebCore::HTMLMediaElement::setClosedCaptionsVisible):
(WebCore::HTMLMediaElement::createMediaPlayer):
(WebCore::HTMLMediaElement::bufferingPolicy const):

  • html/HTMLMediaElement.h:
  • html/HTMLMediaElement.idl:
  • html/HTMLTagNames.in:
  • html/HTMLTrackElement.cpp:
  • html/HTMLTrackElement.h:
  • html/HTMLTrackElement.idl:
  • html/canvas/WebGLRenderingContextBase.cpp:

(WebCore::WebGLRenderingContextBase::texImageSourceHelper):
(WebCore::WebGLRenderingContextBase::validateTexFuncParameters):

  • html/shadow/MediaControlTextTrackContainerElement.cpp:
  • html/shadow/MediaControlTextTrackContainerElement.h:
  • html/track/AudioTrack.cpp:
  • html/track/AudioTrack.h:
  • html/track/AudioTrack.idl:
  • html/track/AudioTrackList.cpp:
  • html/track/AudioTrackList.h:
  • html/track/AudioTrackList.idl:
  • html/track/DataCue.cpp:
  • html/track/DataCue.h:
  • html/track/DataCue.idl:
  • html/track/InbandDataTextTrack.cpp:
  • html/track/InbandDataTextTrack.h:
  • html/track/InbandGenericTextTrack.cpp:
  • html/track/InbandGenericTextTrack.h:
  • html/track/InbandTextTrack.cpp:
  • html/track/InbandTextTrack.h:
  • html/track/InbandWebVTTTextTrack.cpp:
  • html/track/InbandWebVTTTextTrack.h:
  • html/track/LoadableTextTrack.cpp:
  • html/track/LoadableTextTrack.h:
  • html/track/TextTrack.cpp:
  • html/track/TextTrack.h:
  • html/track/TextTrack.idl:
  • html/track/TextTrackCue.cpp:
  • html/track/TextTrackCue.h:
  • html/track/TextTrackCue.idl:
  • html/track/TextTrackCueGeneric.cpp:
  • html/track/TextTrackCueGeneric.h:
  • html/track/TextTrackCueGeneric.idl:
  • html/track/TextTrackCueList.cpp:
  • html/track/TextTrackCueList.h:
  • html/track/TextTrackCueList.idl:
  • html/track/TextTrackList.cpp:
  • html/track/TextTrackList.h:
  • html/track/TextTrackList.idl:
  • html/track/TrackBase.cpp:
  • html/track/TrackBase.h:
  • html/track/TrackEvent.cpp:
  • html/track/TrackEvent.h:
  • html/track/TrackEvent.idl:
  • html/track/TrackListBase.cpp:
  • html/track/TrackListBase.h:
  • html/track/VTTCue.cpp:
  • html/track/VTTCue.h:
  • html/track/VTTCue.idl:
  • html/track/VTTRegion.cpp:
  • html/track/VTTRegion.h:
  • html/track/VTTRegion.idl:
  • html/track/VTTRegionList.cpp:
  • html/track/VTTRegionList.h:
  • html/track/VTTRegionList.idl:
  • html/track/VideoTrack.cpp:
  • html/track/VideoTrack.h:
  • html/track/VideoTrack.idl:
  • html/track/VideoTrackList.cpp:
  • html/track/VideoTrackList.h:
  • html/track/VideoTrackList.idl:
  • html/track/WebVTTElement.cpp:
  • html/track/WebVTTElement.h:
  • html/track/WebVTTParser.cpp:
  • html/track/WebVTTParser.h:
  • html/track/WebVTTToken.h:
  • html/track/WebVTTTokenizer.cpp:
  • html/track/WebVTTTokenizer.h:
  • loader/LinkLoader.cpp:

(WebCore::LinkLoader::resourceTypeFromAsAttribute):
(WebCore::createLinkPreloadResourceClient):
(WebCore::LinkLoader::isSupportedType):

  • loader/ResourceLoadInfo.cpp:

(WebCore::ContentExtensions::toResourceType):

  • loader/SubresourceLoader.cpp:

(WebCore::logResourceLoaded):

  • loader/TextTrackLoader.cpp:
  • loader/TextTrackLoader.h:
  • loader/cache/CachedResource.cpp:

(WebCore::CachedResource::defaultPriorityForResourceType):

  • loader/cache/CachedResource.h:
  • loader/cache/CachedResourceLoader.cpp:

(WebCore::createResource):
(WebCore::contentTypeFromResourceType):
(WebCore::CachedResourceLoader::checkInsecureContent const):
(WebCore::CachedResourceLoader::allowedByContentSecurityPolicy const):
(WebCore::destinationForType):

  • loader/cache/CachedResourceLoader.h:
  • loader/cache/CachedTextTrack.cpp:
  • loader/cache/CachedTextTrack.h:
  • page/CaptionUserPreferences.cpp:
  • page/CaptionUserPreferences.h:
  • page/CaptionUserPreferencesMediaAF.cpp:
  • page/CaptionUserPreferencesMediaAF.h:
  • page/Page.cpp:

(WebCore::Page::setPageScaleFactor):
(WebCore::Page::setUserInterfaceLayoutDirection):
(WebCore::Page::doAfterUpdateRendering):
(WebCore::Page::forEachMediaElement):

  • page/Page.h:
  • page/PageGroup.cpp:
  • page/PageGroup.h:
  • page/Settings.yaml:
  • platform/LocalizedStrings.cpp:
  • platform/LocalizedStrings.h:
  • platform/MIMETypeRegistry.cpp:

(WebCore::MIMETypeRegistry::isSupportedImageVideoOrSVGMIMEType):

  • platform/SerializedPlatformDataCue.cpp:
  • platform/graphics/AudioTrackPrivate.h:
  • platform/graphics/ImageDecoder.cpp:

(WebCore::ImageDecoder::create):
(WebCore::ImageDecoder::supportsMediaType):

  • platform/graphics/InbandGenericCue.cpp:
  • platform/graphics/InbandGenericCue.h:
  • platform/graphics/InbandTextTrackPrivate.h:
  • platform/graphics/InbandTextTrackPrivateClient.h:
  • platform/graphics/MediaPlayer.cpp:

(WebCore::buildMediaEnginesVector):

  • platform/graphics/MediaPlayer.h:

(WebCore::MediaPlayerClient::textTrackRepresentationBoundsChanged):

  • platform/graphics/MediaPlayerPrivate.h:

(WebCore::MediaPlayerPrivateInterface::tracksChanged):

  • platform/graphics/TextTrackRepresentation.cpp:
  • platform/graphics/TextTrackRepresentation.h:
  • platform/graphics/TrackPrivateBase.cpp:
  • platform/graphics/TrackPrivateBase.h:
  • platform/graphics/VideoTrackPrivate.h:
  • platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.h:
  • platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.mm:
  • platform/graphics/avfoundation/AudioTrackPrivateAVF.h:
  • platform/graphics/avfoundation/MediaSelectionGroupAVFObjC.h:
  • platform/graphics/avfoundation/MediaSelectionGroupAVFObjC.mm:
  • platform/graphics/avfoundation/VideoTrackPrivateAVF.h:
  • platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.h:
  • platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.mm:
  • platform/graphics/avfoundation/objc/AudioTrackPrivateMediaSourceAVFObjC.cpp:
  • platform/graphics/avfoundation/objc/AudioTrackPrivateMediaSourceAVFObjC.h:
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
  • platform/graphics/avfoundation/objc/VideoTrackPrivateAVFObjC.cpp:
  • platform/graphics/avfoundation/objc/VideoTrackPrivateAVFObjC.h:
  • platform/graphics/avfoundation/objc/VideoTrackPrivateMediaSourceAVFObjC.h:
  • platform/graphics/avfoundation/objc/VideoTrackPrivateMediaSourceAVFObjC.mm:
  • platform/graphics/cocoa/TextTrackRepresentationCocoa.h:
  • platform/graphics/cocoa/TextTrackRepresentationCocoa.mm:
  • platform/graphics/gstreamer/AudioTrackPrivateGStreamer.cpp:
  • platform/graphics/gstreamer/AudioTrackPrivateGStreamer.h:
  • platform/graphics/gstreamer/GStreamerCommon.cpp:

(WebCore::initializeGStreamer):

  • platform/graphics/gstreamer/ImageDecoderGStreamer.cpp:
  • platform/graphics/gstreamer/ImageDecoderGStreamer.h:
  • platform/graphics/gstreamer/InbandMetadataTextTrackPrivateGStreamer.h:
  • platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
  • platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.h:
  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:

(WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):
(WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideo):
(WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfAudio):
(WebCore::MediaPlayerPrivateGStreamer::newTextSample):
(WebCore::MediaPlayerPrivateGStreamer::updateTracks):
(WebCore::MediaPlayerPrivateGStreamer::handleMessage):
(WebCore::MediaPlayerPrivateGStreamer::purgeInvalidTextTracks):
(WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin):

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
  • platform/graphics/gstreamer/TextCombinerGStreamer.cpp:
  • platform/graphics/gstreamer/TextCombinerGStreamer.h:
  • platform/graphics/gstreamer/TextSinkGStreamer.cpp:
  • platform/graphics/gstreamer/TextSinkGStreamer.h:
  • platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
  • platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h:
  • platform/graphics/gstreamer/VideoTrackPrivateGStreamer.cpp:
  • platform/graphics/gstreamer/VideoTrackPrivateGStreamer.h:
  • platform/mac/SerializedPlatformDataCueMac.h:
  • platform/mac/SerializedPlatformDataCueMac.mm:
  • platform/mediastream/AudioMediaStreamTrackRenderer.cpp:
  • platform/mediastream/AudioMediaStreamTrackRenderer.h:
  • platform/mediastream/AudioTrackPrivateMediaStream.cpp:
  • platform/mediastream/AudioTrackPrivateMediaStream.h:
  • platform/mediastream/VideoTrackPrivateMediaStream.h:
  • platform/mediastream/mac/AudioMediaStreamTrackRendererCocoa.cpp:
  • platform/mediastream/mac/AudioMediaStreamTrackRendererCocoa.h:
  • rendering/RenderVTTCue.cpp:
  • rendering/RenderVTTCue.h:
  • style/ElementRuleCollector.cpp:

(WebCore::Style::ElementRuleCollector::collectMatchingShadowPseudoElementRules):

  • style/PropertyCascade.cpp:

(WebCore::Style::PropertyCascade::addMatch):

  • style/RuleData.cpp:

(WebCore::Style::determinePropertyWhitelistType):

  • style/RuleData.h:
  • style/RuleSet.cpp:

(WebCore::Style::RuleSet::addRule):
(WebCore::Style::RuleSet::traverseRuleDatas):
(WebCore::Style::RuleSet::hasShadowPseudoElementRules const):
(WebCore::Style::RuleSet::shrinkToFit):

  • style/RuleSet.h:
  • style/StyleAdjuster.cpp:

(WebCore::Style::Adjuster::adjustForSiteSpecificQuirks const):

  • testing/InternalSettings.cpp:

(WebCore::InternalSettings::Backup::Backup):
(WebCore::InternalSettings::Backup::restoreTo):
(WebCore::InternalSettings::setShouldDisplayTrackKind):
(WebCore::InternalSettings::shouldDisplayTrackKind):

  • testing/InternalSettings.h:
  • testing/InternalSettings.idl:
  • testing/Internals.cpp:

(WebCore::Internals::resetToConsistentState):
(WebCore::Internals::Internals):
(WebCore::Internals::userPreferredAudioCharacteristics const):
(WebCore::Internals::setUserPreferredAudioCharacteristic):
(WebCore::Internals::captionsStyleSheetOverride):
(WebCore::Internals::setCaptionsStyleSheetOverride):
(WebCore::Internals::setPrimaryAudioTrackLanguageOverride):
(WebCore::Internals::setCaptionDisplayMode):
(WebCore::Internals::textTrackBCP47Language):
(WebCore::Internals::getCurrentMediaControlsStatusForElement):

  • testing/Internals.h:
  • testing/Internals.idl:

Source/WebCore/PAL:

  • Configurations/FeatureDefines.xcconfig:

Source/WebKit:

  • Configurations/FeatureDefines.xcconfig:
  • GPUProcess/GPUConnectionToWebProcess.cpp:

(WebKit::GPUConnectionToWebProcess::dispatchMessage):

  • GPUProcess/GPUConnectionToWebProcess.h:
  • GPUProcess/media/RemoteMediaPlayerProxy.cpp:

(WebKit::RemoteMediaPlayerProxy::textTrackSetMode):
(WebKit::RemoteMediaPlayerProxy::notifyTrackModeChanged):

  • GPUProcess/media/RemoteMediaPlayerProxy.h:
  • GPUProcess/webrtc/RemoteAudioMediaStreamTrackRenderer.cpp:
  • GPUProcess/webrtc/RemoteAudioMediaStreamTrackRenderer.h:
  • GPUProcess/webrtc/RemoteAudioMediaStreamTrackRenderer.messages.in:
  • GPUProcess/webrtc/RemoteAudioMediaStreamTrackRendererManager.cpp:
  • GPUProcess/webrtc/RemoteAudioMediaStreamTrackRendererManager.h:
  • GPUProcess/webrtc/RemoteAudioMediaStreamTrackRendererManager.messages.in:
  • GPUProcess/webrtc/RemoteSampleBufferDisplayLayer.cpp:
  • GPUProcess/webrtc/RemoteSampleBufferDisplayLayer.h:
  • GPUProcess/webrtc/RemoteSampleBufferDisplayLayer.messages.in:
  • GPUProcess/webrtc/RemoteSampleBufferDisplayLayerManager.cpp:
  • GPUProcess/webrtc/RemoteSampleBufferDisplayLayerManager.h:
  • GPUProcess/webrtc/RemoteSampleBufferDisplayLayerManager.messages.in:
  • Shared/WebPreferences.yaml:
  • WebProcess/GPU/GPUProcessConnection.cpp:

(WebKit::GPUProcessConnection::dispatchMessage):

  • WebProcess/GPU/GPUProcessConnection.h:
  • WebProcess/GPU/media/MediaPlayerPrivateRemote.cpp:

(WebKit::MediaPlayerPrivateRemote::tracksChanged):

  • WebProcess/GPU/media/MediaPlayerPrivateRemote.h:
  • WebProcess/GPU/media/RemoteMediaPlayerManager.cpp:

(WebKit::RemoteMediaPlayerManager::updatePreferences):

  • WebProcess/GPU/webrtc/AudioMediaStreamTrackRenderer.cpp:
  • WebProcess/GPU/webrtc/AudioMediaStreamTrackRenderer.h:
  • WebProcess/GPU/webrtc/SampleBufferDisplayLayer.cpp:
  • WebProcess/GPU/webrtc/SampleBufferDisplayLayer.h:
  • WebProcess/GPU/webrtc/SampleBufferDisplayLayer.messages.in:
  • WebProcess/GPU/webrtc/SampleBufferDisplayLayerManager.cpp:
  • WebProcess/GPU/webrtc/SampleBufferDisplayLayerManager.h:
  • WebProcess/InjectedBundle/InjectedBundle.cpp:

(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::maximumBufferingTime):

Source/WebKitLegacy/mac:

  • Configurations/FeatureDefines.xcconfig:
  • WebView/WebPreferences.mm:

(+[WebPreferences initialize]):

  • WebView/WebView.mm:

(-[WebView _preferencesChanged:]):

Source/WebKitLegacy/win:

  • WebPreferences.cpp:

(WebPreferences::shouldDisplaySubtitles):
(WebPreferences::setShouldDisplaySubtitles):
(WebPreferences::shouldDisplayCaptions):
(WebPreferences::setShouldDisplayCaptions):
(WebPreferences::shouldDisplayTextDescriptions):
(WebPreferences::setShouldDisplayTextDescriptions):

  • WebView.cpp:

(WebView::notifyPreferencesChanged):

Source/WTF:

  • wtf/PlatformEnable.h: Remove ENABLE_VIDEO_TRACK, which is now enabled by

default under the ENABLE_VIDEO guard.

  • wtf/PlatformEnableCocoa.h: Ditto.

Tools:

  • Scripts/webkitperl/FeatureList.pm:
  • TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
12:35 AM Changeset in webkit [262694] by ysuzuki@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

[JSC] Checksum for generated files should be emitted at the end of the files
https://bugs.webkit.org/show_bug.cgi?id=212875

Reviewed by Mark Lam.

If the offlineasm file generation is interrupted in the middle of the generation, it already emitted checksum.
So next file generation can accept this broken file as a result of offlineasm and skip file generation.
We should emit checksum at the end of files. For now, this patch takes a quick way: just iterating lines, getting
a last line and use it for checksum comparison.

  • generator/GeneratedFile.rb:
  • offlineasm/asm.rb:

Jun 6, 2020:

7:54 PM Changeset in webkit [262693] by ysuzuki@apple.com
  • 5 edits
    2 adds in trunk

Crash when running web-apis data collection
https://bugs.webkit.org/show_bug.cgi?id=212458

Reviewed by Mark Lam.

Source/WebCore:

Test: js/dom/dom-attribute-getter-setter.html

For properties using DOMAttribute property attribute in the table, code generator must use DOMAttributeGetterSetter instead of CustomGetterSetter.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateImplementation):

  • bindings/scripts/test/JS/JSTestObj.cpp:

(WebCore::JSTestObjPrototype::finishCreation):

LayoutTests:

  • js/dom/dom-attribute-getter-setter-expected.txt: Added.
  • js/dom/dom-attribute-getter-setter.html: Added.
7:52 PM Changeset in webkit [262692] by aestes@apple.com
  • 2 edits in branches/safari-609-branch/LayoutTests

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
5:15 PM Changeset in webkit [262691] by aestes@apple.com
  • 2 edits in branches/safari-609-branch/Source/WebCore

Unreviewed build fix for platforms where APPLE_PAY_INSTALLMENTS is disabled.

  • testing/MockPaymentCoordinator.idl: Moved installmentConfiguration to a partial interface.
11:02 AM Changeset in webkit [262690] by Alan Bujtas
  • 8 edits
    2 adds in trunk

[LFC] Add support for width: min/max-content
https://bugs.webkit.org/show_bug.cgi?id=212869

Reviewed by Antti Koivisto.

Source/WebCore:

Use the existing intrinsic width logic to compute min/max-content width.

Test: fast/layoutformattingcontext/min-max-content-width-simple.html

  • layout/FormattingContext.h:
  • layout/FormattingContextGeometry.cpp:

(WebCore::Layout::FormattingContext::Geometry::computedWidthValue):
(WebCore::Layout::FormattingContext::Geometry::computedWidth):
(WebCore::Layout::FormattingContext::Geometry::fixedValue const):
(WebCore::Layout::FormattingContext::Geometry::computedMinWidth):
(WebCore::Layout::FormattingContext::Geometry::computedMaxWidth):
(WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedHorizontalGeometry):
(WebCore::Layout::FormattingContext::Geometry::floatingReplacedWidthAndMargin):
(WebCore::Layout::FormattingContext::Geometry::inlineReplacedWidthAndMargin):
(WebCore::Layout::FormattingContext::Geometry::computedWidth const): Deleted.
(WebCore::Layout::FormattingContext::Geometry::computedMinWidth const): Deleted.
(WebCore::Layout::FormattingContext::Geometry::computedMaxWidth const): Deleted.
(WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedHorizontalGeometry const): Deleted.
(WebCore::Layout::FormattingContext::Geometry::floatingReplacedWidthAndMargin const): Deleted.
(WebCore::Layout::FormattingContext::Geometry::inlineReplacedWidthAndMargin const): Deleted.

  • layout/blockformatting/BlockFormattingContext.h:
  • layout/blockformatting/BlockFormattingContextGeometry.cpp:

(WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedWidthAndMargin):
(WebCore::Layout::BlockFormattingContext::Geometry::inFlowReplacedWidthAndMargin):
(WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedWidthAndMargin const): Deleted.
(WebCore::Layout::BlockFormattingContext::Geometry::inFlowReplacedWidthAndMargin const): Deleted.

  • layout/tableformatting/TableFormattingContext.h:
  • layout/tableformatting/TableFormattingContextGeometry.cpp:

(WebCore::Layout::TableFormattingContext::Geometry::computedColumnWidth):
(WebCore::Layout::TableFormattingContext::Geometry::computedColumnWidth const): Deleted.

LayoutTests:

  • fast/layoutformattingcontext/min-max-content-width-simple-expected.html: Added.
  • fast/layoutformattingcontext/min-max-content-width-simple.html: Added.
10:49 AM Changeset in webkit [262689] by cturner@igalia.com
  • 29 edits
    2 moves
    15 adds
    6 deletes in trunk/LayoutTests

[GTK][WPE][EME] Update WPT and rebaseline
https://bugs.webkit.org/show_bug.cgi?id=212574

Reviewed by Xabier Rodriguez-Calvar.

LayoutTests/imported/w3c:

Updated the encrypted-media directory like so,

Tools/Scripts/import-w3c-tests -s ~/igalia/sources/wpt/ -d imported/w3c/web-platform-tests/ encrypted-media

  • resources/import-expectations.json:
  • web-platform-tests/encrypted-media/META.yml: Added.
  • web-platform-tests/encrypted-media/OWNERS: Removed.
  • web-platform-tests/encrypted-media/clearkey-check-encryption-scheme.https-expected.txt: Added.
  • web-platform-tests/encrypted-media/clearkey-check-encryption-scheme.https.html: Added.
  • web-platform-tests/encrypted-media/clearkey-check-status-for-hdcp.https.html: Added.
  • web-platform-tests/encrypted-media/clearkey-generate-request-disallowed-input.https-expected.txt:
  • web-platform-tests/encrypted-media/clearkey-mp4-playback-temporary-clear-encrypted-segmented.https.html: Added.
  • web-platform-tests/encrypted-media/clearkey-mp4-playback-temporary-events.https-expected.txt: Renamed from LayoutTests/platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-playback-temporary-events.https-expected.txt.
  • web-platform-tests/encrypted-media/clearkey-mp4-reset-src-after-setmediakeys.https-expected.txt: Renamed from LayoutTests/platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-reset-src-after-setmediakeys.https-expected.txt.
  • web-platform-tests/encrypted-media/clearkey-mp4-waiting-for-a-key.https-expected.txt: Added.
  • web-platform-tests/encrypted-media/content/w3c-import.log:
  • web-platform-tests/encrypted-media/drm-check-encryption-scheme.https.html: Added.
  • web-platform-tests/encrypted-media/drm-check-status-for-hdcp.https.html: Added.
  • web-platform-tests/encrypted-media/encrypted-media-supported-by-feature-policy.tentative.html: Added.
  • web-platform-tests/encrypted-media/idlharness.https.html:
  • web-platform-tests/encrypted-media/polyfill/w3c-import.log:
  • web-platform-tests/encrypted-media/resources/w3c-import.log:
  • web-platform-tests/encrypted-media/scripts/check-encryption-scheme.js: Added.

(checkEncryptionScheme):
(runTest):

  • web-platform-tests/encrypted-media/scripts/check-status-for-hdcp.js: Added.

(checkStatusForMinHdcpVersionPolicy):
(runTest):

  • web-platform-tests/encrypted-media/scripts/clearkey-update-non-ascii-input.js:

(runTest):

  • web-platform-tests/encrypted-media/scripts/generate-request-disallowed-input.js:

(runTest):

  • web-platform-tests/encrypted-media/scripts/invalid-license.js:

(runTest.):
(runTest):

  • web-platform-tests/encrypted-media/scripts/playback-temporary-encrypted-clear-segmented-sources.js: Added.

(runTest):

  • web-platform-tests/encrypted-media/scripts/playback-temporary-expired.js:

(runTest):

  • web-platform-tests/encrypted-media/scripts/requestmediakeysystemaccess.js:

(expect_error):

  • web-platform-tests/encrypted-media/scripts/setmediakeys.js:

(runTest):

  • web-platform-tests/encrypted-media/scripts/syntax-mediakeysession.js:

(runTest.func):

  • web-platform-tests/encrypted-media/scripts/temporary-license-type.js:

(runTest):

  • web-platform-tests/encrypted-media/scripts/update-disallowed-input.js:

(runTest.):
(runTest):

  • web-platform-tests/encrypted-media/scripts/w3c-import.log:
  • web-platform-tests/encrypted-media/scripts/waiting-for-a-key.js:
  • web-platform-tests/encrypted-media/util/utils.js:
  • web-platform-tests/encrypted-media/util/w3c-import.log:
  • web-platform-tests/encrypted-media/w3c-import.log:

LayoutTests:

Update the WPT tests and adjust GTK and WPE test expectations. I
have noticed some crashes locally on occasion, but they are rare
here and I have not at the opportunity to dissect one of them to
figure it out.

  • platform/glib/TestExpectations:
  • platform/glib/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-update-disallowed-input.https-expected.txt:
  • platform/gtk/TestExpectations:
  • platform/gtk/imported/w3c/web-platform-tests/encrypted-media/clearkey-check-status-for-hdcp.https-expected.txt: Added.
  • platform/gtk/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-playback-temporary-events.https-expected.txt: Removed.
  • platform/gtk/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-requestmediakeysystemaccess.https-expected.txt:
  • platform/gtk/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-reset-src-after-setmediakeys.https-expected.txt: Removed.
  • platform/gtk/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-waiting-for-a-key.https-expected.txt: Removed.
  • platform/wpe/TestExpectations:
  • platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-check-status-for-hdcp.https-expected.txt: Added.
  • platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-requestmediakeysystemaccess.https-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-update-disallowed-input.https-expected.txt: Added.
  • platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-waiting-for-a-key.https-expected.txt: Removed.
  • platform/wpe/imported/w3c/web-platform-tests/encrypted-media/encrypted-media-default-feature-policy.https.sub-expected.txt: Removed.
  • tests-options.json:
10:39 AM Changeset in webkit [262688] by Devin Rousso
  • 5 edits in trunk

[ macOS wk2 ] inspector/page/setBootstrapScript-sub-frame.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=207053
<rdar://problem/59064908>

Reviewed by Timothy Hatcher.

Source/WebCore:

Test: inspector/page/setBootstrapScript-sub-frame.html

  • inspector/InspectorInstrumentation.cpp:

(WebCore::InspectorInstrumentation::didCommitLoadImpl):
Ensure the InspectorPageAgent sends the new Page.Frame payload to the frontend before
the PageRuntimeAgent so that a WI.Frame exists before adding any WI.ExecutionContext.

LayoutTests:

  • inspector/page/setBootstrapScript-sub-frame.html:
  • platform/mac/TestExpectations:
10:37 AM Changeset in webkit [262687] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebCore

REGRESSION (r262364): Disney Plus crashes playing videos
https://bugs.webkit.org/show_bug.cgi?id=212862
<rdar://problem/64044841>

Reviewed by Eric Carlson.

In r262364, we specified an incorrect number size for CFNumberGetValue, which nevertheless
worked fine in debug builds, but overwrote stack data in release builds, leading to a crash when
the returned pointer was ref()d. The correct size for a FourCharCode is a
kCFNumberSInt32Type, not a kCFNumberLongType.

  • platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
10:35 AM Changeset in webkit [262686] by Simon Fraser
  • 4 edits in trunk/LayoutTests

fast/scrolling/latching/iframe-latch-small-deltas.html is flakey
https://bugs.webkit.org/show_bug.cgi?id=210348
<rdar://problem/61594742>

Reviewed by Anders Carlsson.

This test needs to use ' eventSender.monitorWheelEvents({ resetLatching: false });' so that it
waits for the events from the last non-momentum scroll without resetting latching.

  • fast/scrolling/latching/iframe-latch-small-deltas-expected.txt:
  • fast/scrolling/latching/iframe-latch-small-deltas.html:
  • platform/mac-wk2/TestExpectations:
10:31 AM Changeset in webkit [262685] by Simon Fraser
  • 7 edits in trunk

Clear WebPageProxy event state between tests
https://bugs.webkit.org/show_bug.cgi?id=212864

Reviewed by Anders Carlsson.

Make sure that event state doesn't leak between tests via events queued in WebPageProxy.

Source/WebKit:

  • UIProcess/API/C/WKPage.cpp:

(WKPageClearEventState):

  • UIProcess/API/C/WKPage.h:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::resetStateAfterProcessExited):
(WebKit::WebPageProxy::clearEventState):

  • UIProcess/WebPageProxy.h:

Tools:

  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetStateToConsistentValues):

9:36 AM Changeset in webkit [262684] by ddkilzer@apple.com
  • 6 edits in trunk/Source/WebCore

[IPC] Adopt enum class for GradientSpreadMethod
<https://webkit.org/b/212868>
<rdar://problem/64069035>

Reviewed by Anders Carlsson.

Summary:

  • Convert GradientSpreadMethod to an enum class.
  • Add WTF::EnumTraits<AutocapitalizeType> for IPC.
  • Remove use of decodeEnum() and encodeEnum().
  • platform/graphics/Gradient.h:

(WebCore::Gradient::encode const):
(WebCore::Gradient::decode):

  • platform/graphics/GraphicsTypes.h:
  • platform/graphics/cairo/GradientCairo.cpp:

(WebCore::Gradient::createPlatformGradient):

  • platform/graphics/cg/GradientCG.cpp:

(WebCore::Gradient::paint):

  • rendering/svg/RenderSVGResourceGradient.cpp:

(WebCore::RenderSVGResourceGradient::applyResource):

9:20 AM Changeset in webkit [262683] by commit-queue@webkit.org
  • 47 edits in trunk/Source

Source/WebCore:
Reduce includes for CustomHeaderFields
https://bugs.webkit.org/show_bug.cgi?id=212691

Patch by Rob Buis <rbuis@igalia.com> on 2020-06-06
Reviewed by Joseph Pecoraro.

Reduce includes for CustomHeaderFields, I guess these were needed
at some point but not anymore.

  • Modules/applepay/ApplePaySession.cpp:
  • Modules/applepay/PaymentSession.cpp:
  • bindings/js/ScriptController.cpp:
  • contentextensions/ContentExtensionsBackend.cpp:
  • dom/Document.cpp:
  • editing/cocoa/EditorCocoa.mm:
  • editing/cocoa/HTMLConverter.mm:
  • editing/cocoa/WebContentReaderCocoa.mm:
  • editing/markup.cpp:
  • history/CachedFrame.cpp:
  • html/HTMLDocument.cpp:
  • html/HTMLHtmlElement.cpp:
  • html/HTMLMediaElement.cpp:
  • html/ImageDocument.cpp:
  • html/MediaDocument.cpp:
  • html/PluginDocument.cpp:
  • html/parser/HTMLDocumentParser.cpp:
  • html/parser/XSSAuditor.cpp:
  • inspector/InspectorInstrumentation.cpp:
  • inspector/agents/InspectorApplicationCacheAgent.cpp:
  • inspector/agents/InspectorNetworkAgent.cpp:
  • inspector/agents/InspectorPageAgent.cpp:
  • inspector/agents/page/PageNetworkAgent.cpp:
  • loader/ApplicationManifestLoader.cpp:
  • loader/FrameLoader.cpp:
  • loader/LoadTiming.cpp:
  • loader/NetscapePlugInStreamLoader.cpp:
  • loader/ResourceLoader.cpp:
  • loader/SubresourceLoader.cpp:
  • loader/appcache/ApplicationCacheHost.cpp:
  • loader/archive/cf/LegacyWebArchive.cpp:
  • loader/icon/IconLoader.cpp:
  • page/ContextMenuController.cpp:
  • page/FrameView.cpp:
  • page/Page.cpp:
  • page/Performance.cpp:
  • page/PerformanceNavigation.cpp:
  • page/Quirks.cpp:
  • page/UserContentProvider.cpp:
  • page/csp/ContentSecurityPolicy.cpp:
  • page/mac/PageMac.mm:
  • platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
  • svg/graphics/SVGImage.cpp:
  • testing/Internals.cpp:

Source/WebKit:
Move URL scheme check to NetworkLoadChecker
https://bugs.webkit.org/show_bug.cgi?id=191924

Patch by Rob Buis <rbuis@igalia.com> on 2020-06-06
Reviewed by Joseph Pecoraro.

Reduce includes for CustomHeaderFields, I guess these were needed
at some point but not anymore.

  • Shared/WebsitePoliciesData.cpp:
9:13 AM Changeset in webkit [262682] by aestes@apple.com
  • 25 edits
    6 copies
    2 adds in trunk

[Apple Pay] Add testing and logging for ApplePaySetup
https://bugs.webkit.org/show_bug.cgi?id=211972
<rdar://problem/63291965>

Reviewed by Alex Christensen.

Source/WebCore:

Test: http/tests/ssl/applepay/ApplePaySetup.https.html

  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • Modules/applepay/ApplePaySetup.cpp:

(WebCore::ApplePaySetup::getSetupFeatures):
(WebCore::ApplePaySetup::begin):
(WebCore::ApplePaySetup::ApplePaySetup):
(WebCore::ApplePaySetup::stop):

  • Modules/applepay/ApplePaySetup.idl:
  • Modules/applepay/ApplePaySetupConfiguration.h: Copied from Source/WebCore/Modules/applepay/ApplePaySetupFeatureType.idl.
  • Modules/applepay/ApplePaySetupConfiguration.idl: Copied from Source/WebCore/Modules/applepay/ApplePaySetupFeatureType.idl.
  • Modules/applepay/ApplePaySetupFeature.idl:
  • Modules/applepay/ApplePaySetupFeature.mm:

(WebCore::ApplePaySetupFeature::state const):

  • Modules/applepay/ApplePaySetupFeatureState.h: Copied from Source/WebCore/Modules/applepay/ApplePaySetupFeatureType.idl.
  • Modules/applepay/ApplePaySetupFeatureState.idl: Copied from Source/WebCore/Modules/applepay/ApplePaySetupFeatureType.idl.
  • Modules/applepay/ApplePaySetupFeatureType.idl:
  • Modules/applepay/ApplePaySetupFeatureWebCore.h:
  • Modules/applepay/ApplePaySetupWebCore.h:

(WebCore::ApplePaySetup::create):

  • Modules/applepay/PaymentCoordinator.cpp:

(WebCore::PaymentCoordinator::setApplePayIsActiveIfAllowed const):
(WebCore::PaymentCoordinator::getSetupFeatures):
(WebCore::PaymentCoordinator::beginApplePaySetup):
(WebCore::PaymentCoordinator::endApplePaySetup):

  • Modules/applepay/PaymentCoordinator.h:
  • Modules/applepay/PaymentCoordinatorClient.h:

(WebCore::PaymentCoordinatorClient::getSetupFeatures):
(WebCore::PaymentCoordinatorClient::beginApplePaySetup):

  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • testing/MockApplePaySetupFeature.cpp: Copied from Source/WebCore/Modules/applepay/ApplePaySetupFeatureWebCore.h.

(WebCore::MockApplePaySetupFeature::create):
(WebCore::MockApplePaySetupFeature::MockApplePaySetupFeature):

  • testing/MockApplePaySetupFeature.h: Copied from Source/WebCore/Modules/applepay/ApplePaySetupFeatureWebCore.h.
  • testing/MockPaymentCoordinator.cpp:

(WebCore::MockPaymentCoordinator::addSetupFeature):
(WebCore::MockPaymentCoordinator::getSetupFeatures):
(WebCore::MockPaymentCoordinator::beginApplePaySetup):

  • testing/MockPaymentCoordinator.h:
  • testing/MockPaymentCoordinator.idl:

LayoutTests:

  • http/tests/ssl/applepay/ApplePaySetup.https-expected.txt: Added.
  • http/tests/ssl/applepay/ApplePaySetup.https.html: Added.
  • platform/mac-wk2/TestExpectations:
9:12 AM Changeset in webkit [262681] by ddkilzer@apple.com
  • 4 edits in trunk/Source

Follow-up: Use OptionSet<DragOperation> for mask values
<https://webkit.org/b/212605>
<rdar://problem/64069091>

Source/WebCore:

  • dom/DataTransfer.cpp:

(WebCore::DataTransfer::destinationOperationMask const):

  • Don't compare to anyDragOperation(). Darin suggested this change during patch review, but this use was missed.

Source/WebKitLegacy/win:

  • WebCoreSupport/WebDragClient.cpp:

(draggingSourceOperationMaskToDragCursors):

  • Don't compare to anyDragOperation(). It's redundant since the code following it will do the same thing.
8:17 AM Changeset in webkit [262680] by ddkilzer@apple.com
  • 54 edits in trunk/Source

Use OptionSet<DragOperation> for mask values
<https://webkit.org/b/212605>

Reviewed by Darin Adler.

Source/WebCore:

In broad strokes:

  • Replace use of DragOperation with OptionSet<DragOperation> or Optional<DragOperation>.
  • Rename function parameters and local variables to denote use of mask values.
  • Remove DragOperationNone enum value.
  • Replace DragOperationEvery enum value with anyDragOperation().
  • dom/DataTransfer.cpp:

(WebCore::DataTransfer::createForDrop):
(WebCore::DataTransfer::createForUpdatingDropTarget):
(WebCore::dragOpFromIEOp):
(WebCore::IEOpFromDragOp):
(WebCore::DataTransfer::sourceOperation const): Rename.
(WebCore::DataTransfer::sourceOperationMask const):
(WebCore::DataTransfer::destinationOperation const): Rename.
(WebCore::DataTransfer::destinationOperationMask const):
(WebCore::DataTransfer::setSourceOperation): Rename.
(WebCore::DataTransfer::setSourceOperationMask):
(WebCore::DataTransfer::setDestinationOperation): Rename.
(WebCore::DataTransfer::setDestinationOperationMask):

  • dom/DataTransfer.h:

(WebCore::DataTransfer::createForDrop):
(WebCore::DataTransfer::createForUpdatingDropTarget):
(WebCore::DataTransfer::sourceOperation const): Rename.
(WebCore::DataTransfer::sourceOperationMask const):
(WebCore::DataTransfer::destinationOperation const): Rename.
(WebCore::DataTransfer::destinationOperationMask const):
(WebCore::DataTransfer::setSourceOperation): Rename.
(WebCore::DataTransfer::setSourceOperationMask):
(WebCore::DataTransfer::setDestinationOperation): Rename.
(WebCore::DataTransfer::setDestinationOperationMask):

  • page/DragActions.h:

(WebCore::anyDragOperation): Add.
(WTF::EnumTraits<WebCore::DragOperation>): Add.
(WTF::OptionSet<WebCore::DragOperation>): Add.

  • page/DragController.cpp:

(WebCore::DragController::dragEntered):
(WebCore::DragController::dragUpdated):
(WebCore::DragController::performDragOperation):
(WebCore::DragController::dragEnteredOrUpdated):
(WebCore::DragController::tryDocumentDrag):
(WebCore::DragController::operationForLoad):
(WebCore::defaultOperationForDrag):
(WebCore::DragController::tryDHTMLDrag):

  • Change logic to call defaultOperationForDrag() to convert targetResponse.operationMask to a single operation when targetResponse.operationMask but doesn't contain with any bit values set in sourceOperationMask.

(WebCore::DragController::startDrag):

  • page/DragController.h:

(WebCore::DragController::dragEntered):
(WebCore::DragController::dragUpdated):
(WebCore::DragController::sourceDragOperation const): Rename.
(WebCore::DragController::sourceDragOperationMask const):
(WebCore::DragController::startDrag):
(WebCore::DragController::dragEnteredOrUpdated):
(WebCore::DragController::operationForLoad):
(WebCore::DragController::tryDocumentDrag):
(WebCore::DragController::tryDHTMLDrag):
(WebCore::DragController::dragOperation):

  • page/EventHandler.cpp:

(WebCore::convertDropZoneOperationToDragOperation):
(WebCore::convertDragOperationToDropZoneOperation):
(WebCore::findDropZone):
(WebCore::EventHandler::dispatchDragEnterOrDragOverEvent):
(WebCore::EventHandler::updateDragAndDrop):
(WebCore::EventHandler::cancelDragAndDrop):
(WebCore::EventHandler::performDragAndDrop):
(WebCore::EventHandler::dragSourceEndedAt):
(WebCore::EventHandler::handleDrag):

  • page/EventHandler.h:

(WebCore::EventHandler::updateDragAndDrop):
(WebCore::EventHandler::cancelDragAndDrop):
(WebCore::EventHandler::performDragAndDrop):
(WebCore::EventHandler::dragSourceEndedAt):
(WebCore::EventHandler::dispatchDragEnterOrDragOverEvent):

  • page/gtk/DragControllerGtk.cpp:

(WebCore::DragController::dragOperation):

  • page/mac/DragControllerMac.mm:

(WebCore::DragController::dragOperation):

  • page/win/DragControllerWin.cpp:

(WebCore::DragController::dragOperation):

  • Clean up comment.
  • platform/DragData.cpp:

(WebCore::DragData::DragData):

  • platform/DragData.h:

(WebCore::DragData::DragData):
(WebCore::DragData::draggingSourceOperationMask const):

  • platform/cocoa/DragDataCocoa.mm:

(WebCore::DragData::DragData):

  • platform/gtk/GtkUtilities.cpp:

(WebCore::gdkDragActionToDragOperation):
(WebCore::dragOperationToGdkDragActions):
(WebCore::dragOperationToSingleGdkDragAction):

  • platform/gtk/GtkUtilities.h:

(WebCore::gdkDragActionToDragOperation):
(WebCore::dragOperationToGdkDragActions):
(WebCore::dragOperationToSingleGdkDragAction):

  • platform/win/DragDataWin.cpp:

(WebCore::DragData::DragData):

Source/WebKit:

In broad strokes:

  • Replace use of DragOperation with OptionSet<DragOperation> or Optional<DragOperation>.
  • Rename function parameters and local variables to denote use of mask values.
  • Remove DragOperationNone enum value.
  • Replace DragOperationEvery enum value with anyDragOperation().
  • Platform/spi/ios/UIKitSPI.h:

(UIDragOperation):

  • Remove unused (and misnamed) UIDragOperation enum typedef.
  • Scripts/webkit/messages.py:

(types_that_cannot_be_forward_declared):
(headers_for_type):

  • Add support for WebCore::DragOperation enum.
  • Shared/API/Cocoa/_WKDragActionsInternal.h:

(WebKit::coreDragOperationMask): Add conversion function.

  • Shared/WebCoreArgumentCoders.cpp:

(IPC::ArgumentCoder<DragData>::encode):
(IPC::ArgumentCoder<DragData>::decode):

  • Update to encode/decode OptionSet<DragOperation>.
  • UIProcess/API/gtk/DragSource.h:

(WebKit::DragSource::begin):

  • UIProcess/API/gtk/DragSourceGtk3.cpp:

(WebKit::DragSource::begin):

  • UIProcess/API/gtk/DragSourceGtk4.cpp:

(WebKit::DragSource::begin):

  • UIProcess/API/gtk/DropTarget.h:
  • UIProcess/API/gtk/DropTargetGtk3.cpp:

(WebKit::DropTarget::didPerformAction):
(WebKit::DropTarget::leaveTimerFired):

  • UIProcess/API/gtk/DropTargetGtk4.cpp:

(WebKit::DropTarget::DropTarget):
(WebKit::DropTarget::didPerformAction):

  • UIProcess/API/gtk/PageClientImpl.cpp:

(WebKit::PageClientImpl::startDrag):

  • UIProcess/API/gtk/PageClientImpl.h:

(WebKit::PageClientImpl::startDrag):

  • UIProcess/API/gtk/WebKitWebViewBase.cpp:

(webkitWebViewBaseStartDrag):

  • UIProcess/API/gtk/WebKitWebViewBasePrivate.h:

(webkitWebViewBaseStartDrag):

  • UIProcess/Cocoa/WebViewImpl.mm:

(WebKit::WebViewImpl::sendDragEndToPage):
(WebKit::WebViewImpl::draggingEntered):
(WebKit::kit): Add conversion function.
(WebKit::WebViewImpl::draggingUpdated):
(WebKit::WebViewImpl::draggingExited):
(WebKit::WebViewImpl::performDragOperation):

  • Make use of coreDragOperationMask() conversion function.
  • UIProcess/PageClient.h:

(WebKit::WebViewImpl::startDrag):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::didPerformDragControllerAction):

  • Remove MESSAGE_CHECK now that we're using the actual type.

(WebKit::WebPageProxy::startDrag):
(WebKit::WebPageProxy::dragEnded):
(WebKit::WebPageProxy::resetCurrentDragInformation):

  • UIProcess/WebPageProxy.h:

(WebKit::WebPageProxy::didPerformDragControllerAction):
(WebKit::WebPageProxy::dragEnded):
(WebKit::WebPageProxy::startDrag):
(WebKit::WebPageProxy::currentDragOperation const):

  • UIProcess/WebPageProxy.messages.in:

(WebPageProxy::DidPerformDragControllerAction):
(WebPageProxy::StartDrag):

  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView _didHandleDragStartRequest:]):
(dropOperationForWebCoreDragOperation):
(coreDragOperationForUIDropOperation): Add conversion function.

  • Note that this was not being converted from UIDropOperation to WebCore::DragOperation previously, and UIDropOperationMove (0x3) was not being properly converted to DragOperationMove (0x16).

(-[WKContentView dragDataForDropSession:dragDestinationAction:]):
(-[WKContentView _didPerformDragOperation:]):
(-[WKContentView dragInteraction:willAnimateLiftWithAnimator:session:]):
(-[WKContentView dragInteraction:session:didEndWithOperation:]):
(-[WKContentView dropInteraction:sessionDidEnd:]):

  • WebProcess/WebCoreSupport/gtk/WebDragClientGtk.cpp:

(WebKit::WebDragClient::startDrag):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::performDragControllerAction):
(WebKit::WebPage::dragEnded):

  • WebProcess/WebPage/WebPage.h:

(WebKit::WebPage::performDragControllerAction):
(WebKit::WebPage::dragEnded):

  • WebProcess/WebPage/WebPage.messages.in:

(WebPage::PerformDragControllerAction):
(WebPage::DragEnded):

  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::requestAdditionalItemsForDragSession):

Source/WebKitLegacy/mac:

In broad strokes:

  • Replace use of DragOperation with OptionSet<DragOperation> or Optional<DragOperation>.
  • Rename function parameters and local variables to denote use of mask values.
  • Remove DragOperationNone enum value.
  • Replace DragOperationEvery enum value with anyDragOperation().
  • WebView/WebFrame.mm:

(-[WebFrame _dragSourceEndedAt:operation:]):

  • WebView/WebHTMLView.mm:

(kit): Add conversion function.
(-[WebHTMLView draggingSourceOperationMaskForLocal:]):
(-[WebHTMLView draggingSession:sourceOperationMaskForDraggingContext:]):

  • WebView/WebView.mm:

(coreDragOperationMask): Add conversion function.
(kit): Ditto.

  • Map WebCore::DragOperationGeneric to _UIDragOperationMove based on logic in WebCore. All other WebCore::DragOperation enum values map to _UIDragOperationNone.

(-[WebView dragDataForSession:client:global:operation:]):
(-[WebView _enteredDataInteraction:client:global:operation:]):
(-[WebView _updatedDataInteraction:client:global:operation:]):
(-[WebView draggingEntered:]):
(-[WebView draggingUpdated:]):
(-[WebView draggingExited:]):
(-[WebView performDragOperation:]):

  • WebView/WebViewInternal.h:

(CocoaDragOperation):

  • Add typedef so coreDragOperationMask() may be shared across platforms.

(coreDragOperationMask): Add declaration.
(coreOptions):

  • Remove redundant parameter name.

Source/WebKitLegacy/win:

In broad strokes:

  • Replace use of DragOperation with OptionSet<DragOperation> or Optional<DragOperation>.
  • Rename function parameters and local variables to denote use of mask values.
  • Remove DragOperationNone enum value.
  • Replace DragOperationEvery enum value with anyDragOperation().
  • WebCoreSupport/WebDragClient.cpp:

(draggingSourceOperationMaskToDragCursors):
(WebDragClient::startDrag):

  • WebView.cpp:

(dragOperationToDragCursor):
(WebView::keyStateToDragOperation const):
(WebView::DragLeave):

  • WebView.h:

(WebView::keyStateToDragOperation const):

Source/WTF:

  • wtf/OptionSet.h:

(WTF::OptionSet::OptionSet):

  • Add constructor for OptionSet(Optional).
8:02 AM Changeset in webkit [262679] by Alan Bujtas
  • 4 edits in trunk/Source/WebCore

[LFC] FormattingContext::Geometry::computedValue should not try to resolve values when layout is required
https://bugs.webkit.org/show_bug.cgi?id=212867

Reviewed by Antti Koivisto.

This is in preparation for adding min/max/fit-content support.

  • layout/FormattingContext.h:
  • layout/FormattingContextGeometry.cpp:

(WebCore::Layout::FormattingContext::Geometry::computedWidth const):
(WebCore::Layout::FormattingContext::Geometry::computedValue const):
(WebCore::Layout::FormattingContext::Geometry::computedMinWidth const):
(WebCore::Layout::FormattingContext::Geometry::computedMaxWidth const):
(WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedVerticalGeometry const):
(WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedHorizontalGeometry):
(WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedVerticalGeometry const):
(WebCore::Layout::FormattingContext::Geometry::outOfFlowReplacedHorizontalGeometry const):
(WebCore::Layout::FormattingContext::Geometry::inFlowPositionedPositionOffset const):
(WebCore::Layout::FormattingContext::Geometry::computedHorizontalMargin const):
(WebCore::Layout::FormattingContext::Geometry::computedVerticalMargin const):
(WebCore::Layout::FormattingContext::Geometry::computedValueIfNotAuto const): Deleted.

  • layout/inlineformatting/InlineFormattingContextGeometry.cpp:

(WebCore::Layout::InlineFormattingContext::Geometry::inlineBlockWidthAndMargin):

7:57 AM Changeset in webkit [262678] by Andres Gonzalez
  • 2 edits in trunk/LayoutTests

[Win EWS] REGRESSION (r262500): accessibility/svg-text.html always fails
https://bugs.webkit.org/show_bug.cgi?id=212845

Unreviewed test gardening.

  • platform/win/TestExpectations:
7:11 AM Changeset in webkit [262677] by mark.lam@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Make CodeBlockHash robust against unreasonably long source code.
https://bugs.webkit.org/show_bug.cgi?id=212847
<rdar://problem/64024279>

Reviewed by Saam Barati.

This patch adds a heuristic to avoid trying to compute the CodeBlockHash on
unreasonably long source code strings. This is done by first applying a length
check and, if needed, computing the hash with an alternate method.

This is OK to do because:

  1. CodeBlockHash is not a critical hash.
  2. In practice, reasonable source code are not that long.
  3. And if they are that long, then we are still diversifying the hash on their length. But if they do collide, it's OK.

The only invariant here is that we should always produce the same hash for the
same source string. Since the algorithm is deterministic, this invariant is not
violated.

  • bytecode/CodeBlockHash.cpp:

(JSC::CodeBlockHash::CodeBlockHash):

6:53 AM Changeset in webkit [262676] by Jonathan Bedard
  • 3 edits in trunk/Source/WebKitLegacy/mac

WebKitLegacy: Link to framework stubs for watchOS and tvOS
https://bugs.webkit.org/show_bug.cgi?id=212855
<rdar://problem/64049486>

Reviewed by Tim Horton.

  • Configurations/Base.xcconfig: Define tvOS and watchOS major version macros.
  • Configurations/WebKitLegacy.xcconfig: Link to framework stubs for watchOS and tvOS.
6:02 AM Changeset in webkit [262675] by Devin Rousso
  • 4 edits in trunk/LayoutTests

(r261103) [ Mac WK2 ] inspector/page/overrideSetting-ITPDebugModeEnabled.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=211791
<rdar://problem/63147694>

Reviewed by Timothy Hatcher.

  • inspector/page/overrideSetting-ITPDebugModeEnabled.html:
  • inspector/page/overrideSetting-ITPDebugModeEnabled-expected.txt:

Wait for three console messages instead of one, as we know there should be at least three.

  • platform/mac-wk2/TestExpectations:
5:51 AM Changeset in webkit [262674] by Devin Rousso
  • 4 edits in trunk/LayoutTests

[ macOS ] inspector/debugger/break-in-constructor-before-super.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=210062
<rdar://problem/61351481>

Reviewed by Timothy Hatcher.

  • inspector/debugger/break-in-constructor-before-super.html:
  • inspector/debugger/debugger-statement.html:
  • platform/mac/TestExpectations:
5:47 AM Changeset in webkit [262673] by Devin Rousso
  • 38 edits in trunk/Source

Web Inspector: unify the naming scheme for agents used by instrumentation
https://bugs.webkit.org/show_bug.cgi?id=212859

Reviewed by Timothy Hatcher.

Inspector agents fall into one of three categories:

  • "persistent" when Web Inspector is connected
  • "enabled" when that agent is enabled, such as if the corresponding tab is visible
  • "tracking" when that agent is part of a timeline recording.

The only exception to this is the Console agent, as that exists regardless of whether Web
Inspector is connected as it needs to preserve messages logged before Web Inspector connects.

Also remove the "Inspector" prefix from getter/setter methods as it adds confusion if that
agent also has subclasses (e.g. InspectorRuntimeAgent and PageRuntimeAgent).

Source/JavaScriptCore:

  • inspector/JSGlobalObjectConsoleClient.h:
  • inspector/JSGlobalObjectInspectorController.cpp:
  • inspector/agents/InspectorConsoleAgent.h:

Source/WebCore:

  • inspector/InstrumentingAgents.h:
  • inspector/InstrumentingAgents.cpp:

Use macros to simplify the process of adding an agent.

  • inspector/CommandLineAPIHost.cpp:
  • inspector/InspectorController.h:
  • inspector/InspectorController.cpp:
  • inspector/InspectorInstrumentation.cpp:
  • inspector/agents/InspectorAnimationAgent.cpp:
  • inspector/agents/InspectorApplicationCacheAgent.cpp:
  • inspector/agents/InspectorCPUProfilerAgent.cpp:
  • inspector/agents/InspectorCSSAgent.cpp:
  • inspector/agents/InspectorCanvasAgent.cpp:
  • inspector/agents/InspectorDOMAgent.cpp:
  • inspector/agents/InspectorDOMDebuggerAgent.cpp:
  • inspector/agents/InspectorDOMStorageAgent.cpp:
  • inspector/agents/InspectorDatabaseAgent.cpp:
  • inspector/agents/InspectorLayerTreeAgent.cpp:
  • inspector/agents/InspectorMemoryAgent.cpp:
  • inspector/agents/InspectorNetworkAgent.cpp:
  • inspector/agents/InspectorPageAgent.cpp:
  • inspector/agents/InspectorTimelineAgent.cpp:
  • inspector/agents/InspectorWorkerAgent.cpp:
  • inspector/agents/WebDebuggerAgent.cpp:
  • inspector/agents/WebHeapAgent.cpp:
  • inspector/agents/page/PageConsoleAgent.cpp:
  • inspector/agents/page/PageDOMDebuggerAgent.cpp:
  • inspector/agents/page/PageDebuggerAgent.cpp:
  • inspector/agents/page/PageHeapAgent.cpp:
  • inspector/agents/page/PageNetworkAgent.cpp:
  • inspector/agents/page/PageRuntimeAgent.cpp:

Simple naming changes elided to avoid a long ChangeLog.

Source/WebKit:

  • UIProcess/Inspector/Agents/InspectorBrowserAgent.cpp:
  • UIProcess/Inspector/WebInspectorProxy.cpp:
  • UIProcess/Inspector/WebPageInspectorController.h:

Simple naming changes elided to avoid a long ChangeLog.

12:17 AM Changeset in webkit [262672] by Peng Liu
  • 2 edits in trunk/Tools

REGRESSION (r262456): [iOS Debug] TestWebKitAPI.WKWebViewCloseAllMediaPresentations.PictureInPicture is frequently timing out
https://bugs.webkit.org/show_bug.cgi?id=212777

Unreviewed test gardening.

  • TestWebKitAPI/Tests/WebKitCocoa/WKWebViewCloseAllMediaPresentations.mm:

Disable the PictureInPicture test for old iOS devices.

Note: See TracTimeline for information about the timeline view.