Timeline



Jun 22, 2020:

10:55 PM Changeset in webkit [263388] by Carlos Garcia Campos
  • 5 edits
    2 adds in trunk

REGRESSION(r258741): [GTK] anchor-file-blob-download-includes-backslash.html is failing
https://bugs.webkit.org/show_bug.cgi?id=209329

Reviewed by Adrian Perez de Castro.

Source/WebCore:

Sanitize the suggested filename. We replace characters that can be problematic in filenames with '_' to match
what Chromium and Firefox do.

  • platform/network/soup/ResourceResponseSoup.cpp:

(WebCore::sanitizeFilename):
(WebCore::ResourceResponse::platformSuggestedFilename const):

LayoutTests:

Rebaseline tests.

  • platform/gtk/TestExpectations:
  • platform/gtk/fast/dom/HTMLAnchorElement/anchor-file-blob-download-includes-backslash-expected.txt: Added.
  • platform/gtk/fast/dom/HTMLAnchorElement/anchor-file-blob-download-includes-doublequote-expected.txt: Added.
  • platform/gtk/fast/dom/HTMLAnchorElement/anchor-file-blob-download-includes-slashes-expected.txt:
10:51 PM Changeset in webkit [263387] by Carlos Garcia Campos
  • 2 edits in trunk/Tools

[GTK] MiniBrowser: set a base directory for website data and cache
https://bugs.webkit.org/show_bug.cgi?id=213368

Reviewed by Michael Catanzaro.

Stop using the default ones.

  • MiniBrowser/gtk/main.c:

(activate):

10:49 PM Changeset in webkit [263386] by Carlos Garcia Campos
  • 14 edits in trunk

[GTK][WPE] Add API to configure and handle DOM cache to WebKitWebsiteDataManager
https://bugs.webkit.org/show_bug.cgi?id=213337

Reviewed by Adrian Perez de Castro.

Source/WebKit:

The default path is always used even for apps setting a base data directory. We should handle
WebsiteDataType::DOMCache to configure the directory and allow to fetch and clear it.

  • UIProcess/API/glib/WebKitWebsiteData.cpp:

(recordContainsSupportedDataTypes):
(toWebKitWebsiteDataTypes):

  • UIProcess/API/glib/WebKitWebsiteDataManager.cpp:

(webkitWebsiteDataManagerGetProperty):
(webkitWebsiteDataManagerSetProperty):
(webkitWebsiteDataManagerConstructed):
(webkit_website_data_manager_class_init):
(webkitWebsiteDataManagerGetDataStore):
(webkit_website_data_manager_get_dom_cache_directory):
(toWebsiteDataTypes):

  • UIProcess/API/gtk/WebKitWebsiteData.h:
  • UIProcess/API/gtk/WebKitWebsiteDataManager.h:
  • UIProcess/API/gtk/docs/webkit2gtk-4.0-sections.txt:
  • UIProcess/API/wpe/WebKitWebsiteData.h:
  • UIProcess/API/wpe/WebKitWebsiteDataManager.h:
  • UIProcess/API/wpe/docs/wpe-1.0-sections.txt:
  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::websiteDataStoreFromSessionID): GTK and WPE ports don't use the default website
data store, so only use it when it already exists. Use the process pool website data store instead.

Tools:

Handle new website data in MiniBrowser and add a unit test.

  • MiniBrowser/gtk/main.c:

(gotWebsiteDataCallback):

  • TestWebKitAPI/Tests/WebKitGLib/TestWebsiteData.cpp:

(testWebsiteDataConfiguration):
(testWebsiteDataDOMCache):
(beforeAll):

  • TestWebKitAPI/glib/WebKitGLib/TestMain.h:

(Test::Test):

10:27 PM Changeset in webkit [263385] by sbarati@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Attempt to fix watchOS simulator build.

  • assembler/FastJITPermissions.h:

(threadSelfRestrictRWXToRW):
(threadSelfRestrictRWXToRX):

10:04 PM Changeset in webkit [263384] by Diego Pino Garcia
  • 5 edits in trunk/Tools

[ews] Add JSC-Only builders for MIPS and ARMv7 architectures
https://bugs.webkit.org/show_bug.cgi?id=213366

Reviewed by Aakash Jain.

In a follow-up patch the built product of these bots will be consumed
by the EWS JSC-Only testing bots.

  • BuildSlaveSupport/ews-build/config.json:
  • BuildSlaveSupport/ews-build/factories.py:

(JSCBuildFactory):
(JSCBuildFactory.init):

  • BuildSlaveSupport/ews-build/factories_unittest.py:

(TestBuildFactory):
(TestBuildFactory.test_jsc_mipsel_factory):
(TestBuildFactory.test_jsc_armv7_factory):

  • BuildSlaveSupport/ews-build/loadConfig.py:
9:13 PM Changeset in webkit [263383] by wilander@apple.com
  • 22 edits in trunk/Source

Storage Access API: Add the capability to call the Storage Access API as a quirk, on behalf of websites that should be doing it themselves
https://bugs.webkit.org/show_bug.cgi?id=213418
<rdar://problem/64549429>

Reviewed by Alex Christensen.

Source/WebCore:

No new tests. This patch adds quirks for specific websites.
The general functionality that's touched has tests under
LayoutTests/http/tests/storageAccess/.

  • dom/Document.h:

(WebCore::Document::isTopDocument const):

New convenience function.

(WebCore::Document::setUserDidInteractWithPage):

Use of the new convenience function.

(WebCore::Document::userDidInteractWithPage const):

Use of the new convenience function.

  • dom/DocumentStorageAccess.cpp:

(WebCore::DocumentStorageAccess::hasStorageAccessQuickCheck):
(WebCore::DocumentStorageAccess::hasStorageAccess):
(WebCore::DocumentStorageAccess::hasStorageAccessForDocumentQuirk):
(WebCore::DocumentStorageAccess::requestStorageAccess):
(WebCore::DocumentStorageAccess::requestStorageAccessQuickCheck):
(WebCore::DocumentStorageAccess::requestStorageAccessForDocumentQuirk):
(WebCore::DocumentStorageAccess::requestStorageAccessForNonDocumentQuirk):
(WebCore::DocumentStorageAccess::requestStorageAccessQuirk):

These functions are split up to allow quirks to call directly into the
implementation of the Storage Access API without the JavaScript
promise that goes with the web API. It also allows for quirks to call
the API without an iframe document.

  • dom/DocumentStorageAccess.h:
  • dom/Element.cpp:

(WebCore::Element::dispatchMouseEvent):

The two existing quirks are for click events.

  • loader/ResourceLoadObserver.h:

(WebCore::ResourceLoadObserver::setDomainsWithUserInteraction):
(WebCore::ResourceLoadObserver::hasHadUserInteraction const):

These two new functions allow the Storage Access API quirks
to synchronously check if it's worth calling the API or not.
If there has been no user interaction for the requesting
domain, there is no need to call the API.

  • page/Quirks.cpp:

(WebCore::Quirks::triggerOptionalStorageAccessQuirk const):

This is the new quirks function, hiding the specifics of
certain elements clicked and for which websites. It also
calls the Storage Access API.

  • page/Quirks.h:

Source/WebKit:

These changes are for forwarding ITP's knowledge of user interaction
for specific quirks domains to the WebKit::WebProcessPool where it in
turn can be distributed to all existing and new Web Content processes.

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::needsUserInteractionQuirk const):
(WebKit::WebResourceLoadStatisticsStore::callUpdatePrevalentDomainsToBlockCookiesForHandler):

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h:
  • Shared/WebProcessDataStoreParameters.h:

(WebKit::WebProcessDataStoreParameters::encode const):
(WebKit::WebProcessDataStoreParameters::decode):

  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::setDomainsWithUserInteraction):

  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/Network/NetworkProcessProxy.messages.in:
  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::webProcessDataStoreParameters):
(WebKit::WebProcessPool::setDomainsWithUserInteraction):

  • UIProcess/WebProcessPool.h:
  • WebProcess/WebCoreSupport/WebResourceLoadObserver.cpp:

(WebKit::WebResourceLoadObserver::hasHadUserInteraction const):

  • WebProcess/WebCoreSupport/WebResourceLoadObserver.h:
  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::setWebsiteDataStoreParameters):
(WebKit::WebProcess::setDomainsWithUserInteraction):

  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:
9:00 PM Changeset in webkit [263382] by Lauro Moura
  • 2 edits in trunk/WebDriverTests

[WebDriver][GTK] Mark two scrolling tests as fail

Unreviewed test gardening.

They are failing because element.location expects Get_Element_Rect to
return page coordinates instead of the browsing context coordinates.
There an open issue at https://github.com/w3c/webdriver/issues/1533
to clarify the correct behavior. Meanwhile, we should mark them as
failure.

The change that introduced this new behavior was r262997, and its bug
is used as the reference bug for these expectations.

8:25 PM Changeset in webkit [263381] by Chris Dumez
  • 26 edits
    3 copies in trunk

Introduce BaseAudioContext interface
https://bugs.webkit.org/show_bug.cgi?id=213491

Reviewed by Geoffrey Garen.

LayoutTests/imported/w3c:

Rebaseline WPT test now that more checks are passing.

  • web-platform-tests/webaudio/idlharness.https.window-expected.txt:

Source/WebCore:

Introduce BaseAudioContext interface as per W3C WebAudio specification:

No new tests, rebaselined existing test.

  • CMakeLists.txt:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • Modules/webaudio/AudioContext.cpp:

(WebCore::AudioContext::AudioContext):
(WebCore::AudioContext::close):
(WebCore::AudioContext::createMediaElementSource):
(WebCore::AudioContext::createMediaStreamSource):
(WebCore::AudioContext::createMediaStreamDestination):

  • Modules/webaudio/AudioContext.h:
  • Modules/webaudio/AudioContext.idl:
  • Modules/webaudio/AudioNode.cpp:

(WebCore::AudioNode::contextForBindings const):

  • Modules/webaudio/AudioNode.h:
  • Modules/webaudio/AudioNode.idl:
  • Modules/webaudio/BaseAudioContext.cpp: Copied from Source/WebCore/Modules/webaudio/AudioContext.cpp.

(WebCore::BaseAudioContext::isSampleRateRangeGood):
(WebCore::AudioContextBase::AudioContextBase):
(WebCore::BaseAudioContext::BaseAudioContext):
(WebCore::BaseAudioContext::constructCommon):
(WebCore::BaseAudioContext::~BaseAudioContext):
(WebCore::BaseAudioContext::lazyInitialize):
(WebCore::BaseAudioContext::clear):
(WebCore::BaseAudioContext::uninitialize):
(WebCore::BaseAudioContext::isInitialized const):
(WebCore::BaseAudioContext::addReaction):
(WebCore::BaseAudioContext::setState):
(WebCore::BaseAudioContext::stop):
(WebCore::BaseAudioContext::suspend):
(WebCore::BaseAudioContext::resume):
(WebCore::BaseAudioContext::activeDOMObjectName const):
(WebCore::AudioContextBase::document const):
(WebCore::BaseAudioContext::hostingDocumentIdentifier const):
(WebCore::BaseAudioContext::isSuspended const):
(WebCore::BaseAudioContext::visibilityStateChanged):
(WebCore::BaseAudioContext::wouldTaintOrigin const):
(WebCore::BaseAudioContext::createBuffer):
(WebCore::BaseAudioContext::decodeAudioData):
(WebCore::BaseAudioContext::createBufferSource):
(WebCore::BaseAudioContext::createScriptProcessor):
(WebCore::BaseAudioContext::createBiquadFilter):
(WebCore::BaseAudioContext::createWaveShaper):
(WebCore::BaseAudioContext::createPanner):
(WebCore::BaseAudioContext::createConvolver):
(WebCore::BaseAudioContext::createDynamicsCompressor):
(WebCore::BaseAudioContext::createAnalyser):
(WebCore::BaseAudioContext::createGain):
(WebCore::BaseAudioContext::createDelay):
(WebCore::BaseAudioContext::createChannelSplitter):
(WebCore::BaseAudioContext::createChannelMerger):
(WebCore::BaseAudioContext::createOscillator):
(WebCore::BaseAudioContext::createPeriodicWave):
(WebCore::BaseAudioContext::notifyNodeFinishedProcessing):
(WebCore::BaseAudioContext::derefFinishedSourceNodes):
(WebCore::BaseAudioContext::refNode):
(WebCore::BaseAudioContext::derefNode):
(WebCore::BaseAudioContext::derefUnfinishedSourceNodes):
(WebCore::BaseAudioContext::lock):
(WebCore::BaseAudioContext::tryLock):
(WebCore::BaseAudioContext::unlock):
(WebCore::BaseAudioContext::isAudioThread const):
(WebCore::BaseAudioContext::isGraphOwner const):
(WebCore::BaseAudioContext::addDeferredFinishDeref):
(WebCore::BaseAudioContext::handlePreRenderTasks):
(WebCore::BaseAudioContext::handlePostRenderTasks):
(WebCore::BaseAudioContext::handleDeferredFinishDerefs):
(WebCore::BaseAudioContext::markForDeletion):
(WebCore::BaseAudioContext::scheduleNodeDeletion):
(WebCore::BaseAudioContext::deleteMarkedNodes):
(WebCore::BaseAudioContext::markSummingJunctionDirty):
(WebCore::BaseAudioContext::removeMarkedSummingJunction):
(WebCore::BaseAudioContext::eventTargetInterface const):
(WebCore::BaseAudioContext::markAudioNodeOutputDirty):
(WebCore::BaseAudioContext::handleDirtyAudioSummingJunctions):
(WebCore::BaseAudioContext::handleDirtyAudioNodeOutputs):
(WebCore::BaseAudioContext::addAutomaticPullNode):
(WebCore::BaseAudioContext::removeAutomaticPullNode):
(WebCore::BaseAudioContext::updateAutomaticPullNodes):
(WebCore::BaseAudioContext::processAutomaticPullNodes):
(WebCore::AudioContextBase::scriptExecutionContext const):
(WebCore::BaseAudioContext::nodeWillBeginPlayback):
(WebCore::shouldDocumentAllowWebAudioToAutoPlay):
(WebCore::BaseAudioContext::willBeginPlayback):
(WebCore::BaseAudioContext::willPausePlayback):
(WebCore::BaseAudioContext::startRendering):
(WebCore::BaseAudioContext::mediaCanStart):
(WebCore::BaseAudioContext::mediaState const):
(WebCore::BaseAudioContext::pageMutedStateDidChange):
(WebCore::BaseAudioContext::isPlayingAudioDidChange):
(WebCore::BaseAudioContext::finishedRendering):
(WebCore::BaseAudioContext::dispatchEvent):
(WebCore::BaseAudioContext::incrementActiveSourceCount):
(WebCore::BaseAudioContext::decrementActiveSourceCount):
(WebCore::BaseAudioContext::suspendRendering):
(WebCore::BaseAudioContext::resumeRendering):
(WebCore::BaseAudioContext::suspendPlayback):
(WebCore::BaseAudioContext::mayResumePlayback):
(WebCore::BaseAudioContext::postTask):
(WebCore::BaseAudioContext::origin const):
(WebCore::BaseAudioContext::addConsoleMessage):
(WebCore::BaseAudioContext::clearPendingActivity):
(WebCore::BaseAudioContext::makePendingActivity):
(WebCore::BaseAudioContext::logChannel const):

  • Modules/webaudio/BaseAudioContext.h: Copied from Source/WebCore/Modules/webaudio/AudioContext.h.

(WebCore::AudioContextBase::AutoLocker::AutoLocker):
(WebCore::AudioContextBase::AutoLocker::~AutoLocker):
(WebCore::BaseAudioContext::destination):
(WebCore::BaseAudioContext::activeSourceCount const):
(WebCore::BaseAudioContext::listener):
(WebCore::BaseAudioContext::state const):
(WebCore::BaseAudioContext::isClosed const):
(WebCore::BaseAudioContext::connectionCount const):
(WebCore::BaseAudioContext::audioThread const):
(WebCore::BaseAudioContext::maxNumberOfChannels):
(WebCore::BaseAudioContext::destinationNode const):
(WebCore::BaseAudioContext::userGestureRequiredForAudioStart const):
(WebCore::BaseAudioContext::pageConsentRequiredForAudioStart const):
(isType):

  • Modules/webaudio/BaseAudioContext.idl: Copied from Source/WebCore/Modules/webaudio/AudioContext.idl.
  • Modules/webaudio/OfflineAudioContext.cpp:

(WebCore::OfflineAudioContext::OfflineAudioContext):

  • Modules/webaudio/OfflineAudioContext.h:
  • Modules/webaudio/OfflineAudioContext.idl:
  • Modules/webaudio/PannerNode.cpp:

(WebCore::PannerNode::PannerNode):

  • Modules/webaudio/PannerNode.h:
  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • bindings/js/WebCoreBuiltinNames.h:
  • dom/EventTargetFactory.in:
  • testing/Internals.cpp:

(WebCore::Internals::setAudioContextRestrictions):

  • testing/Internals.h:
  • testing/Internals.idl:
6:28 PM Changeset in webkit [263380] by sbarati@apple.com
  • 21 edits
    1 add in trunk

Allow building JavaScriptCore Mac+arm64 in public SDK build
https://bugs.webkit.org/show_bug.cgi?id=213472

Reviewed by Sam Weinig.

.:

  • Source/cmake/OptionsFTW.cmake:
  • Source/cmake/WebKitFeatures.cmake:

Source/JavaScriptCore:

We used to only builld code for fast permission switching when using the
Apple internal SDK. However, with arm64 on macOS, this is no longer a viable
implementation strategy.

This patch makes it so we can build JSC on macOS+arm64 using the public Xcode
SDK.

  • ENABLE_FAST_JIT_PERMISSIONS is removed. We now use runtime checks instead.
  • In the new suite of OS betas, pthreads has added API for fast permissions switching. We now use this API instead of using the non-public SDK found in the kernel headers.
  • We fall back to the separated W/X heaps when fast permissions checking is not supported. This all happens at runtime.
  • CMakeLists.txt:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • assembler/ARM64Assembler.h:

(JSC::ARM64Assembler::fillNops):

  • assembler/ARMv7Assembler.h:

(JSC::ARMv7Assembler::fillNops):

  • assembler/FastJITPermissions.h: Added.

(useFastJITPermissions):
(threadSelfRestrictRWXToRW):
(threadSelfRestrictRWXToRX):
(fastJITPermissionsIsSupported):

  • assembler/LinkBuffer.cpp:

(JSC::memcpyWrapper):
(JSC::LinkBuffer::copyCompactAndLinkCode):

  • assembler/MIPSAssembler.h:

(JSC::MIPSAssembler::fillNops):

  • assembler/MacroAssemblerARM64.h:

(JSC::MacroAssemblerARM64::link):

  • assembler/MacroAssemblerARMv7.h:

(JSC::MacroAssemblerARMv7::link):

  • jit/ExecutableAllocator.cpp:

(JSC::initializeJITPageReservation):

  • jit/ExecutableAllocator.h:

(JSC::performJITMemcpy):
(JSC::useFastJITPermissions): Deleted.

  • runtime/JSCConfig.h:
  • runtime/Options.cpp:

(JSC::Options::recomputeDependentOptions):

  • runtime/OptionsList.h:

Source/WTF:

  • wtf/PlatformEnable.h:
  • wtf/PlatformEnableCocoa.h:
  • wtf/PlatformHave.h:
6:23 PM Changeset in webkit [263379] by Fujii Hironori
  • 3 edits
    2 deletes in trunk

[Win] fast/dom/Window/alert-with-unmatched-utf16-surrogate-should-not-crash.html is failing
https://bugs.webkit.org/show_bug.cgi?id=213452

Reviewed by Yusuke Suzuki.

Tools:

If window.alert() was given an invalid UTF-16 sequence, Windows
DumpRenderTree output it without any conversions. It should output
"(null)" to match with WebKitTestRunner behavior.

  • DumpRenderTree/win/UIDelegate.cpp:

(toMessage): Added
(UIDelegate::runJavaScriptAlertPanelWithMessage):
(UIDelegate::runJavaScriptConfirmPanelWithMessage):
(UIDelegate::runJavaScriptTextInputPanelWithPrompt):
(UIDelegate::runBeforeUnloadConfirmPanelWithMessage):
(UIDelegate::setStatusText):

LayoutTests:

  • platform/win/fast/dom/Window/alert-with-unmatched-utf16-surrogate-should-not-crash-expected.txt: Removed.
  • platform/wincairo/fast/dom/Window/alert-with-unmatched-utf16-surrogate-should-not-crash-expected.txt: Removed.
4:54 PM Changeset in webkit [263378] by Andres Gonzalez
  • 4 edits in trunk/Source/WebCore

AXIsolatedTree::generateSubtree should properly assign the generated subtree to its parent node.
https://bugs.webkit.org/show_bug.cgi?id=213435

Reviewed by Darin Adler.

AXIsolatedTree::generateSubtree now properly updates the children IDs
of the parent node of the subtree being generated.

  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::generateIsolatedTree):

  • accessibility/isolatedtree/AXIsolatedTree.cpp:

(WebCore::AXIsolatedTree::updateChildrenIDs):
(WebCore::AXIsolatedTree::generateSubtree): Takes the parent object
instead of the parent ID. This allows to retrieve the children IDs of
the parent object.
(WebCore::AXIsolatedTree::createSubtree):
(WebCore::AXIsolatedTree::updateSubtree):
(WebCore::AXIsolatedTree::updateChildren):
(WebCore::AXIsolatedTree::setRootNode):
(WebCore::AXIsolatedTree::removeSubtree):
(WebCore::AXIsolatedTree::appendNodeChanges): R-value parameter instead
of by reference.

  • accessibility/isolatedtree/AXIsolatedTree.h:
4:44 PM Changeset in webkit [263377] by Devin Rousso
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: adjust height of undocked title area to match macOS Big Sur
https://bugs.webkit.org/show_bug.cgi?id=213490

Reviewed by Timothy Hatcher.

  • UserInterface/Views/Variables.css:

(body.mac-platform:not(.big-sur):not(.docked)): Added.
(body.mac-platform.big-sur:not(.docked)): Added.
(body.mac-platform:not(.docked)): Deleted.

  • UserInterface/Base/Platform.js:

Add logic for detecting macOS Big Sur (and Catalina).

4:43 PM Changeset in webkit [263376] by Devin Rousso
  • 4 edits in trunk/Source/WebInspectorUI

Web Inspector: Elements: Node: use a WI.ContextMenu instead of a <select> for listener filtering
https://bugs.webkit.org/show_bug.cgi?id=213492

Reviewed by Timothy Hatcher.

  • UserInterface/Views/DOMNodeDetailsSidebarPanel.js:

(WI.DOMNodeDetailsSidebarPanel.prototype.initialLayout):
(WI.DOMNodeDetailsSidebarPanel.prototype._populateEventListenersFilterContextMenu): Added.

  • UserInterface/Views/DOMNodeDetailsSidebarPanel.css:

(.sidebar > .panel.dom-node-details .details-section.dom-node-event-listeners > .header > .filter > select): Deleted.

  • Localizations/en.lproj/localizedStrings.js:
4:42 PM Changeset in webkit [263375] by timothy_horton@apple.com
  • 4 edits in trunk/Source/ThirdParty/libwebrtc

libwebrtc fails to build on arm64
https://bugs.webkit.org/show_bug.cgi?id=213476

Reviewed by Maciej Stachowiak.

  • Configurations/libvpx.xcconfig:
  • Configurations/libwebrtc.xcconfig:
  • Configurations/opus.xcconfig:

Use architecture conditionals instead of SDK conditionals for code that is
architecture-dependent.

Remove an macOS-version-dependent definition of EXCLUDED_SOURCE_FILE_NAMES
which is no longer used after r232665.

4:01 PM Changeset in webkit [263374] by Wenson Hsieh
  • 2 edits in trunk/Source/WebKit

[macOS] WebPageProxy::setPromisedDataForImage should sanitize its filename
https://bugs.webkit.org/show_bug.cgi?id=213486
<rdar://problem/56522262>

Reviewed by Megan Gardner.

Ensure that the filename passed into WebPageProxy::setPromisedDataForImage is sanitized in the UI process prior
to being used as a suggested filename when writing a dragged image to the pasteboard.

  • UIProcess/mac/WebPageProxyMac.mm:

(WebKit::WebPageProxy::setPromisedDataForImage):

3:25 PM Changeset in webkit [263373] by timothy_horton@apple.com
  • 3 edits in trunk/Source/WebKit

WebEx can not share video from Safari on arm64
https://bugs.webkit.org/show_bug.cgi?id=213481

