Branch: refs/heads/main Home: https://github.com/WebKit/WebKit Commit: 03ee317ac8d06a3245e106fd0da4674bd4918970 https://github.com/WebKit/WebKit/commit/03ee317ac8d06a3245e106fd0da4674bd4918970 Author: Youenn Fablet <youe...@gmail.com> Date: 2023-02-23 (Thu, 23 Feb 2023)
Changed paths: A LayoutTests/http/wpt/background-fetch/fetch-denied.window-expected.txt A LayoutTests/http/wpt/background-fetch/fetch-denied.window.html A LayoutTests/http/wpt/background-fetch/fetch-denied.window.js A LayoutTests/http/wpt/background-fetch/sw.js M LayoutTests/imported/w3c/web-platform-tests/resources/testdriver-vendor.js M LayoutTests/platform/glib/TestExpectations M LayoutTests/platform/mac-wk1/TestExpectations M LayoutTests/platform/wincairo/TestExpectations M Source/WebCore/workers/service/server/SWServer.cpp M Source/WebCore/workers/service/server/SWServer.h M Source/WebCore/workers/service/server/SWServerDelegate.h M Source/WebKit/NetworkProcess/NetworkProcess.cpp M Source/WebKit/NetworkProcess/NetworkProcess.h M Source/WebKit/NetworkProcess/NetworkSession.cpp M Source/WebKit/NetworkProcess/NetworkSession.h M Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStore.mm M Source/WebKit/UIProcess/API/Cocoa/_WKWebsiteDataStoreDelegate.h M Source/WebKit/UIProcess/Network/NetworkProcessProxy.cpp M Source/WebKit/UIProcess/Network/NetworkProcessProxy.h M Source/WebKit/UIProcess/Network/NetworkProcessProxy.messages.in M Source/WebKit/UIProcess/WebsiteData/WebsiteDataStoreClient.h M Tools/WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl M Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp M Tools/WebKitTestRunner/InjectedBundle/TestRunner.h M Tools/WebKitTestRunner/TestController.cpp M Tools/WebKitTestRunner/TestController.h M Tools/WebKitTestRunner/TestInvocation.cpp M Tools/WebKitTestRunner/cocoa/TestControllerCocoa.mm M Tools/WebKitTestRunner/cocoa/TestWebsiteDataStoreDelegate.h M Tools/WebKitTestRunner/cocoa/TestWebsiteDataStoreDelegate.mm Log Message: ----------- Add a delegate to allow/deny background fetches https://bugs.webkit.org/show_bug.cgi?id=252565 rdar://problem/105678551 Reviewed by Alex Christensen. Add plumbing code to check for background fetch permission at SWServer/NetworkProcess level to WebsiteDataStore delegate/UIProcess. Covered by added test. * LayoutTests/http/wpt/background-fetch/fetch-denied.window-expected.txt: Added. * LayoutTests/http/wpt/background-fetch/fetch-denied.window.html: Added. * LayoutTests/http/wpt/background-fetch/fetch-denied.window.js: Added. (promise_test.async t): * LayoutTests/http/wpt/background-fetch/sw.js: Added. * LayoutTests/imported/w3c/web-platform-tests/resources/testdriver-vendor.js: (async switch): (window.test_driver_internal.set_permission): * LayoutTests/platform/glib/TestExpectations: * Source/WebCore/workers/service/server/SWServer.cpp: (WebCore::SWServer::Connection::startBackgroundFetch): * Source/WebCore/workers/service/server/SWServer.h: (WebCore::SWServer::requestBackgroundFetchPermission): * Source/WebCore/workers/service/server/SWServerDelegate.h: * Source/WebKit/NetworkProcess/NetworkProcess.cpp: (WebKit::NetworkProcess::requestBackgroundFetchPermission): * Source/WebKit/NetworkProcess/NetworkProcess.h: * Source/WebKit/NetworkProcess/NetworkSession.cpp: (WebKit::NetworkSession::requestBackgroundFetchPermission): * Source/WebKit/NetworkProcess/NetworkSession.h: * Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStore.mm: * Source/WebKit/UIProcess/API/Cocoa/_WKWebsiteDataStoreDelegate.h: * Source/WebKit/UIProcess/Network/NetworkProcessProxy.cpp: (WebKit::NetworkProcessProxy::requestBackgroundFetchPermission): * Source/WebKit/UIProcess/Network/NetworkProcessProxy.h: * Source/WebKit/UIProcess/Network/NetworkProcessProxy.messages.in: * Source/WebKit/UIProcess/WebsiteData/WebsiteDataStoreClient.h: (WebKit::WebsiteDataStoreClient::requestBackgroundFetchPermission): * Tools/WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl: * Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp: (WTR::TestRunner::setBackgroundFetchPermission): * Tools/WebKitTestRunner/InjectedBundle/TestRunner.h: * Tools/WebKitTestRunner/TestController.cpp: (WTR::TestController::resetStateToConsistentValues): (WTR::TestController::setBackgroundFetchPermission): * Tools/WebKitTestRunner/TestController.h: * Tools/WebKitTestRunner/TestInvocation.cpp: (WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle): * Tools/WebKitTestRunner/cocoa/TestControllerCocoa.mm: (WTR::TestController::setBackgroundFetchPermission): * Tools/WebKitTestRunner/cocoa/TestWebsiteDataStoreDelegate.h: * Tools/WebKitTestRunner/cocoa/TestWebsiteDataStoreDelegate.mm: (-[TestWebsiteDataStoreDelegate init]): (-[TestWebsiteDataStoreDelegate setBackgroundFetchPermission:]): (-[TestWebsiteDataStoreDelegate requestBackgroundFetchPermission:frameOrigin:decisionHandler:]): Canonical link: https://commits.webkit.org/260737@main _______________________________________________ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes