Timeline



Mar 18, 2020:

10:53 PM BuildingCairoOnWindows edited by Fujii Hironori
(diff)
10:23 PM Changeset in webkit [258682] by Peng Liu
  • 6 edits in trunk/Source

The value of [AVPlayerViewController isPictureInPicturePossible] is NO in the first attempt to enter PiP
https://bugs.webkit.org/show_bug.cgi?id=204979

Reviewed by Jer Noble.

A follow-up patch to fix build failures.
Source/WebCore:

This patch also removes a meaningless line in the dealloc of WebAVPlayerViewController.

  • platform/ios/VideoFullscreenInterfaceAVKit.mm:

(-[WebAVPlayerViewController initWithFullscreenInterface:]):
(-[WebAVPlayerViewController dealloc]):
(VideoFullscreenInterfaceAVKit::doEnterFullscreen):

Source/WebCore/PAL:

  • pal/spi/cocoa/AVKitSPI.h:

Source/WTF:

  • wtf/PlatformHave.h:
10:18 PM Changeset in webkit [258681] by Andres Gonzalez
  • 2 edits in trunk/Source/WebCore

Use helper function retainPtr(T*) instead of creating one.
https://bugs.webkit.org/show_bug.cgi?id=209269

Reviewed by Chris Fleizach.

This is acorrection to patch in bug: https://bugs.webkit.org/show_bug.cgi?id=209247.
Use the existing retainPtr helper funtion instead of creating a new helper.

  • accessibility/mac/WebAccessibilityObjectWrapperMac.mm:

(-[WebAccessibilityObjectWrapper attachmentView]):
(-[WebAccessibilityObjectWrapper doAXAttributedStringForTextMarkerRange:spellCheck:]):
(-[WebAccessibilityObjectWrapper textMarkerRangeFromVisiblePositions:endPosition:]):
(-[WebAccessibilityObjectWrapper associatedPluginParent]):
(-[WebAccessibilityObjectWrapper windowElement:]):
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
(-[WebAccessibilityObjectWrapper accessibilityShowContextMenu]):
(-[WebAccessibilityObjectWrapper textMarkerRangeAtTextMarker:forUnit:]):
(-[WebAccessibilityObjectWrapper lineTextMarkerRangeForTextMarker:forUnit:]):
(-[WebAccessibilityObjectWrapper textMarkerForTextMarker:atUnit:]):
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
(retainWrapper): Deleted.

10:02 PM Changeset in webkit [258680] by Alan Bujtas
  • 5 edits
    2 adds in trunk

[Multicolumn] RenderListItem::positionListMarker should not fail when the list marker is inside a spanner.
https://bugs.webkit.org/show_bug.cgi?id=209262
<rdar://problem/58447665>

Reviewed by Simon Fraser.

Source/WebCore:

When the list marker is in a column spanner and as a result it gets moved under the column flow, the
normal "let's find the list item by walking up on the ancestor chain" does not work anymore.
We need to check if this list marker is inside a spanner and climb up on the ancestor chain by
using the spanner placeholder position (see RenderListMarker::parentBox).
This patch also moves the marker's overflow computation from the list item to the marker.

Test: fast/multicol/list-item-marker-inside-column-spanner.html

  • rendering/RenderListItem.cpp:

(WebCore::RenderListItem::addOverflowFromChildren):
(WebCore::RenderListItem::positionListMarker): Deleted.

  • rendering/RenderListMarker.cpp:

(WebCore::RenderListMarker::parentBox):
(WebCore::RenderListMarker::addOverflowFromListMarker):
(WebCore::RenderListMarker::layout):

  • rendering/RenderListMarker.h:

LayoutTests:

  • fast/multicol/list-item-marker-inside-column-spanner-expected.txt: Added.
  • fast/multicol/list-item-marker-inside-column-spanner.html: Added.
9:06 PM Changeset in webkit [258679] by Simon Fraser
  • 36 edits in trunk

eventSender.monitorWheelEvents() is very fragile
https://bugs.webkit.org/show_bug.cgi?id=197819
<rdar://problem/51319456>

Reviewed by Tim Horton.

Source/WebCore:

Deflake tests using eventSender.monitorWheelEvents() by fixing several causes of flakiness,
adding back changes from r257844 that were reverted in r258558.

First, have EventSendingController keep track of whether it's seen then "end" event
for the scrolling and momentum phases, and pass this down to WheelEventTestMonitor, which
now waits until it sees these, which prevents premature triggering which was a common cause of
failure before.

Second, remove WheelEventTestMonitor's 1/60s timer and instead have WheelEventTestMonitor test
for completion in a callout from the end of Page::updateRendering(), which makes it test
and fire at a more consistent time.

Third, push WheelEventTestMonitor to the ScrollingTree, so that reasons for deferral
can be added on the scrolling thread. This fixes an issue where the RunLoop::main().dispatch()
used to send the "ScrollingThreadSyncNeeded" reason to the main thread would get delayed,
also resulting in a premature trigger.

  • Modules/applepay/ApplePaySession.cpp: Unified sources!
  • dom/WindowEventLoop.cpp: Unified sources!
  • page/EventHandler.cpp:

(WebCore::EventHandler::handleWheelEvent):

  • page/FrameView.cpp:

(WebCore::FrameView::scrollOffsetChangedViaPlatformWidgetImpl):

  • page/Page.cpp:

(WebCore::Page::doAfterUpdateRendering):
(WebCore::Page::wheelEventTestMonitor const):
(WebCore::Page::clearWheelEventTestMonitor):
(WebCore::Page::isMonitoringWheelEvents const):
(WebCore::Page::ensureWheelEventTestMonitor):

  • page/Page.h:

(WebCore::Page::wheelEventTestMonitor const): Deleted.
(WebCore::Page::clearWheelEventTestMonitor): Deleted.
(WebCore::Page::isMonitoringWheelEvents const): Deleted.

  • page/WheelEventTestMonitor.cpp:

(WebCore::WheelEventTestMonitor::WheelEventTestMonitor):
(WebCore::WheelEventTestMonitor::clearAllTestDeferrals):
(WebCore::WheelEventTestMonitor::setTestCallbackAndStartMonitoring):
(WebCore::WheelEventTestMonitor::deferForReason):
(WebCore::WheelEventTestMonitor::removeDeferralForReason):
(WebCore::WheelEventTestMonitor::receivedWheelEvent):
(WebCore::WheelEventTestMonitor::scheduleCallbackCheck):
(WebCore::WheelEventTestMonitor::checkShouldFireCallbacks):
(WebCore::operator<<):
(WebCore::WheelEventTestMonitor::setTestCallbackAndStartNotificationTimer): Deleted.
(WebCore::WheelEventTestMonitor::triggerTestTimerFired): Deleted.

  • page/WheelEventTestMonitor.h:

(WebCore::WheelEventTestMonitorCompletionDeferrer::WheelEventTestMonitorCompletionDeferrer):
(WebCore::WheelEventTestMonitorCompletionDeferrer::~WheelEventTestMonitorCompletionDeferrer):

  • page/scrolling/AsyncScrollingCoordinator.cpp:

(WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
(WebCore::AsyncScrollingCoordinator::deferWheelEventTestCompletionForReason const): Deleted.
(WebCore::AsyncScrollingCoordinator::removeWheelEventTestCompletionDeferralForReason const): Deleted.

  • page/scrolling/AsyncScrollingCoordinator.h:
  • page/scrolling/ScrollingCoordinator.h:

(WebCore::ScrollingCoordinator::startMonitoringWheelEvents):
(WebCore::ScrollingCoordinator::stopMonitoringWheelEvents):

  • page/scrolling/ScrollingTree.cpp:

(WebCore::ScrollingTree::handleWheelEvent):

  • page/scrolling/ScrollingTree.h:

(WebCore::ScrollingTree::setWheelEventTestMonitor):
(WebCore::ScrollingTree::receivedWheelEvent):

  • page/scrolling/ThreadedScrollingTree.cpp:

(WebCore::ThreadedScrollingTree::scrollingTreeNodeDidScroll):
(WebCore::ThreadedScrollingTree::deferWheelEventTestCompletionForReason): Deleted.
(WebCore::ThreadedScrollingTree::removeWheelEventTestCompletionDeferralForReason): Deleted.

  • page/scrolling/ThreadedScrollingTree.h:
  • page/scrolling/mac/ScrollingCoordinatorMac.h:
  • page/scrolling/mac/ScrollingCoordinatorMac.mm:

(WebCore::ScrollingCoordinatorMac::startMonitoringWheelEvents):
(WebCore::ScrollingCoordinatorMac::stopMonitoringWheelEvents):

  • page/scrolling/mac/ScrollingTreeMac.h:
  • page/scrolling/mac/ScrollingTreeMac.mm:

(ScrollingTreeMac::setWheelEventTestMonitor):
(ScrollingTreeMac::receivedWheelEvent):
(ScrollingTreeMac::deferWheelEventTestCompletionForReason):
(ScrollingTreeMac::removeWheelEventTestCompletionDeferralForReason):

  • page/scrolling/mac/ScrollingTreeScrollingNodeDelegateMac.mm:

(WebCore::ScrollingTreeScrollingNodeDelegateMac::deferWheelEventTestCompletionForReason const):
(WebCore::ScrollingTreeScrollingNodeDelegateMac::removeWheelEventTestCompletionDeferralForReason const):

  • testing/js/WebCoreTestSupport.cpp:

(WebCoreTestSupport::setWheelEventMonitorTestCallbackAndStartMonitoring):
(WebCoreTestSupport::setTestCallbackAndStartNotificationTimer): Deleted.

  • testing/js/WebCoreTestSupport.h:

Source/WebKit:

Deflake tests using eventSender.monitorWheelEvents() by fixing several causes of flakiness,
adding back changes from r257844 that were reverted in r258558.

First, have EventSendingController keep track of whether it's seen then "end" event
for the scrolling and momentum phases, and pass this down to WheelEventTestMonitor, which
now waits until it sees these, which prevents premature triggering which was a common cause of
failure before.

Second, remove WheelEventTestMonitor's 1/60s timer and instead have WheelEventTestMonitor test
for completion in a callout from the end of Page::updateRendering(), which makes it test
and fire at a more consistent time.

Third, push WheelEventTestMonitor to the ScrollingTree, so that reasons for deferral
can be added on the scrolling thread. This fixes an issue where the RunLoop::main().dispatch()
used to send the "ScrollingThreadSyncNeeded" reason to the main thread would get delayed,
also resulting in a premature trigger.

  • WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:

(WKBundlePageRegisterScrollOperationCompletionCallback):

  • WebProcess/InjectedBundle/API/c/WKBundlePage.h:

Tools:

Deflake tests using eventSender.monitorWheelEvents() by fixing several causes of flakiness,
adding back changes from r257844 that were reverted in r258558.

First, have EventSendingController keep track of whether it's seen then "end" event
for the scrolling and momentum phases, and pass this down to WheelEventTestMonitor, which
now waits until it sees these, which prevents premature triggering which was a common cause of
failure before.

Second, remove WheelEventTestMonitor's 1/60s timer and instead have WheelEventTestMonitor test
for completion in a callout from the end of Page::updateRendering(), which makes it test
and fire at a more consistent time.

Third, push WheelEventTestMonitor to the ScrollingTree, so that reasons for deferral
can be added on the scrolling thread. This fixes an issue where the RunLoop::main().dispatch()
used to send the "ScrollingThreadSyncNeeded" reason to the main thread would get delayed,
also resulting in a premature trigger.

  • DumpRenderTree/mac/EventSendingController.h:
  • DumpRenderTree/mac/EventSendingController.mm:

(-[EventSendingController mouseScrollByX:andY:withWheel:andMomentumPhases:]):
(-[EventSendingController monitorWheelEvents]):
(-[EventSendingController callAfterScrollingCompletes:]):

  • DumpRenderTree/win/EventSender.cpp:

(mouseScrollBy):

  • WebKitTestRunner/InjectedBundle/EventSendingController.cpp:

(WTR::EventSendingController::mouseScrollByWithWheelAndMomentumPhases):
(WTR::EventSendingController::monitorWheelEvents):
(WTR::EventSendingController::callAfterScrollingCompletes):

  • WebKitTestRunner/InjectedBundle/EventSendingController.h:

LayoutTests:

  • platform/mac-wk2/TestExpectations:
  • platform/win/TestExpectations:
  • tiled-drawing/scrolling/scroll-snap/scroll-snap-mandatory-2d-overflow.html: Need to call eventSender.monitorWheelEvents()

for each subtest.

8:23 PM Changeset in webkit [258678] by commit-queue@webkit.org
  • 11 edits in trunk/Source

Add HTTP3 as an experimental feature
https://bugs.webkit.org/show_bug.cgi?id=209267
<rdar://problem/60245262> and <rdar://problem/60245168>

Patch by Alex Christensen <achristensen@webkit.org> on 2020-03-18
Reviewed by Brent Fulgham.

Source/WebCore/PAL:

  • pal/spi/cf/CFNetworkSPI.h:

Source/WebKit:

Manually verified this sets the CFNetwork SPI as expected.

  • NetworkProcess/NetworkSessionCreationParameters.cpp:

(WebKit::NetworkSessionCreationParameters::encode const):
(WebKit::NetworkSessionCreationParameters::decode):

  • NetworkProcess/NetworkSessionCreationParameters.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(WebKit::NetworkSessionCocoa::NetworkSessionCocoa):

  • Shared/WebPreferences.yaml:
  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::ensureNetworkProcess):

  • UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:

(WebKit::WebsiteDataStore::parameters):
(WebKit::WebsiteDataStore::http3Enabled):

  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::http3Enabled):

  • UIProcess/WebsiteData/WebsiteDataStore.h:
8:07 PM Changeset in webkit [258677] by sbarati@apple.com
  • 2 edits in trunk/Source/WebKit

SharedMemory::Handle::decode shouldn't check rounded size
https://bugs.webkit.org/show_bug.cgi?id=209263

Reviewed by Sam Weinig.

  • Platform/cocoa/SharedMemoryCocoa.cpp:

(WebKit::SharedMemory::Handle::decode):
(WebKit::SharedMemory::map):

8:05 PM Changeset in webkit [258676] by Fujii Hironori
  • 2 edits in trunk/Source/WebCore

AuthenticatorResponseData::decode should check bufferIsLargeEnoughToContain before allocating buffers
https://bugs.webkit.org/show_bug.cgi?id=209133

Reviewed by Darin Adler.

Check bufferIsLargeEnoughToContain with the decoded size before
allocating buffers.

Replaced ArrayBuffer::create with ArrayBuffer::tryCreate, and
added a null check.

  • Modules/webauthn/AuthenticatorResponseData.h:

(WebCore::encodeArrayBuffer): Added.
(WebCore::decodeArrayBuffer): Added.
(WebCore::AuthenticatorResponseData::encode const):
(WebCore::AuthenticatorResponseData::decode):

7:58 PM Changeset in webkit [258675] by Fujii Hironori
  • 2 edits in trunk/Source/WebKit

WebCoreArgumentCoders should check bufferIsLargeEnoughToContain before allocating buffers
https://bugs.webkit.org/show_bug.cgi?id=209219

Reviewed by Darin Adler.

  • Shared/WebCoreArgumentCoders.cpp:

(IPC::decodeSharedBuffer): Added checking of bufferIsLargeEnoughToContain.
(IPC::decodeTypesAndData): Don't allocate a buffer with the
decoded size. bufferIsLargeEnoughToContain can't be used in this
case because SharedBuffer is encoded as variable length data.
Instead, append items one-by-one.

7:27 PM Changeset in webkit [258674] by commit-queue@webkit.org
  • 5 edits in trunk/LayoutTests

svg/custom/animate-initial-pause-unpause.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=127116
<rdar://problem/59430898>

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2020-03-18
Reviewed by Ryosuke Niwa.

Use the 'onend' event to perform post-animation actions instead of relying
on setTimeout() which can be flaky if the bots are really slow.

  • platform/gtk/TestExpectations:
  • platform/ios-wk2/TestExpectations:
  • platform/mac/TestExpectations:
  • svg/custom/animate-initial-pause-unpause.html:
7:09 PM Changeset in webkit [258673] by Andres Gonzalez
  • 3 edits in trunk/Source/WebCore

Several TextMarker attributes need to run on the main thread.
https://bugs.webkit.org/show_bug.cgi?id=209247

Reviewed by Chris Fleizach.

  • Dispatch several TextMarker parameterized attributes to the main

thread.

  • Added helper methods to return TextMarkers and TextMarkerRanges for

diffferent units of text such as word or sentence.

  • Added a helper function, retainWrapper to make code a bit more

readable in lambda definitions.

  • accessibility/mac/AXObjectCacheMac.mm:

(WebCore::textMarkerForVisiblePosition):
(WebCore::textMarkerRangeFromVisiblePositions):

  • accessibility/mac/WebAccessibilityObjectWrapperMac.mm:

(retainWrapper):
(-[WebAccessibilityObjectWrapper attachmentView]):
(-[WebAccessibilityObjectWrapper doAXAttributedStringForTextMarkerRange:spellCheck:]):
(-[WebAccessibilityObjectWrapper textMarkerRangeFromVisiblePositions:endPosition:]):
(-[WebAccessibilityObjectWrapper associatedPluginParent]):
(-[WebAccessibilityObjectWrapper windowElement:]):
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
(-[WebAccessibilityObjectWrapper accessibilityShowContextMenu]):
(-[WebAccessibilityObjectWrapper textMarkerRangeAtTextMarker:forUnit:]):
(-[WebAccessibilityObjectWrapper lineTextMarkerRangeForTextMarker:forUnit:]):
(-[WebAccessibilityObjectWrapper textMarkerForTextMarker:atUnit:]):
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):

6:26 PM Changeset in webkit [258672] by wilander@apple.com
  • 24 edits
    6 adds in trunk

WebResourceLoadStatisticsStore::requestStorageAccessUnderOpener() should call its ephemeral counterpart when appropriate
https://bugs.webkit.org/show_bug.cgi?id=209245
<rdar://problem/60511121>

Reviewed by Chris Dumez.

Source/WebKit:

This change makes sure that WebResourceLoadStatisticsStore::requestStorageAccessUnderOpener()
calls WebResourceLoadStatisticsStore::requestStorageAccessUnderOpenerEphemeral() for ephemeral
sessions.

Tests: http/tests/storageAccess/deny-storage-access-under-opener-ephemeral.html

http/tests/storageAccess/deny-storage-access-under-opener-if-auto-dismiss-ephemeral.html
http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture-ephemeral.html

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::requestStorageAccessUnderOpener):

Tools:

These changes to the TestRunner makes sure that

  • statisticsClearInMemoryAndPersistentStore()
  • statisticsClearInMemoryAndPersistentStoreModifiedSinceHours()

... use their own StatisticsDidClearInMemoryAndPersistentStoreCallbackID
and adds the infrastructure for that.

  • WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:

(WTR::InjectedBundle::didReceiveMessageToPage):

  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::statisticsClearInMemoryAndPersistentStore):
(WTR::TestRunner::statisticsClearInMemoryAndPersistentStoreModifiedSinceHours):
(WTR::TestRunner::statisticsCallClearInMemoryAndPersistentStoreCallback):

  • WebKitTestRunner/InjectedBundle/TestRunner.h:
  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::statisticsClearInMemoryAndPersistentStore):
(WTR::TestController::statisticsClearInMemoryAndPersistentStoreModifiedSinceHours):

  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::didClearStatisticsInMemoryAndPersistentStore):

  • WebKitTestRunner/TestInvocation.h:

LayoutTests:

There are new tests added for the code change. The rest of these change are to better
align test cases with asynchronous TestRunner functions that landed in
https://trac.webkit.org/changeset/258566 and https://trac.webkit.org/changeset/258598.

While working on the new tests, I found a crasher which Chris Dumez fixed in
https://trac.webkit.org/changeset/258562, so there's a dependency on that change.

  • http/tests/resourceLoadStatistics/cookies-with-and-without-user-interaction-database.html:
  • http/tests/resourceLoadStatistics/cookies-with-and-without-user-interaction.html:
  • http/tests/resourceLoadStatistics/count-third-party-script-import-in-worker-database.html:
  • http/tests/resourceLoadStatistics/count-third-party-script-import-in-worker.html:
  • http/tests/resourceLoadStatistics/count-third-party-script-loads-database.html:
  • http/tests/resourceLoadStatistics/count-third-party-script-loads.html:
  • http/tests/resourceLoadStatistics/do-not-switch-session-on-navigation-to-prevalent-without-interaction-database.php:
  • http/tests/resourceLoadStatistics/do-not-switch-session-on-navigation-to-prevalent-without-interaction.php:
  • http/tests/resourceLoadStatistics/dont-count-third-party-image-as-third-party-script-database.html:
  • http/tests/resourceLoadStatistics/dont-count-third-party-image-as-third-party-script.html:
  • http/tests/resourceLoadStatistics/grandfathering-database.html:
  • http/tests/resourceLoadStatistics/grandfathering.html:
  • http/tests/resourceLoadStatistics/switch-session-on-navigation-to-prevalent-with-interaction-database.php:
  • http/tests/resourceLoadStatistics/switch-session-on-navigation-to-prevalent-with-interaction.php:
  • http/tests/storageAccess/deny-storage-access-under-opener-ephemeral-expected.txt: Added.
  • http/tests/storageAccess/deny-storage-access-under-opener-ephemeral.html: Added.
  • http/tests/storageAccess/deny-storage-access-under-opener-if-auto-dismiss-ephemeral-expected.txt: Added.
  • http/tests/storageAccess/deny-storage-access-under-opener-if-auto-dismiss-ephemeral.html: Added.
  • http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture-ephemeral-expected.txt: Added.
  • http/tests/storageAccess/grant-storage-access-under-opener-at-popup-user-gesture-ephemeral.html: Added.
5:54 PM WebKitGTK/2.28.x edited by clopez@igalia.com
(diff)
5:41 PM Changeset in webkit [258671] by Brent Fulgham
  • 2 edits in trunk/Source/WebKit

Avoid calling 'notifyThisWebProcessPoolWasCreated' inside the constructor
https://bugs.webkit.org/show_bug.cgi?id=209254
<rdar://problem/60564526>

Reviewed by Alex Christensen and Chris Dumez.

Enqueue calls to 'notifyThisWebProcessPoolWasCreated' so they are not invoked until
after the process pool is finished with its constructor.

Behavior covered by existing tests.

  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::WebProcessPool):

5:04 PM Changeset in webkit [258670] by Ross Kirsling
  • 2 edits in trunk/Source/WebKit

Unreviewed WinCairo build fix following r258665.

  • NetworkProcess/curl/NetworkProcessCurl.cpp:

(WebKit::NetworkProcess::clearCacheForAllOrigins): Deleted.

4:45 PM Changeset in webkit [258669] by Ryan Haddad
  • 3 edits in trunk/LayoutTests

svg/as-object/object-box-sizing-no-width-height.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=209257

Unreviewed test gardening.

  • platform/ios/TestExpectations: Mark test as flaky.
  • platform/mac/TestExpectations: Ditto.
4:22 PM Changeset in webkit [258668] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Unreviewed test gardening.

  • platform/ios/TestExpectations: Skip the http/wpt/notifications directory on iOS.
4:09 PM Changeset in webkit [258667] by Kate Cheney
  • 28 edits
    1 copy in trunk/Source/WebKit

Pass isNavigatingToAppBoundDomain for speculative loads, preconnect tasks and downloads
https://bugs.webkit.org/show_bug.cgi?id=209246
<rdar://problem/60552712>

Reviewed by Alex Christensen.

Pass isNavigatingToAppBoundDomain in 4 new places:

1) Speculative Loads
2) Preconnect Tasks
3) Downloads
4) CORS preflight checker

These loads should happen in an app-bound session if isNavigatingToAppBoundDomain
is true.

  • NetworkProcess/Downloads/DownloadManager.cpp:

(WebKit::DownloadManager::startDownload):

  • NetworkProcess/Downloads/DownloadManager.h:

(WebKit::DownloadManager::startDownload):

  • NetworkProcess/Downloads/PendingDownload.cpp:

(WebKit::PendingDownload::PendingDownload):

  • NetworkProcess/NetworkConnectionToWebProcess.cpp:

(WebKit::NetworkConnectionToWebProcess::startDownload):
(WebKit::NetworkConnectionToWebProcess::convertMainResourceLoadToDownload):

  • NetworkProcess/NetworkConnectionToWebProcess.h:

(WebKit::NetworkConnectionToWebProcess::startDownload):

  • NetworkProcess/NetworkConnectionToWebProcess.messages.in:
  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::preconnectTo):
(WebKit::NetworkProcess::downloadRequest):

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcess.messages.in:
  • NetworkProcess/NetworkResourceLoader.cpp:

(WebKit::NetworkResourceLoader::start):
(WebKit::NetworkResourceLoader::retrieveCacheEntry):
(WebKit::NetworkResourceLoader::convertToDownload):

  • NetworkProcess/PreconnectTask.cpp:
  • NetworkProcess/ServiceWorker/ServiceWorkerSoftUpdateLoader.cpp:

(WebKit::ServiceWorkerSoftUpdateLoader::ServiceWorkerSoftUpdateLoader):
The service worker script should be considered an app-bound load.

  • NetworkProcess/cache/AsyncRevalidation.cpp:

(WebKit::NetworkCache::AsyncRevalidation::AsyncRevalidation):

  • NetworkProcess/cache/AsyncRevalidation.h:
  • NetworkProcess/cache/NetworkCache.cpp:

(WebKit::NetworkCache::Cache::startAsyncRevalidationIfNeeded):
(WebKit::NetworkCache::Cache::retrieve):

  • NetworkProcess/cache/NetworkCache.h:
  • NetworkProcess/cache/NetworkCacheSpeculativeLoad.cpp:

(WebKit::NetworkCache::SpeculativeLoad::SpeculativeLoad):

  • NetworkProcess/cache/NetworkCacheSpeculativeLoad.h:
  • NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.cpp:

(WebKit::NetworkCache::SpeculativeLoadManager::registerLoad):
(WebKit::NetworkCache::SpeculativeLoadManager::preconnectForSubresource):
(WebKit::NetworkCache::SpeculativeLoadManager::revalidateSubresource):
(WebKit::NetworkCache::SpeculativeLoadManager::preloadEntry):
(WebKit::NetworkCache::SpeculativeLoadManager::startSpeculativeRevalidation):

  • NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(WebKit::NetworkSessionCocoa::sessionWrapperForTask):

  • Shared/NavigatingToAppBoundDomain.h:

Separates NavigatingToAppBoundDomain to its own file to allow for
sending over IPC.

  • Shared/PolicyDecision.h:
  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::preconnectTo):

  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::setIsNavigatingToAppBoundDomain):
(WebKit::WebPageProxy::preconnectTo):

  • UIProcess/WebPageProxy.h:

(WebKit::WebPageProxy::isNavigatingToAppBoundDomain const):

  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::download):

  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::preconnectTo):

  • WebProcess/WebPage/WebFrame.cpp:

(WebKit::WebFrame::startDownload):
(WebKit::WebFrame::convertMainResourceLoadToDownload):

3:48 PM Changeset in webkit [258666] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[MultiColumn] Ignore spanner boxes inside <legend>
https://bugs.webkit.org/show_bug.cgi?id=209248
<rdar://problem/51857865>

Reviewed by Simon Fraser.

Source/WebCore:

<legend> boxes don't participate in the multicolumn flow, they are simply ignored.
This patch ensures that we don't include their descendants in the spanner construction.
<column>some<legend><div spanner></div></legend>content</column> <- the "spanner" div won't span the column content.

Test: fast/multicol/spanner-inside-legend-crash.html

  • rendering/updating/RenderTreeBuilderMultiColumn.cpp:

(WebCore::isValidColumnSpanner):

LayoutTests:

  • fast/multicol/spanner-inside-legend-crash-expected.txt: Added.
  • fast/multicol/spanner-inside-legend-crash.html: Added.
3:30 PM Changeset in webkit [258665] by sihui_liu@apple.com
  • 10 edits
    1 delete in trunk/Source/WebKit

Remove unused IPC message NetworkProcess::ClearCacheForAllOrigins
https://bugs.webkit.org/show_bug.cgi?id=209152
<rdar://problem/59681717>

Reviewed by Chris Dumez.

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcess.messages.in:
  • NetworkProcess/ios/NetworkProcessIOS.mm:

(WebKit::NetworkProcess::clearCacheForAllOrigins): Deleted.

  • NetworkProcess/mac/NetworkProcessMac.mm:

(WebKit::NetworkProcess::clearCacheForAllOrigins): Deleted.

  • NetworkProcess/soup/NetworkProcessSoup.cpp:

(WebKit::NetworkProcess::clearCacheForAllOrigins): Deleted.

  • Shared/ResourceCachesToClear.h: Removed.
  • UIProcess/API/C/WKAPICast.h:

(WebKit::toResourceCachesToClear): Deleted.

  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::clearResourceCaches): Deleted.

  • WebProcess/WebProcess.h:
3:27 PM Changeset in webkit [258664] by ysuzuki@apple.com
  • 9 edits
    1 add in trunk

Add a way to mark a rejected promise as handled
https://bugs.webkit.org/show_bug.cgi?id=209241

Reviewed by Michael Saboff.

JSTests:

  • stress/reject-as-handled.js: Added.

(shouldBe):
(set new):

Source/JavaScriptCore:

Some of WebCore promise implementations (WebAnimation etc.) want to reject promise
as handled state to suppress UnhandledPromiseRejection tracking. For example, a
lot of WebCore implementations expose Promise DOM attributes which will be rejected
at some conditions. But we do not want to force users setting a handler for each such an
attribute.

This patch adds JSPromise::rejectAsHandled C++ function. This simply sets isHandledFlag
before executing JSPromise::reject if we are not calling a reject function yet.

  • runtime/JSPromise.cpp:

(JSC::JSPromise::rejectAsHandled):

  • runtime/JSPromise.h:
  • tools/JSDollarVM.cpp:

(JSC::functionRejectPromiseAsHandled):
(JSC::JSDollarVM::finishCreation):

Source/WebCore:

This adds an interface using JSPromise::rejectAsHandled to DOMPromise classes.

  • bindings/js/DOMPromiseProxy.h:

(WebCore::DOMPromiseProxy<IDLType>::reject):
(WebCore::DOMPromiseProxy<IDLVoid>::reject):
(WebCore::DOMPromiseProxyWithResolveCallback<IDLType>::reject):

  • bindings/js/JSDOMPromiseDeferred.cpp:

(WebCore::DeferredPromise::callFunction):
(WebCore::DeferredPromise::reject):

  • bindings/js/JSDOMPromiseDeferred.h:

(WebCore::DeferredPromise::reject):
(WebCore::DeferredPromise::rejectWithCallback):
(WebCore::DOMPromiseDeferredBase::reject):
(WebCore::DOMPromiseDeferredBase::rejectType):

1:30 PM Changeset in webkit [258663] by youenn@apple.com
  • 14 edits in trunk/Source

WebPage should own a Ref<WebFrame>
https://bugs.webkit.org/show_bug.cgi?id=209235

Reviewed by Geoffrey Garen.

Source/WebCore:

  • loader/FrameLoaderStateMachine.h:

Export committedFirstRealDocumentLoad/

Source/WebKit:

Update code since m_mainFrame is now a Ref and no longer a RefPtr.

Update WebPage constructor to set its m_mainFrame very early.
We update WebPage::didCompletePageTransition to compute whether this is initialization or not using the frame state machine state
instead of m_mainFrame being null.

  • WebProcess/Automation/WebAutomationSessionProxy.cpp:

(WebKit::WebAutomationSessionProxy::evaluateJavaScriptFunction):
(WebKit::WebAutomationSessionProxy::resolveChildFrameWithOrdinal):
(WebKit::WebAutomationSessionProxy::resolveChildFrameWithNodeHandle):
(WebKit::WebAutomationSessionProxy::resolveChildFrameWithName):
(WebKit::WebAutomationSessionProxy::resolveParentFrame):
(WebKit::WebAutomationSessionProxy::focusFrame):
(WebKit::WebAutomationSessionProxy::computeElementLayout):
(WebKit::WebAutomationSessionProxy::selectOptionElement):
(WebKit::WebAutomationSessionProxy::setFilesForInputFileUpload):
(WebKit::WebAutomationSessionProxy::takeScreenshot):
(WebKit::WebAutomationSessionProxy::snapshotRectForScreenshot):
(WebKit::WebAutomationSessionProxy::getCookiesForFrame):
(WebKit::WebAutomationSessionProxy::deleteCookie):

  • WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:

(WKBundlePageGetMainFrame):

  • WebProcess/WebCoreSupport/WebChromeClient.cpp:

(WebKit::findLargestFrameInFrameSet):
(WebKit::WebChromeClient::closeWindowSoon):

  • WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:

(WebKit::WebFrameLoaderClient::dispatchDidReachLayoutMilestone):
(WebKit::WebFrameLoaderClient::dispatchDidLayout):
(WebKit::WebFrameLoaderClient::restoreViewState):

  • WebProcess/WebPage/ViewGestureGeometryCollector.cpp:

(WebKit::ViewGestureGeometryCollector::collectGeometryForSmartMagnificationGesture):
(WebKit::ViewGestureGeometryCollector::collectGeometryForMagnificationGesture):

  • WebProcess/WebPage/WebBackForwardListProxy.cpp:

(WebKit::WebBackForwardListProxy::goToItem):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::WebPage):
(WebKit::m_processDisplayName):
(WebKit::WebPage::close):
(WebKit::WebPage::suspendForProcessSwap):
(WebKit::WebPage::loadDataInFrame):
(WebKit::WebPage::loadRequest):
(WebKit::WebPage::reload):
(WebKit::WebPage::didCompletePageTransition):
(WebKit::WebPage::runJavaScriptInFrameInScriptWorld):
(WebKit::WebPage::setIsSuspended):
(WebKit::WebPage::didLoadFromRegistrableDomain):

  • WebProcess/WebPage/WebPage.h:

(WebKit::WebPage::mainWebFrame const):

  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::cancelPotentialTap):

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::origin):

1:23 PM Changeset in webkit [258662] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

Source/WebCore:
Fix ReplaceSelectionCommand::InsertedNodes::willRemoveNodePreservingChildren crash
https://bugs.webkit.org/show_bug.cgi?id=208312

Patch by Eugene But <eugenebut@chromium.org> on 2020-03-18
Reviewed by Ryosuke Niwa

ReplaceSelectionCommand::InsertedNodes::willRemoveNodePreservingChildren
was crashing on dereferencing m_firstNodeInserted pointer. Before the crash
ReplaceSelectionCommand::InsertedNodes object received the following calls:

respondToNodeInsertion() with node A, which set m_firstNodeInserted and m_lastNodeInserted to A
willRemoveNode() with node B, which left m_firstNodeInserted and m_lastNodeInserted unchanged (A)
(node A was destroyed setting m_firstNodeInserted and m_lastNodeInserted to null)
respondToNodeInsertion() with node C, which set m_firstNodeInserted and m_lastNodeInserted to C
willRemoveNodePreservingChildren() with node C, which set m_firstNodeInserted to null and crashed

This patch checks m_firstNodeInserted before dereferencing and sets m_lastNodeInserted to null if
m_firstNodeInserted became null. It seems like having non-null value for m_lastNodeInserted would
be an invalid state.

Test: editing/pasteboard/insert-apple-style-span-after-timeout.html

  • editing/ReplaceSelectionCommand.cpp:

(WebCore::ReplaceSelectionCommand::InsertedNodes::willRemoveNodePreservingChildren):

LayoutTests:
Test for ReplaceSelectionCommand::InsertedNodes::willRemoveNodePreservingChildren crash fix
https://bugs.webkit.org/show_bug.cgi?id=208312

Patch by Eugene But <eugenebut@chromium.org> on 2020-03-18
Reviewed by Ryosuke Niwa

This test insers empty Apple-style-span after timeout to a non-empty document.

  • editing/pasteboard/insert-apple-style-span-after-timeout.html:
12:52 PM Changeset in webkit [258661] by mmaxfield@apple.com
  • 6 edits
    2274 adds in trunk/LayoutTests

[CSS Writing Modes] Import css/css-writing-modes from WPT
https://bugs.webkit.org/show_bug.cgi?id=209088

Patch by Frank Yang <guowei_yang@apple.com> on 2020-03-18
Reviewed by Myles C. Maxfield.

LayoutTests/imported/w3c:

Imported new tests in css-writing-mode from web platform tests. Those
tests are important for testing CSS property behaviors like "text-orientation"

  • resources/import-expectations.json:
  • resources/resource-files.json:
  • web-platform-tests/css/css-writing-modes/*: Added.

LayoutTests:

Turns out that the imported tests from w3c in LayoutTests doesn't included
css-writing-modes, which is a set of tests that checks the behavior of
css properties like "text-orientation". This patch is for importing those
tests in LayoutTests/import/w3c/css.

12:40 PM Changeset in webkit [258660] by youenn@apple.com
  • 3 edits in trunk/Source/WebCore

CrossOriginPreflightResultCacheItem::allows methods should not use out parameters
https://bugs.webkit.org/show_bug.cgi?id=209224

Reviewed by Alex Christensen.

Instead of having an out parameter for the error description, either return whether there is an error or not.
Covered by existing tests.

  • loader/CrossOriginPreflightResultCache.cpp:

(WebCore::CrossOriginPreflightResultCacheItem::validateMethodAndHeaders const):
(WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginMethod const):
(WebCore::CrossOriginPreflightResultCacheItem::validateCrossOriginHeaders const):
(WebCore::CrossOriginPreflightResultCacheItem::allowsRequest const):
(WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginHeaders const): Deleted.

  • loader/CrossOriginPreflightResultCache.h:
12:31 PM Changeset in webkit [258659] by Wenson Hsieh
  • 5 edits in trunk

REGRESSION (r257214): Targeted preview animates to the wrong place when dropping in editable content
https://bugs.webkit.org/show_bug.cgi?id=209218
<rdar://problem/60560831>

Reviewed by Tim Horton.

Source/WebKit:

In r257214, we split out the context menu hint preview container view into two views: one for drag and drop, and
another for the context menu hint. The container view used for both drag and drop previews was removed under
-cleanUpDragSourceSessionState, which is invoked after both drag and drop sessions have ended; however, in the
case of a drop in editable content where the drop preview is delayed, the drop animation can end up finishing
after -cleanUpDragSourceSessionState is invoked. This means we end up prematurely unparenting the preview
container, which results in a broken drop animation.

To fix this, split the drag and drop container views further, into separate container views for dragging and for
dropping. The drag preview container will continue to be removed under -cleanUpDragSourceSessionState, and the
drop preview container will now be removed under the delegate call to -dropInteraction:concludeDrop:, which is
invoked by UIKit after all drop previews are finished animating.

Covered by adding additional test assertions while running existing API tests (see Tools/ChangeLog for more
details).

  • UIProcess/ios/WKContentViewInteraction.h:
  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView _createPreviewContainerWithLayerName:]):

Pull out common logic for creating and setting up a preview container view into a helper method. This is used by
the three methods below, which ensure container views for each of the types of previews we create when showing
the context menu, dragging an element, and dropping.

(-[WKContentView containerForDropPreviews]):
(-[WKContentView containerForDragPreviews]):
(-[WKContentView containerForContextMenuHintPreviews]):

Add a third preview container view for drop previews, and factor duplicated code in these three methods into a
common helper (see above).

(-[WKContentView _hideTargetedPreviewContainerViews]):
(-[WKContentView _deliverDelayedDropPreviewIfPossible:]):

Instead of using the container for drag previews, use the container for drop previews.

(-[WKContentView dropInteraction:concludeDrop:]):

Remove the drop preview container after the drop has concluded (i.e. all animations are complete).

Tools:

Augment the drag and drop test harness to verify that for all targeted previews, if they have container views,
those views must be parented (i.e. they must be connected to a UIWindow).

  • TestWebKitAPI/ios/DragAndDropSimulatorIOS.mm:

(-[DragAndDropSimulator _concludeDropAndPerformOperationIfNecessary]):
(-[DragAndDropSimulator _expectNoDropPreviewsWithUnparentedContainerViews]):
(-[DragAndDropSimulator _invokeDropAnimationCompletionBlocksAndConcludeDrop]):

12:28 PM Changeset in webkit [258658] by mmaxfield@apple.com
  • 2 edits in trunk/Source/WTF

REGRESSION(r254389): Cordova throws an exception because it expects a hyphen inside navigator.locale
https://bugs.webkit.org/show_bug.cgi?id=208969
<rdar://problem/59845517>

Reviewed by Darin Adler.

We want to thwart fingerprinting by minimizing the list of locales, but we also don't want to break existing apps.
We can achieve both by a linked-on-or-after check.

  • wtf/cocoa/LanguageCocoa.mm:

(WTF::canMinimizeLanguages):

12:24 PM Changeset in webkit [258657] by graouts@webkit.org
  • 4 edits in trunk/LayoutTests

[macOS WK1] Layout Test media/modern-media-controls/compact-media-controls/compact-media-controls-constructor.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=192974
<rdar://problem/59063969>

Reviewed by Dean Jackson.

Since the console output is not guaranteed to appear in a deterministic order, we supress it.

  • media/modern-media-controls/compact-media-controls/compact-media-controls-constructor-expected.txt:
  • media/modern-media-controls/compact-media-controls/compact-media-controls-constructor.html:
  • platform/mac-wk1/TestExpectations:
12:22 PM Changeset in webkit [258656] by graouts@webkit.org
  • 4 edits in trunk/LayoutTests

[ Mac WK1 ] Layout Test media/modern-media-controls/compact-media-controls/compact-media-controls-layout.html is a flaky text diff failure
https://bugs.webkit.org/show_bug.cgi?id=194309
<rdar://problem/48012947>

Reviewed by Dean Jackson.

Since the console output is not guaranteed to appear in a deterministic order, we supress it.

  • media/modern-media-controls/compact-media-controls/compact-media-controls-layout-expected.txt:
  • media/modern-media-controls/compact-media-controls/compact-media-controls-layout.html:
  • platform/mac-wk1/TestExpectations:
12:18 PM Changeset in webkit [258655] by Peng Liu
  • 4 edits in trunk/Source/WebCore

The value of [AVPlayerViewController isPictureInPicturePossible] is NO in the first attempt to enter PiP
https://bugs.webkit.org/show_bug.cgi?id=204979

Reviewed by Jer Noble.

Source/WebCore:

Since [AVPlayerViewControl isPictureInPicturePossible] can be NO initially, we may fail to enter
the Picture-in-Picture mode.

This patch implements the mechanism to observe [AVPlayerViewControl isPictureInPicturePossible] after
a user requests to enter the Picture-in-Picture mode, and call [AVPlayerViewController startPictureInPicture]
when [AVPlayerViewController isPictureInPicturePossible] changes to YES.
A timer is added to monitor the status. If [AVPlayerViewController isPictureInPicturePossible] does not
change to YES in 0.5 second, we will give up the attempt.

  • platform/ios/VideoFullscreenInterfaceAVKit.mm:

(-[WebAVPlayerViewController initWithFullscreenInterface:]):
(-[WebAVPlayerViewController dealloc]):
(-[WebAVPlayerViewController MY_NO_RETURN]):
(VideoFullscreenInterfaceAVKit::doEnterFullscreen):

Source/WebCore/PAL:

import AVKit/AVObservationController.h

  • pal/spi/cocoa/AVKitSPI.h:
12:09 PM Changeset in webkit [258654] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Unreviewed, fix iOS build with recent SDKs.

  • Platform/cocoa/PaymentAuthorizationViewController.mm:
11:15 AM Changeset in webkit [258653] by Megan Gardner
  • 2 edits in trunk/Source/WebKit

Remove unneeded and incorrect respondsToSelector checks.
https://bugs.webkit.org/show_bug.cgi?id=209208
<rdar://problem/60512470>

Reviewed by Tim Horton.

No behaviour change, no tests needed.

  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView continueContextMenuInteractionWithDataDetectors:]):

11:15 AM Changeset in webkit [258652] by aakash_jain@apple.com
  • 3 edits in trunk/Tools

[ews] commit-queue should comment on bug in case of test failures
https://bugs.webkit.org/show_bug.cgi?id=209226

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-build/steps.py:

(AnalyzeLayoutTestsResults.report_failure): Comment on bug and set cq- in case of test failure on commit-queue.
(BuildLogLineObserver.outLineReceived): Drive-by fix to use single quotes instead of double quotes.
(SetBuildSummary): Ditto.

  • BuildSlaveSupport/ews-build/steps_unittest.py: Added unit-test.
11:12 AM Changeset in webkit [258651] by commit-queue@webkit.org
  • 4 edits in trunk

frame/iframe scrolling attribute does to recognize value "noscroll" or "off"
https://bugs.webkit.org/show_bug.cgi?id=208570

Patch by Frederic Wang <fwang@igalia.com> on 2020-03-18
Reviewed by Rob Buis.

Source/WebCore:

Tests: imported/w3c/web-platform-tests/html/rendering/non-replaced-elements/the-page/iframe-scrolling-attribute.html

imported/w3c/web-platform-tests/html/rendering/non-replaced-elements/the-page/iframe-scrolling-attribute-values.html

  • html/HTMLFrameElementBase.cpp:

(WebCore::HTMLFrameElementBase::scrollingMode const): Treat "noscroll" and "off" the same as "no".

LayoutTests:

11:09 AM Changeset in webkit [258650] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

[ Mac ] imported/w3c/web-platform-tests/web-animations/timing-model/timelines/update-and-send-events-replacement.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=209239

Unreviewed test gardening.

  • platform/mac/TestExpectations:
10:57 AM Changeset in webkit [258649] by Chris Dumez
  • 9 edits in trunk

[ Mac wk2 ] http/wpt/beacon/beacon-quota.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=207894
<rdar://problem/59551688>

Reviewed by Geoffrey Garen.

Source/WebCore:

Add internals API exposing the number of inflight beacon loads for a given navigator object
so that the test can rely on it.

  • Modules/beacon/NavigatorBeacon.h:
  • testing/Internals.cpp:

(WebCore::Internals::inflightBeaconsCount const):

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

LayoutTests:

Update test to address flakiness and unskip it.

  • http/wpt/beacon/beacon-quota-expected.txt:
  • http/wpt/beacon/beacon-quota.html:
  • platform/mac-wk2/TestExpectations:
10:55 AM Changeset in webkit [258648] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebCore

[intersection-observer] Accept a Document as an explicit root
https://bugs.webkit.org/show_bug.cgi?id=208047

Patch by Frederic Wang <fwang@igalia.com> on 2020-03-18
Reviewed by Rob Buis.

No new tests, no behavior change.

  • page/IntersectionObserver.cpp:

(WebCore::IntersectionObserver::create):
(WebCore::IntersectionObserver::IntersectionObserver):

  • page/IntersectionObserver.h:

(WebCore::IntersectionObserver::root const):

10:40 AM Changeset in webkit [258647] by Brent Fulgham
  • 2 edits in trunk/Source/WebKit

Switch from debug ASSERT to RELEASE_ASSERT in toNPObjectProxy
https://bugs.webkit.org/show_bug.cgi?id=209212
<rdar://problem/59595502>

Reviewed by Alex Christensen.

  • Shared/Plugins/NPObjectProxy.h:

(WebKit::NPObjectProxy::toNPObjectProxy):

10:37 AM Changeset in webkit [258646] by Brent Fulgham
  • 2 edits in trunk/Source/WebKit

Switch to release asserts for MediaDeviceSandboxExtension class
https://bugs.webkit.org/show_bug.cgi?id=209211
<rdar://problem/59595299>

Reviewed by Eric Carlson.

Switch from debug ASSERT to RELEASE_ASSERT.

  • WebProcess/MediaStream/MediaDeviceSandboxExtensions.cpp:

(WebKit::MediaDeviceSandboxExtensions::MediaDeviceSandboxExtensions):
(WebKit::MediaDeviceSandboxExtensions::operator[]):

10:24 AM Changeset in webkit [258645] by Brent Fulgham
  • 2 edits in trunk/Source/WebKit

Switch from debug ASSERT to RELEASE_ASSERT in PluginQuirks.h
https://bugs.webkit.org/show_bug.cgi?id=209213
<rdar://problem/59595834>

Reviewed by Alex Christensen.

  • Shared/Plugins/PluginQuirks.h:

(WebKit::PluginQuirks::add):

10:09 AM Changeset in webkit [258644] by Philippe Normand
  • 2 edits in trunk/Tools

REGRESSION (r258626): test262 tests failing to run on macOS with error 'Undefined subroutine &Test262::Runner::setConfiguration'
https://bugs.webkit.org/show_bug.cgi?id=209238

Reviewed by Jonathan Bedard.

  • Scripts/test262-runner: Perform the flatpak check on Linux only.
10:07 AM Changeset in webkit [258643] by stephan.szabo@sony.com
  • 2 edits in trunk/Tools

[WinCairo] archive-built-product fails after r258612
https://bugs.webkit.org/show_bug.cgi?id=209237

Reviewed by Alex Christensen.

  • BuildSlaveSupport/built-product-archive:

Update name of version file for requirements version
file for wincairo.

10:02 AM Changeset in webkit [258642] by aakash_jain@apple.com
  • 2 edits in trunk/Tools

commit-queue should allow patches which are reviewed by patch author
https://bugs.webkit.org/show_bug.cgi?id=209231

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-build/steps.py:

(BugzillaMixin._does_patch_have_acceptable_review_flag):

9:18 AM Changeset in webkit [258641] by Philippe Normand
  • 2 edits in trunk/Tools

[JHBuild] Flatpak used for run-minibrowser even when forcing jhbuild
https://bugs.webkit.org/show_bug.cgi?id=209222

Reviewed by Carlos Alberto Lopez Perez.

  • Scripts/webkitdirs.pm:

(runInFlatpakIfAvailable): If a command wrapper is required it
means Flatpak shouldn't be used.

9:07 AM Changeset in webkit [258640] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

Default attachment icon is not necessarily the same as the file attachment icon whose extension is ".dat"
https://bugs.webkit.org/show_bug.cgi?id=209210
<rdar://problem/59606671>

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2020-03-18
Reviewed by Daniel Bates.

Ensure that the default attachment icon is the one which iconForFileType
returns for "public.data" icon.

  • fast/attachment/attachment-default-icon-expected.html:
8:59 AM Changeset in webkit [258639] by graouts@webkit.org
  • 5 edits in trunk/LayoutTests

[macOS iOS ] animations/animation-direction-normal.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=206685
<rdar://problem/58841791>

Reviewed by Antti Koivisto.

To make this test robust we animate a non-accelerated property and we use the Web Animations API to set the time
at which we want to pause the animation (2.5s).

  • animations/animation-direction-normal-expected.txt:
  • animations/animation-direction-normal.html:
  • platform/ios-wk2/TestExpectations:
  • platform/mac/TestExpectations:
8:38 AM Changeset in webkit [258638] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

[ iOS wk2 Release ] platform/ios/ios/plugin/youtube-flash-plugin-iframe-no-height-or-width.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=209234

Unreviewed test gardening.

  • platform/ios-simulator-wk2/TestExpectations:
8:35 AM Changeset in webkit [258637] by aakash_jain@apple.com
  • 3 edits in trunk/Tools

[ews] commit-queue should comment on bug in case patch fails to build
https://bugs.webkit.org/show_bug.cgi?id=209227

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-build/steps.py:

(AnalyzeCompileWebKitResults.start):

  • BuildSlaveSupport/ews-build/steps_unittest.py: Added unit-test.
8:31 AM Changeset in webkit [258636] by aakash_jain@apple.com
  • 6 edits in trunk/Websites/bugs.webkit.org

Remove status-bubble iframe from old EWS
https://bugs.webkit.org/show_bug.cgi?id=209215

Reviewed by Jonathan Bedard.

  • code-review.js:
  • js/status-bubble.js:

(handleStatusBubbleLoadNewEWS): Deleted.

  • template/en/default/attachment/edit.html.tmpl: Removed old EWS iframe.
  • template/en/default/attachment/list.html.tmpl: Ditto.
  • template/en/default/attachment/reviewform.html.tmpl: Ditto.
8:30 AM Changeset in webkit [258635] by jh718.park@samsung.com
  • 2 edits in trunk/Source/WebCore

Unreviewed. Remove the build warnings below since r256756
warning: unused parameter ‘foo’ [-Wunused-parameter]

no new tests, no new behaviours.

  • testing/Internals.cpp:

(WebCore::Internals::readPreferenceInteger):
(WebCore::Internals::encodedPreferenceValue):
(WebCore::Internals::getUTIFromMIMEType):
(WebCore::Internals::getUTIFromTag):

8:26 AM Changeset in webkit [258634] by commit-queue@webkit.org
  • 5 edits in trunk/LayoutTests

animations/animation-direction-reverse.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=206671
<rdar://problem/58838216>

Patch by Antoine Quint <Antoine Quint> on 2020-03-18
Reviewed by Antti Koivisto.

To make this test robust we animate a non-accelerated property.

  • animations/animation-direction-reverse-expected.txt:
  • animations/animation-direction-reverse.html:
  • platform/ios/TestExpectations:
  • platform/mac/TestExpectations:
8:17 AM Changeset in webkit [258633] by jh718.park@samsung.com
  • 2 edits in trunk/Source/WebCore

Unreviewed. Remove the build warning below since r256196
warning: variable ‘highlightEnd’ set but not used [-Wunused-but-set-variable]

no new tests, no new behaviours.

  • rendering/HighlightData.cpp:

(WebCore::HighlightData::highlightStateForRenderer):

8:11 AM Changeset in webkit [258632] by eric.carlson@apple.com
  • 4 edits in trunk/LayoutTests

Update some fast/mediastream to make failures easier to diagnose.
https://bugs.webkit.org/show_bug.cgi?id=209205
<rdar://problem/60561372>

Log more state when a test fails.

Reviewed by Alex Christensen.

  • fast/mediastream/MediaStream-video-element-displays-buffer.html:
  • fast/mediastream/MediaStream-video-element-video-tracks-disabled-then-enabled.html:
  • fast/mediastream/resize-trim.html:
7:49 AM Changeset in webkit [258631] by youenn@apple.com
  • 7 edits
    5 adds in trunk

Make sure a preflight fails if response headers are invalid
https://bugs.webkit.org/show_bug.cgi?id=208924

Reviewed by Alex Christensen.

LayoutTests/imported/w3c:

  • web-platform-tests/fetch/api/cors/cors-preflight-response-validation.any-expected.txt: Added.
  • web-platform-tests/fetch/api/cors/cors-preflight-response-validation.any.html: Added.
  • web-platform-tests/fetch/api/cors/cors-preflight-response-validation.any.js: Added.

(corsPreflightResponseValidation):

  • web-platform-tests/fetch/api/cors/cors-preflight-response-validation.any.worker-expected.txt: Added.
  • web-platform-tests/fetch/api/cors/cors-preflight-response-validation.any.worker.html: Added.

Source/WebCore:

Implement https://fetch.spec.whatwg.org/#cors-preflight-fetch-0 step 7.3.
In case header parsing is wrong, fail the preflight with a meaningful message.
Update parsing of headers to return an Optional so that parsing error is handled as a nullopt.
Minor refactoring to return Expected/Optional for error handlng instead of passing an out parameter.
Also, adding preflight cache entry if it is valid, no matter whether preflight succeeds or not.

Tests: imported/w3c/web-platform-tests/fetch/api/cors/cors-preflight-response-validation.any.html

imported/w3c/web-platform-tests/fetch/api/cors/cors-preflight-response-validation.any.worker.html

  • loader/CrossOriginAccessControl.cpp:

(WebCore::validatePreflightResponse):

  • loader/CrossOriginPreflightResultCache.cpp:

(WebCore::CrossOriginPreflightResultCacheItem::create):
(WebCore::CrossOriginPreflightResultCacheItem::validateMethodAndHeaders const):

  • loader/CrossOriginPreflightResultCache.h:

(WebCore::CrossOriginPreflightResultCacheItem::CrossOriginPreflightResultCacheItem):

  • platform/network/HTTPParsers.h:

(WebCore::parseAccessControlAllowList):

  • platform/network/ResourceResponseBase.cpp:

(WebCore::ResourceResponseBase::filter):
(WebCore::ResourceResponseBase::sanitizeHTTPHeaderFieldsAccordingToTainting):

7:28 AM Changeset in webkit [258630] by jh718.park@samsung.com
  • 2 edits in trunk/Source/WebCore

Unreviewed. Remove the build warning below since r258458
warning: unused variable ‘frame’ [-Wunused-variable]

No new tests, no new behaviors.

  • loader/ResourceLoader.cpp:

(WebCore::ResourceLoader::didReceiveResponse):

7:24 AM Changeset in webkit [258629] by youenn@apple.com
  • 3 edits in trunk/Source/WebKit

REGRESSION (r257472): Can't start old Safari with new WebKit (dyld: Symbol not found: _WKContextConfigurationSetShouldCaptureAudioInUIProcess)
https://bugs.webkit.org/show_bug.cgi?id=209155

Reviewed by Eric Carlson.

Add a no-op WKContextConfigurationSetShouldCaptureAudioInUIProcess to allow latest WebKit being run on older Safari.

  • UIProcess/API/C/WKContextConfigurationRef.cpp:

(WKContextConfigurationSetShouldCaptureAudioInUIProcess):

  • UIProcess/API/C/WKContextConfigurationRef.h:
6:59 AM Changeset in webkit [258628] by youenn@apple.com
  • 32 edits in trunk/Source

Source/WebCore:
FrameLoader should own its FrameLoaderClient
https://bugs.webkit.org/show_bug.cgi?id=208918

Reviewed by Geoff Garen.

Update Frame/FrameLoader constructors to get a UniqueRef<FrameLoaderClient>.
This makes the lifetime management much clearer and allows some WebKit1/WebKit2 clean-up.

Covered by existing tests.

  • loader/EmptyClients.cpp:

(WebCore::pageConfigurationWithEmptyClients):

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

(WebCore::FrameLoader::FrameLoader):
(WebCore::FrameLoader::~FrameLoader):
(WebCore::FrameLoader::init):
(WebCore::FrameLoader::initForSynthesizedDocument):
(WebCore::FrameLoader::didExplicitOpen):
(WebCore::FrameLoader::receivedFirstData):
(WebCore::FrameLoader::finishedParsing):
(WebCore::FrameLoader::loadArchive):
(WebCore::FrameLoader::setOpener):
(WebCore::FrameLoader::provisionalLoadStarted):
(WebCore::FrameLoader::loadInSameDocument):
(WebCore::FrameLoader::prepareForLoadStart):
(WebCore::FrameLoader::setupForReplace):
(WebCore::FrameLoader::load):
(WebCore::FrameLoader::loadWithNavigationAction):
(WebCore::FrameLoader::loadWithDocumentLoader):
(WebCore::FrameLoader::willLoadMediaElementURL):
(WebCore::FrameLoader::reloadWithOverrideEncoding):
(WebCore::FrameLoader::reload):
(WebCore::FrameLoader::setDocumentLoader):
(WebCore::FrameLoader::commitProvisionalLoad):
(WebCore::FrameLoader::transitionToCommitted):
(WebCore::FrameLoader::clientRedirectCancelledOrFinished):
(WebCore::FrameLoader::clientRedirected):
(WebCore::FrameLoader::closeOldDataSources):
(WebCore::FrameLoader::willChangeTitle):
(WebCore::FrameLoader::dispatchDidFailProvisionalLoad):
(WebCore::FrameLoader::checkLoadCompleteForThisFrame):
(WebCore::FrameLoader::didReachLayoutMilestone):
(WebCore::FrameLoader::didReachVisuallyNonEmptyState):
(WebCore::FrameLoader::frameLoadCompleted):
(WebCore::FrameLoader::checkLoadComplete):
(WebCore::FrameLoader::userAgent const):
(WebCore::FrameLoader::dispatchOnloadEvents):
(WebCore::FrameLoader::detachViewsAndDocumentLoader):
(WebCore::FrameLoader::receivedMainResourceError):
(WebCore::FrameLoader::continueLoadAfterNavigationPolicy):
(WebCore::FrameLoader::continueLoadAfterNewWindowPolicy):
(WebCore::FrameLoader::loadedResourceFromMemoryCache):
(WebCore::FrameLoader::loadDifferentDocumentItem):
(WebCore::FrameLoader::cancelledError const):
(WebCore::FrameLoader::blockedByContentBlockerError const):
(WebCore::FrameLoader::blockedError const):
(WebCore::FrameLoader::blockedByContentFilterError const):
(WebCore::FrameLoader::connectionProperties):
(WebCore::FrameLoader::dispatchDidClearWindowObjectInWorld):
(WebCore::FrameLoader::dispatchGlobalObjectAvailableInAllWorlds):
(WebCore::FrameLoader::didChangeTitle):
(WebCore::FrameLoader::dispatchDidCommitLoad):
(WebCore::FrameLoader::tellClientAboutPastMemoryCacheLoads):
(WebCore::FrameLoader::completePageTransitionIfNeeded):

  • loader/FrameLoader.h:
  • loader/FrameLoaderClient.h:
  • page/Frame.cpp:

(WebCore::Frame::Frame):
(WebCore::Frame::create):

  • page/Frame.h:
  • page/Page.cpp:

(WebCore::Page::Page):

  • page/PageConfiguration.cpp:

(WebCore::PageConfiguration::PageConfiguration):

  • page/PageConfiguration.h:
  • workers/service/context/SWContextManager.cpp:
  • workers/service/context/SWContextManager.h:

Source/WebKit:
FrameLoader should own its FrameLoaderClient
https://bugs.webkit.org/show_bug.cgi?id=208918

Reviewed by Geoff Garen.

Pass a UniqueRef to the PageConfiguration.
Update WebFrameLoaderClient according updated FrameLoaderClient interface.

WebFrame no longer needs to ref/unref itself to keep the loader client alive.
Update WebFrame construction to not need a static_cast at initialization of the main frame.

The ownership is now that a WebCore::FrameLoader owns a FrameLoaderClient who owns a WebFrame.

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::tryLoadingUsingURLSchemeHandler):
(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):
(WebKit::WebLoaderStrategy::tryLoadingSynchronouslyUsingURLSchemeHandler):
(WebKit::WebLoaderStrategy::loadResourceSynchronously):
(WebKit::WebLoaderStrategy::startPingLoad):
(WebKit::WebLoaderStrategy::preconnectTo):

  • WebProcess/Storage/WebSWContextManagerConnection.cpp:

(WebKit::WebSWContextManagerConnection::installServiceWorker):

  • WebProcess/Storage/WebSWContextManagerConnection.h:
  • WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:

(WebKit::WebFrameLoaderClient::WebFrameLoaderClient):
(WebKit::WebFrameLoaderClient::~WebFrameLoaderClient):
(WebKit::WebFrameLoaderClient::webPageProxyID const):
(WebKit::WebFrameLoaderClient::pageID const):
(WebKit::WebFrameLoaderClient::frameID const):
(WebKit::WebFrameLoaderClient::detachedFromParent2):
(WebKit::WebFrameLoaderClient::assignIdentifierToInitialRequest):
(WebKit::WebFrameLoaderClient::dispatchWillSendRequest):
(WebKit::WebFrameLoaderClient::shouldUseCredentialStorage):
(WebKit::WebFrameLoaderClient::dispatchDidReceiveResponse):
(WebKit::WebFrameLoaderClient::dispatchDidReceiveContentLength):
(WebKit::WebFrameLoaderClient::dispatchDidFinishLoading):
(WebKit::WebFrameLoaderClient::dispatchDidFailLoading):
(WebKit::WebFrameLoaderClient::dispatchDidDispatchOnloadEvents):
(WebKit::WebFrameLoaderClient::dispatchDidReceiveServerRedirectForProvisionalLoad):
(WebKit::WebFrameLoaderClient::dispatchDidCancelClientRedirect):
(WebKit::WebFrameLoaderClient::dispatchWillPerformClientRedirect):
(WebKit::WebFrameLoaderClient::dispatchDidChangeLocationWithinPage):
(WebKit::WebFrameLoaderClient::dispatchDidPushStateWithinPage):
(WebKit::WebFrameLoaderClient::dispatchDidReplaceStateWithinPage):
(WebKit::WebFrameLoaderClient::dispatchDidPopStateWithinPage):
(WebKit::WebFrameLoaderClient::dispatchDidStartProvisionalLoad):
(WebKit::WebFrameLoaderClient::dispatchDidReceiveTitle):
(WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
(WebKit::WebFrameLoaderClient::dispatchDidFailProvisionalLoad):
(WebKit::WebFrameLoaderClient::dispatchDidFailLoad):
(WebKit::WebFrameLoaderClient::dispatchDidFinishDocumentLoad):
(WebKit::WebFrameLoaderClient::dispatchDidFinishLoad):
(WebKit::WebFrameLoaderClient::dispatchDidReachLayoutMilestone):
(WebKit::WebFrameLoaderClient::dispatchDidLayout):
(WebKit::WebFrameLoaderClient::dispatchShow):
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse):
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
(WebKit::WebFrameLoaderClient::applyToDocumentLoader):
(WebKit::WebFrameLoaderClient::allowsContentJavaScriptFromMostRecentNavigation const):
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
(WebKit::WebFrameLoaderClient::dispatchUnableToImplementPolicy):
(WebKit::WebFrameLoaderClient::dispatchWillSendSubmitEvent):
(WebKit::WebFrameLoaderClient::dispatchWillSubmitForm):
(WebKit::WebFrameLoaderClient::willReplaceMultipartContent):
(WebKit::WebFrameLoaderClient::didReplaceMultipartContent):
(WebKit::WebFrameLoaderClient::didDisplayInsecureContent):
(WebKit::WebFrameLoaderClient::didRunInsecureContent):
(WebKit::WebFrameLoaderClient::didDetectXSS):
(WebKit::WebFrameLoaderClient::cancelledError const):
(WebKit::WebFrameLoaderClient::blockedError const):
(WebKit::WebFrameLoaderClient::blockedByContentBlockerError const):
(WebKit::WebFrameLoaderClient::cannotShowURLError const):
(WebKit::WebFrameLoaderClient::interruptedForPolicyChangeError const):
(WebKit::WebFrameLoaderClient::blockedByContentFilterError const):
(WebKit::WebFrameLoaderClient::cannotShowMIMETypeError const):
(WebKit::WebFrameLoaderClient::fileDoesNotExistError const):
(WebKit::WebFrameLoaderClient::pluginWillHandleLoadError const):
(WebKit::WebFrameLoaderClient::shouldFallBack const):
(WebKit::WebFrameLoaderClient::restoreViewState):
(WebKit::WebFrameLoaderClient::didFinishLoad):
(WebKit::WebFrameLoaderClient::userAgent const):
(WebKit::WebFrameLoaderClient::createPlugin):
(WebKit::WebFrameLoaderClient::webGLPolicyForURL const):
(WebKit::WebFrameLoaderClient::resolveWebGLPolicyForURL const):
(WebKit::WebFrameLoaderClient::objectContentType):
(WebKit::WebFrameLoaderClient::overrideMediaType const):
(WebKit::WebFrameLoaderClient::dispatchDidClearWindowObjectInWorld):
(WebKit::WebFrameLoaderClient::dispatchGlobalObjectAvailable):
(WebKit::WebFrameLoaderClient::willInjectUserScript):
(WebKit::WebFrameLoaderClient::willCacheResponse const):
(WebKit::WebFrameLoaderClient::createNetworkingContext):

  • WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
  • WebProcess/WebPage/WebFrame.cpp:

(WebKit::WebFrame::initWithCoreMainFrame):
(WebKit::WebFrame::createSubframe):
(WebKit::WebFrame::WebFrame):
(WebKit::WebFrame::frameLoaderClient const):
(WebKit::WebFrame::fromCoreFrame):
(WebKit::WebFrame::didReceivePolicyDecision):

  • WebProcess/WebPage/WebFrame.h:

(WebKit::WebFrame::create):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::m_processDisplayName):

Source/WebKitLegacy/mac:
FrameLoader should own its FrameLoaderClient
https://bugs.webkit.org/show_bug.cgi?id=208918

Reviewed by Geoff Garen.

Update according new Frame/FrameLoader constructors and FrameLoaderClient interface.

  • WebCoreSupport/WebFrameLoaderClient.h:

(WebFrameLoaderClient::setWebFrame):

  • WebCoreSupport/WebFrameLoaderClient.mm:

(WebFrameLoaderClient::~WebFrameLoaderClient):
(WebFrameLoaderClient::cancelledError const):
(WebFrameLoaderClient::blockedError const):
(WebFrameLoaderClient::blockedByContentBlockerError const):
(WebFrameLoaderClient::cannotShowURLError const):
(WebFrameLoaderClient::interruptedForPolicyChangeError const):
(WebFrameLoaderClient::blockedByContentFilterError const):
(WebFrameLoaderClient::cannotShowMIMETypeError const):
(WebFrameLoaderClient::fileDoesNotExistError const):
(WebFrameLoaderClient::pluginWillHandleLoadError const):
(WebFrameLoaderClient::shouldFallBack const):
(WebFrameLoaderClient::userAgent const):

  • WebView/WebFrame.mm:

(+[WebFrame _createFrameWithPage:frameName:frameView:ownerElement:]):
(+[WebFrame _createMainFrameWithPage:frameName:frameView:]):
(+[WebFrame _createMainFrameWithSimpleHTMLDocumentWithPage:frameView:style:]):

  • WebView/WebView.mm:

(-[WebView _commonInitializationWithFrameName:groupName:]):
(-[WebView initSimpleHTMLDocumentWithStyle:frame:preferences:groupName:]):

Source/WebKitLegacy/win:
Make sure a preflight fails if response headers are invalid
https://bugs.webkit.org/show_bug.cgi?id=208924

Reviewed by Geoff Garen.

  • WebCoreSupport/WebFrameLoaderClient.cpp:

(WebFrameLoaderClient::cancelledError const):
(WebFrameLoaderClient::blockedError const):
(WebFrameLoaderClient::blockedByContentBlockerError const):
(WebFrameLoaderClient::cannotShowURLError const):
(WebFrameLoaderClient::interruptedForPolicyChangeError const):
(WebFrameLoaderClient::cannotShowMIMETypeError const):
(WebFrameLoaderClient::fileDoesNotExistError const):
(WebFrameLoaderClient::pluginWillHandleLoadError const):
(WebFrameLoaderClient::shouldFallBack const):
(WebFrameLoaderClient::userAgent const):
(WebFrameLoaderClient::frameLoaderDestroyed): Deleted.
(WebFrameLoaderClient::cancelledError): Deleted.
(WebFrameLoaderClient::blockedError): Deleted.
(WebFrameLoaderClient::blockedByContentBlockerError): Deleted.
(WebFrameLoaderClient::cannotShowURLError): Deleted.
(WebFrameLoaderClient::interruptedForPolicyChangeError): Deleted.
(WebFrameLoaderClient::cannotShowMIMETypeError): Deleted.
(WebFrameLoaderClient::fileDoesNotExistError): Deleted.
(WebFrameLoaderClient::pluginWillHandleLoadError): Deleted.
(WebFrameLoaderClient::shouldFallBack): Deleted.
(WebFrameLoaderClient::userAgent): Deleted.

  • WebCoreSupport/WebFrameLoaderClient.h:
  • WebFrame.cpp:

(WebFrame::createSubframeWithOwnerElement):

6:34 AM Changeset in webkit [258627] by commit-queue@webkit.org
  • 5 edits in trunk/LayoutTests

[ macOS iOS ] animations/play-state-paused.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=206682
<rdar://problem/58840950>

Patch by Antoine Quint <Antoine Quint> on 2020-03-18
Reviewed by Antti Koivisto.

To make this test robust we animate a non-accelerated property and we use the Web Animations API to set the time
at which we want to pause the animation (1s).

  • animations/play-state-paused-expected.txt:
  • animations/play-state-paused.html:
  • platform/ios-wk2/TestExpectations:
  • platform/mac/TestExpectations:
3:30 AM BuildingGtk edited by Philippe Normand
(diff)
3:29 AM BuildingGtk edited by Philippe Normand
(diff)
2:54 AM Changeset in webkit [258626] by Philippe Normand
  • 32 edits
    1 move
    17 deletes in trunk

[GTK][WPE] Migrate to Flatpak-based dev SDK
https://bugs.webkit.org/show_bug.cgi?id=205658

Reviewed by Carlos Alberto Lopez Perez.

Source/WebCore:

  • platform/text/hyphen/HyphenationLibHyphen.cpp:

(WebCore::scanTestDictionariesDirectoryIfNecessary): Check for flatpak-installed dictionaries.

Tools:

JHBuild will now be used only if the WEBKIT_JHBUILD environment
variable is set to 1, which is the case for the time being on the
GTK and WPE EWS/build bots.

By default the build dependencies are now locally installed from a
Flatpak repository hosted at https://software.igalia.com. The
repository can be regenerated with the scripts from the
webkit-flatpak-sdk Github project
(https://github.com/Igalia/webkit-flatpak-sdk). This is done
transparently with the update-webkit{gtk,wpe}-libs scripts. As
there is no need to rebuild the dependencies from scratch, the
developer user-experience should now be much more friendly and
overall build times reduced.

As an additional commodity, the new environment supports the
GStreamer gst-build-based workflow. Just set the GST_BUILD_PATH
environment variable to your gst-build path. This feature was
contributed by Thibault Saunier.

The JHBuild infrastructure will be removed once all the bots have
been switched over to Flatpak.

  • BuildSlaveSupport/ews-build/steps.py:

(InstallGtkDependencies):
(InstallWpeDependencies):
(CompileWebKit.start):

  • BuildSlaveSupport/gtk/buildbot/run:
  • Scripts/build-webkit:
  • Scripts/run-bindings-tests:
  • Scripts/run-builtins-generator-tests:
  • Scripts/run-gtk-tests:
  • Scripts/run-javascriptcore-tests:
  • Scripts/run-minibrowser:
  • Scripts/run-qt-wpe-minibrowser:
  • Scripts/run-webdriver-tests:
  • Scripts/run-wpe-tests:
  • Scripts/test-webkitperl:
  • Scripts/test-webkitpy:
  • Scripts/test262-runner:
  • Scripts/update-webkit-flatpak: Renamed from Tools/Scripts/update-webkitgtk-flatpak.
  • Scripts/update-webkitgtk-libs:
  • Scripts/update-webkitwpe-flatpak: Removed.
  • Scripts/update-webkitwpe-libs:
  • Scripts/webkitdirs.pm:

(getUserFlatpakPath):
(inFlatpakSandbox):
(runInFlatpakIfAvailable):
(wrapperPrefixIfNeeded):
(shouldUseJhbuild):
(shouldUseFlatpak):
(shouldRemoveCMakeCache):

  • Scripts/webkitpy/common/system/executive.py:

(Executive.kill_all):

  • Scripts/webkitpy/port/base.py:

(Port._path_to_apache):
(Port._should_run_as_pixel_test):
(Port._in_flatpak_sandbox):

  • Scripts/webkitpy/port/gtk.py:

(GtkPort.setup_environ_for_server):
(GtkPort._get_crash_log):

  • Scripts/webkitpy/port/linux_get_crash_log.py:

(GDBCrashLogGenerator):
(GDBCrashLogGenerator.init):
(GDBCrashLogGenerator.generate_crash_log):

  • Scripts/webkitpy/port/linux_get_crash_log_unittest.py:

(GDBCrashLogGeneratorTest.test_generate_crash_log):

  • Scripts/webkitpy/port/wpe.py:

(WPEPort.setup_environ_for_server):
(WPEPort._get_crash_log):

  • Scripts/webkitpy/port/xvfbdriver.py:

(XvfbDriver._setup_environ_for_test):

  • WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp:

(WTR::getFontsPath):

  • WebKitTestRunner/InjectedBundle/wpe/ActivateFontsWPE.cpp:

(WTR::getFontsPath):

  • flatpak/files/default.xkm: Removed.
  • flatpak/files/httpd-autogen.sh: Removed.
  • flatpak/flatpakutils.py:

(check_flatpak):
(FlatpakRepos.update):
(FlatpakPackage.repr):
(FlatpakPackage.str):
(WebkitFlatpak.load_from_args):
(WebkitFlatpak.init):
(WebkitFlatpak.clean_args):
(WebkitFlatpak.setup_builddir):
(WebkitFlatpak):
(WebkitFlatpak.setup_gstbuild):
(WebkitFlatpak.run_in_sandbox):
(WebkitFlatpak.run):
(WebkitFlatpak.has_environment):
(WebkitFlatpak.save_config):
(WebkitFlatpak.setup_dev_env):
(WebkitFlatpak.install_all):
(WebkitFlatpak.run_gdb):

  • flatpak/org.webkit.CommonModules.yaml: Removed.
  • flatpak/org.webkit.GTK.yaml: Removed.
  • flatpak/org.webkit.WPE.yaml: Removed.
  • flatpak/org.webkit.WPEModules.yaml: Removed.
  • flatpak/org.webkit.WPEQT.yaml: Removed.
  • flatpak/org.webkit.WebKit.yaml: Removed.
  • flatpak/patches/httpd-0001-configure-use-pkg-config-for-PCRE-detection.patch: Removed.
  • flatpak/patches/libgcrypt-0001-Use-pkg-config-to-detect-gpg-error.patch: Removed.
  • flatpak/patches/xvfb-0001-HACK-Avoid-compiling-a-kbm-file.patch: Removed.

LayoutTests:

  • http/conf/flatpak-httpd.conf: Adjust paths.

Mar 17, 2020:

10:47 PM Changeset in webkit [258625] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

Crash in CSSPrimitiveValue::cleanup
https://bugs.webkit.org/show_bug.cgi?id=208316

Patch by Pinki Gyanchandani <pgyanchandani@apple.com> on 2020-03-17
Reviewed by Ryosuke Niwa.

Source/WebCore:

Added a NULL check before calling deref() for CSSUnitType :: CSS_CALC.

During initialization of CSSCalcValue, createCSS returns nullptr when processing min() operator
and there is a category mismatch between length and percent for min() operator
as seen in this newly added test case.

Test: editing/execCommand/primitive-value-cleanup-minimal.html

  • css/CSSPrimitiveValue.cpp:

(WebCore::CSSPrimitiveValue::cleanup):

LayoutTests:

Added modified version of testcase attached in 208316. Minimized version provided by Ryosuke Niwa.

  • editing/execCommand/primitive-value-cleanup-minimal-expected.txt: Added.
  • editing/execCommand/primitive-value-cleanup-minimal.html: Added.
9:45 PM Changeset in webkit [258624] by clopez@igalia.com
  • 2 edits in trunk/Source/ThirdParty/libwebrtc

[CMake] libopus 1.1 its enough for building WebKitGTK with ENABLE_WEB_RTC
https://bugs.webkit.org/show_bug.cgi?id=209209

Reviewed by Konstantin Tokarev.

Ubuntu 18.04 ships libopus 1.1.2 which its enough for building with -DENABLE_WEB_RTC=ON

  • CMakeLists.txt:
9:30 PM Changeset in webkit [258623] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: the width of WI.TabBarItem can change if the detached window is resized
https://bugs.webkit.org/show_bug.cgi?id=209200

Reviewed by Timothy Hatcher.

  • UserInterface/Views/TabBar.js:

(WI.TabBar.prototype.layout):
(WI.TabBar.prototype.layout.measureWidth): Renamed from measureItemWidth.
When undocked, WI.TabBarItem grow to fill any available space. As a result, if a
WI.TabBarItem is added or removed, the width of all WI.TabBarItem will change.
Wait to measure widths until all WI.TabBarItem are un-hidden for the reason above.

9:14 PM Changeset in webkit [258622] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Network: we should prefer showing "Preserve Log" over "Group Media Requests"
https://bugs.webkit.org/show_bug.cgi?id=209199

Reviewed by Timothy Hatcher.

  • UserInterface/Views/NetworkTableContentView.js:

(WI.NetworkTableContentView):
Change the WI.NavigationItem.VisibilityPriority of the various WI.NavigationItem:

High:

  • URL filter
  • resource type filter
  • live/HAR view switcher
  • disable resource caching toggle

Normal:

  • Preserve Log checkbox
  • clear button

Low:

  • Group Media Requests checkbox
  • HAR import/export buttons

This way, items that have alternate ways of being triggered (e.g. keyboard shortcuts) are
hidden first, and vica versa.

8:59 PM Changeset in webkit [258621] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Sources: hovering the title of an object preview popup for a DOM node doesn't highlight it
https://bugs.webkit.org/show_bug.cgi?id=209159

Reviewed by Timothy Hatcher.

  • UserInterface/Views/SourceCodeTextEditor.js:

(WI.SourceCodeTextEditor.prototype._showPopoverForObject):

8:32 PM Changeset in webkit [258620] by ddkilzer@apple.com
  • 2 edits in trunk/Source/WebKit

SharedMemory::Handle::m_size should be more consistent
<https://webkit.org/b/209007>
<rdar://problem/60340890>

Reviewed by Darin Adler.

  • Platform/cocoa/SharedMemoryCocoa.cpp:

(WebKit::SharedMemory::Handle::decode):

  • Return early if an invalid size is decoded.

(WebKit::SharedMemory::map):

  • Drive-by fix to change '0' to 'nullptr'.
  • Since all known methods of creating a SharedMemory::Handle() set SharedMemory::Handle::m_size to a value of round_page(), this means we can also change round_page(handle.m_size) to handle.m_size in the call to mach_vm_map() since we know they're equal.
8:18 PM Changeset in webkit [258619] by Lauro Moura
  • 2 edits in trunk/LayoutTests

[WPE] Gardening

Unreviewed test gardening.

  • platform/wpe/TestExpectations:
8:15 PM Changeset in webkit [258618] by Lauro Moura
  • 8 edits in trunk/LayoutTests

[WPE] Rebaseline after r258492.

Unreviewed test gardening.

  • platform/wpe/imported/w3c/web-platform-tests/svg/import/text-path-01-b-manual-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/svg/import/text-path-02-b-manual-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/svg/painting/marker-008-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/svg/painting/reftests/paint-order-001-expected.txt:
  • platform/wpe/imported/w3c/web-platform-tests/svg/text/reftests/textpath-shape-001-expected.txt:
  • platform/wpe/svg/W3C-SVG-1.1/text-path-01-b-expected.txt:
  • platform/wpe/svg/text/text-path-01-b-expected.txt:
8:12 PM Changeset in webkit [258617] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

Unreviewed, reverting r258496.
https://bugs.webkit.org/show_bug.cgi?id=209217

Introduced sandbox regression (Requested by perarne on
#webkit).

Reverted changeset:

"[iOS] Add telemetry for message filtering"
https://bugs.webkit.org/show_bug.cgi?id=208925
https://trac.webkit.org/changeset/258496

5:45 PM Changeset in webkit [258616] by Kate Cheney
  • 8 edits
    1 add
    2 deletes in trunk

Expand In-App-Browser-Privacy testing
https://bugs.webkit.org/show_bug.cgi?id=209142
<rdar://problem/60496618>

Reviewed by Darin Adler.

Source/WebKit:

Adds a testing API to check whether a navigation was classified as
app-bound.

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _isNavigatingToAppBoundDomain:]):

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::isNavigatingToAppBoundDomainTesting):

  • UIProcess/WebPageProxy.h:

Tools:

Expanded test coverage by adding new tests and creating a custom url
scheme handler to get around the fact that local file loads are
always classified as app-bound.

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

(-[InAppBrowserSchemeHandler webView:startURLSchemeTask:]):
If the path indicates testing user scripts on load, notify the script message
handler that the navigation has finished. If the path indicates
testing user-agent scripts, set the window.wkUserScriptInjected
variable to true. A user agent script will attempt to read this
variable and should fail.

(-[InAppBrowserSchemeHandler webView:stopURLSchemeTask:]):
(initializeInAppBrowserPrivacyTestSettings):
Basic test setup. Initialize the main run loop and make sure we are
starting with a clean state.

(TEST):
Add tests for all protocols checked in shouldBeTreatedAsAppBound,
except for blob files which must be generated within the web content.

  • TestWebKitAPI/Tests/WebKitCocoa/in-app-browser-privacy-local-file.html: Added.

Basic html document to test local file loads are classified as
app-bound.

  • TestWebKitAPI/Tests/WebKitCocoa/in-app-browser-privacy-test-user-agent-script.html: Removed.
  • TestWebKitAPI/Tests/WebKitCocoa/in-app-browser-privacy-test-user-script.html: Removed.

These files are no longer needed as their content is directly copied
into the URL scheme handler.

5:31 PM Changeset in webkit [258615] by Alan Coon
  • 1 copy in tags/Safari-610.1.7.5

Tag Safari-610.1.7.5.

5:29 PM Changeset in webkit [258614] by Fujii Hironori
  • 2 edits in trunk/Source/WebCore

SerializedScriptValue::decode should check bufferIsLargeEnoughToContain before allocating a buffer
https://bugs.webkit.org/show_bug.cgi?id=209132

Reviewed by Darin Adler.

  • bindings/js/SerializedScriptValue.h:

(WebCore::SerializedScriptValue::decode): Added bufferIsLargeEnoughToContain check.
Added a null check for Gigacage::tryMalloc.

5:12 PM Changeset in webkit [258613] by Chris Dumez
  • 8 edits
    3 adds in trunk

REGRESSION: [ macOS wk1 ] ASSERTION FAILED: _notifications.contains(notificationID) imported/w3c/web-platform-tests/notifications/constructor-basic.html is flaky crashing
https://bugs.webkit.org/show_bug.cgi?id=207307
<rdar://problem/59206964>

Reviewed by Alex Christensen.

Source/WebKitLegacy/mac:

  • WebView/WebNotification.h:
  • WebView/WebNotification.mm:

(-[WebNotification finalize]):

Tools:

When [MockWebNotificationProvider reset] was called at the end of the test, it would remove all
notifications from the map but not tell WebCore that the notification were discarded. As a result,
WebCore would later tell the MockWebNotificationProvider to cancel the notification but this
notification would no longer be in the map, causing us to hit an assertion in debug.

To address the issue, we now call Notification::finalize() in [MockWebNotificationProvider reset]
to let WebCore know the notification was discarded. This is similar to what is already done for
WebKit2 in WebNotificationManager::clearNotifications().

  • DumpRenderTree/mac/MockWebNotificationProvider.mm:

(-[MockWebNotificationProvider reset]):

LayoutTests:

Add test coverage.

  • http/wpt/notifications/constructor-basic-bfcache-expected.txt: Added.
  • http/wpt/notifications/constructor-basic-bfcache.html: Added.
  • platform/mac/TestExpectations:
5:06 PM Changeset in webkit [258612] by don.olmstead@sony.com
  • 2 edits in trunk/Tools

[WinCairo][FTW] Update path to requirements download
https://bugs.webkit.org/show_bug.cgi?id=209202

Reviewed by Ross Kirsling.

Repository was renamed from WinCairoRequirements to WebKitRequirements in the
WebKitForWindows org on GitHub. Additionally the .zip file was renamed to
WebKitRequirementsWin64.zip.

  • Scripts/update-webkit-wincairo-libs.py:
5:01 PM Changeset in webkit [258611] by aakash_jain@apple.com
  • 4 edits in trunk/Tools

[ews] Resubmit patches to commit-queue which were cq- by commit-queue and later cq+
https://bugs.webkit.org/show_bug.cgi?id=208920

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-app/ews/common/buildbot.py:

(Buildbot.update_builder_name_to_id_mapping): Method to generate builder name to id mapping.
(Buildbot.fetch_pending_and_inprogress_builds): Method to fetch pendign and in-progress builds from buildbot.
(Buildbot.get_patches_in_queue): Method to fetch list of patches which are pending or are in-progress on buildbot.

  • BuildSlaveSupport/ews-app/ews/common/bugzilla.py:

(Bugzilla.get_cq_plus_timestamp): Get UTC timestamp when cq+ flag was set.

  • BuildSlaveSupport/ews-app/ews/fetcher.py:

(FetchLoop.run): Update builder name to id mapping. We just need to update it one-time, since we need the id only
for commit-queue which isn't expected to change.
(BugzillaPatchFetcher.fetch_commit_queue_patches):
(BugzillaPatchFetcher.send_patches_to_buildbot): Allow sending the patch again to commit-queue.
(BugzillaPatchFetcher.patches_to_send_to_commit_queue): Find patches which needs to be sent to commit-queue. Filter
out patches which are already waiting or in-progress on commit-queue, or whose recent build was completed after
setting cq+ flag on bugzilla.

4:32 PM Changeset in webkit [258610] by achristensen@apple.com
  • 2 edits in trunk/Source/WebKit

Fix API tests after r258574
https://bugs.webkit.org/show_bug.cgi?id=209192

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::printFrame):
I forgot to call the CompletionHandler from the IPC call.

4:02 PM Changeset in webkit [258609] by Chris Fleizach
  • 3 edits
    2 adds in trunk

AX: WebKit crashes with VO and keyboard support fails on encapsulated radio button components.
https://bugs.webkit.org/show_bug.cgi?id=208844
<rdar://problem/60252659>

Reviewed by Darin Adler.

Source/WebCore:

Test: accessibility/mac/crash-bounds-for-range.html

Don't access renderer if nil in getInlineBoxAndOffset.

  • dom/Position.cpp:

(WebCore::Position::getInlineBoxAndOffset const):

LayoutTests:

  • accessibility/mac/crash-bounds-for-range-expected.txt: Added.
  • accessibility/mac/crash-bounds-for-range.html: Added.
3:56 PM Changeset in webkit [258608] by Jacob Uphoff
  • 2 edits in trunk/LayoutTests

[ macOS wk1 ] imported/w3c/web-platform-tests/html/semantics/embedded-content/media-elements/loading-the-media-resource/resource-selection-pointer-insert-text.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=209201

Unreviewed test gardening.

  • platform/mac-wk1/TestExpectations:
3:46 PM Changeset in webkit [258607] by Alan Coon
  • 2 edits in branches/safari-610.1.7-branch/Source/WebKit

Cherry-pick r258515. rdar://problem/60551856

[Cocoa] Crash under -[WKPreferenceObserver init]
https://bugs.webkit.org/show_bug.cgi?id=209145

Reviewed by Darin Adler.

Handle the case when calling [NSUserDefaults initWithSuiteName:] did not succeed.

No new tests, since I have not been able to reproduce.

  • UIProcess/Cocoa/PreferenceObserver.mm: (-[WKPreferenceObserver init]):

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

3:45 PM Changeset in webkit [258606] by eric.carlson@apple.com
  • 2 edits in trunk/Source/WebCore

TextTrackBase should validate language before setting m_validBCP47Language
https://bugs.webkit.org/show_bug.cgi?id=209094
<rdar://problem/60439603>

Unreviewed, address post-commit review comments.

  • html/track/TrackBase.cpp:

(WebCore::TrackBase::setLanguage): Use makeString instead of StringBuilder.

3:44 PM Changeset in webkit [258605] by Alan Coon
  • 8 edits in branches/safari-610.1.7-branch

Cherry-pick r258518. rdar://problem/60517387

[macOS] Accessibility sandbox regressions
https://bugs.webkit.org/show_bug.cgi?id=209065
Source/WebCore/PAL:

Reviewed by Brent Fulgham.

Add Accessibility notification name.

  • pal/spi/cocoa/NSAccessibilitySPI.h:

Source/WebKit:

<rdar://problem/60202450>

Reviewed by Brent Fulgham.

When Accessibility is enabled, the WebContent process needs access to the preference service, since Accessibility
is relying on some advanced features of the service. Also, when CF prefs direct mode is enabled, the WebContent
sandbox needs to explicitly allow reading of the various plist files.

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm: (WebKit::WebProcessPool::registerNotificationObservers):
  • WebProcess/com.apple.WebProcess.sb.in:

Tools:

Reviewed by Brent Fulgham.

  • TestWebKitAPI/Tests/WebKit/EnableAccessibility.mm: (TEST):
  • TestWebKitAPI/Tests/WebKit/GrantAccessToPreferencesService.mm: (TEST):

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

3:44 PM Changeset in webkit [258604] by Alan Coon
  • 13 edits
    1 add in branches/safari-610.1.7-branch

Cherry-pick r258359. rdar://problem/60517387

[macOS] _AXSApplicationAccessibilityEnabled should not be called
https://bugs.webkit.org/show_bug.cgi?id=208953

Reviewed by Brent Fulgham.

Source/WebCore:

The function _AXSApplicationAccessibilityEnabled and the notification kAXSApplicationAccessibilityEnabledNotification
exist on macOS, but they do not have the same behavior as on iOS, and should not be used in the same way. Using this
function and notification on macOS was introduced in <https://bugs.webkit.org/show_bug.cgi?id=208690>, and this patch
partially reverts this behavior.

API test: WebKit.IsRemoteUIAppForAccessibility

  • testing/Internals.cpp: (WebCore::Internals::isRemoteUIAppForAccessibility):
  • testing/Internals.h:
  • testing/Internals.idl:
  • testing/Internals.mm: (WebCore::Internals::isRemoteUIAppForAccessibility):

Source/WebCore/PAL:

Declare method to check if the process is a remote UI app for accessibility.

  • pal/spi/cocoa/NSAccessibilitySPI.h:

Source/WebKit:

On macOS, stop using the function _AXSApplicationAccessibilityEnabled and listening to the notification
kAXSApplicationAccessibilityEnabledNotification, since they do not have the same behavior as on iOS.

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm: (WebKit::WebProcessPool::platformInitializeWebProcess): (WebKit::WebProcessPool::registerNotificationObservers): (WebKit::WebProcessPool::unregisterNotificationObservers):
  • UIProcess/Cocoa/WebProcessProxyCocoa.mm: (WebKit::WebProcessProxy::unblockAccessibilityServerIfNeeded):
  • WebProcess/cocoa/WebProcessCocoa.mm: (WebKit::WebProcess::platformInitializeProcess): (WebKit::WebProcess::unblockAccessibilityServer):

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:

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

3:29 PM Changeset in webkit [258603] by ysuzuki@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

[JSC] DeleteIC patchpoint in FTL should require tag and mask registers
https://bugs.webkit.org/show_bug.cgi?id=209197
<rdar://problem/60531308>

Reviewed by Tadeu Zagallo and Saam Barati.

DeleteIC patchpoint is emitting branchIfNotCell machine code. This requires a mask register
while we are not reserving them when creating a patchpoint.

In general, our IC code is assuming usual CCallHelpers environment which provides macro-assembler
scratch, tag, and mask registers. We should offer them even if IC is emitted from FTL. In this
patch, we offer tag and mask registers for Delete IC even if this IC is not currently using tag
register.

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compileDelBy):

3:04 PM Changeset in webkit [258602] by jiewen_tan@apple.com
  • 2 edits in trunk/Source/WebKit

WebKit::LocalAuthenticator::deleteDuplicateCredential() should check buffer size before memcmp
https://bugs.webkit.org/show_bug.cgi?id=209156
<rdar://problem/60444655>

Reviewed by Alex Christensen.

Covered by existing tests.

  • UIProcess/WebAuthentication/Cocoa/LocalAuthenticator.mm:

(WebKit::LocalAuthenticator::deleteDuplicateCredential const):

2:56 PM Changeset in webkit [258601] by Alan Coon
  • 2 edits in branches/safari-609-branch/Source/WebKit

Apply patch. rdar://problem/60363244

Crash in com.apple.WebKit.WebContent at WebKit::WebSWClientConnection::scheduleJobInServer <rdar://problem/60363244>

Patch by Youenn Fablet <youenn@apple.com> on 2020-03-13
Reviewed by David Kilzer.

  • WebProcess/Storage/WebSWClientConnection.cpp: (WebKit::WebSWClientConnection::scheduleJobInServer):
  • Revert branch commit r256687. This RELEASE_ASSERT() was removed on trunk as part of r256578 (which was merged to this branch in r256680, then added back in r256687).
2:36 PM Changeset in webkit [258600] by Kate Cheney
  • 4 edits in trunk/Source/WebKit

Add internal debugging when initializing an app-bound session
https://bugs.webkit.org/show_bug.cgi?id=209190
<rdar://problem/60371620>

Reviewed by Brent Fulgham.

  • NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:

(WebKit::NetworkDataTaskCocoa::NetworkDataTaskCocoa):

  • NetworkProcess/cocoa/NetworkSessionCocoa.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(WebKit::SessionWrapper::initialize):
(WebKit::NetworkSessionCocoa::NetworkSessionCocoa):
(WebKit::NetworkSessionCocoa::initializeEphemeralStatelessSession):
(WebKit::NetworkSessionCocoa::sessionWrapperForTask):
(WebKit::NetworkSessionCocoa::appBoundSession):
(WebKit::NetworkSessionCocoa::isolatedSession):

2:35 PM Changeset in webkit [258599] by wilander@apple.com
  • 3 edits in trunk/Source/WebKit

Add quirk for cookie blocking latch mode ymail.com redirecting to yahoo.com under yahoo.com
https://bugs.webkit.org/show_bug.cgi?id=209193
<rdar://problem/60089022>

Reviewed by Brent Fulgham.

No new tests. Site-specific quirk tested manually on the site in question.

  • NetworkProcess/cocoa/NetworkDataTaskCocoa.h:
  • NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:

(WebKit::NetworkDataTaskCocoa::unblockCookies):
(WebKit::NetworkDataTaskCocoa::needsFirstPartyCookieBlockingLatchModeQuirk const):
(WebKit::NetworkDataTaskCocoa::willPerformHTTPRedirection):

2:25 PM Changeset in webkit [258598] by Chris Dumez
  • 3 edits in trunk/Tools

[WKTR] testRunner API that takes in a completion handler should use async IPC
https://bugs.webkit.org/show_bug.cgi?id=209187

Reviewed by John Wilander.

testRunner API that takes in a completion handler should use async IPC. This hangs
the WebProcess for no reason and can cause deadlocks if the UIProcess then tries
to IPC the WebProcess as a result of this testRunner call.

  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::setStatisticsHasHadUserInteraction):
(WTR::TestRunner::statisticsUpdateCookieBlocking):
(WTR::TestRunner::statisticsClearInMemoryAndPersistentStore):
(WTR::TestRunner::statisticsClearInMemoryAndPersistentStoreModifiedSinceHours):
(WTR::TestRunner::statisticsClearThroughWebsiteDataRemoval):
(WTR::TestRunner::setStatisticsShouldDowngradeReferrer):
(WTR::TestRunner::setStatisticsFirstPartyWebsiteDataRemovalMode):
(WTR::TestRunner::statisticsResetToConsistentState):
(WTR::TestRunner::getAllStorageAccessEntries):
(WTR::TestRunner::removeAllSessionCredentials):
(WTR::TestRunner::getApplicationManifestThen):

  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):

2:07 PM Changeset in webkit [258597] by Alan Coon
  • 3 edits in branches/safari-609-branch/Source/WebKit

Apply patch. rdar://problem/60500511

2:07 PM Changeset in webkit [258596] by Alan Coon
  • 2 edits in branches/safari-609-branch/Source/WebKit

Apply patch. rdar://problem/60433244

2:07 PM Changeset in webkit [258595] by Alan Coon
  • 2 edits in branches/safari-609-branch/Source/WebKit

Apply patch. rdar://problem/60436975

2:06 PM Changeset in webkit [258594] by Alan Coon
  • 2 edits in branches/safari-609-branch/Source/WebKit

Apply patch. rdar://problem/60396281

2:06 PM Changeset in webkit [258593] by Alan Coon
  • 6 edits in branches/safari-609-branch/Source/WebKit

Apply patch. rdar://problem/60396294

2:06 PM Changeset in webkit [258592] by Alan Coon
  • 2 edits in branches/safari-609-branch/Source/WebKit

Apply patch. rdar://problem/60430195

2:06 PM Changeset in webkit [258591] by Alan Coon
  • 2 edits in branches/safari-609-branch/Source/JavaScriptCore

Apply patch. rdar://problem/60396286

Cherry-pick r258062. rdar://problem/60396286

2020-03-06 David Kilzer <ddkilzer@apple.com>

REGRESSION (r258038): Build failure on Windows 10 bots
<https://bugs.webkit.org/show_bug.cgi?id=208731>
<rdar://problem/59222568>

  • assembler/testmasm.cpp: (JSC::testCompareDouble): (JSC::testCompareDoubleSameArg): (JSC::testMoveConditionallyFloatingPoint): (JSC::testMoveConditionallyFloatingPointSameArg):
  • Add RELEASE_ASSERT_NOT_REACHED() statements to try to fix the bots.
2:06 PM Changeset in webkit [258590] by Alan Coon
  • 3 edits in branches/safari-609-branch/Source/JavaScriptCore

Apply patch. rdar://problem/60396286

Cherry-pick r258038. rdar://problem/60396286

2020-03-06 Mark Lam <mark.lam@apple.com>

Fix some issues in the ARM64 moveConditionallyAfterFloatingPointCompare() and moveDoubleConditionallyAfterFloatingPointCompare().
https://bugs.webkit.org/show_bug.cgi?id=208731
<rdar://problem/59222568>

Patch by Mark Lam <mark.lam@apple.com> on 2020-03-06
Reviewed by Saam Barati.

Both the ARM64 moveConditionallyAfterFloatingPointCompare() and
moveDoubleConditionallyAfterFloatingPointCompare() had the following issues:

  1. For the DoubleNotEqual condition, they fail to set the result register if one or both of the comparison operands is a NaN.
  1. For the DoubleEqualOrUnordered condition, they can clobber the else case input register if one of the comparison operands is a NaN.

This patch fixes both of these, and exhaustive testmasm test cases for affected
MacroAssembler instruction emitters using these functions.

  • assembler/MacroAssemblerARM64.h: (JSC::MacroAssemblerARM64::moveConditionallyAfterFloatingPointCompare): (JSC::MacroAssemblerARM64::moveDoubleConditionallyAfterFloatingPointCompare):
  • assembler/testmasm.cpp: (JSC::testCompareDouble): (JSC::testCompareDoubleSameArg): (JSC::testMoveConditionallyFloatingPoint): (JSC::testMoveConditionallyDouble2): (JSC::testMoveConditionallyDouble3): (JSC::testMoveConditionallyDouble3DestSameAsThenCase): (JSC::testMoveConditionallyDouble3DestSameAsElseCase): (JSC::testMoveConditionallyFloat2): (JSC::testMoveConditionallyFloat3): (JSC::testMoveConditionallyFloat3DestSameAsThenCase): (JSC::testMoveConditionallyFloat3DestSameAsElseCase): (JSC::testMoveDoubleConditionallyDouble): (JSC::testMoveDoubleConditionallyDoubleDestSameAsThenCase): (JSC::testMoveDoubleConditionallyDoubleDestSameAsElseCase): (JSC::testMoveDoubleConditionallyFloat): (JSC::testMoveDoubleConditionallyFloatDestSameAsThenCase): (JSC::testMoveDoubleConditionallyFloatDestSameAsElseCase): (JSC::testMoveConditionallyFloatingPointSameArg): (JSC::testMoveConditionallyDouble2SameArg): (JSC::testMoveConditionallyDouble3SameArg): (JSC::testMoveConditionallyFloat2SameArg): (JSC::testMoveConditionallyFloat3SameArg): (JSC::testMoveDoubleConditionallyDoubleSameArg): (JSC::testMoveDoubleConditionallyFloatSameArg): (JSC::run):
2:06 PM Changeset in webkit [258589] by Alan Coon
  • 5 edits in branches/safari-609-branch/Source/WebCore

Apply patch. rdar://problem/60396271

2:04 PM Changeset in webkit [258588] by BJ Burg
  • 2 edits in trunk/Source/WebKit

REGRESSION(r256882): WebDriver commands that run before initial navigation do not complete
https://bugs.webkit.org/show_bug.cgi?id=209185
<rdar://problem/60010248>

Reviewed by Brian Weinstein.

No new tests, covered by w3c/webdriver/tests/back/back.py.

  • UIProcess/Automation/WebAutomationSession.cpp:

(WebKit::WebAutomationSession::createBrowsingContext):
Force eager creation of WebProcess when a browsing context is created. This allows
all subsequent commands that use WebProcess IPC to proceed instead of hanging.

1:52 PM Changeset in webkit [258587] by eric.carlson@apple.com
  • 8 edits
    2 adds in trunk

TextTrackBase should validate language before setting m_validBCP47Language
https://bugs.webkit.org/show_bug.cgi?id=209094
<rdar://problem/60439603>

Reviewed by Jer Noble.
Source/WebCore:

Test: media/track/track-bcp-language.html

  • html/track/TextTrack.idl:
  • html/track/TrackBase.cpp:

(WebCore::TrackBase::TrackBase): Don't set m_validBCP47Language unless the language is valid.
(WebCore::TrackBase::setLanguage): Clear m_validBCP47Language if the language is invalid.
Restructure the code to use early returns.
(WebCore::TrackBase::validBCP47Language const): Deleted.

  • html/track/TrackBase.h:

(WebCore::TrackBase::validBCP47Language const):

  • testing/Internals.cpp:

(WebCore::Internals::textTrackBCP47Language):

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

LayoutTests:

  • media/track/track-bcp-language-expected.txt: Added.
  • media/track/track-bcp-language.html: Added.
1:47 PM Changeset in webkit [258586] by aakash_jain@apple.com
  • 3 edits in trunk/Tools

[ews-app] Timestamp shown in status-bubble hover-over message is in future
https://bugs.webkit.org/show_bug.cgi?id=196628

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-build/events.py:

(JSONProducer.json_serialize_datetime): Keep the timestamp in UTC, instead of converting it to local time zone.

  • BuildSlaveSupport/ews-app/ews/views/statusbubble.py:

(StatusBubble.get_all_builds_for_queue): Sort the queues based on build number instead of start time, since the
timestamps for new builds might be less than timestamps for old builds which completed immediately prior to this change.

1:46 PM Changeset in webkit [258585] by Jacob Uphoff
  • 2 edits in trunk/LayoutTests

[ macOS wk2 ] imported/w3c/web-platform-tests/webrtc/RTCRtpReceiver-getSynchronizationSources.https.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=209194

Unreviewed test gardening

  • platform/mac-wk2/TestExpectations:
1:39 PM Changeset in webkit [258584] by Alan Coon
  • 4 edits
    2 adds in branches/safari-609-branch

Cherry-pick r258459. rdar://problem/60539192

SVGMatrix should have the access right of its owner SVGTransform always
https://bugs.webkit.org/show_bug.cgi?id=207462

Reviewed by Simon Fraser.

Source/WebCore:

The SVGMatrix needs to be reattached to its owner SVGTransform when the
access right of this owner changes. The access right of the owner changes
when it gets attached to or detached from a higher level owner.

Test: svg/dom/SVGTransformList-anim-read-only.html

  • svg/SVGTransform.h:
  • svg/properties/SVGProperty.h: (WebCore::SVGProperty::attach): (WebCore::SVGProperty::detach): (WebCore::SVGProperty::reattach):

LayoutTests:

  • svg/dom/SVGTransformList-anim-read-only-expected.txt: Added.
  • svg/dom/SVGTransformList-anim-read-only.html: Added.

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

1:39 PM Changeset in webkit [258583] by Alan Coon
  • 3 edits
    2 adds in branches/safari-609-branch

Cherry-pick r258455. rdar://problem/60539179

[Tree building] Block::attachIgnoringContinuation should allow inline tables as before child container
https://bugs.webkit.org/show_bug.cgi?id=209095
<rdar://problem/59837588>

Reviewed by Simon Fraser.

Source/WebCore:

It's perfectly valid to have an inline table as the anonymous container for the before child.
It'll get wrapped inside an anonymous block right before we insert the block box candidate, so
the final result will be something like:

new block level child (this is the child we are inserting)
anonymous block wrapper

inline table (this is the before child's inline container)

before child

Test: fast/table/before-child-is-inline-table.html

  • rendering/updating/RenderTreeBuilderBlock.cpp: (WebCore::RenderTreeBuilder::Block::attachIgnoringContinuation):

LayoutTests:

  • fast/table/before-child-is-inline-table-expected.txt: Added.
  • fast/table/before-child-is-inline-table.html: Added.

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

1:39 PM Changeset in webkit [258582] by Alan Coon
  • 2 edits in branches/safari-609-branch/Source/JavaScriptCore

Cherry-pick r258381. rdar://problem/60539195

DFG nodes that take a TypedArray's storage need to keepAlive the TypedArray
https://bugs.webkit.org/show_bug.cgi?id=209035

Reviewed by Saam Barati.

It might be possible to produce a graph where the last reference to a TypedArray
is via a GetByVal or PutByVal. Since those nodes don't create any reference to the
TypedArray in B3 we may end up not keeping the TypedArray alive until after the
storage access.

  • ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileAtomicsReadModifyWrite): (JSC::FTL::DFG::LowerDFGToB3::compileGetByVal): (JSC::FTL::DFG::LowerDFGToB3::compilePutByVal):

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

1:39 PM Changeset in webkit [258581] by Alan Coon
  • 2 edits in branches/safari-609-branch/Source/WebCore

Cherry-pick r258267. rdar://problem/60539190

Consolidate detachment of document timeline into Document::commonTeardown.
https://bugs.webkit.org/show_bug.cgi?id=208786
<rdar://problem/59936716>

Patch by Jack Lee <Jack Lee> on 2020-03-11
Reviewed by Ryosuke Niwa.

Move detachment of DocumentTimeline to Document::commonTeardown().

No new tests. Covered by existing document tests.

  • dom/Document.cpp: (WebCore::Document::removedLastRef): (WebCore::Document::commonTeardown): (WebCore::Document::prepareForDestruction):

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

1:39 PM Changeset in webkit [258580] by Alan Coon
  • 2 edits in branches/safari-609-branch/Source/WebCore

Cherry-pick r255997. rdar://problem/60495055

Incorrect TextTrack sorting with invalid BCP47 language
https://bugs.webkit.org/show_bug.cgi?id=207315

Patch by Doug Kelly <Doug Kelly> on 2020-02-06
Reviewed by Jer Noble.

When comparing TextTracks, this ensures all tracks are compared based on consistent parameters, including tracks with an invalid BCP47
language attribute.

  • page/CaptionUserPreferencesMediaAF.cpp: (WebCore::textTrackCompare):

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

1:28 PM Changeset in webkit [258579] by Alan Coon
  • 2 edits in branches/safari-609.2.1.2-branch/Source/JavaScriptCore

Cherry-pick r258381. rdar://problem/60539194

DFG nodes that take a TypedArray's storage need to keepAlive the TypedArray
https://bugs.webkit.org/show_bug.cgi?id=209035

Reviewed by Saam Barati.

It might be possible to produce a graph where the last reference to a TypedArray
is via a GetByVal or PutByVal. Since those nodes don't create any reference to the
TypedArray in B3 we may end up not keeping the TypedArray alive until after the
storage access.

  • ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileAtomicsReadModifyWrite): (JSC::FTL::DFG::LowerDFGToB3::compileGetByVal): (JSC::FTL::DFG::LowerDFGToB3::compilePutByVal):

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

1:28 PM Changeset in webkit [258578] by Alan Coon
  • 2 edits in branches/safari-609.2.1.2-branch/Source/WebCore

Cherry-pick r255997. rdar://problem/60507340

Incorrect TextTrack sorting with invalid BCP47 language
https://bugs.webkit.org/show_bug.cgi?id=207315

Patch by Doug Kelly <Doug Kelly> on 2020-02-06
Reviewed by Jer Noble.

When comparing TextTracks, this ensures all tracks are compared based on consistent parameters, including tracks with an invalid BCP47
language attribute.

  • page/CaptionUserPreferencesMediaAF.cpp: (WebCore::textTrackCompare):

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

1:24 PM Changeset in webkit [258577] by Alan Coon
  • 8 edits in branches/safari-609.2.1.2-branch/Source

Versioning.

12:52 PM Changeset in webkit [258576] by Simon Fraser
  • 8 edits
    2 moves in trunk/LayoutTests

REGRESSION (257844): fast/scrolling/scroll-container-horizontally.html is timing out
https://bugs.webkit.org/show_bug.cgi?id=209083

Unreviewed test gardening.

mac/scroll-container-horizontally.html is a wheel event test, so move it to the mac directory.

  • fast/scrolling/mac/scroll-container-horizontally-expected.txt: Renamed from LayoutTests/fast/scrolling/scroll-container-horizontally-expected.txt.
  • fast/scrolling/mac/scroll-container-horizontally.html: Renamed from LayoutTests/fast/scrolling/scroll-container-horizontally.html.
  • platform/gtk/TestExpectations:
  • platform/ios-wk1/TestExpectations:
  • platform/ios-wk2/TestExpectations:
  • platform/ios/TestExpectations:
  • platform/mac-wk1/TestExpectations:
  • platform/mac-wk2/TestExpectations:
  • platform/win/TestExpectations:
12:49 PM Changeset in webkit [258575] by achristensen@apple.com
  • 2 edits in trunk/Source/WebKit

Fix GTK build.
https://bugs.webkit.org/show_bug.cgi?id=209192

  • UIProcess/API/glib/WebKitUIClient.cpp:

I committed r258574 too fast.

12:46 PM Changeset in webkit [258574] by achristensen@apple.com
  • 9 edits in trunk

Add WKUIDelegatePrivate SPI _webView:printFrame:completionHandler:
https://bugs.webkit.org/show_bug.cgi?id=209192
<rdar://problem/51313336>

Reviewed by Geoff Garen.

Source/WebKit:

This is just like the existing _webView:printFrame: but you tell it when you're done instead of just returning.
Covered by API tests.

  • UIProcess/API/APIUIClient.h:

(API::UIClient::printFrame):

  • UIProcess/API/C/WKPage.cpp:

(WKPageSetPageUIClient):

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

(WebKit::UIDelegate::setDelegate):
(WebKit::UIDelegate::UIClient::printFrame):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::printFrame):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/UIDelegate.mm:

(-[PrintDelegateWithCompletionHandler _webView:printFrame:completionHandler:]):
(-[PrintDelegateWithCompletionHandler waitForPrintFrameCall]):
(TEST):

12:45 PM Changeset in webkit [258573] by Tadeu Zagallo
  • 2 edits in trunk/Source/JavaScriptCore

AccessCase::canReplace should allow a Getter to replace an IntrinsicGetter
https://bugs.webkit.org/show_bug.cgi?id=209158
<rdar://problem/59222012>

Reviewed by Saam Barati.

When we override an intrinsic getter with a user defined getter, we might end up with the
same offset and attributes. In which case, an inline cache that contained an entry for the
intrisic getter will believe that it is still valid, and add a new getter access case,
leading to duplicate entries for the same structure.

  • bytecode/AccessCase.cpp:

(JSC::AccessCase::canReplace const):

12:39 PM Changeset in webkit [258572] by graouts@webkit.org
  • 3 edits in trunk/LayoutTests

http/wpt/css/css-animations/start-animation-001.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=207337
<rdar://problem/59226371>

Reviewed by Dean Jackson.

This test was written in a flaky way for two reasons:

  1. it was using a timer to assume state in the animation engine
  2. it was using an accelerated animation that wasn't absolutely required to as an indicator of what a non-steps based version of the tested animation would look like, but accelerated animations are notoriously hard to test for rendering purposes

We update the test to use the secondary animation as a timer so that we can test the state of animations at 200ms precisely,
and we get rid of the accelerated animation such that only the tested animation's rendering is tested.

  • http/wpt/css/css-animations/start-animation-001.html:
  • platform/mac/TestExpectations:
12:32 PM Changeset in webkit [258571] by graouts@webkit.org
  • 2 edits in trunk/LayoutTests

REGRESSION (r258411): imported/w3c/web-platform-tests/dom/events/Event-dispatch-redispatch.html is failing consistently
https://bugs.webkit.org/show_bug.cgi?id=209175
<rdar://problem/60513114>

Unreviewed test gardening.

Actually, this test is not a pass on OpenSource iOS bots, reverting.

  • platform/ios-wk2/imported/w3c/web-platform-tests/dom/events/Event-dispatch-redispatch-expected.txt:
12:10 PM Changeset in webkit [258570] by Alan Coon
  • 14 edits in branches/safari-610.1.7-branch/Source

Cherry-pick r258557. rdar://problem/60517387

[Cocoa] Disable CF prefs direct mode
https://bugs.webkit.org/show_bug.cgi?id=209166
<rdar://problem/60517387>

Reviewed by Brent Fulgham.

Revert <https://trac.webkit.org/changeset/258064> by disabling the CF prefs direct mode feature,
since it caused performance regressions.

Source/WebKit:

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm: (WebKit::XPCServiceMain):
  • UIProcess/Cocoa/PreferenceObserver.mm:
  • UIProcess/Cocoa/WebPageProxyCocoa.mm: (WebKit::WebPageProxy::grantAccessToPreferenceService):
  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:
  • UIProcess/Cocoa/WebProcessProxyCocoa.mm:
  • UIProcess/WebProcessPool.h:
  • UIProcess/WebProcessProxy.h:
  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:

Source/WTF:

  • wtf/PlatformEnable.h:

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

12:10 PM Changeset in webkit [258569] by Alan Coon
  • 2 edits in branches/safari-610.1.7-branch/Source/WebKit

Cherry-pick r258512. rdar://problem/60517387

[Cocoa] Only set CF prefs direct mode for the WebContent process
https://bugs.webkit.org/show_bug.cgi?id=209091
<rdar://problem/60337842>

Reviewed by Brent Fulgham.

Currently, we enable CF prefs direct mode in XPCServiceMain. This is incorrect, it should only be enabled
for the WebContent process.

  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm: (WebKit::XPCServiceMain):

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

12:03 PM Changeset in webkit [258568] by Alan Coon
  • 8 edits in branches/safari-610.1.7-branch/Source

Versioning.

11:40 AM Changeset in webkit [258567] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

[ Mac wk2 ] http/tests/IndexedDB/storage-limit.https.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=209189

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
11:33 AM Changeset in webkit [258566] by Chris Dumez
  • 5 edits in trunk

Use less sync IPC for ITP testRunner methods
https://bugs.webkit.org/show_bug.cgi?id=209184

Reviewed by Alex Christensen.

  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::setStatisticsDebugMode):
(WTR::TestRunner::setStatisticsPrevalentResourceForDebugMode):
(WTR::TestRunner::setStatisticsLastSeen):
(WTR::TestRunner::setStatisticsMergeStatistic):
(WTR::TestRunner::setStatisticsPrevalentResource):
(WTR::TestRunner::setStatisticsVeryPrevalentResource):
(WTR::TestRunner::installStatisticsDidScanDataRecordsCallback):

  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):

11:33 AM Changeset in webkit [258565] by ddkilzer@apple.com
  • 2 edits in trunk/Source/WebKit

REGRESSION (r258334): WebPasteboardProxy::setPasteboardBufferForType should allow zero-size buffers
<https://webkit.org/b/209167>
<rdar://problem/60516302>

Reviewed by Geoffrey Garen.

  • UIProcess/Cocoa/WebPasteboardProxyCocoa.mm:

(WebKit::WebPasteboardProxy::setPasteboardBufferForType):

  • Remove check for zero-size buffer to match WebPageProxy::dataSelectionForPasteboard().
11:31 AM Changeset in webkit [258564] by achristensen@apple.com
  • 6 edits in trunk/Source

REGRESSION(r254856) Add exception for window.openDatabase to not masquerade as undefined in currently shipping Jesus Calling Devotional app
https://bugs.webkit.org/show_bug.cgi?id=209160
<rdar://problem/60297073>

Reviewed by Geoff Garen.

Source/WebCore:

Manually verified this fixes the app, which compares typeof openDatabase with 'undefined'
Going forward, we intend to completely remove WebSQL, so this is a temporary exception to our removal strategy.

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::openDatabase const):

  • platform/RuntimeApplicationChecks.h:
  • platform/cocoa/RuntimeApplicationChecksCocoa.mm:

(WebCore::IOSApplication::isJesusCalling):

Source/WTF:

  • wtf/spi/darwin/dyldSPI.h:
11:18 AM Changeset in webkit [258563] by Jason_Lawrence
  • 3 edits in trunk/LayoutTests

[ macOS wk1 ] platform/mac/webrtc/captureCanvas-webrtc-software-encoder.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=207150

Unreviewed test gardening.

Adjusted the test expectations to further reflect the issue.

  • platform/mac-wk1/TestExpectations:
  • platform/mac/TestExpectations:
11:17 AM Changeset in webkit [258562] by Chris Dumez
  • 3 edits
    2 adds in trunk

[WKTR] Crash when trying to open a new window in an ephemeral session test
https://bugs.webkit.org/show_bug.cgi?id=209181

Reviewed by Geoffrey Garen.

Tools:

Make sure that the new WKWebView is using the same data store as its related WKWebView.

  • WebKitTestRunner/cocoa/TestControllerCocoa.mm:

(WTR::TestController::platformCreateOtherPage):

LayoutTests:

Add layout test coverage.

  • fast/dom/window-open-ephemeral-expected.txt: Added.
  • fast/dom/window-open-ephemeral.html: Added.
11:07 AM Changeset in webkit [258561] by Simon Fraser
  • 15 edits in trunk/LayoutTests

Clean up some latching tests
https://bugs.webkit.org/show_bug.cgi?id=209170

Reviewed by Antti Koivisto.

These tests were weird in various ways:

  • <table>s to take up space when a simple <div> would do
  • Mixture of js-test-pre/post and waitUntilDone/notifyDone
  • JS in script tag at the start of the body

Fix these things.

  • tiled-drawing/scrolling/fast-scroll-div-latched-div-expected.txt:
  • tiled-drawing/scrolling/fast-scroll-div-latched-div-with-handler-expected.txt:
  • tiled-drawing/scrolling/fast-scroll-div-latched-div-with-handler.html:
  • tiled-drawing/scrolling/fast-scroll-div-latched-div.html:
  • tiled-drawing/scrolling/fast-scroll-div-latched-mainframe-expected.txt:
  • tiled-drawing/scrolling/fast-scroll-div-latched-mainframe-with-handler.html:
  • tiled-drawing/scrolling/fast-scroll-div-latched-mainframe.html:
  • tiled-drawing/scrolling/fast-scroll-iframe-latched-iframe-expected.txt:
  • tiled-drawing/scrolling/fast-scroll-iframe-latched-iframe-with-handler-expected.txt:
  • tiled-drawing/scrolling/fast-scroll-iframe-latched-iframe-with-handler.html:
  • tiled-drawing/scrolling/fast-scroll-iframe-latched-iframe.html:
  • tiled-drawing/scrolling/fast-scroll-mainframe-zoom-expected.txt:
  • tiled-drawing/scrolling/fast-scroll-mainframe-zoom.html:
  • tiled-drawing/scrolling/scrolling-no-iframe-latching.html:
11:07 AM Changeset in webkit [258560] by Andres Gonzalez
  • 4 edits in trunk/Source/WebCore

AXIsolatedTree removal should set all nodes to be removed on AX secondary thread.
https://bugs.webkit.org/show_bug.cgi?id=209169

Reviewed by Chris Fleizach.

  • AXIsolatedTree::removeTreeForPageID is called on the main thread but

it should not remove the nodes in the main thread, but instead add them
to the pending changes to be removed on the secondary thread. This was
causing the problem of empty new trees when the old tree would go away
but the client was holding a reference to an object that has been
disconnected and thus had no children.

  • In addition, this change fixes an isolated tree mode crash in AccessibilityMenuList.
  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::~AXObjectCache):

  • accessibility/AccessibilityMenuList.cpp:

(WebCore::AccessibilityMenuList::isCollapsed const):

  • accessibility/isolatedtree/AXIsolatedTree.cpp:

(WebCore::AXIsolatedTree::removeTreeForPageID):

10:28 AM Changeset in webkit [258559] by Brent Fulgham
  • 2 edits in trunk/Source/WebKit

Terminate the WebContent process when receiving invalid IPC from a WebInspector session
https://bugs.webkit.org/show_bug.cgi?id=209157
<rdar://problem/58961055>

Reviewed by Chris Dumez.

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::backForwardGoToItemShared): Add a message check that we are not receiving
the request from a WebInspector page.
(WebKit::WebPageProxy::maybeInitializeSandboxExtensionHandle): Switch to a release assert.

10:14 AM Changeset in webkit [258558] by Jacob Uphoff
  • 11 edits in trunk

Unreviewed, reverting r257844.

this revision caused a test to start timing out

Reverted changeset:

"(r256513) [ Mac ] fast/scrolling/programmatic-scroll-to-zero-
zero.html is a flaky failure"
https://bugs.webkit.org/show_bug.cgi?id=207948
https://trac.webkit.org/changeset/257844

9:59 AM Changeset in webkit [258557] by pvollan@apple.com
  • 14 edits in trunk/Source

[Cocoa] Disable CF prefs direct mode
https://bugs.webkit.org/show_bug.cgi?id=209166
<rdar://problem/60517387>

Reviewed by Brent Fulgham.

Revert <https://trac.webkit.org/changeset/258064> by disabling the CF prefs direct mode feature,
since it caused performance regressions.

Source/WebKit:

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm:

(WebKit::XPCServiceMain):

  • UIProcess/Cocoa/PreferenceObserver.mm:
  • UIProcess/Cocoa/WebPageProxyCocoa.mm:

(WebKit::WebPageProxy::grantAccessToPreferenceService):

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:
  • UIProcess/Cocoa/WebProcessProxyCocoa.mm:
  • UIProcess/WebProcessPool.h:
  • UIProcess/WebProcessProxy.h:
  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:

Source/WTF:

  • wtf/PlatformEnable.h:
9:50 AM Changeset in webkit [258556] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

[ Mac wk2 ] webrtc/concurrentVideoPlayback.html is flaky timing out.
https://bugs.webkit.org/show_bug.cgi?id=209183

unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
9:47 AM Changeset in webkit [258555] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

Unreviewed, reverting r258554.

Incorrect expectations set.

Reverted changeset:

"[ Mac wk2 ] webrtc/concurrentVideoPlayback.html is flaky
timing out."
https://bugs.webkit.org/show_bug.cgi?id=209183
https://trac.webkit.org/changeset/258554

9:43 AM Changeset in webkit [258554] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

[ Mac wk2 ] webrtc/concurrentVideoPlayback.html is flaky timing out.
https://bugs.webkit.org/show_bug.cgi?id=209183

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
9:20 AM Changeset in webkit [258553] by commit-queue@webkit.org
  • 6 edits
    1 copy
    5 adds in trunk/LayoutTests

Update wpt tests imported/w3c/web-platform-tests/html/rendering/non-replaced-elements/the-page
https://bugs.webkit.org/show_bug.cgi?id=209178

Patch by Frederic Wang <fwang@igalia.com> on 2020-03-17
Reviewed by Rob Buis.

LayoutTests/imported/w3c:

  • resources/resource-files.json:
  • web-platform-tests/html/rendering/non-replaced-elements/the-page/iframe-scrolling-attribute-expected.html: Added.
  • web-platform-tests/html/rendering/non-replaced-elements/the-page/iframe-scrolling-attribute-values-expected.html: Added.
  • web-platform-tests/html/rendering/non-replaced-elements/the-page/iframe-scrolling-attribute-values.html: Added.
  • web-platform-tests/html/rendering/non-replaced-elements/the-page/iframe-scrolling-attribute.html: Added.
  • web-platform-tests/html/rendering/non-replaced-elements/the-page/support/big-page.html: Added.
  • web-platform-tests/html/rendering/non-replaced-elements/the-page/support/w3c-import.log:
  • web-platform-tests/html/rendering/non-replaced-elements/the-page/w3c-import.log:

LayoutTests:

This imports a new test for bug 208570.

9:18 AM Changeset in webkit [258552] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

[ Mac wk1 Debug] inspector/debugger/setShouldBlackboxURL.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=209182

Unreviewed test gardening.

  • platform/mac-wk1/TestExpectations:
8:48 AM Changeset in webkit [258551] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

[ Mac wk1 ] inspector/script-profiler/event-type-Other.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=209180

Unreviewed test gardening.

  • platform/mac-wk1/TestExpectations:
8:39 AM Changeset in webkit [258550] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

REGRESSION(r257759): Web Inspector: Settings icon sometimes placed below the tab bar
https://bugs.webkit.org/show_bug.cgi?id=208603
<rdar://problem/60108967>

Reviewed by Brian Burg.

  • UserInterface/Views/TabBar.js:

(WI.TabBar.prototype.layout):
Don't take into account the width of the flexible space before or after the normal tab bar
items since they will shrink to fit (the container is using display: flex;). Instead, use
determine the available space by subtracting the width of every WI.PinnedTabBarItem from
the realOffsetWidth of the container, comparing against the sum of the realOffsetWidth
of all WI.GeneralTabBarItem. If the sum is greater than the available space, successively
mark items from the end (right in LTR, left in RTL) as hidden until the remaining will fit.

8:36 AM Changeset in webkit [258549] by commit-queue@webkit.org
  • 32 edits in trunk/Source

Unreviewed, reverting r258339.
https://bugs.webkit.org/show_bug.cgi?id=209179

"Is it sometimes breaking rendering" (Requested by youenn on
#webkit).

Reverted changeset:

"FrameLoader should own its FrameLoaderClient"
https://bugs.webkit.org/show_bug.cgi?id=208918
https://trac.webkit.org/changeset/258339

8:19 AM Changeset in webkit [258548] by commit-queue@webkit.org
  • 2 edits
    2 adds in trunk/LayoutTests

pointerevents/ios/touch-action-none-link-traversal.html times out
https://bugs.webkit.org/show_bug.cgi?id=209177
<rdar://problem/60393055>

Patch by Antoine Quint <Antoine Quint> on 2020-03-17
Reviewed by Antti Koivisto.

  • pointerevents/ios/resources/touch-action-none-link-traversal-resource.html: Added.
  • pointerevents/ios/touch-action-none-link-traversal.html:
7:56 AM Changeset in webkit [258547] by Philippe Normand
  • 30 edits
    1 add in trunk

RELEASE_LOG should not be Cocoa specific
https://bugs.webkit.org/show_bug.cgi?id=195182

Reviewed by Konstantin Tokarev.

.:

Add a Systemd Journald Logger implementation, enabled by default
in the GTK and WPE ports. When this is enabled, release logs will
be sent to the Systemd Journal. To retrieve media logs for
instance, this command can be used:

$ journalctl WEBKIT_SUBSYSTEM=WebKitGTK WEBKIT_CHANNEL=Media

  • Source/cmake/FindSystemd.cmake: Added.
  • Source/cmake/OptionsGTK.cmake:
  • Source/cmake/OptionsWPE.cmake:

Source/WebCore:

WPE/GTK build fixes related with Release logging support.

  • bridge/npruntime_internal.h:
  • dom/ScriptedAnimationController.cpp:

(WebCore::throttlingReasonToString):

  • page/PerformanceLogging.cpp:

(WebCore::toString):

  • page/PerformanceMonitor.cpp:

(WebCore::stringForCPUSamplingActivityState):

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:

(WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
(WebCore::MediaPlayerPrivateGStreamer::logChannel const):

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:

(WebCore::MediaPlayerPrivateGStreamer::mediaPlayerLogIdentifier):
(WebCore::MediaPlayerPrivateGStreamer::mediaPlayerLogger):

  • platform/graphics/gstreamer/eme/CDMProxyClearKey.cpp:

(WebCore::CDMProxyClearKey::cencDecryptSubsampled):
(WebCore::CDMProxyClearKey::initializeGcrypt):

  • platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.h:
  • platform/graphics/gstreamer/mse/MediaSourceGStreamer.cpp:

(WebCore::MediaSourceGStreamer::MediaSourceGStreamer):
(WebCore::MediaSourceGStreamer::~MediaSourceGStreamer):
(WebCore::MediaSourceGStreamer::addSourceBuffer):
(WebCore::MediaSourceGStreamer::logChannel const):

  • platform/graphics/gstreamer/mse/MediaSourceGStreamer.h:
  • platform/graphics/gstreamer/mse/SourceBufferPrivateGStreamer.cpp:

(WebCore::SourceBufferPrivateGStreamer::SourceBufferPrivateGStreamer):
(WebCore::SourceBufferPrivateGStreamer::logChannel const):

  • platform/graphics/gstreamer/mse/SourceBufferPrivateGStreamer.h:
  • platform/mediastream/AudioMediaStreamTrackRenderer.cpp:
  • platform/mediastream/libwebrtc/LibWebRTCProvider.cpp:

(WebCore::computeLogLevel):

  • platform/network/soup/NetworkStorageSessionSoup.cpp:

(WebCore::NetworkStorageSession::getRawCookies const):

Source/WTF:

Add sd-journal logging support and wrap the os_log calls with the USE(OS_LOG) guard.

  • wtf/Assertions.cpp:
  • wtf/Assertions.h:
  • wtf/Logger.h:

(WTF::Logger::log):

  • wtf/MemoryPressureHandler.cpp:

(WTF::toString):

  • wtf/PlatformGTK.cmake:
  • wtf/PlatformWPE.cmake:
  • wtf/RefCountedLeakCounter.cpp:
4:45 AM Changeset in webkit [258546] by graouts@webkit.org
  • 2 edits in trunk/LayoutTests

REGRESSION (r258411): imported/w3c/web-platform-tests/dom/events/Event-dispatch-redispatch.html is failing consistently
https://bugs.webkit.org/show_bug.cgi?id=209175
<rdar://problem/60513114>

Unreviewed test gardening.

Following r258411 this test is a PASS on iOS. Adjusting the expectation.

  • platform/ios-wk2/imported/w3c/web-platform-tests/dom/events/Event-dispatch-redispatch-expected.txt:
3:59 AM WebKitGTK/2.28.x edited by Philippe Normand
(diff)
3:50 AM Changeset in webkit [258545] by youenn@apple.com
  • 5 edits in trunk

Safari doesn't insert mDNS candidates to SDP
https://bugs.webkit.org/show_bug.cgi?id=209050
<rdar://problem/60419936>

Reviewed by Eric Carlson.

Source/WebCore:

Instead of removing host candidate lines in SDP, replace the host IP address by the corresponding mDNS name.
Covered by updated test.

  • Modules/mediastream/PeerConnectionBackend.cpp:

(WebCore::extractIPAddress):
(WebCore::PeerConnectionBackend::filterSDP const):
(WebCore::PeerConnectionBackend::finishedRegisteringMDNSName):

  • Modules/mediastream/PeerConnectionBackend.h:

LayoutTests:

  • webrtc/datachannel/mdns-ice-candidates.html:
3:42 AM Changeset in webkit [258544] by Alexey Shvayka
  • 1 edit
    2 adds in trunk/LayoutTests

Sync web-platform-tests/css/css-cascade from upstream
https://bugs.webkit.org/show_bug.cgi?id=209150

Unreviewed test gardening.

  • platform/ios/imported/w3c/web-platform-tests/css/css-cascade: Added.
  • platform/ios/imported/w3c/web-platform-tests/css/css-cascade/all-prop-initial-xml-expected.txt: Added.
3:14 AM Changeset in webkit [258543] by Alexey Shvayka
  • 4 edits
    41 adds in trunk/LayoutTests

Sync web-platform-tests/css/css-cascade from upstream
https://bugs.webkit.org/show_bug.cgi?id=209150

Reviewed by Youenn Fablet.

Sync web-platform-tests/css/css-cascade from upstream ec2bf5a86c00.

LayoutTests/imported/w3c:

  • resources/import-expectations.json:
  • web-platform-tests/css/css-cascade/*: Added.

LayoutTests:

2:36 AM Changeset in webkit [258542] by Philippe Normand
  • 5 edits in trunk/Source/WebCore

[GStreamer][MSE] Playback rate update support
https://bugs.webkit.org/show_bug.cgi?id=208454

Reviewed by Xabier Rodriguez-Calvar.

Implement playback rate update support for the MSE player. Also
includes drive-by logging cleanups.

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:

(WebCore::MediaPlayerPrivateGStreamer::updatePlaybackRate):
(WebCore::MediaPlayerPrivateGStreamer::setRate):
(WebCore::MediaPlayerPrivateGStreamer::setPreservesPitch):

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:

(WebCore::MediaPlayerPrivateGStreamer::pipeline const):

  • platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp:

(WebCore::MediaPlayerPrivateGStreamerMSE::seek):
(WebCore::MediaPlayerPrivateGStreamerMSE::doSeek):
(WebCore::MediaPlayerPrivateGStreamerMSE::maybeFinishSeek):
(WebCore::MediaPlayerPrivateGStreamerMSE::seekCompleted):
(WebCore::MediaPlayerPrivateGStreamerMSE::updatePlaybackRate): Deleted.
(WebCore::MediaPlayerPrivateGStreamerMSE::setRate): Deleted.

  • platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.h:

Mar 16, 2020:

10:27 PM Changeset in webkit [258541] by Simon Fraser
  • 6 edits in trunk

Remove the zero-delay ScrollingCoordinatorMac commit timer
https://bugs.webkit.org/show_bug.cgi?id=209164

Reviewed by Zalan Bujtas.

Source/WebCore:

The scrolling tree on macOS should just commit at rendering update time. There's no need
for a separate zero-delay timer.

Tested by existing tests.

  • page/scrolling/mac/ScrollingCoordinatorMac.h:
  • page/scrolling/mac/ScrollingCoordinatorMac.mm:

(WebCore::ScrollingCoordinatorMac::ScrollingCoordinatorMac):
(WebCore::ScrollingCoordinatorMac::pageDestroyed):
(WebCore::ScrollingCoordinatorMac::scheduleTreeStateCommit):
(WebCore::ScrollingCoordinatorMac::commitTreeStateIfNeeded):
(WebCore::ScrollingCoordinatorMac::commitTreeState): Deleted.

LayoutTests:

Dumping layers just made this test flakey. It's enough to test for scroll events on the overflow.

  • tiled-drawing/scrolling/fast-scroll-div-latched-mainframe-expected.txt:
  • tiled-drawing/scrolling/fast-scroll-div-latched-mainframe.html:
10:22 PM Changeset in webkit [258540] by ysuzuki@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

[JSC] JSMapIterator and JSSetIterator are CellType
https://bugs.webkit.org/show_bug.cgi?id=209168
<rdar://problem/59705631>

Reviewed by Saam Barati.

They are JSCell, not JSObject since they are not used as a user-observable set/map iterators in JSC.
However, their JSType is ObjectType. They should use CellType instead.

  • runtime/JSMapIterator.h:
  • runtime/JSSetIterator.h:
10:09 PM Changeset in webkit [258539] by Simon Fraser
  • 5 edits in trunk/Source

Add a bit more UIHitTesting logging, and make it possible to dump EventRegions from WebKit
https://bugs.webkit.org/show_bug.cgi?id=209058

Reviewed by Antti Koivisto.

Source/WebCore:

Export operator<<(TextStream&, const EventRegion&) so it can be used from Webkit.

  • rendering/EventRegion.h:

Source/WebKit:

Add a UIHitTesting log.

  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView gestureRecognizer:shouldReceiveTouch:]):

9:44 PM Changeset in webkit [258538] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebCore

Remove a 'using namespace WebCore' in MediaSessionManagerCocoa
https://bugs.webkit.org/show_bug.cgi?id=209162

Reviewed by Simon Fraser.

  • platform/audio/cocoa/MediaSessionManagerCocoa.mm:

Unified source cleanliness. Not currently causing any trouble, but
it did when I changed something locally!

7:30 PM WebKitGTK/2.28.x edited by clopez@igalia.com
(diff)
6:32 PM Changeset in webkit [258537] by Lauro Moura
  • 3 edits in trunk/LayoutTests

WPE and GTK gardening.

Unreviewed test gardening.

  • platform/gtk/TestExpectations:
  • platform/wpe/TestExpectations:
6:01 PM Changeset in webkit [258536] by Nikita Vasilyev
  • 2 edits in trunk/Source/WebInspectorUI

REGRESSION(r257380): Web Inspector: deleting node causes TreeOutline to lose focus
https://bugs.webkit.org/show_bug.cgi?id=208364
<rdar://problem/59871772>

Reviewed by Devin Rousso.

Maintain keyboard focus within TreeOutline when selection changes.

  • UserInterface/Views/TreeElement.js:

(WI.TreeElement.prototype.select):

5:32 PM Changeset in webkit [258535] by Alan Coon
  • 1 copy in tags/Safari-610.1.7.4

Tag Safari-610.1.7.4.

5:31 PM Changeset in webkit [258534] by Alan Coon
  • 8 edits in branches/safari-610.1.7-branch/Source

Versioning.

5:30 PM Changeset in webkit [258533] by achristensen@apple.com
  • 2 edits in trunk/Source/WebCore/PAL

Build fix.

https://bugs.webkit.org/show_bug.cgi?id=208951

  • pal/spi/cocoa/AVFoundationSPI.h:

r258314 was missing a nullability annotation.

5:14 PM Changeset in webkit [258532] by rniwa@webkit.org
  • 3 edits
    2 adds in trunk

A change event gets dispatched when textarea gets changed without focus
https://bugs.webkit.org/show_bug.cgi?id=202144

Patch by ChangSeok Oh <ChangSeok Oh> on 2020-03-16
Reviewed by Ryosuke Niwa.

Source/WebCore:

A crash happens in WebCore::ValidationMessage::buildBubbleTree. An immediate reason
is that DOM tree is modified in buildBubbleTree triggered by a timer.
The function calls document.updateLayout() that causes a change event
for textarea to fire when something changed in the textarea.
This bug is not reproduced on Mac because buildBubbleTree is not called.
See ValidationMessage::setMessage.
On the other hand, the root cause of this issue is triggering the change event
for textarea even if it is not focused when a change is made. This behavior
is different to what Gecko and Chromium do. When loading the test, they do not
trigger the change event although the textarea is filled by the script
since the textarea is not focused. Only when we manually make a change (meaning
the textarea is focused by user input), the event gets dispatched. To fix it,
setChangedSinceLastFormControlChangeEvent(true) is moved below the focus check
in HTMLTextAreaElement::subtreeHasChanged();

Test: fast/forms/textfield-onchange-without-focus.html

  • html/HTMLTextAreaElement.cpp:

(WebCore::HTMLTextAreaElement::subtreeHasChanged):

LayoutTests:

The test should be identical to the extected result without crash.

  • fast/forms/textfield-onchange-without-focus-expected.html: Added.
  • fast/forms/textfield-onchange-without-focus.html: Added.
5:12 PM Changeset in webkit [258531] by keith_miller@apple.com
  • 13 edits
    1 add in trunk

JavaScript identifier grammar supports unescaped astral symbols, but JSC doesn’t
https://bugs.webkit.org/show_bug.cgi?id=208998

Reviewed by Michael Saboff.

JSTests:

  • stress/unicode-identifiers-with-surrogate-pairs.js: Added.

(let.c.of.chars.eval.foo):
(throwsSyntaxError):
(let.c.of.continueChars.throwsSyntaxError.foo):

Source/JavaScriptCore:

This patch fixes a bug in the parser that allows for surrogate pairs when parsing identifiers.
It also makes a few other changes to the parser:

1) When looking for keywords we just need to check that subsequent
character cannot be a identifier part or an escape start.

2) The only time we call parseIdentifierSlowCase is when we hit an
escape start or a surrogate pair so we can optimize that to just
copy everything up slow character into our buffer.

3) We shouldn't allow for asking if a UChar is an identifier start/part.

  • KeywordLookupGenerator.py:

(Trie.printSubTreeAsC):
(Trie.printAsC):

  • parser/Lexer.cpp:

(JSC::isNonLatin1IdentStart):
(JSC::isIdentStart):
(JSC::isSingleCharacterIdentStart):
(JSC::cannotBeIdentStart):
(JSC::isIdentPart):
(JSC::isSingleCharacterIdentPart):
(JSC::cannotBeIdentPartOrEscapeStart):
(JSC::Lexer<LChar>::currentCodePoint const):
(JSC::Lexer<UChar>::currentCodePoint const):
(JSC::Lexer<LChar>::parseIdentifier):
(JSC::Lexer<UChar>::parseIdentifier):
(JSC::Lexer<CharacterType>::parseIdentifierSlowCase):
(JSC::Lexer<T>::lexWithoutClearingLineTerminator):
(JSC::Lexer<T>::scanRegExp):
(JSC::isIdentPartIncludingEscapeTemplate): Deleted.
(JSC::isIdentPartIncludingEscape): Deleted.

  • parser/Lexer.h:

(JSC::Lexer::setOffsetFromSourcePtr): Deleted.

  • parser/Parser.cpp:

(JSC::Parser<LexerType>::printUnexpectedTokenText):

  • parser/ParserTokens.h:

Source/WTF:

  • wtf/text/WTFString.cpp:

(WTF::String::fromCodePoint):

  • wtf/text/WTFString.h:

LayoutTests:

Fix broken test that asserted a non-ID_START codepoint was a start codepoint and
an ID_START codepoint was not a valid codepoint...

  • js/script-tests/unicode-escape-sequences.js:
  • js/unicode-escape-sequences-expected.txt:
5:03 PM Changeset in webkit [258530] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Crash under WebCookieCache::clearForHost()
https://bugs.webkit.org/show_bug.cgi?id=209149
<rdar://problem/60453086>

Reviewed by Darin Adler.

Alternative fix for Bug 209149 based on comments from Darin.

  • WebProcess/WebPage/WebCookieCache.cpp:

(WebKit::WebCookieCache::clearForHost):
(WebKit::WebCookieCache::pruneCacheIfNecessary):

4:56 PM Changeset in webkit [258529] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKit

Fix the macCatalyst build after r258525

  • WebProcess/WebPage/Cocoa/TextCheckingControllerProxy.mm:

(WebKit::TextCheckingControllerProxy::annotatedSubstringBetweenPositions):

4:34 PM Changeset in webkit [258528] by Simon Fraser
  • 6 edits in trunk/Source/WebCore

Update touch event regions once per frame
https://bugs.webkit.org/show_bug.cgi?id=209153

Reviewed by Zalan Bujtas.

Call document->updateTouchEventRegions() once at the end of Page::updateRendering() instead
of relying on a timer.

Also rename the functions called from Internal to make it clear they are testing-only.

Page::scrollingStateTreeAsText() needs to eagerly update event regions because they are input
to the scrolling tree.

  • dom/Document.cpp:

(WebCore::Document::Document):

  • page/Page.cpp:

(WebCore::Page::scrollingStateTreeAsText):
(WebCore::Page::touchEventRectsForEventForTesting):
(WebCore::Page::passiveTouchEventListenerRectsForTesting):
(WebCore::Page::doAfterUpdateRendering):
(WebCore::Page::touchEventRectsForEvent): Deleted.
(WebCore::Page::passiveTouchEventListenerRects): Deleted.

  • page/Page.h:
  • page/scrolling/ScrollingCoordinator.cpp:

(WebCore::ScrollingCoordinator::absoluteEventTrackingRegionsForFrame const):

  • testing/Internals.cpp:

(WebCore::Internals::touchEventRectsForEvent):
(WebCore::Internals::passiveTouchEventListenerRects):

4:16 PM Changeset in webkit [258527] by Justin Michaud
  • 2 edits in trunk/Tools

Add personal email to Tools/Scripts/webkitpy/common/config/contributors.json
https://bugs.webkit.org/show_bug.cgi?id=209151

Reviewed by Yusuke Suzuki.

  • Scripts/webkitpy/common/config/contributors.json:
4:12 PM Changeset in webkit [258526] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

[ Mac wk1 ] http/tests/security/clipboard/copy-paste-html-cross-origin-iframe-across-origin.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=209154

Unreviewed test gardening.

  • platform/mac-wk1/TestExpectations:
4:02 PM Changeset in webkit [258525] by Darin Adler
  • 45 edits
    1 delete in trunk/Source

Move most of TextIterator off of live ranges
https://bugs.webkit.org/show_bug.cgi?id=209129

Reviewed by Antti Koivisto.

Source/WebCore:

  • Change almost all arguments and return values of functions in TextIterator.h to use SimpleRange instead of live ranges. Exceptions are an overload of plainText TextIterator::rangeLength, TextIterator::rangeFromLocationAndLength, TextIterator::getLocationAndLengthFromRange, and TextIterator::subrange. Those five are a little trickier to convert, so I will do them each in separate patches.
  • Go with the flow in adding an include of Node.h to BoundaryPoint.h. I had avoided this in the initial version, but now it seems practical to just leave it that way. This led to removing BoundaryPoint.cpp and moving all functions to the header.
  • Converted many member functions of the Position class from using int to unsigned for offsets. The DOM specifies unsigned for offsets, but for some reason we used int for them a lot historically, even though negative numbers don't make sense. New classes like StaticRange, SimpleRange, and BoundaryPoint are already using unsigned exclusively and we'll eventually convert everything.
  • Remove includes of SimpleRange.h from files that also include TextIterator.h, now that TextIterator.h pulls it in.
  • Sources.txt: Removed BoundaryPoint.cpp.
  • WebCore.xcodeproj/project.pbxproj: Ditto.
  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::traverseToOffsetInRange): Updated to pass a reference
to a range rather than a pointer, after null-checking it.
(WebCore::AXObjectCache::lengthForRange): Ditto.
(WebCore::AXObjectCache::nextBoundary): Ditto.
(WebCore::AXObjectCache::previousBoundary): Ditto.

  • accessibility/AccessibilityObject.cpp:

(WebCore::AccessibilityObject::stringForRange const): Ditto.
(WebCore::AccessibilityObject::stringForVisiblePositionRange): Ditto.
(WebCore::AccessibilityObject::lengthForVisiblePositionRange const): Ditto.

  • accessibility/AccessibilityObjectInterface.h: Removed an extra include.
  • accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:

(-[WebAccessibilityObjectWrapper arrayOfTextForTextMarkers:attributed:]):
Updated to pass a reference to a range rather than a pointer, after null-checking it.

  • accessibility/mac/WebAccessibilityObjectWrapperMac.mm:

(-[WebAccessibilityObjectWrapper doAXAttributedStringForTextMarkerRange:spellCheck:]): Ditto.

  • dom/BoundaryPoint.cpp: Removed.
  • dom/BoundaryPoint.h: Removed redundant includes and forward declarations

since we're now committing to including "Node.h" here. Moved functions
all out of the .cpp file and made them inlines.

  • dom/DocumentMarkerController.cpp:

(WebCore::DocumentMarkerController::collectTextRanges): Pass a reference to
a range instead of a pointer.

  • dom/Position.cpp:

(WebCore::Position::Position): Take unsigned.
(WebCore::Position::moveToPosition): Ditto.
(WebCore::Position::moveToOffset): Ditto.
(WebCore::Position::parentAnchoredEquivalent const): Cast to unsigned.
(WebCore::Position::anchorTypeForLegacyEditingPosition): Take unsigned.
(WebCore::Position::previous const): Use unsigned.
(WebCore::Position::next const): Ditto.
(WebCore::Position::uncheckedPreviousOffset): Take unsigned.
(WebCore::Position::uncheckedPreviousOffsetForBackwardDeletion): Ditto.
(WebCore::Position::uncheckedNextOffset): Ditto.
(WebCore::Position::atLastEditingPositionForNode const): Cast to unsigned.
(WebCore::Position::atEndOfTree const): Ditto.
(WebCore::Position::rendersInDifferentPosition const): Added casts to
unsigned and also removed unneeded redundant checks. In a place where
we had already checked that both nodes were the same and both offsets
were different, we were checking the types of both nodes (but they are
the same so only need to check one) and we were checking that both
offsets were different (but we already knew they were different).
(WebCore::searchAheadForBetterMatch): Use unsigned.
(WebCore::Position::getInlineBoxAndOffset const): Ditto.
(WebCore::Position::equals const): Removed a cast to int.
(WebCore::makeBoundaryPoint): Moved this function here so now it can be
used in more places.

  • dom/Position.h: Changed many argument types to unsigned. Moved declarations

of all the functions up above all the inline implementations of the functions
to separate interface from implementation a bit better. Wrote a FIXME about
the name createLegacyEditingPosition. Moved makeBoundaryPoint here and exported
it from WebCore so we can use it from more places.

  • dom/Range.cpp:

(WebCore::createLiveRange): Moved these functions here from SimpleRange.cpp
because a live range is more advanced concept, so makes more sense for live
range to know about simple range rather than vice versa.

  • dom/Range.h: Removed some unneeded includes and forward declarations.

Added a FIXME about renaming to LiveRange. Moved the createLiveRange
functions here. Moved declarations of functions above inline function bodies.

  • dom/SimpleRange.cpp:

(WebCore::createLiveRange): Moved to Range.cpp.

  • dom/SimpleRange.h: Exported the constructor. Removed unneeded overload

that takes a Range*.

  • editing/ApplyStyleCommand.cpp:

(WebCore::ApplyStyleCommand::mergeStartWithPreviousIfIdentical):
Refactored code a bit and use unsigned.
(WebCore::ApplyStyleCommand::mergeEndWithNextIfIdentical): Use unsigned.

  • editing/Editing.cpp:

(WebCore::visibleImageElementsInRangeWithNonLoadedImages): Use a reference
to a range rather than a pointer.

  • editing/Editing.h: Added a forward declaration of Range that now seems to

be needed to compile.

  • editing/Editor.cpp:

(WebCore::Editor::selectedText const): Call makeBoundaryPoint twice here to
convert two Position objects into a SimpleRange.

  • editing/HTMLInterchange.cpp: Removed some extra includes.

(WebCore::convertHTMLTextToInterchangeFormat): Use variadic
StringBuilder::append.

  • editing/TextIterator.cpp:

(WebCore::firstNode): Added. We use this instead of Range::firstNode.
If we find we need it outside TextIterator we can find a header for it.
Not sure it would be great to add it to in BoundaryPoint.h, nor is it
obviously better as a BoundaryPoint member function.
(WebCore::TextIterator::TextIterator): Cut down on the extra constructors
and have the single remaining one take a SimpleRange.
(WebCore::SimplifiedBackwardsTextIterator::SimplifiedBackwardsTextIterator):
Ditto. Also change some int to unsigned.
(WebCore::CharacterIterator::CharacterIterator): Ditto.
(WebCore::BackwardsCharacterIterator::BackwardsCharacterIterator): Ditto.
(WebCore::WordAwareIterator::WordAwareIterator): Ditto.
(WebCore::TextIterator::rangeLength): Since this is one of the functions
that still takes a live range pointer, updated it to check for null and
pass a reference rather than a pointer.
(WebCore::TextIterator::rangeFromLocationAndLength): Ditto.
(WebCore::hasAnyPlainText): Removed now-unneeded call to createLiveRange.
(WebCore::plainText): Updated the main implementation to take a SimpleRange,
eliminating the version that takes two Position objects, but keeping the
one that takes a live range pointer for now.
(WebCore::plainTextReplacingNoBreakSpace): Removed all but the one, and
have that one take a SimpleRange.

  • editing/TextIterator.h: Removed the include of SimpleRange.h. Also

Updated for the changes above, eliminating five different constructors
that take a live range and also overloads that take two Position objects.

  • editing/TextManipulationController.cpp:

(WebCore::ParagraphContentIterator::ParagraphContentIterator):
Call makeBoundaryPoint twice here to convert two Position objects into
a SimpleRange.

  • editing/VisibleSelection.cpp: Removed an include.
  • editing/VisibleUnits.cpp:

(WebCore::suffixLengthForRange): Pass a reference to a range known to
not be null.
(WebCore::previousBoundary): Ditto.
(WebCore::nextBoundary): Ditto.

  • editing/cocoa/DataDetection.mm:

(WebCore::buildQuery): Take a SimpleRange.
(WebCore::DataDetection::detectContentInRange): Added a null check on
a live range and pass a reference to it.

  • editing/cocoa/DictionaryLookup.mm:

(WebCOre::DictionaryLookup::rangeAtHitTestResult): Ditto.

  • editing/cocoa/HTMLConverter.mm:

(WebCore::editingAttributedStringFromRange): Pass a reference to a range
known to not be null.

  • page/TextIndicator.cpp:

(WebCore::estimatedTextColorsForRange): Ditto.
(WebCore::containsOnlyWhiteSpaceText): Ditto.

  • page/ios/FrameIOS.mm:

(WebCore::Frame::interpretationsForCurrentRoot const): Ditto.

  • rendering/HitTestResult.cpp:

(WebCore::HitTestResult::selectedText const): Added a null check on
a live range and pass a reference to it.

Source/WebKit:

  • WebProcess/InjectedBundle/API/mac/WKDOMTextIterator.mm:

(-[WKDOMTextIterator initWithRange:]): Leave _textIterator as a nullptr
if the passed-in range is nil since we no longer offer a way to create
an empty TextIterator; other clients don't seem to need one.
(-[WKDOMTextIterator advance]): Add a null check.
(-[WKDOMTextIterator atEnd]): Ditto.
(-[WKDOMTextIterator currentRange]): Ditto.
(-[WKDOMTextIterator currentTextPointer]): Ditto.
(-[WKDOMTextIterator currentTextLength]): Ditto.

  • WebProcess/WebPage/Cocoa/TextCheckingControllerProxy.mm: Removed include.
  • WebProcess/WebPage/ViewGestureGeometryCollector.cpp:

(WebKit::ViewGestureGeometryCollector::computeTextLegibilityScales): Pass
a reference to a range known not to be null.

  • WebProcess/WebPage/WebPage.cpp: Removed an include.
  • WebProcess/WebPage/ios/WebPageIOS.mm: Removed a "using naemsapce WebCore".

Added two local functions
(WebKit::plainTextForContext): Added. Helper for just this file where calling
plainTextReplacingNoBreakSpace on a possibly null Range is common.
(WebKit::plainTextForDisplay): Ditto. This one passes true for isDisplayString.
Not entirely clear how carefully we chose which of the two to call, or if there
is sufficient test coverage.
(WebKit::WebPage::platformEditorState const): Use plainTextForContext
and plainTextForDisplay.
(WebKit::WebPage::getSelectionContext): Ditto.
(WebKit::WebPage::getRectsAtSelectionOffsetWithText): Use plainTextForDisplay.
(WebKit::WebPage::requestDictationContext): Use plainTextForContext.
(WebKit::WebPage::replaceSelectedText): Ditto.
(WebKit::WebPage::replaceDictatedText): Ditto.
(WebKit::WebPage::requestAutocorrectionData): Ditto.
(WebKit::WebPage::applyAutocorrectionInternal): Ditto.
(WebKit::WebPage::autocorrectionContext): Ditto.
(WebKit::dataDetectorLinkPositionInformation): Use plainTextForDisplay.
(WebKit::WebPage::requestDocumentEditingContext): Use RetainPtr instead of
autorelease. Use makeBoundaryPoint to convert Position objects to SimpleRange.

Source/WebKitLegacy/mac:

  • WebView/WebFrame.mm: Removed an include.
  • WebView/WebHTMLView.mm:

(-[WebHTMLView _legacyAttributedStringFrom:offset:to:offset:]):
Add casts to unsigned.

  • WebView/WebTextIterator.mm:

(-[WebTextIterator initWithRange:]): Leave _private->_textIterator
as a nullptr if the passed-in range is nil since we no longer offer
a way to create an empty TextIterator; other clients don't seem to
need one.
(-[WebTextIterator advance]): Check _private->_textIterator for null.
(-[WebTextIterator atEnd]): Ditto.
(-[WebTextIterator currentRange]): Ditto.
(-[WebTextIterator currentTextPointer]): Ditto.
(-[WebTextIterator currentTextLength]): Ditto.
(-[WebTextIterator currentNode]): Ditto.
(-[WebTextIterator currentText]): Ditto.

3:49 PM Changeset in webkit [258524] by Russell Epstein
  • 1 delete in branches/safari-610.1.7.3-branch

Delete branch.

3:41 PM Changeset in webkit [258523] by Russell Epstein
  • 1 copy in branches/safari-610.1.7.3-branch

New branch.

3:10 PM Changeset in webkit [258522] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

Crash in CSSValue::isPrimitiveValue
https://bugs.webkit.org/show_bug.cgi?id=208309

Patch by Pinki Gyanchandani <pgyanchandani@apple.com> on 2020-03-16
Reviewed by Ryosuke Niwa.

Source/WebCore:

Added a NULL check before dereferencing value in ApplyStyleCommand::computedFontSize

Test: editing/execCommand/primitive-value.html

  • editing/ApplyStyleCommand.cpp:

(WebCore::ApplyStyleCommand::computedFontSize):

LayoutTests:

Added a testcase attached to bugzilla issue 208309, with little modification.

  • editing/execCommand/primitive-value-expected.txt: Added.
  • editing/execCommand/primitive-value.html: Added.
3:04 PM Changeset in webkit [258521] by Chris Dumez
  • 4 edits in trunk

Crash under WebCookieCache::clearForHost()
https://bugs.webkit.org/show_bug.cgi?id=209149
<rdar://problem/60453086>

Reviewed by Alex Christensen.

Source/WebKit:

Make sure WebCookieCache::pruneCacheIfNecessary() keeps alive the host String it is passing
to WebCookieCache::clearForHost(). Previously, it was merely deferencing a HashSet iterator
and passing that to clearForHost(). However, clearForHost() would then drop the String from
the HashSet and the host would no longer be valid.

Change covered by new API test.

  • WebProcess/WebPage/WebCookieCache.cpp:

(WebKit::WebCookieCache::pruneCacheIfNecessary):

Tools:

Add API test coverage.

  • TestWebKitAPI/Tests/WebKitCocoa/CookiePrivateBrowsing.mm:

(TEST):

2:50 PM Changeset in webkit [258520] by Keith Rollin
  • 8 edits
    3 deletes in trunk

Remove support for WebKitSystemInterface
https://bugs.webkit.org/show_bug.cgi?id=208894
<rdar://problem/60297590>

Reviewed by Brent Fulgham.

This project provided support for facilities that are now handled
elsewhere and is no longer needed.

.:

  • .gitignore:
  • Source/PlatformWin.cmake:
  • Source/cmake/OptionsAppleWin.cmake:

Tools:

  • Scripts/copy-webkitlibraries-to-product-directory:

WebKitLibraries:

  • Makefile:
  • WebKitSystemInterface.h: Removed.
  • win/include/WebKitSystemInterface/WebKitSystemInterface.h: Removed.
  • win/lib32/WebKitSystemInterface.lib: Removed.
2:41 PM Changeset in webkit [258519] by timothy_horton@apple.com
  • 3 edits in trunk/Source/WebKitLegacy/mac

Always include System.framework in WebKitLegacy's CPLUSPLUSFLAGS
https://bugs.webkit.org/show_bug.cgi?id=209147

Reviewed by Darin Adler.

  • Configurations/Base.xcconfig:
  • Configurations/WebKitLegacy.xcconfig:

Bring WebKitLegacy's xcconfigs in line with all the other projects,
adding System.framework globally, and in Base.xcconfig.

2:11 PM Changeset in webkit [258518] by pvollan@apple.com
  • 8 edits in trunk

[macOS] Accessibility sandbox regressions
https://bugs.webkit.org/show_bug.cgi?id=209065
Source/WebCore/PAL:

Reviewed by Brent Fulgham.

Add Accessibility notification name.

  • pal/spi/cocoa/NSAccessibilitySPI.h:

Source/WebKit:

<rdar://problem/60202450>

Reviewed by Brent Fulgham.

When Accessibility is enabled, the WebContent process needs access to the preference service, since Accessibility
is relying on some advanced features of the service. Also, when CF prefs direct mode is enabled, the WebContent
sandbox needs to explicitly allow reading of the various plist files.

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::registerNotificationObservers):

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

Tools:

Reviewed by Brent Fulgham.

  • TestWebKitAPI/Tests/WebKit/EnableAccessibility.mm:

(TEST):

  • TestWebKitAPI/Tests/WebKit/GrantAccessToPreferencesService.mm:

(TEST):

1:54 PM Changeset in webkit [258517] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

[ Mac wk2 ] imported/w3c/web-platform-tests/mediacapture-streams/MediaStream tests are flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=209148

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
1:21 PM Changeset in webkit [258516] by Megan Gardner
  • 3 edits
    2 adds in trunk

Color Picker crashes on touch
https://bugs.webkit.org/show_bug.cgi?id=209086

Reviewed by Darin Adler.

Source/WebCore:

Vector sizing lost in refactor. Not perfomance sensitive code, so just expanding vector as needed.

Test: fast/forms/color/color-input-activate-crash.html

  • html/ColorInputType.cpp:

(WebCore::ColorInputType::suggestedColors const):

LayoutTests:

  • fast/forms/color/color-input-activate-crash-expected.txt: Added.
  • fast/forms/color/color-input-activate-crash.html: Added.
1:11 PM Changeset in webkit [258515] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[Cocoa] Crash under -[WKPreferenceObserver init]
https://bugs.webkit.org/show_bug.cgi?id=209145

Reviewed by Darin Adler.

Handle the case when calling [NSUserDefaults initWithSuiteName:] did not succeed.

No new tests, since I have not been able to reproduce.

  • UIProcess/Cocoa/PreferenceObserver.mm:

(-[WKPreferenceObserver init]):

12:57 PM Changeset in webkit [258514] by sihui_liu@apple.com
  • 3 edits in trunk/LayoutTests

IndexedDB hits assertion with crypto/workers/subtle/aes-indexeddb.html
https://bugs.webkit.org/show_bug.cgi?id=202648
<rdar://problem/56059602>

Unreviewed test gardening.

12:56 PM Changeset in webkit [258513] by Brent Fulgham
  • 5 edits in trunk/Source/WebKit

Remove unused IPC messages from DrawingAreaProxy
https://bugs.webkit.org/show_bug.cgi?id=209090
<rdar://problem/60333300>

Reviewed by Wenson Hsieh.

Do not compile the following three unused messages in DrawingAreaProxy when
building for a Cocoa platform target.

DrawingAreaProxy::Update
DrawingAreaProxy::DidUpdateBackingStoreState
DrawingAreaProxy::ExitAcceleratedCompositingMode

  • UIProcess/DrawingAreaProxy.h:

(WebKit::DrawingAreaProxy::enterAcceleratedCompositingMode):
(WebKit::DrawingAreaProxy::update):
(WebKit::DrawingAreaProxy::didUpdateBackingStoreState):
(WebKit::DrawingAreaProxy::exitAcceleratedCompositingMode):

  • UIProcess/DrawingAreaProxy.messages.in:
  • UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
  • UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:

(WebKit::TiledCoreAnimationDrawingAreaProxy::exitAcceleratedCompositingMode): Deleted.

12:50 PM Changeset in webkit [258512] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[Cocoa] Only set CF prefs direct mode for the WebContent process
https://bugs.webkit.org/show_bug.cgi?id=209091
<rdar://problem/60337842>

Reviewed by Brent Fulgham.

Currently, we enable CF prefs direct mode in XPCServiceMain. This is incorrect, it should only be enabled
for the WebContent process.

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

(WebKit::XPCServiceMain):

11:49 AM Changeset in webkit [258511] by Simon Fraser
  • 8 edits in trunk/Source

Remove FrameView::scheduleRenderingUpdate()
https://bugs.webkit.org/show_bug.cgi?id=209109

Reviewed by Antti Koivisto.

FrameView::scheduleRenderingUpdate() called through to compositor(), but that just
turned around to call scheduleRenderingUpdate() via Page. So Remove it and change
callers to call Page::scheduleRenderingUpdate() directly.

Source/WebCore:

  • page/FrameView.cpp:

(WebCore::FrameView::setViewExposedRect):
(WebCore::FrameView::scheduleRenderingUpdate): Deleted.

  • page/FrameView.h:
  • page/Page.cpp:

(WebCore::Page::scheduleRenderingUpdate):

  • page/Page.h:
  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::scheduleRenderingUpdate):

Source/WebKitLegacy/mac:

  • WebView/WebView.mm:
11:42 AM Changeset in webkit [258510] by Simon Fraser
  • 3 edits in trunk/Source/WebCore

Commit Xcode-modified xcfilelist.

New WebXR idl files.

  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
11:42 AM Changeset in webkit [258509] by Simon Fraser
  • 3 edits in trunk/Source/WebCore

Factor some post-updateRendering code into its own function
https://bugs.webkit.org/show_bug.cgi?id=209108

Reviewed by Antti Koivisto.

Make a new function to hold code that needs to do post update-rendering work.
It asserts that the layout is clean at the end.

  • page/Page.cpp:

(WebCore::Page::updateRendering):
(WebCore::Page::doAfterUpdateRendering):

  • page/Page.h:
10:34 AM Changeset in webkit [258508] by dbates@webkit.org
  • 27 edits
    2 adds in trunk
ASSERTION FAILURE: !result.innerNode()
(request.resultIsElementList() && result.listBasedTestResult().size()) in RenderLayer::hitTestContents()

https://bugs.webkit.org/show_bug.cgi?id=209112

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Update test result now that more sub-tests are passing.

  • web-platform-tests/shadow-dom/DocumentOrShadowRoot-prototype-elementFromPoint-expected.txt:

Source/WebCore:

Fix rect-based hit testing (e.g. used in the impl of document.elementsFromPoint()) of ::before
and ::after pseudo elements. Same issue as in r133330, updateHitTestResult() and addNodeToRectBasedTestResult()
are using different "hit" nodes. In particular, RenderObject::updateHitTestResult() knows how to
reason about ::before and ::after pseudo elements, but addNodeToRectBasedTestResult() cannot.
Standardize the concept of the node used for hit testing from something-specifically added to RenderBlock
in r133330 to all renderers. Have both updateHitTestResult() and addNodeToRectBasedTestResult()
make use of this concept so that they consider the same hit node.

Test: fast/dom/nodesFromRect/pseudo-empty-svg-image-crash.html

  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::LineLayout::hitTest):

  • rendering/EllipsisBox.cpp:

(WebCore::EllipsisBox::nodeAtPoint):

  • rendering/InlineFlowBox.cpp:

(WebCore::InlineFlowBox::nodeAtPoint):

  • rendering/InlineTextBox.cpp:

(WebCore::InlineTextBox::nodeAtPoint):
Update code to call nodeForHitTest() to keep the code behavior we have today. Note that RenderElement::element()
and RenderText::textNode() just cast the return value of RenderObject::node().

  • rendering/RenderBlock.cpp:

(WebCore::RenderBlock::nodeForHitTest const): Remove special case for RenderView now that I added RenderView::nodeForHitTest().
Moreover, this special case was returning the document even though RenderView::updateHitTestResult() hit
test the document element. See remarks for RenderView::nodeForHitTest() for more details.

  • rendering/RenderBlock.h:
  • rendering/RenderBox.cpp:

(WebCore::RenderBox::nodeAtPoint): Use nodeForHitTest(). This fixes the bug. Currently, updateHitTestResult()
knows that when RenderObject::node() is nullptr and the parent renderer is for generated content that it can
walk up the hierarchy to find the hit PseudoElement. But in the call to addNodeToListBasedTestResult(), RenderObject::element()
was passed, which is nullptr for an anonymous node, and addNodeToListBasedTestResult() doesn't have enough info
to know that this means generated content was hit and hence it is not able to find the PseudoElement. This
disagreement caused the assertion failure because updateHitTestResult() would update the inner node, but
addNodeToListBasedTestResult() would not add a node to the set.

  • rendering/RenderInline.cpp:

(WebCore::RenderInline::hitTestCulledInline): Use nodeForHitTest().
(WebCore::RenderInline::updateHitTestResult): Update code as needed to use nodeForHitTest(). Also while I
am here fix up code style of comment and rename the local from element to node to match the return value
of nodeForHitTest().

  • rendering/RenderMultiColumnSet.cpp:

(WebCore::RenderMultiColumnSet::nodeForHitTest const): Added.
(WebCore::RenderMultiColumnSet::updateHitTestResult): Update code as needed to use nodeForHitTest().

  • rendering/RenderMultiColumnSet.h:
  • rendering/RenderObject.cpp:

(WebCore::RenderObject::nodeForHitTest const): Added.
(WebCore::RenderObject::updateHitTestResult): Update code as needed to use nodeForHitTest().

  • rendering/RenderObject.h:
  • rendering/RenderTable.cpp:

(WebCore::RenderTable::nodeAtPoint): Ditto.

  • rendering/RenderView.cpp:

(WebCore::RenderView::nodeForHitTest const): Added. This overrides RenderBlock::nodeForHitTest(), which
following r155370 was returning the document as the hit test node even though RenderView::updateHitTestResult()
considered the document element as the hit node for a RenderView. As a result of this change, the rect-based
hit testing no longer returns the document (seen in test results as #document) in the list of nodes.
(WebCore::RenderView::updateHitTestResult): Update code as needed to use nodeForHitTest().

  • rendering/RenderView.h:
  • rendering/SimpleLineLayoutFunctions.cpp:

(WebCore::SimpleLineLayout::hitTestFlow): Ditto.

  • rendering/svg/RenderSVGContainer.cpp:

(WebCore::RenderSVGContainer::nodeAtFloatPoint): Ditto.

  • rendering/svg/RenderSVGImage.cpp:

(WebCore::RenderSVGImage::nodeAtFloatPoint): Ditto.

  • rendering/svg/RenderSVGRoot.cpp:

(WebCore::RenderSVGRoot::nodeAtPoint): Ditto.

  • rendering/svg/RenderSVGShape.cpp:

(WebCore::RenderSVGShape::nodeAtFloatPoint): Ditto.

  • rendering/svg/SVGInlineTextBox.cpp:

(WebCore::SVGInlineTextBox::nodeAtPoint): Ditto.

LayoutTests:

Add a new test for an pseudo element.

Also update tests now that I added the RenderView::nodeForHitTest(), which returns the
same hit test node (the document element) as used in RenderView::updateHitTestResult().
Currently RenderView::nodeForHitTest() would actually fall back to RenderBlock::nodeForHitTest(),
which returned the document (seen in the test resutls as #document).

  • fast/dom/nodesFromRect/nodesFromRect-child-frame-content.html: Update test to match new results.
  • fast/dom/nodesFromRect/nodesFromRect-embedded-frame-content.html: Ditto.
  • fast/dom/nodesFromRect/pseudo-empty-svg-image-crash-expected.txt: Added.
  • fast/dom/nodesFromRect/pseudo-empty-svg-image-crash.html: Added.
10:24 AM Changeset in webkit [258507] by ddkilzer@apple.com
  • 3 edits in trunk/Source/WebKit

WebPage::GetDataSelectionForPasteboard should validate its size variable
<https://webkit.org/b/209092>
<rdar://problem/60181345>

Reviewed by Brent Fulgham.

  • Platform/IPC/Connection.h:

(MESSAGE_CHECK_WITH_RETURN_VALUE_BASE): Add.

  • Variant of MESSAGE_CHECK_BASE() that takes a return value.
  • UIProcess/mac/WebPageProxyMac.mm:

(MESSAGE_CHECK_WITH_RETURN_VALUE): Add.
(WebKit::WebPageProxy::dataSelectionForPasteboard):

  • Use new MESSAGE_CHECK_WITH_RETURN_VALUE() macro to update check for handle.isNull() and to add check for size variable.
  • Add static_cast<size_t>() to size variable to denote type change.
9:51 AM Changeset in webkit [258506] by youenn@apple.com
  • 3 edits in trunk/Source/WebCore

Make CoreAudioCaptureSourceFactoryIOS an AudioSession::InterruptionObserver
https://bugs.webkit.org/show_bug.cgi?id=209138

Reviewed by Eric Carlson.

Instead of listening to Audiosession interruptions, CoreAudioCaptureSourceFactoryIOS is now relying on AudioSession directly.
This allows removing some duplicate code.
No change of behavior.

  • platform/mediastream/ios/CoreAudioCaptureSourceIOS.h:
  • platform/mediastream/ios/CoreAudioCaptureSourceIOS.mm:

(-[WebCoreAudioCaptureSourceIOSListener initWithCallback:]):
(WebCore::CoreAudioCaptureSourceFactoryIOS::CoreAudioCaptureSourceFactoryIOS):
(WebCore::CoreAudioCaptureSourceFactoryIOS::~CoreAudioCaptureSourceFactoryIOS):
(-[WebCoreAudioCaptureSourceIOSListener handleInterruption:]): Deleted.

9:44 AM Changeset in webkit [258505] by Ryan Haddad
  • 2 edits in trunk/Tools

Unreviewed infrastructure fix.

  • BuildSlaveSupport/ews-build/config.json: Temporarily remove ews114

while the hardware is out for repair.

9:41 AM Changeset in webkit [258504] by youenn@apple.com
  • 14 edits
    2 adds in trunk

Apply rotation at source level if WebRTC sink ask so
https://bugs.webkit.org/show_bug.cgi?id=205645

Reviewed by Eric Carlson.

Source/WebCore:

Add a virtual method to RealtimeMediaSource to pass the information that the sink prefers the frames to be rotated before sending them.

Source/WebKit:

Implement RealtimeMediaSource setShouldApplyRotation by sending IPC to capture process.
In capture process, if rotation should be applied, use an ImageRotationSessionVT session to apply it before sending the video frame.
This allows WebProcess to no longer need an ImageRotationSessionVT for WebRTC.

  • UIProcess/Cocoa/UserMediaCaptureManagerProxy.cpp:

(WebKit::UserMediaCaptureManagerProxy::SourceProxy::setShouldApplyRotation):
(WebKit::UserMediaCaptureManagerProxy::SourceProxy::rotatePixelBuffer):
(WebKit::UserMediaCaptureManagerProxy::setShouldApplyRotation):

  • UIProcess/Cocoa/UserMediaCaptureManagerProxy.h:
  • UIProcess/Cocoa/UserMediaCaptureManagerProxy.messages.in:
  • WebProcess/cocoa/UserMediaCaptureManager.cpp:

(WebKit::UserMediaCaptureManager::Source::setShouldApplyRotation):

LayoutTests:

  • webrtc/video-rotation-no-cvo-expected.txt: Added.
  • webrtc/video-rotation-no-cvo.html: Added.
9:36 AM Changeset in webkit [258503] by youenn@apple.com
  • 4 edits
    2 adds in trunk

Audio is not played from an audio element when the srcObject object has unstarted video tracks
https://bugs.webkit.org/show_bug.cgi?id=207041
<rdar://problem/59084745>

Reviewed by Eric Carlson.

Source/WebCore:

In case MediaPlayer is an audio element, we should just make it as if there is no video track in the stream.

Test: imported/w3c/web-platform-tests/webrtc/audio-video-element-playing.html

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.h:
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:

(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::enqueueVideoSample):
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::ensureLayers):
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::activeVideoTrack const):
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::didPassCORSAccessCheck const):
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentDisplayMode const):
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::currentReadyState):
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::checkSelectedVideoTrack):
(WebCore::MediaPlayerPrivateMediaStreamAVFObjC::updateTracks):

LayoutTests:

  • webrtc/audio-video-element-playing-expected.txt: Added.
  • webrtc/audio-video-element-playing.html: Added.
9:34 AM Changeset in webkit [258502] by youenn@apple.com
  • 3 edits
    2 adds in trunk

RTCRtpSender of kind video should have a null dtmf attribute
https://bugs.webkit.org/show_bug.cgi?id=209135

Reviewed by Eric Carlson.

LayoutTests/imported/w3c:

  • web-platform-tests/webrtc/RTCRtpSender.https-expected.txt: Added.
  • web-platform-tests/webrtc/RTCRtpSender.https.html: Added.

Source/WebCore:

Test: imported/w3c/web-platform-tests/webrtc/RTCRtpSender.https.html

  • Modules/mediastream/RTCRtpSender.cpp:

(WebCore::RTCRtpSender::dtmf):

9:22 AM Changeset in webkit [258501] by Truitt Savell
  • 2 edits in trunk/LayoutTests

[ Mac wk2 ] (r258249) fast/scrolling/mac/absolute-in-overflow-scroll-dynamic.html is a flaky failure (209052)
https://bugs.webkit.org/show_bug.cgi?id=209052

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
9:14 AM Changeset in webkit [258500] by Jason_Lawrence
  • 2 edits in trunk/LayoutTests

[ iOS wk2 ] webgl/1.0.3/conformance/textures/copy-tex-image-2d-formats.html is failing.
https://bugs.webkit.org/show_bug.cgi?id=209139

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations:
9:09 AM Changeset in webkit [258499] by svillar@igalia.com
  • 4 edits
    113 adds in trunk/LayoutTests

[WebXR] Import wpt tests
https://bugs.webkit.org/show_bug.cgi?id=208989

Reviewed by Youenn Fablet.

LayoutTests/imported/w3c:

  • resources/import-expectations.json:
  • web-platform-tests/webxr/META.yml: Added.
  • web-platform-tests/webxr/ar-module/idlharness.https.window.html: Added.
  • web-platform-tests/webxr/ar-module/idlharness.https.window.js: Added.

(async idl_array):

  • web-platform-tests/webxr/ar-module/w3c-import.log: Added.
  • web-platform-tests/webxr/ar-module/xrDevice_isSessionSupported_immersive-ar.https.html: Added.
  • web-platform-tests/webxr/ar-module/xrDevice_requestSession_immersive-ar.https.html: Added.
  • web-platform-tests/webxr/ar-module/xrSession_environmentBlendMode.https.html: Added.
  • web-platform-tests/webxr/dom-overlay/ar_dom_overlay.https.html: Added.
  • web-platform-tests/webxr/dom-overlay/w3c-import.log: Added.
  • web-platform-tests/webxr/events_input_source_recreation.https.html: Added.
  • web-platform-tests/webxr/events_input_sources_change.https.html: Added.
  • web-platform-tests/webxr/events_referenceSpace_reset_immersive.https.html: Added.
  • web-platform-tests/webxr/events_referenceSpace_reset_inline.https.html: Added.
  • web-platform-tests/webxr/events_session_select.https.html: Added.
  • web-platform-tests/webxr/events_session_select_subframe.https.html: Added.
  • web-platform-tests/webxr/events_session_squeeze.https.html: Added.
  • web-platform-tests/webxr/exclusive_requestFrame_nolayer.https.html: Added.
  • web-platform-tests/webxr/gamepads-module/idlharness.https.window.html: Added.
  • web-platform-tests/webxr/gamepads-module/idlharness.https.window.js: Added.

(async idl_array):

  • web-platform-tests/webxr/gamepads-module/w3c-import.log: Added.
  • web-platform-tests/webxr/gamepads-module/xrInputSource_gamepad_disconnect.https.html: Added.
  • web-platform-tests/webxr/gamepads-module/xrInputSource_gamepad_input_registered.https.html: Added.
  • web-platform-tests/webxr/getInputPose_handedness.https.html: Added.
  • web-platform-tests/webxr/getInputPose_pointer.https.html: Added.
  • web-platform-tests/webxr/getViewerPose_emulatedPosition.https.html: Added.
  • web-platform-tests/webxr/hit-test/ar_hittest_subscription_refSpaces.https.html: Added.
  • web-platform-tests/webxr/hit-test/ar_hittest_subscription_states.https.html: Added.
  • web-platform-tests/webxr/hit-test/w3c-import.log: Added.
  • web-platform-tests/webxr/hit-test/xrRay_constructor.https.html: Added.
  • web-platform-tests/webxr/hit-test/xrRay_matrix.https.html: Added.
  • web-platform-tests/webxr/idlharness.https.window.html: Added.
  • web-platform-tests/webxr/idlharness.https.window.js: Added.

(async idl_array):

  • web-platform-tests/webxr/navigator_xr_sameObject.https.html: Added.
  • web-platform-tests/webxr/render_state_vertical_fov_immersive.https.html: Added.
  • web-platform-tests/webxr/render_state_vertical_fov_inline.https.html: Added.
  • web-platform-tests/webxr/resources/w3c-import.log: Added.
  • web-platform-tests/webxr/resources/webxr_check.html: Added.
  • web-platform-tests/webxr/resources/webxr_math_utils.js: Added.

(let.transform_point_by_matrix):
(let.normalize_quaternion):
(let.conjugate_quaternion):
(let.multiply_quaternions):
(let.normalize_perspective):
(let.transform_point_by_quaternion):

  • web-platform-tests/webxr/resources/webxr_test_asserts.js: Added.

(const.assert_point_approx_equals):
(const.assert_point_significantly_not_equals):
(const.assert_transform_approx_equals):
(const.assert_matrix_approx_equals):
(const.assert_matrix_significantly_not_equals):
(const.assert_ray_approx_equals):

  • web-platform-tests/webxr/resources/webxr_test_constants.js: Added.
  • web-platform-tests/webxr/resources/webxr_test_constants_fake_world.js: Added.

(createFakeWorld):

  • web-platform-tests/webxr/resources/webxr_util.js: Added.

(xr_promise_test):
(async let):
(async xr_session_promise_test):
(async promise_simulate_user_activation):

  • web-platform-tests/webxr/w3c-import.log: Added.
  • web-platform-tests/webxr/webGLCanvasContext_create_xrcompatible.https.html: Added.
  • web-platform-tests/webxr/webGLCanvasContext_makecompatible_contextlost.https.html: Added.
  • web-platform-tests/webxr/webxr-supported-by-feature-policy.html: Added.
  • web-platform-tests/webxr/webxr_availability.http.sub.html: Added.
  • web-platform-tests/webxr/webxr_feature_policy.https.html: Added.
  • web-platform-tests/webxr/webxr_feature_policy.https.html.headers: Added.
  • web-platform-tests/webxr/xrBoundedReferenceSpace_updates.https.html: Added.
  • web-platform-tests/webxr/xrDevice_disconnect_ends.https.html: Added.
  • web-platform-tests/webxr/xrDevice_isSessionSupported_immersive.https.html: Added.
  • web-platform-tests/webxr/xrDevice_isSessionSupported_immersive_unsupported.https.html: Added.
  • web-platform-tests/webxr/xrDevice_isSessionSupported_inline.https.html: Added.
  • web-platform-tests/webxr/xrDevice_requestSession_immersive.https.html: Added.
  • web-platform-tests/webxr/xrDevice_requestSession_immersive_no_gesture.https.html: Added.
  • web-platform-tests/webxr/xrDevice_requestSession_immersive_unsupported.https.html: Added.
  • web-platform-tests/webxr/xrDevice_requestSession_no_mode.https.html: Added.
  • web-platform-tests/webxr/xrDevice_requestSession_non_immersive_no_gesture.https.html: Added.
  • web-platform-tests/webxr/xrDevice_requestSession_optionalFeatures.https.html: Added.
  • web-platform-tests/webxr/xrDevice_requestSession_requiredFeatures_unknown.https.html: Added.
  • web-platform-tests/webxr/xrFrame_getPose.https.html: Added.
  • web-platform-tests/webxr/xrFrame_getViewerPose_getPose.https.html: Added.
  • web-platform-tests/webxr/xrFrame_lifetime.https.html: Added.
  • web-platform-tests/webxr/xrFrame_session_sameObject.https.html: Added.
  • web-platform-tests/webxr/xrInputSource_add_remove.https.html: Added.
  • web-platform-tests/webxr/xrInputSource_emulatedPosition.https.html: Added.
  • web-platform-tests/webxr/xrInputSource_profiles.https.html: Added.
  • web-platform-tests/webxr/xrInputSource_sameObject.https.html: Added.
  • web-platform-tests/webxr/xrPose_transform_sameObject.https.html: Added.
  • web-platform-tests/webxr/xrReferenceSpace_originOffset.https.html: Added.
  • web-platform-tests/webxr/xrReferenceSpace_originOffsetBounded.https.html: Added.
  • web-platform-tests/webxr/xrReferenceSpace_originOffset_viewer.https.html: Added.
  • web-platform-tests/webxr/xrRigidTransform_constructor.https.html: Added.
  • web-platform-tests/webxr/xrRigidTransform_inverse.https.html: Added.
  • web-platform-tests/webxr/xrRigidTransform_matrix.https.html: Added.
  • web-platform-tests/webxr/xrRigidTransform_sameObject.https.html: Added.
  • web-platform-tests/webxr/xrSession_cancelAnimationFrame.https.html: Added.
  • web-platform-tests/webxr/xrSession_cancelAnimationFrame_invalidhandle.https.html: Added.
  • web-platform-tests/webxr/xrSession_end.https.html: Added.
  • web-platform-tests/webxr/xrSession_features_deviceSupport.https.html: Added.
  • web-platform-tests/webxr/xrSession_input_events_end.https.html: Added.
  • web-platform-tests/webxr/xrSession_prevent_multiple_exclusive.https.html: Added.
  • web-platform-tests/webxr/xrSession_requestAnimationFrame_callback_calls.https.html: Added.
  • web-platform-tests/webxr/xrSession_requestAnimationFrame_data_valid.https.html: Added.
  • web-platform-tests/webxr/xrSession_requestAnimationFrame_getViewerPose.https.html: Added.
  • web-platform-tests/webxr/xrSession_requestAnimationFrame_timestamp.https.html: Added.
  • web-platform-tests/webxr/xrSession_requestReferenceSpace.https.html: Added.
  • web-platform-tests/webxr/xrSession_requestReferenceSpace_features.https.html: Added.
  • web-platform-tests/webxr/xrSession_sameObject.https.html: Added.
  • web-platform-tests/webxr/xrSession_viewer_availability.https.html: Added.
  • web-platform-tests/webxr/xrSession_viewer_referenceSpace.https.html: Added.
  • web-platform-tests/webxr/xrSession_visibilityState.https.html: Added.
  • web-platform-tests/webxr/xrStationaryReferenceSpace_floorlevel_updates.https.html: Added.
  • web-platform-tests/webxr/xrView_eyes.https.html: Added.
  • web-platform-tests/webxr/xrView_match.https.html: Added.
  • web-platform-tests/webxr/xrView_oneframeupdate.https.html: Added.
  • web-platform-tests/webxr/xrView_sameObject.https.html: Added.
  • web-platform-tests/webxr/xrViewerPose_views_sameObject.https.html: Added.
  • web-platform-tests/webxr/xrViewport_valid.https.html: Added.
  • web-platform-tests/webxr/xrWebGLLayer_constructor.https.html: Added.
  • web-platform-tests/webxr/xrWebGLLayer_framebuffer_draw.https.html: Added.
  • web-platform-tests/webxr/xrWebGLLayer_framebuffer_sameObject.https.html: Added.
  • web-platform-tests/webxr/xrWebGLLayer_framebuffer_scale.https.html: Added.
  • web-platform-tests/webxr/xrWebGLLayer_opaque_framebuffer.https.html: Added.
  • web-platform-tests/webxr/xrWebGLLayer_opaque_framebuffer_stencil.https.html: Added.
  • web-platform-tests/webxr/xrWebGLLayer_viewports.https.html: Added.

LayoutTests:

8:49 AM Changeset in webkit [258498] by svillar@igalia.com
  • 35 edits
    89 adds in trunk

[WebXR] IDLs, stubs and build configuration for WPE
https://bugs.webkit.org/show_bug.cgi?id=208702

Reviewed by Dean Jackson.

.:

Added a new compile flag for WEBXR which depends on WEBGL.

For the WPE port, added OpenXR detection and USE_OPENXR define to be
used in the sources. It also adds a dependency between USE_OPENXR and
ENABLE_WEBXR.

Largely based on previous work by Žan Doberšek.

  • Source/cmake/FindOpenXR.cmake: Added.
  • Source/cmake/OptionsWPE.cmake: Added mandatory OpenXR dependency if

WEBXR is enabled exposing USE_OPENXR to the build.

  • Source/cmake/WebKitFeatures.cmake: Added ENABLE_WEBXR.
  • Source/cmake/tools/vsprops/FeatureDefines.props: Ditto.
  • Source/cmake/tools/vsprops/FeatureDefinesCairo.props: Ditto.

Source/JavaScriptCore:

  • Configurations/FeatureDefines.xcconfig: Added ENABLE_WEBXR, off by default.

Source/WebCore:

Added the IDLs defined by the spec with very basic empty implementations to get them
built. Apart from that a very basic implementation of the required platform code using
OpenXR API was also added.

No new tests as no new functionality was really added (empty implementations). However
follow up patches will import the already available WPT tests for WebXR.

Largely based on previous work by Žan Doberšek.

  • CMakeLists.txt:
  • Configurations/FeatureDefines.xcconfig: Added ENABLE_WEBXR off by default.
  • DerivedSources.make:
  • Modules/webxr/NavigatorWebXR.cpp: Added.

(WebCore::NavigatorWebXR::xr):
(WebCore::NavigatorWebXR::from):

  • Modules/webxr/NavigatorWebXR.h: Added.
  • Modules/webxr/NavigatorWebXR.idl: Added.
  • Modules/webxr/WebXRBoundedReferenceSpace.cpp: Added.

(WebCore::WebXRBoundedReferenceSpace::boundsGeometry const):

  • Modules/webxr/WebXRBoundedReferenceSpace.h: Added.
  • Modules/webxr/WebXRBoundedReferenceSpace.idl: Added.
  • Modules/webxr/WebXRFrame.cpp: Added.

(WebCore::WebXRFrame::create):
(WebCore::WebXRFrame::WebXRFrame):
(WebCore::WebXRFrame::session const):
(WebCore::WebXRFrame::getViewerPose):
(WebCore::WebXRFrame::getPose):

  • Modules/webxr/WebXRFrame.h: Added.
  • Modules/webxr/WebXRFrame.idl: Added.
  • Modules/webxr/WebXRInputSource.cpp: Added.

(WebCore::WebXRInputSource::create):
(WebCore::WebXRInputSource::WebXRInputSource):
(WebCore::WebXRInputSource::handedness const):
(WebCore::WebXRInputSource::targetRayMode const):
(WebCore::WebXRInputSource::targetRaySpace const):
(WebCore::WebXRInputSource::gripSpace const):
(WebCore::WebXRInputSource::profiles const):

  • Modules/webxr/WebXRInputSource.h: Added.
  • Modules/webxr/WebXRInputSource.idl: Added.
  • Modules/webxr/WebXRInputSourceArray.cpp: Added.

(WebCore::WebXRInputSourceArray::length const):
(WebCore::WebXRInputSourceArray::item const):

  • Modules/webxr/WebXRInputSourceArray.h: Added.
  • Modules/webxr/WebXRInputSourceArray.idl: Added.
  • Modules/webxr/WebXRPose.cpp: Added.

(WebCore::WebXRPose::create):
(WebCore::WebXRPose::WebXRPose):
(WebCore::WebXRPose::transform const):
(WebCore::WebXRPose::emulatedPosition const):

  • Modules/webxr/WebXRPose.h: Added.
  • Modules/webxr/WebXRPose.idl: Added.
  • Modules/webxr/WebXRReferenceSpace.cpp: Added.

(WebCore::WebXRReferenceSpace::WebXRReferenceSpace):
(WebCore::WebXRReferenceSpace::getOffsetReferenceSpace):

  • Modules/webxr/WebXRReferenceSpace.h: Added.
  • Modules/webxr/WebXRReferenceSpace.idl: Added.
  • Modules/webxr/WebXRRenderState.cpp: Added.

(WebCore::WebXRRenderState::create):
(WebCore::WebXRRenderState::WebXRRenderState):
(WebCore::WebXRRenderState::depthNear const):
(WebCore::WebXRRenderState::depthFar const):
(WebCore::WebXRRenderState::inlineVerticalFieldOfView const):
(WebCore::WebXRRenderState::baseLayer const):

  • Modules/webxr/WebXRRenderState.h: Added.
  • Modules/webxr/WebXRRenderState.idl: Added.
  • Modules/webxr/WebXRRigidTransform.cpp: Added.

(WebCore::WebXRRigidTransform::create):
(WebCore::WebXRRigidTransform::WebXRRigidTransform):
(WebCore::WebXRRigidTransform::position const):
(WebCore::WebXRRigidTransform::orientation const):
(WebCore::WebXRRigidTransform::matrix const):
(WebCore::WebXRRigidTransform::inverse const):

  • Modules/webxr/WebXRRigidTransform.h: Added.
  • Modules/webxr/WebXRRigidTransform.idl: Added.
  • Modules/webxr/WebXRSession.cpp: Added.

(WebCore::WebXRSession::environmentBlendMode const):
(WebCore::WebXRSession::visibilityState const):
(WebCore::WebXRSession::renderState const):
(WebCore::WebXRSession::inputSources const):
(WebCore::WebXRSession::updateRenderState):
(WebCore::WebXRSession::requestReferenceSpace):
(WebCore::WebXRSession::requestAnimationFrame):
(WebCore::WebXRSession::cancelAnimationFrame):
(WebCore::WebXRSession::end):
(WebCore::WebXRSession::activeDOMObjectName const):
(WebCore::WebXRSession::stop):

  • Modules/webxr/WebXRSession.h: Added.
  • Modules/webxr/WebXRSession.idl: Added.
  • Modules/webxr/WebXRSpace.cpp: Added.

(WebCore::WebXRSpace::WebXRSpace):

  • Modules/webxr/WebXRSpace.h: Added.
  • Modules/webxr/WebXRSpace.idl: Added.
  • Modules/webxr/WebXRSystem.cpp: Added.

(WebCore::WebXRSystem::create):
(WebCore::WebXRSystem::WebXRSystem):
(WebCore::WebXRSystem::isSessionSupported):
(WebCore::WebXRSystem::requestSession):
(WebCore::WebXRSystem::activeDOMObjectName const):
(WebCore::WebXRSystem::stop):

  • Modules/webxr/WebXRSystem.h: Added.
  • Modules/webxr/WebXRSystem.idl: Added.
  • Modules/webxr/WebXRView.cpp: Added.

(WebCore::WebXRView::create):
(WebCore::WebXRView::WebXRView):
(WebCore::WebXRView::eye const):
(WebCore::WebXRView::projectionMatrix const):
(WebCore::WebXRView::transform const):

  • Modules/webxr/WebXRView.h: Added.
  • Modules/webxr/WebXRView.idl: Added.
  • Modules/webxr/WebXRViewerPose.cpp: Added.

(WebCore::WebXRViewerPose::create):
(WebCore::WebXRViewerPose::views const):

  • Modules/webxr/WebXRViewerPose.h: Added.
  • Modules/webxr/WebXRViewerPose.idl: Added.
  • Modules/webxr/WebXRViewport.cpp: Added.

(WebCore::WebXRViewport::create):
(WebCore::WebXRViewport::x const):
(WebCore::WebXRViewport::y const):
(WebCore::WebXRViewport::width const):
(WebCore::WebXRViewport::height const):

  • Modules/webxr/WebXRViewport.h: Added.
  • Modules/webxr/WebXRViewport.idl: Added.
  • Modules/webxr/WebXRWebGLLayer.cpp: Added.

(WebCore::WebXRWebGLLayer::create):
(WebCore::WebXRWebGLLayer::WebXRWebGLLayer):
(WebCore::WebXRWebGLLayer::antialias const):
(WebCore::WebXRWebGLLayer::ignoreDepthValues const):
(WebCore::WebXRWebGLLayer::framebuffer const):
(WebCore::WebXRWebGLLayer::framebufferWidth const):
(WebCore::WebXRWebGLLayer::framebufferHeight const):
(WebCore::WebXRWebGLLayer::getViewport):
(WebCore::WebXRWebGLLayer::getNativeFramebufferScaleFactor):

  • Modules/webxr/WebXRWebGLLayer.h: Added.
  • Modules/webxr/WebXRWebGLLayer.idl: Added.
  • Modules/webxr/XREnvironmentBlendMode.h: Added.
  • Modules/webxr/XREnvironmentBlendMode.idl: Added.
  • Modules/webxr/XREye.h: Added.
  • Modules/webxr/XREye.idl: Added.
  • Modules/webxr/XRFrameRequestCallback.h: Added.
  • Modules/webxr/XRFrameRequestCallback.idl: Added.
  • Modules/webxr/XRHandedness.h: Added.
  • Modules/webxr/XRHandedness.idl: Added.
  • Modules/webxr/XRInputSourceEvent.cpp: Added.

(WebCore::XRInputSourceEvent::create):
(WebCore::XRInputSourceEvent::XRInputSourceEvent):
(WebCore::XRInputSourceEvent::frame const):
(WebCore::XRInputSourceEvent::inputSource const):
(WebCore::XRInputSourceEvent::buttonIndex const):

  • Modules/webxr/XRInputSourceEvent.h: Added.
  • Modules/webxr/XRInputSourceEvent.idl: Added.
  • Modules/webxr/XRInputSourcesChangeEvent.cpp: Added.

(WebCore::XRInputSourcesChangeEvent::create):
(WebCore::XRInputSourcesChangeEvent::XRInputSourcesChangeEvent):
(WebCore::XRInputSourcesChangeEvent::session const):
(WebCore::XRInputSourcesChangeEvent::added const):
(WebCore::XRInputSourcesChangeEvent::removed const):

  • Modules/webxr/XRInputSourcesChangeEvent.h: Added.
  • Modules/webxr/XRInputSourcesChangeEvent.idl: Added.
  • Modules/webxr/XRReferenceSpaceEvent.cpp: Added.

(WebCore::XRReferenceSpaceEvent::create):
(WebCore::XRReferenceSpaceEvent::XRReferenceSpaceEvent):
(WebCore::XRReferenceSpaceEvent::referenceSpace const):
(WebCore::XRReferenceSpaceEvent::transform const):

  • Modules/webxr/XRReferenceSpaceEvent.h: Added.
  • Modules/webxr/XRReferenceSpaceEvent.idl: Added.
  • Modules/webxr/XRReferenceSpaceType.h: Added.
  • Modules/webxr/XRReferenceSpaceType.idl: Added.
  • Modules/webxr/XRRenderStateInit.h: Added.
  • Modules/webxr/XRRenderStateInit.idl: Added.
  • Modules/webxr/XRSessionEvent.cpp: Added.

(WebCore::XRSessionEvent::create):
(WebCore::XRSessionEvent::XRSessionEvent):
(WebCore::XRSessionEvent::session const):

  • Modules/webxr/XRSessionEvent.h: Added.
  • Modules/webxr/XRSessionEvent.idl: Added.
  • Modules/webxr/XRSessionInit.h: Added.
  • Modules/webxr/XRSessionInit.idl: Added.
  • Modules/webxr/XRSessionMode.h: Added.
  • Modules/webxr/XRSessionMode.idl: Added.
  • Modules/webxr/XRTargetRayMode.h: Added.
  • Modules/webxr/XRTargetRayMode.idl: Added.
  • Modules/webxr/XRVisibilityState.h: Added.
  • Modules/webxr/XRVisibilityState.idl: Added.
  • Modules/webxr/XRWebGLLayerInit.h: Added.
  • Modules/webxr/XRWebGLLayerInit.idl: Added.
  • PlatformWPE.cmake: Added OpenXR libraries and include paths.
  • Sources.txt: Added new cpp files.
  • WebCore.xcodeproj/project.pbxproj: Added new files.
  • bindings/IDLTypes.h: Added SequenceStorageType.
  • bindings/js/JSDOMConvertSequences.h:
  • bindings/js/WebCoreBuiltinNames.h:
  • dom/EventNames.h:
  • dom/EventNames.in: Added WebXR events.
  • dom/EventTargetFactory.in: Added WebXR event targets.
  • page/RuntimeEnabledFeatures.h: Added new runtime feature for WebXR.

(WebCore::RuntimeEnabledFeatures::setWebXREnabled):
(WebCore::RuntimeEnabledFeatures::webXREnabled const):

  • platform/xr/PlatformXR.cpp: Added.
  • platform/xr/PlatformXR.h: Added.
  • platform/xr/openxr/PlatformXR.cpp: Added.

(PlatformXR::createStructure): Utility function to create OpenXR structs.
(PlatformXR::resultToString): Translates OpenXR error codes to strings.
(PlatformXR::Instance::Impl::Impl):
(PlatformXR::Instance::Impl::~Impl):
(PlatformXR::Instance::singleton):

Source/WebCore/PAL:

  • Configurations/FeatureDefines.xcconfig: Added ENABLE_WEBXR off by default.

Source/WebKit:

Added WebXR to the list of experimental features.

  • Configurations/FeatureDefines.xcconfig: Added ENABLE_WEBXR off by default.
  • Shared/WebPreferences.yaml: Added WebXR feature.
  • Shared/WebPreferencesDefaultValues.cpp:

(WebKit::defaultWebXREnabled): Set WebXR to off by default unless HAVE_SYSTEM_FEATURE_FLAGS.

  • Shared/WebPreferencesDefaultValues.h:
  • WebProcess/InjectedBundle/InjectedBundle.cpp:

(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):

Source/WebKitLegacy/mac:

  • Configurations/FeatureDefines.xcconfig: Added ENABLE_WEBXR, off by default.

Tools:

  • Scripts/webkitperl/FeatureList.pm: Added WebXR.
  • TestWebKitAPI/Configurations/FeatureDefines.xcconfig: Added ENABLE_WEBXR, off by default.
8:27 AM Changeset in webkit [258497] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

[Cairo] Path copy constructor and operator must also copy over CTM
https://bugs.webkit.org/show_bug.cgi?id=183327

Patch by Zan Dobersek <zdobersek@igalia.com> on 2020-03-16
Reviewed by Carlos Garcia Campos.

Cairo implementations of Path copy constructor and assignment operator
must also copy over the current transformation matrix that's maintained
on the source path's cairo_t context.

cairo_copy_path() copies the current path off of a Cairo context, but
during that also transforms every point on the path through inverse of
the CTM, back into user coordinates. For copying to be done correctly,
the copied path must be transformed through the CTM when it's appended
to the target Cairo context. For that reason the CTM has to be copied
over from source to target context before the path is copied and
appended.

  • platform/graphics/cairo/PathCairo.cpp:

(WebCore::Path::Path):
(WebCore::Path::operator=):

8:26 AM Changeset in webkit [258496] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[iOS] Add telemetry for message filtering
https://bugs.webkit.org/show_bug.cgi?id=208925
<rdar://problem/58885485>

Reviewed by Darin Adler.

On iOS, add telemetry for message filtering in the WebContent process' sandbox.

No new tests, no behavior change.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
8:19 AM Changeset in webkit [258495] by pvollan@apple.com
  • 4 edits in trunk

[Cocoa] Limit set of classes that can be decoded when a preference has changed
https://bugs.webkit.org/show_bug.cgi?id=208012

Reviewed by Brent Fulgham.

Source/WebKit:

As a hardening measure, limit the set of ObjectiveC classes that can be decoded in the WebContent process
as a result of a preference change.

API tests: WebKit.PreferenceChangesDictionary

WebKit.PreferenceChangesData
WebKit.PreferenceChangesDate

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::notifyPreferencesChanged):

Tools:

  • TestWebKitAPI/Tests/WebKit/PreferenceChanges.mm:

(TEST):

6:15 AM Changeset in webkit [258494] by youenn@apple.com
  • 11 edits
    3 adds in trunk

Unique origins should not be Potentially Trustworthy
https://bugs.webkit.org/show_bug.cgi?id=209049

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

  • web-platform-tests/service-workers/service-worker/interfaces-window.https-expected.txt:

Source/WebCore:

Unique origins should not be considered trustworthy as per https://w3c.github.io/webappsec-secure-contexts/#is-origin-trustworthy.

Test: http/tests/security/iframe-unique-origin.https.html

  • dom/Document.cpp:

(WebCore::Document::isSecureContext const):
Removed check for top level origins as we make all unique origins not trusted.

  • page/SecurityOrigin.cpp:

Source/WebKit:

  • WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:

(WebKit::WebFrameLoaderClient::hasNavigatedAwayFromAppBoundDomain):
We should only check this for the main frame since this is tied to the page.

Tools:

  • TestWebKitAPI/Tests/WebCore/SecurityOrigin.cpp:

(TestWebKitAPI::TEST_F):

LayoutTests:

  • editing/async-clipboard/resources/sanitize-when-reading-markup-iframe.html: Added.
  • editing/async-clipboard/sanitize-when-reading-markup.html:

Updating test to use HTTP instead of data URL for iFrame since clipboard is SecureContext.

  • http/tests/security/iframe-unique-origin.https-expected.txt: Added.
  • http/tests/security/iframe-unique-origin.https.html: Added.
6:15 AM Changeset in webkit [258493] by youenn@apple.com
  • 14 edits in trunk

Remove the use of empty WebRTC sources for receiver tracks
https://bugs.webkit.org/show_bug.cgi?id=209061

Reviewed by Eric Carlson.

LayoutTests/imported/w3c:

  • web-platform-tests/webrtc/RTCPeerConnection-track-stats.https-expected.txt:

Source/WebCore:

We no longer need to create receivers with empty sources since we now always have a libwebrtc receiver from which we can get the track.
We remove that code path.
This sldo allows using the right track parameters from the start, like track id.

Covered by existing and rebased tests.

  • Modules/mediastream/RTCPeerConnection.h:
  • Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp:

(WebCore::LibWebRTCMediaEndpoint::addPendingTrackEvent):
(WebCore::LibWebRTCMediaEndpoint::collectTransceivers):
(WebCore::LibWebRTCMediaEndpoint::newTransceiver):

  • Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp:

(WebCore::LibWebRTCPeerConnectionBackend::createReceiver):
(WebCore::LibWebRTCPeerConnectionBackend::addTrack):
(WebCore::LibWebRTCPeerConnectionBackend::addTransceiverFromTrackOrKind):
(WebCore::LibWebRTCPeerConnectionBackend::newRemoteTransceiver):

  • Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.h:
  • Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.cpp:

(WebCore::LibWebRTCRtpReceiverBackend::createSource):

  • Modules/mediastream/libwebrtc/LibWebRTCRtpReceiverBackend.h:
  • platform/mediastream/RealtimeIncomingAudioSource.cpp:

(WebCore::RealtimeIncomingAudioSource::RealtimeIncomingAudioSource):

  • platform/mediastream/RealtimeIncomingAudioSource.h:
  • platform/mediastream/RealtimeIncomingVideoSource.cpp:

(WebCore::RealtimeIncomingVideoSource::RealtimeIncomingVideoSource):

  • platform/mediastream/RealtimeIncomingVideoSource.h:
  • testing/MockLibWebRTCPeerConnection.h:

(WebCore::MockMediaStreamTrack::state const):
(WebCore::MockRtpReceiver::SetObserver):

5:41 AM Changeset in webkit [258492] by Carlos Garcia Campos
  • 13 edits in trunk

[Cairo][SVG] marker-mid isn't shown on a joint of rectilinearly connected line-to path segments
https://bugs.webkit.org/show_bug.cgi?id=113849

Reviewed by Adrian Perez de Castro.

Source/WebCore:

Marker-mid of svg is not displayed because path elements that added to
cairo backend are optimized. If the new line_to has same slope with
the previous path element, then the path element is joined to previous
path element.

Example:

added path elements : moveto(-5,-2), lineto(0,-2), lineto(5,-2)
cairo_path_data : moveto(-5,-2), lineto(5, -2)

This patch stores all of path informations separately in order to avoid
this problem. When generating positions of markers, we use stored path
informations instead of cairo_path_data.

When a new operation can't be directly stored in an ElementPath, we fallback to use cairo_path_data() in
Path::apply().

  • platform/graphics/Path.h: Add new constructor that receives a cairo context, make ensureCairoPath() private

and add m_elements member.

  • platform/graphics/cairo/FontCairo.cpp:

(WebCore::Font::platformPathForGlyph const): Create a cairo context for the path and use the new constructor
that receives a RefPtr<cairo_t>&&.

  • platform/graphics/cairo/PathCairo.cpp:

(WebCore::Path::Path): Initialize m_elements to an empty vector when created without a cairo context.
(WebCore::Path::operator=): Also copy m_elements.
(WebCore::Path::clear): Initialize m_elements to an empty vector.
(WebCore::Path::translate): Apply the translate to elements in m_elements.
(WebCore::Path::appendElement): Helper to add an operation to m_elements.
(WebCore::Path::moveToSlowCase): Call appendElement() if m_elements is not nullopt.
(WebCore::Path::addLineToSlowCase): Ditto.
(WebCore::Path::addRect): Ditto.
(WebCore::Path::addQuadCurveToSlowCase): Ditto.
(WebCore::Path::addBezierCurveToSlowCase): Ditto.
(WebCore::Path::addArcSlowCase): Set m_elements to nullopt.
(WebCore::Path::addArcTo): Ditto.
(WebCore::Path::addEllipse): Ditto.
(WebCore::Path::addPath): Ditto.
(WebCore::Path::closeSubpath): Call appendElement() if m_elements is not nullopt.
(WebCore::Path::applySlowCase const): Use elements from m_elements if it's not nullopt, otherwise fallback to
use cairo_path_data.
(WebCore::Path::transform): Apply the transform to elements in m_elements.

LayoutTests:

Remove svg/custom/local-url-reference-marker.html from expectations and rebaseline other tests.

  • platform/gtk/TestExpectations:
  • platform/gtk/imported/w3c/web-platform-tests/svg/import/text-path-01-b-manual-expected.txt:
  • platform/gtk/imported/w3c/web-platform-tests/svg/import/text-path-02-b-manual-expected.txt:
  • platform/gtk/imported/w3c/web-platform-tests/svg/painting/marker-008-expected.txt:
  • platform/gtk/imported/w3c/web-platform-tests/svg/text/reftests/textpath-shape-001-expected.txt:
  • platform/gtk/svg/text/text-path-01-b-expected.png:
  • platform/gtk/svg/text/text-path-01-b-expected.txt:
  • platform/wpe/TestExpectations:
5:17 AM Changeset in webkit [258491] by Nikolas Zimmermann
  • 624 edits
    2 copies
    2 adds in trunk/LayoutTests

[Gtk] Update pixel test baseline in svg/ subdirectory
https://bugs.webkit.org/show_bug.cgi?id=209137

Ruber-stamped by Žan Doberšek.

Update pixel test baseline, reflecting the status quo with WebKit ToT.

  • platform/gtk/svg: > 600 modifications of the -expected.png files.
  • platform/gtk/svg/W3C-SVG-1.1-SE/painting-marker-06-f-expected.png: Added.
  • platform/gtk/svg/filters/filter-refresh-expected.png: Copied from LayoutTests/platform/gtk/svg/filters/feImage-reference-invalidation-expected.png.
  • platform/gtk/svg/hixie/error/015-expected.png: Copied from LayoutTests/platform/gtk/svg/zoom/page/absolute-sized-document-no-scrollbars-expected.png.
  • platform/gtk/svg/overflow/overflow-on-outermost-svg-element-ignore-attribute-1-expected.png: Added.
4:08 AM Changeset in webkit [258490] by Nikolas Zimmermann
  • 1 edit
    27 adds in trunk/LayoutTests

[Gtk] Add missing pixel test results in svg/ subdirectory
https://bugs.webkit.org/show_bug.cgi?id=209136

Reviewed by Žan Doberšek.

Add pixel tests results based on current WebKit ToT.
No Gtk bot is running pixel tests, but it is still helpful to have an
updated pixel test baseline for local development. Many SVG tests
still depend on the pixel test output as only way to catch
regressions. This should be changed in future, but for now we should
at least have an accurate baseline.

  • platform/gtk/svg/animations/animate-marker-orienttype-1-expected.png: Added.
  • platform/gtk/svg/animations/animate-marker-orienttype-2-expected.png: Added.
  • platform/gtk/svg/animations/animate-marker-orienttype-3-expected.png: Added.
  • platform/gtk/svg/animations/animate-viewport-overflow-2-expected.png: Added.
  • platform/gtk/svg/animations/animate-viewport-overflow-expected.png: Added.
  • platform/gtk/svg/animations/avoid-calculating-for-non-animating-elements-expected.png: Added.
  • platform/gtk/svg/css/shape-rendering-parsing-expected.png: Added.
  • platform/gtk/svg/custom/non-scaling-stroke-markers-expected.png: Added.
  • platform/gtk/svg/custom/relative-sized-use-without-attributes-on-symbol-expected.png: Added.
  • platform/gtk/svg/custom/use-on-symbol-inside-pattern-expected.png: Added.
  • platform/gtk/svg/dynamic-updates/SVGClipPath-prefixed-influences-hitTesting-expected.png: Added.
  • platform/gtk/svg/dynamic-updates/SVGClipPath-prefixed-path-influences-hitTesting-expected.png: Added.
  • platform/gtk/svg/dynamic-updates/SVGClipPathElement-prefixed-css-transform-influences-hitTesting-expected.png: Added.
  • platform/gtk/svg/dynamic-updates/SVGClipPathElement-prefixed-transform-influences-hitTesting-expected.png: Added.
  • platform/gtk/svg/dynamic-updates/SVGFEGaussianBlurElement-dom-edgeMode-attr-expected.png: Added.
  • platform/gtk/svg/dynamic-updates/SVGFEGaussianBlurElement-svgdom-edgeMode-prop-expected.png: Added.
  • platform/gtk/svg/dynamic-updates/SVGFilterElement-dom-filterRes-attr-expected.png: Added.
  • platform/gtk/svg/filters/feBlend-all-blendmodes-expected.png: Added.
  • platform/gtk/svg/filters/filter-image-ref-root-expected.png: Added.
  • platform/gtk/svg/hixie/text/001-expected.png: Added.
  • platform/gtk/svg/in-html/overflow-repaint-expected.png: Added.
  • platform/gtk/svg/overflow/overflow-scroll-on-outermost-svg-element-expected.png: Added.
  • platform/gtk/svg/text/scaled-font-expected.png: Added.
  • platform/gtk/svg/text/text-hkern-expected.png: Added.
  • platform/gtk/svg/text/text-overflow-ellipsis-svgfont-kerning-ligatures-expected.png: Added.
  • platform/gtk/svg/text/text-vkern-on-horizontal-text-expected.png: Added.
2:29 AM Changeset in webkit [258489] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

[GTK] Gardening, update TestExpectations
https://bugs.webkit.org/show_bug.cgi?id=209105

Unreviewed gardening.

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

Remove addHTTPOriginIfNeeded calls
https://bugs.webkit.org/show_bug.cgi?id=209127

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

Remove addHTTPOriginIfNeeded calls since they are get requests and navigations and the spec [1]
indicates that the Origin header should not be written out, making these calls no-ops.

[1] https://fetch.spec.whatwg.org/#append-a-request-origin-header

  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::changeLocation):
(WebCore::FrameLoader::loadURL):

12:20 AM Changeset in webkit [258487] by commit-queue@webkit.org
  • 16 edits in trunk/Source

Simplify ChromeClient.createWindow
https://bugs.webkit.org/show_bug.cgi?id=209123

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

Source/WebCore:

Simplify ChromeClient.createWindow by removing the FrameLoadRequest parameter.
It was only passed for its ResourceRequest member, which can also be obtained
from the NavigationAction parameter.

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

(WebCore::createWindow):

  • page/Chrome.cpp:

(WebCore::Chrome::createWindow const):

  • page/Chrome.h:
  • page/ChromeClient.h:
  • page/ContextMenuController.cpp:

(WebCore::openNewWindow):

Source/WebKit:

Adapt to API change.

  • WebProcess/Inspector/WebInspector.cpp:

(WebKit::WebInspector::openInNewTab):

  • WebProcess/WebCoreSupport/WebChromeClient.cpp:

(WebKit::WebChromeClient::createWindow):

  • WebProcess/WebCoreSupport/WebChromeClient.h:
  • WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:

(WebKit::WebFrameLoaderClient::dispatchCreatePage):

Mar 15, 2020:

7:58 PM Changeset in webkit [258486] by Fujii Hironori
  • 4 edits in trunk

KeyedDecoderGeneric fails to allocate Vector while decoding broken data
https://bugs.webkit.org/show_bug.cgi?id=207324

Reviewed by Darin Adler.

Source/WebCore:

There were three crash bugs in it.

KeyedDecoderGeneric was trying to allocate a buffer without
ensuring the size wouldn't exceed the decoding data size by using
bufferIsLargeEnoughToContain.

It was trying to push an itme into the top dictionary of emtpy
m_dictionaryStack when EndObject tag would appear without the
preceding BeginObject tag.

It was trying to push an item into the top array of empty
m_arrayStack when EndArray tag would appear without the preceding
BeginArray tag.

Tests: TestWebKitAPI: KeyedCoding.DecodeRandomData

  • platform/generic/KeyedDecoderGeneric.cpp:

(WebCore::readString):
(WebCore::KeyedDecoderGeneric::KeyedDecoderGeneric):
Check bufferIsLargeEnoughToContain(size) before allocating a Vector with size.
Check if m_dictionaryStack and m_arrayStack are empty.

Tools:

  • TestWebKitAPI/Tests/WebCore/KeyedCoding.cpp:

(TestWebKitAPI::generateRandomData): Added.
(TestWebKitAPI::KeyedCoding.DecodeRandomData): Added a new test decoding random data.

7:33 PM Changeset in webkit [258485] by Lauro Moura
  • 4 edits in trunk/LayoutTests

WPE gardening.

Updated a test baseline with new message after changed from
js-test-pre to js-test.

Unreviewed test gardening.

  • platform/gtk/TestExpectations: Updated an expectation with new bug

number.

  • platform/wpe/TestExpectations:
  • platform/wpe/fast/frames/sandboxed-iframe-navigation-allowed-expected.txt:
7:08 PM Changeset in webkit [258484] by commit-queue@webkit.org
  • 3 edits in trunk/Source/ThirdParty/ANGLE

[ANGLE] Source/ThirdParty/ANGLE/src/common/utilities.cpp:10: warning: ignoring #pragma clang diagnostic [-Wunknown-pragmas]
https://bugs.webkit.org/show_bug.cgi?id=209014

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-03-15
Reviewed by Darin Adler.

Silence compiler warning.

  • changes.diff:
  • src/common/utilities.cpp:
6:41 PM Changeset in webkit [258483] by commit-queue@webkit.org
  • 2 edits in trunk/Source/ThirdParty/ANGLE

[ANGLE] Source/ThirdParty/ANGLE/src/libANGLE/Display.h:221:73: warning: implicitly-declared ‘egl::AttributeMap& egl::AttributeMap::operator=(const egl::AttributeMap&)’ is deprecated [-Wdeprecated-copy]
https://bugs.webkit.org/show_bug.cgi?id=209015

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-03-15
Reviewed by Darin Adler.

Suppress compiler warning. If this were WebKit code, I might take the time to fix it, but
with third-party code it's probably best to just turn off warnings that upstream is not
using.

  • CMakeLists.txt:
6:17 PM Changeset in webkit [258482] by Chris Dumez
  • 6 edits in trunk/Source/WebCore

[DRT] InternalSettingsGenerated::resetToConsistentState() may override TestOptions::enableBackForwardCache
https://bugs.webkit.org/show_bug.cgi?id=207481
<rdar://problem/59331661>

Reviewed by Darin Adler.

Add a support for a new excludeFromInternalSetting option in Settings.yaml and use it for
'usesBackForwardCache' setting. This means that script will no longer be able to toggle
this particular setting via internals.settings JS API. Tests wanting to turn on the
back / forward cache are supposed to use the following:
<!-- webkit-test-runner [ enableBackForwardCache=true ] -->

Using internals.settings JS API to turn on the back/forward cache would not work well
with WebKit2 because of process-swap-on-navigation. Support for it in WK1 / DRT was
causing flakiness because of a conflict between the 2 ways of enabling the setting.

  • Scripts/GenerateSettings.rb:
  • Scripts/SettingsTemplates/InternalSettingsGenerated.cpp.erb:
  • Scripts/SettingsTemplates/InternalSettingsGenerated.h.erb:
  • Scripts/SettingsTemplates/InternalSettingsGenerated.idl.erb:
  • page/Settings.yaml:
2:28 PM Changeset in webkit [258481] by aakash_jain@apple.com
  • 2 edits in trunk/LayoutTests

Regression r258439: quicklook/multi-sheet-numbers-09.html is failing consistently on iOS
https://bugs.webkit.org/show_bug.cgi?id=209128

Partially revert r258439.

Unreviewed test gardening.

  • platform/ios-simulator-wk2/TestExpectations:
8:33 AM Changeset in webkit [258480] by Alan Bujtas
  • 6 edits
    2 adds in trunk

[LFC][TFC] Add basic column span support for content box width
https://bugs.webkit.org/show_bug.cgi?id=209120
<rdar://problem/60463424>

Reviewed by Antti Koivisto.

Source/WebCore:

Take the column spanning into account when computing the content width for the table cell.
[content box width = column width(1) + column width(2) + .. + column width(spanning value) + ((spanning value - 1) * horizontal spacing)]

Test: fast/layoutformattingcontext/table-colspan-simple.html

  • layout/tableformatting/TableFormattingContext.cpp:

(WebCore::Layout::TableFormattingContext::layoutInFlowContent):
(WebCore::Layout::TableFormattingContext::layoutTableCellBox):
(WebCore::Layout::TableFormattingContext::positionTableCells):

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

(WebCore::Layout::TableGrid::appendCell):

  • layout/tableformatting/TableGrid.h:

(WebCore::Layout::TableGrid::CellInfo::startColumn const):
(WebCore::Layout::TableGrid::CellInfo::endColumn const):
(WebCore::Layout::TableGrid::CellInfo::startRow const):
(WebCore::Layout::TableGrid::CellInfo::endRow const):
(WebCore::Layout::TableGrid::CellInfo::columnSpan const):
(WebCore::Layout::TableGrid::CellInfo::rowSpan const):

LayoutTests:

  • fast/layoutformattingcontext/table-colspan-simple-expected.html: Added.
  • fast/layoutformattingcontext/table-colspan-simple.html: Added.
3:51 AM Changeset in webkit [258479] by ysuzuki@apple.com
  • 4 edits in trunk/Source/JavaScriptCore

reportZappedCellAndCrash should handle PreciseAllocation in IsoSubspace
https://bugs.webkit.org/show_bug.cgi?id=209042

Reviewed by Mark Lam.

This patch adds support of PreciseAllocation cells to reportZappedCellAndCrash, since now it is frequently used
as a lower-tier cells in IsoSubspace.

  • heap/IsoSubspace.h:
  • heap/IsoSubspaceInlines.h:

(JSC::IsoSubspace::forEachLowerTierFreeListedPreciseAllocation):

  • runtime/JSCell.cpp:

(JSC::reportZappedCellAndCrash):

3:16 AM Changeset in webkit [258478] by ysuzuki@apple.com
  • 37 edits
    2 adds in trunk

Should not use variable-length-array (VLA)
https://bugs.webkit.org/show_bug.cgi?id=209043

Reviewed by Mark Lam.

PerformanceTests:

  • MediaTime/Configurations/Base.xcconfig:

Source/bmalloc:

  • Configurations/Base.xcconfig:

Source/JavaScriptCore:

This patch disables variable-length-array (VLA). If this feature uses user-input, user can
control the stack height consumed by C++ code. This patch avoids using VLA. To achieve that,

  1. We set -Wvla warning option to trigger warnings if it is used.
  2. Introduce MarkedJSValueRefArray for API. This replaces JSValueRef arguments[variableLength] use case. MarkedJSValueRefArray registers itself to JSC GC so that GC can mark it as a strong root.
  • API/JSContext.mm:

(+[JSContext currentArguments]):

  • API/JSValue.mm:

(-[JSValue callWithArguments:]):
(-[JSValue constructWithArguments:]):
(-[JSValue invokeMethod:withArguments:]):

  • API/MarkedJSValueRefArray.cpp: Added.

(JSC::MarkedJSValueRefArray::MarkedJSValueRefArray):
(JSC::MarkedJSValueRefArray::~MarkedJSValueRefArray):
(JSC::MarkedJSValueRefArray::visitAggregate):

  • API/MarkedJSValueRefArray.h: Added.
  • API/tests/minidom.c:

(print):

  • API/tests/testapi.cpp:

(TestAPI::markedJSValueArrayAndGC):
(testCAPIViaCpp):

  • Configurations/Base.xcconfig:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Sources.txt:
  • heap/Heap.cpp:

(JSC::Heap::addCoreConstraints):
(JSC::Heap::addMarkedJSValueRefArray):

  • heap/Heap.h:
  • heap/MarkedSpace.h:

(JSC::MarkedSpace::activeWeakSetsBegin): Deleted.
(JSC::MarkedSpace::activeWeakSetsEnd): Deleted.
(JSC::MarkedSpace::newActiveWeakSetsBegin): Deleted.
(JSC::MarkedSpace::newActiveWeakSetsEnd): Deleted.

  • runtime/ArgList.h:

Source/WebCore:

  • Configurations/Base.xcconfig:
  • crypto/mac/SerializedCryptoKeyWrapMac.mm:

(WebCore::wrapSerializedCryptoKey):
(WebCore::unwrapSerializedCryptoKey):

  • html/canvas/WebGL2RenderingContext.cpp:

(WebCore::WebGL2RenderingContext::getInternalformatParameter):

  • platform/mediastream/mac/CoreAudioCaptureDeviceManager.cpp:

(WebCore::CoreAudioCaptureDeviceManager::refreshAudioCaptureDevices):

  • platform/mediastream/mac/ScreenDisplayCaptureSourceMac.mm:

(WebCore::updateDisplayID):
(WebCore::ScreenDisplayCaptureSourceMac::screenCaptureDevices):

Source/WebCore/PAL:

  • Configurations/Base.xcconfig:

Source/WebInspectorUI:

  • Configurations/Base.xcconfig:

Source/WebKit:

  • Configurations/Base.xcconfig:
  • UIProcess/_WKTouchEventGenerator.mm:

(-[_WKTouchEventGenerator touchDown:touchCount:]):
(-[_WKTouchEventGenerator liftUp:touchCount:]):
(-[_WKTouchEventGenerator moveToPoints:touchCount:duration:]):

Source/WebKitLegacy/mac:

  • Configurations/Base.xcconfig:

Source/WTF:

  • Configurations/Base.xcconfig:
  • wtf/UUID.cpp:

(WTF::bootSessionUUIDString):

Tools:

  • ContentExtensionTester/Configurations/Base.xcconfig:
  • lldb/lldbWebKitTester/Configurations/Base.xcconfig:

Mar 14, 2020:

8:40 PM Changeset in webkit [258477] by beidson@apple.com
  • 3 edits in trunk/Source/WebKit

Fix the "deliver cached ranges" logic in PDFPlugin (and other small cleanups)
https://bugs.webkit.org/show_bug.cgi?id=209097

Reviewed by Tim Hatcher.

Streaming in data always appended to the buffer instead of first growing the buffer.
This wasn't noticed earlier because we often did not grow the buffer for successful range request completion.
But now we often do!

So this cleans that all up.

At the same time it revealed other interactions with PDFKit that force us to handle data requests on the main
thread after the document load is complete - Which is fine!

  • WebProcess/Plugins/PDF/PDFPlugin.h:
  • WebProcess/Plugins/PDF/PDFPlugin.mm:

(WebKit::dataProviderGetBytesAtPositionCallback): If on the main thread (and the document load is complete)

handle the request directly!

(WebKit::PDFPlugin::getResourceBytesAtPositionMainThread):
(WebKit::PDFPlugin::ByteRangeRequest::completeWithAccumulatedData):
(WebKit::PDFPlugin::ensureDataBufferLength):
(WebKit::PDFPlugin::didFail):
(WebKit::PDFPlugin::maybeClearHighLatencyDataProviderFlag):
(WebKit::PDFPlugin::documentDataDidFinishLoading):
(WebKit::PDFPlugin::installPDFDocument):
(WebKit::PDFPlugin::manualStreamDidReceiveData): Grow the buffer instead of append.

5:14 PM Changeset in webkit [258476] by Brent Fulgham
  • 8 edits in trunk/Source

Add missing checks needed for AppBound Quirk
https://bugs.webkit.org/show_bug.cgi?id=209117
<rdar://problem/60460097>

Reviewed by John Wilander.

The checks for the 'NeedsInAppBrowserPrivacyQuirks' flag added in r258101 was incomplete.
Source/WebCore:

Two additional call sites need to check the state of the flag.

  • bindings/js/ScriptController.cpp:

(WebCore::ScriptController::executeScriptInWorld): Add missing check for the quirk.

  • loader/FrameLoaderClient.h: Add new API for the 'NeedsInAppBrowserPrivacyQuirks'

debug flag.

  • page/Frame.cpp:

(WebCore::Frame::injectUserScriptImmediately): Ditto.

Source/WebKit:

These changes let the WebFrameLoaderClient report the quirk state to WebCore code.

  • WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:

(WebKit::WebFrameLoaderClient::needsInAppBrowserPrivacyQuirks): Added.

  • WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
  • WebProcess/WebPage/WebPage.h:

(WebKit::WebPage::needsInAppBrowserPrivacyQuirks const): Added.

3:59 PM Changeset in webkit [258475] by Darin Adler
  • 20 edits in trunk/Source

Change all return values in TextIterator header from live ranges to SimpleRange
https://bugs.webkit.org/show_bug.cgi?id=208906

Reviewed by Antti Koivisto.

Source/WebCore:

This is another step in moving off of live ranges for WebKit internals.

  • Change return values of remaining functions that were returning live ranges in the TextIterator header to return SimpleRange.
  • Change some arguments from live ranges to SimpleRange.
  • At some call sites, use createLiveRange to convert the SimpleRange into a live range (for now), but at others update the code to use SimpleRange.
  • Renamed a version of findPlainText that returns a boolean to containsPlainText.
  • Convert call sites that were using createLiveRange just to use the Range::startPosition and Range::endPosition functions to instead use a new overload of the createLegacyEditingPosition function that can be used with SimpleRange::start and SimpleRange::end because it takes a BoundaryPoint.
  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::rangeMatchesTextNearRange): Return Optional<SimpleRange>
and take SimpleRange argument.
(WebCore::AXObjectCache::previousBoundary): Updated since
SimplifiedBackwardsTextIterator::range now returns SimpleRange.

  • accessibility/AXObjectCache.h: Updated for the above.
  • accessibility/AccessibilityObjectInterface.h:

(WebCore::AXCoreObject::containsText const): Updated for name change.
Now containsPlainText instead of findPlainText.

  • accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:

(-[WebAccessibilityObjectWrapper arrayOfTextForTextMarkers:attributed:]):
Use createLegacyEditingPosition instead of createLiveRange.
(-[WebAccessibilityObjectWrapper rangeFromMarkers:withText:]): Use createLiveRange.

  • accessibility/mac/WebAccessibilityObjectWrapperMac.mm:

(-[WebAccessibilityObjectWrapper doAXAttributedStringForTextMarkerRange:spellCheck:]):
Use createLegacyEditingPosition instead of createLiveRange.

  • dom/Position.cpp:

(WebCore::createLegacyEditingPosition): Added an overload that takes a BoundaryPoint.

  • dom/Position.h: Updated for the above, also removed unneeded includes and forward

declarations.

  • editing/Editing.cpp:

(WebCore::visiblePositionForIndexUsingCharacterIterator): Updated since
CharacterIterator::range is now a SimpleRange, use createLegacyEditingPosition.

  • editing/Editor.cpp:

(WebCore::Editor::advanceToNextMisspelling): Updated since CharacterIterator::range
is now a SimpleRange.
(WebCore::Editor::rangeOfString): Updated since findPlainText now returns a
SimpleRange; use createLiveRange.
(WebCore::Editor::countMatchesForText): Ditto.

  • editing/TextIterator.cpp:

(WebCore::SimplifiedBackwardsTextIterator::range const): Return a SimpleRange.
(WebCore::CharacterIterator::range const): Ditto.
(WebCore::characterSubrange): Updated since CharacterIterator::range returns
a SimpleRange. Use createLiveRange.
(WebCore::BackwardsCharacterIterator::BackwardsCharacterIterator): Cut down
code here by initializing data members in the class definition.
(WebCore::BackwardsCharacterIterator::range const): Return a SimpleRange.
(WebCore::WordAwareIterator::WordAwareIterator): Cut down code here by
initializing data members in the class definition.
(WebCore::hasAnyPlainText): Take a SimpleRange, use createLiveRange.
(WebCore::plainTextUsingBackwardsTextIteratorForTesting): Take a SimpleRange,
use createLiveRange.
(WebCore::collapsedToBoundary): Take and return a SimpleRange.
(WebCore::findPlainTextMatches): Take a SimpleRange, use createLiveRange.
(WebCore::rangeForMatch): Take and return a SimpleRange.
(WebCore::findClosestPlainText): Ditto.
(WebCore::findPlainText): Ditto.
(WebCore::containsPlainText): Renamed from findPlainText since this returns
a boolean, not a found location of some text.

  • editing/TextIterator.h: Updated for the above. Also changed some data

members to use unsigned for offsets rather than int.

  • editing/TextManipulationController.cpp:

(WebCore::ParagraphContentIterator::startPosition): Use
createLegacyEditingPosition instead of createLiveRange.
(WebCore::ParagraphContentIterator::endPosition): Ditto.

  • editing/VisiblePosition.h: Added a forward declaration here since Position.h

no longer forward declares it.

  • editing/VisibleSelection.cpp:

(WebCore::VisibleSelection::appendTrailingWhitespace): Updated since
CharacterIterator::range is now a SimpleRange, use createLegacyEditingPosition.

  • editing/VisibleUnits.cpp:

(WebCore::previousBoundary): Ditto.
(WebCore::nextBoundary): Ditto.

  • testing/Internals.cpp:

(WebCore::Internals::rangeOfStringNearLocation): Updated since
findClosestPlainText now returns a SimpleRange, use createLiveRange.

Source/WebKit:

  • WebProcess/WebPage/Cocoa/WebPageCocoa.mm: Removed unneeded include of

TextIterator.h.

  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::rangeNearPositionMatchesText): Removed unused originalRange argument,
changed return type to Optional<SimpleRange> since findClosestPlainText now
returns a SimpleRange.
(WebKit::WebPage::getRectsAtSelectionOffsetWithText): Updated since
rangeNearPositionMatchesText now returns Optional<SimpleRange>, use createLiveRange.
(WebKit::WebPage::requestDocumentEditingContext): Updated since
CharacterIterator::range returns SimpleRange, use createLiveRange.

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

Gather PDF scripts to run on a background thread.
https://bugs.webkit.org/show_bug.cgi?id=209063

Reviewed by Geoff Garen.

In incremental loading mode, gathering document scripts will sometimes require PDFKit/CG
to lock and wait on data loads from our data provider.

So if we gather them on the main thread, we will hang the main thread and therefore deadlock
with our data provider thread/queue.

So let's gather those scripts on a background thread!

  • WebProcess/Plugins/PDF/PDFPlugin.h:
  • WebProcess/Plugins/PDF/PDFPlugin.mm:

(WebKit::PDFPlugin::threadEntry):
(WebKit::PDFPlugin::ByteRangeRequest::completeWithAccumulatedData):
(WebKit::PDFPlugin::documentDataDidFinishLoading):
(WebKit::PDFPlugin::installPDFDocument):
(WebKit::PDFPlugin::streamDidFinishLoading):
(WebKit::PDFPlugin::manualStreamDidFinishLoading):
(WebKit::PDFPlugin::tryRunScriptsInPDFDocument): Only actually gathers scripts to execute if there

is a m_pdfDocument and the entire document data finished loading.

(WebKit::PDFPlugin::pdfDocumentDidLoad): Deleted.
(WebKit::PDFPlugin::runScriptsInPDFDocument): Deleted.

3:04 PM Changeset in webkit [258473] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[LFC][TFC] Fill in the gaps with anonymous table cell boxes
https://bugs.webkit.org/show_bug.cgi?id=209114
<rdar://problem/60458806>

Reviewed by Antti Koivisto.

Source/WebCore:

17.5 Visual layout of table contents
A "missing cell" is a cell in the row/column grid that is not
occupied by an element or pseudo-element. Missing cells are rendered
as if an anonymous table-cell box occupied their position in the grid.
(https://www.w3.org/TR/CSS22/tables.html)

This helps to keep TableGrid an actual grid.

Test: fast/layoutformattingcontext/table-missing-cells-simple.html

  • layout/layouttree/LayoutTreeBuilder.cpp:

(WebCore::Layout::TreeBuilder::buildTableStructure):

LayoutTests:

  • fast/layoutformattingcontext/table-missing-cells-simple-expected.html: Added.
  • fast/layoutformattingcontext/table-missing-cells-simple.html: Added.
12:53 PM Changeset in webkit [258472] by Adrian Perez de Castro
  • 3 edits
    2 adds in releases/WebKitGTK/webkit-2.26

Merge r257720 - ASSERT(m_column != unsetColumnIndex) in RenderTable::cellBefore
https://bugs.webkit.org/show_bug.cgi?id=208397

Patch by Doug Kelly <Doug Kelly> on 2020-03-02
Reviewed by Zalan Bujtas.

Source/WebCore:

When inserting a cell into a table row which is not visible, this can lead to attempting to compute the repaint
rects during tree building. Instead, mark the layer as dirty using dirtyVisibleContentStatus(), and the visibility
will be recomputed at a later time.

Test: fast/table/insert-cell-invisible-parent.html

  • rendering/RenderElement.cpp:

(WebCore::RenderElement::insertedIntoTree):

LayoutTests:

  • fast/table/insert-cell-invisible-parent-expected.txt: Added.
  • fast/table/insert-cell-invisible-parent.html: Added.
12:53 PM Changeset in webkit [258471] by Adrian Perez de Castro
  • 3 edits
    4 adds in releases/WebKitGTK/webkit-2.26

Merge r257897 - Crash in SVGElement::removeEventListener with symbol element
https://bugs.webkit.org/show_bug.cgi?id=207920

Patch by Doug Kelly <Doug Kelly> on 2020-03-04
Reviewed by Ryosuke Niwa.

Source/WebCore:

Resolves a crash in SVGElement::removeEventListener by only attaching the events to the window if the SVG element is both the outermost
SVG element, in addition to ensuring the SVG element is attached to the tree. The symbol element's behavior when referenced by a use
tag actually creates an svg tag instead, so the SVGSVGElement's special behavior for copying attributes is vital.

Note that Chrome and Firefox have a similar behavior for detached SVG elements as to what this change creates: in both other browsers,
onerror is not fired for a detached svg element, and in Firefox, onresize is not fired for a detached svg element (it is however fired
in Chrome).

Tests: fast/events/detached-svg-parent-window-events.html

fast/events/onerror-svg-symbol.html

  • svg/SVGSVGElement.cpp:

(WebCore::SVGSVGElement::parseAttribute):

LayoutTests:

  • fast/events/detached-svg-parent-window-events-expected.txt: Added.
  • fast/events/detached-svg-parent-window-events.html: Added.
  • fast/events/onerror-svg-symbol-expected.txt: Added.
  • fast/events/onerror-svg-symbol.html: Added.
12:52 PM Changeset in webkit [258470] by Adrian Perez de Castro
  • 2 edits in releases/WebKitGTK/webkit-2.26/Source/bmalloc

Merge r258142 - Build failure on ppc64le if unix is undefined
https://bugs.webkit.org/show_bug.cgi?id=207906

Patch by Mike Gorse <mgorse@suse.com> on 2020-03-09
Reviewed by Yusuke Suzuki.

  • bmalloc/BPlatform.h: Check for unix along with unix.
12:19 PM Changeset in webkit [258469] by Peng Liu
  • 10 edits
    2 deletes in trunk

Cleanup RenderMediaControls.cpp and RenderMediaControlElements.cpp
https://bugs.webkit.org/show_bug.cgi?id=209008

Reviewed by Daniel Bates.

Source/WebCore:

Merge RenderMediaControls.[h|cpp] and RenderMediaControlElements.[h|cpp].
Remove class RenderMediaVolumeSliderContainer because we can use RenderBlockFlow
to render MediaControlTextTrackContainerElement.

No new tests, no functional change.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • html/shadow/MediaControlElementTypes.cpp:
  • html/shadow/MediaControlElements.cpp:

(WebCore::MediaControlTextTrackContainerElement::createElementRenderer):

  • rendering/RenderMediaControlElements.cpp: Removed.
  • rendering/RenderMediaControlElements.h: Removed.
  • rendering/RenderMediaControls.cpp:

(WebCore::RenderMediaVolumeSliderContainer::RenderMediaVolumeSliderContainer):
(WebCore::RenderMediaVolumeSliderContainer::layout):
(WebCore::RenderMediaControlTimelineContainer::RenderMediaControlTimelineContainer):
(WebCore::RenderMediaControlTimelineContainer::layout):

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

LayoutTests:

Remove unused code in a test.

  • media/track/track-cue-rendering-rtl.html:
12:01 PM Changeset in webkit [258468] by dbates@webkit.org
  • 3 edits in trunk/Source/WebCore

Share HitTestResult::addNodeToListBasedTestResult() impl for LayoutRect and FloatRect overloads
https://bugs.webkit.org/show_bug.cgi?id=209107

Reviewed by Brady Eidson.

Remove code duplication for adding a node to the result set.

  • rendering/HitTestResult.cpp:

(WebCore::HitTestResult::addNodeToListBasedTestResultCommon): Added.
(WebCore::HitTestResult::addNodeToListBasedTestResult): Write in terms of addNodeToListBasedTestResultCommon().

  • rendering/HitTestResult.h:
9:10 AM Changeset in webkit [258467] by commit-queue@webkit.org
  • 2 edits in trunk

[CMake] Warning when ccache is not installed
https://bugs.webkit.org/show_bug.cgi?id=208952

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-03-14
Reviewed by Daniel Bates.

Change the warning when ccache is not installed to a status message. We shouldn't be
printing warnings except when there is an actual problem.

  • Source/cmake/WebKitCCache.cmake:
5:57 AM Changeset in webkit [258466] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[Tree building] Reset the fragmented flow status before calling child.willBeRemovedFromTree.
https://bugs.webkit.org/show_bug.cgi?id=209100
<rdar://problem/60434672>

Reviewed by Simon Fraser.

Source/WebCore:

::willBeRemovedFromTree() assumes all the cleanup has happened and it's the final step before calling d'tor.
It clears m_fragmentList that resetFragmentedFlowStateOnRemoval() later checks for consistency (m_fragmentList.contains(fragment)).

Test: fast/multicol/reparent-fragment-flow-content.html

  • rendering/updating/RenderTreeBuilder.cpp:

(WebCore::RenderTreeBuilder::detachFromRenderElement):

LayoutTests:

  • fast/multicol/reparent-fragment-flow-content-expected.txt: Added.
  • fast/multicol/reparent-fragment-flow-content.html: Added.
3:22 AM Changeset in webkit [258465] by commit-queue@webkit.org
  • 10 edits in trunk

Set Origin header value to null rather than omitting it
https://bugs.webkit.org/show_bug.cgi?id=186030

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

LayoutTests/imported/w3c:

Update improved test result.

  • web-platform-tests/fetch/origin/assorted.window-expected.txt:

Source/WebCore:

For every redirect, addHTTPOriginIfNeeded should be called to
make sure that the tainted origin logic is applied [1, Step 10] and
thus the request after redirect has the correct Origin header.

Make AppleWin treat 308 redirects like 307 and so keeping http
methods across redirects. This is similar to
https://bugs.webkit.org/show_bug.cgi?id=154348.

[1] https://fetch.spec.whatwg.org/#concept-http-network-or-cache-fetch

  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::addHTTPOriginIfNeeded):

  • loader/SubresourceLoader.cpp:

(WebCore::SubresourceLoader::checkRedirectionCrossOriginAccessControl):

  • platform/network/cf/ResourceHandleCFURLConnectionDelegate.cpp:

(WebCore::ResourceHandleCFURLConnectionDelegate::createResourceRequest):

LayoutTests:

Update improved test result.

  • http/tests/security/cors-post-redirect-307-expected.txt:
  • http/tests/security/cors-post-redirect-307-pson-expected.txt:
  • http/tests/security/cors-post-redirect-308-expected.txt:
12:15 AM Changeset in webkit [258464] by rniwa@webkit.org
  • 3 edits in trunk/Source/WebCore

Call SVGTRefElement::buildPendingResource in SVGElement::didFinishInsertingNode
https://bugs.webkit.org/show_bug.cgi?id=208981

Reviewed by Antti Koivisto.

This patch moves the call to SVGTRefElement::buildPendingResource from SVGElement::insertedIntoAncestor
to SVGElement::didFinishInsertingNode.

  • svg/SVGElement.cpp:

(WebCore::SVGElement::insertedIntoAncestor): Return true when the element has a pending resource ID.
(WebCore::SVGElement::didFinishInsertingNode): Added. Calls buildPendingResourcesIfNeeded.

  • svg/SVGElement.h:
12:03 AM Changeset in webkit [258463] by sbarati@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed. Fix windows build by making configSizeToProtect stay 4KB.

  • runtime/JSCConfig.h:
Note: See TracTimeline for information about the timeline view.