Reviewed by Dean Jackson.

  • UIProcess/UserMediaProcessManager.cpp:

(WebKit::needsAppleCameraService):
(WebKit::UserMediaProcessManager::willCreateMediaStream):
(WebKit::UserMediaProcessManager::revokeSandboxExtensionsIfNeeded):
Pass sandbox extension for "com.apple.applecamerad" to the Web Content
process after the user allows camera access, when running on hardware which requires it.

  • WebProcess/com.apple.WebProcess.sb.in:

Make it possible to dynamically extend the sandbox as above.

3:17 PM Changeset in webkit [263372] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKit

Cannot play back encrypted media on arm64
https://bugs.webkit.org/show_bug.cgi?id=213483

Reviewed by Jer Noble and Per Arne Vollan.

  • WebProcess/com.apple.WebProcess.sb.in:

Extend the sandbox as necessary for encrypted media support.

3:17 PM Changeset in webkit [263371] by sbarati@apple.com
  • 2 edits in trunk/Source/bmalloc

Only use vm_kernel_page_size on arm architectures
https://bugs.webkit.org/show_bug.cgi?id=213474

Reviewed by Sam Weinig.

We don't want to use this under catalyst.

  • bmalloc/VMAllocate.h:

(bmalloc::vmPageSizePhysical):

3:17 PM Changeset in webkit [263370] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WTF

Fix the build

  • wtf/TranslatedProcess.h:

(WTF::isX86BinaryRunningOnARM):

2:57 PM Changeset in webkit [263369] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

[WPE][GTK] Public API should not allow trying to register a special URI scheme
https://bugs.webkit.org/show_bug.cgi?id=209900
<rdar://problem/61200217>

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-06-22
Reviewed by Adrian Perez de Castro

Epiphany prior to 3.36 registers a scheme handler for ftp. This introduced criticals. Let's
use g_warning() instead, and avoid hardcoding the list of disallowed schemes.

  • UIProcess/API/glib/WebKitWebContext.cpp:

(webkit_web_context_register_uri_scheme):

2:55 PM Changeset in webkit [263368] by jer.noble@apple.com
  • 2 edits in trunk/Tools

[ macOS iOS ] (r263321): TestWebKitAPI.SleepDisabler.Load & TestWebKitAPI.SleepDisabler.Reload are constant failures
https://bugs.webkit.org/show_bug.cgi?id=213475
<rdar://problem/64603555>

Reviewed by Eric Carlson.

Looks like the SleepDisabler can come and go while the TestWebKitAPI process is spinning, so make the
Reload and Load tests more deterministic by only checking SleepDisabler after getting a "playing" message
from the WebContent process.

  • TestWebKitAPI/Tests/WebKit/SleepDisabler.mm:

(SleepDisabler::runAndWaitUntilPlaying):
(SleepDisabler::loadPlayingPage):
(TEST_F):

2:53 PM Changeset in webkit [263367] by Jonathan Bedard
  • 2 edits in trunk/Tools

resultsdbpy: Make architecture differences explicit
https://bugs.webkit.org/show_bug.cgi?id=213473
<rdar://problem/64602736>

Rubber-stamped by Aakash Jain.

  • resultsdbpy/resultsdbpy/view/static/js/configuration.js:

(Configuration.prototype.toString):

2:24 PM Changeset in webkit [263366] by timothy_horton@apple.com
  • 3 edits in trunk/Source/WebKit

dlopen() always fails on arm64, cannot load soft-linked libraries
https://bugs.webkit.org/show_bug.cgi?id=213480

Reviewed by Alexey Proskuryakov and Per Arne Vollan.

  • Shared/mac/AuxiliaryProcessMac.mm:

(WebKit::initializeSandboxParameters):
Expose the auxiliary process' CPU family as a parameter to the sandbox profile,
so that it can be used to predicate sandbox expressions.

  • WebProcess/com.apple.WebProcess.sb.in:

Allow mremap_encrypted from the Web Content process, because the arm64 dlopen() needs it.

2:05 PM Changeset in webkit [263365] by timothy_horton@apple.com
  • 6 edits
    1 add in trunk/Source

Disable the JS JIT when running in a translated process
https://bugs.webkit.org/show_bug.cgi?id=213478

Reviewed by Saam Barati.

Source/JavaScriptCore:

  • runtime/Options.cpp:

(JSC::Options::recomputeDependentOptions):
Based on our performance experiements, disable the JavaScript JIT
(but not the regular expression, DOM, or Wasm JIT) when running
in a translated process.

Source/WTF:

  • wtf/PlatformHave.h:
  • wtf/TranslatedProcess.h: Added.
  • WTF.xcodeproj/project.pbxproj:
  • wtf/CMakeLists.txt:

Add a helper function that can be used to determine that the current process
is being translated; currently the only case is an x86_64 process running on arm64e.

1:48 PM Changeset in webkit [263364] by timothy_horton@apple.com
  • 65 edits in trunk

Update macOS version macros
https://bugs.webkit.org/show_bug.cgi?id=213484

Reviewed by Alexey Proskuryakov.

Source/bmalloc:

  • Configurations/Base.xcconfig:
  • Configurations/DebugRelease.xcconfig:

Source/JavaScriptCore:

  • Configurations/Base.xcconfig:
  • Configurations/DebugRelease.xcconfig:
  • Configurations/Version.xcconfig:
  • Configurations/WebKitTargetConditionals.xcconfig:

Source/ThirdParty:

  • gtest/xcode/Config/DebugProject.xcconfig:
  • gtest/xcode/Config/ReleaseProject.xcconfig:

Source/ThirdParty/ANGLE:

  • Configurations/Base.xcconfig:
  • Configurations/DebugRelease.xcconfig:
  • Configurations/Version.xcconfig:
  • Configurations/WebKitTargetConditionals.xcconfig:

Source/ThirdParty/libwebrtc:

  • Configurations/Base.xcconfig:
  • Configurations/DebugRelease.xcconfig:
  • Configurations/Version.xcconfig:
  • Configurations/WebKitTargetConditionals.xcconfig:

Source/WebCore:

  • Configurations/Base.xcconfig:
  • Configurations/DebugRelease.xcconfig:
  • Configurations/Version.xcconfig:
  • Configurations/WebKitTargetConditionals.xcconfig:

Source/WebCore/PAL:

  • Configurations/Base.xcconfig:
  • Configurations/DebugRelease.xcconfig:
  • Configurations/Version.xcconfig:
  • Configurations/WebKitTargetConditionals.xcconfig:

Source/WebInspectorUI:

  • Configurations/DebugRelease.xcconfig:
  • Configurations/WebKitTargetConditionals.xcconfig:

Source/WebKit:

  • Configurations/Base.xcconfig:
  • Configurations/DebugRelease.xcconfig:
  • Configurations/Version.xcconfig:
  • Configurations/WebKitTargetConditionals.xcconfig:

Source/WebKitLegacy/mac:

  • Configurations/Base.xcconfig:
  • Configurations/DebugRelease.xcconfig:
  • Configurations/Version.xcconfig:
  • Configurations/WebKitTargetConditionals.xcconfig:

Source/WTF:

  • Configurations/Base.xcconfig:
  • Configurations/DebugRelease.xcconfig:

Tools:

  • ContentExtensionTester/Configurations/Base.xcconfig:
  • ContentExtensionTester/Configurations/DebugRelease.xcconfig:
  • DumpRenderTree/mac/Configurations/Base.xcconfig:
  • DumpRenderTree/mac/Configurations/DebugRelease.xcconfig:
  • ImageDiff/cg/Configurations/Base.xcconfig:
  • ImageDiff/cg/Configurations/DebugRelease.xcconfig:
  • MiniBrowser/Configurations/Base.xcconfig:
  • MiniBrowser/Configurations/DebugRelease.xcconfig:
  • TestWebKitAPI/Configurations/Base.xcconfig:
  • TestWebKitAPI/Configurations/DebugRelease.xcconfig:
  • WebEditingTester/Configurations/Base.xcconfig:
  • WebEditingTester/Configurations/DebugRelease.xcconfig:
  • WebKitTestRunner/Configurations/Base.xcconfig:
  • WebKitTestRunner/Configurations/DebugRelease.xcconfig:
  • lldb/lldbWebKitTester/Configurations/Base.xcconfig:
  • lldb/lldbWebKitTester/Configurations/DebugRelease.xcconfig:
1:46 PM Changeset in webkit [263363] by timothy_horton@apple.com
  • 3 edits in trunk/Source/WebKit

sysctl() fails due to sandbox violation
https://bugs.webkit.org/show_bug.cgi?id=213482

Reviewed by Maciej Stachowiak.

  • NetworkProcess/mac/com.apple.WebKit.NetworkProcess.sb.in:
  • WebProcess/com.apple.WebProcess.sb.in:

Extend the sandbox as necessary to make sysctl calls work.

1:24 PM Changeset in webkit [263362] by timothy_horton@apple.com
  • 2 edits in trunk/Source/ThirdParty/ANGLE

WebGL cannot create a context if there is no GPU on the PCIe bus
https://bugs.webkit.org/show_bug.cgi?id=213479

Reviewed by Maciej Stachowiak and Dean Jackson.

  • src/gpu_info_util/SystemInfo_macos.mm:

(angle::GetSystemInfo):
Do not bail from WebGL initialization if there are no GPUs on the PCIe bus.
Instead, continue on to context creation, and allow the system frameworks
to return an error if there truly is no GPU.

1:22 PM Changeset in webkit [263361] by timothy_horton@apple.com
  • 5 edits in trunk/Tools

API Test WeakLinking.WeakImport fails on arm64
https://bugs.webkit.org/show_bug.cgi?id=213477

Reviewed by Alexey Proskuryakov.

  • TestWebKitAPI/Tests/WTF/darwin/libTestWTFAlwaysMissing-iOS-v2.tbd:
  • TestWebKitAPI/Tests/WTF/darwin/libTestWTFAlwaysMissing-iOS.tbd:
  • TestWebKitAPI/Tests/WTF/darwin/libTestWTFAlwaysMissing-macOS-v2.tbd:
  • TestWebKitAPI/Tests/WTF/darwin/libTestWTFAlwaysMissing-macOS.tbd:

Add this architecture to the TBD files.

12:59 PM Changeset in webkit [263360] by eric.carlson@apple.com
  • 2 edits in trunk/LayoutTests

REGRESSION (r263121): [ Catalina Debug ] media/video-fullscreen-only-playback.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=213407
<rdar://problem/64545587>

Unreviewed speculative change as I have not been able to reproduce the reported bug.

  • media/video-fullscreen-only-playback.html:
12:26 PM Changeset in webkit [263359] by commit-queue@webkit.org
  • 7 edits in trunk

Added getFloatTimeDomainData method to AnalyserNode
https://bugs.webkit.org/show_bug.cgi?id=213393

Patch by Clark Wang <clark_wang@apple.com> on 2020-06-22
Reviewed by Chris Dumez.

LayoutTests/imported/w3c:

Re-baselined test to show a new passing test.

  • web-platform-tests/webaudio/idlharness.https.window-expected.txt:

Source/WebCore:

Added getFloatTimeDomainData method, as per spec: https://www.w3.org/TR/webaudio/#analysernode.
Implementation of RealtimeAnalyser::getFloatTimeDomainData(Float32Array* destinationArray) is based on:
https://source.chromium.org/chromium/chromium/src/+/master:third_party/blink/renderer/modules/webaudio/realtime_analyser.cc.
Removed nullable option from some AnalyserNode methods.

Re-baselined existing tests to show new passing test.

  • Modules/webaudio/AnalyserNode.h:
  • Modules/webaudio/AnalyserNode.idl:
  • Modules/webaudio/RealtimeAnalyser.cpp:

(WebCore::RealtimeAnalyser::getFloatFrequencyData):
(WebCore::RealtimeAnalyser::getByteFrequencyData):
(WebCore::RealtimeAnalyser::getFloatTimeDomainData):
(WebCore::RealtimeAnalyser::getByteTimeDomainData):

  • Modules/webaudio/RealtimeAnalyser.h:
11:58 AM Changeset in webkit [263358] by Jonathan Bedard
  • 2 edits in trunk/Tools

Bring up watchOS/tvOS on build.webkit.org (Follow-up fix x3)
https://bugs.webkit.org/show_bug.cgi?id=213402
<rdar://problem/64542588>

Reviewed by Alexey Proskuryakov.

  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/WebKitBuildbot.js:

(WebKitBuildbot): 64 bit is more correct for watchOS embedded builds.

10:43 AM Changeset in webkit [263357] by ggaren@apple.com
  • 2 edits in trunk/Source/WTF

Unreviewed, re-landing r262904.

r263223 should fix the test flakiness we saw.

Re-landed changeset:

"[Cocoa] Build callOnMainThread on WTF::RunLoop rather than on
a timer"
https://bugs.webkit.org/show_bug.cgi?id=213063
https://trac.webkit.org/changeset/262904

10:20 AM Changeset in webkit [263356] by commit-queue@webkit.org
  • 16 edits
    8 adds in trunk

Add referrerpolicy attribute support for <link>
https://bugs.webkit.org/show_bug.cgi?id=213342

Patch by Rob Buis <rbuis@igalia.com> on 2020-06-22
Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Fix wrong resource file name usage.

  • web-platform-tests/referrer-policy/generic/multiple-headers-and-values.html:
  • web-platform-tests/referrer-policy/generic/multiple-headers-combined.html:
  • web-platform-tests/referrer-policy/generic/multiple-headers-one-invalid.html:
  • web-platform-tests/referrer-policy/generic/multiple-headers-one-unknown-token.html:
  • web-platform-tests/referrer-policy/generic/multiple-headers.html:

Source/WebCore:

Add support for referrerpolicy attribute handling on
link prefetch/preload/stylesheet.

Tests: http/tests/security/referrer-policy-attribute-style-no-referrer.html

http/wpt/preload/refferer-policy.html

  • html/HTMLLinkElement.cpp:

(WebCore::HTMLLinkElement::process):
(WebCore::HTMLLinkElement::setReferrerPolicyForBindings):
(WebCore::HTMLLinkElement::referrerPolicyForBindings const):
(WebCore::HTMLLinkElement::referrerPolicy const):

  • html/HTMLLinkElement.h:
  • html/parser/HTMLPreloadScanner.cpp:

(WebCore::TokenPreloadScanner::StartTagScanner::processAttribute):

  • html/parser/HTMLResourcePreloader.cpp:

(WebCore::PreloadRequest::resourceRequest):

  • loader/LinkLoader.cpp:

(WebCore::LinkLoader::loadLinksFromHeader):
(WebCore::LinkLoader::preloadIfNeeded):
(WebCore::LinkLoader::prefetchIfNeeded):

  • loader/LinkLoader.h:

LayoutTests:

Add a tests for <link rel="stylesheet">, <link rel="preload"> and the
referrerpolicy attribute.
Unskip the referrer-policy/generic/link-rel-prefetch.html test.

  • TestExpectations:
  • http/tests/security/referrer-policy-attribute-style-no-referrer-expected.html: Added.
  • http/tests/security/referrer-policy-attribute-style-no-referrer.html: Added.
  • http/tests/security/resources/green-background.css: Added.

(body):

  • http/tests/security/resources/green-if-no-referrer-css.php: Added.
  • http/tests/security/resources/pass-if-no-referrer.php: Added.
  • http/wpt/preload/refferer-policy-expected.txt: Added.
  • http/wpt/preload/refferer-policy.html: Added.
  • http/wpt/preload/resources/referrer-img.py: Added.

(main):

10:01 AM Changeset in webkit [263355] by Simon Fraser
  • 2 edits in trunk/Source/WebCore

Fix build error with release build and "#define LOG_DISABLED 0"
https://bugs.webkit.org/show_bug.cgi?id=213420

Reviewed by Sam Weinig.

AnimationBase::updateStateMachine() uses LOG_ERROR so needs to test ERROR_DISABLED not LOG_DISABLED.

  • page/animation/AnimationBase.cpp:

(WebCore::AnimationBase::updateStateMachine):

9:58 AM Changeset in webkit [263354] by aestes@apple.com
  • 2 edits in trunk/LayoutTests

REGRESSION (r263150): http/tests/ssl/applepay/ApplePayInstallmentItems.https.html is failing
https://bugs.webkit.org/show_bug.cgi?id=213466
<rdar://problem/64537600>

Reviewed by Tim Horton.

  • http/tests/ssl/applepay/ApplePayInstallmentItems.https.html: Restored two lines of code

that were accidentally removed in r263150 and are necessary for the test to pass.

9:34 AM Changeset in webkit [263353] by commit-queue@webkit.org
  • 7 edits in trunk

Fix the case of "null type Blob slice" in wpt/FileAPI/blob/Blob-slice.html
https://bugs.webkit.org/show_bug.cgi?id=213370

Patch by Tetsuharu Ohzeki <Tetsuharu Ohzeki> on 2020-06-22
Reviewed by Darin Adler.

LayoutTests/imported/w3c:

  • web-platform-tests/FileAPI/blob/Blob-slice-expected.txt:

Source/WebCore:

  • fileapi/Blob.h:

(WebCore::Blob::slice const):
Remove unnecessary default arguments
These default arguments are introduced in r83873
but we don't need them because WebIDL binding handles them.

  • In the previous code, we use optional DOMString? for the _contentType_ arguments for Blob.slice(). Then, our codegen generates a code which uses convert<IDLNullable<IDLDOMString>> and it returns String() if the JS value is null. This caused the failure case in this change.

LayoutTests:

  • http/tests/local/fileapi/send-sliced-dragged-file-expected.txt:
  • http/tests/local/fileapi/send-sliced-dragged-file.html:
9:31 AM Changeset in webkit [263352] by Andres Gonzalez
  • 3 edits in trunk/Source/WebCore

Code cleanup in WebAccessibilityObjectWrapper updateObjectBackingStore and position.
https://bugs.webkit.org/show_bug.cgi?id=213438

Reviewed by Darin Adler.

  • accessibility/mac/WebAccessibilityObjectWrapperBase.mm:

(-[WebAccessibilityObjectWrapperBase updateObjectBackingStore]):
Removed unnecessary call to axBackingObject.

  • accessibility/mac/WebAccessibilityObjectWrapperMac.mm:

(-[WebAccessibilityObjectWrapper position]):
Check for isIsolatedTreeEnabled instead of for the request thread,
since isolated tree mode = 1 runs on the main thread.

9:15 AM Changeset in webkit [263351] by youenn@apple.com
  • 6 edits in trunk

[WebRTC] Add support for freeze/pause receiver stats
https://bugs.webkit.org/show_bug.cgi?id=212938
<rdar://problem/64141493>

Reviewed by Eric Carlson.

Source/WebCore:

Covered by updated tests.

Receiver stats are useful to check for freezes.
Let's introduce it in 'track' stats for now, we will later on move all
'receiver' stats to its own object once we fully align with spec.

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

(WebCore::fillRTCMediaStreamTrackStats):

LayoutTests:

  • webrtc/video-mediastreamtrack-stats.html:
9:09 AM Changeset in webkit [263350] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Image crossorigin mutations should be considered "relevant mutations"
https://bugs.webkit.org/show_bug.cgi?id=213335

Patch by Rob Buis <rbuis@igalia.com> on 2020-06-22
Reviewed by Darin Adler.

As follow up to r263345, this check is not needed after all since the for loop
already does the same check.

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):

8:26 AM Changeset in webkit [263349] by Jason_Lawrence
  • 21 edits in trunk/Source/WebCore

Unreviewed, reverting r263331.

This commit was causing 50+ iOS debug tests to crash.

Reverted changeset:

"Convert DateComponents parsing code to use Optional based
return values rather than out-parameters"
https://bugs.webkit.org/show_bug.cgi?id=213440
https://trac.webkit.org/changeset/263331

8:06 AM Changeset in webkit [263348] by Jacob Uphoff
  • 3 edits in trunk/LayoutTests

[ macOS iOS ] REGRESSION: fast/mediastream/mediastrea mtrack-video-frameRate-clon e-increasing.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=213461

Unreviewed test gardening

  • platform/ios-wk2/TestExpectations:
  • platform/mac-wk2/TestExpectations:
7:32 AM Changeset in webkit [263347] by aakash_jain@apple.com
  • 2 edits in trunk/Tools

[ews] Switch contributors.json url from trac to svn server
https://bugs.webkit.org/show_bug.cgi?id=213457

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-build/steps.py:

(ValidateCommiterAndReviewer):
(ValidateCommiterAndReviewer.load_contributors_from_trac):

5:28 AM Changeset in webkit [263346] by svillar@igalia.com
  • 7 edits
    2 adds in trunk

[WebXR] Add a preliminary implementation of XRWebGLLayer
https://bugs.webkit.org/show_bug.cgi?id=213022

Reviewed by Carlos Garcia Campos.

LayoutTests/imported/w3c:

Added new expectations.

  • web-platform-tests/webxr/xrWebGLLayer_constructor.https-expected.txt: Added.
  • web-platform-tests/webxr/xrWebGLLayer_framebuffer_sameObject.https-expected.txt: Added.

Source/WebCore:

Added a preliminary implementation of XRWebGLLayer. It does not have any functionality at the moment so
it cannot be used to render WebXR stuff. This patch adds all the machinery required to create and properly
initialize the layer according to the spec.

Two new wpt tests are passing now.

  • Modules/webxr/WebXRSession.h: Expose session mode.
  • Modules/webxr/WebXRWebGLLayer.cpp:

(WebCore::WebXRWebGLLayer::create): Implemented spec for XRWebGLLayer creation.
(WebCore::WebXRWebGLLayer::computeNativeWebGLFramebufferResolution): Added with mock implementation.
(WebCore::WebXRWebGLLayer::computeRecommendedWebGLFramebufferResolution): Added.
(WebCore::WebXRWebGLLayer::WebXRWebGLLayer):
(WebCore::WebXRWebGLLayer::framebuffer const): Returned type should be a pointer.
(WebCore::WebXRWebGLLayer::framebufferWidth const): Return framebuffer width if available, otherwise return
the base context width.
(WebCore::WebXRWebGLLayer::framebufferHeight const): Ditto but with heights.
(WebCore::WebXRWebGLLayer::getNativeFramebufferScaleFactor): Implemented.

  • Modules/webxr/WebXRWebGLLayer.h: New methods and type adjustments.

LayoutTests:

  • platform/wpe/TestExpectations: Added 2 more tests that are passing now.
3:49 AM Changeset in webkit [263345] by commit-queue@webkit.org
  • 10 edits in trunk

Image crossorigin mutations should be considered "relevant mutations"
https://bugs.webkit.org/show_bug.cgi?id=213335

Patch by Rob Buis <rbuis@igalia.com> on 2020-06-22
Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Update improved test result.

  • web-platform-tests/html/canvas/element/drawing-images-to-the-canvas/drawimage_crossorigin.sub-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/relevant-mutations-expected.txt:

Source/WebCore:

Make crossorigin attribute's state changes relevant mutations [1]. This change
also fixes several picture related mutations to be relevant [2].

Test: imported/w3c/web-platform-tests/html/semantics/embedded-content/the-img-element/relevant-mutations.html

[1] https://html.spec.whatwg.org/#reacting-to-dom-mutations:attr-img-crossorigin
[2] https://html.spec.whatwg.org/#reacting-to-dom-mutations

  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::bestFitSourceFromPictureElement):
(WebCore::HTMLImageElement::evaluateDynamicMediaQueryDependencies):
(WebCore::HTMLImageElement::selectImageSource):
(WebCore::parseCrossoriginState):
(WebCore::HTMLImageElement::attributeChanged):
(WebCore::HTMLImageElement::parseAttribute):
(WebCore::HTMLImageElement::insertedIntoAncestor):
(WebCore::HTMLImageElement::removedFromAncestor):

  • html/HTMLImageElement.h:
  • html/HTMLPictureElement.cpp:

(WebCore::HTMLPictureElement::sourcesChanged):

  • html/HTMLSourceElement.cpp:

(WebCore::HTMLSourceElement::insertedIntoAncestor):
(WebCore::HTMLSourceElement::removedFromAncestor):
(WebCore::HTMLSourceElement::parseAttribute):

  • html/HTMLSourceElement.h:
  • loader/ImageLoader.h:
2:23 AM Changeset in webkit [263344] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

[Flatpak SDK] Persist sccache auth token across flatpak updates
https://bugs.webkit.org/show_bug.cgi?id=213427

Patch by Philippe Normand <pnormand@igalia.com> on 2020-06-22
Reviewed by Žan Doberšek.

After a successful flatpak update check if an sccache auth token exists and reuse it when
updating the sccache config file.

  • flatpak/flatpakutils.py:

(WebkitFlatpak.save_config):

12:50 AM Changeset in webkit [263343] by Carlos Garcia Campos
  • 4 edits in trunk/LayoutTests

[GTK] Ping attribute tests have been timeout since r204720
https://bugs.webkit.org/show_bug.cgi?id=162017

Reviewed by Adrian Perez de Castro.

The tests are using "TouchEvent" in window to check whether it's a touch screen and use
uiController.singleTapAtPoint() instead of the eventSender. TouchEvent is always added to the window object when
building with touch events enabled, which is the case of the GTK port. However, the ontouch event handlers are
added at runtime only when there's an actual touch screen (EnabledAtRuntime=TouchEvents). So, we can check
"ontouchstart" in window instead.

  • http/tests/inspector/network/ping-type.html:
  • http/tests/navigation/ping-attribute/resources/utilities.js:

(clickElement):

  • platform/gtk/TestExpectations:
12:18 AM Changeset in webkit [263342] by graouts@webkit.org
  • 2 edits in trunk/Source/WebKit

WebKit fails to leave audio routing arbitration during navigation, closing.
https://bugs.webkit.org/show_bug.cgi?id=213426
<rdar://problem/64395051>

Unreviewed build fix for an unannotated switch fall-through between switch labels.

  • UIProcess/API/Cocoa/WKWebViewTesting.mm:

(-[WKWebView _audioRoutingArbitrationStatus]):

Jun 21, 2020:

11:51 PM Changeset in webkit [263341] by ysuzuki@apple.com
  • 3 edits in trunk/Source/WTF

[WTF] Ensure ASCIILiteral is ASCII characters at compile time
https://bugs.webkit.org/show_bug.cgi?id=213449

Reviewed by Ross Kirsling.

The purpose of ASCIILiteral is ensure that this is compile-time (do not need to consider about ownership) ASCII characters.
By using isASCII and ASSERT_UNDER_CONSTEXPR_CONTEXT, we can make sure that this C string does not include non ASCII characters.
For example,

auto globalVariable = "ラーメン (Ramen in Japanese)"_s;

becomes compile error.

  • wtf/ASCIICType.h:

(WTF::isASCII):

  • wtf/text/ASCIILiteral.h:

(WTF::StringLiterals::operator _s):

11:50 PM Changeset in webkit [263340] by ysuzuki@apple.com
  • 5 edits in trunk

[WTF] URL should support dataLog
https://bugs.webkit.org/show_bug.cgi?id=213450

Reviewed by Mark Lam.

Source/WTF:

Add URL::dump(PrintStream&) to support dataLog(url) which is extremely useful for WTF / JSC developers.

  • wtf/URL.cpp:

(WTF::URL::dump const):

  • wtf/URL.h:

Tools:

Add test for URL::dump.

  • TestWebKitAPI/Tests/WTF/URL.cpp:

(TestWebKitAPI::TEST_F):

9:43 PM Changeset in webkit [263339] by Lauro Moura
  • 2 edits in trunk/WebDriverTests

[WebDriver][GTK] Some executing_async_javascript_tests.py tests are failing with TimeoutExceptions
https://bugs.webkit.org/show_bug.cgi?id=211496

Unreviewed test gardening.

The two tests started passing with the updated selenium imported
tests from r263264;

9:41 PM Changeset in webkit [263338] by Lauro Moura
  • 2 edits in trunk/WebDriverTests

WebDriver: several tests in imported/selenium/py/test/selenium/webdriver/common/visibility_tests.py fail
https://bugs.webkit.org/show_bug.cgi?id=182334

Unreviewed test gardening.

The last two remaining tests from this bug started passing after the
imported selenium tests were updated in r263264.

9:39 PM Changeset in webkit [263337] by Lauro Moura
  • 2 edits in trunk/WebDriverTests

WebDriver: two selenium alert tests are failing
https://bugs.webkit.org/show_bug.cgi?id=181727

Unreviewed test gardening.

These tests also have been passing since r262861.

9:38 PM Changeset in webkit [263336] by Lauro Moura
  • 2 edits in trunk/WebDriverTests

[WebDriver][GTK] Gardening failures related to missing selenium files

Unreviewed test gardening.

The relative_by_tests require some JS fragments built by Bazel,
Selenium's build tool.

3:58 PM Changeset in webkit [263335] by commit-queue@webkit.org
  • 2 edits in trunk/JSTests

Attempt to unskip stress test array-buffer-view-watchpoint-can-be-fired-really-add-in-dfg.js on most architectures
https://bugs.webkit.org/show_bug.cgi?id=213433

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-06-21
Reviewed by Darin Adler.

  • stress/array-buffer-view-watchpoint-can-be-fired-in-really-add-in-dfg.js:
3:47 PM Changeset in webkit [263334] by weinig@apple.com
  • 43 edits in trunk/Source/WebCore

Convert much of the SVG string parsing code to use Optional based return values rather than out-parameters
https://bugs.webkit.org/show_bug.cgi?id=213416

Reviewed by Darin Adler.

Update SVG parsers to use Optional style return programming rather than out parameters.
To make things even nicer, SVGPathSource based parsers now have a type per-parse function,
which makes working with them much easier. In the future, we should consider exanding these
new types to be used by SVGPathConsumer family of classes as well.

  • WebCore.xcodeproj/project.pbxproj:

Add SVGPathSegValue.h, which was missing from the Xcode project.

  • svg/SVGAngleValue.cpp:

(WebCore::parseAngleType):
(WebCore::SVGAngleValue::setValueAsString):
Adopt updated parseNumber() function, and do a drive by removal of an easy to remove
upconvertedCharacters.

  • svg/SVGAnimateMotionElement.cpp:

(WebCore::SVGAnimateMotionElement::calculateToAtEndOfDurationValue):
(WebCore::SVGAnimateMotionElement::calculateFromAndToValues):
(WebCore::SVGAnimateMotionElement::calculateFromAndByValues):
(WebCore::SVGAnimateMotionElement::calculateDistance):
Now uses new parsePoint() function. Using Optional.valueOr() where
the old code would have had parsePoint() doing the clearing.

  • svg/SVGAnimationElement.cpp:

(WebCore::parseKeySplines):
Now returns an Optional<Vector<UnitBezier>>.
(WebCore::SVGAnimationElement::parseAttribute):
Now uses new parseKeySplines, and does an explicit clear on parse failure (old code
did it implicitly in the parse function).

  • svg/SVGFEConvolveMatrixElement.cpp:

(WebCore::SVGFEConvolveMatrixElement::parseAttribute):

  • svg/SVGFEDiffuseLightingElement.cpp:

(WebCore::SVGFEDiffuseLightingElement::parseAttribute):

  • svg/SVGFEDropShadowElement.cpp:

(WebCore::SVGFEDropShadowElement::parseAttribute):

  • svg/SVGFEGaussianBlurElement.cpp:

(WebCore::SVGFEGaussianBlurElement::parseAttribute):

  • svg/SVGFEMorphologyElement.cpp:

(WebCore::SVGFEMorphologyElement::parseAttribute):

  • svg/SVGFESpecularLightingElement.cpp:

(WebCore::SVGFESpecularLightingElement::parseAttribute):

  • svg/SVGFETurbulenceElement.cpp:

(WebCore::SVGFETurbulenceElement::parseAttribute):
Adopt Optional based parseNumberOptionalNumber.

  • svg/SVGImageElement.cpp:

(WebCore::SVGImageElement::parseAttribute):

  • svg/SVGFEImageElement.cpp:

(WebCore::SVGFEImageElement::parseAttribute):
Simplify by using the SVGPreserveAspectRatioValue constructor
which calls parse. No need for three lines.

  • svg/SVGFitToViewBox.cpp:

(WebCore::SVGFitToViewBox::parseAttribute):
Adopt new Optional based parseViewBox.
Simplify by using the SVGPreserveAspectRatioValue constructor
which calls parse. No need for three lines.

(WebCore::SVGFitToViewBox::parseViewBox):
Convert to be Optional based, and adopt new parseNumber functions.

  • svg/SVGFitToViewBox.h:

Updated signatures for new Optional based functions.

  • svg/SVGGlyphRefElement.cpp:

(WebCore::parseFloat):
Adopt Optional based parseNumber.

  • svg/SVGHKernElement.cpp:

(WebCore::SVGHKernElement::buildHorizontalKerningPair const):

  • svg/SVGHKernElement.h:
  • svg/SVGVKernElement.cpp:

(WebCore::SVGVKernElement::buildVerticalKerningPair const):

  • svg/SVGVKernElement.h:

Convert to be Optional based. Update a few callers to use makeString.

  • svg/SVGToOTFFontConversion.cpp:

(WebCore::SVGToOTFFontConverter::addKerningPair const):
(WebCore::SVGToOTFFontConverter::appendKERNSubtable):
Adopt new Optional based kerning pair builders. Add some moves
to avoid some copies.

  • svg/SVGLengthValue.cpp:

(WebCore::SVGLengthValue::setValueAsString):
Adopt Optional based parseNumber.

  • svg/SVGNumberList.h:

(WebCore::SVGNumberList::parse):
Adopt Optional based parseNumber.

  • svg/SVGParserUtilities.cpp:

(WebCore::genericParseNumber):
(WebCore::parseNumber):
(WebCore::genericParseArcFlag):
(WebCore::parseArcFlag):
(WebCore::parseNumberOptionalNumber):
(WebCore::parsePoint):
(WebCore::parseRect):
(WebCore::parseGlyphName):
(WebCore::parseUnicodeRange):
(WebCore::parseKerningUnicodeString):
(WebCore::genericParseFloatPoint):
(WebCore::parseFloatPoint):
(WebCore::parseSVGNumber): Deleted.
(WebCore::parseNumberFromString): Deleted.
(WebCore::parseDelimitedString): Deleted.
(WebCore::parseFloatPoint2): Deleted.
(WebCore::parseFloatPoint3): Deleted.

  • svg/SVGParserUtilities.h:

(WebCore::isSVGSpace):
(WebCore::skipOptionalSVGSpaces):
(WebCore::skipOptionalSVGSpacesOrDelimiter):

  • Converts parse* functions to return Optional values rather than using outparameters.
  • Removes unused parseSVGNumber and parseDelimitedString.
  • Removes parseFloatPoint2 and parseFloatPoint3. They weren't useful enough to keep around.
  • Renames parseNumberFromString to parseNumber. The argument is a String, it's clear enough.
  • Replace boolean skip parameters with new enum SuffixSkippingPolicy.
  • Make parseFloatPoint have two overloads rather than being templatized to be consistent.
  • svg/SVGPathBlender.cpp:

(WebCore::pullFromSources):
(WebCore::SVGPathBlender::blendMoveToSegment):
(WebCore::SVGPathBlender::blendLineToSegment):
(WebCore::SVGPathBlender::blendLineToHorizontalSegment):
(WebCore::SVGPathBlender::blendLineToVerticalSegment):
(WebCore::SVGPathBlender::blendCurveToCubicSegment):
(WebCore::SVGPathBlender::blendCurveToCubicSmoothSegment):
(WebCore::SVGPathBlender::blendCurveToQuadraticSegment):
(WebCore::SVGPathBlender::blendCurveToQuadraticSmoothSegment):
(WebCore::SVGPathBlender::blendArcToSegment):
(WebCore::SVGPathBlender::canBlendPaths):
(WebCore::SVGPathBlender::blendAnimatedPath):
Update to adopt new SVGPathSource interface. Added pullFromSources helper
which substantially simplifies pulling from both the from and to source at
the same time and is now possible due to all the SVGPathSource functions
returning the segment types rather than taking them as out parameters.

  • svg/SVGPathByteStreamSource.cpp:

(WebCore::SVGPathByteStreamSource::nextCommand):
(WebCore::SVGPathByteStreamSource::parseSVGSegmentType):
(WebCore::SVGPathByteStreamSource::parseMoveToSegment):
(WebCore::SVGPathByteStreamSource::parseLineToSegment):
(WebCore::SVGPathByteStreamSource::parseLineToHorizontalSegment):
(WebCore::SVGPathByteStreamSource::parseLineToVerticalSegment):
(WebCore::SVGPathByteStreamSource::parseCurveToCubicSegment):
(WebCore::SVGPathByteStreamSource::parseCurveToCubicSmoothSegment):
(WebCore::SVGPathByteStreamSource::parseCurveToQuadraticSegment):
(WebCore::SVGPathByteStreamSource::parseCurveToQuadraticSmoothSegment):
(WebCore::SVGPathByteStreamSource::parseArcToSegment):

  • svg/SVGPathByteStreamSource.h:

Adopt new SVGPathSource interface.

  • svg/SVGPathParser.cpp:

(WebCore::SVGPathParser::parseMoveToSegment):
(WebCore::SVGPathParser::parseLineToSegment):
(WebCore::SVGPathParser::parseLineToHorizontalSegment):
(WebCore::SVGPathParser::parseLineToVerticalSegment):
(WebCore::SVGPathParser::parseCurveToCubicSegment):
(WebCore::SVGPathParser::parseCurveToCubicSmoothSegment):
(WebCore::SVGPathParser::parseCurveToQuadraticSegment):
(WebCore::SVGPathParser::parseCurveToQuadraticSmoothSegment):
(WebCore::SVGPathParser::parseArcToSegment):
(WebCore::SVGPathParser::parsePathData):
Adapt to new SVGPathSource interface. Code reads a bit nicer now
that we don't have a ton of local variables in each method. Could
be made nicer in the future by adopting Segment types in the path
consumer code.

  • svg/SVGPathSegListSource.cpp:

(WebCore::SVGPathSegListSource::nextCommand):
(WebCore::SVGPathSegListSource::parseSVGSegmentType):
(WebCore::SVGPathSegListSource::parseMoveToSegment):
(WebCore::SVGPathSegListSource::parseLineToSegment):
(WebCore::SVGPathSegListSource::parseLineToHorizontalSegment):
(WebCore::SVGPathSegListSource::parseLineToVerticalSegment):
(WebCore::SVGPathSegListSource::parseCurveToCubicSegment):
(WebCore::SVGPathSegListSource::parseCurveToCubicSmoothSegment):
(WebCore::SVGPathSegListSource::parseCurveToQuadraticSegment):
(WebCore::SVGPathSegListSource::parseCurveToQuadraticSmoothSegment):
(WebCore::SVGPathSegListSource::parseArcToSegment):

  • svg/SVGPathSegListSource.h:

Adopt new SVGPathSource interface.

  • svg/SVGPathSource.h:

Update interface to return Optionals, with a specific type for
segment kind that be parsed.

  • svg/SVGPathStringSource.cpp:

(WebCore::nextCommandHelper):
(WebCore::SVGPathStringSource::nextCommand):
(WebCore::parseSVGSegmentTypeHelper):
(WebCore::SVGPathStringSource::parseSVGSegmentType):
(WebCore::SVGPathStringSource::parseMoveToSegment):
(WebCore::SVGPathStringSource::parseLineToSegment):
(WebCore::SVGPathStringSource::parseLineToHorizontalSegment):
(WebCore::SVGPathStringSource::parseLineToVerticalSegment):
(WebCore::SVGPathStringSource::parseCurveToCubicSegment):
(WebCore::SVGPathStringSource::parseCurveToCubicSmoothSegment):
(WebCore::SVGPathStringSource::parseCurveToQuadraticSegment):
(WebCore::SVGPathStringSource::parseCurveToQuadraticSmoothSegment):
(WebCore::SVGPathStringSource::parseArcToSegment):
(WebCore::parseArcToSegmentHelper): Deleted.

  • svg/SVGPathStringSource.h:

Adopt new SVGPathSource interface. Replace out of line helpers (or use of things
like parseFloatPoint2) with generic lambda helpers, helping to keep the code more
localized.

  • svg/SVGPointList.h:

(WebCore::SVGPointList::parse):
Adopt Optional based parseNumber.

  • svg/SVGTransformList.h:
  • svg/SVGTransformable.cpp:

(WebCore::parseTransformParamList):
(WebCore::SVGTransformable::parseTransformValue):
(WebCore::SVGTransformable::parseAndSkipType):
(WebCore::SVGTransformable::parseTransformType):

  • svg/SVGTransformable.h:

Convert parseTransformValue/parseAndSkipType to be Optional based.

  • svg/SVGViewSpec.cpp:

(WebCore::SVGViewSpec::parseViewSpec):
Adopt Optional based parseViewBox.

  • svg/properties/SVGAnimationAdditiveValueFunctionImpl.h:

Adopt Optional based parseNumber.

  • svg/properties/SVGPropertyTraits.h:

(WebCore::SVGPropertyTraits<float>::fromString):
(WebCore::SVGPropertyTraits<float>::parse):
(WebCore::SVGPropertyTraits<FloatPoint>::fromString):
(WebCore::SVGPropertyTraits<FloatPoint>::parse):
(WebCore::SVGPropertyTraits<FloatRect>::fromString):
(WebCore::SVGPropertyTraits<FloatRect>::parse):
Adopt Optional based parsers.

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

[Flatpak] Nightly runner fails to extract zip files
https://bugs.webkit.org/show_bug.cgi?id=213445

Patch by Philippe Normand <pnormand@igalia.com> on 2020-06-21
Reviewed by Darin Adler.

  • Scripts/webkit-flatpak-run-nightly: Ensure the buffered zip data is written to disk before

extraction.

1:20 PM Changeset in webkit [263332] by ggaren@apple.com
  • 3 edits in trunk/LayoutTests

compositing/video/video-border-radius-clipping.html was a flaky failure after r263223
https://bugs.webkit.org/show_bug.cgi?id=213424

Reviewed by Darin Adler.

The last attempt to unflake this test was r253310. Let's try again.

I took a screen recording of a few hundred loads of this test @ r263222,
and it looks like it was always possible for canplaythrough and seeked
to fire before the video had rendered its first frame. So, this is a
test issue.

The screen recording seems to show that waiting for
requestAnimationFrame ensures that the video renders its first frame.
This might be for a principled system vsync reason, or just a lucky
delay. Either way, the test seems less flaky now.

This might mean that we can remove the previous seeked event workaround,
but I chose not to tempt fate, and left it in place.

  • compositing/video/video-border-radius-clipping-expected.html:
  • compositing/video/video-border-radius-clipping.html:
  • media/video-test.js:

(_eventCallback):
(waitForEvent):

12:58 PM Changeset in webkit [263331] by weinig@apple.com
  • 21 edits in trunk/Source/WebCore

Convert DateComponents parsing code to use Optional based return values rather than out-parameters
https://bugs.webkit.org/show_bug.cgi?id=213440

Reviewed by Darin Adler.

Rework DateComponents and Date/Time related InputTypes to use Optional based programming
for parsing results. Also take the opportunity to remove unicode upconversion from
DateComponent parsing and instead separate UChar and LChar variants via templates.

  • html/BaseDateAndTimeInputType.cpp:
  • html/BaseDateAndTimeInputType.h:
  • html/DateInputType.cpp:
  • html/DateInputType.h:
  • html/DateTimeInputType.cpp:
  • html/DateTimeInputType.h:
  • html/DateTimeLocalInputType.cpp:
  • html/DateTimeLocalInputType.h:
  • html/HTMLInputElement.cpp:
  • html/HTMLInputElement.h:
  • html/InputType.cpp:
  • html/InputType.h:
  • html/MonthInputType.cpp:
  • html/MonthInputType.h:
  • html/TimeInputType.cpp:
  • html/TimeInputType.h:
  • html/WeekInputType.cpp:
  • html/WeekInputType.h:
    • Removes parseToDateComponentsInternal. No need it and parseToDateComponents.
    • Makes parseToDateComponents pure virtual. The old code had a default implementations down in InputType, but it had no callers.
    • Remove iOS vs. non-iOS difference for dateType(). It is now available on InputType on all platforms.
    • Make setMillisecondToDateComponents and parseToDateComponents return an Optional.
  • platform/DateComponents.cpp:
  • platform/DateComponents.h:
    • Replace member function based interfaces for parsing/setting explicit time offsets with new factory functions that return Optional<DateComponents>.
    • These factories are implemented using the existing member functions, which are now private.
    • Make max/min constants constexpr.
    • Make parse* member functions templates to allow factory parse functions to call them without upconverting.
    • Replace header guard with #pragma once.
11:43 AM Changeset in webkit [263330] by mmaxfield@apple.com
  • 1 edit
    3 adds in trunk/LayoutTests

fast/text/international/system-language/navigator-language/navigator-language tests are failing on Mojave
<rdar://problem/64468227>

Unreviewed test gardening.

  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-en-US-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-es-ES-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-pt-BR-expected.txt: Added.
10:13 AM Changeset in webkit [263329] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[LFC] Add basic support for width: fit-content
https://bugs.webkit.org/show_bug.cgi?id=213444

Reviewed by Antti Koivisto.

Source/WebCore:

At this point this is just a shrink-to-fit sizing (missing the case when the available horizontal space is not specified).

Test: fast/layoutformattingcontext/fit-content-width-simple.html

  • layout/FormattingContextGeometry.cpp:

(WebCore::Layout::FormattingContext::Geometry::computedWidthValue):

LayoutTests:

  • fast/layoutformattingcontext/fit-content-width-simple-expected.html: Added.
  • fast/layoutformattingcontext/fit-content-width-simple.html: Added.
8:34 AM Changeset in webkit [263328] by jer.noble@apple.com
  • 14 edits
    1 add in trunk

WebKit fails to leave audio routing arbitration during navigation, closing.
https://bugs.webkit.org/show_bug.cgi?id=213426
<rdar://problem/64395051>

Reviewed by Eric Carlson.

Source/WebCore:

When setting the AudioSession category, make sure to leave routing arbitration before bailing out early. Also,
HTMLMediaElement::canProduceAudio() should return false when the element's document is suspended or stopped.
Otherwise, the AudioSession will continue in the MediaPlayback category indefinitely, and routing arbitration
will remain active.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::canProduceAudio const):

  • platform/audio/mac/AudioSessionMac.mm:

(WebCore::AudioSession::setCategory):

Source/WebKit:

Add testing SPIs to verify whether a WebPage successfully entered or left audio routing
arbitration. Notify the Arbitration proxy when the page is shut down, which ensures arbitration
will end if the client closes the WKWebView.

  • UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h:
  • UIProcess/API/Cocoa/WKWebViewTesting.mm:

(-[WKWebView _audioRoutingArbitrationStatus]):

  • UIProcess/API/mac/WKWebViewTestingMac.mm:
  • UIProcess/Media/AudioSessionRoutingArbitratorProxy.h:

(WebKit::AudioSessionRoutingArbitratorProxy::arbitrationStatus const):

  • UIProcess/Media/cocoa/AudioSessionRoutingArbitratorProxyCocoa.mm:

(WebKit::AudioSessionRoutingArbitratorProxy::processDidTerminate):
(WebKit::AudioSessionRoutingArbitratorProxy::beginRoutingArbitrationWithCategory):
(WebKit::AudioSessionRoutingArbitratorProxy::endRoutingArbitration):

  • UIProcess/WebPageProxy.h:
  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::shutDown):

  • UIProcess/WebProcessProxy.h:

(WebKit::WebProcessProxy::audioSessionRoutingArbitrator):

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKitCocoa/AudioRoutingArbitration.mm: Added.

(AudioRoutingArbitration::statusShouldBecomeEqualTo):
(TEST_F):

6:51 AM Changeset in webkit [263327] by Alan Bujtas
  • 6 edits
    2 adds in trunk

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

Reviewed by Antti Koivisto.

Source/WebCore:

  1. The table generates a principal block container box called the table wrapper box that contains the table box itself and any caption boxes.
  2. The table wrapper box establishes a block formatting context, and the table box establishes a table formatting context.
  3. The computed values of properties 'position', 'float', 'margin-*', 'top', 'right', 'bottom', and 'left' on the table element are used on the table wrapper box and not the table box; all other values of non-inheritable properties are used on the table box and not the table wrapper box.
  4. In a block formatting context, each box's left outer edge touches the left edge of the containing block. This is true even in the presence of floats, unless the box establishes a new block formatting context (in which case the box itself may become narrower due to the floats)

Now consider the following case:
<div style="display: block; width: 500px;">

<div style="float: left; width: 100px;"></div>
<div style="display: table; width: 10%;"></div>

</div>

  1. We create a table wrapper box to wrap the "display: table" block level box (#1).
  2. The table wrapper box's width property is set to auto (#3).
  3. Since it establishes a new block formatting context, the available horizontal space gets shrunk by the float (#4)
  4. The table wrapper box's used width computes to 500px - 100px -> 400px;

Now we are inside the BFC established by the table wrapper box and try to resolve the table's width -> %10.
According to the normal BFC rules, it should compute to 10% of the containing block's logical width: 400px -> 40px.
However in practice it computes to 50px (10% of 500px).

Similar setup with non-table content would resolve the inner block level box's width to 40px;
<div style="display: block; width: 500px">

<div style="float: left; width: 100px;"></div>
<div style="display: block; overflow: hidden;">

<div style="display: block; width: 10%"></div>

</div>

</div>
This needs clarification.

Test: fast/layoutformattingcontext/float-avoider-available-horizontal-space3.html

  • layout/FormattingContext.h:

(WebCore::Layout::FormattingContext::isTableWrapperBlockFormattingContext const):

  • layout/blockformatting/BlockFormattingContext.cpp:

(WebCore::Layout::BlockFormattingContext::layoutInFlowContent):

  • layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContext.cpp:

(WebCore::Layout::TableWrapperBlockFormattingContext::computeWidthAndMarginForTableBox):

  • layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContext.h:

LayoutTests:

  • fast/layoutformattingcontext/float-avoider-available-horizontal-space3-expected.html: Added.
  • fast/layoutformattingcontext/float-avoider-available-horizontal-space3.html: Added.
2:13 AM Changeset in webkit [263326] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

[WPE][GTK] Specify underlying storage type for InputMethodState::Hint
https://bugs.webkit.org/show_bug.cgi?id=213401

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-06-21
Reviewed by Carlos Garcia Campos.

Using unsigned types for flags enums seems nice to do.

  • Shared/glib/InputMethodState.h:
2:11 AM Changeset in webkit [263325] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebKit

[WPE][GTK] Add autocleanup for WebKitWebsitePolicies
https://bugs.webkit.org/show_bug.cgi?id=213399

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-06-21
Reviewed by Carlos Garcia Campos.

Add missing autocleanups.

  • UIProcess/API/gtk/WebKitAutocleanups.h:
  • UIProcess/API/wpe/WebKitAutocleanups.h:

Jun 20, 2020:

11:10 PM Changeset in webkit [263324] by jiewen_tan@apple.com
  • 2 edits in trunk/Source/WebKit

[AppSSO] Should do null check on m_page in dismissViewController()
https://bugs.webkit.org/show_bug.cgi?id=213415
<rdar://problem/59672418>

Reviewed by Alexey Proskuryakov.

  • UIProcess/Cocoa/SOAuthorization/SOAuthorizationSession.mm:

(WebKit::SOAuthorizationSession::dismissViewController):

7:49 PM Changeset in webkit [263323] by jer.noble@apple.com
  • 5 edits in trunk/Source

RecoveryOS: PAL::getAVPlayerLayerClass() will crash when AVFoundation is missing
https://bugs.webkit.org/show_bug.cgi?id=213437
<rdar://problem/64563064>

Reviewed by Eric Carlson.

Check PAL::isAVFoundationAvailable() before calling PAL::getAVPlayerLayerClass();

Source/WebCore:

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

(WebCore::VideoLayerManagerObjC::setVideoLayer):

  • platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:

(WebCore::PlatformCALayerCocoa::layerTypeForPlatformLayer):
(WebCore::PlatformCALayerCocoa::PlatformCALayerCocoa):
(WebCore::PlatformCALayerCocoa::clone const):
(WebCore::PlatformCALayerCocoa::avPlayerLayer const):

Source/WebKit:

  • WebProcess/WebPage/RemoteLayerTree/PlatformCALayerRemoteCustom.mm:

(WebKit::PlatformCALayerRemoteCustom::clone const):

7:13 PM Changeset in webkit [263322] by Simon Fraser
  • 6 edits in trunk/Source/WebCore

Crash under ScrollController::startSnapRubberbandTimer() firing
https://bugs.webkit.org/show_bug.cgi?id=213439
<rdar://problem/63986013>

Reviewed by Tim Horton.

A wholesale destruction of the ScrollingTree (e.g. via ScrollingCoordinatorMac::pageDestroyed()) never
ran the code to stop CFRunLoopTimers in ScrollController, which could lead to this crash.
Fix by calling removeAllNodes() in ThreadedScrollingTree::invalidate().

Add an assertion in ScrollController's destructor that stopAllTimers() has been called, and have
ScrollAnimator's destructor call stopAllTimers() too.

  • page/scrolling/ScrollingTree.h:
  • page/scrolling/ThreadedScrollingTree.cpp:

(WebCore::ThreadedScrollingTree::invalidate):

  • platform/ScrollAnimator.cpp:

(WebCore::ScrollAnimator::~ScrollAnimator):

  • platform/cocoa/ScrollController.h:
  • platform/cocoa/ScrollController.mm:

(WebCore::ScrollController::~ScrollController):
(WebCore::ScrollController::stopAllTimers):

6:13 PM Changeset in webkit [263321] by jer.noble@apple.com
  • 4 edits in trunk

REGRESSION(r259219): Sleep assertion remains active if WKWebView is closed or WebContent process crashes
https://bugs.webkit.org/show_bug.cgi?id=213434
<rdar://problem/57541662>

Reviewed by Eric Carlson.

Source/WebKit:

Tests: TestWebKitAPI tests:

SleepDisabler.Basic
SleepDisabler.Pause
SleepDisabler.Mute
SleepDisabler.Unmute
SleepDisabler.DisableAudioTrack
SleepDisabler.Loop
SleepDisabler.ChangeSrc
SleepDisabler.Load
SleepDisabler.Unload
SleepDisabler.Navigate
SleepDisabler.NavigateBack
SleepDisabler.Reload
SleepDisabler.Close
SleepDisabler.Crash

Ensure the SleepDisablers are cleared when the WebProcess closes or crashes.

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::shutDown):
(WebKit::WebProcessProxy::processDidTerminateOrFailedToLaunch):

Tools:

  • TestWebKitAPI/Tests/WebKit/SleepDisabler.mm:

(SleepDisabler::loadPlayingPage):
(SleepDisabler::hasSleepDisablerShouldBecomeEqualTo):
(TEST_F):

4:35 PM Changeset in webkit [263320] by Brent Fulgham
  • 7 edits in trunk/Source/WebKit

[iOS, macOS] Allow access to the container manager to support Mail InjectedBundle
https://bugs.webkit.org/show_bug.cgi?id=213357
<rdar://problem/63837247>

Reviewed by Darin Adler.

The Mail Injected Bundle requires access to the container manager to support certain OS operations. We do not need
this access for web browsing, and should limit this access to this one case.

This patch creates a dynamic mach extension to the container manager for this single use case. It also denies the
non-extension access case with a backtrace so we can see if any other clients are hitting this.

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

(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):

  • Shared/WebProcessCreationParameters.h:
  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::platformInitializeWebProcess):

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):

  • WebProcess/com.apple.WebProcess.sb.in:
4:16 PM Changeset in webkit [263319] by Jonathan Bedard
  • 2 edits in trunk/Tools

Bring up watchOS/tvOS on build.webkit.org (Follow-up fix x2)
https://bugs.webkit.org/show_bug.cgi?id=213402
<rdar://problem/64542588>

Unreviewed test fix.

  • Scripts/webkitperl/webkitdirs_unittest/extractNonMacOSHostConfiguration.pl: Native Macs never

use 32 bit tool binaries.

8:24 AM Changeset in webkit [263318] by Alan Bujtas
  • 9 edits
    1 copy
    4 adds in trunk

[LFC][TFC][Quirk] Table height needs quirk handling
https://bugs.webkit.org/show_bug.cgi?id=213430

Reviewed by Antti Koivisto.

Source/WebCore:

In quirks mode the used table height of an empty table is 0, while in standards mode
we take the specified value into account and size the table accordingly.

Tests: fast/layoutformattingcontext/empty-table-with-specified-height-quirk-simple.html

fast/layoutformattingcontext/empty-table-with-specified-height-standards-simple.html

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • layout/FormattingContext.h:
  • layout/blockformatting/BlockFormattingContext.h:

(WebCore::Layout::BlockFormattingContext::Quirks::geometry const):

  • layout/blockformatting/BlockFormattingContextQuirks.cpp:

(WebCore::Layout::BlockFormattingContext::Quirks::stretchedInFlowHeight):

  • layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContext.cpp:

(WebCore::Layout::TableWrapperBlockFormattingContext::computeHeightAndMarginForTableBox):

  • layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContext.h:

(WebCore::Layout::TableWrapperBlockFormattingContext::Quirks::Quirks):

  • layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContextQuirks.cpp: Copied from Source/WebCore/layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContext.h.

(WebCore::Layout::TableWrapperBlockFormattingContext::Quirks::usedTableHeight const):

LayoutTests:

  • fast/layoutformattingcontext/empty-table-with-specified-height-quirk-simple-expected.html: Added.
  • fast/layoutformattingcontext/empty-table-with-specified-height-quirk-simple.html: Added.
  • fast/layoutformattingcontext/empty-table-with-specified-height-standards-simple-expected.html: Added.
  • fast/layoutformattingcontext/empty-table-with-specified-height-standards-simple.html: Added.
12:08 AM Changeset in webkit [263317] by Wenson Hsieh
  • 4 edits in trunk/LayoutTests

[Windows] fast/forms/search-field-buttons-do-not-have-focus-rings.html is failing
https://bugs.webkit.org/show_bug.cgi?id=213422

Reviewed by Tim Horton.

Refactor this test so that it doesn't attempt to hard-code the position and sizes of the search field buttons.
To do this, we use an internal helper to grab the div elements that correspond to the results and cancel
buttons, and then use their bounding rects to place the opaque divs to cover these buttons.

  • fast/forms/search-field-buttons-do-not-have-focus-rings-expected.html:
  • fast/forms/search-field-buttons-do-not-have-focus-rings.html:
  • platform/win/TestExpectations:

Jun 19, 2020:

9:20 PM Changeset in webkit [263316] by ysuzuki@apple.com
  • 11 edits
    1 add in trunk

[JSC] Check Gigacage usage before launching VM
https://bugs.webkit.org/show_bug.cgi?id=213410

Reviewed by Mark Lam.

JSTests:

  • stress/exhaust-gigacage-and-allocate-vm.js: Added.

(foo):

Source/bmalloc:

Add Gigacage::footprint and Gigacage::size functions to expose usage to API users.
Rename Gigacage::size to Gigacage::maxSize.

  • bmalloc/Gigacage.cpp:

(Gigacage::ensureGigacage):
(Gigacage::size):
(Gigacage::footprint):

  • bmalloc/Gigacage.h:

(Gigacage::maxSize):
(Gigacage::alignment):
(Gigacage::mask):
(Gigacage::size):
(Gigacage::footprint):

  • bmalloc/Heap.cpp:

(bmalloc::Heap::gigacageSize):

  • bmalloc/Heap.h:

Source/JavaScriptCore:

Since VM allocates JSBigInt from Gigacage, it is possible that VM creation fails when Gigacage is exhausted.
As a work-around for internal testing, we insert ad-hoc Gigacage usage check before launching a new agent.
If 80% of Gigacage is used, we fail to launch a new VM gracefully.

  • assembler/testmasm.cpp:

(JSC::testCagePreservesPACFailureBit):

  • jsc.cpp:

(functionDollarAgentStart):

Source/WTF:

  • wtf/Gigacage.h:

(Gigacage::footprint):
(Gigacage::maxSize):
(Gigacage::size):

9:06 PM Changeset in webkit [263315] by commit-queue@webkit.org
  • 2 edits
    1 add in trunk

Typed array constructor behaves differently when length is not passed or when undefined is passed
https://bugs.webkit.org/show_bug.cgi?id=184232

Patch by James Darpinian <James Darpinian> on 2020-06-19
Reviewed by Yusuke Suzuki.

Passing undefined for length should have the same effect as omitting the argument. It was being
treated as 0 instead.

  • runtime/JSGenericTypedArrayViewConstructorInlines.h:

(JSC::constructGenericTypedArrayView):

9:02 PM Changeset in webkit [263314] by mmaxfield@apple.com
  • 8 edits
    12 adds in trunk/LayoutTests

fast/text/international/system-language/navigator-language/navigator-language tests are failing on Catalina and iOS
<rdar://problem/64468227>

Unreviewed test gardening.

Rather than marking the tests as flakey, we can just commit -expected results for every OS.

  • fast/text/international/system-language/navigator-language/navigator-language-en-US-expected.txt:
  • fast/text/international/system-language/navigator-language/navigator-language-es-ES-expected.txt:
  • fast/text/international/system-language/navigator-language/navigator-language-es-MX-expected.txt:
  • fast/text/international/system-language/navigator-language/navigator-language-pt-BR-expected.txt:
  • fast/text/international/system-language/navigator-language/navigator-language-zh-Hant-expected.txt:
  • platform/ios/TestExpectations:
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-en-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-es-419-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-es-MX-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-es-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-fr-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-hi-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-ja-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-ru-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-zh-HK-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-zh-Hant-HK-expected.txt: Added.
  • platform/mac-mojave/fast/text/international/system-language/navigator-language/navigator-language-zh-Hant-expected.txt: Added.
  • platform/mac/TestExpectations:
8:50 PM Changeset in webkit [263313] by Chris Dumez
  • 15 edits in trunk/Source

[Cocoa] Delay issuing ManagedSession & Network Extension sandbox extensions until a load is actually issued
https://bugs.webkit.org/show_bug.cgi?id=213414
<rdar://problem/64548684>

Reviewed by Per Arne Vollan.

Source/WebCore:

setHasConsumedSandboxExtensions() can now get called several times, every time a WebPage is created.
Once a sandbox extension has been consumed, there is no going back so return early if the state is
already "Consumed".

  • platform/cocoa/NetworkExtensionContentFilter.mm:

(WebCore::NetworkExtensionContentFilter::setHasConsumedSandboxExtensions):

  • platform/cocoa/ParentalControlsContentFilter.mm:

(WebCore::ParentalControlsContentFilter::setHasConsumedSandboxExtension):

Source/WebKit:

Delay issuing ManagedSession & Network Extension sandbox extensions until a load is actually issued.
This is a Safari launch time optimization since the checks needed to decide whether or not to issue
the extensions are expensive and there is no reason to issue them as soon as the process launches
(especially in the case of a prewarmed process).

  • Shared/Cocoa/LoadParametersCocoa.mm:

(WebKit::LoadParameters::platformEncode const):
(WebKit::LoadParameters::platformDecode):

  • Shared/LoadParameters.h:
  • Shared/WebProcessCreationParameters.cpp:

(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):

  • Shared/WebProcessCreationParameters.h:
  • UIProcess/Cocoa/WebPageProxyCocoa.mm:

(WebKit::WebPageProxy::addPlatformLoadParameters):

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::platformInitializeWebProcess):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::addPlatformLoadParameters):
(WebKit::WebPageProxy::loadRequestWithNavigationShared):
(WebKit::WebPageProxy::loadFile):
(WebKit::WebPageProxy::loadDataWithNavigationShared):
(WebKit::WebPageProxy::loadAlternateHTML):
(WebKit::WebPageProxy::loadWebArchiveData):

  • UIProcess/WebPageProxy.h:
  • UIProcess/WebProcessProxy.h:

(WebKit::WebProcessProxy::hasNetworkExtensionSandboxAccess const):
(WebKit::WebProcessProxy::markHasNetworkExtensionSandboxAccess):
(WebKit::WebProcessProxy::hasManagedSessionSandboxAccess const):
(WebKit::WebProcessProxy::markHasManagedSessionSandboxAccess):

  • WebProcess/WebPage/Cocoa/WebPageCocoa.mm:

(WebKit::WebPage::platformDidReceiveLoadParameters):

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):

8:17 PM Changeset in webkit [263312] by ysuzuki@apple.com
  • 15 edits in trunk

[JSC] Attempt to reduce timeout failures on Apple Watch Series 3
https://bugs.webkit.org/show_bug.cgi?id=213419

Reviewed by Mark Lam.

JSTests:

Look into timeout tests, and

  1. If the test is using too many iterations, decrease the count.
  2. If the test is still useful while iteration count is not so much, try attaching slow! to see the effect on the bot.
  • stress/memcpy-typed-loops.js:
  • stress/op_bitand.js:
  • stress/op_bitor.js:
  • stress/op_bitxor.js:
  • stress/op_mul-ConstVar.js:
  • stress/op_mul-VarConst.js:
  • stress/op_mul-VarVar.js:
  • stress/op_sub-ConstVar.js:
  • stress/op_sub-VarConst.js:
  • stress/op_sub-VarVar.js:
  • stress/set-iteration-oas.js:
  • stress/value-to-boolean.js:

Source/JavaScriptCore:

  • tools/JSDollarVM.cpp:

(JSC::functionUseJIT):
(JSC::JSDollarVM::finishCreation):

7:44 PM Changeset in webkit [263311] by Alan Bujtas
  • 8 edits
    2 adds in trunk

[AutoSizing] Resolve viewport units against the preferred content size
https://bugs.webkit.org/show_bug.cgi?id=213408
<rdar://problem/64267539>

Reviewed by Tim Horton.

Source/WebCore:

Instead of resolving the viewport units against the maximum content size constraints, let's use the preferred content size.
It ensures that content with vw, vh units does not grow beyond the preferred content size.

Test: fast/dynamic/size-to-content-autosize-with-viewport-units.html

  • page/FrameView.cpp:

(WebCore::FrameView::performSizeToContentAutoSize):
(WebCore::FrameView::enableAutoSizeMode): Let's "ignore" viewport units during the initial
pass and use the preferred width to finalize the vw vh unit values (we don't really ignore them, but they are resolved against a [ 1, 1 ] viewport).
This approach fails if the main content has 100vw with overflow hidden. Such content would end up with a [ 1, 1 ] size (we might want to detect it
and resolved the values against the horizontal constraint).
(WebCore::FrameView::overrideViewportWidthForCSSViewportUnits):
(WebCore::FrameView::resetOverriddenViewportWidthForCSSViewportUnits):

  • page/FrameView.h:
  • testing/Internals.cpp:

(WebCore::Internals::enableSizeToContentAutoSizeMode):

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

LayoutTests:

  • fast/dynamic/size-to-content-autosize-with-viewport-units-expected.txt: Added.
  • fast/dynamic/size-to-content-autosize-with-viewport-units.html: Added.
7:37 PM Changeset in webkit [263310] by Jonathan Bedard
  • 5 edits in trunk/Tools

Bring up watchOS/tvOS on build.webkit.org (Follow-up fix)
https://bugs.webkit.org/show_bug.cgi?id=213402
<rdar://problem/64542588>

Unreviewed build-fix.

  • BuildSlaveSupport/build.webkit.org-config/config.json: Use arm64_32 to build watchOS device.
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/WebKitBuildbot.js:

(WebKitBuildbot): watchOS device should be considered 32 bit.

  • Scripts/configure-xcode-for-embedded-development: Force-copy MediaAccessibility.framework.
  • Scripts/webkitdirs.pm:

(extractNonMacOSHostConfiguration): Native Macs never use 32 bit tool binaries.

7:26 PM Changeset in webkit [263309] by Wenson Hsieh
  • 4 edits in trunk/Source/WebCore

[macOS] Move progress bar painting code off of Carbon API
https://bugs.webkit.org/show_bug.cgi?id=213405
<rdar://problem/63958537>

Reviewed by Tim Horton.

Source/WebCore:

Adopts CoreUI constants and AppKit SPI (-[NSAppearance _drawInRect:context:options:]) when painting progress
elements. This is being done in light of recent changes around how HIThemeDrawTrack draws progress bars on
recent versions of macOS; it has been recommended to us that we move away from using Carbon, and instead use
AppKit.

  • rendering/RenderThemeMac.mm:

(WebCore::RenderThemeMac::paintProgressBar):

The NSControlSize to CUISize mapping here looks counterintuitive, but matches our current behavior. This is
because kThemeLargeProgressBar and kThemeLargeIndeterminateBar both map to kCUISizeRegular, while
kThemeMediumIndeterminateBar and kThemeMediumProgressBar map to kCUISizeSmall.

Source/WebCore/PAL:

Add forward declarations for CoreUI SPI on non-internal SDKs.

  • pal/spi/mac/CoreUISPI.h:
6:22 PM Changeset in webkit [263308] by aakash_jain@apple.com
  • 5 edits
    3 deletes in trunk/Tools

Delete dead code for old ews api tests
https://bugs.webkit.org/show_bug.cgi?id=213421

Rubber-stamped by Alexey Proskuryakov.

  • Scripts/webkitpy/common/config/ports.py:

(DeprecatedPort.run_api_tests_command): Deleted.

  • Scripts/webkitpy/common/net/apitestresults.py: Removed.
  • Scripts/webkitpy/common/net/apitestresults_unittest.py: Removed.
  • Scripts/webkitpy/port/base.py:

(Port.bindings_results_directory):
(Port.api_results_directory): Deleted.

  • Scripts/webkitpy/tool/bot/apitestresultsreader.py: Removed.
  • Scripts/webkitpy/tool/steps/runtests.py:

(RunTests._run_api_tests): Deleted.

  • Scripts/webkitpy/tool/steps/steps_unittest.py:

(test_runtests_api_debug): Deleted.

6:07 PM Changeset in webkit [263307] by Ryan Haddad
  • 7 edits in trunk/Source/WebKit

Unreviewed, reverting r263287.

Caused tests to exit early with crashes on Catalina.

Reverted changeset:

"[iOS, macOS] Allow access to the container manager to support Mail InjectedBundle"
https://bugs.webkit.org/show_bug.cgi?id=213357
https://trac.webkit.org/changeset/263287

6:04 PM Changeset in webkit [263306] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Crash under WebKit::ProcessAndUIAssertion::updateRunInBackgroundCount()
https://bugs.webkit.org/show_bug.cgi?id=213417
<rdar://problem/63477676>

Reviewed by Darin Adler.

Make sure |this| is still alive in ProcessAndUIAssertion::processAssertionWasInvalidated()
after calling ProcessAssertion::processAssertionWasInvalidated() and before calling
updateRunInBackgroundCount(). Calling ProcessAssertion::processAssertionWasInvalidated()
notifies the client and the client may destroy the assertion as a result.

  • UIProcess/ios/ProcessAssertionIOS.mm:

(WebKit::ProcessAndUIAssertion::processAssertionWasInvalidated):

5:57 PM Changeset in webkit [263305] by Wenson Hsieh
  • 2 edits in trunk/LayoutTests

Unreviewed test gardening on Windows

Mark a test as failing while it's being investigated.

  • platform/win/TestExpectations:
5:53 PM Changeset in webkit [263304] by commit-queue@webkit.org
  • 6 edits in trunk

Remove setVelocity() from PannerNode
https://bugs.webkit.org/show_bug.cgi?id=213360

Patch by Clark Wang <clark_wang@apple.com> on 2020-06-19
Reviewed by Chris Dumez.

LayoutTests/imported/w3c:

Re-baselined previous test that now passes with velocity removed.

  • web-platform-tests/webaudio/historical-expected.txt:

Source/WebCore:

Removed setVelocity() and other velocity dependencies, as per spec: https://www.w3.org/TR/webaudio/#pannernode.
Simplified dopplerRate, since sourceVelocity is always zero.

Re-baselined previous test that now passes with velocity removed.

  • Modules/webaudio/PannerNode.cpp:

(WebCore::PannerNode::PannerNode):
(WebCore::PannerNode::dopplerRate):

  • Modules/webaudio/PannerNode.h:
  • Modules/webaudio/PannerNode.idl:
5:43 PM Changeset in webkit [263303] by Wenson Hsieh
  • 3 edits
    2 adds in trunk

REGRESSION (r263253): Search field results and cancel buttons have their own focus rings
https://bugs.webkit.org/show_bug.cgi?id=213413
<rdar://problem/64548419>

Reviewed by Tim Horton.

Source/WebCore:

After r263253, paintCellAndSetFocusedElementNeedsRepaintIfNecessary is used when painting the buttons in a
search field's shadow root. However, the renderer that is passed in (which is used to determine whether we
should additionally draw focus rings) is the input element's renderer rather than the renderers of the results
and cancel buttons themselves. This means that when the search field is focused, we will draw focus rings around
each of the buttons in the shadow root as well.

Address this by using box (the buttons' RenderBoxes) instead.

Test: fast/forms/search-field-buttons-do-not-have-focus-rings.html

  • rendering/RenderThemeMac.mm:

(WebCore::RenderThemeMac::paintSearchFieldCancelButton):
(WebCore::RenderThemeMac::paintSearchFieldResultsButton):

LayoutTests:

Add a ref test to verify that the search and cancel buttons don't draw individual focus rings. This test works
by verifying that no focus ring around either the cancel or results button bleeds outside of the bounds of a div
that obscures the buttons.

  • fast/forms/search-field-buttons-do-not-have-focus-rings-expected.html: Added.
  • fast/forms/search-field-buttons-do-not-have-focus-rings.html: Added.
5:16 PM Changeset in webkit [263302] by commit-queue@webkit.org
  • 7 edits in trunk

Crash in WebCore::Range::borderAndTextRects
https://bugs.webkit.org/show_bug.cgi?id=209379

Patch by Pinki Gyanchandani <pgyanchandani@apple.com> on 2020-06-19
Reviewed by Darin Adler.

When a parentless node is moved to a new document, then all ranges associated with this node and its children also should
be updated with new document information.

Test woould be submitted later.

  • dom/Document.cpp:

(WebCore::Document::parentlessNodeMoveToNewDocument):

  • dom/Document.h:
  • dom/Node.cpp:

(WebCore::Node::moveNodeToNewDocument):

  • dom/Range.cpp:

(WebCore::Range::parentlessNodeMoveToNewDocumentAffectsRange):
(WebCore::Range::updateRangeForParentlessNodeMoveToNewDocument):

  • dom/Range.h:
5:11 PM Changeset in webkit [263301] by Truitt Savell
  • 7 edits
    2 deletes in trunk

Unreviewed, reverting r263121.

Broke media/video-fullscreen-only-playback.html on Catalina
Debug

Reverted changeset:

"Don't claim to support fullscreen mode unless
fullScreenEnabled setting is enabled"
https://bugs.webkit.org/show_bug.cgi?id=213142
https://trac.webkit.org/changeset/263121

5:07 PM Changeset in webkit [263300] by Jonathan Bedard
  • 3 edits in trunk/Tools

Bring up watchOS/tvOS on build.webkit.org
https://bugs.webkit.org/show_bug.cgi?id=213402
<rdar://problem/64542588>

Unreviewed infrastructure fix.

  • BuildSlaveSupport/build.webkit.org-config/wkbuild.py:

(_should_file_trigger_build): Add tvOS and watchOS.

  • BuildSlaveSupport/build.webkit.org-config/wkbuild_unittest.py:

(ShouldBuildTest):
(ShouldBuildTest.test_should_build):

5:07 PM Changeset in webkit [263299] by Truitt Savell
  • 2 edits in trunk/Source/WTF

Unreviewed, reverting r263223.

Broke compositing/video/video-border-radius-clipping.html on
Mac release wk1

Reverted changeset:

"Unreviewed, re-landing r262904."
https://bugs.webkit.org/show_bug.cgi?id=213063
https://trac.webkit.org/changeset/263223

5:02 PM Changeset in webkit [263298] by Kate Cheney
  • 6 edits in trunk/Source/WebKit

com.apple.WebKit.Networking crash: suspended with locked system files (observations.db)
https://bugs.webkit.org/show_bug.cgi?id=213391
<rdar://problem/64494167>

Reviewed by Chris Dumez.

ITP is the only database that attempts to close when
NetworkProcess::didClose() is called. This causes the network process
to sometimes crash if the database is still closing when checking for
locked system files. Instead, we should only flush the
memory store to disk when calling NetworkProcess::didClose (in the
memory store case), and only close the database when the network session is destroyed.

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::didDestroyNetworkSession):
(WebKit::WebResourceLoadStatisticsStore::destroyResourceLoadStatisticsStore):
(WebKit::WebResourceLoadStatisticsStore::flushAndDestroyPersistentStore):

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h:

Split into two functions, one to flush and destroy the persistent
store, and one to destroy the memory or database store.

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::didClose):
Only flush the persistent store here, as described above.

  • NetworkProcess/NetworkSession.cpp:

(WebKit::NetworkSession::flushAndDestroyPersistentStore):

  • NetworkProcess/NetworkSession.h:
5:00 PM Changeset in webkit [263297] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

[CG] REGRESSION (r256892): Luminance SVG mask is not applied when accelerated drawing is enabled
https://bugs.webkit.org/show_bug.cgi?id=213403
<rdar://problem/64489419>

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2020-06-19
Reviewed by Simon Fraser.

Source/WebCore:

Test: svg/masking/mask-css-luminance.html

If the ImageBuffer is backed by an IOSurface, its context has to be flushed
out before convertToLuminanceMask() can access its data.

  • platform/graphics/ConcreteImageBuffer.h:

LayoutTests:

  • svg/masking/mask-css-luminance-expected.html: Added.
  • svg/masking/mask-css-luminance.html: Added.
4:40 PM Changeset in webkit [263296] by jiewen_tan@apple.com
  • 7 edits
    1 add in trunk

[WebAuthn] Provide a _WKWebAuthenticationPanelUpdatePINInvalid update to UI clients if the returned PIN from the client is not valid
https://bugs.webkit.org/show_bug.cgi?id=213404
<rdar://problem/64543894>

Reviewed by Brent Fulgham.

Source/WebKit:

Provide a _WKWebAuthenticationPanelUpdatePINInvalid update to UI clients if the returned PIN from the client is not valid such that clients can
reuse the same logic to handle invalid pin from the authenticator. This change makes their life easier.

Covered by API tests.

  • UIProcess/API/APIWebAuthenticationPanelClient.h:

(API::WebAuthenticationPanelClient::requestPin const):

  • UIProcess/WebAuthentication/Cocoa/WebAuthenticationPanelClient.mm:

(WebKit::WebAuthenticationPanelClient::requestPin const):
Now, only null strings are intepreted as cancels.

  • UIProcess/WebAuthentication/fido/CtapAuthenticator.cpp:

(WebKit::CtapAuthenticator::continueMakeCredentialAfterResponseReceived):
(WebKit::CtapAuthenticator::continueGetAssertionAfterResponseReceived):
(WebKit::CtapAuthenticator::continueGetPinTokenAfterRequestPin):
(WebKit::CtapAuthenticator::continueRequestAfterGetPinToken):
This patch also removes potential null pointer dereferences.

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKitCocoa/_WKWebAuthenticationPanel.mm:

(TestWebKitAPI::TEST):

  • TestWebKitAPI/Tests/WebKitCocoa/web-authentication-make-credential-hid-pin-get-pin-token-fake-pin-invalid-error-retry.html: Added.
4:37 PM Changeset in webkit [263295] by pvollan@apple.com
  • 10 edits in trunk/Source

[macOS] Connections to the preference daemon are established before entering the sandbox
https://bugs.webkit.org/show_bug.cgi?id=213379

Reviewed by Darin Adler.

Source/WebCore/PAL:

Use correct parameter types in _CFPrefsSetDirectModeEnabled and _CFPrefsSetReadOnly, and move
_CFPrefsSetDirectModeEnabled inside an Objective-C guard, since BOOL only seems to be a builtin
type in Objective-C.

  • pal/spi/cf/CFUtilitiesSPI.h:

Source/WebKit:

On macOS, connections to the preference daemon are established before entering the sandbox. These connections also persist
after entering the sandbox and denying access to the preference daemon. There should not be attempts to connect to the
preference daemon before entering the sandbox, since these attempts will not be stopped by the sandbox. This patch moves
code that connects to the preference daemon to be executed after the sandbox has been entered. That includes code to
prevent connections to the Dock and code to initialize WebKit logging. Also, instead of calling [NSBundle bundleForClass:],
call [NSBundle bundleWithIdentifier:], since calling [NSBundle bundleForClass:] will connect to the preference daemon.
Finally, allow the syscall SYS_gethostuuid, since that is needed by CoreFoundation when there is no access to the
preference daemon.

No new tests. This should be covered by existing tests. It would be nice to have a test to make sure that there are no
connections to the preference daemon just before entering the sandbox, but I am not aware of how to implement this.

  • NetworkProcess/mac/NetworkProcessMac.mm:

(WebKit::NetworkProcess::initializeSandbox):

  • Shared/AuxiliaryProcess.cpp:

(WebKit::AuxiliaryProcess::initialize):

  • Shared/Cocoa/WebKit2InitializeCocoa.mm:

(WebKit::runInitializationCode):

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

(WebKit::XPCServiceMain):

  • Shared/mac/AuxiliaryProcessMac.mm:

(WebKit::webKit2Bundle):

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):
(WebKit::WebProcess::initializeSandbox):

  • WebProcess/com.apple.WebProcess.sb.in:
4:12 PM Changeset in webkit [263294] by Alan Coon
  • 1 copy in tags/Safari-610.1.17.1

Tag Safari-610.1.17.1.

3:50 PM Changeset in webkit [263293] by Chris Dumez
  • 5 edits in trunk/Source

Avoid initializing RenderTheme singleton unnecessarily in the UIProcess
https://bugs.webkit.org/show_bug.cgi?id=213406

Reviewed by Per Arne Vollan.

Avoid initializing RenderTheme singleton unnecessarily in the UIProcess. Instead, introduce
a static function to get the focus ring color on iOS.

Source/WebCore:

  • rendering/RenderThemeIOS.h:
  • rendering/RenderThemeIOS.mm:

(WebCore::RenderThemeIOS::systemFocusRingColor):
(WebCore::RenderThemeIOS::platformFocusRingColor const):

Source/WebKit:

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::platformInitializeWebProcess):

3:40 PM Changeset in webkit [263292] by mark.lam@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

toString of String doesn't check integrity of structureID in one path.
https://bugs.webkit.org/show_bug.cgi?id=213338

Reviewed by Saam Barati.

  • runtime/StringPrototype.cpp:

(JSC::stringProtoFuncToString):

3:22 PM Changeset in webkit [263291] by Jonathan Bedard
  • 8 edits
    8 adds in trunk/Tools

Bring up watchOS/tvOS on build.webkit.org
https://bugs.webkit.org/show_bug.cgi?id=213402
<rdar://problem/64542588>

Reviewed by Aakash Jain.

  • BuildSlaveSupport/build.webkit.org-config/config.json: Add AppleTV and watchOS builders.
  • BuildSlaveSupport/build.webkit.org-config/factories.py:

(BuildFactory.init): Support AppleTV and watchOS.

  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/TvOS13.png: Added.
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/TvOS13@2x.png: Added.
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/TvOS13Simulator.png: Added.
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/TvOS13Simulator@2x.png: Added.
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/WatchOS6.png: Added.
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/WatchOS6@2x.png: Added.
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/WatchOSSimulator6.png: Added.
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Images/WatchOSSimulator6@2x.png: Added.
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/Dashboard.js:
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Scripts/WebKitBuildbot.js:
  • BuildSlaveSupport/build.webkit.org-config/public_html/dashboard/Styles/Main.css:
  • BuildSlaveSupport/build.webkit.org-config/steps.py:
  • BuildSlaveSupport/build.webkit.org-config/steps_unittest.py:
3:13 PM Changeset in webkit [263290] by sbarati@apple.com
  • 6 edits in trunk

Have a memory monitor thread in jsc shell when running tests using --memory-limited
https://bugs.webkit.org/show_bug.cgi?id=213389

Reviewed by Mark Lam.

Source/JavaScriptCore:

When testing on iOS, there are times high memory usage from a JSC test
will jetsam our entire test runner. This makes it so we don't get any test
results from that test run, which can make it difficult to track testing
results.

This patch introduces an optional memory monitoring thread to the JSC
shell. It's a best effort approach. If memory usage exceeds the passed
in threshold, we crash the process. Similar to how the timeout mechanism
works. On Cocoa platforms, we also perform this check in the low memory
warning handler.

Currently, we use this feature when running JSC stress tests in
"--memory-limited" mode.

  • jsc.cpp:

(crashIfExceedingMemoryLimit):
(startMemoryMonitoringThreadIfNeeded):
(jscmain):

Tools:

  • Scripts/run-jsc-stress-tests:
  • Scripts/webkitruby/jsc-stress-test-writer-default.rb:
  • Scripts/webkitruby/jsc-stress-test-writer-ruby.rb:
2:43 PM Changeset in webkit [263289] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Unreviewed build fix after r263288.

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::platformInitializeWebProcess):

2:31 PM Changeset in webkit [263288] by Chris Dumez
  • 9 edits in trunk/Source/WebKit

Use ASCIILiteral more for SandboxExtension functions
https://bugs.webkit.org/show_bug.cgi?id=213400

Reviewed by Per Arne Vollan.

Use ASCIILiteral more for SandboxExtension functions. Functions like createHandleForMachLookup() / createHandleForIOKitClassExtension()
don't need to take in Strings, ASCIILiteral is enough.

  • Shared/Cocoa/SandboxExtensionCocoa.mm:

(WebKit::createHandlesForResources):
(WebKit::SandboxExtension::createReadOnlyHandlesForFiles):
(WebKit::SandboxExtension::createHandleForGenericExtension):
(WebKit::SandboxExtension::createHandleForMachLookup):
(WebKit::SandboxExtension::createHandlesForMachLookup):
(WebKit::SandboxExtension::createHandleForIOKitClassExtension):
(WebKit::SandboxExtension::createHandlesForIOKitClassExtensions):

  • Shared/SandboxExtension.h:
  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::mediaRelatedMachServices):
(WebKit::nonBrowserServices):
(WebKit::diagnosticServices):
(WebKit::agxCompilerClasses):
(WebKit::WebProcessPool::platformInitializeWebProcess):

  • UIProcess/Cocoa/WebProcessProxyCocoa.mm:

(WebKit::WebProcessProxy::enableRemoteInspectorIfNeeded):

  • UIProcess/GPU/GPUProcessProxy.cpp:

(WebKit::GPUProcessProxy::singleton):

  • UIProcess/UserMediaPermissionRequestManagerProxy.cpp:

(WebKit::UserMediaPermissionRequestManagerProxy::finishGrantingRequest):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::didChooseFilesForOpenPanelWithDisplayStringAndIcon):
(WebKit::WebPageProxy::creationParameters):

  • UIProcess/ios/WebPageProxyIOS.mm:

(WebKit::WebPageProxy::grantAccessToAssetServices):

2:12 PM Changeset in webkit [263287] by Brent Fulgham
  • 7 edits in trunk/Source/WebKit

[iOS, macOS] Allow access to the container manager to support Mail InjectedBundle
https://bugs.webkit.org/show_bug.cgi?id=213357
<rdar://problem/63837247>

Reviewed by Darin Adler.

The Mail Injected Bundle requires access to the container manager to support certain OS operations. We do not need
this access for web browsing, and should limit this access to this one case.

This patch creates a dynamic mach extension to the container manager for this single use case. It also denies the
non-extension access case with a backtrace so we can see if any other clients are hitting this.

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

(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):

  • Shared/WebProcessCreationParameters.h:
  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::platformInitializeWebProcess):

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):

  • WebProcess/com.apple.WebProcess.sb.in:
2:08 PM Changeset in webkit [263286] by Alan Coon
  • 1 copy in tags/Safari-609.3.5.0.1

Tag Safari-609.3.5.0.1.

2:03 PM Changeset in webkit [263285] by Andres Gonzalez
  • 4 edits in trunk/Source

AX: web process crash in AXObjectCache::postNotification.
https://bugs.webkit.org/show_bug.cgi?id=213398

Reviewed by Chris Fleizach.

AXObjectCache was being instantiated on the AX secondary thread.
Therefore the timers for the different delayed notifications where
initialized with the secondary thread. When postNotification was triggered
on the main thread as it should, and the timer was accessed, the timer
would assert/crash for being accessed in a thread different than where
it was created. This change guaranties that AXObjectCache is always
created on the main thread.

Source/WebCore:

  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::enableAccessibility):
(WebCore::AXObjectCache::AXObjectCache):
(WebCore::AXObjectCache::postNotification):

Source/WebKit:

  • WebProcess/WebPage/mac/WKAccessibilityWebPageObjectBase.mm:

(-[WKAccessibilityWebPageObjectBase axObjectCache]):
(-[WKAccessibilityWebPageObjectBase accessibilityPluginObject]):
(-[WKAccessibilityWebPageObjectBase accessibilityRootObjectWrapper]):
(-[WKAccessibilityWebPageObjectBase setWebPage:]):
(-[WKAccessibilityWebPageObjectBase setHasMainFramePlugin:]):
(-[WKAccessibilityWebPageObjectBase setRemoteParent:]):

2:03 PM Changeset in webkit [263284] by Jonathan Bedard
  • 5 edits in trunk/Source/ThirdParty/ANGLE

[ANGLE] Correct Catalyst guards
https://bugs.webkit.org/show_bug.cgi?id=211410
<rdar://problem/62891185>

Reviewed by Dean Jackson.

  • src/libANGLE/renderer/gl/eagl/DeviceEAGL.cpp: Do not compile on Mac.
  • src/libANGLE/renderer/gl/eagl/DeviceEAGL.h: Definitions should not be available on Mac.
  • src/libANGLE/renderer/gl/eagl/DisplayEAGL.h: Definitions should not be available on Mac.
  • src/libANGLE/renderer/gl/eagl/DisplayEAGL.mm: Do not compile on Mac.
2:00 PM Changeset in webkit [263283] by mark.lam@apple.com
  • 3 edits
    1 add in trunk

Make $vm properties non-configurable, non-enumerable, and non-writable.
https://bugs.webkit.org/show_bug.cgi?id=213395

Reviewed by Saam Barati and Yusuke Suzuki.

JSTests:

  • stress/dollarVM-properties-should-not-be-enumerable.js: Added.

Source/JavaScriptCore:

$vm provides functions for test development and VM debugging. There's no reason
for them to be configurable, enumerable, and writable.

We particularly don't want them to be enumerable as this can trip up some fuzzers.
Fuzzers should not be fuzzing the $vm object which doesn't exist in real world
uses of JavaScriptCore.

  • tools/JSDollarVM.cpp:

(JSC::JSDollarVM::finishCreation):
(JSC::JSDollarVM::addFunction):
(JSC::JSDollarVM::addConstructibleFunction):

1:13 PM Changeset in webkit [263282] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

[iOS] RenderThemeIOS::cssValueToSystemColorMap() does an unnecessary linear search under systemColorFromCSSValueID()
https://bugs.webkit.org/show_bug.cgi?id=213396

Reviewed by Timothy Hatcher.

RenderThemeIOS::cssValueToSystemColorMap() does an unnecessary linear search under systemColorFromCSSValueID().
cssValueToSystemColorMap() already has the selector, yet it passes a CSSValueID to systemColorFromCSSValueID() which
then does a linear search to match the CSSValueID to a selector. This was very inefficient / unfortunate.

This patch introduces a systemColorFromCSSValueIDSelector() which takes in a selector instead of a CSSValueID. I have
also moved the constructor of the LocalCurrentTraitCollection variable to the call site so that we don't keep
constructing / destroying it for each loop iteration. The traces show us spending a lot of time in its constructor /
destructor.

  • rendering/RenderThemeIOS.mm:

(WebCore::systemColorFromCSSValueIDSelector):
(WebCore::RenderThemeIOS::cssValueToSystemColorMap):

12:59 PM Changeset in webkit [263281] by commit-queue@webkit.org
  • 33 edits in trunk

[WebGL2] Uniform Buffer Objects
https://bugs.webkit.org/show_bug.cgi?id=209518

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

All uniform buffer object conformance tests pass.

Implemented Uniform Buffer Object related functions:
bindBufferBase, bindBufferRange, getUniformIndices, getActiveUniforms, getUniformBlockIndex,
getActiveUniformBlockParameter, getActiveUniformBlockName, uniformBlockBinding

Additionally, fixed many tangentially related issues:
getIntegeri_v and getInteger64i_v were not present.
drawArraysInstances and drawElementsInstanced did not work for WebGL 2.
drawRangeElements was not implemented.
WebGLAny did not support Vector<unsigned>, so Uint32Arrays could not be returned from WebGL functions.
The maximum uniform location length was wrong for WebGL 2.
Transform feedback indexed binding points weren't being tracked.
Some functions in ExtensionsGLANGLE didn't call makeContextCurrent.
New WebGL 2 buffer usage types COPY and READ weren't supported in bufferData.
pause/resumeTransformFeedback were unimplemented.
getParameter(READ_BUFFER) was unimplemented.
readBuffer conformance test was incorrect.

  • bindings/js/JSDOMConvertWebGL.cpp:

(WebCore::convertToJSValue):

  • html/canvas/WebGL2RenderingContext.cpp:

(WebCore::WebGL2RenderingContext::~WebGL2RenderingContext):
(WebCore::WebGL2RenderingContext::initializeNewContext):
(WebCore::WebGL2RenderingContext::drawRangeElements):
(WebCore::WebGL2RenderingContext::setIndexedBufferBinding):
(WebCore::WebGL2RenderingContext::bindBufferBase):
(WebCore::WebGL2RenderingContext::bindBufferRange):
(WebCore::WebGL2RenderingContext::getIndexedParameter):
(WebCore::WebGL2RenderingContext::getUniformIndices):
(WebCore::WebGL2RenderingContext::getActiveUniforms):
(WebCore::WebGL2RenderingContext::getUniformBlockIndex):
(WebCore::WebGL2RenderingContext::getActiveUniformBlockParameter):
(WebCore::WebGL2RenderingContext::getActiveUniformBlockName):
(WebCore::WebGL2RenderingContext::uniformBlockBinding):

  • html/canvas/WebGL2RenderingContext.h:
  • html/canvas/WebGLAny.h:
  • html/canvas/WebGLRenderingContextBase.cpp:

(WebCore::WebGLRenderingContextBase::validateLocationLength):
(WebCore::WebGLRenderingContextBase::validateBufferDataParameters):

  • loader/SubresourceLoader.cpp:

(WebCore::SubresourceLoader::didFinishLoading):

  • platform/graphics/GraphicsContextGL.h:
  • platform/graphics/angle/ExtensionsGLANGLE.cpp:

(WebCore::ExtensionsGLANGLE::getTranslatedShaderSourceANGLE):
(WebCore::ExtensionsGLANGLE::blitFramebuffer):
(WebCore::ExtensionsGLANGLE::renderbufferStorageMultisample):
(WebCore::ExtensionsGLANGLE::drawBuffersEXT):
(WebCore::ExtensionsGLANGLE::getBooleanvRobustANGLE):
(WebCore::ExtensionsGLANGLE::getBufferParameterivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getFloatvRobustANGLE):
(WebCore::ExtensionsGLANGLE::getFramebufferAttachmentParameterivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getIntegervRobustANGLE):
(WebCore::ExtensionsGLANGLE::getProgramivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getRenderbufferParameterivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getShaderivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getTexParameterfvRobustANGLE):
(WebCore::ExtensionsGLANGLE::getTexParameterivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getUniformfvRobustANGLE):
(WebCore::ExtensionsGLANGLE::getUniformivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getVertexAttribfvRobustANGLE):
(WebCore::ExtensionsGLANGLE::getVertexAttribivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getVertexAttribPointervRobustANGLE):
(WebCore::ExtensionsGLANGLE::readPixelsRobustANGLE):
(WebCore::ExtensionsGLANGLE::texImage2DRobustANGLE):
(WebCore::ExtensionsGLANGLE::texParameterfvRobustANGLE):
(WebCore::ExtensionsGLANGLE::texParameterivRobustANGLE):
(WebCore::ExtensionsGLANGLE::texSubImage2DRobustANGLE):
(WebCore::ExtensionsGLANGLE::compressedTexImage2DRobustANGLE):
(WebCore::ExtensionsGLANGLE::compressedTexSubImage2DRobustANGLE):
(WebCore::ExtensionsGLANGLE::compressedTexImage3DRobustANGLE):
(WebCore::ExtensionsGLANGLE::compressedTexSubImage3DRobustANGLE):
(WebCore::ExtensionsGLANGLE::texImage3DRobustANGLE):
(WebCore::ExtensionsGLANGLE::texSubImage3DRobustANGLE):
(WebCore::ExtensionsGLANGLE::getQueryivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getQueryObjectuivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getBufferPointervRobustANGLE):
(WebCore::ExtensionsGLANGLE::getIntegeri_vRobustANGLE):
(WebCore::ExtensionsGLANGLE::getInternalformativRobustANGLE):
(WebCore::ExtensionsGLANGLE::getVertexAttribIivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getVertexAttribIuivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getUniformuivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getActiveUniformBlockivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getInteger64vRobustANGLE):
(WebCore::ExtensionsGLANGLE::getInteger64i_vRobustANGLE):
(WebCore::ExtensionsGLANGLE::getBufferParameteri64vRobustANGLE):
(WebCore::ExtensionsGLANGLE::samplerParameterivRobustANGLE):
(WebCore::ExtensionsGLANGLE::samplerParameterfvRobustANGLE):
(WebCore::ExtensionsGLANGLE::getSamplerParameterivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getSamplerParameterfvRobustANGLE):
(WebCore::ExtensionsGLANGLE::getFramebufferParameterivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getProgramInterfaceivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getBooleani_vRobustANGLE):
(WebCore::ExtensionsGLANGLE::getMultisamplefvRobustANGLE):
(WebCore::ExtensionsGLANGLE::getTexLevelParameterivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getTexLevelParameterfvRobustANGLE):
(WebCore::ExtensionsGLANGLE::getPointervRobustANGLERobustANGLE):
(WebCore::ExtensionsGLANGLE::readnPixelsRobustANGLE):
(WebCore::ExtensionsGLANGLE::getnUniformfvRobustANGLE):
(WebCore::ExtensionsGLANGLE::getnUniformivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getnUniformuivRobustANGLE):
(WebCore::ExtensionsGLANGLE::texParameterIivRobustANGLE):
(WebCore::ExtensionsGLANGLE::texParameterIuivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getTexParameterIivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getTexParameterIuivRobustANGLE):
(WebCore::ExtensionsGLANGLE::samplerParameterIivRobustANGLE):
(WebCore::ExtensionsGLANGLE::samplerParameterIuivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getSamplerParameterIivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getSamplerParameterIuivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getQueryObjectivRobustANGLE):
(WebCore::ExtensionsGLANGLE::getQueryObjecti64vRobustANGLE):
(WebCore::ExtensionsGLANGLE::getQueryObjectui64vRobustANGLE):

  • platform/graphics/angle/GraphicsContextGLANGLE.cpp:

(WebCore::GraphicsContextGLOpenGL::getIntegeri_v):
(WebCore::GraphicsContextGLOpenGL::getInteger64v):
(WebCore::GraphicsContextGLOpenGL::getInteger64i_v):
(WebCore::GraphicsContextGLOpenGL::drawArraysInstanced):
(WebCore::GraphicsContextGLOpenGL::drawElementsInstanced):
(WebCore::GraphicsContextGLOpenGL::getUniformBlockIndex):
(WebCore::GraphicsContextGLOpenGL::getActiveUniformBlockiv):
(WebCore::GraphicsContextGLOpenGL::getActiveUniformBlockName):
(WebCore::GraphicsContextGLOpenGL::uniformBlockBinding):
(WebCore::GraphicsContextGLOpenGL::drawRangeElements):
(WebCore::GraphicsContextGLOpenGL::pauseTransformFeedback):
(WebCore::GraphicsContextGLOpenGL::resumeTransformFeedback):
(WebCore::GraphicsContextGLOpenGL::bindBufferRange):
(WebCore::GraphicsContextGLOpenGL::getUniformIndices):

  • platform/graphics/opengl/GraphicsContextGLOpenGL.h:
  • platform/graphics/opengl/GraphicsContextGLOpenGLBase.cpp:

(WebCore::GraphicsContextGLOpenGL::getIntegeri_v):

  • platform/graphics/opengl/GraphicsContextGLOpenGLCommon.cpp:

(WebCore::GraphicsContextGLOpenGL::getInteger64v):
(WebCore::GraphicsContextGLOpenGL::getInteger64i_v):

12:52 PM Changeset in webkit [263280] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WTF

-Wsign-compare in isValidOptionSet
https://bugs.webkit.org/show_bug.cgi?id=213383

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-06-19
Reviewed by Darin Adler.

The OptionSet's StorageType is always unsigned, even if the enum's underlying value is not.
Match this in isValidOptionSet to avoid -Wsign-compare during validity checking.

  • wtf/OptionSet.h:

(WTF::isValidOptionSet):

12:39 PM Changeset in webkit [263279] by Alan Coon
  • 15 edits
    2 moves
    2 adds in branches/safari-610.1.17-branch

Reintroduce content to branch.

This reverts r263238.

11:43 AM Changeset in webkit [263278] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

[iOS] Drop std::call_once() from RenderThemeIOS::cssValueToSystemColorMap()
https://bugs.webkit.org/show_bug.cgi?id=213392

Reviewed by Geoffrey Garen.

Drop std::call_once() from RenderThemeIOS::cssValueToSystemColorMap() since this function
is always called from the main thread.

  • rendering/RenderThemeIOS.mm:

(WebCore::RenderThemeIOS::cssValueToSystemColorMap):

11:07 AM Changeset in webkit [263277] by commit-queue@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

functionCpuClflush checks that the second argument is Int32 but it actually expects it to be UInt32
https://bugs.webkit.org/show_bug.cgi?id=213388

Patch by Tuomas Karkkainen <tuomas.webkit@apple.com> on 2020-06-19
Reviewed by Saam Barati.

This changes the check from isInt32() to isUInt32() so that the logic is consistent.

  • tools/JSDollarVM.cpp:
10:15 AM Changeset in webkit [263276] by Diego Pino Garcia
  • 3 edits in trunk/LayoutTests

[GLIB] Unreviewed test gardening. Update test expectations after r263268.

  • platform/glib/TestExpectations:
  • platform/gtk/TestExpectations:
10:11 AM Changeset in webkit [263275] by Chris Fleizach
  • 8 edits in trunk

AX: Make isolated tree enablement status dependent on client preference
https://bugs.webkit.org/show_bug.cgi?id=213355
<rdar://problem/64506577>

Reviewed by Zalan Bujtas.

Source/WebKit:

We don't want the isolated tree mode in all clients (like Mail or Dictionary).
As a result, we can set this setting to off and allow safari and mini browser turn on more directly.

  • Shared/WebPreferences.yaml:
  • UIProcess/API/Cocoa/WKPreferences.mm:

(-[WKPreferences _setAccessibilityIsolatedTreeEnabled:]):
(-[WKPreferences _accessibilityIsolatedTreeEnabled]):

  • UIProcess/API/Cocoa/WKPreferencesPrivate.h:
  • WebProcess/InjectedBundle/InjectedBundle.cpp:

(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
(WebKit::InjectedBundle::setAccessibilityIsolatedTreeEnabled):

  • WebProcess/InjectedBundle/InjectedBundle.h:

Tools:

  • MiniBrowser/mac/AppDelegate.m:

(-[BrowserAppDelegate defaultConfiguration]):

10:07 AM Changeset in webkit [263274] by commit-queue@webkit.org
  • 4 edits in trunk/Source

Enable referrer policy attribute support by default
https://bugs.webkit.org/show_bug.cgi?id=213285

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

Enable referrer policy attribute support by default by flipping the switch.

Source/WebCore:

  • page/RuntimeEnabledFeatures.h:

Source/WebKit:

  • Shared/WebPreferences.yaml:
9:45 AM Changeset in webkit [263273] by Lauro Moura
  • 2 edits in trunk/WebDriverTests

[WebDriver][GTK] Some tests fails to click elements because element is outside visible rect
https://bugs.webkit.org/show_bug.cgi?id=211330

Unreviewed test gardening.

These tests have been passing since r262861 landed.

9:34 AM Changeset in webkit [263272] by youenn@apple.com
  • 3 edits in trunk/Source/WebKit

LibWebRTCSocketClient::sendTo is too verbose in case of error
https://bugs.webkit.org/show_bug.cgi?id=213380

Reviewed by Eric Carlson.

Only log error message if the error code is different from the previous one.

  • NetworkProcess/webrtc/LibWebRTCSocketClient.cpp:

(WebKit::LibWebRTCSocketClient::sendTo):

  • NetworkProcess/webrtc/LibWebRTCSocketClient.h:
9:30 AM Changeset in webkit [263271] by Chris Dumez
  • 3 edits in trunk/Source/WebKit

Web Inspector: RemoteInspector::singleton() slows down MobileSafari launch
https://bugs.webkit.org/show_bug.cgi?id=213381
<rdar://problem/64533003>

Reviewed by Darin Adler.

RemoteInspector::singleton() is expensive according to traces. It was called in WebProcessPool::initializeNewWebProcess()
which happens on MobileSafari launch because we prewarm a WebProcess. However, there is no reason to initialize remote
Web Inspector at this point. Per associated comment, Remote Web Inspector needs to be initialized once there is a
sub process hosting one of our Web View. As a result, I moved the initialization call to WebPageProxy::initializeWebPage()
which is when we actually send the IPC to the WebProcess to create the WebPage that is backing the UI-side WebView.

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::initializeWebPage):

  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::initializeNewWebProcess):

9:21 AM Changeset in webkit [263270] by Chris Dumez
  • 13 edits in trunk/Source

Move Prefixed WebAudio interfaces behind their own feature flag
https://bugs.webkit.org/show_bug.cgi?id=213356

Reviewed by Darin Adler.

Source/WebCore:

Move Prefixed WebAudio interfaces behind their own feature flag, on by default. This will
allow us to easily disable the prefixed API and will also allow it to live independently
from the unprefixed API.

  • Modules/webaudio/AudioContext.idl:
  • Modules/webaudio/WebKitAudioContext.idl:
  • Modules/webaudio/WebKitAudioPannerNode.idl:
  • Modules/webaudio/WebKitOfflineAudioContext.idl:
  • bindings/js/WebCoreBuiltinNames.h:
  • page/Settings.yaml:

Source/WebKit:

  • Shared/WebPreferences.yaml:

Source/WebKitLegacy/mac:

  • WebView/WebView.mm:

(-[WebView _preferencesChanged:]):

Source/WebKitLegacy/win:

  • WebView.cpp:

(WebView::notifyPreferencesChanged):

9:18 AM Changeset in webkit [263269] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

Enable stale-while-revalidate support by default
https://bugs.webkit.org/show_bug.cgi?id=213286

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

Enable stale-while-revalidate support for Mac/GTK/WPE by changing the default
to true. Note that platforms that do not support speculative loads, which s-w-r
relies on, will not see any change in bahavior.

  • UIProcess/WebsiteData/WebsiteDataStoreConfiguration.h:
8:39 AM Changeset in webkit [263268] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[LFC][TFC] Do not special-case empty tables
https://bugs.webkit.org/show_bug.cgi?id=213378

Reviewed by Antti Koivisto.

Source/WebCore:

Now that min/max-width support is added, empty tables can just go through the normal width computation path.

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

  • layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContext.cpp:

(WebCore::Layout::TableWrapperBlockFormattingContext::computeWidthAndMarginForTableBox):

LayoutTests:

  • fast/layoutformattingcontext/table-min-max-width-empty-content-simple-expected.html: Added.
  • fast/layoutformattingcontext/table-min-max-width-empty-content-simple.html: Added.
8:31 AM Changeset in webkit [263267] by aakash_jain@apple.com
  • 3 edits in trunk/Tools

Improve handling of trac downtime by commit-queue
https://bugs.webkit.org/show_bug.cgi?id=213377

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-build/steps.py: Load contributors.json from disk when loading from trac fails.

(ValidateCommiterAndReviewer.load_contributors_from_disk):
(ValidateCommiterAndReviewer.load_contributors_from_trac):
(ValidateCommiterAndReviewer.load_contributors):

  • BuildSlaveSupport/ews-build/steps_unittest.py: Added unit-test
8:28 AM Changeset in webkit [263266] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

Mac wk2 Debug] webaudio/biquad-bandpass.html is flaky crashing with alert WTFCrash - WebCore::WebKitAudioContext::~WebKitAudioContext() + 654 (WebKitAudioContext.cpp:209).
https://bugs.webkit.org/show_bug.cgi?id=213375

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
7:35 AM Changeset in webkit [263265] by svillar@igalia.com
  • 7 edits in trunk

REGRESSION(r262254?): [WPE] imported/w3c/web-platform-tests/webxr/idlharness.https.window.html is failing
https://bugs.webkit.org/show_bug.cgi?id=212897

Reviewed by Youenn Fablet.

LayoutTests/imported/w3c:

  • web-platform-tests/webxr/idlharness.https.window-expected.txt: Updated expectations.

Source/WebCore:

WPT tests were updated in r262254 and they already include the latest changes in the specs. Among others the
XR interface was renamed to XRSystem. We were already using that name in the C++ code but not in the JS interface.
The WPT update brings in another set of changes like the new XRLayer which is already not supported (I am
adding it soon in another patch). Last but not least, the new tests include checks for the XRPermissionStatus interface
which is not going to be implemented soon as it requires the Permission API which is not supported in WebKit yet. All in
all, this patch renames XR to XRSystem and marks as failing the XRLayer (temporarily) and XRPermissionStatus checks.

No new tests as there is no change in functionality.

  • Modules/webxr/WebXRSystem.idl: Rename XR to XRSystem.
  • bindings/js/WebCoreBuiltinNames.h: Ditto.

LayoutTests:

  • platform/wpe/TestExpectations: Re-enable the idlharness.https.window.html test.
6:52 AM Changeset in webkit [263264] by Lauro Moura
  • 71 edits
    7 copies
    9 adds in trunk/WebDriverTests

[WebDriver][WPE] Update imported selenium to a version with the WPE WebDriver
https://bugs.webkit.org/show_bug.cgi?id=213263

Reviewed by Carlos Garcia Campos.

Updated Selenium tests to 0d7e57a7079c, which added the WPE WebDriver.

  • imported/selenium/common/src/web/button.png: Added.
  • imported/selenium/common/src/web/formPage.html:
  • imported/selenium/common/src/web/inputs.html:
  • imported/selenium/common/src/web/relative_locators.html: Added.
  • imported/selenium/common/src/web/screen/screen.css:
  • imported/selenium/common/src/web/selectableItems.html:
  • imported/selenium/common/src/web/simpleTest.html:
  • imported/selenium/common/src/web/upload.html:
  • imported/selenium/common/src/web/upload_invisible.html:
  • imported/selenium/common/src/web/xhtmlTest.html:
  • imported/selenium/importer.json: Modified hash and skipped folders
  • imported/selenium/py/conftest.py:
  • imported/selenium/py/selenium/init.py:
  • imported/selenium/py/selenium/common/exceptions.py:
  • imported/selenium/py/selenium/webdriver/init.py:
  • imported/selenium/py/selenium/webdriver/common/action_chains.py:
  • imported/selenium/py/selenium/webdriver/common/actions/action_builder.py:
  • imported/selenium/py/selenium/webdriver/common/actions/input_device.py:
  • imported/selenium/py/selenium/webdriver/common/actions/interaction.py:
  • imported/selenium/py/selenium/webdriver/common/actions/key_actions.py:
  • imported/selenium/py/selenium/webdriver/common/actions/mouse_button.py:
  • imported/selenium/py/selenium/webdriver/common/actions/pointer_actions.py:
  • imported/selenium/py/selenium/webdriver/common/actions/pointer_input.py:
  • imported/selenium/py/selenium/webdriver/common/alert.py:
  • imported/selenium/py/selenium/webdriver/common/desired_capabilities.py:
  • imported/selenium/py/selenium/webdriver/common/html5/application_cache.py:
  • imported/selenium/py/selenium/webdriver/common/options.py: Added.
  • imported/selenium/py/selenium/webdriver/common/proxy.py:
  • imported/selenium/py/selenium/webdriver/common/timeouts.py: Added.
  • imported/selenium/py/selenium/webdriver/common/utils.py:
  • imported/selenium/py/selenium/webdriver/common/window.py: Copied from WebDriverTests/imported/selenium/py/selenium/init.py.
  • imported/selenium/py/selenium/webdriver/remote/command.py:
  • imported/selenium/py/selenium/webdriver/remote/errorhandler.py:
  • imported/selenium/py/selenium/webdriver/remote/remote_connection.py:
  • imported/selenium/py/selenium/webdriver/remote/switch_to.py:
  • imported/selenium/py/selenium/webdriver/remote/utils.py:
  • imported/selenium/py/selenium/webdriver/remote/webdriver.py:
  • imported/selenium/py/selenium/webdriver/remote/webelement.py:
  • imported/selenium/py/selenium/webdriver/safari/permissions.py: Copied from WebDriverTests/imported/selenium/py/selenium/init.py.
  • imported/selenium/py/selenium/webdriver/safari/remote_connection.py: Copied from WebDriverTests/imported/selenium/py/test/selenium/webdriver/remote/remote_firefox_profile_tests.py.
  • imported/selenium/py/selenium/webdriver/safari/service.py:
  • imported/selenium/py/selenium/webdriver/safari/webdriver.py:
  • imported/selenium/py/selenium/webdriver/support/color.py:
  • imported/selenium/py/selenium/webdriver/support/event_firing_webdriver.py:
  • imported/selenium/py/selenium/webdriver/support/expected_conditions.py:
  • imported/selenium/py/selenium/webdriver/support/relative_locator.py: Added.
  • imported/selenium/py/selenium/webdriver/support/select.py:
  • imported/selenium/py/selenium/webdriver/support/wait.py:
  • imported/selenium/py/selenium/webdriver/webkitgtk/options.py:
  • imported/selenium/py/selenium/webdriver/webkitgtk/webdriver.py:
  • imported/selenium/py/selenium/webdriver/wpewebkit/init.py: Copied from WebDriverTests/imported/selenium/py/selenium/init.py.
  • imported/selenium/py/selenium/webdriver/wpewebkit/options.py: Copied from WebDriverTests/imported/selenium/py/selenium/webdriver/webkitgtk/options.py.
  • imported/selenium/py/selenium/webdriver/wpewebkit/service.py: Copied from WebDriverTests/imported/selenium/py/selenium/webdriver/safari/service.py.
  • imported/selenium/py/selenium/webdriver/wpewebkit/webdriver.py: Copied from WebDriverTests/imported/selenium/py/selenium/webdriver/webkitgtk/webdriver.py.
  • imported/selenium/py/test/selenium/webdriver/common/alerts_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/api_example_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/appcache_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/click_scrolling_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/cookie_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/correct_event_firing_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/driver_element_finding_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/element_attribute_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/executing_async_javascript_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/form_handling_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/frame_switching_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/interactions_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/page_load_timeout_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/page_loading_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/position_and_size_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/proxy_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/rendered_webelement_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/select_class_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/select_element_handling_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/takes_screenshots_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/timeout_tests.py: Added.
  • imported/selenium/py/test/selenium/webdriver/common/typing_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/w3c_interaction_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/webdriverwait_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/window_switching_tests.py:
  • imported/selenium/py/test/selenium/webdriver/common/window_tests.py:
  • imported/selenium/py/test/selenium/webdriver/remote/remote_firefox_profile_tests.py:
  • imported/selenium/py/test/selenium/webdriver/safari/launcher_tests.py:
  • imported/selenium/py/test/selenium/webdriver/support/event_firing_webdriver_tests.py:
  • imported/selenium/py/test/selenium/webdriver/support/expected_conditions_tests.py: Added.
  • imported/selenium/py/test/selenium/webdriver/support/relative_by_tests.py: Added.
6:40 AM Changeset in webkit [263263] by Lauro Moura
  • 2 edits in trunk/Tools

[WPE] Warn potential issues when creating WindowViewBackend
https://bugs.webkit.org/show_bug.cgi?id=213326

Reviewed by Philippe Normand.

Make it easier to debug eventual GL issues when starting up MiniBrowser in
windowed mode.

  • wpe/backends/WindowViewBackend.cpp:

(WPEToolingBackends::WaylandEGLConnection::singleton):
(WPEToolingBackends::WindowViewBackend::WindowViewBackend):

6:34 AM Changeset in webkit [263262] by Lauro Moura
  • 4 edits in trunk/LayoutTests

[GTK] Garden some flaky crashes and start expect reorg

Unreviewed test gardening.

Also start new section in the top of the file to follow the glib
expectation grouping.

  • platform/gtk-wayland/TestExpectations:
  • platform/gtk/TestExpectations:
  • platform/glib/TestExpectations:
6:18 AM Changeset in webkit [263261] by Lauro Moura
  • 5 edits in trunk/Tools

[webkitpy][WPE] Default to headless if _display_server is xfvb
https://bugs.webkit.org/show_bug.cgi?id=213327

Reviewed by Philippe Normand.

Xvfb is used as the default display server for some scripts, and the
equivalent for WPE is the headless one.

WTR and the API tests already create only HeadlessViewBackends, but the
WebDriver tests create them through MiniBrowser, which requires the
'--headless' parameter.

  • Scripts/run-webdriver-tests: Do not override _display_server
  • Scripts/webkitpy/port/base.py:

(Port.init): Define _display_server for all ports to avoid
eventually needing to override it.

  • Scripts/webkitpy/port/wpe.py:

(WPEPort.init): Default to 'headless' if _display_server is 'xvfb'

  • Scripts/webkitpy/w3c/wpt_runner.py:

(main): Dot not override _display_server

5:43 AM Changeset in webkit [263260] by Alan Bujtas
  • 6 edits
    2 adds in trunk

[LFC][BFC] Min/max-width should always be resolved against the containing block width
https://bugs.webkit.org/show_bug.cgi?id=213365

Reviewed by Antti Koivisto.

Source/WebCore:

Even when neighboring floats shrink the available horizontal space, the min/max(normal) widths should
be resolved against the containing block's logical width.

Test: fast/layoutformattingcontext/float-avoider-available-horizontal-space2.html

  • layout/blockformatting/BlockFormattingContext.cpp:

(WebCore::Layout::BlockFormattingContext::computeWidthAndMargin):

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

(WebCore::Layout::BlockFormattingContext::Geometry::computedWidthAndMargin):

  • layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContext.cpp:

(WebCore::Layout::TableWrapperBlockFormattingContext::computeWidthAndMarginForTableBox):

LayoutTests:

  • fast/layoutformattingcontext/float-avoider-available-horizontal-space2-expected.html: Added.
  • fast/layoutformattingcontext/float-avoider-available-horizontal-space2.html: Added.
5:27 AM Changeset in webkit [263259] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

REGRESSION(r253360): [GTK] Page starts loading during animation in back/forward gesture
https://bugs.webkit.org/show_bug.cgi?id=205650

Patch by Alexander Mikhaylenko <Alexander Mikhaylenko> on 2020-06-19
Reviewed by Carlos Garcia Campos.

r253360 changed the swipe gesture to start loading the page during the gesture, relying on
freezing the layer tree state to prevent unwanted redraws. However, it was implemented for
AC mode, but didn't prevent redraws in non-accelerated mode. Add a simple check to skip
redraws in this case.

  • WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp:

(WebKit::DrawingAreaCoordinatedGraphics::display): Skip drawing if layer tree state is frozen.

12:49 AM Changeset in webkit [263258] by Carlos Garcia Campos
  • 17 edits in trunk

Add support for fetching registrable domains with resource load statistics
https://bugs.webkit.org/show_bug.cgi?id=213291

Source/WebKit:

Reviewed by Adrian Perez de Castro and Youenn Fablet.

WebsiteDataStore::fetchData() doesn't return anything for resource load statistics because
NetworkProcess::fetchWebsiteData() doesn't handle WebsiteDataType::ResourceLoadStatistics.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:

(WebKit::ResourceLoadStatisticsDatabaseStore::allDomains const): Query all registrable domains from database.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsMemoryStore.cpp:

(WebKit::ResourceLoadStatisticsMemoryStore::allDomains const): Return all registrable domains in memory map.

  • NetworkProcess/Classifier/ResourceLoadStatisticsMemoryStore.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.h:
  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::registrableDomains): Get the list of registrable domains.

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h:
  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::fetchWebsiteData): Handle WebsiteDataType::ResourceLoadStatistics.

  • Shared/WebsiteData/WebsiteData.cpp:

(WebKit::WebsiteData::encode const): Encode registrableDomainsWithResourceLoadStatistics.
(WebKit::WebsiteData::decode): Decode registrableDomainsWithResourceLoadStatistics.

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

(WKWebsiteDataStoreRemoveITPDataForDomain): Use WebsiteDataRecord::addResourceLoadStatisticsRegistrableDomain()
instead of the display name.

  • UIProcess/WebsiteData/WebsiteDataRecord.cpp:

(WebKit::WebsiteDataRecord::addResourceLoadStatisticsRegistrableDomain): Add the given registrable domain to the list.

  • UIProcess/WebsiteData/WebsiteDataRecord.h:
  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::fetchDataAndApply): Handle registrable domains with resource load statistics.
(WebKit::WebsiteDataStore::removeData): Use resourceLoadStatisticsRegistrableDomains instead of the display name.

Tools:

Reviewed by Adrian Perez de Castro.

Update GLib ITP unit test to check also fetch and remove.

  • TestWebKitAPI/Tests/WebKitGLib/TestWebsiteData.cpp:

(testWebsiteDataITP):

12:43 AM Changeset in webkit [263257] by Tomoki Imai
  • 2 edits in trunk/Tools

Change my (Tomoki Imai's) status to committer

Unreviewed, just updating contributors.json for myself.

  • Scripts/webkitpy/common/config/contributors.json:
12:32 AM Changeset in webkit [263256] by svillar@igalia.com
  • 4 edits in trunk/Source/WebCore

[WebXR] unsigned long in IDL should be translated as unsigned in C++ code
https://bugs.webkit.org/show_bug.cgi?id=213020

Reviewed by Darin Adler.

The "unsigned long" type definition in IDL must be translated to unsigned in C++ code.

I'm also replacing the very long XRFrameRequestCallback::Identifier by simply unsigned as it
isn't adding anything.

No new test required as there is no change in functionality, just removing an alias.

  • Modules/webxr/WebXRSession.cpp:

(WebCore::WebXRSession::requestAnimationFrame):
(WebCore::WebXRSession::cancelAnimationFrame):

  • Modules/webxr/WebXRSession.h:
  • Modules/webxr/XRFrameRequestCallback.h:

(WebCore::XRFrameRequestCallback::callbackId):
(WebCore::XRFrameRequestCallback::setCallbackId):

12:04 AM Changeset in webkit [263255] by mmaxfield@apple.com
  • 25 edits
    1 copy
    57 adds in trunk

[Cocoa] Unify "font:" CSS shorthand values between macOS and iOS family
https://bugs.webkit.org/show_bug.cgi?id=213332
<rdar://problem/64479189>

Reviewed by Tim Horton and Darin Adler.

Source/WebCore:

They exist on all Cocoa platforms, so we might as well hook them up.

This unifies the shorthand CSS value handling from RenderThemeMac and
RenderThemeIOS into RenderThemeCocoa. This has two effects:

  • It hooks up the -apple-system keywords on macOS (they previously were only implemented for the iOS family).
  • It hooks up the CSS2 keywords (caption, menu, etc.) on the iOS family (they previously were only implemented on Mac).

All these fonts have been around since Mojave, so there is no need to
introduce any new platform guards.

Tests: fast/text/text-styles/-apple-system/-apple-system-body.html

fast/text/text-styles/-apple-system/-apple-system-caption1.html
fast/text/text-styles/-apple-system/-apple-system-caption2.html
fast/text/text-styles/-apple-system/-apple-system-footnote.html
fast/text/text-styles/-apple-system/-apple-system-headline.html
fast/text/text-styles/-apple-system/-apple-system-short-body.html
fast/text/text-styles/-apple-system/-apple-system-short-caption1.html
fast/text/text-styles/-apple-system/-apple-system-short-footnote.html
fast/text/text-styles/-apple-system/-apple-system-short-headline.html
fast/text/text-styles/-apple-system/-apple-system-short-subheadline.html
fast/text/text-styles/-apple-system/-apple-system-subheadline.html
fast/text/text-styles/-apple-system/-apple-system-tall-body.html
fast/text/text-styles/-apple-system/-apple-system-title0.html
fast/text/text-styles/-apple-system/-apple-system-title1.html
fast/text/text-styles/-apple-system/-apple-system-title2.html
fast/text/text-styles/-apple-system/-apple-system-title3.html
fast/text/text-styles/-apple-system/-apple-system-title4.html
fast/text/text-styles/-webkit-control.html
fast/text/text-styles/-webkit-mini-control.html
fast/text/text-styles/-webkit-small-control.html
fast/text/text-styles/bogus.html
fast/text/text-styles/caption.html
fast/text/text-styles/icon.html
fast/text/text-styles/menu.html
fast/text/text-styles/message-box.html
fast/text/text-styles/small-caption.html
fast/text/text-styles/status-bar.html

  • css/CSSValueKeywords.in: All Cocoa ports should be able to parse these values
  • platform/graphics/cocoa/FontCacheCoreText.cpp:

(WebCore::fontWithFamilySpecialCase): Move code that used to be in the Mac and
iOS implementations of platformFontWithFamilySpecialCase() (inside FontCacheMac.mm
and FontCacheIOS.mm) to be shared to be shared inside fontWithFamilySpecialCase().

  • platform/graphics/cocoa/FontDescriptionCocoa.cpp: Remove platform guards.

(WebCore::convertArray):
(WebCore::matchSystemFontUse):

  • platform/graphics/cocoa/SystemFontDatabaseCoreText.cpp: Ditto.

(WebCore::SystemFontDatabaseCoreText::createTextStyleFont):

  • platform/graphics/ios/FontCacheIOS.mm: Move code from here into FontCacheCoreText.

(WebCore::platformFontWithFamilySpecialCase):

  • platform/graphics/mac/FontCacheMac.mm: Ditto.

(WebCore::platformFontWithFamilySpecialCase):

  • platform/mac/ThemeMac.h: Delete systemFontSizeFor(NSControlSize) because

<rdar://problem/60350699> is fixed.

  • platform/mac/ThemeMac.mm: Ditto.

(WebCore::ThemeMac::controlFont const):
(WebCore::ThemeMac::systemFontSizeFor): Deleted.

  • rendering/RenderThemeCocoa.h: Previously, code was calling

RenderThemeIOS::contentSizeCategory(), which was a static function. Now, both Mac
and iOS need to be able to call this. However, the implementation of this function
is different between Mac and iOS. So, turn it from a static function in RenderThemeIOS
into a method in RenderThemeCocoa, and give RenderThemeCocoa a singleton() function
that downcasts the return of RenderTheme::singleton(). This way, instead of calling
RenderThemeIOS::contentSizeCategory(), code can call
RenderThemeCocoa::singleton().contentSizeCategory().

  • rendering/RenderThemeCocoa.mm: Move code from RenderThemeIOS and RenderThemeMac

into RenderThemeCocoa.
(WebCore::RenderThemeCocoa::singleton):
(WebCore::RenderThemeCocoa::cachedSystemFontDescription const):
(WebCore::cssWeightOfSystemFont):
(WebCore::RenderThemeCocoa::updateCachedSystemFontDescription const):

  • rendering/RenderThemeIOS.h: Ditto.
  • rendering/RenderThemeIOS.mm: Ditto.

(WebCore::RenderThemeIOS::contentSizeCategory const):
(WebCore::attachmentActionFont):
(WebCore::attachmentTitleFont):
(WebCore::RenderThemeIOS::contentSizeCategory): Deleted.
(WebCore::RenderThemeIOS::cachedSystemFontDescription const): Deleted.
(WebCore::cssWeightOfSystemFont): Deleted.
(WebCore::RenderThemeIOS::updateCachedSystemFontDescription const): Deleted.

  • rendering/RenderThemeMac.h: Ditto.
  • rendering/RenderThemeMac.mm: Ditto.

(WebCore::RenderThemeMac::contentSizeCategory const):
(WebCore::RenderThemeMac::setFontFromControlSize const):
(WebCore::RenderThemeMac::controlSizeForSystemFont const):
(WebCore::toFontWeight): Deleted.
(WebCore::RenderThemeMac::updateCachedSystemFontDescription const): Deleted.

Source/WebCore/PAL:

  • pal/spi/cocoa/CoreTextSPI.h:

The implementation of RenderThemeMac::contentSizeCategory() needs to use
kCTFontContentSizeCategoryL.

Source/WTF:

All Cocoa platforms support kCTUIFontTextStyleTitle0 and kCTUIFontTextStyleTitle4.

  • wtf/PlatformHave.h:

LayoutTests:

  • TestExpectations:
  • fast/text/text-styles/-apple-system/-apple-system-body-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-body.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-caption1-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-caption1.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-caption2-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-caption2.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-footnote-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-footnote.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-headline-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-headline.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-short-body-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-short-body.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-short-caption1-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-short-caption1.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-short-footnote-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-short-footnote.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-short-headline-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-short-headline.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-short-subheadline-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-short-subheadline.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-subheadline-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-subheadline.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-tall-body-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-tall-body.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-title0-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-title0.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-title1-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-title1.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-title2-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-title2.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-title3-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-title3.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-title4-expected-mismatch.html: Added.
  • fast/text/text-styles/-apple-system/-apple-system-title4.html: Added.
  • fast/text/text-styles/-webkit-control-expected-mismatch.html: Added.
  • fast/text/text-styles/-webkit-control.html: Added.
  • fast/text/text-styles/-webkit-mini-control-expected-mismatch.html: Added.
  • fast/text/text-styles/-webkit-mini-control.html: Added.
  • fast/text/text-styles/-webkit-small-control-expected-mismatch.html: Added.
  • fast/text/text-styles/-webkit-small-control.html: Added.
  • fast/text/text-styles/bogus-expected.html: Added.
  • fast/text/text-styles/bogus.html: Added.
  • fast/text/text-styles/caption-expected-mismatch.html: Added.
  • fast/text/text-styles/caption.html: Added.
  • fast/text/text-styles/icon-expected-mismatch.html: Added.
  • fast/text/text-styles/icon.html: Added.
  • fast/text/text-styles/menu-expected-mismatch.html: Added.
  • fast/text/text-styles/menu.html: Added.
  • fast/text/text-styles/message-box-expected-mismatch.html: Added.
  • fast/text/text-styles/message-box.html: Added.
  • fast/text/text-styles/small-caption-expected-mismatch.html: Added.
  • fast/text/text-styles/small-caption.html: Added.
  • fast/text/text-styles/status-bar-expected-mismatch.html: Added.
  • fast/text/text-styles/status-bar.html: Added.
  • platform/ios/TestExpectations:
  • platform/ios/fast/css/css2-system-fonts-expected.txt:
  • platform/mac/TestExpectations:
  • platform/mac/fast/text/international/system-language/system-font-punctuation-expected.txt:
  • platform/mac-mojave/fast/text/international/system-language/system-font-punctuation-expected.txt: Added.

Jun 18, 2020:

8:59 PM Changeset in webkit [263254] by Diego Pino Garcia
  • 3 edits
    3 adds in trunk/LayoutTests

[GTK] Unreviewed test gardening. Update test expectations after r263222.

  • platform/gtk/TestExpectations:
  • platform/gtk/imported/w3c/web-platform-tests/service-workers/service-worker/fetch-audio-tainting.https-expected.txt: Added.
8:42 PM Changeset in webkit [263253] by Doug Kelly
  • 4 edits in trunk/Source/WebCore

Use paintCellAndSetFocusedElementNeedsRepaintIfNecessary() for search field buttons
https://bugs.webkit.org/show_bug.cgi?id=213352
<rdar://problem/57129008>

Reviewed by Simon Fraser.

The search fields cancel and results buttons should use the common
paintCellAndSetFocusedElementNeedsRepaintIfNecessary() function instead of directly painting the cell.
This allows for an image buffer to be used for drawing specifically in cases when it becomes needed,
when a scale (either via zoom or CSS transform) is applied.

This also moves the logic for determining if an image buffer should be used into
ThemeMac::drawCellOrFocusRingWithViewIntoContext(), which uses the current user-defined CTM
(inverting the base CTM to negate the effect of a device-specific scale factor). This also negates
the need for the page scale factor and the effective zoom applied to the renderer style, since it is
computed into the CTM already.

  • platform/mac/ThemeMac.h:
  • platform/mac/ThemeMac.mm:

(WebCore::paintToggleButton):
(WebCore::paintButton):
(WebCore::ThemeMac::drawCellOrFocusRingWithViewIntoContext):
(WebCore::paintColorWell):
(WebCore::ThemeMac::paint):

  • rendering/RenderThemeMac.mm:

(WebCore::RenderThemeMac::paintCellAndSetFocusedElementNeedsRepaintIfNecessary):
(WebCore::RenderThemeMac::paintSliderThumb):
(WebCore::RenderThemeMac::paintSearchFieldCancelButton):
(WebCore::RenderThemeMac::paintSearchFieldResultsButton):

8:30 PM Changeset in webkit [263252] by mark.lam@apple.com
  • 7 edits in trunk/Source

Unify Bitmap math loops in MarkedBlock::Handle::specializedSweep().
https://bugs.webkit.org/show_bug.cgi?id=213345

Reviewed by Robin Morisset and Saam Barati.

Source/JavaScriptCore:

This change appears to be performance neutral. However, we'll take the change
because we know that it does less work, and the new way of expressing the Bitmap
math in MarkedBlock::Handle::specializedSweep() does appear to be easier to
understand than the old code.

Also addressed feedback from Robin and Saam in https://bugs.webkit.org/show_bug.cgi?id=213071.

Changes made:

  1. Use the new Bitmap::words() API to get direct access to the underlying bits storage. With this, we can do the merging of the marked and newlyAllocated bits with a single pass looping thru the bitmap words.
  1. In MarkedBlock::Handle::specializedSweep()'s Bitmap free list code, moved the implementation of handleDeadCells lambda down to the call to freeAtoms.forEachSetBit() because this is the only place it is used.
  1. Fixed MarkedBlock::Handle::specializedSweep()'s Bitmap free list code to handle the dead cells unconditionally. This condition check was wrongly adapted from the linked list implementation where handleDeadCell() was called in 2 places depending on the destruction mode. With the Bitmap free list, there is only once place to handle the dead cells, and it should be executed unconditionally.

This fixes a bug where the FreeList::originalSize() never gets computed if the
cells in the block does not need destruction.

  1. Renamed FreeList::bitmapRows() to FreeList::bitmapRowsMinusOne(). Renamed FreeList::offsetOfBitmapRows() to FreeList::offsetOfBitmapRowsMinusOne().
  1. Also fixed some typos in comments.
  • heap/FreeList.h:

(JSC::FreeList::bitmapIsEmpty const):
(JSC::FreeList::offsetOfBitmapRowsMinusOne):
(JSC::FreeList::bitmapRowsMinusOne const):
(JSC::FreeList::offsetOfBitmapRows): Deleted.
(JSC::FreeList::bitmapRows const): Deleted.

  • heap/FreeListInlines.h:

(JSC::FreeList::allocate):
(JSC::FreeList::forEach const):

  • heap/MarkedBlockInlines.h:

(JSC::MarkedBlock::Handle::specializedSweep):

  • jit/AssemblyHelpers.cpp:

(JSC::AssemblyHelpers::emitAllocateWithNonNullAllocator):

Source/WTF:

  1. Removed Bitmap::words. Use Bitmap::numberOfWords instead.
  2. Removed Bitmap::wordSize. Use Bitmap::bitsInWord instead.
  3. Added a new Bitmap::words() method which returns the address of the underlying bitmap storage as a Bitmap::Word*. This enables clients to do direct bit manipulation on the Bitmap words if needed.
  • wtf/Bitmap.h:

(WTF::WordType>::get const):
(WTF::WordType>::set):
(WTF::WordType>::testAndSet):
(WTF::WordType>::testAndClear):
(WTF::WordType>::concurrentTestAndSet):
(WTF::WordType>::concurrentTestAndClear):
(WTF::WordType>::clear):
(WTF::WordType>::invert):
(WTF::WordType>::nextPossiblyUnset const):
(WTF::WordType>::count const):
(WTF::WordType>::isEmpty const):
(WTF::WordType>::isFull const):
(WTF::WordType>::merge):
(WTF::WordType>::filter):
(WTF::WordType>::exclude):
(WTF::WordType>::concurrentFilter):
(WTF::WordType>::subsumes const):
(WTF::WordType>::forEachSetBit const):
(WTF::WordType>::findBit const):
(WTF::WordType>::mergeAndClear):
(WTF::WordType>::setAndClear):
(WTF::WordType>::setEachNthBit):
(WTF::= const):
(WTF::=):
(WTF::WordType>::hash const):

6:45 PM Changeset in webkit [263251] by ddkilzer@apple.com
  • 2 edits in trunk/Source/WebKit

Use fastMalloc/fastFree in WebCoreArgumentCodersMac.mm
<https://webkit.org/b/213325>

Reviewed by Darin Adler.

  • Shared/mac/WebCoreArgumentCodersMac.mm:

(IPC::createArchiveList):
(IPC::createCFURLRequestFromSerializableRepresentation):

6:43 PM Changeset in webkit [263250] by ysuzuki@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

[JSC] Remove dead non-ICU locale Date code since we are always using ICU version
https://bugs.webkit.org/show_bug.cgi?id=213362

Reviewed by Ross Kirsling.

There are old non-ICU version of Date locale code. But this is now dead code since we are always using ICU version,
which is invoked from builtin JS DatePrototype.js. We should remove these dead code.

  • runtime/DatePrototype.cpp:

(JSC::DatePrototype::finishCreation):
(): Deleted.
(JSC::styleFromArgString): Deleted.
(JSC::formatLocaleDate): Deleted.
(JSC::dateProtoFuncToLocaleString): Deleted.
(JSC::dateProtoFuncToLocaleDateString): Deleted.
(JSC::dateProtoFuncToLocaleTimeString): Deleted.

6:04 PM Changeset in webkit [263249] by ysuzuki@apple.com
  • 1 edit
    2 adds in trunk/LayoutTests

Unreviewed, fix test failure in Windows part 2
https://bugs.webkit.org/show_bug.cgi?id=213269

Looks like Windows TWR and DRT have different implementation.

  • platform/win/fast/dom/Window/alert-with-unmatched-utf16-surrogate-should-not-crash-expected.txt: Added.
  • platform/wincairo/fast/dom/Window/alert-with-unmatched-utf16-surrogate-should-not-crash-expected.txt: Added.
5:37 PM Changeset in webkit [263248] by timothy_horton@apple.com
  • 11 edits
    2 moves in trunk

Remove some vestiges of the 32-bit Plugin Process
https://bugs.webkit.org/show_bug.cgi?id=213361

Reviewed by Dan Bernstein.

.:

  • Makefile.shared:

This hack from r203348 is no longer needed, because WebKit cannot be built for 32-bit anymore.

Source/WebKit:

We haven't launched 32-bit plugins for a while, but there are some
build system complications and random references in the code that we can get rid of.

  • WebKit.xcodeproj/project.pbxproj:
  • Configurations/PluginService.xcconfig: Renamed from Source/WebKit/Configurations/PluginService.64.xcconfig.

No need for .64 in the name anymore, since it's the only one.
We do have to leave the .64 in the product name because there are other things in the system that depend on this.

  • PluginProcess/EntryPoint/Cocoa/XPCService/PluginService.Info.plist: Renamed from Source/WebKit/PluginProcess/EntryPoint/Cocoa/XPCService/PluginService.64.Info.plist.

No need for .64 in the name anymore.

  • UIProcess/AuxiliaryProcessProxy.cpp:

(WebKit::AuxiliaryProcessProxy::getLaunchOptions):

  • UIProcess/Launcher/ProcessLauncher.h:
  • UIProcess/Launcher/mac/ProcessLauncherMac.mm:

(WebKit::serviceName):

  • UIProcess/Plugins/mac/PluginProcessProxyMac.mm:

(WebKit::PluginProcessProxy::platformGetLaunchOptionsWithAttributes):
There need only be one ProcessType for the plugin process now!

  • UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp:

(WebKit::PluginProcessProxy::platformGetLaunchOptionsWithAttributes):

  • UIProcess/Launcher/glib/BubblewrapLauncher.cpp:

(WebKit::bubblewrapSpawn):

  • UIProcess/Launcher/glib/ProcessLauncherGLib.cpp:

(WebKit::ProcessLauncher::launchProcess):
GTK WebKit appears to also only launch 64-bit plugin processes.

4:42 PM Changeset in webkit [263247] by Alan Coon
  • 1 copy in tags/Safari-609.3.5.1.2

Tag Safari-609.3.5.1.2.

4:38 PM Changeset in webkit [263246] by Alan Coon
  • 8 edits in branches/safari-609.3.5.1-branch/Source

Versioning.

WebKit-609.3.5.1.2

4:34 PM Changeset in webkit [263245] by ysuzuki@apple.com
  • 3 edits in trunk/LayoutTests

Unreviewed, fix test failure in Windows
https://bugs.webkit.org/show_bug.cgi?id=213269

  • fast/dom/Window/alert-with-unmatched-utf16-surrogate-should-not-crash-expected.txt:
  • fast/dom/Window/alert-with-unmatched-utf16-surrogate-should-not-crash.html:
4:28 PM Changeset in webkit [263244] by Truitt Savell
  • 2 edits in trunk/LayoutTests

[ Catalina Debug WK2 ] fast/events/platform-wheelevent-in-scrolling-div.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=213351

Unreviewed test gardening.

Patch by Karl Rackler <Karl Rackler> on 2020-06-18

  • platform/mac-wk2/TestExpectations:
4:13 PM Changeset in webkit [263243] by Ross Kirsling
  • 3 edits in trunk/Source/JavaScriptCore

Unreviewed, address Darin's feedback on r263227.

  • runtime/IntlRelativeTimeFormat.cpp:

(JSC::IntlRelativeTimeFormat::UNumberFormatDeleter::operator() const):
(JSC::IntlRelativeTimeFormat::initializeRelativeTimeFormat):
(JSC::IntlRelativeTimeFormat::formatToParts const):

  • runtime/IntlRelativeTimeFormat.h:

Keep ownership over our UNumberFormat instance after all,
to avoid relying on behavior ICU isn't explicitly guaranteeing.

4:11 PM Changeset in webkit [263242] by Jonathan Bedard
  • 2 edits in trunk/Tools

Add SPI to preconnect to a server (Follow-up fix)
https://bugs.webkit.org/show_bug.cgi?id=213109
<rdar://problem/64184412>

Unreviewed build-fix.

  • TestWebKitAPI/Tests/WebKitCocoa/Preconnect.mm: HTTPServer does not exist if HAVE(NETWORK_FRAMEWORK) is false.
4:04 PM Changeset in webkit [263241] by Jonathan Bedard
  • 2 edits in trunk/Tools

[iOS] Two KeyboardInputTests are failing on recent iOS SDK versions (build-fix)
https://bugs.webkit.org/show_bug.cgi?id=213183
<rdar://problem/64273483>

Unreviewed build fix.

  • TestWebKitAPI/Tests/ios/KeyboardInputTestsIOS.mm:

(webViewWithAutofocusedInput): bool may not be the same type as BOOL.

3:58 PM Changeset in webkit [263240] by sbarati@apple.com
  • 2 edits in trunk/JSTests

sampling-profiler-wasm-name-section should run for more iterations
https://bugs.webkit.org/show_bug.cgi?id=207576
<rdar://problem/59431250>

Reviewed by Mark Lam.

This test was flaky because the sampling profiler is inherently probabilistic.
We need to run it for more iterations to ensure it's not flaky.

  • stress/sampling-profiler-wasm-name-section.js:
3:53 PM Changeset in webkit [263239] by Alan Coon
  • 8 edits in branches/safari-610.1.17-branch/Source

Versioning.

WebKit-610.1.17.1

3:53 PM Changeset in webkit [263238] by Alan Coon
  • 15 edits
    2 moves
    2 deletes in branches/safari-610.1.17-branch

Temporarily revert non-Hunter tested content.

3:47 PM Changeset in webkit [263237] by Alan Coon
  • 1 copy in tags/Safari-609.3.5.1.1

Tag Safari-609.3.5.1.1.

3:47 PM Changeset in webkit [263236] by Russell Epstein
  • 12 edits
    2 adds in branches/safari-609.3.5.0-branch

Apply patch. rdar://problem/64178850

3:41 PM Changeset in webkit [263235] by sbarati@apple.com
  • 2 edits in trunk/Tools

call skip when skipping JetStream2 wasm test
https://bugs.webkit.org/show_bug.cgi?id=213354

Reviewed by Yusuke Suzuki.

So we can see the logging that we're skipping.

  • Scripts/run-jsc-stress-tests:
3:37 PM Changeset in webkit [263234] by Alan Coon
  • 8 edits in branches/safari-609.3.5.1-branch/Source

Versioning.

WebKit-609.3.5.1.1

3:18 PM Changeset in webkit [263233] by Alan Coon
  • 1 copy in tags/Safari-610.1.17

Tag Safari-610.1.17.

3:16 PM Changeset in webkit [263232] by Megan Gardner
  • 2 edits in trunk/Source/WebKit

Workaround for UIKit layout bug in time picker.
https://bugs.webkit.org/show_bug.cgi?id=213346
<rdar://problem/64042277>

Reviewed by Tim Horton.

There is a bug in the layout of UIKit that needs to be fixed.
Until then, this workaround should give us a view that is viable.

  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView resignFirstResponderForWebView]):

  • UIProcess/ios/forms/WKDateTimeInputControl.mm:

(-[WKDateTimeContextMenuViewController preferredContentSize]):

3:11 PM Changeset in webkit [263231] by Devin Rousso
  • 3 edits in trunk/Source/WebCore

Web Inspector: ASSERTION FAILED: decodedLength >= dataLength at WebCore::NetworkResourcesData::ResourceData::decodeDataToContent()
https://bugs.webkit.org/show_bug.cgi?id=213271
<rdar://problem/64168350>

Reviewed by Brian Burg.

Remove the invalid ASSERT(decodedLength >= dataLength) as it's very possible for decoded
content to be smaller than encoded content (e.g. something gzipped).

Use String::sizeInBytes instead of StringImpl::sizeInBytes as the latter also includes
sizeof(*this), which is not really part of the resource's size, as it's really more of an
implementation detail.

  • inspector/NetworkResourcesData.h:
  • inspector/NetworkResourcesData.cpp:

(WebCore::NetworkResourcesData::ResourceData::removeContent):
(WebCore::NetworkResourcesData::ResourceData::decodeDataToContent):
(WebCore::NetworkResourcesData::setResourceContent):
(WebCore::NetworkResourcesData::maybeDecodeDataToContent):
(WebCore::contentSizeInBytes): Deleted.

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

[Apple Pay] Fix a log message typo in PaymentCoordinator::didAuthorizePayment

Rubber-stamped by Beth Dakin.

  • Modules/applepay/PaymentCoordinator.cpp:

(WebCore::PaymentCoordinator::didAuthorizePayment): Logged the correct function name.

2:12 PM Changeset in webkit [263229] by Russell Epstein
  • 8 edits in branches/safari-609.3.5.0-branch/Source

Versioning.

WebKit-609.3.5.0.1

1:54 PM Changeset in webkit [263228] by jh718.park@samsung.com
  • 2 edits in trunk/Tools

Unreviewed. Remove the build warning below since r262971.
warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]

  • WebKitTestRunner/TestController.cpp:

(WTR::getAllStorageAccessEntriesCallback):

1:48 PM Changeset in webkit [263227] by Ross Kirsling
  • 12 edits in trunk

[Intl] Enable RelativeTimeFormat and Locale by default
https://bugs.webkit.org/show_bug.cgi?id=213324

Reviewed by Yusuke Suzuki.

JSTests:

  • stress/intl-locale-as-intl-param.js:
  • stress/intl-locale.js:
  • stress/intl-relativetimeformat.js:
  • test262/config.yaml:

Remove feature flags.

Source/JavaScriptCore:

  • runtime/IntlObject.cpp:

(JSC::createDateTimeFormatConstructor):
(JSC::createLocaleConstructor):
(JSC::createNumberFormatConstructor):
(JSC::createRelativeTimeFormatConstructor):
(JSC::IntlObject::finishCreation):
Unconditionalize creation of RelativeTimeFormat and Locale constructors.

  • runtime/IntlRelativeTimeFormat.cpp:

(JSC::IntlRelativeTimeFormat::initializeRelativeTimeFormat):
(JSC::IntlRelativeTimeFormat::formatToParts const):
(JSC::IntlRelativeTimeFormat::UNumberFormatDeleter::operator() const): Deleted.

  • runtime/IntlRelativeTimeFormat.h:

Fix an actual bug -- URelativeDateTimeFormatter *adopts* the UNumberFormat it's instantiated with,
so we can't keep a unique_ptr to it.

  • runtime/OptionsList.h:

Remove feature flags.

Tools:

  • Scripts/run-jsc-stress-tests:

Remove feature flags.

1:34 PM WebInspectorCodingStyleGuide edited by Devin Rousso
(diff)
1:34 PM WebInspectorCodingStyleGuide edited by Devin Rousso
(diff)
1:33 PM WebInspectorCodingStyleGuide edited by Devin Rousso
(diff)
1:29 PM WebInspectorCodingStyleGuide edited by Devin Rousso
(diff)
1:25 PM WebInspectorCodingStyleGuide edited by Devin Rousso
(diff)
1:22 PM Changeset in webkit [263226] by Alan Coon
  • 8 edits in branches/safari-610.1.15.51-branch/Source

Versioning.

WebKit-610.1.15.51.5

1:12 PM Changeset in webkit [263225] by Devin Rousso
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Console: add comments for localized strings in execution context picker
https://bugs.webkit.org/show_bug.cgi?id=213280

Reviewed by Joseph Pecoraro.

  • UserInterface/Views/QuickConsole.js:

(WI.QuickConsole.prototype._populateActiveExecutionContextNavigationItemContextMenu):

  • Localizations/en.lproj/localizedStrings.js:
1:09 PM WebInspectorTests edited by Devin Rousso
(diff)
1:07 PM Changeset in webkit [263224] by aestes@apple.com
  • 2 edits in trunk/Tools

Unreviewed build fix after r263194

  • WebKitTestRunner/ios/TestControllerIOS.mm:

(WTR::TestController::platformResetStateToConsistentValues): Guarded code that mentions
UIContextMenuInteraction with USE(UICONTEXTMENU).

1:06 PM Changeset in webkit [263223] by ggaren@apple.com
  • 2 edits in trunk/Source/WTF

Unreviewed, re-landing r262904.

r263219 and r263175 should fix the test flakiness we saw.

Re-landed changeset:

"[Cocoa] Build callOnMainThread on WTF::RunLoop rather than on
a timer"
https://bugs.webkit.org/show_bug.cgi?id=213063
https://trac.webkit.org/changeset/262904

11:22 AM Changeset in webkit [263222] by Alexey Shvayka
  • 6 edits in trunk

Promise built-in functions should be anonymous non-constructors
https://bugs.webkit.org/show_bug.cgi?id=213317

Reviewed by Darin Adler.

JSTests:

  • test262/expectations.yaml: Mark 20 test cases as passing.

Source/JavaScriptCore:

This patch makes userland-exposed Promise built-in functions
non-constructors and sets their "name" properties to empty strings
as per spec [1], aligning JSC with V8 and SpiderMonkey.

@createResolvingFunctionsWithoutPromise change is covered by test262's
async-generator/yield-thenable-create-resolving-functions-*.js cases.

Promise microbenchmarks are neutral. Promise constructors bytecode is
unchanged, while @createResolvingFunctions* bytecode is reduced by 2
instructions.

[1]: https://tc39.es/ecma262/#sec-ecmascript-standard-built-in-objects

  • builtins/PromiseConstructor.js:

(nakedConstructor.Promise):
(nakedConstructor.InternalPromise):

  • builtins/PromiseOperations.js:

(globalPrivate.newPromiseCapabilitySlow):
(globalPrivate.createResolvingFunctions):
(globalPrivate.createResolvingFunctionsWithoutPromise):
(globalPrivate.createResolvingFunctions.resolve): Deleted.
(globalPrivate.createResolvingFunctions.reject): Deleted.
(resolve): Deleted.
(reject): Deleted.

  • builtins/PromisePrototype.js:

(globalPrivate.getThenFinally):
(globalPrivate.getCatchFinally):
(valueThunk): Deleted.
(thrower): Deleted.

10:47 AM Changeset in webkit [263221] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[LFC][BFC] Available space computation for the float avoider needs coordinate mapping
https://bugs.webkit.org/show_bug.cgi?id=213339

Reviewed by Antti Koivisto.

Source/WebCore:

The FloatConstraints position values are in formatting root coordinates but the available space
requires containing block coordinates.

Test: fast/layoutformattingcontext/float-avoider-available-horizontal-space.html

  • layout/blockformatting/BlockFormattingContext.cpp:

(WebCore::Layout::BlockFormattingContext::usedAvailableWidthForFloatAvoider):

LayoutTests:

  • fast/layoutformattingcontext/float-avoider-available-horizontal-space-expected.html: Added.
  • fast/layoutformattingcontext/float-avoider-available-horizontal-space.html: Added.
10:45 AM Changeset in webkit [263220] by stephan.szabo@sony.com
  • 2 edits in trunk/Source/WebCore

[PlayStation] Build fix for errors with structured bindings to const structure
https://bugs.webkit.org/show_bug.cgi?id=213323

Reviewed by Fujii Hironori.

Our system seems to have trouble with these structured bindings,
similar to what was previously seen for clang-cl.

No new tests, build fix.

  • inspector/agents/InspectorNetworkAgent.cpp:
10:42 AM Changeset in webkit [263219] by ggaren@apple.com
  • 2 edits in trunk/LayoutTests

inspector/canvas/create-context-webgpu.html was a flaky failure after r262904
https://bugs.webkit.org/show_bug.cgi?id=213343

Reviewed by Darin Adler.

This test races a zero-delay GC timer against WebCore releasing its last
reference to a WebGPU canvas. Flaky!

Make GC deterministic by continually retrying GC until the Web
Inspector is notified that the canvas has been collected.

Also make sure to stop GC'ing afterwards. I'm not sure if this matters
or not, but it is good to prevent one test from changing behavior in
another.

  • inspector/canvas/resources/create-context-utilities.js:

(destroyCanvases):

10:28 AM Changeset in webkit [263218] by youenn@apple.com
  • 4 edits in trunk

REGRESSION (r263098): [Win10] http/tests/security/cross-origin-clean-css-resource-timing.html and http/tests/security/cross-origin-css-resource-timing.html are failing
https://bugs.webkit.org/show_bug.cgi?id=213303
<rdar://problem/64452203>

Reviewed by Alex Christensen.

Source/WebCore:

Covered by existing tests.

  • loader/ResourceLoaderOptions.h:

Reverting part of https://trac.webkit.org/changeset/263098/webkit that might have broken win10 bots.

LayoutTests:

  • platform/win/TestExpectations:
10:25 AM Changeset in webkit [263217] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

[GStreamer] Avoid setting GstContext twice in GLVideoSinkGStreamer
https://bugs.webkit.org/show_bug.cgi?id=213029

Patch by Víctor Manuel Jáquez Leal <vjaquez@igalia.com> on 2020-06-18
Reviewed by Xabier Rodriguez-Calvar.

There is a reported issued in GStrearGL < 1.17 for GLBaseFilter
can't handle its GLContext and Display reassignation. This patch
aims to to avoid setting Display or GL Context in GL video sink
multiple times by checking if the video sink bin already has those
contexts.

Also, instead of relying on an assert if something goes wrong at
fetching the GL parameters, it returns an error at state change.

No new tests required.

  • platform/graphics/gstreamer/GLVideoSinkGStreamer.cpp:

(requestGLContext):
(setGLContext): new function.
(webKitGLVideoSinkChangeState):

10:10 AM Changeset in webkit [263216] by Alexey Shvayka
  • 8 edits in trunk

TypedArray.prototype.set is incorrect with primitives
https://bugs.webkit.org/show_bug.cgi?id=212730

Reviewed by Yusuke Suzuki.

JSTests:

  • test262/expectations.yaml: Mark 2 test cases as passing.

Source/JavaScriptCore:

This change implements step 14 of %TypedArray%.prototype.set [1],
which coerces primitives to objects instead of throwing an error,
aligning JSC with V8 and SpiderMonkey.

[1]: https://tc39.es/ecma262/#sec-%typedarray%.prototype.set-array-offset

  • runtime/JSGenericTypedArrayViewPrototypeFunctions.h:

(JSC::genericTypedArrayViewProtoFuncSet):

LayoutTests:

  • fast/canvas/webgl/array-get-and-set-method-removal-expected.txt:
  • fast/canvas/webgl/array-get-and-set-method-removal.html:
  • fast/canvas/webgl/array-set-invalid-arguments-expected.txt:
10:03 AM Changeset in webkit [263215] by Diego Pino Garcia
  • 3 edits
    4 adds in trunk/LayoutTests

[GTK] Unreviewed test gardening. Update test expectations after r263207.

  • platform/glib/js/dom/constructor-length-expected.txt: Updated.
  • platform/gtk/TestExpectations:
  • platform/gtk/imported/w3c/web-platform-tests/html/canvas/element/imagebitmap/createImageBitmap-serializable-expected.txt: Added.
9:52 AM Changeset in webkit [263214] by Alan Coon
  • 5 edits
    2 moves in branches/safari-610.1.17-branch/Source/WebCore

Cherry-pick r263129. rdar://problem/64492826

FileListCreator should only be used for resolving directories
https://bugs.webkit.org/show_bug.cgi?id=213259
<rdar://problem/64375709>

Reviewed by David Kilzer.

Depending on whether directories should be resolved, FileListCreator::create would either
synchronously execute its completion handler then return nullptr or asynchronously dispatch
its completion handler then return a non-null RefPtr. Interfaces with sometimes-synchronous
callbacks can be hard to use correctly; e.g., r262962 fixes a problem where
FileInputType::m_fileListCreator was being modified in an unexpected order.

This patch makes the interface between FileInputType and FileListCreator less error-prone
and more explicit by renaming FileListCreator to DirectoryFileListCreator, making its job
solely to create directory FileLists on a background queue, and giving it an explicit start
member function. For non-directories, FileInputType::filesChosen now bypasses
DirectoryFileListCreator and directly converts from Vector<FileChooserFileInfo> to FileList.

Covered by existing tests.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • html/DirectoryFileListCreator.cpp: Renamed from html/FileListCreator.cpp. (WebCore::createFileList): Removed the template and ShouldResolveDirectories parameter. (WebCore::DirectoryFileListCreator::DirectoryFileListCreator): Moved the work queue dispatching to DirectoryFileListCreator::start. (WebCore::DirectoryFileListCreator::start): Added; moved the work queue dispatching here from the ctor.
  • html/DirectoryFileListCreator.h: Renamed from html/FileListCreator.h. (WebCore::DirectoryFileListCreator::create): Stopped performing non-directory creation and changed the return value back to Ref<>.
  • html/FileInputType.cpp: (WebCore::FileInputType::filesChosen): Moved most of the work done in the FileListCreator completion handler to didCreateFileList. When !FileInputType::allowsDirectories, used Vector::map to convert paths to a Vector<Ref<File>>, used that to create a FileList, then called didCreateFileList. Otherwise, created and started a DirectoryFileListCreator that calls didCreateFileList in its completion handler. (WebCore::FileInputType::didCreateFileList): Added; sets the new file list and icon and clears m_directoryFileListCreator.
  • html/FileInputType.h:

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

9:52 AM Changeset in webkit [263213] by Alan Coon
  • 5 edits
    2 adds in branches/safari-610.1.17-branch

Cherry-pick r263128. rdar://problem/64492837

REGRESSION (r262643): DumpRenderTree at com.apple.WebCore: WebCore::Document::prepareCanvasesForDisplayIfNeeded
https://bugs.webkit.org/show_bug.cgi?id=213221
rdar://64260400

Reviewed by Simon Fraser.

Source/WebCore:

A Document could still be holding a pointer to an HTMLCanvasElement after the
canvas had been deleted because the CanvasObserver protocol was disconnected
too early. The fix is to explicitly clear the canvas from the Document as it
stops observing.

Test: webgl/preparation-removed-from-document.html

  • dom/Document.cpp: (WebCore::Document::prepareCanvasesForDisplayIfNeeded): Copy the HashSet to a Vector just in case something weird happens to the set during iteration. (WebCore::Document::clearCanvasPreparation): Remove the canvas from the list of of elements that need preparation.
  • dom/Document.h: Add the new clearCanvasPreparation method.
  • html/HTMLCanvasElement.cpp: (WebCore::HTMLCanvasElement::~HTMLCanvasElement): Clear the document. (WebCore::HTMLCanvasElement::didMoveToNewDocument): Ditto. (WebCore::HTMLCanvasElement::removedFromAncestor): Ditto.

LayoutTests:

Test that triggers a rendering on a canvas, then rips it out of
the document before drawing.

  • webgl/preparation-removed-from-document-expected.txt: Added.
  • webgl/preparation-removed-from-document.html: Added.

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

9:52 AM Changeset in webkit [263212] by Alan Coon
  • 7 edits in branches/safari-610.1.17-branch/Source/WebCore

Cherry-pick r263119. rdar://problem/64492834

Web Inspector: replace completion handler with a function in interception.
https://bugs.webkit.org/show_bug.cgi?id=213252

Patch by Pavel Feldman <pavel.feldman@gmail.com> on 2020-06-16
Reviewed by Devin Rousso.

Don't use a CompletionHandler as it asserts that it's been called when it's destroyed.
Both Network.interceptRequestWithResponse and Network.interceptRequestWithError essentially
"skip" the network pipeline, so the CompletionHandler is not invoked for those commands.

  • inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::interceptRequestImpl):
  • inspector/InspectorInstrumentation.h: (WebCore::InspectorInstrumentation::interceptRequest):
  • inspector/InspectorInstrumentationWebKit.cpp: (WebCore::InspectorInstrumentationWebKit::interceptRequestInternal):
  • inspector/InspectorInstrumentationWebKit.h: (WebCore::InspectorInstrumentationWebKit::interceptRequest):
  • inspector/agents/InspectorNetworkAgent.cpp: (WebCore::InspectorNetworkAgent::interceptRequest): (WebCore::InspectorNetworkAgent::interceptRequestWithResponse): (WebCore::InspectorNetworkAgent::interceptRequestWithError):
  • inspector/agents/InspectorNetworkAgent.h: (WebCore::InspectorNetworkAgent::PendingInterceptRequest::PendingInterceptRequest): (WebCore::InspectorNetworkAgent::PendingInterceptRequest::continueAsHandled):

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

9:32 AM Changeset in webkit [263211] by Doug Kelly
  • 4 edits in trunk/Source/WebCore

Clamp text run width to zero
https://bugs.webkit.org/show_bug.cgi?id=212655
<rdar://problem/61462335>

Reviewed by Said Abou-Hallawa.

It's possible to end up with a text run with negative width, if the text run is relatively short
and the character spacing is relatively large (but negative). If this occurs, clamp the value to
zero. This also adds additional asserts and checks to ensure the value remains non-negative.

  • platform/graphics/cg/GraphicsContextCG.cpp:

(WebCore::GraphicsContext::drawLinesForText):

  • rendering/ComplexLineLayout.cpp:

(WebCore::setLogicalWidthForTextRun):

  • rendering/RenderText.cpp:

(WebCore::RenderText::width const):

9:30 AM Changeset in webkit [263210] by Ryan Haddad
  • 2 edits in trunk/Tools

Unreviewed infrastructure fix, temporarily remove ews116 due to hardware failure tracked with rdar://64424245

  • BuildSlaveSupport/ews-build/config.json:
9:28 AM Changeset in webkit [263209] by ddkilzer@apple.com
  • 3 edits in trunk/Source/WebCore

Fix misspellings of "namespace" in comments

  • page/SpatialNavigation.h:
  • platform/gtk/RenderThemeScrollbar.cpp:
8:53 AM Changeset in webkit [263208] by ddkilzer@apple.com
  • 31 edits in trunk/Source

[IPC hardening] OptionSet<> values should be validated
<https://webkit.org/b/213199>
<rdar://problem/64369963>

Reviewed by Anders Carlsson.

Source/WebCore:

Summary:

  • Add WTF::EnumTraits<> for all OptionSet<> enums.
  • Specify unsigned backing types for enum classes.
  • loader/CrossOriginAccessControl.h:
  • page/ActivityState.h:
  • page/AutoplayEvent.h:
  • page/CrossSiteNavigationDataTransfer.h:
  • page/LayoutMilestone.h:
  • page/TextIndicator.h:
  • platform/PlatformEvent.h:
  • platform/graphics/GraphicsContext.h:

Source/WebKit:

Summary:

  • Add WTF::EnumTraits<> for all OptionSet<> enums.
  • Specify unsigned backing types for enum classes.
  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkSession.h:
  • Platform/IPC/ArgumentCoders.h:

(IPC::ArgumentCoder<OptionSet<T>>::encode):
(IPC::ArgumentCoder<OptionSet<T>>::decode):

  • Add WTF::isValidOptionSet() checks.
  • Platform/IPC/Decoder.h:
  • Platform/IPC/Encoder.h:
  • Replace <wtf/EnumTraits.h> with <wtf/OptionSet.h> since the latter now includes the former.
  • Platform/IPC/MessageFlags.h:
  • Shared/DocumentEditingContext.h:
  • Shared/RemoteLayerTree/RemoteLayerTreeTransaction.h:
  • Shared/WebEvent.h:
  • Shared/WebsiteAutoplayQuirk.h:
  • Shared/WebsiteData/WebsiteData.h:
  • Shared/WebsiteData/WebsiteDataFetchOption.h:
  • Shared/WebsiteData/WebsiteDataType.h:
  • Shared/ios/GestureTypes.h:
  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/Plugins/PluginProcessManager.h:
  • UIProcess/WebProcessProxy.h:
  • UIProcess/WebsiteData/WebsiteDataStore.h:
  • WebProcess/WebProcess.h:

Source/WTF:

  • wtf/OptionSet.h:

(WTF::isValidOptionSet): Add.

7:25 AM Changeset in webkit [263207] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

[GTK] Unreviewed test gardening. Update status of flaky timeout failures after r263206.

  • platform/gtk/TestExpectations:
4:41 AM Changeset in webkit [263206] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

[GTK] Unreviewed test gardening. Remove stale flaky failures after r263205.

  • platform/gtk/TestExpectations:
2:45 AM Changeset in webkit [263205] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

[GTK] Unreviewed test gardening. Remove stake flaky crash failures after r263204.

  • platform/gtk/TestExpectations:
1:17 AM Changeset in webkit [263204] by Carlos Garcia Campos
  • 13 edits in trunk

[GTK][WPE] Add API to configure and handle service worker registrations to WebKitWebsiteDataManager
https://bugs.webkit.org/show_bug.cgi?id=213290

Reviewed by Michael Catanzaro.

Source/WebKit:

The default path is always used even for apps setting a base data directory. We should handle
WebsiteDataType::ServiceWorkerRegistrations to configure the directory and allow to fetch and clear them.

  • UIProcess/API/glib/WebKitWebsiteData.cpp:

(recordContainsSupportedDataTypes):
(toWebKitWebsiteDataTypes):

  • UIProcess/API/glib/WebKitWebsiteDataManager.cpp:

(webkitWebsiteDataManagerGetProperty):
(webkitWebsiteDataManagerSetProperty):
(webkitWebsiteDataManagerConstructed):
(webkit_website_data_manager_class_init):
(webkitWebsiteDataManagerGetDataStore):
(webkit_website_data_manager_get_service_worker_registrations_directory):
(toWebsiteDataTypes):

  • UIProcess/API/gtk/WebKitWebsiteData.h:
  • UIProcess/API/gtk/WebKitWebsiteDataManager.h:
  • UIProcess/API/gtk/docs/webkit2gtk-4.0-sections.txt:
  • UIProcess/API/wpe/WebKitWebsiteData.h:
  • UIProcess/API/wpe/WebKitWebsiteDataManager.h:
  • UIProcess/API/wpe/docs/wpe-1.0-sections.txt:

Tools:

Handle new website data in MiniBrowser and add a unit test.

  • MiniBrowser/gtk/main.c:

(gotWebsiteDataCallback):

  • TestWebKitAPI/Tests/WebKitGLib/TestWebsiteData.cpp:

(serverCallback):
(testWebsiteDataConfiguration):
(testWebsiteDataEphemeral):
(testWebsiteDataITP):
(testWebsiteDataServiceWorkerRegistrations):
(beforeAll):

  • TestWebKitAPI/glib/WebKitGLib/TestMain.h:

(Test::Test):

1:15 AM Changeset in webkit [263203] by Carlos Garcia Campos
  • 2 edits in trunk/Source/WebCore/platform/gtk/po

[GTK] [l10n] Updated Ukrainian translation of WebKitGTK
https://bugs.webkit.org/show_bug.cgi?id=212844

Patch by Yuri Chornoivan <yurchor@ukr.net> on 2020-06-18
Rubber-stamped by Carlos Garcia Campos.

  • uk.po:
1:12 AM Changeset in webkit [263202] by Carlos Garcia Campos
  • 2 edits in trunk/Source/WebKit

Unreviewed. Fix a typo introduced in r263085

Patch by Yuri Chornoivan <yurchor@ukr.net> on 2020-06-18

  • UIProcess/API/glib/WebKitWebsiteDataManager.cpp:

(webkit_website_data_manager_class_init):

12:36 AM Changeset in webkit [263201] by Diego Pino Garcia
  • 5 edits in trunk/LayoutTests

[WPE] Unreviewed test gardening. Update test expectations after r263199.

  • platform/glib/TestExpectations:
  • platform/gtk/TestExpectations:
  • platform/wpe/TestExpectations:
  • platform/wpe/accessibility/roles-exposed-expected.txt:
Note: See TracTimeline for information about the timeline view.