Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.
TypeScript automationchromechromiume2e-testingelectronend-to-end-testingfirefoxjavascriptplaywrighttesttest-automationtestingtesting-toolswebwebkit
chore: update browser_patches to 9768715bd (#36191)
Max Schmitt85519de71bf7
diff --git a/browser_patches/firefox/UPSTREAM_CONFIG.sh b/browser_patches/firefox/UPSTREAM_CONFIG.shindex 5ae9758e38..db9424fcf3 100644--- a/browser_patches/firefox/UPSTREAM_CONFIG.sh+++ b/browser_patches/firefox/UPSTREAM_CONFIG.sh@@ -1,3 +1,3 @@REMOTE_URL="https://github.com/mozilla/gecko-dev"BASE_BRANCH="release"-BASE_REVISION="5e1efb776a56e399f6810204a2eca13f18a3eba6"+BASE_REVISION="9cbfae27052e4aaeb064d2d08e7e869f31ee4288"diff --git a/browser_patches/firefox/juggler/Helper.js b/browser_patches/firefox/juggler/Helper.jsindex f5a64d6c8b..875dd5ac2e 100644--- a/browser_patches/firefox/juggler/Helper.js+++ b/browser_patches/firefox/juggler/Helper.js@@ -4,9 +4,9 @@const uuidGen = Cc["@mozilla.org/uuid-generator;1"].getService(Ci.nsIUUIDGenerator);-class Helper {+export class Helper {decorateAsEventEmitter(objectToDecorate) {- const { EventEmitter } = ChromeUtils.import('resource://gre/modules/EventEmitter.jsm');+ const { EventEmitter } = ChromeUtils.importESModule('resource://gre/modules/EventEmitter.sys.mjs');const emitter = new EventEmitter();objectToDecorate.on = emitter.on.bind(emitter);objectToDecorate.addEventListener = emitter.on.bind(emitter);@@ -172,7 +172,7 @@ class Helper {const helper = new Helper();-class EventWatcher {+export class EventWatcher {constructor(receiver, eventNames, pendingEventWatchers = new Set()) {this._pendingEventWatchers = pendingEventWatchers;this._pendingEventWatchers.add(this);@@ -233,7 +233,3 @@ class EventWatcher {}}-var EXPORTED_SYMBOLS = [ "Helper", "EventWatcher" ];-this.Helper = Helper;-this.EventWatcher = EventWatcher;-diff --git a/browser_patches/firefox/juggler/JugglerFrameParent.jsm b/browser_patches/firefox/juggler/JugglerFrameParent.jsmindex e621fab240..9c3b588989 100644--- a/browser_patches/firefox/juggler/JugglerFrameParent.jsm+++ b/browser_patches/firefox/juggler/JugglerFrameParent.jsm@@ -1,13 +1,11 @@"use strict";-const { TargetRegistry } = ChromeUtils.import('chrome://juggler/content/TargetRegistry.js');-const { Helper } = ChromeUtils.import('chrome://juggler/content/Helper.js');+const { TargetRegistry } = ChromeUtils.importESModule('chrome://juggler/content/TargetRegistry.js');+const { Helper } = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');const helper = new Helper();-var EXPORTED_SYMBOLS = ['JugglerFrameParent'];--class JugglerFrameParent extends JSWindowActorParent {+export class JugglerFrameParent extends JSWindowActorParent {constructor() {super();}diff --git a/browser_patches/firefox/juggler/NetworkObserver.js b/browser_patches/firefox/juggler/NetworkObserver.jsindex 3fc9368d81..e3df3b15b7 100644--- a/browser_patches/firefox/juggler/NetworkObserver.js+++ b/browser_patches/firefox/juggler/NetworkObserver.js@@ -4,9 +4,9 @@"use strict";-const {Helper} = ChromeUtils.import('chrome://juggler/content/Helper.js');-const {NetUtil} = ChromeUtils.import('resource://gre/modules/NetUtil.jsm');-const { ChannelEventSinkFactory } = ChromeUtils.import("chrome://remote/content/cdp/observers/ChannelEventSink.jsm");+const {Helper} = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');+const {NetUtil} = ChromeUtils.importESModule('resource://gre/modules/NetUtil.sys.mjs');+const { ChannelEventSinkFactory } = ChromeUtils.importESModule("chrome://remote/content/cdp/observers/ChannelEventSink.sys.mjs");const Cc = Components.classes;@@ -28,7 +28,7 @@ const MAX_RESPONSE_STORAGE_SIZE = 100 * 1024 * 1024;const pageNetworkSymbol = Symbol('PageNetwork');-class PageNetwork {+export class PageNetwork {static forPageTarget(target) {if (!target)return undefined;@@ -143,9 +143,10 @@ class NetworkRequest {const target = this._networkObserver._targetRegistry.targetForBrowserId(browsingContext.browserId);this._pageNetwork = PageNetwork.forPageTarget(target);}- this._expectingInterception = false;+ this._shouldYieldInterceptionToServiceWorker = false;this._expectingResumedRequest = undefined; // { method, headers, postData }this._overriddenHeadersForRedirect = redirectedFrom?._overriddenHeadersForRedirect;+ this._sentOnRequest = false;this._sentOnResponse = false;this._fulfilled = false;@@ -318,9 +319,8 @@ class NetworkRequest {const interceptController = this._fallThroughInterceptController();if (interceptController && interceptController.shouldPrepareForIntercept(aURI, channel)) {// We assume that interceptController is a service worker if there is one,- // and yield interception to it. We are not going to intercept ourselves,- // so we send onRequest now.- this._sendOnRequest(false);+ // and yield interception to it.+ this._shouldYieldInterceptionToServiceWorker = true;return true;}@@ -329,12 +329,6 @@ class NetworkRequest {return false;}- // We do not want to intercept any redirects, because we are not able- // to intercept subresource redirects, and it's unreliable for main requests.- // We do not sendOnRequest here, because redirects do that in constructor.- if (this.redirectedFromId)- return false;-const shouldIntercept = this._shouldIntercept();if (!shouldIntercept) {// We are not intercepting - ready to issue onRequest.@@ -342,21 +336,24 @@ class NetworkRequest {return false;}- this._expectingInterception = true;return true;}// nsINetworkInterceptControllerchannelIntercepted(intercepted) {- if (!this._expectingInterception) {- // We are not intercepting, fall-through.- const interceptController = this._fallThroughInterceptController();- if (interceptController)- interceptController.channelIntercepted(intercepted);+ // Yield to a service worker if determined so in shouldPrepareForIntercept().+ const serviceWorker = this._shouldYieldInterceptionToServiceWorker ? this._fallThroughInterceptController() : undefined;+ // Clear the flag to avoid an infinite loop. After service worker, we should intercept ourselves.+ this._shouldYieldInterceptionToServiceWorker = false;++ if (serviceWorker) {+ const interceptedChannel = intercepted.QueryInterface(Ci.nsIInterceptedChannel);+ // If service worker will not actually intercept the request, we want to be called again.+ interceptedChannel.interceptAfterServiceWorkerResets();+ serviceWorker.channelIntercepted(intercepted);return;}- this._expectingInterception = false;this._interceptedChannel = intercepted.QueryInterface(Ci.nsIInterceptedChannel);const pageNetwork = this._pageNetwork;@@ -410,6 +407,7 @@ class NetworkRequest {// See https://github.com/microsoft/playwright/issues/9418#issuecomment-944836244if (aRequest !== this.httpChannel)return;+ this._sendOnRequest(false);try {this._originalListener.onStartRequest(aRequest);} catch (e) {@@ -447,6 +445,10 @@ class NetworkRequest {}_shouldIntercept() {+ // We do not want to intercept any redirects, because we are not able+ // to intercept subresource redirects, and it's unreliable for main requests.+ if (this.redirectedFromId)+ return false;const pageNetwork = this._pageNetwork;if (!pageNetwork)return false;@@ -467,8 +469,15 @@ class NetworkRequest {}_sendOnRequest(isIntercepted) {- // Note: we call _sendOnRequest either after we intercepted the request,- // or at the first moment we know that we are not going to intercept.+ if (this._sentOnRequest) {+ // We can come here twice because:+ // - Redirects call _sendOnRequest in the constructor and from inside interception.+ // - All other requests might call _sendOnRequest from onStartRequest and from inside interception.+ // - All requests call _sendOnRequest from _sendOnResponse to avoid responses without requests.+ return;+ }+ this._sentOnRequest = true;+const pageNetwork = this._pageNetwork;if (!pageNetwork)return;@@ -491,11 +500,21 @@ class NetworkRequest {}_sendOnResponse(fromCache, opt_statusCode, opt_statusText) {+ // For internal redirects, and perhaps something else that we lack test coverage for,+ // we can arrive here before onStartRequest has fired. Make sure we+ // notify about the request first.+ this._sendOnRequest(false);+if (this._sentOnResponse) {- // We can come here twice because of internal redirects, e.g. service workers.+ // We can come here twice because of an internal redirect, for example:+ // - request was intercepted by a service worker;+ // - HSTS redirect;+ // - CORS preflight;+ // - who knows what else?return;}this._sentOnResponse = true;+const pageNetwork = this._pageNetwork;if (!pageNetwork)return;@@ -576,7 +595,7 @@ class NetworkRequest {}}-class NetworkObserver {+export class NetworkObserver {static instance() {return NetworkObserver._instance || null;}@@ -776,6 +795,10 @@ function clearRequestHeaders(httpChannel) {// We cannot remove the "host" header.if (header.name.toLowerCase() === 'host')continue;+ // Keep the "cookie" header. If there is an override, it will be set anyway.+ // Otherwise, we may delete a cookie that was set for a redirect.+ if (header.name.toLowerCase() === 'cookie')+ continue;httpChannel.setRequestHeader(header.name, '', false /* merge */);}}@@ -964,6 +987,3 @@ PageNetwork.Events = {RequestFailed: Symbol('PageNetwork.Events.RequestFailed'),};-var EXPORTED_SYMBOLS = ['NetworkObserver', 'PageNetwork'];-this.NetworkObserver = NetworkObserver;-this.PageNetwork = PageNetwork;diff --git a/browser_patches/firefox/juggler/SimpleChannel.js b/browser_patches/firefox/juggler/SimpleChannel.jsindex a4e1b19df4..cc555451cd 100644--- a/browser_patches/firefox/juggler/SimpleChannel.js+++ b/browser_patches/firefox/juggler/SimpleChannel.js@@ -79,7 +79,7 @@ class SimpleChannel {_setTimeout(cb, timeout) {// Lazy load on first call.- this._setTimeout = ChromeUtils.import('resource://gre/modules/Timer.jsm').setTimeout;+ this._setTimeout = ChromeUtils.importESModule('resource://gre/modules/Timer.sys.mjs').setTimeout;this._setTimeout(cb, timeout);}@@ -251,6 +251,3 @@ class SimpleChannel {}}}--var EXPORTED_SYMBOLS = ['SimpleChannel'];-this.SimpleChannel = SimpleChannel;diff --git a/browser_patches/firefox/juggler/TargetRegistry.js b/browser_patches/firefox/juggler/TargetRegistry.jsindex 2ffb53390d..4bdf162ab6 100644--- a/browser_patches/firefox/juggler/TargetRegistry.js+++ b/browser_patches/firefox/juggler/TargetRegistry.js@@ -2,12 +2,11 @@* License, v. 2.0. If a copy of the MPL was not distributed with this* file, You can obtain one at http://mozilla.org/MPL/2.0/. */-const {Helper} = ChromeUtils.import('chrome://juggler/content/Helper.js');-const {SimpleChannel} = ChromeUtils.import('chrome://juggler/content/SimpleChannel.js');-const {Preferences} = ChromeUtils.import("resource://gre/modules/Preferences.jsm");-const {ContextualIdentityService} = ChromeUtils.import("resource://gre/modules/ContextualIdentityService.jsm");-const {NetUtil} = ChromeUtils.import('resource://gre/modules/NetUtil.jsm');-const {AppConstants} = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");+const {Helper} = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');+const {Preferences} = ChromeUtils.importESModule("resource://gre/modules/Preferences.sys.mjs");+const {ContextualIdentityService} = ChromeUtils.importESModule("resource://gre/modules/ContextualIdentityService.sys.mjs");+const {NetUtil} = ChromeUtils.importESModule('resource://gre/modules/NetUtil.sys.mjs');+const {AppConstants} = ChromeUtils.importESModule("resource://gre/modules/AppConstants.sys.mjs");const Cr = Components.results;@@ -23,6 +22,7 @@ const ALL_PERMISSIONS = [let globalTabAndWindowActivationChain = Promise.resolve();// This is a workaround for https://github.com/microsoft/playwright/issues/34586+let didCreateFirstPage = false;let globalNewPageChain = Promise.resolve();class DownloadInterceptor {@@ -104,7 +104,7 @@ class DownloadInterceptor {const screencastService = Cc['@mozilla.org/juggler/screencast;1'].getService(Ci.nsIScreencastService);-class TargetRegistry {+export class TargetRegistry {static instance() {return TargetRegistry._instance || null;}@@ -310,61 +310,68 @@ class TargetRegistry {}async newPage({browserContextId}) {- const result = globalNewPageChain.then(async () => {- const browserContext = this.browserContextForId(browserContextId);- const features = "chrome,dialog=no,all";- // See _callWithURIToLoad in browser.js for the structure of window.arguments- // window.arguments[1]: unused (bug 871161)- // [2]: referrerInfo (nsIReferrerInfo)- // [3]: postData (nsIInputStream)- // [4]: allowThirdPartyFixup (bool)- // [5]: userContextId (int)- // [6]: originPrincipal (nsIPrincipal)- // [7]: originStoragePrincipal (nsIPrincipal)- // [8]: triggeringPrincipal (nsIPrincipal)- // [9]: allowInheritPrincipal (bool)- // [10]: csp (nsIContentSecurityPolicy)- // [11]: nsOpenWindowInfo- const args = Cc["@mozilla.org/array;1"].createInstance(Ci.nsIMutableArray);- const urlSupports = Cc["@mozilla.org/supports-string;1"].createInstance(- Ci.nsISupportsString- );- urlSupports.data = 'about:blank';- args.appendElement(urlSupports); // 0- args.appendElement(undefined); // 1- args.appendElement(undefined); // 2- args.appendElement(undefined); // 3- args.appendElement(undefined); // 4- const userContextIdSupports = Cc[- "@mozilla.org/supports-PRUint32;1"- ].createInstance(Ci.nsISupportsPRUint32);- userContextIdSupports.data = browserContext.userContextId;- args.appendElement(userContextIdSupports); // 5- args.appendElement(undefined); // 6- args.appendElement(undefined); // 7- args.appendElement(Services.scriptSecurityManager.getSystemPrincipal()); // 8-- const window = Services.ww.openWindow(null, AppConstants.BROWSER_CHROME_URL, '_blank', features, args);- await waitForWindowReady(window);- if (window.gBrowser.browsers.length !== 1)- throw new Error(`Unexpected number of tabs in the new window: ${window.gBrowser.browsers.length}`);- const browser = window.gBrowser.browsers[0];- let target = this._browserToTarget.get(browser);- while (!target) {- await helper.awaitEvent(this, TargetRegistry.Events.TargetCreated);- target = this._browserToTarget.get(browser);- }- browser.focus();- if (browserContext.crossProcessCookie.settings.timezoneId) {- if (await target.hasFailedToOverrideTimezone())- throw new Error('Failed to override timezone');- }- return target.id();- });+ // When creating the very first page, we cannot create multiple in parallel.+ // See https://github.com/microsoft/playwright/issues/34586.+ if (didCreateFirstPage)+ return this._newPageInternal({browserContextId});+ const result = globalNewPageChain.then(() => this._newPageInternal({browserContextId}));globalNewPageChain = result.catch(error => { /* swallow errors to keep chain running */ });return result;}+ async _newPageInternal({browserContextId}) {+ const browserContext = this.browserContextForId(browserContextId);+ const features = "chrome,dialog=no,all";+ // See _callWithURIToLoad in browser.js for the structure of window.arguments+ // window.arguments[1]: unused (bug 871161)+ // [2]: referrerInfo (nsIReferrerInfo)+ // [3]: postData (nsIInputStream)+ // [4]: allowThirdPartyFixup (bool)+ // [5]: userContextId (int)+ // [6]: originPrincipal (nsIPrincipal)+ // [7]: originStoragePrincipal (nsIPrincipal)+ // [8]: triggeringPrincipal (nsIPrincipal)+ // [9]: allowInheritPrincipal (bool)+ // [10]: csp (nsIContentSecurityPolicy)+ // [11]: nsOpenWindowInfo+ const args = Cc["@mozilla.org/array;1"].createInstance(Ci.nsIMutableArray);+ const urlSupports = Cc["@mozilla.org/supports-string;1"].createInstance(+ Ci.nsISupportsString+ );+ urlSupports.data = 'about:blank';+ args.appendElement(urlSupports); // 0+ args.appendElement(undefined); // 1+ args.appendElement(undefined); // 2+ args.appendElement(undefined); // 3+ args.appendElement(undefined); // 4+ const userContextIdSupports = Cc[+ "@mozilla.org/supports-PRUint32;1"+ ].createInstance(Ci.nsISupportsPRUint32);+ userContextIdSupports.data = browserContext.userContextId;+ args.appendElement(userContextIdSupports); // 5+ args.appendElement(undefined); // 6+ args.appendElement(undefined); // 7+ args.appendElement(Services.scriptSecurityManager.getSystemPrincipal()); // 8++ const window = Services.ww.openWindow(null, AppConstants.BROWSER_CHROME_URL, '_blank', features, args);+ await waitForWindowReady(window);+ if (window.gBrowser.browsers.length !== 1)+ throw new Error(`Unexpected number of tabs in the new window: ${window.gBrowser.browsers.length}`);+ const browser = window.gBrowser.browsers[0];+ let target = this._browserToTarget.get(browser);+ while (!target) {+ await helper.awaitEvent(this, TargetRegistry.Events.TargetCreated);+ target = this._browserToTarget.get(browser);+ }+ browser.focus();+ if (browserContext.crossProcessCookie.settings.timezoneId) {+ if (await target.hasFailedToOverrideTimezone())+ throw new Error('Failed to override timezone');+ }+ didCreateFirstPage = true;+ return target.id();+ }+targets() {return Array.from(this._browserToTarget.values());}@@ -378,7 +385,7 @@ class TargetRegistry {}}-class PageTarget {+export class PageTarget {constructor(registry, win, tab, browserContext, opener) {helper.decorateAsEventEmitter(this);@@ -1286,7 +1293,3 @@ TargetRegistry.Events = {DownloadFinished: Symbol('TargetRegistry.Events.DownloadFinished'),ScreencastStopped: Symbol('TargetRegistry.ScreencastStopped'),};--var EXPORTED_SYMBOLS = ['TargetRegistry', 'PageTarget'];-this.TargetRegistry = TargetRegistry;-this.PageTarget = PageTarget;diff --git a/browser_patches/firefox/juggler/components/Juggler.js b/browser_patches/firefox/juggler/components/Juggler.jsindex aa51a88879..6121c4d392 100644--- a/browser_patches/firefox/juggler/components/Juggler.js+++ b/browser_patches/firefox/juggler/components/Juggler.js@@ -2,16 +2,17 @@* License, v. 2.0. If a copy of the MPL was not distributed with this* file, You can obtain one at http://mozilla.org/MPL/2.0/. */-var EXPORTED_SYMBOLS = ["Juggler", "JugglerFactory"];--const {XPCOMUtils} = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");-const {ComponentUtils} = ChromeUtils.import("resource://gre/modules/ComponentUtils.jsm");-const {Dispatcher} = ChromeUtils.import("chrome://juggler/content/protocol/Dispatcher.js");-const {BrowserHandler} = ChromeUtils.import("chrome://juggler/content/protocol/BrowserHandler.js");-const {NetworkObserver} = ChromeUtils.import("chrome://juggler/content/NetworkObserver.js");-const {TargetRegistry} = ChromeUtils.import("chrome://juggler/content/TargetRegistry.js");-const {Helper} = ChromeUtils.import('chrome://juggler/content/Helper.js');-const {ActorManagerParent} = ChromeUtils.import('resource://gre/modules/ActorManagerParent.jsm');+// Load SimpleChannel in browser-process global.+Services.scriptloader.loadSubScript('chrome://juggler/content/SimpleChannel.js');++const {XPCOMUtils} = ChromeUtils.importESModule("resource://gre/modules/XPCOMUtils.sys.mjs");+const {ComponentUtils} = ChromeUtils.importESModule("resource://gre/modules/ComponentUtils.sys.mjs");+const {Dispatcher} = ChromeUtils.importESModule("chrome://juggler/content/protocol/Dispatcher.js");+const {BrowserHandler} = ChromeUtils.importESModule("chrome://juggler/content/protocol/BrowserHandler.js");+const {NetworkObserver} = ChromeUtils.importESModule("chrome://juggler/content/NetworkObserver.js");+const {TargetRegistry} = ChromeUtils.importESModule("chrome://juggler/content/TargetRegistry.js");+const {Helper} = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');+const {ActorManagerParent} = ChromeUtils.importESModule('resource://gre/modules/ActorManagerParent.sys.mjs');const helper = new Helper();const Cc = Components.classes;@@ -21,10 +22,10 @@ const Ci = Components.interfaces;ActorManagerParent.addJSWindowActors({JugglerFrame: {parent: {- moduleURI: 'chrome://juggler/content/JugglerFrameParent.jsm',+ esModuleURI: 'chrome://juggler/content/JugglerFrameParent.jsm',},child: {- moduleURI: 'chrome://juggler/content/content/JugglerFrameChild.jsm',+ esModuleURI: 'chrome://juggler/content/content/JugglerFrameChild.jsm',events: {// Normally, we instantiate an actor when a new window is created.DOMWindowCreated: {},@@ -45,7 +46,7 @@ ActorManagerParent.addJSWindowActors({let browserStartupFinishedCallback;let browserStartupFinishedPromise = new Promise(x => browserStartupFinishedCallback = x);-class Juggler {+export class Juggler {get classDescription() { return "Sample command-line handler"; }get classID() { return Components.ID('{f7a74a33-e2ab-422d-b022-4fb213dd2639}'); }get contractID() { return "@mozilla.org/remote/juggler;1" }@@ -154,7 +155,7 @@ class Juggler {const jugglerInstance = new Juggler();// This is used by the XPCOM codepath which expects a constructor-var JugglerFactory = function() {+export var JugglerFactory = function() {return jugglerInstance;};diff --git a/browser_patches/firefox/juggler/components/components.conf b/browser_patches/firefox/juggler/components/components.confindex e5bc6523b1..955b38ab9c 100644--- a/browser_patches/firefox/juggler/components/components.conf+++ b/browser_patches/firefox/juggler/components/components.conf@@ -11,7 +11,7 @@ Classes = ["command-line-handler": "m-remote","profile-after-change": "Juggler",},- "jsm": "chrome://juggler/content/components/Juggler.js",+ "esModule": "chrome://juggler/content/components/Juggler.js","constructor": "JugglerFactory",},]diff --git a/browser_patches/firefox/juggler/content/FrameTree.js b/browser_patches/firefox/juggler/content/FrameTree.jsindex 721f392b9b..09a95b3548 100644--- a/browser_patches/firefox/juggler/content/FrameTree.js+++ b/browser_patches/firefox/juggler/content/FrameTree.js@@ -7,13 +7,11 @@ const Ci = Components.interfaces;const Cr = Components.results;const Cu = Components.utils;-const {Helper} = ChromeUtils.import('chrome://juggler/content/Helper.js');-const {SimpleChannel} = ChromeUtils.import('chrome://juggler/content/SimpleChannel.js');-const {Runtime} = ChromeUtils.import('chrome://juggler/content/content/Runtime.js');+const {Helper} = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');const helper = new Helper();-class FrameTree {+export class FrameTree {constructor(rootBrowsingContext) {helper.decorateAsEventEmitter(this);@@ -690,6 +688,3 @@ function channelId(channel) {}-var EXPORTED_SYMBOLS = ['FrameTree'];-this.FrameTree = FrameTree;-diff --git a/browser_patches/firefox/juggler/content/JugglerFrameChild.jsm b/browser_patches/firefox/juggler/content/JugglerFrameChild.jsmindex 05d91473d3..af060c57aa 100644--- a/browser_patches/firefox/juggler/content/JugglerFrameChild.jsm+++ b/browser_patches/firefox/juggler/content/JugglerFrameChild.jsm@@ -1,7 +1,7 @@"use strict";-const { Helper } = ChromeUtils.import('chrome://juggler/content/Helper.js');-const { initialize } = ChromeUtils.import('chrome://juggler/content/content/main.js');+const { Helper } = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');+const { initialize } = ChromeUtils.importESModule('chrome://juggler/content/content/main.js');const Ci = Components.interfaces;const helper = new Helper();@@ -10,7 +10,7 @@ let sameProcessInstanceNumber = 0;const topBrowingContextToAgents = new Map();-class JugglerFrameChild extends JSWindowActorChild {+export class JugglerFrameChild extends JSWindowActorChild {constructor() {super();@@ -83,4 +83,3 @@ class JugglerFrameChild extends JSWindowActorChild {receiveMessage() { }}-var EXPORTED_SYMBOLS = ['JugglerFrameChild'];diff --git a/browser_patches/firefox/juggler/content/PageAgent.js b/browser_patches/firefox/juggler/content/PageAgent.jsindex 255b84f726..2ff5e6b922 100644--- a/browser_patches/firefox/juggler/content/PageAgent.js+++ b/browser_patches/firefox/juggler/content/PageAgent.js@@ -8,9 +8,9 @@ const Ci = Components.interfaces;const Cr = Components.results;const Cu = Components.utils;-const {Helper} = ChromeUtils.import('chrome://juggler/content/Helper.js');-const {NetUtil} = ChromeUtils.import('resource://gre/modules/NetUtil.jsm');-const {setTimeout} = ChromeUtils.import('resource://gre/modules/Timer.jsm');+const {Helper} = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');+const {NetUtil} = ChromeUtils.importESModule('resource://gre/modules/NetUtil.sys.mjs');+const {setTimeout} = ChromeUtils.importESModule('resource://gre/modules/Timer.sys.mjs');const dragService = Cc["@mozilla.org/widget/dragservice;1"].getService(Ci.nsIDragService@@ -51,7 +51,7 @@ class WorkerData {}}-class PageAgent {+export class PageAgent {constructor(browserChannel, frameTree) {this._browserChannel = browserChannel;this._browserPage = browserChannel.connect('page');@@ -575,7 +575,7 @@ class PageAgent {// We crash by using js-ctypes and dereferencing// a bad pointer. The crash should happen immediately// upon loading this frame script.- const { ctypes } = ChromeUtils.import('resource://gre/modules/ctypes.jsm');+ const { ctypes } = ChromeUtils.importESModule('resource://gre/modules/ctypes.sys.mjs');ChromeUtils.privateNoteIntentionalCrash();const zero = new ctypes.intptr_t(8);const badptr = ctypes.cast(zero, ctypes.PointerType(ctypes.int32_t));@@ -709,6 +709,3 @@ class PageAgent {}}-var EXPORTED_SYMBOLS = ['PageAgent'];-this.PageAgent = PageAgent;-diff --git a/browser_patches/firefox/juggler/content/Runtime.js b/browser_patches/firefox/juggler/content/Runtime.jsindex a5fa7a03dd..ad8720a1d3 100644--- a/browser_patches/firefox/juggler/content/Runtime.js+++ b/browser_patches/firefox/juggler/content/Runtime.js@@ -8,8 +8,8 @@if (!this.Debugger) {// Worker has a Debugger defined already.- const {addDebuggerToGlobal} = ChromeUtils.import("resource://gre/modules/jsdebugger.jsm", {});- addDebuggerToGlobal(Components.utils.getGlobalForObject(this));+ const {addDebuggerToGlobal} = ChromeUtils.importESModule("resource://gre/modules/jsdebugger.sys.mjs");+ addDebuggerToGlobal(Components.utils.getGlobalForObject(globalThis));}let lastId = 0;@@ -596,5 +596,5 @@ function emitEvent(event, ...args) {listener.call(null, ...args);}-var EXPORTED_SYMBOLS = ['Runtime'];-this.Runtime = Runtime;+// Export Runtime to global.+globalThis.Runtime = Runtime;diff --git a/browser_patches/firefox/juggler/content/main.js b/browser_patches/firefox/juggler/content/main.jsindex 7eaa704059..68fb364ead 100644--- a/browser_patches/firefox/juggler/content/main.js+++ b/browser_patches/firefox/juggler/content/main.js@@ -2,14 +2,20 @@* License, v. 2.0. If a copy of the MPL was not distributed with this* file, You can obtain one at http://mozilla.org/MPL/2.0/. */-const {Helper} = ChromeUtils.import('chrome://juggler/content/Helper.js');-const {FrameTree} = ChromeUtils.import('chrome://juggler/content/content/FrameTree.js');-const {SimpleChannel} = ChromeUtils.import('chrome://juggler/content/SimpleChannel.js');-const {PageAgent} = ChromeUtils.import('chrome://juggler/content/content/PageAgent.js');+// Load SimpleChannel and Runtime in content process's global.+// NOTE: since these have to exist in both Worker and main threads, and we do+// not know a way to load ES Modules in worker threads, we have to use the loadSubScript+// utility instead.+Services.scriptloader.loadSubScript('chrome://juggler/content/SimpleChannel.js');+Services.scriptloader.loadSubScript('chrome://juggler/content/content/Runtime.js');++const {Helper} = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');+const {FrameTree} = ChromeUtils.importESModule('chrome://juggler/content/content/FrameTree.js');+const {PageAgent} = ChromeUtils.importESModule('chrome://juggler/content/content/PageAgent.js');const helper = new Helper();-function initialize(browsingContext, docShell) {+export function initialize(browsingContext, docShell) {const data = { channel: undefined, pageAgent: undefined, frameTree: undefined, failedToOverrideTimezone: false };const applySetting = {@@ -114,6 +120,3 @@ function initialize(browsingContext, docShell) {return data;}--var EXPORTED_SYMBOLS = ['initialize'];-this.initialize = initialize;diff --git a/browser_patches/firefox/juggler/protocol/BrowserHandler.js b/browser_patches/firefox/juggler/protocol/BrowserHandler.jsindex e92b6dfefe..035a53bb68 100644--- a/browser_patches/firefox/juggler/protocol/BrowserHandler.js+++ b/browser_patches/firefox/juggler/protocol/BrowserHandler.js@@ -4,15 +4,15 @@"use strict";-const {AddonManager} = ChromeUtils.import("resource://gre/modules/AddonManager.jsm");-const {TargetRegistry} = ChromeUtils.import("chrome://juggler/content/TargetRegistry.js");-const {Helper} = ChromeUtils.import('chrome://juggler/content/Helper.js');-const {PageHandler} = ChromeUtils.import("chrome://juggler/content/protocol/PageHandler.js");-const {AppConstants} = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");+const {AddonManager} = ChromeUtils.importESModule("resource://gre/modules/AddonManager.sys.mjs");+const {TargetRegistry} = ChromeUtils.importESModule("chrome://juggler/content/TargetRegistry.js");+const {Helper} = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');+const {PageHandler} = ChromeUtils.importESModule("chrome://juggler/content/protocol/PageHandler.js");+const {AppConstants} = ChromeUtils.importESModule("resource://gre/modules/AppConstants.sys.mjs");const helper = new Helper();-class BrowserHandler {+export class BrowserHandler {constructor(session, dispatcher, targetRegistry, startCompletePromise, onclose) {this._session = session;this._dispatcher = dispatcher;@@ -313,6 +313,3 @@ async function waitForWindowClosed(browserWindow) {function nullToUndefined(value) {return value === null ? undefined : value;}--var EXPORTED_SYMBOLS = ['BrowserHandler'];-this.BrowserHandler = BrowserHandler;diff --git a/browser_patches/firefox/juggler/protocol/Dispatcher.js b/browser_patches/firefox/juggler/protocol/Dispatcher.jsindex 8542461d52..7a65d0a117 100644--- a/browser_patches/firefox/juggler/protocol/Dispatcher.js+++ b/browser_patches/firefox/juggler/protocol/Dispatcher.js@@ -2,12 +2,13 @@* License, v. 2.0. If a copy of the MPL was not distributed with this* file, You can obtain one at http://mozilla.org/MPL/2.0/. */-const {protocol, checkScheme} = ChromeUtils.import("chrome://juggler/content/protocol/Protocol.js");-const {Helper} = ChromeUtils.import('chrome://juggler/content/Helper.js');+const {protocol} = ChromeUtils.importESModule("chrome://juggler/content/protocol/Protocol.js");+const {checkScheme} = ChromeUtils.importESModule("chrome://juggler/content/protocol/PrimitiveTypes.js");+const {Helper} = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');const helper = new Helper();-class Dispatcher {+export class Dispatcher {/*** @param {Connection} connection*/@@ -132,7 +133,3 @@ class ProtocolSession {return await this._handler[method](params);}}--this.EXPORTED_SYMBOLS = ['Dispatcher'];-this.Dispatcher = Dispatcher;-diff --git a/browser_patches/firefox/juggler/protocol/PageHandler.js b/browser_patches/firefox/juggler/protocol/PageHandler.jsindex 5892c88603..1dab7d8803 100644--- a/browser_patches/firefox/juggler/protocol/PageHandler.js+++ b/browser_patches/firefox/juggler/protocol/PageHandler.js@@ -4,11 +4,11 @@"use strict";-const {Helper, EventWatcher} = ChromeUtils.import('chrome://juggler/content/Helper.js');-const {NetUtil} = ChromeUtils.import('resource://gre/modules/NetUtil.jsm');-const {NetworkObserver, PageNetwork} = ChromeUtils.import('chrome://juggler/content/NetworkObserver.js');-const {PageTarget} = ChromeUtils.import('chrome://juggler/content/TargetRegistry.js');-const {setTimeout} = ChromeUtils.import('resource://gre/modules/Timer.jsm');+const {Helper, EventWatcher} = ChromeUtils.importESModule('chrome://juggler/content/Helper.js');+const {NetUtil} = ChromeUtils.importESModule('resource://gre/modules/NetUtil.sys.mjs');+const {NetworkObserver, PageNetwork} = ChromeUtils.importESModule('chrome://juggler/content/NetworkObserver.js');+const {PageTarget} = ChromeUtils.importESModule('chrome://juggler/content/TargetRegistry.js');+const {setTimeout} = ChromeUtils.importESModule('resource://gre/modules/Timer.sys.mjs');const Cc = Components.classes;const Ci = Components.interfaces;@@ -65,7 +65,7 @@ class WorkerHandler {}}-class PageHandler {+export class PageHandler {constructor(target, session, contentChannel) {this._session = session;this._contentChannel = contentChannel;@@ -691,6 +691,3 @@ class PageHandler {return await worker.sendMessage(JSON.parse(message));}}--var EXPORTED_SYMBOLS = ['PageHandler'];-this.PageHandler = PageHandler;diff --git a/browser_patches/firefox/juggler/protocol/PrimitiveTypes.js b/browser_patches/firefox/juggler/protocol/PrimitiveTypes.jsindex 5799038f19..ca6d1ec4f6 100644--- a/browser_patches/firefox/juggler/protocol/PrimitiveTypes.js+++ b/browser_patches/firefox/juggler/protocol/PrimitiveTypes.js@@ -2,7 +2,7 @@* License, v. 2.0. If a copy of the MPL was not distributed with this* file, You can obtain one at http://mozilla.org/MPL/2.0/. */-const t = {};+export const t = {};t.String = function(x, details = {}, path = ['<root>']) {if (typeof x === 'string' || typeof x === 'String')@@ -96,7 +96,7 @@ function beauty(path, obj) {return `property "${path.join('.')}" - ${JSON.stringify(obj, null, 2)}`;}-function checkScheme(scheme, x, details = {}, path = ['<root>']) {+export function checkScheme(scheme, x, details = {}, path = ['<root>']) {if (!scheme)throw new Error(`ILLDEFINED SCHEME: ${path.join('.')}`);if (typeof scheme === 'object') {@@ -142,6 +142,3 @@ test(t.Either(t.String, t.Number), {});*/-this.t = t;-this.checkScheme = checkScheme;-this.EXPORTED_SYMBOLS = ['t', 'checkScheme'];diff --git a/browser_patches/firefox/juggler/protocol/Protocol.js b/browser_patches/firefox/juggler/protocol/Protocol.jsindex f18dff61bf..4cb44d679c 100644--- a/browser_patches/firefox/juggler/protocol/Protocol.js+++ b/browser_patches/firefox/juggler/protocol/Protocol.js@@ -2,7 +2,7 @@* License, v. 2.0. If a copy of the MPL was not distributed with this* file, You can obtain one at http://mozilla.org/MPL/2.0/. */-const {t, checkScheme} = ChromeUtils.import('chrome://juggler/content/protocol/PrimitiveTypes.js');+const {t} = ChromeUtils.importESModule('chrome://juggler/content/protocol/PrimitiveTypes.js');// Protocol-specific types.const browserTypes = {};@@ -1018,8 +1018,6 @@ const Accessibility = {}}-this.protocol = {+export const protocol = {domains: {Browser, Heap, Page, Runtime, Network, Accessibility},};-this.checkScheme = checkScheme;-this.EXPORTED_SYMBOLS = ['protocol', 'checkScheme'];diff --git a/browser_patches/firefox/patches/bootstrap.diff b/browser_patches/firefox/patches/bootstrap.diffindex 094a734019..8cb0e71d92 100644--- a/browser_patches/firefox/patches/bootstrap.diff+++ b/browser_patches/firefox/patches/bootstrap.diff@@ -89,7 +89,7 @@ index 8167d2b81c918e02ce757f7f448f22e07c29d140..3ae798880acfd8aa965ae08051f2f818DWORD creationFlags = CREATE_SUSPENDED | CREATE_UNICODE_ENVIRONMENT;diff --git a/browser/installer/allowed-dupes.mn b/browser/installer/allowed-dupes.mn-index 213a99ed433d5219c2b9a64baad82d14cdbcd432..ee4f6484cdfe80899c28a1d9607494e520bfc93d 100644+index a097c2c56a665204ff7b5593c7faf836366801cf..235a4e224e08c22870c6913e335f0b6020b3e7da 100644--- a/browser/installer/allowed-dupes.mn+++ b/browser/installer/allowed-dupes.mn@@ -67,6 +67,12 @@ browser/features/[email protected]/shims/empty-shim.txt@@ -106,7 +106,7 @@ index 213a99ed433d5219c2b9a64baad82d14cdbcd432..ee4f6484cdfe80899c28a1d9607494e5browser/chrome/browser/content/activity-stream/data/content/tippytop/favicons/allegro-pl.icobrowser/defaults/settings/main/search-config-icons/96327a73-c433-5eb4-a16d-b090cadfb80bdiff --git a/browser/installer/package-manifest.in b/browser/installer/package-manifest.in-index beae3018bb533529555496433b90403827ba07fc..3f3c750f4cef768b5429492c0077616505262cb9 100644+index 89cff6b562a82bd3a9a5d268abd4373199b31fac..e58dbf0ab0b06e84f6dac64698d11c6268091204 100644--- a/browser/installer/package-manifest.in+++ b/browser/installer/package-manifest.in@@ -196,6 +196,9 @@@@ -167,10 +167,10 @@ index d49c6fbf1bf83b832795fa674f6b41f223eef812..7ea3540947ff5f61b15f27fbf4b95564const transportProvider = {setListener(upgradeListener) {diff --git a/docshell/base/BrowsingContext.cpp b/docshell/base/BrowsingContext.cpp-index 28e9d14bd7979798025f9fc30d9a45527488c34c..d6abf1c3e7e2b2cdfd51351ced4aa6fb0d51327b 100644+index 2425779a7767e9350ee2afc4aea111a090c7f909..393eb86bf2d9a8f778bfce560a9fb3bf528ba558 100644--- a/docshell/base/BrowsingContext.cpp+++ b/docshell/base/BrowsingContext.cpp-@@ -106,8 +106,15 @@ struct ParamTraits<mozilla::dom::DisplayMode>+@@ -108,8 +108,15 @@ struct ParamTraits<mozilla::dom::DisplayMode>template <>struct ParamTraits<mozilla::dom::PrefersColorSchemeOverride>@@ -188,7 +188,7 @@ index 28e9d14bd7979798025f9fc30d9a45527488c34c..d6abf1c3e7e2b2cdfd51351ced4aa6fbtemplate <>struct ParamTraits<mozilla::dom::ForcedColorsOverride>-@@ -2887,6 +2894,32 @@ void BrowsingContext::DidSet(FieldIndex<IDX_ForcedColorsOverride>,+@@ -2891,6 +2898,32 @@ void BrowsingContext::DidSet(FieldIndex<IDX_ForcedColorsOverride>,PresContextAffectingFieldChanged();}@@ -222,7 +222,7 @@ index 28e9d14bd7979798025f9fc30d9a45527488c34c..d6abf1c3e7e2b2cdfd51351ced4aa6fbnsString&& aOldValue) {MOZ_ASSERT(IsTop());diff --git a/docshell/base/BrowsingContext.h b/docshell/base/BrowsingContext.h-index 13815ddf7e13825970cafda19ca24412a5150b53..71c7ae2fce1d92614a60b2aba85bbd70629f682f 100644+index eb183cb5c0751e43ea674f9e52441a5a82f186e0..79c5d8110faa89779dd0c16ba00620e7e65d06f5 100644--- a/docshell/base/BrowsingContext.h+++ b/docshell/base/BrowsingContext.h@@ -203,10 +203,10 @@ struct EmbedderColorSchemes {@@ -248,7 +248,7 @@ index 13815ddf7e13825970cafda19ca24412a5150b53..71c7ae2fce1d92614a60b2aba85bbd70/* The number of entries added to the session history because of this \* browsing context. */ \FIELD(HistoryEntryCount, uint32_t) \-@@ -948,6 +951,14 @@ class BrowsingContext : public nsILoadContext, public nsWrapperCache {+@@ -950,6 +953,14 @@ class BrowsingContext : public nsILoadContext, public nsWrapperCache {return GetForcedColorsOverride();}@@ -263,7 +263,7 @@ index 13815ddf7e13825970cafda19ca24412a5150b53..71c7ae2fce1d92614a60b2aba85bbd70bool IsInBFCache() const;bool AllowJavascript() const { return GetAllowJavascript(); }-@@ -1107,6 +1118,11 @@ class BrowsingContext : public nsILoadContext, public nsWrapperCache {+@@ -1112,6 +1123,11 @@ class BrowsingContext : public nsILoadContext, public nsWrapperCache {return IsTop();}@@ -275,7 +275,7 @@ index 13815ddf7e13825970cafda19ca24412a5150b53..71c7ae2fce1d92614a60b2aba85bbd70bool CanSet(FieldIndex<IDX_ForcedColorsOverride>, dom::ForcedColorsOverride,ContentParent*) {return IsTop();-@@ -1125,10 +1141,22 @@ class BrowsingContext : public nsILoadContext, public nsWrapperCache {+@@ -1130,10 +1146,22 @@ class BrowsingContext : public nsILoadContext, public nsWrapperCache {void DidSet(FieldIndex<IDX_ForcedColorsOverride>,dom::ForcedColorsOverride aOldValue);@@ -299,10 +299,10 @@ index 13815ddf7e13825970cafda19ca24412a5150b53..71c7ae2fce1d92614a60b2aba85bbd70bool CanSet(FieldIndex<IDX_SuspendMediaWhenInactive>, bool, ContentParent*) {diff --git a/docshell/base/CanonicalBrowsingContext.cpp b/docshell/base/CanonicalBrowsingContext.cpp-index 671a12de84d3b01c4331dbbb2fac050ce061cda1..afcd95e77185e6d606503b7c01d6ab48cc236cc8 100644+index bef42c91d6f88922c8c101f3675325d828872aaf..8eb68c441fbef8ecbe5e90c118ccc00813564577 100644--- a/docshell/base/CanonicalBrowsingContext.cpp+++ b/docshell/base/CanonicalBrowsingContext.cpp-@@ -323,6 +323,8 @@ void CanonicalBrowsingContext::ReplacedBy(+@@ -324,6 +324,8 @@ void CanonicalBrowsingContext::ReplacedBy(txn.SetShouldDelayMediaFromStart(GetShouldDelayMediaFromStart());txn.SetForceOffline(GetForceOffline());txn.SetTopInnerSizeForRFP(GetTopInnerSizeForRFP());@@ -311,7 +311,7 @@ index 671a12de84d3b01c4331dbbb2fac050ce061cda1..afcd95e77185e6d606503b7c01d6ab48// Propagate some settings on BrowsingContext replacement so they're not lost// on bfcached navigations. These are important for GeckoView (see bug-@@ -1600,6 +1602,12 @@ void CanonicalBrowsingContext::LoadURI(nsIURI* aURI,+@@ -1635,6 +1637,12 @@ void CanonicalBrowsingContext::LoadURI(nsIURI* aURI,return;}@@ -325,7 +325,7 @@ index 671a12de84d3b01c4331dbbb2fac050ce061cda1..afcd95e77185e6d606503b7c01d6ab48}diff --git a/docshell/base/nsDocShell.cpp b/docshell/base/nsDocShell.cpp-index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af15704738700b0e14f 100644+index 32c537d6be90247af8d778048c6d27f3800d4b02..b72196b0694828489f8ad27c209f49f0d41c43cb 100644--- a/docshell/base/nsDocShell.cpp+++ b/docshell/base/nsDocShell.cpp@@ -15,6 +15,12 @@@@ -348,16 +348,16 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387+#include "mozilla/dom/Geolocation.h"#include "mozilla/dom/HTMLAnchorElement.h"#include "mozilla/dom/HTMLIFrameElement.h"- #include "mozilla/dom/PerformanceNavigation.h"-@@ -90,6 +97,7 @@- #include "mozilla/dom/JSWindowActorChild.h"+ #include "mozilla/dom/Navigation.h"+@@ -94,6 +101,7 @@#include "mozilla/dom/DocumentBinding.h"+ #include "mozilla/glean/DocshellMetrics.h"#include "mozilla/ipc/ProtocolUtils.h"+#include "mozilla/dom/WorkerCommon.h"#include "mozilla/net/DocumentChannel.h"#include "mozilla/net/DocumentChannelChild.h"#include "mozilla/net/ParentChannelWrapper.h"-@@ -113,6 +121,7 @@+@@ -117,6 +125,7 @@#include "nsIDocumentViewer.h"#include "mozilla/dom/Document.h"#include "nsHTMLDocument.h"@@ -365,7 +365,7 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387#include "nsIDocumentLoaderFactory.h"#include "nsIDOMWindow.h"#include "nsIEditingSession.h"-@@ -207,6 +216,7 @@+@@ -211,6 +220,7 @@#include "nsGlobalWindowInner.h"#include "nsGlobalWindowOuter.h"#include "nsJSEnvironment.h"@@ -373,7 +373,7 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387#include "nsNetCID.h"#include "nsNetUtil.h"#include "nsObjectLoadingContent.h"-@@ -347,6 +357,14 @@ nsDocShell::nsDocShell(BrowsingContext* aBrowsingContext,+@@ -352,6 +362,14 @@ nsDocShell::nsDocShell(BrowsingContext* aBrowsingContext,mAllowDNSPrefetch(true),mAllowWindowControl(true),mCSSErrorReportingEnabled(false),@@ -388,7 +388,7 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387mAllowAuth(mItemType == typeContent),mAllowKeywordFixup(false),mDisableMetaRefreshWhenInactive(false),-@@ -3019,6 +3037,232 @@ nsDocShell::GetMessageManager(ContentFrameMessageManager** aMessageManager) {+@@ -3024,6 +3042,232 @@ nsDocShell::GetMessageManager(ContentFrameMessageManager** aMessageManager) {return NS_OK;}@@ -621,7 +621,7 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387NS_IMETHODIMPnsDocShell::GetIsNavigating(bool* aOut) {*aOut = mIsNavigating;-@@ -4715,7 +4959,7 @@ nsDocShell::GetVisibility(bool* aVisibility) {+@@ -4731,7 +4975,7 @@ nsDocShell::GetVisibility(bool* aVisibility) {}void nsDocShell::ActivenessMaybeChanged() {@@ -630,7 +630,7 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387if (RefPtr<PresShell> presShell = GetPresShell()) {presShell->ActivenessMaybeChanged();}-@@ -6639,6 +6883,10 @@ bool nsDocShell::CanSavePresentation(uint32_t aLoadType,+@@ -6658,6 +6902,10 @@ bool nsDocShell::CanSavePresentation(uint32_t aLoadType,return false; // no entry to save into}@@ -641,7 +641,7 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387MOZ_ASSERT(!mozilla::SessionHistoryInParent(),"mOSHE cannot be non-null with SHIP");nsCOMPtr<nsIDocumentViewer> viewer = mOSHE->GetDocumentViewer();-@@ -8377,6 +8625,12 @@ nsresult nsDocShell::PerformRetargeting(nsDocShellLoadState* aLoadState) {+@@ -8399,6 +8647,12 @@ nsresult nsDocShell::PerformRetargeting(nsDocShellLoadState* aLoadState) {true, // aForceNoOpenergetter_AddRefs(newBC));MOZ_ASSERT(!newBC);@@ -654,7 +654,7 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387return rv;}-@@ -9531,6 +9785,16 @@ nsresult nsDocShell::InternalLoad(nsDocShellLoadState* aLoadState,+@@ -9572,6 +9826,16 @@ nsresult nsDocShell::InternalLoad(nsDocShellLoadState* aLoadState,nsINetworkPredictor::PREDICT_LOAD, attrs, nullptr);nsCOMPtr<nsIRequest> req;@@ -671,7 +671,7 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387rv = DoURILoad(aLoadState, aCacheKey, getter_AddRefs(req));if (NS_SUCCEEDED(rv)) {-@@ -12733,6 +12997,9 @@ class OnLinkClickEvent : public Runnable {+@@ -12791,6 +13055,9 @@ class OnLinkClickEvent : public Runnable {mHandler->OnLinkClickSync(mContent, mLoadState, mNoOpenerImplied,mTriggeringPrincipal);}@@ -681,7 +681,7 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387return NS_OK;}-@@ -12819,6 +13086,8 @@ nsresult nsDocShell::OnLinkClick(+@@ -12877,6 +13144,8 @@ nsresult nsDocShell::OnLinkClick(nsCOMPtr<nsIRunnable> ev = new OnLinkClickEvent(this, aContent, loadState, noOpenerImplied, aTriggeringPrincipal);@@ -691,7 +691,7 @@ index f3069febc1bd9f3ff6acbe162b5475963e004e6c..65ab560c9f13c837c9ed6af157047387}diff --git a/docshell/base/nsDocShell.h b/docshell/base/nsDocShell.h-index 888741f8490d6f0e885ed0ce73115c16e7bbe821..9cb32a1ec61bc4cb67f5fc5bb1fa723055bb1eaa 100644+index f22a333733322ad17f097d7edd46af21a687906c..6bcf8ca9f9cd64dc9f5695d00e0a3e6a97978f02 100644--- a/docshell/base/nsDocShell.h+++ b/docshell/base/nsDocShell.h@@ -15,6 +15,7 @@@@ -702,7 +702,7 @@ index 888741f8490d6f0e885ed0ce73115c16e7bbe821..9cb32a1ec61bc4cb67f5fc5bb1fa7230#include "mozilla/dom/WindowProxyHolder.h"#include "nsCOMPtr.h"#include "nsCharsetSource.h"-@@ -76,6 +77,7 @@ class nsCommandManager;+@@ -77,6 +78,7 @@ class nsCommandManager;class nsDocShellEditorData;class nsDOMNavigationTiming;class nsDSURIContentListener;@@ -710,7 +710,7 @@ index 888741f8490d6f0e885ed0ce73115c16e7bbe821..9cb32a1ec61bc4cb67f5fc5bb1fa7230class nsGlobalWindowOuter;class FramingChecker;-@@ -402,6 +404,15 @@ class nsDocShell final : public nsDocLoader,+@@ -403,6 +405,15 @@ class nsDocShell final : public nsDocLoader,void SetWillChangeProcess() { mWillChangeProcess = true; }bool WillChangeProcess() { return mWillChangeProcess; }@@ -726,7 +726,7 @@ index 888741f8490d6f0e885ed0ce73115c16e7bbe821..9cb32a1ec61bc4cb67f5fc5bb1fa7230// Create a content viewer within this nsDocShell for the given// `WindowGlobalChild` actor.nsresult CreateDocumentViewerForActor(-@@ -1005,6 +1016,8 @@ class nsDocShell final : public nsDocLoader,+@@ -1006,6 +1017,8 @@ class nsDocShell final : public nsDocLoader,bool CSSErrorReportingEnabled() const { return mCSSErrorReportingEnabled; }@@ -735,7 +735,7 @@ index 888741f8490d6f0e885ed0ce73115c16e7bbe821..9cb32a1ec61bc4cb67f5fc5bb1fa7230// Handles retrieval of subframe session history for nsDocShell::LoadURI. If a// load is requested in a subframe of the current DocShell, the subframe// loadType may need to reflect the loadType of the parent document, or in-@@ -1282,6 +1295,17 @@ class nsDocShell final : public nsDocLoader,+@@ -1285,6 +1298,17 @@ class nsDocShell final : public nsDocLoader,bool mAllowDNSPrefetch : 1;bool mAllowWindowControl : 1;bool mCSSErrorReportingEnabled : 1;@@ -812,10 +812,10 @@ index 84e821e33e8164829dfee4f05340784e189b90ee..aa690eb747cb73bc6bff40a62546037c* This attempts to save any applicable layout history state (like* scroll position) in the nsISHEntry. This is normally donediff --git a/dom/base/Document.cpp b/dom/base/Document.cpp-index 46de7024c0e148c5bc9b90553f0ab7c961acdaae..4ce29d24b940940ba7eefab60ac2be55bb888f78 100644+index fd2d0be5f7755e64fc134515ea138c4ed0d28daf..ae48159ddbfb98d03e538d077a33260c639a74ac 100644--- a/dom/base/Document.cpp+++ b/dom/base/Document.cpp-@@ -3765,6 +3765,9 @@ void Document::SendToConsole(nsCOMArray<nsISecurityConsoleMessage>& aMessages) {+@@ -3752,6 +3752,9 @@ void Document::SendToConsole(nsCOMArray<nsISecurityConsoleMessage>& aMessages) {}void Document::ApplySettingsFromCSP(bool aSpeculative) {@@ -825,7 +825,7 @@ index 46de7024c0e148c5bc9b90553f0ab7c961acdaae..4ce29d24b940940ba7eefab60ac2be55nsresult rv = NS_OK;if (!aSpeculative) {// 1) apply settings from regular CSP-@@ -3822,6 +3825,11 @@ nsresult Document::InitCSP(nsIChannel* aChannel) {+@@ -3809,6 +3812,11 @@ nsresult Document::InitCSP(nsIChannel* aChannel) {MOZ_ASSERT(!mScriptGlobalObject,"CSP must be initialized before mScriptGlobalObject is set!");@@ -837,7 +837,7 @@ index 46de7024c0e148c5bc9b90553f0ab7c961acdaae..4ce29d24b940940ba7eefab60ac2be55// If this is a data document - no need to set CSP.if (mLoadedAsData) {return NS_OK;-@@ -4629,6 +4637,10 @@ bool Document::HasFocus(ErrorResult& rv) const {+@@ -4617,6 +4625,10 @@ bool Document::HasFocus(ErrorResult& rv) const {return false;}@@ -848,7 +848,7 @@ index 46de7024c0e148c5bc9b90553f0ab7c961acdaae..4ce29d24b940940ba7eefab60ac2be55if (!fm->IsInActiveWindow(bc)) {return false;}-@@ -19580,6 +19592,35 @@ ColorScheme Document::PreferredColorScheme(IgnoreRFP aIgnoreRFP) const {+@@ -19688,6 +19700,35 @@ ColorScheme Document::PreferredColorScheme(IgnoreRFP aIgnoreRFP) const {return PreferenceSheet::PrefsFor(*this).mColorScheme;}@@ -885,10 +885,10 @@ index 46de7024c0e148c5bc9b90553f0ab7c961acdaae..4ce29d24b940940ba7eefab60ac2be55if (!sLoadingForegroundTopLevelContentDocument) {return false;diff --git a/dom/base/Document.h b/dom/base/Document.h-index 7eb244d65eb55322fb16ed185be83cb731fc268c..3cfb3c17c1a769e4d0fc3fa76288c570822dc48f 100644+index 622f54e369d324a4cc2800dd4b331bd628339bed..2ef6ed20cf35febeff75b22dfa5bb2fbb4e295fe 100644--- a/dom/base/Document.h+++ b/dom/base/Document.h-@@ -4134,6 +4134,8 @@ class Document : public nsINode,+@@ -4140,6 +4140,8 @@ class Document : public nsINode,// color-scheme meta tag.ColorScheme DefaultColorScheme() const;@@ -898,7 +898,7 @@ index 7eb244d65eb55322fb16ed185be83cb731fc268c..3cfb3c17c1a769e4d0fc3fa76288c570static bool AutomaticStorageAccessPermissionCanBeGranted(diff --git a/dom/base/Navigator.cpp b/dom/base/Navigator.cpp-index 0f159ad09a2a4b8962307b9f20abf30323377a36..e0cbb3f1f8af42825696d7152eb9993ab3802f90 100644+index a13cae5b990fb2f750e62f5117ad63aa981d787f..bc0f2d674aadd8eba867f56e873595a8885d1798 100644--- a/dom/base/Navigator.cpp+++ b/dom/base/Navigator.cpp@@ -344,14 +344,18 @@ void Navigator::GetAppName(nsAString& aAppName) const {@@ -961,20 +961,17 @@ index 6abf6cef230c97815f17f6b7abf9f1b1de274a6f..46ead1f32e0d710b5b32e61dff72a4f7dom::MediaCapabilities* MediaCapabilities();dom::MediaSession* MediaSession();diff --git a/dom/base/nsContentUtils.cpp b/dom/base/nsContentUtils.cpp-index 3793f9845d12dc6d88604c43baca744fe559ed21..6f2ec74a8613b72be0ed27cb566bfdbc388a692b 100644+index f362a444a0f5ed247582646754dffd54d0b4540a..bbd72dab7ff4fbac8c247961e530764cb5c68d11 100644--- a/dom/base/nsContentUtils.cpp+++ b/dom/base/nsContentUtils.cpp-@@ -8740,7 +8740,8 @@ nsresult nsContentUtils::SendMouseEvent(- bool aIgnoreRootScrollFrame, float aPressure,- unsigned short aInputSourceArg, uint32_t aIdentifier, bool aToWindow,- PreventDefaultResult* aPreventDefault, bool aIsDOMEventSynthesized,+@@ -9151,11 +9151,13 @@ nsresult nsContentUtils::SendMouseEvent(+ int32_t aClickCount, int32_t aModifiers, bool aIgnoreRootScrollFrame,+ float aPressure, unsigned short aInputSourceArg, uint32_t aIdentifier,+ bool aToWindow, bool* aPreventDefault, bool aIsDOMEventSynthesized,- bool aIsWidgetEventSynthesized) {+ bool aIsWidgetEventSynthesized,+ bool convertToPointer, uint32_t aJugglerEventId) {- nsPoint offset;- nsCOMPtr<nsIWidget> widget = GetWidget(aPresShell, &offset);- if (!widget) return NS_ERROR_FAILURE;-@@ -8748,6 +8749,7 @@ nsresult nsContentUtils::SendMouseEvent(+ MOZ_ASSERT(aWidget);EventMessage msg;Maybe<WidgetMouseEvent::ExitFrom> exitFrom;bool contextMenuKey = false;@@ -982,7 +979,7 @@ index 3793f9845d12dc6d88604c43baca744fe559ed21..6f2ec74a8613b72be0ed27cb566bfdbcif (aType.EqualsLiteral("mousedown")) {msg = eMouseDown;} else if (aType.EqualsLiteral("mouseup")) {-@@ -8773,6 +8775,12 @@ nsresult nsContentUtils::SendMouseEvent(+@@ -9181,6 +9183,12 @@ nsresult nsContentUtils::SendMouseEvent(msg = eMouseHitTest;} else if (aType.EqualsLiteral("MozMouseExploreByTouch")) {msg = eMouseExploreByTouch;@@ -995,7 +992,7 @@ index 3793f9845d12dc6d88604c43baca744fe559ed21..6f2ec74a8613b72be0ed27cb566bfdbc} else {return NS_ERROR_FAILURE;}-@@ -8783,7 +8791,14 @@ nsresult nsContentUtils::SendMouseEvent(+@@ -9191,7 +9199,14 @@ nsresult nsContentUtils::SendMouseEvent(Maybe<WidgetPointerEvent> pointerEvent;Maybe<WidgetMouseEvent> mouseEvent;@@ -1003,7 +1000,7 @@ index 3793f9845d12dc6d88604c43baca744fe559ed21..6f2ec74a8613b72be0ed27cb566bfdbc+ Maybe<WidgetDragEvent> pwDragEvent;++ if (isPWDragEventMessage) {-+ pwDragEvent.emplace(true, msg, widget);++ pwDragEvent.emplace(true, msg, aWidget);+ pwDragEvent->mReason = aIsWidgetEventSynthesized+ ? WidgetMouseEvent::eSynthesized+ : WidgetMouseEvent::eReal;@@ -1011,7 +1008,7 @@ index 3793f9845d12dc6d88604c43baca744fe559ed21..6f2ec74a8613b72be0ed27cb566bfdbcMOZ_ASSERT(!aIsWidgetEventSynthesized,"The event shouldn't be dispatched as a synthesized event");if (MOZ_UNLIKELY(aIsWidgetEventSynthesized)) {-@@ -8802,8 +8817,11 @@ nsresult nsContentUtils::SendMouseEvent(+@@ -9210,8 +9225,11 @@ nsresult nsContentUtils::SendMouseEvent(contextMenuKey ? WidgetMouseEvent::eContextMenuKey: WidgetMouseEvent::eNormal);}@@ -1023,7 +1020,7 @@ index 3793f9845d12dc6d88604c43baca744fe559ed21..6f2ec74a8613b72be0ed27cb566bfdbcmouseOrPointerEvent.pointerId = aIdentifier;mouseOrPointerEvent.mModifiers = GetWidgetModifiers(aModifiers);mouseOrPointerEvent.mButton = aButton;-@@ -8816,6 +8834,8 @@ nsresult nsContentUtils::SendMouseEvent(+@@ -9224,6 +9242,8 @@ nsresult nsContentUtils::SendMouseEvent(mouseOrPointerEvent.mClickCount = aClickCount;mouseOrPointerEvent.mFlags.mIsSynthesizedForTests = aIsDOMEventSynthesized;mouseOrPointerEvent.mExitFrom = exitFrom;@@ -1033,21 +1030,23 @@ index 3793f9845d12dc6d88604c43baca744fe559ed21..6f2ec74a8613b72be0ed27cb566bfdbcnsPresContext* presContext = aPresShell->GetPresContext();if (!presContext) return NS_ERROR_FAILURE;diff --git a/dom/base/nsContentUtils.h b/dom/base/nsContentUtils.h-index ed822f10425272124dd33a74d1cdac5011b1ba6a..0f29ce787f9cebc068d2e5faa9907d52b177283a 100644+index 779cd9e544bfb2d135f12c3558c0ca8164b37029..041eba4bcbf40f51fc40ce7609ea81408e6a788d 100644--- a/dom/base/nsContentUtils.h+++ b/dom/base/nsContentUtils.h-@@ -3019,7 +3019,8 @@ class nsContentUtils {+@@ -3015,8 +3015,9 @@ class nsContentUtils {+ int32_t aButton, int32_t aButtons, int32_t aClickCount,int32_t aModifiers, bool aIgnoreRootScrollFrame, float aPressure,unsigned short aInputSourceArg, uint32_t aIdentifier, bool aToWindow,- mozilla::PreventDefaultResult* aPreventDefault,-- bool aIsDOMEventSynthesized, bool aIsWidgetEventSynthesized);+- bool* aPreventDefault, bool aIsDOMEventSynthesized,+- bool aIsWidgetEventSynthesized);++ bool* aPreventDefault,+ bool aIsDOMEventSynthesized, bool aIsWidgetEventSynthesized,+ bool convertToPointer = true, uint32_t aJugglerEventId = 0);static void FirePageShowEventForFrameLoaderSwap(nsIDocShellTreeItem* aItem,diff --git a/dom/base/nsDOMWindowUtils.cpp b/dom/base/nsDOMWindowUtils.cpp-index fe23028691d0d06f6b036fd9da2c466730f58cb7..40cfc256510cbddea50574b531ce4369462fd956 100644+index 15fe1db8a28ed2592b61aaf2006ddaa656f12389..2642c18bebcdfdd467be557171ba4ee204fcabde 100644--- a/dom/base/nsDOMWindowUtils.cpp+++ b/dom/base/nsDOMWindowUtils.cpp@@ -710,6 +710,26 @@ nsDOMWindowUtils::GetPresShellId(uint32_t* aPresShellId) {@@ -1095,27 +1094,29 @@ index fe23028691d0d06f6b036fd9da2c466730f58cb7..40cfc256510cbddea50574b531ce4369}NS_IMETHODIMP-@@ -751,13 +771,13 @@ nsDOMWindowUtils::SendMouseEventCommon(+@@ -751,7 +771,7 @@ nsDOMWindowUtils::SendMouseEventCommon(int32_t aClickCount, int32_t aModifiers, bool aIgnoreRootScrollFrame,float aPressure, unsigned short aInputSourceArg, uint32_t aPointerId,bool aToWindow, bool* aPreventDefault, bool aIsDOMEventSynthesized,- bool aIsWidgetEventSynthesized, int32_t aButtons) {+ bool aIsWidgetEventSynthesized, int32_t aButtons, bool aConvertToPointer, uint32_t aJugglerEventId) {RefPtr<PresShell> presShell = GetPresShell();- PreventDefaultResult preventDefaultResult;- nsresult rv = nsContentUtils::SendMouseEvent(- presShell, aType, aX, aY, aButton, aButtons, aClickCount, aModifiers,- aIgnoreRootScrollFrame, aPressure, aInputSourceArg, aPointerId, aToWindow,-- &preventDefaultResult, aIsDOMEventSynthesized, aIsWidgetEventSynthesized);-+ &preventDefaultResult, aIsDOMEventSynthesized, aIsWidgetEventSynthesized, aConvertToPointer, aJugglerEventId);-- if (aPreventDefault) {- *aPreventDefault = preventDefaultResult != PreventDefaultResult::No;+ if (!presShell) {+ return NS_ERROR_FAILURE;+@@ -768,7 +788,7 @@ nsDOMWindowUtils::SendMouseEventCommon(+ presShell, widget, aType, refPoint, aButton, aButtons, aClickCount,+ aModifiers, aIgnoreRootScrollFrame, aPressure, aInputSourceArg,+ aPointerId, aToWindow, aPreventDefault, aIsDOMEventSynthesized,+- aIsWidgetEventSynthesized);++ aIsWidgetEventSynthesized, aConvertToPointer, aJugglerEventId);+ }++ NS_IMETHODIMPdiff --git a/dom/base/nsDOMWindowUtils.h b/dom/base/nsDOMWindowUtils.h-index 47ff326b202266b1d7d6af8bdfb72776df8a6a93..b8e084b0c788c46345b1455b8257f1719c851404 100644+index a8a48d28fc4ef612f8234bc2490a41672f1704f5..f702b0c9a0783ec547a41bbefd68e18a27a239fe 100644--- a/dom/base/nsDOMWindowUtils.h+++ b/dom/base/nsDOMWindowUtils.h-@@ -93,7 +93,7 @@ class nsDOMWindowUtils final : public nsIDOMWindowUtils,+@@ -94,7 +94,7 @@ class nsDOMWindowUtils final : public nsIDOMWindowUtils,int32_t aClickCount, int32_t aModifiers, bool aIgnoreRootScrollFrame,float aPressure, unsigned short aInputSourceArg, uint32_t aIdentifier,bool aToWindow, bool* aPreventDefault, bool aIsDOMEventSynthesized,@@ -1125,10 +1126,10 @@ index 47ff326b202266b1d7d6af8bdfb72776df8a6a93..b8e084b0c788c46345b1455b8257f171MOZ_CAN_RUN_SCRIPTnsresult SendTouchEventCommon(diff --git a/dom/base/nsFocusManager.cpp b/dom/base/nsFocusManager.cpp-index a1d3ae3f3cb8d916a9a8bcca4cb515a2ab496ccb..72326b41064f6a86d76aba7b1902851e966365a8 100644+index 555a08b4b3fcd0d0c7986014d2e3516c6e5991c0..74a39e000b0e68042f1f51f6fafbc39ac9b42e51 100644--- a/dom/base/nsFocusManager.cpp+++ b/dom/base/nsFocusManager.cpp-@@ -1719,6 +1719,10 @@ Maybe<uint64_t> nsFocusManager::SetFocusInner(Element* aNewContent,+@@ -1720,6 +1720,10 @@ Maybe<uint64_t> nsFocusManager::SetFocusInner(Element* aNewContent,(GetActiveBrowsingContext() == newRootBrowsingContext);}@@ -1139,7 +1140,7 @@ index a1d3ae3f3cb8d916a9a8bcca4cb515a2ab496ccb..72326b41064f6a86d76aba7b1902851e// Exit fullscreen if a website focuses another windowif (StaticPrefs::full_screen_api_exit_on_windowRaise() &&!isElementInActiveWindow && (aFlags & FLAG_RAISE)) {-@@ -2304,6 +2308,7 @@ bool nsFocusManager::BlurImpl(BrowsingContext* aBrowsingContextToClear,+@@ -2306,6 +2310,7 @@ bool nsFocusManager::BlurImpl(BrowsingContext* aBrowsingContextToClear,bool aIsLeavingDocument, bool aAdjustWidget,bool aRemainActive, Element* aElementToFocus,uint64_t aActionId) {@@ -1147,7 +1148,7 @@ index a1d3ae3f3cb8d916a9a8bcca4cb515a2ab496ccb..72326b41064f6a86d76aba7b1902851eLOGFOCUS(("<<Blur begin actionid: %" PRIu64 ">>", aActionId));// hold a reference to the focused content, which may be null-@@ -2350,6 +2355,11 @@ bool nsFocusManager::BlurImpl(BrowsingContext* aBrowsingContextToClear,+@@ -2352,6 +2357,11 @@ bool nsFocusManager::BlurImpl(BrowsingContext* aBrowsingContextToClear,return true;}@@ -1159,7 +1160,7 @@ index a1d3ae3f3cb8d916a9a8bcca4cb515a2ab496ccb..72326b41064f6a86d76aba7b1902851e// Keep a ref to presShell since dispatching the DOM event may cause// the document to be destroyed.RefPtr<PresShell> presShell = docShell->GetPresShell();-@@ -3064,7 +3074,9 @@ void nsFocusManager::RaiseWindow(nsPIDOMWindowOuter* aWindow,+@@ -3066,7 +3076,9 @@ void nsFocusManager::RaiseWindow(nsPIDOMWindowOuter* aWindow,}}@@ -1171,10 +1172,10 @@ index a1d3ae3f3cb8d916a9a8bcca4cb515a2ab496ccb..72326b41064f6a86d76aba7b1902851e// care of lowering the present active window. This happens in// a separate runnable to avoid touching multiple windows indiff --git a/dom/base/nsGlobalWindowOuter.cpp b/dom/base/nsGlobalWindowOuter.cpp-index 4d0483fb6cc4b7ed6cc9633c72413017e7b49249..9eb60397c94f567cc76fcbeec4585bf92b2fd0f7 100644+index 99a5049a3aff2efb208895d60622fd9c8d7f337a..9a9b039a46f1294a8b4af0613fb4f4173ac6a8a0 100644--- a/dom/base/nsGlobalWindowOuter.cpp+++ b/dom/base/nsGlobalWindowOuter.cpp-@@ -2516,10 +2516,16 @@ nsresult nsGlobalWindowOuter::SetNewDocument(Document* aDocument,+@@ -2512,10 +2512,16 @@ nsresult nsGlobalWindowOuter::SetNewDocument(Document* aDocument,}();if (!isContentAboutBlankInChromeDocshell) {@@ -1195,7 +1196,7 @@ index 4d0483fb6cc4b7ed6cc9633c72413017e7b49249..9eb60397c94f567cc76fcbeec4585bf9}}-@@ -2639,6 +2645,19 @@ void nsGlobalWindowOuter::DispatchDOMWindowCreated() {+@@ -2635,6 +2641,19 @@ void nsGlobalWindowOuter::DispatchDOMWindowCreated() {}}@@ -1216,10 +1217,10 @@ index 4d0483fb6cc4b7ed6cc9633c72413017e7b49249..9eb60397c94f567cc76fcbeec4585bf9void nsGlobalWindowOuter::SetDocShell(nsDocShell* aDocShell) {diff --git a/dom/base/nsGlobalWindowOuter.h b/dom/base/nsGlobalWindowOuter.h-index d4347e7a508742986f634e97394a9e3dd435d170..5088520537c8c5c6cc79c1dffd91a68de09f27eb 100644+index 0453a18ec10c1434d1692f10b1b4acee754e6b7e..ee7bad691515bb51f6b4345e88944b02ad173180 100644--- a/dom/base/nsGlobalWindowOuter.h+++ b/dom/base/nsGlobalWindowOuter.h-@@ -317,6 +317,7 @@ class nsGlobalWindowOuter final : public mozilla::dom::EventTarget,+@@ -320,6 +320,7 @@ class nsGlobalWindowOuter final : public mozilla::dom::EventTarget,// Outer windows only.void DispatchDOMWindowCreated();@@ -1228,10 +1229,10 @@ index d4347e7a508742986f634e97394a9e3dd435d170..5088520537c8c5c6cc79c1dffd91a68d// Outer windows only.virtual void EnsureSizeAndPositionUpToDate() override;diff --git a/dom/base/nsINode.cpp b/dom/base/nsINode.cpp-index 4c1efbb1edf0e7d34a333e2724baf055eefa7e6e..c5d64fba742187c8ebaad8f45e868ab65722d07a 100644+index 8e2bbed21c13f23745e2eaad4ded831106ebd930..a17b0c7b9730737f178c05703b08d0f5f6d9ecd1 100644--- a/dom/base/nsINode.cpp+++ b/dom/base/nsINode.cpp-@@ -1437,6 +1437,61 @@ void nsINode::GetBoxQuadsFromWindowOrigin(const BoxQuadOptions& aOptions,+@@ -1449,6 +1449,61 @@ void nsINode::GetBoxQuadsFromWindowOrigin(const BoxQuadOptions& aOptions,mozilla::GetBoxQuadsFromWindowOrigin(this, aOptions, aResult, aRv);}@@ -1294,10 +1295,10 @@ index 4c1efbb1edf0e7d34a333e2724baf055eefa7e6e..c5d64fba742187c8ebaad8f45e868ab6DOMQuad& aQuad, const GeometryNode& aFrom,const ConvertCoordinateOptions& aOptions, CallerType aCallerType,diff --git a/dom/base/nsINode.h b/dom/base/nsINode.h-index e1fb6c2aeb67ab600b668b342bee0c716427d116..55e573dce8ad4d34542f89b9179a1da14f45d1bc 100644+index eb75f281630f8ca1b901686207c9fc97336d675f..e607f0ae454d52fc2bfe19046b492352a84b4ebd 100644--- a/dom/base/nsINode.h+++ b/dom/base/nsINode.h-@@ -2356,6 +2356,10 @@ class nsINode : public mozilla::dom::EventTarget {+@@ -2397,6 +2397,10 @@ class nsINode : public mozilla::dom::EventTarget {nsTArray<RefPtr<DOMQuad>>& aResult,ErrorResult& aRv);@@ -1337,7 +1338,7 @@ index f32e21752d5013bf143eb45391ab9218debab08e..83763d2354dade2f8d2b7930ba18ae91static bool DumpEnabled();diff --git a/dom/chrome-webidl/BrowsingContext.webidl b/dom/chrome-webidl/BrowsingContext.webidl-index 28e8d8cb9c61ff8362b2d191d47c3630d2cb0b34..58c12d597978100507dbc21e88c49c5642a3ba1f 100644+index 6ec88536141126c97c9b599e3237bb5670d42ce8..41c6cc56738bdaf711adf2cf5b00c7fad5d71ba8 100644--- a/dom/chrome-webidl/BrowsingContext.webidl+++ b/dom/chrome-webidl/BrowsingContext.webidl@@ -61,6 +61,26 @@ enum ForcedColorsOverride {@@ -1381,10 +1382,10 @@ index 28e8d8cb9c61ff8362b2d191d47c3630d2cb0b34..58c12d597978100507dbc21e88c49c56* A unique identifier for the browser element that is hosting this* BrowsingContext tree. Every BrowsingContext in the element's tree willdiff --git a/dom/fetch/Fetch.cpp b/dom/fetch/Fetch.cpp-index a030f3f07b9f4a676f87ac482507056bc911edf5..68bd39affdbbe2e35fdac62b1e159ebc7ffd031c 100644+index 0bd219694282347309680fc9b53b945e1fd0ad92..c5c2e2d32a380ec72379b05a8b84f187431f7309 100644--- a/dom/fetch/Fetch.cpp+++ b/dom/fetch/Fetch.cpp-@@ -689,6 +689,12 @@ already_AddRefed<Promise> FetchRequest(nsIGlobalObject* aGlobal,+@@ -701,6 +701,12 @@ already_AddRefed<Promise> FetchRequest(nsIGlobalObject* aGlobal,ipcArgs.hasCSPEventListener() = false;ipcArgs.isWorkerRequest() = false;@@ -1398,10 +1399,10 @@ index a030f3f07b9f4a676f87ac482507056bc911edf5..68bd39affdbbe2e35fdac62b1e159ebcmozilla::glean::networking::fetch_keepalive_request_count.Get("main"_ns)diff --git a/dom/fetch/FetchService.cpp b/dom/fetch/FetchService.cpp-index 6fc05bf6cc8341e7cfac63789b79f610bdbe9641..112db3c2e6d2f854103ddacde896904018f5ea90 100644+index b5e60bbd27fbb2f033d233e9ae2ebc728f442512..0adc568ece34d2c0f35eeacd81e2db9125b7c327 100644--- a/dom/fetch/FetchService.cpp+++ b/dom/fetch/FetchService.cpp-@@ -265,6 +265,14 @@ RefPtr<FetchServicePromises> FetchService::FetchInstance::Fetch() {+@@ -268,6 +268,14 @@ RefPtr<FetchServicePromises> FetchService::FetchInstance::Fetch() {false // IsTrackingFetch);@@ -1417,10 +1418,10 @@ index 6fc05bf6cc8341e7cfac63789b79f610bdbe9641..112db3c2e6d2f854103ddacde8969040auto& args = mArgs.as<WorkerFetchArgs>();mFetchDriver->SetWorkerScript(args.mWorkerScript);diff --git a/dom/geolocation/Geolocation.cpp b/dom/geolocation/Geolocation.cpp-index e67cb4efce43b42fa876c906f7f1927c65d34ea7..a42da20dc6aaa1915c611d4bc339a8db974c75eb 100644+index 7c653fe131dc34d35ffdc030950071adb31a9fc9..b23442a42ba8ee270e8e38930e59ae15c2a29039 100644--- a/dom/geolocation/Geolocation.cpp+++ b/dom/geolocation/Geolocation.cpp-@@ -29,6 +29,7 @@+@@ -28,6 +28,7 @@#include "nsComponentManagerUtils.h"#include "nsContentPermissionHelper.h"#include "nsContentUtils.h"@@ -1428,7 +1429,7 @@ index e67cb4efce43b42fa876c906f7f1927c65d34ea7..a42da20dc6aaa1915c611d4bc339a8db#include "nsGlobalWindowInner.h"#include "mozilla/dom/Document.h"#include "nsINamed.h"-@@ -429,10 +430,8 @@ nsGeolocationRequest::Allow(JS::Handle<JS::Value> aChoices) {+@@ -428,10 +429,8 @@ nsGeolocationRequest::Allow(JS::Handle<JS::Value> aChoices) {return NS_OK;}@@ -1441,7 +1442,7 @@ index e67cb4efce43b42fa876c906f7f1927c65d34ea7..a42da20dc6aaa1915c611d4bc339a8dbCachedPositionAndAccuracy lastPosition = gs->GetCachedPosition();if (lastPosition.position) {EpochTimeStamp cachedPositionTime_ms;-@@ -640,8 +639,7 @@ void nsGeolocationRequest::Shutdown() {+@@ -639,8 +638,7 @@ void nsGeolocationRequest::Shutdown() {// If there are no other high accuracy requests, the geolocation service will// notify the provider to switch to the default accuracy.if (mOptions && mOptions->mEnableHighAccuracy) {@@ -1451,7 +1452,7 @@ index e67cb4efce43b42fa876c906f7f1927c65d34ea7..a42da20dc6aaa1915c611d4bc339a8dbif (gs) {gs->UpdateAccuracy();}-@@ -958,8 +956,14 @@ void nsGeolocationService::StopDevice() {+@@ -957,8 +955,14 @@ void nsGeolocationService::StopDevice() {StaticRefPtr<nsGeolocationService> nsGeolocationService::sService;already_AddRefed<nsGeolocationService>@@ -1467,7 +1468,7 @@ index e67cb4efce43b42fa876c906f7f1927c65d34ea7..a42da20dc6aaa1915c611d4bc339a8dbif (nsGeolocationService::sService) {result = nsGeolocationService::sService;-@@ -1051,7 +1055,9 @@ nsresult Geolocation::Init(nsPIDOMWindowInner* aContentDom) {+@@ -1050,7 +1054,9 @@ nsresult Geolocation::Init(nsPIDOMWindowInner* aContentDom) {// If no aContentDom was passed into us, we are being used// by chrome/c++ and have no mOwner, no mPrincipal, and no need// to prompt.@@ -1516,7 +1517,7 @@ index 992de29b5d2d09c19e55ebb2502215ec9d05a171..cdc20567b693283b0fd5a5923f7ea542~Geolocation();diff --git a/dom/html/HTMLInputElement.cpp b/dom/html/HTMLInputElement.cpp-index 2e6ef116be73d0794683189c07afc8a629859154..33f4add0cb7736edd416d31d0feca4fd5afc4526 100644+index c3e7de8f41e06e11155620b75c4d8a830d908b37..39eb9d31258693dce3a26c3227f28d92bccdb019 100644--- a/dom/html/HTMLInputElement.cpp+++ b/dom/html/HTMLInputElement.cpp@@ -64,6 +64,7 @@@@ -1527,7 +1528,7 @@ index 2e6ef116be73d0794683189c07afc8a629859154..33f4add0cb7736edd416d31d0feca4fd#include "nsIFrame.h"#include "nsRangeFrame.h"#include "nsError.h"-@@ -789,6 +790,13 @@ nsresult HTMLInputElement::InitFilePicker(FilePickerType aType) {+@@ -790,6 +791,13 @@ nsresult HTMLInputElement::InitFilePicker(FilePickerType aType) {return NS_ERROR_FAILURE;}@@ -1542,7 +1543,7 @@ index 2e6ef116be73d0794683189c07afc8a629859154..33f4add0cb7736edd416d31d0feca4fdreturn NS_OK;}diff --git a/dom/interfaces/base/nsIDOMWindowUtils.idl b/dom/interfaces/base/nsIDOMWindowUtils.idl-index 8ddde6e5de319142ce0898dc3667c08f1f24cce9..9e530a727f06b924e3d0bcf4ba52507231778257 100644+index 5e417145c4f21d8f2aa65088611477b681c9c327..bc84c509659c7556077e69c652e5b19639eb88bb 100644--- a/dom/interfaces/base/nsIDOMWindowUtils.idl+++ b/dom/interfaces/base/nsIDOMWindowUtils.idl@@ -374,6 +374,26 @@ interface nsIDOMWindowUtils : nsISupports {@@ -1846,7 +1847,7 @@ index 3b39538e51840cd9b1685b2efd2ff2e9ec83608a..c7bf4f2d53b58bbacb22b3ebebf6f3fcreturn aGlobalOrNull;diff --git a/dom/security/nsCSPUtils.cpp b/dom/security/nsCSPUtils.cpp-index 32a8d9496e674e752dd3ac41afc7f22ed534dce3..e57690654be4ae18f14d3171fa4eab9ec8aa991f 100644+index 5ec21c1c7f975a372399748e8bab2b21ce347f20..ed16831e549afa3d6623398d35eb61e26ab5f2b0 100644--- a/dom/security/nsCSPUtils.cpp+++ b/dom/security/nsCSPUtils.cpp@@ -23,6 +23,7 @@@@ -1857,7 +1858,7 @@ index 32a8d9496e674e752dd3ac41afc7f22ed534dce3..e57690654be4ae18f14d3171fa4eab9e#include "mozilla/Assertions.h"#include "mozilla/Components.h"-@@ -134,6 +135,11 @@ void CSP_ApplyMetaCSPToDoc(mozilla::dom::Document& aDoc,+@@ -135,6 +136,11 @@ void CSP_ApplyMetaCSPToDoc(mozilla::dom::Document& aDoc,return;}@@ -1893,10 +1894,10 @@ index aee376e971ae01ac1e512c3920b115bfaf06afa8..1701311534bf77e6cd9bafc0e3a28361* returned quads are further translated relative to the window* origin -- which is not the layout origin. Further translationdiff --git a/dom/workers/RuntimeService.cpp b/dom/workers/RuntimeService.cpp-index f528bec20afef533e4c6b99c5e9d1680fd0b636e..a0d22d38657f672d865f35c02975e7b611571353 100644+index a23637c4a887b66a1b4c709a648762b84151bf01..d8da9063261482f1da3257e3f95a8a49d94325f8 100644--- a/dom/workers/RuntimeService.cpp+++ b/dom/workers/RuntimeService.cpp-@@ -1027,7 +1027,7 @@ void PrefLanguagesChanged(const char* /* aPrefName */, void* /* aClosure */) {+@@ -1026,7 +1026,7 @@ void PrefLanguagesChanged(const char* /* aPrefName */, void* /* aClosure */) {AssertIsOnMainThread();nsTArray<nsString> languages;@@ -1905,7 +1906,7 @@ index f528bec20afef533e4c6b99c5e9d1680fd0b636e..a0d22d38657f672d865f35c02975e7b6RuntimeService* runtime = RuntimeService::GetService();if (runtime) {-@@ -1215,8 +1215,7 @@ bool RuntimeService::RegisterWorker(WorkerPrivate& aWorkerPrivate) {+@@ -1214,8 +1214,7 @@ bool RuntimeService::RegisterWorker(WorkerPrivate& aWorkerPrivate) {}// The navigator overridden properties should have already been read.@@ -1915,7 +1916,7 @@ index f528bec20afef533e4c6b99c5e9d1680fd0b636e..a0d22d38657f672d865f35c02975e7b6mNavigatorPropertiesLoaded = true;}-@@ -1837,6 +1836,13 @@ void RuntimeService::PropagateStorageAccessPermissionGranted(+@@ -1836,6 +1835,13 @@ void RuntimeService::PropagateStorageAccessPermissionGranted(}}@@ -1929,7 +1930,7 @@ index f528bec20afef533e4c6b99c5e9d1680fd0b636e..a0d22d38657f672d865f35c02975e7b6template <typename Func>void RuntimeService::BroadcastAllWorkers(const Func& aFunc) {AssertIsOnMainThread();-@@ -2362,6 +2368,14 @@ void PropagateStorageAccessPermissionGrantedToWorkers(+@@ -2361,6 +2367,14 @@ void PropagateStorageAccessPermissionGrantedToWorkers(}}@@ -1971,7 +1972,7 @@ index 58894a8361c7ef1dddd481ca5877a209a8b8ff5c..c481d40d79b6397b7f1d571bd9f6ae5cbool IsWorkerGlobal(JSObject* global);diff --git a/dom/workers/WorkerPrivate.cpp b/dom/workers/WorkerPrivate.cpp-index 0076a8463fa9ff05b32edfe21462987610432b5d..9f810c9728b7d7caf9fbeb3e24346c219326637d 100644+index 5d918a82708a26125f7322e43f6436d7eafaa812..b230baead02e05d87a211c276066ec7939ea8251 100644--- a/dom/workers/WorkerPrivate.cpp+++ b/dom/workers/WorkerPrivate.cpp@@ -736,6 +736,18 @@ class UpdateContextOptionsRunnable final : public WorkerControlRunnable {@@ -1993,7 +1994,7 @@ index 0076a8463fa9ff05b32edfe21462987610432b5d..9f810c9728b7d7caf9fbeb3e24346c21class UpdateLanguagesRunnable final : public WorkerThreadRunnable {nsTArray<nsString> mLanguages;-@@ -2149,6 +2161,16 @@ void WorkerPrivate::UpdateContextOptions(+@@ -2159,6 +2171,16 @@ void WorkerPrivate::UpdateContextOptions(}}@@ -2010,7 +2011,7 @@ index 0076a8463fa9ff05b32edfe21462987610432b5d..9f810c9728b7d7caf9fbeb3e24346c21void WorkerPrivate::UpdateLanguages(const nsTArray<nsString>& aLanguages) {AssertIsOnParentThread();-@@ -5833,6 +5855,15 @@ void WorkerPrivate::UpdateContextOptionsInternal(+@@ -5946,6 +5968,15 @@ void WorkerPrivate::UpdateContextOptionsInternal(}}@@ -2027,7 +2028,7 @@ index 0076a8463fa9ff05b32edfe21462987610432b5d..9f810c9728b7d7caf9fbeb3e24346c21const nsTArray<nsString>& aLanguages) {WorkerGlobalScope* globalScope = GlobalScope();diff --git a/dom/workers/WorkerPrivate.h b/dom/workers/WorkerPrivate.h-index c2ade467934d08587d4e3589b310c6302534d699..414814c03180b50d218ad84a0db262fff19f78a7 100644+index 7bccdc8c0c2cd53f7aa7a6d9a74435344dd27980..86bba2128a7c0f4e5efa4bfbc939937aec146695 100644--- a/dom/workers/WorkerPrivate.h+++ b/dom/workers/WorkerPrivate.h@@ -443,6 +443,8 @@ class WorkerPrivate final@@ -2039,7 +2040,7 @@ index c2ade467934d08587d4e3589b310c6302534d699..414814c03180b50d218ad84a0db262ffvoid UpdateLanguagesInternal(const nsTArray<nsString>& aLanguages);void UpdateJSWorkerMemoryParameterInternal(JSContext* aCx, JSGCParamKey key,-@@ -1086,6 +1088,8 @@ class WorkerPrivate final+@@ -1091,6 +1093,8 @@ class WorkerPrivate finalvoid UpdateContextOptions(const JS::ContextOptions& aContextOptions);@@ -2101,10 +2102,10 @@ index 523e84c8c93f4221701f90f2e8ee146ec8e1adbd..98d5b1176e5378431b859a2dbd4d4e77inline ClippedTime TimeClip(double time);diff --git a/js/src/debugger/Object.cpp b/js/src/debugger/Object.cpp-index 880e716c24464c93283410417f8e69d6d233d105..6e046fbd2e643dace5ad7796740253df3ddf2cbe 100644+index b7ea4b6f66d14db0324397cdc1b0ed8c5ea167e2..1c59e328079e7e43b65f7cb7bc31636a48a93263 100644--- a/js/src/debugger/Object.cpp+++ b/js/src/debugger/Object.cpp-@@ -2474,7 +2474,11 @@ Maybe<Completion> DebuggerObject::call(JSContext* cx,+@@ -2484,7 +2484,11 @@ Maybe<Completion> DebuggerObject::call(JSContext* cx,invokeArgs[i].set(args2[i]);}@@ -2117,7 +2118,7 @@ index 880e716c24464c93283410417f8e69d6d233d105..6e046fbd2e643dace5ad7796740253df}diff --git a/js/src/vm/DateTime.cpp b/js/src/vm/DateTime.cpp-index cf63b124f39223a1a42c322dcc0ad108947d54f5..9e3a7b757cbad57ee6cfe2254d0355f62f7c8662 100644+index a57b8fefa104f966393a99f5a81876b9a95f9743..adc42dd227e52643b06fb101170aeafb490c0acc 100644--- a/js/src/vm/DateTime.cpp+++ b/js/src/vm/DateTime.cpp@@ -185,6 +185,11 @@ void js::DateTimeInfo::internalResetTimeZone(ResetTimeZoneMode mode) {@@ -2272,10 +2273,10 @@ index 4bfd336ddcbee8004ac538ca7b7d8216d04a61c3..cd22351c4aeacea8afc9828972222aca// No boxes to returnreturn;diff --git a/layout/base/PresShell.cpp b/layout/base/PresShell.cpp-index ede24b9c7ac3569d6467ac88bc491d2987ac0bca..a45ebcdf3a3caaad15a8dff0b8ebbec971aac8a6 100644+index e8fb3a8304b27814e6e84355f24410c820667f9d..211c86fe55b8b650e40275a427b30a1ee8a9a3d7 100644--- a/layout/base/PresShell.cpp+++ b/layout/base/PresShell.cpp-@@ -11265,7 +11265,9 @@ bool PresShell::ComputeActiveness() const {+@@ -11512,7 +11512,9 @@ bool PresShell::ComputeActiveness() const {if (!browserChild->IsVisible()) {MOZ_LOG(gLog, LogLevel::Debug,(" > BrowserChild %p is not visible", browserChild));@@ -2287,7 +2288,7 @@ index ede24b9c7ac3569d6467ac88bc491d2987ac0bca..a45ebcdf3a3caaad15a8dff0b8ebbec9// If the browser is visible but just due to be preserving layersdiff --git a/layout/base/nsLayoutUtils.cpp b/layout/base/nsLayoutUtils.cpp-index b9f06daa19e5aecb976ad198990a315bc39f736d..1600435c406e2e652abdab72a7947add7266c75a 100644+index 315d532eab56dab13b6c8bc2380a5cda2a17ffc1..7c4552137149e8c7fc9ac08a09bd4242952b53b6 100644--- a/layout/base/nsLayoutUtils.cpp+++ b/layout/base/nsLayoutUtils.cpp@@ -708,6 +708,10 @@ bool nsLayoutUtils::AllowZoomingForDocument(@@ -2301,7 +2302,7 @@ index b9f06daa19e5aecb976ad198990a315bc39f736d..1600435c406e2e652abdab72a7947add// True if we allow zooming for all documents on this platform, or if we are// in RDM.BrowsingContext* bc = aDocument->GetBrowsingContext();-@@ -9748,6 +9752,9 @@ void nsLayoutUtils::ComputeSystemFont(nsFont* aSystemFont,+@@ -9770,6 +9774,9 @@ void nsLayoutUtils::ComputeSystemFont(nsFont* aSystemFont,/* static */bool nsLayoutUtils::ShouldHandleMetaViewport(const Document* aDocument) {@@ -2312,10 +2313,10 @@ index b9f06daa19e5aecb976ad198990a315bc39f736d..1600435c406e2e652abdab72a7947addreturn StaticPrefs::dom_meta_viewport_enabled() || (bc && bc->InRDMPane());}diff --git a/layout/style/GeckoBindings.h b/layout/style/GeckoBindings.h-index 3f97c46ee5721c9f5bb9b86e2c0ece552ed00568..52f6c4d600baccc846503373af3476816f4c9fdc 100644+index c7cf59c2661c7e203384c9b82789879f756b44b7..21e32dab4e60112c073bdd5070a308da2b4e0373 100644--- a/layout/style/GeckoBindings.h+++ b/layout/style/GeckoBindings.h-@@ -595,6 +595,7 @@ float Gecko_MediaFeatures_GetResolution(const mozilla::dom::Document*);+@@ -596,6 +596,7 @@ float Gecko_MediaFeatures_GetResolution(const mozilla::dom::Document*);bool Gecko_MediaFeatures_PrefersReducedMotion(const mozilla::dom::Document*);bool Gecko_MediaFeatures_PrefersReducedTransparency(const mozilla::dom::Document*);@@ -2362,7 +2363,7 @@ index ca382a3cfba8ce5839890d6e4cb3cf9789287e3b..5800fc23dc77ee5764beddd6fa48a7fdreturn StylePrefersContrast::NoPreference;}diff --git a/netwerk/base/LoadInfo.cpp b/netwerk/base/LoadInfo.cpp-index 06acdc629c2b6ee0e29c50d8edc5a96d343b1ef2..6c263edf54117fd9cbf4a77abc396f1238730880 100644+index 1ec2c64193206d31702e22e5c4783f084b1cff31..fb463eb12ee39cd1e448369f3b47fbcfbb2473b9 100644--- a/netwerk/base/LoadInfo.cpp+++ b/netwerk/base/LoadInfo.cpp@@ -696,7 +696,8 @@ LoadInfo::LoadInfo(const LoadInfo& rhs)@@ -2375,7 +2376,7 @@ index 06acdc629c2b6ee0e29c50d8edc5a96d343b1ef2..6c263edf54117fd9cbf4a77abc396f12}LoadInfo::LoadInfo(-@@ -2515,4 +2516,16 @@ LoadInfo::SetSkipHTTPSUpgrade(bool aSkipHTTPSUpgrade) {+@@ -2534,4 +2535,16 @@ LoadInfo::SetSkipHTTPSUpgrade(bool aSkipHTTPSUpgrade) {return NS_OK;}@@ -2393,10 +2394,10 @@ index 06acdc629c2b6ee0e29c50d8edc5a96d343b1ef2..6c263edf54117fd9cbf4a77abc396f12+} // namespace mozilla::netdiff --git a/netwerk/base/LoadInfo.h b/netwerk/base/LoadInfo.h-index c78602f6b46c983aa4d96c5727ebbaf7e2c7d984..e292766a0f34306ea1101be4ecd8848764726bad 100644+index 93cc8d3630f7029303240555ae72d41b68047375..8a09863af399e25ba3f01caff2f6b3af1260e8b8 100644--- a/netwerk/base/LoadInfo.h+++ b/netwerk/base/LoadInfo.h-@@ -423,6 +423,8 @@ class LoadInfo final : public nsILoadInfo {+@@ -426,6 +426,8 @@ class LoadInfo final : public nsILoadInfo {bool mIsNewWindowTarget = false;bool mSkipHTTPSUpgrade = false;@@ -2406,10 +2407,10 @@ index c78602f6b46c983aa4d96c5727ebbaf7e2c7d984..e292766a0f34306ea1101be4ecd88487// This is exposed solely for testing purposes and should not be used outside ofdiff --git a/netwerk/base/TRRLoadInfo.cpp b/netwerk/base/TRRLoadInfo.cpp-index 5984a0a196615cca5544de052874cbb163a8233b..3617816a06651ae65c214ebd5f0affedc4d11390 100644+index d1650595f8cf28a704f94a99c1f6bfe1deb9cc77..2072a3990ff6f4496626dcebb277291ad845cac3 100644--- a/netwerk/base/TRRLoadInfo.cpp+++ b/netwerk/base/TRRLoadInfo.cpp-@@ -936,5 +936,15 @@ TRRLoadInfo::GetFetchDestination(nsACString& aDestination) {+@@ -950,5 +950,15 @@ TRRLoadInfo::GetFetchDestination(nsACString& aDestination) {return NS_ERROR_NOT_IMPLEMENTED;}@@ -2426,33 +2427,42 @@ index 5984a0a196615cca5544de052874cbb163a8233b..3617816a06651ae65c214ebd5f0affed} // namespace net} // namespace mozilladiff --git a/netwerk/base/nsILoadInfo.idl b/netwerk/base/nsILoadInfo.idl-index 2d77b8aa8799ec6bb7f38722e837d070f9057ea6..0261e58afd17c78a1484ec55e45bf34442929200 100644+index 774ec045c0b18310e8cb86e8a9d6b1788d028435..cbf303a0ed872c27d580b4b6615f3dd9c76a8a19 100644--- a/netwerk/base/nsILoadInfo.idl+++ b/netwerk/base/nsILoadInfo.idl-@@ -1609,4 +1609,6 @@ interface nsILoadInfo : nsISupports- * When true, this load will never be upgraded to HTTPS.- */- [infallible] attribute boolean skipHTTPSUpgrade;+@@ -1626,4 +1626,6 @@ interface nsILoadInfo : nsISupports+ return static_cast<mozilla::dom::UserNavigationInvolvement>(userNavigationInvolvement);+ }+ %}++ [infallible] attribute unsigned long long jugglerLoadIdentifier;};diff --git a/netwerk/base/nsINetworkInterceptController.idl b/netwerk/base/nsINetworkInterceptController.idl-index 7f91d2df6f8bb4020c75c132dc8f6bf26625fa1e..ba6569f4be8fc54ec96ee44d5de45a0904c077ba 100644+index 7f91d2df6f8bb4020c75c132dc8f6bf26625fa1e..aaa5541a17039d6b13ad83ab176fdaaf79edb2a0 100644--- a/netwerk/base/nsINetworkInterceptController.idl+++ b/netwerk/base/nsINetworkInterceptController.idl-@@ -59,6 +59,7 @@ interface nsIInterceptedChannel : nsISupports- * results in the resulting client not being controlled.+@@ -60,6 +60,16 @@ interface nsIInterceptedChannel : nsISupports*/void resetInterception(in boolean bypass);-+ void resetInterceptionWithURI(in nsIURI aURI);++ // ----- Playwright begin -----++++ // Same as resetInterception, but updates the URI.++ void resetInterceptionWithURI(in nsIURI aURI);++++ // After resetInterception is called, this request will be intercepted again.++ void interceptAfterServiceWorkerResets();++++ // ----- Playwright end -------++/*** Set the status and reason for the forthcoming synthesized response.+ * Multiple calls overwrite existing values.diff --git a/netwerk/ipc/DocumentLoadListener.cpp b/netwerk/ipc/DocumentLoadListener.cpp-index cdf9ad443ebf49eabc362fd555ae54c09502395c..8bca3d81fef7b59334b2ab0cdccdd80ef19c675d 100644+index 771ae1fbe3d54aa25443eea675cf3abd26a21ce9..a916cb49c16dc6c7809ccbb7c8d4172446a5ac07 100644--- a/netwerk/ipc/DocumentLoadListener.cpp+++ b/netwerk/ipc/DocumentLoadListener.cpp-@@ -175,6 +175,7 @@ static auto CreateDocumentLoadInfo(CanonicalBrowsingContext* aBrowsingContext,+@@ -177,6 +177,7 @@ static auto CreateDocumentLoadInfo(CanonicalBrowsingContext* aBrowsingContext,loadInfo->SetTextDirectiveUserActivation(aLoadState->GetTextDirectiveUserActivation());loadInfo->SetIsMetaRefresh(aLoadState->IsMetaRefresh());@@ -2461,13 +2471,19 @@ index cdf9ad443ebf49eabc362fd555ae54c09502395c..8bca3d81fef7b59334b2ab0cdccdd80ereturn loadInfo.forget();}diff --git a/netwerk/protocol/http/InterceptedHttpChannel.cpp b/netwerk/protocol/http/InterceptedHttpChannel.cpp-index 6d8d65c9335583d28aa3be8c05c065fa5aede908..6ab815111954b53b4dc722a1babe6b49a78bbedc 100644+index fbf4bdf1e24d1102df113984be6c8dc3a7d0d810..787bf014d3bf0b8537f99bf5eb4074e100c78c18 100644--- a/netwerk/protocol/http/InterceptedHttpChannel.cpp+++ b/netwerk/protocol/http/InterceptedHttpChannel.cpp-@@ -727,6 +727,14 @@ NS_IMPL_ISUPPORTS(ResetInterceptionHeaderVisitor, nsIHttpHeaderVisitor)+@@ -728,10 +728,33 @@ NS_IMPL_ISUPPORTS(ResetInterceptionHeaderVisitor, nsIHttpHeaderVisitor)} // anonymous namespace++NS_IMETHODIMP++InterceptedHttpChannel::InterceptAfterServiceWorkerResets() {++ mInterceptAfterServiceWorkerResets = true;++ return NS_OK;++}+++NS_IMETHODIMP+InterceptedHttpChannel::ResetInterceptionWithURI(nsIURI* aURI) {+ if (aURI) {@@ -2479,7 +2495,20 @@ index 6d8d65c9335583d28aa3be8c05c065fa5aede908..6ab815111954b53b4dc722a1babe6b49NS_IMETHODIMPInterceptedHttpChannel::ResetInterception(bool aBypass) {INTERCEPTED_LOG(("InterceptedHttpChannel::ResetInterception [%p] bypass: %s",-@@ -1140,11 +1148,18 @@ InterceptedHttpChannel::OnStartRequest(nsIRequest* aRequest) {+ this, aBypass ? "true" : "false"));++ if (mInterceptAfterServiceWorkerResets) {++ mInterceptAfterServiceWorkerResets = false;++ nsCOMPtr<nsINetworkInterceptController> controller;++ GetCallback(controller);++ if (!controller)++ return NS_ERROR_DOM_INVALID_STATE_ERR;++ return controller->ChannelIntercepted(this);++ }+++ if (mCanceled) {+ return mStatus;+ }+@@ -1146,11 +1169,18 @@ InterceptedHttpChannel::OnStartRequest(nsIRequest* aRequest) {GetCallback(mProgressSink);}@@ -2498,11 +2527,27 @@ index 6d8d65c9335583d28aa3be8c05c065fa5aede908..6ab815111954b53b4dc722a1babe6b49if (mPump && mLoadFlags & LOAD_CALL_CONTENT_SNIFFERS) {mPump->PeekStream(CallTypeSniffers, static_cast<nsIChannel*>(this));+diff --git a/netwerk/protocol/http/InterceptedHttpChannel.h b/netwerk/protocol/http/InterceptedHttpChannel.h+index 704404c9f094640ad63b685d64bd5a396e733e4b..92bdc21b4d6a015cc2f2bb22781ec6750c7789ec 100644+--- a/netwerk/protocol/http/InterceptedHttpChannel.h++++ b/netwerk/protocol/http/InterceptedHttpChannel.h+@@ -90,6 +90,11 @@ class InterceptedHttpChannel final+ Atomic<bool> mCallingStatusAndProgress;+ bool mInterceptionReset{false};+++ // ----- Playwright begin -----++ // After resetInterception is called, this request will call into interceptors again.++ bool mInterceptAfterServiceWorkerResets{false};++ // ----- Playwright end -------+++ /**+ * InterceptionTimeStamps is used to record the time stamps of the+ * interception.diff --git a/parser/html/nsHtml5TreeOpExecutor.cpp b/parser/html/nsHtml5TreeOpExecutor.cpp-index d05b06c3f9ddba3b40d5969730474eaf0d843cb1..9b2cc35c504e1044ac681c62c107f8feb6c16938 100644+index d3b44cc62d3df49bbf842356cbdb153c82c3163c..23cf9bc83fb1faaf1c7406331b78e522b307cbf0 100644--- a/parser/html/nsHtml5TreeOpExecutor.cpp+++ b/parser/html/nsHtml5TreeOpExecutor.cpp-@@ -1334,6 +1334,10 @@ void nsHtml5TreeOpExecutor::UpdateReferrerInfoFromMeta(+@@ -1349,6 +1349,10 @@ void nsHtml5TreeOpExecutor::UpdateReferrerInfoFromMeta(void nsHtml5TreeOpExecutor::AddSpeculationCSP(const nsAString& aCSP) {NS_ASSERTION(NS_IsMainThread(), "Wrong thread!");@@ -2514,7 +2559,7 @@ index d05b06c3f9ddba3b40d5969730474eaf0d843cb1..9b2cc35c504e1044ac681c62c107f8fensCOMPtr<nsIContentSecurityPolicy> preloadCsp = mDocument->GetPreloadCsp();if (!preloadCsp) {diff --git a/security/manager/ssl/nsCertOverrideService.cpp b/security/manager/ssl/nsCertOverrideService.cpp-index 1b9f32fc97bf3c5000db95567eaab85b518fe03a..3a39859d58b05b373e9db7ebb2b7ae37166d74e7 100644+index 8413eb5916f1f857e18972a14292d14f32684aee..66a3c7b01fdc56c29d789ff786aa91d8b0f02cd6 100644--- a/security/manager/ssl/nsCertOverrideService.cpp+++ b/security/manager/ssl/nsCertOverrideService.cpp@@ -433,7 +433,12 @@ nsCertOverrideService::HasMatchingOverride(@@ -2624,7 +2669,7 @@ index 75555352b8a15a50e4a21e34fc8ede4e9246c7cc..72855a404effa42b6c55cd0c2fcb8bdd// ignored for Linux.const unsigned long CHROME_SUPPRESS_ANIMATION = 1 << 24;diff --git a/toolkit/components/enterprisepolicies/EnterprisePoliciesParent.sys.mjs b/toolkit/components/enterprisepolicies/EnterprisePoliciesParent.sys.mjs-index 8b975a8b11bcf2eabbb7fa51a431ff99ff69a5bc..0eeb5924c43a21b8561dd4b68fa89228ddcbc708 100644+index 76fb919603e8d2b7864d351eb47be2a38e40e31e..cdfef96e20bea13799751154f4076bbcc2f827d4 100644--- a/toolkit/components/enterprisepolicies/EnterprisePoliciesParent.sys.mjs+++ b/toolkit/components/enterprisepolicies/EnterprisePoliciesParent.sys.mjs@@ -108,6 +108,12 @@ EnterprisePoliciesManager.prototype = {@@ -2641,10 +2686,10 @@ index 8b975a8b11bcf2eabbb7fa51a431ff99ff69a5bc..0eeb5924c43a21b8561dd4b68fa89228if (provider.failed) {diff --git a/toolkit/components/resistfingerprinting/nsUserCharacteristics.cpp b/toolkit/components/resistfingerprinting/nsUserCharacteristics.cpp-index cb235ed5b39fe5092a17b12976121ee3952d2062..649bba4c0faab1745f3040eba5925ef48b8f34f9 100644+index 253171bed4dea54fc28bb4ddc9920823dbd9351c..6dc0e620b399ed9ee6b53f97bc080ec17ee4e1b5 100644--- a/toolkit/components/resistfingerprinting/nsUserCharacteristics.cpp+++ b/toolkit/components/resistfingerprinting/nsUserCharacteristics.cpp-@@ -489,7 +489,7 @@ void PopulateLanguages() {+@@ -490,7 +490,7 @@ void PopulateLanguages() {// sufficient to only collect this information as the other properties are// just reformats of Navigator::GetAcceptLanguages.nsTArray<nsString> languages;@@ -2682,10 +2727,10 @@ index 654903fadb709be976b72f36f155e23bc0622152..815b3dc24c9fda6b1db6c4666ac68904int32_t aMaxSelfProgress,int32_t aCurTotalProgress,diff --git a/toolkit/components/windowwatcher/nsWindowWatcher.cpp b/toolkit/components/windowwatcher/nsWindowWatcher.cpp-index 585a957fd8a1467dc262bd1ca2058584fd8762c9..16ad38c3b7d753c386e091af700d1bebd4c59e3e 100644+index 811fb16410e8cf900ad873797269e5fe715579a5..821f5b0c2af8e1dc8754cd023571d1d0ff09eeb6 100644--- a/toolkit/components/windowwatcher/nsWindowWatcher.cpp+++ b/toolkit/components/windowwatcher/nsWindowWatcher.cpp-@@ -1875,7 +1875,11 @@ uint32_t nsWindowWatcher::CalculateChromeFlagsForContent(+@@ -1880,7 +1880,11 @@ uint32_t nsWindowWatcher::CalculateChromeFlagsForContent(// Open a minimal popup.*aIsPopupRequested = true;@@ -2699,10 +2744,10 @@ index 585a957fd8a1467dc262bd1ca2058584fd8762c9..16ad38c3b7d753c386e091af700d1beb/**diff --git a/toolkit/mozapps/update/UpdateService.sys.mjs b/toolkit/mozapps/update/UpdateService.sys.mjs-index b050236a46af8dc5f1b72559065c813db9343088..85873915d92d49fddff3b7c4330cbe2d39719f39 100644+index 40f04aeace0efd701e9454bb8dc6260dec90807e..5b70f65f3e78fc0889b15651ff203bb82e79d202 100644--- a/toolkit/mozapps/update/UpdateService.sys.mjs+++ b/toolkit/mozapps/update/UpdateService.sys.mjs-@@ -3752,6 +3752,8 @@ export class UpdateService {+@@ -3814,6 +3814,8 @@ export class UpdateService {}get disabledForTesting() {@@ -2723,22 +2768,6 @@ index c50b7f3932e18da9fad4b673e353974a001e78c4..708e0d75594ddcd62276d4e08c4bd5c6"/toolkit/components/telemetry/tests/marionette",]-diff --git a/toolkit/xre/nsAppRunner.cpp b/toolkit/xre/nsAppRunner.cpp-index 7a16ea20770dd945e743871e15e5b02da4842c60..e608a81c3b069b4a020da2d7807556975f603d33 100644---- a/toolkit/xre/nsAppRunner.cpp-+++ b/toolkit/xre/nsAppRunner.cpp-@@ -5669,7 +5669,10 @@ nsresult XREMain::XRE_mainRun() {-- if (!AppShutdown::IsInOrBeyond(ShutdownPhase::AppShutdownConfirmed)) {- #ifdef XP_MACOSX-- if (!BackgroundTasks::IsBackgroundTaskMode()) {-+# if defined(MOZ_BACKGROUNDTASKS)-+ if (!BackgroundTasks::IsBackgroundTaskMode())-+# endif // defined(MOZ_BACKGROUNDTASKS)-+ {- rv = appStartup->CreateHiddenWindow();- NS_ENSURE_SUCCESS(rv, NS_ERROR_FAILURE);- }diff --git a/toolkit/xre/nsWindowsWMain.cpp b/toolkit/xre/nsWindowsWMain.cppindex 7eb9e1104682d4eb47060654f43a1efa8b2a6bb2..a8315d6decf654b5302bea5beeea34140c300ded 100644--- a/toolkit/xre/nsWindowsWMain.cpp@@ -2792,7 +2821,7 @@ index e5cc386651e192710b61858ab5625c97a02b92da..e560ad4fef232a26ce1e1b244f4ccea0// nsDocumentViewer::LoadComplete that doesn't do various things// that are not relevant here because this wasn't an actualdiff --git a/uriloader/exthandler/nsExternalHelperAppService.cpp b/uriloader/exthandler/nsExternalHelperAppService.cpp-index 418902fc1d00a2f0bc06bd68402e8bb342485c0a..101a7b63128743862d404c3fcadaa2aa886a7f8a 100644+index e23df8e6f982ea71eb1f07dd677ed13109d2831b..d98f49d34a346113fd0ed5c242d5ef228ea0e0cd 100644--- a/uriloader/exthandler/nsExternalHelperAppService.cpp+++ b/uriloader/exthandler/nsExternalHelperAppService.cpp@@ -112,6 +112,7 @@@@ -3027,10 +3056,10 @@ index 5ca1a6fa13233b1bd00ee0467732c5875c51d343..0d3b8ebe127e59516802e8819f4bbed9mIgnoreCapturingContent = aEvent.mIgnoreCapturingContent;mClickEventPrevented = aEvent.mClickEventPrevented;diff --git a/widget/cocoa/NativeKeyBindings.mm b/widget/cocoa/NativeKeyBindings.mm-index e4bdf715e2fb899e97a5bfeb2e147127460d6047..3554f919480278b7353617481c7ce8050630a1aa 100644+index 24b70173c2e8bb9be9fd6255984a70efe3b14099..75ac367a1c4bb44d4b68b5f4ecc6adf56dbd408e 100644--- a/widget/cocoa/NativeKeyBindings.mm+++ b/widget/cocoa/NativeKeyBindings.mm-@@ -528,6 +528,13 @@+@@ -549,6 +549,13 @@break;case KEY_NAME_INDEX_ArrowLeft:if (aEvent.IsAlt()) {@@ -3044,7 +3073,7 @@ index e4bdf715e2fb899e97a5bfeb2e147127460d6047..3554f919480278b7353617481c7ce805break;}if (aEvent.IsMeta() || (aEvent.IsControl() && aEvent.IsShift())) {-@@ -550,6 +557,13 @@+@@ -571,6 +578,13 @@break;case KEY_NAME_INDEX_ArrowRight:if (aEvent.IsAlt()) {@@ -3058,7 +3087,7 @@ index e4bdf715e2fb899e97a5bfeb2e147127460d6047..3554f919480278b7353617481c7ce805break;}if (aEvent.IsMeta() || (aEvent.IsControl() && aEvent.IsShift())) {-@@ -572,6 +586,10 @@+@@ -593,6 +607,10 @@break;case KEY_NAME_INDEX_ArrowUp:if (aEvent.IsControl()) {@@ -3069,7 +3098,7 @@ index e4bdf715e2fb899e97a5bfeb2e147127460d6047..3554f919480278b7353617481c7ce805break;}if (aEvent.IsMeta()) {-@@ -582,7 +600,7 @@+@@ -603,7 +621,7 @@!aEvent.IsShift()? ToObjcSelectorPtr(@selector(moveToBeginningOfDocument:)): ToObjcSelectorPtr(@@ -3078,7 +3107,7 @@ index e4bdf715e2fb899e97a5bfeb2e147127460d6047..3554f919480278b7353617481c7ce805aCommands);break;}-@@ -609,6 +627,10 @@+@@ -630,6 +648,10 @@break;case KEY_NAME_INDEX_ArrowDown:if (aEvent.IsControl()) {@@ -3293,7 +3322,7 @@ index 39833c28e40c61e354119cde429b8389056bafac..a638fb7520b857219ce58fcbf9ca0ed9~HeadlessWidget();bool mEnabled;diff --git a/widget/nsGUIEventIPC.h b/widget/nsGUIEventIPC.h-index a1f48167403f5bfb30a66809ec3e64bea468fa05..eac7fccf3493e162629918462294456e6ee6b6e1 100644+index f7262978239665cbe20470da0790d4d177d4c501..70d11aca3d5b509cf5b37d626299a23fede73ba3 100644--- a/widget/nsGUIEventIPC.h+++ b/widget/nsGUIEventIPC.h@@ -244,6 +244,7 @@ struct ParamTraits<mozilla::WidgetMouseEvent> {diff --git a/browser_patches/firefox/preferences/playwright.cfg b/browser_patches/firefox/preferences/playwright.cfgindex b5c5e2254c..8c0404cbe7 100644--- a/browser_patches/firefox/preferences/playwright.cfg+++ b/browser_patches/firefox/preferences/playwright.cfg@@ -96,6 +96,14 @@ pref("geo.provider.testing", true);pref("media.getdisplaymedia.screencapturekit.enabled", false);pref("media.getdisplaymedia.screencapturekit.picker.enabled", false);+// Allow proxying loopback URLs; see https://phabricator.services.mozilla.com/D237187+pref("network.proxy.allow_hijacking_localhost", true);+pref("network.proxy.testing_localhost_is_secure_when_hijacked", true);++// Disable double-dispatching of "input" event for the text composition.+// See https://phabricator.services.mozilla.com/D234620 for details.+pref("dom.input_events.dispatch_before_compositionend", false);+// Enable software-backed webgl. See https://phabricator.services.mozilla.com/D164016pref("webgl.forbid-software", false);diff --git a/browser_patches/webkit/UPSTREAM_CONFIG.sh b/browser_patches/webkit/UPSTREAM_CONFIG.shindex 2cb5272893..a5ab8feea5 100644--- a/browser_patches/webkit/UPSTREAM_CONFIG.sh+++ b/browser_patches/webkit/UPSTREAM_CONFIG.sh@@ -1,3 +1,3 @@REMOTE_URL="https://github.com/WebKit/WebKit.git"BASE_BRANCH="main"-BASE_REVISION="ba8bcf39b0a89706b998447abba82590ad50fc36"+BASE_REVISION="4dd862e5ce1c10d77f72be94260164c5f13aafbd"diff --git a/browser_patches/webkit/embedder/Playwright/win/MainWindow.cpp b/browser_patches/webkit/embedder/Playwright/win/MainWindow.cppindex e74590c491..f8430a601d 100644--- a/browser_patches/webkit/embedder/Playwright/win/MainWindow.cpp+++ b/browser_patches/webkit/embedder/Playwright/win/MainWindow.cpp@@ -140,7 +140,7 @@ void MainWindow::createToolbar(HINSTANCE hInstance)SendMessage(m_hToolbarWnd, TB_ADDBUTTONS, _countof(tbButtons), reinterpret_cast<LPARAM>(&tbButtons));ShowWindow(m_hToolbarWnd, true);- m_hURLBarWnd = CreateWindow(L"EDIT", 0, WS_CHILD | WS_VISIBLE | WS_BORDER | ES_LEFT | ES_AUTOVSCROLL, 0, 0, 0, 0, m_hToolbarWnd, 0, hInstance, 0);+ m_hURLBarWnd = CreateWindow(L"EDIT", 0, WS_CHILD | WS_VISIBLE | WS_BORDER | ES_LEFT | ES_AUTOHSCROLL, 0, 0, 0, 0, m_hToolbarWnd, 0, hInstance, 0);DefEditProc = reinterpret_cast<WNDPROC>(GetWindowLongPtr(m_hURLBarWnd, GWLP_WNDPROC));SetWindowLongPtr(m_hURLBarWnd, GWLP_WNDPROC, reinterpret_cast<LONG_PTR>(EditProc));@@ -210,7 +210,9 @@ bool MainWindow::init(HINSTANCE hInstance, WKPageConfigurationRef conf)resizeSubViews();if (s_headless) {+ auto menu = GetMenu(m_hMainWnd);SetMenu(m_hMainWnd, NULL);+ DestroyMenu(menu);} else {SetFocus(m_hURLBarWnd);ShowWindow(m_hMainWnd, SW_SHOW);diff --git a/browser_patches/webkit/embedder/Playwright/win/Playwright.ico b/browser_patches/webkit/embedder/Playwright/win/Playwright.icoindex 0137fe83a5..cea0bdebc3 100644Binary files a/browser_patches/webkit/embedder/Playwright/win/Playwright.ico and b/browser_patches/webkit/embedder/Playwright/win/Playwright.ico differdiff --git a/browser_patches/webkit/patches/bootstrap.diff b/browser_patches/webkit/patches/bootstrap.diffindex a94e5b5ffa..573fbebe44 100644--- a/browser_patches/webkit/patches/bootstrap.diff+++ b/browser_patches/webkit/patches/bootstrap.diff@@ -1,8 +1,8 @@diff --git a/Source/JavaScriptCore/CMakeLists.txt b/Source/JavaScriptCore/CMakeLists.txt-index b52d8892843f6b934081c0e0b9f93264626937b5..d076e8ad848680e0a0b7790ff4b11bb768c72523 100644+index 27178e3306f1a1957516fbf90e101d1da144a8bd..ed99032196ff06fbe32cc3d88cdca110d0a29d30 100644--- a/Source/JavaScriptCore/CMakeLists.txt+++ b/Source/JavaScriptCore/CMakeLists.txt-@@ -1401,21 +1401,26 @@ set(JavaScriptCore_INSPECTOR_DOMAINS+@@ -1405,21 +1405,26 @@ set(JavaScriptCore_INSPECTOR_DOMAINS${JAVASCRIPTCORE_DIR}/inspector/protocol/CSS.json${JAVASCRIPTCORE_DIR}/inspector/protocol/Canvas.json${JAVASCRIPTCORE_DIR}/inspector/protocol/Console.json@@ -30,10 +30,10 @@ index b52d8892843f6b934081c0e0b9f93264626937b5..d076e8ad848680e0a0b7790ff4b11bb7${JAVASCRIPTCORE_DIR}/inspector/protocol/ServiceWorker.json${JAVASCRIPTCORE_DIR}/inspector/protocol/Target.jsondiff --git a/Source/JavaScriptCore/DerivedSources-input.xcfilelist b/Source/JavaScriptCore/DerivedSources-input.xcfilelist-index a92c371597d3af93bc7dd936efb1046ad899eaec..dc94df080778cb9b38b6a9cc3213d922505ff323 100644+index 4ebffbf7b080143afc4d9da6c516174cd08ffb5c..ddf59a7c8f336d9ee13b052c3ff685f1cadacd30 100644--- a/Source/JavaScriptCore/DerivedSources-input.xcfilelist+++ b/Source/JavaScriptCore/DerivedSources-input.xcfilelist-@@ -99,20 +99,25 @@ $(PROJECT_DIR)/inspector/protocol/CPUProfiler.json+@@ -97,20 +97,25 @@ $(PROJECT_DIR)/inspector/protocol/CPUProfiler.json$(PROJECT_DIR)/inspector/protocol/CSS.json$(PROJECT_DIR)/inspector/protocol/Canvas.json$(PROJECT_DIR)/inspector/protocol/Console.json@@ -60,10 +60,10 @@ index a92c371597d3af93bc7dd936efb1046ad899eaec..dc94df080778cb9b38b6a9cc3213d922$(PROJECT_DIR)/inspector/protocol/Security.json$(PROJECT_DIR)/inspector/protocol/ServiceWorker.jsondiff --git a/Source/JavaScriptCore/DerivedSources.make b/Source/JavaScriptCore/DerivedSources.make-index 706f3548b9a40b323d49af7d61f5bc59692a0da6..c2b49f4b97f34e512442c1a790ba794df2ae26cd 100644+index a37d9dfd55e0d0e20db0c984e594b685fbb96a9e..11e68adc7db68a30be854177a93984d074dbac85 100644--- a/Source/JavaScriptCore/DerivedSources.make+++ b/Source/JavaScriptCore/DerivedSources.make-@@ -302,21 +302,26 @@ INSPECTOR_DOMAINS := \+@@ -300,21 +300,26 @@ INSPECTOR_DOMAINS := \$(JavaScriptCore)/inspector/protocol/CSS.json \$(JavaScriptCore)/inspector/protocol/Canvas.json \$(JavaScriptCore)/inspector/protocol/Console.json \@@ -169,10 +169,10 @@ index 1f5d0adbf624bd24ef1e525967e6e82e8c37b4e5..4fe0f364b4ccd11774bf29f772e0a568// We could be called re-entrantly from a nested run loop, so restore the previous id.SetForScope scopedRequestId(m_currentRequestId, requestId);diff --git a/Source/JavaScriptCore/inspector/InspectorBackendDispatcher.h b/Source/JavaScriptCore/inspector/InspectorBackendDispatcher.h-index 2eba743177c016a3415d4a5deafc552e842dd0fa..939d14be7a2703777652467f0f60e67ef1c5e0f8 100644+index 28f4cdacf6ebd7037a42a75872618436332d90ec..463f014be2bd29a75bee7b2113b6f929da13aca5 100644--- a/Source/JavaScriptCore/inspector/InspectorBackendDispatcher.h+++ b/Source/JavaScriptCore/inspector/InspectorBackendDispatcher.h-@@ -83,8 +83,11 @@ public:+@@ -95,8 +95,11 @@ public:ServerError};@@ -391,7 +391,7 @@ index 04377b714a6ccb5294c65d592e74350621d470ba..b6de937bfa3e6185ce29f4e432d327a3// FrontendChannelFrontendChannel::ConnectionType connectionType() const;diff --git a/Source/JavaScriptCore/inspector/protocol/DOM.json b/Source/JavaScriptCore/inspector/protocol/DOM.json-index 27c65fbda226f1cd5bfd68944fe87fb9b2a688a6..b036f050859ee88004a7bf6daa4bb73835360615 100644+index 3fbb38e3ce2676cc569dc706d74b3fc7431eb3fb..e1dec7287ce55077bfeaa1a601c7ffdea0a61008 100644--- a/Source/JavaScriptCore/inspector/protocol/DOM.json+++ b/Source/JavaScriptCore/inspector/protocol/DOM.json@@ -80,6 +80,16 @@@@ -411,24 +411,7 @@ index 27c65fbda226f1cd5bfd68944fe87fb9b2a688a6..b036f050859ee88004a7bf6daa4bb738{"id": "EventListener","type": "object",-@@ -268,6 +278,16 @@- { "name": "width", "type": "number" },- { "name": "height", "type": "number" }- ]-+ },-+ {-+ "id": "FilePayload",-+ "type": "object",-+ "description": "Data to construct File object.",-+ "properties": [-+ { "name": "name", "type": "string", "description": "File name." },-+ { "name": "type", "type": "string", "description": "File type." },-+ { "name": "data", "type": "string", "description": "Base64-encoded file data." }-+ ]- }- ],- "commands": [-@@ -697,7 +717,10 @@+@@ -717,7 +727,10 @@"description": "Resolves JavaScript node object for given node id.","targetTypes": ["page"],"parameters": [@@ -440,7 +423,7 @@ index 27c65fbda226f1cd5bfd68944fe87fb9b2a688a6..b036f050859ee88004a7bf6daa4bb738{ "name": "objectGroup", "type": "string", "optional": true, "description": "Symbolic group name that can be used to release multiple objects." }],"returns": [-@@ -774,6 +797,47 @@+@@ -794,6 +807,46 @@"returns": [{ "name": "mediaStats", "$ref": "MediaStats", "description": "An interleaved array of node attribute names and values." }]@@ -481,8 +464,7 @@ index 27c65fbda226f1cd5bfd68944fe87fb9b2a688a6..b036f050859ee88004a7bf6daa4bb738+ "description": "Sets input files for given <input type=file>",+ "parameters": [+ { "name": "objectId", "$ref": "Runtime.RemoteObjectId", "description": "Input element handle." },-+ { "name": "files", "type": "array", "items": { "$ref": "FilePayload" }, "optional": true, "description": "Files to set" },-+ { "name": "paths", "type": "array", "items": { "type": "string" }, "optional": true, "description": "File paths to set" }++ { "name": "paths", "type": "array", "items": { "type": "string" }, "description": "File paths to set" }+ ],+ "async": true}@@ -1697,7 +1679,7 @@ index 24891ad836086fd23024fcb4d08ca63f6974c812..29f4b6b1923383fec7a99d28a4e815dcprivate:enum ArgumentRequirement { ArgumentRequired, ArgumentNotRequired };diff --git a/Source/ThirdParty/libwebrtc/CMakeLists.txt b/Source/ThirdParty/libwebrtc/CMakeLists.txt-index 2ccb951b0cf57707b68ce5e971c5e191b91f2bd0..6ff141b41f4b6c279c367ad66d5c2b6adede8646 100644+index ca4f3508a44e3c6677a72fbe3d7c853714b4f2c6..ae117f5f402a7eb259e376ca9440e00062e22d9f 100644--- a/Source/ThirdParty/libwebrtc/CMakeLists.txt+++ b/Source/ThirdParty/libwebrtc/CMakeLists.txt@@ -532,6 +532,11 @@ set(webrtc_SOURCES@@ -1712,15 +1694,7 @@ index 2ccb951b0cf57707b68ce5e971c5e191b91f2bd0..6ff141b41f4b6c279c367ad66d5c2b6aSource/third_party/libyuv/source/compare.ccSource/third_party/libyuv/source/compare_common.ccSource/third_party/libyuv/source/compare_gcc.cc-@@ -695,7 +700,6 @@ set(webrtc_SOURCES- Source/webrtc/api/video_codecs/builtin_video_encoder_factory.cc- Source/webrtc/api/video_codecs/h264_profile_level_id.cc- Source/webrtc/api/video_codecs/h265_profile_tier_level.cc-- Source/webrtc/api/video_codecs/libaom_av1_encoder_factory.cc- Source/webrtc/api/video_codecs/scalability_mode.cc- Source/webrtc/api/video_codecs/scalability_mode_helper.cc- Source/webrtc/api/video_codecs/sdp_video_format.cc-@@ -2350,6 +2354,11 @@ set(webrtc_INCLUDE_DIRECTORIES PRIVATE+@@ -2348,6 +2353,11 @@ set(webrtc_INCLUDE_DIRECTORIES PRIVATESource/third_party/libsrtp/configSource/third_party/libsrtp/crypto/includeSource/third_party/libsrtp/include@@ -1746,13 +1720,13 @@ index 0c5c8e689bdddec766f9de5bffd4444a5e068d77..330dd1f585e530722178c65c883641a2// FIXME: Set WEBRTC_USE_BUILTIN_ISAC_FIX and WEBRTC_USE_BUILTIN_ISAC_FLOAT for iOS and Macdiff --git a/Source/ThirdParty/libwebrtc/Configurations/libwebrtc.exp b/Source/ThirdParty/libwebrtc/Configurations/libwebrtc.exp-index 6c754858a3ea883a65ad022ce16b6c45ae65ee35..15f968472712e1a2a88672ed290b103cf9d620ec 100644+index f7995f8f8b7af9fb6b28fe81b371a16700549cdf..c372447fbe21912803997876f95b5ca263cb47b5 100644--- a/Source/ThirdParty/libwebrtc/Configurations/libwebrtc.exp+++ b/Source/ThirdParty/libwebrtc/Configurations/libwebrtc.exp-@@ -421,3 +421,16 @@ __ZNK8mkvmuxer7Segment16GetTrackByNumberEy- __ZN8mkvmuxer6Tracks11kAv1CodecIdE- __ZN8mkvmuxer6Tracks11kVp8CodecIdE- __ZN8mkvmuxer6Tracks11kVp9CodecIdE+@@ -425,3 +425,16 @@ __ZN6webrtc21SdpSerializeCandidateERKN7cricket9CandidateE+ __ZNK6webrtc18VideoFrameMetadata8GetCsrcsEv+ __ZN6webrtc15CloneAudioFrameEPNS_32TransformableAudioFrameInterfaceE+ __ZN6webrtc15CloneVideoFrameEPNS_32TransformableVideoFrameInterfaceE+__ZN8mkvmuxer11SegmentInfo4InitEv+__ZN8mkvmuxer9MkvWriterC1EP7__sFILE+_ARGBToI420@@ -1767,10 +1741,10 @@ index 6c754858a3ea883a65ad022ce16b6c45ae65ee35..15f968472712e1a2a88672ed290b103c+_vpx_codec_version_str+_vpx_codec_vp8_cxdiff --git a/Source/ThirdParty/libwebrtc/libwebrtc.xcodeproj/project.pbxproj b/Source/ThirdParty/libwebrtc/libwebrtc.xcodeproj/project.pbxproj-index 2c30b5b08d589c82def812fb881a63cb6e49e7b4..c76a8a2963923bf54c3d134aa2594150c43a4b3c 100644+index 7585b2e5e9bffdc8cabd888dd822313d53b30141..5909d33b9726cdc7d2d53b538f7da18bc221e30b 100644--- a/Source/ThirdParty/libwebrtc/libwebrtc.xcodeproj/project.pbxproj+++ b/Source/ThirdParty/libwebrtc/libwebrtc.xcodeproj/project.pbxproj-@@ -55,6 +55,20 @@+@@ -56,6 +56,20 @@};/* End PBXAggregateTarget section */@@ -1791,7 +1765,7 @@ index 2c30b5b08d589c82def812fb881a63cb6e49e7b4..c76a8a2963923bf54c3d134aa2594150/* Begin PBXBuildFile section */2D6BFF60280A93DF00A1A74F /* video_coding.h in Headers */ = {isa = PBXBuildFile; fileRef = 4131C45B234C81710028A615 /* video_coding.h */; settings = {ATTRIBUTES = (Public, ); }; };2D6BFF61280A93EC00A1A74F /* video_codec_initializer.h in Headers */ = {isa = PBXBuildFile; fileRef = 4131C45E234C81720028A615 /* video_codec_initializer.h */; settings = {ATTRIBUTES = (Public, ); }; };-@@ -5772,6 +5786,13 @@+@@ -5786,6 +5800,13 @@remoteGlobalIDString = DDF30D0527C5C003006A526F;remoteInfo = absl;};@@ -1805,7 +1779,7 @@ index 2c30b5b08d589c82def812fb881a63cb6e49e7b4..c76a8a2963923bf54c3d134aa2594150/* End PBXContainerItemProxy section *//* Begin PBXCopyFilesBuildPhase section */-@@ -24241,6 +24262,7 @@+@@ -24271,6 +24292,7 @@);dependencies = (410B3827292B73E90003E515 /* PBXTargetDependency */,@@ -1813,7 +1787,7 @@ index 2c30b5b08d589c82def812fb881a63cb6e49e7b4..c76a8a2963923bf54c3d134aa2594150DD2E76E827C6B69A00F2A74C /* PBXTargetDependency */,CDEBB4CC24C01AB400ADBD44 /* PBXTargetDependency */,411ED040212E0811004320BA /* PBXTargetDependency */,-@@ -24334,6 +24356,7 @@+@@ -24364,6 +24386,7 @@4460B8B92B155B6A00392062 /* vp9_qp_parser_fuzzer */,444A6EF02AEADFC9005FE121 /* vp9_replay_fuzzer */,44945C512B9BA1C300447FFD /* webm_fuzzer */,@@ -1821,7 +1795,7 @@ index 2c30b5b08d589c82def812fb881a63cb6e49e7b4..c76a8a2963923bf54c3d134aa2594150);};/* End PBXProject section */-@@ -24437,6 +24460,23 @@+@@ -24467,6 +24490,23 @@shellPath = /bin/sh;shellScript = "[ -z \"${WK_DERIVED_SDK_HEADERS_DIR}\" -o -d \"${WK_DERIVED_SDK_HEADERS_DIR}\" ] && touch \"${SCRIPT_OUTPUT_FILE_0}\"\n";};@@ -1845,7 +1819,7 @@ index 2c30b5b08d589c82def812fb881a63cb6e49e7b4..c76a8a2963923bf54c3d134aa2594150/* End PBXShellScriptBuildPhase section *//* Begin PBXSourcesBuildPhase section */-@@ -27400,6 +27440,11 @@+@@ -27437,6 +27477,11 @@target = DDF30D0527C5C003006A526F /* absl */;targetProxy = DD2E76E727C6B69A00F2A74C /* PBXContainerItemProxy */;};@@ -1857,7 +1831,7 @@ index 2c30b5b08d589c82def812fb881a63cb6e49e7b4..c76a8a2963923bf54c3d134aa2594150/* End PBXTargetDependency section *//* Begin XCBuildConfiguration section */-@@ -28167,6 +28212,27 @@+@@ -28204,6 +28249,27 @@};name = Production;};@@ -1885,7 +1859,7 @@ index 2c30b5b08d589c82def812fb881a63cb6e49e7b4..c76a8a2963923bf54c3d134aa2594150FB39D0711200ED9200088E69 /* Debug */ = {isa = XCBuildConfiguration;baseConfigurationReference = 5D7C59C71208C68B001C873E /* DebugRelease.xcconfig */;-@@ -28549,6 +28615,16 @@+@@ -28586,6 +28652,16 @@defaultConfigurationIsVisible = 0;defaultConfigurationName = Production;};@@ -1903,7 +1877,7 @@ index 2c30b5b08d589c82def812fb881a63cb6e49e7b4..c76a8a2963923bf54c3d134aa2594150isa = XCConfigurationList;buildConfigurations = (diff --git a/Source/ThirdParty/skia/CMakeLists.txt b/Source/ThirdParty/skia/CMakeLists.txt-index 74b12c3ccae8b65ad3a35063bece92a9ecb27cbe..1656508a1c5a2103b2bab3068305c6bdba7f0208 100644+index 6bfc5cba986488f3d808ebd0583c476cd93da70e..f4c4222d17bce640355ba52e00152069d5b14432 100644--- a/Source/ThirdParty/skia/CMakeLists.txt+++ b/Source/ThirdParty/skia/CMakeLists.txt@@ -10,6 +10,8 @@ if (USE_SKIA_ENCODERS)@@ -1915,7 +1889,7 @@ index 74b12c3ccae8b65ad3a35063bece92a9ecb27cbe..1656508a1c5a2103b2bab3068305c6bdif (ANDROID)find_package(EXPAT REQUIRED)endif ()-@@ -947,6 +949,7 @@ endif ()+@@ -948,6 +950,7 @@ endif ()target_link_libraries(Skia PRIVATEJPEG::JPEGPNG::PNG@@ -1923,8 +1897,20 @@ index 74b12c3ccae8b65ad3a35063bece92a9ecb27cbe..1656508a1c5a2103b2bab3068305c6bd)WEBKIT_ADD_TARGET_CXX_FLAGS(Skia+diff --git a/Source/ThirdParty/skia/src/opts/SkOpts_SetTarget.h b/Source/ThirdParty/skia/src/opts/SkOpts_SetTarget.h+index 525cfcb862ae96bf8573d00b67dc9e5e23c10d22..f2debc0444cb8f5b80a0e99a2214bceaab3960c1 100644+--- a/Source/ThirdParty/skia/src/opts/SkOpts_SetTarget.h++++ b/Source/ThirdParty/skia/src/opts/SkOpts_SetTarget.h+@@ -65,6 +65,7 @@+ // Each of the specific intrinsic headers also checks to ensure that immintrin.h has been+ // included, so do that here, first.+ #if defined(__clang__) && defined(_MSC_VER)++ #define __RTMINTRIN_H // Workaround for https://github.com/llvm/llvm-project/issues/95133+ #include <immintrin.h>+ #endif+diff --git a/Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml b/Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml-index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddd2ca52c 100644+index e6e1af5d1973c991229948e0b1eb0d5c456f846f..7fb6e2455bd489c5b5f9f2169fea5a2f9865bf91 100644--- a/Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml+++ b/Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml@@ -602,6 +602,7 @@ ApplePayEnabled:@@ -1958,7 +1944,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falseBlobRegistryTopOriginPartitioningEnabled:-@@ -2270,6 +2268,7 @@ CrossOriginEmbedderPolicyEnabled:+@@ -2312,6 +2310,7 @@ CrossOriginEmbedderPolicyEnabled:WebCore:default: false@@ -1966,7 +1952,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0dCrossOriginOpenerPolicyEnabled:type: boolstatus: stable-@@ -2310,7 +2309,7 @@ CustomPasteboardDataEnabled:+@@ -2352,7 +2351,7 @@ CustomPasteboardDataEnabled:WebKitLegacy:default: falseWebKit:@@ -1975,7 +1961,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falseDOMAudioSessionEnabled:-@@ -2343,6 +2342,7 @@ DOMAudioSessionFullEnabled:+@@ -2385,6 +2384,7 @@ DOMAudioSessionFullEnabled:WebCore:default: false@@ -1983,7 +1969,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0dDOMPasteAccessRequestsEnabled:type: boolstatus: internal-@@ -2354,7 +2354,7 @@ DOMPasteAccessRequestsEnabled:+@@ -2396,7 +2396,7 @@ DOMPasteAccessRequestsEnabled:default: falseWebKit:"PLATFORM(IOS) || PLATFORM(MAC) || PLATFORM(GTK) || PLATFORM(VISION)": true@@ -1992,7 +1978,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0dWebCore:default: false-@@ -2420,10 +2420,10 @@ DataListElementEnabled:+@@ -2462,10 +2462,10 @@ DataListElementEnabled:WebKitLegacy:default: falseWebKit:@@ -2005,7 +1991,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falsesharedPreferenceForWebProcess: true-@@ -2436,7 +2436,7 @@ DataTransferItemsEnabled:+@@ -2478,7 +2478,7 @@ DataTransferItemsEnabled:WebKitLegacy:default: trueWebKit:@@ -2014,7 +2000,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falseWebCore:default: false-@@ -2691,7 +2691,7 @@ DirectoryUploadEnabled:+@@ -2734,7 +2734,7 @@ DirectoryUploadEnabled:WebKitLegacy:default: falseWebKit:@@ -2023,7 +2009,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falseWebCore:default: false-@@ -3143,10 +3143,10 @@ FullScreenEnabled:+@@ -3202,10 +3202,10 @@ FullScreenEnabled:WebKitLegacy:default: falseWebKit:@@ -2036,7 +2022,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falsesharedPreferenceForWebProcess: true-@@ -3707,7 +3707,7 @@ InputTypeColorEnabled:+@@ -3811,7 +3811,7 @@ InputTypeColorEnabled:WebKitLegacy:default: falseWebKit:@@ -2045,7 +2031,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falseWebCore:default: false-@@ -3740,7 +3740,7 @@ InputTypeDateEnabled:+@@ -3844,7 +3844,7 @@ InputTypeDateEnabled:"PLATFORM(IOS_FAMILY)": truedefault: falseWebKit:@@ -2054,7 +2040,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falseWebCore:default: false-@@ -3756,7 +3756,7 @@ InputTypeDateTimeLocalEnabled:+@@ -3860,7 +3860,7 @@ InputTypeDateTimeLocalEnabled:"PLATFORM(IOS_FAMILY)": truedefault: falseWebKit:@@ -2063,7 +2049,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falseWebCore:default: false-@@ -3788,7 +3788,7 @@ InputTypeTimeEnabled:+@@ -3892,7 +3892,7 @@ InputTypeTimeEnabled:"PLATFORM(IOS_FAMILY)": truedefault: falseWebKit:@@ -2072,24 +2058,24 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falseWebCore:default: false-@@ -3836,6 +3836,7 @@ InspectorAttachmentSide:- WebKit:- default: 0+@@ -3953,6 +3953,7 @@ InspectorMaximumResourcesContentSize:+ "PLATFORM(WPE)": 50+ default: 200+# Playwright: disable setting.InspectorStartsAttached:type: boolstatus: embedder-@@ -3843,7 +3844,7 @@ InspectorStartsAttached:+@@ -3960,7 +3961,7 @@ InspectorStartsAttached:exposed: [ WebKit ]defaultValue:WebKit:- default: true+ default: false- InspectorWindowFrame:- type: String-@@ -5778,7 +5779,7 @@ PermissionsAPIEnabled:+ InspectorSupportsShowingCertificate:+ type: bool+@@ -5911,7 +5912,7 @@ PermissionsAPIEnabled:WebKitLegacy:default: falseWebKit:@@ -2098,7 +2084,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falseWebCore:default: false-@@ -5841,6 +5842,19 @@ PitchCorrectionAlgorithm:+@@ -5990,6 +5991,19 @@ PitchCorrectionAlgorithm:WebCore:default: MediaPlayerEnums::PitchCorrectionAlgorithm::BestAllAround@@ -2118,7 +2104,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0dPointerLockOptionsEnabled:type: boolstatus: stable-@@ -6420,7 +6434,7 @@ ScreenOrientationAPIEnabled:+@@ -6586,7 +6600,7 @@ ScreenOrientationAPIEnabled:WebKitLegacy:default: falseWebKit:@@ -2127,7 +2113,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0dWebCore:default: falsesharedPreferenceForWebProcess: true-@@ -7879,6 +7893,7 @@ UseCGDisplayListsForDOMRendering:+@@ -8063,6 +8077,7 @@ UseCGDisplayListsForDOMRendering:default: truesharedPreferenceForWebProcess: true@@ -2135,7 +2121,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0dUseGPUProcessForCanvasRenderingEnabled:type: boolstatus: stable-@@ -7891,7 +7906,7 @@ UseGPUProcessForCanvasRenderingEnabled:+@@ -8075,7 +8090,7 @@ UseGPUProcessForCanvasRenderingEnabled:defaultValue:WebKit:"ENABLE(GPU_PROCESS_BY_DEFAULT)": true@@ -2144,7 +2130,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0ddefault: falseUseGPUProcessForDOMRenderingEnabled:-@@ -7936,6 +7951,7 @@ UseGPUProcessForMediaEnabled:+@@ -8120,6 +8135,7 @@ UseGPUProcessForMediaEnabled:sharedPreferenceForWebProcess: truemediaPlaybackRelated: true@@ -2152,7 +2138,7 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0dUseGPUProcessForWebGLEnabled:type: boolstatus: internal-@@ -7947,7 +7963,7 @@ UseGPUProcessForWebGLEnabled:+@@ -8131,7 +8147,7 @@ UseGPUProcessForWebGLEnabled:default: falseWebKit:"ENABLE(GPU_PROCESS_BY_DEFAULT) && ENABLE(GPU_PROCESS_WEBGL_BY_DEFAULT)": true@@ -2162,10 +2148,10 @@ index 02d962ba310f7e231c84657823766c834ae5b6a6..44587b824e07c1d8a9fa99b32a02da0dWebCore:"ENABLE(GPU_PROCESS_BY_DEFAULT) && ENABLE(GPU_PROCESS_WEBGL_BY_DEFAULT)": truediff --git a/Source/WTF/wtf/PlatformEnable.h b/Source/WTF/wtf/PlatformEnable.h-index d86540738b2e5e66811b67dd07889c6188126dd7..128f697e7a46b2c6af7716933ee8845228eaba0e 100644+index 0652dc379f7322cd7af4078cf1b6c54588565aea..51ce8260d8889c6e3dbef09bfff48177b9cf9f0a 100644--- a/Source/WTF/wtf/PlatformEnable.h+++ b/Source/WTF/wtf/PlatformEnable.h-@@ -385,7 +385,7 @@+@@ -387,7 +387,7 @@// ORIENTATION_EVENTS should never get enabled on Desktop, only Mobile.#if !defined(ENABLE_ORIENTATION_EVENTS)@@ -2174,7 +2160,7 @@ index d86540738b2e5e66811b67dd07889c6188126dd7..128f697e7a46b2c6af7716933ee88452#endif#if !defined(ENABLE_OVERFLOW_SCROLLING_TOUCH)-@@ -502,7 +502,7 @@+@@ -504,7 +504,7 @@#endif#if !defined(ENABLE_TOUCH_EVENTS)@@ -2184,10 +2170,10 @@ index d86540738b2e5e66811b67dd07889c6188126dd7..128f697e7a46b2c6af7716933ee88452#if !defined(ENABLE_TOUCH_ACTION_REGIONS)diff --git a/Source/WTF/wtf/PlatformEnableCocoa.h b/Source/WTF/wtf/PlatformEnableCocoa.h-index bacd225fea9dc695e021649fc6d74012e300be27..9e5497d6f0ecca35bbb5fc2a53f36ee8a3b39435 100644+index e416fc014aa5731d77f7a3a440b762a9814f6ef5..00a67ad2516627e982763f4684fb951741517817 100644--- a/Source/WTF/wtf/PlatformEnableCocoa.h+++ b/Source/WTF/wtf/PlatformEnableCocoa.h-@@ -813,7 +813,7 @@+@@ -817,7 +817,7 @@#endif#if !defined(ENABLE_SEC_ITEM_SHIM)@@ -2197,10 +2183,10 @@ index bacd225fea9dc695e021649fc6d74012e300be27..9e5497d6f0ecca35bbb5fc2a53f36ee8#if !defined(ENABLE_SERVER_PRECONNECT)diff --git a/Source/WTF/wtf/PlatformHave.h b/Source/WTF/wtf/PlatformHave.h-index 93e12dd54312a4c8479687b9f175c948250339f8..b39779453f1d51c302e5c5a39d58594a63eb22a2 100644+index e4a8591c4a4e0d682cdf3d4232e25e6af963ba16..96a65e06d788995714bafc95bde3ad8bf21bc2e8 100644--- a/Source/WTF/wtf/PlatformHave.h+++ b/Source/WTF/wtf/PlatformHave.h-@@ -1220,7 +1220,8 @@+@@ -1198,7 +1198,8 @@#endif#if PLATFORM(MAC)@@ -2227,10 +2213,10 @@ index 007b8fe3292f326504013be8198ae020f7aacf35..1c722c473732ffe05fdb61010fa4417enamespace Unicode {diff --git a/Source/WebCore/DerivedSources.make b/Source/WebCore/DerivedSources.make-index 6b62ff89947f5a393ee50381af9f6ddfecc91037..202376ddb4a475a23e0379e26f866451c6e184ba 100644+index d0e3444bd9699dfe2bc1c85dde2ad5543d71b0df..b624441883bfa4ea04ee22fef2c38ad0daabe479 100644--- a/Source/WebCore/DerivedSources.make+++ b/Source/WebCore/DerivedSources.make-@@ -1221,6 +1221,10 @@ JS_BINDING_IDLS := \+@@ -1229,6 +1229,10 @@ JS_BINDING_IDLS := \$(WebCore)/dom/SubscriberCallback.idl \$(WebCore)/dom/SubscriptionObserver.idl \$(WebCore)/dom/SubscriptionObserverCallback.idl \@@ -2241,7 +2227,7 @@ index 6b62ff89947f5a393ee50381af9f6ddfecc91037..202376ddb4a475a23e0379e26f866451$(WebCore)/dom/Text.idl \$(WebCore)/dom/TextDecoder.idl \$(WebCore)/dom/TextDecoderStream.idl \-@@ -1821,9 +1825,6 @@ JS_BINDING_IDLS := \+@@ -1829,9 +1833,6 @@ JS_BINDING_IDLS := \ADDITIONAL_BINDING_IDLS = \DocumentTouch.idl \GestureEvent.idl \@@ -2252,7 +2238,7 @@ index 6b62ff89947f5a393ee50381af9f6ddfecc91037..202376ddb4a475a23e0379e26f866451vpath %.in $(WEBKITADDITIONS_HEADER_SEARCH_PATHS)diff --git a/Source/WebCore/Modules/geolocation/Geolocation.cpp b/Source/WebCore/Modules/geolocation/Geolocation.cpp-index d66eb4a0c175ab495ef10bd393115165b5545fc2..cd89bd44bd2a8b3036c3446c01475bf726a3a18a 100644+index 05091a46212f00333ed97939a6ec18d8656657e9..3fb779a3eba806cf416d0dd7586be871d4782651 100644--- a/Source/WebCore/Modules/geolocation/Geolocation.cpp+++ b/Source/WebCore/Modules/geolocation/Geolocation.cpp@@ -361,8 +361,9 @@ bool Geolocation::shouldBlockGeolocationRequests()@@ -2316,10 +2302,10 @@ index 7bbcd501126a7b83986f5d1f5a077779441dc1fe..13e68ac853603d8e7da1b42f5c8073ebset(WebCore_USER_AGENT_SCRIPTS_DEPENDENCIES ${WEBCORE_DIR}/platform/wpe/RenderThemeWPE.cpp)diff --git a/Source/WebCore/SourcesCocoa.txt b/Source/WebCore/SourcesCocoa.txt-index 7cd931c48dd3c7c4cc6136c91692054ca98e6ddf..e32cfb28521033f1713bd963ba9825a9500f4fc9 100644+index 06a9accfc8e6c46493733663b5d76b07fc80db22..4946d012d166c84b25d4d954266c4dc528f7d8ad 100644--- a/Source/WebCore/SourcesCocoa.txt+++ b/Source/WebCore/SourcesCocoa.txt-@@ -733,3 +733,9 @@ testing/cocoa/WebViewVisualIdentificationOverlay.mm+@@ -734,3 +734,9 @@ testing/cocoa/WebViewVisualIdentificationOverlay.mmplatform/graphics/angle/GraphicsContextGLANGLE.cpp @no-unifyplatform/graphics/cocoa/GraphicsContextGLCocoa.mm @no-unifyplatform/graphics/cv/GraphicsContextGLCVCocoa.mm @no-unify@@ -2345,7 +2331,7 @@ index 9cc9f51e48b3058ea29da389629c021bcf05e202..978ac405073534ba6fa79f483d885643+JSSpeechSynthesisEventInit.cpp+// Playwright: end.diff --git a/Source/WebCore/SourcesWPE.txt b/Source/WebCore/SourcesWPE.txt-index f785335022a20f31c8941c0aabd8895a17f71a3e..a3516d2db0cef38b3257b4b8653711f90f24c257 100644+index 5fd26e859ef215fccd597ca475a320abcad83b98..f422c4023eb1c9f101d989ce56e4b4b42e203c83 100644--- a/Source/WebCore/SourcesWPE.txt+++ b/Source/WebCore/SourcesWPE.txt@@ -46,6 +46,8 @@ editing/libwpe/EditorLibWPE.cpp@@ -2357,7 +2343,7 @@ index f785335022a20f31c8941c0aabd8895a17f71a3e..a3516d2db0cef38b3257b4b8653711f9page/linux/ResourceUsageOverlayLinux.cpppage/linux/ResourceUsageThreadLinux.cpp-@@ -89,6 +91,17 @@ platform/text/LocaleICU.cpp+@@ -91,6 +93,17 @@ platform/android/SharedMemoryAndroid.cppplatform/unix/LoggingUnix.cppplatform/unix/SharedMemoryUnix.cpp@@ -2376,10 +2362,10 @@ index f785335022a20f31c8941c0aabd8895a17f71a3e..a3516d2db0cef38b3257b4b8653711f9+JSSpeechSynthesisEventInit.cpp+// Playwright: end.diff --git a/Source/WebCore/WebCore.xcodeproj/project.pbxproj b/Source/WebCore/WebCore.xcodeproj/project.pbxproj-index d58402bdd7423c3274088b4e35a22922a107062a..4dc6b7adcaf5a34ffbe0b4aad5552a17daa926e7 100644+index 656e474f969c44c344c87d53aca6981071b39ef5..c8cf5ab6da2a5d2a2c2a723e52a32e2bee261846 100644--- a/Source/WebCore/WebCore.xcodeproj/project.pbxproj+++ b/Source/WebCore/WebCore.xcodeproj/project.pbxproj-@@ -6404,6 +6404,13 @@+@@ -6432,6 +6432,13 @@EE0C7E042CE845CB0043DAF8 /* CSSPositionTryRule.h in Headers */ = {isa = PBXBuildFile; fileRef = EE0C7E002CE845CB0043DAF8 /* CSSPositionTryRule.h */; };EE0D3C492D2F4B4C00072978 /* StageModeOperations.h in Headers */ = {isa = PBXBuildFile; fileRef = EE0D3C482D2F4AE600072978 /* StageModeOperations.h */; settings = {ATTRIBUTES = (Private, ); }; };EFCC6C8F20FE914400A2321B /* CanvasActivityRecord.h in Headers */ = {isa = PBXBuildFile; fileRef = EFCC6C8D20FE914000A2321B /* CanvasActivityRecord.h */; settings = {ATTRIBUTES = (Private, ); }; };@@ -2393,7 +2379,7 @@ index d58402bdd7423c3274088b4e35a22922a107062a..4dc6b7adcaf5a34ffbe0b4aad5552a17F12171F616A8CF0B000053CA /* WebVTTElement.h in Headers */ = {isa = PBXBuildFile; fileRef = F12171F416A8BC63000053CA /* WebVTTElement.h */; };F32BDCD92363AACA0073B6AE /* UserGestureEmulationScope.h in Headers */ = {isa = PBXBuildFile; fileRef = F32BDCD72363AACA0073B6AE /* UserGestureEmulationScope.h */; };F344C7141125B82C00F26EEE /* InspectorFrontendClient.h in Headers */ = {isa = PBXBuildFile; fileRef = F344C7121125B82C00F26EEE /* InspectorFrontendClient.h */; settings = {ATTRIBUTES = (Private, ); }; };-@@ -21038,6 +21045,14 @@+@@ -21095,6 +21102,14 @@EE7A169F2C607BFA0057B563 /* StartViewTransitionOptions.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = StartViewTransitionOptions.h; sourceTree = "<group>"; };EFB7287B2124C73D005C2558 /* CanvasActivityRecord.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = CanvasActivityRecord.cpp; sourceTree = "<group>"; };EFCC6C8D20FE914000A2321B /* CanvasActivityRecord.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CanvasActivityRecord.h; sourceTree = "<group>"; };@@ -2408,7 +2394,7 @@ index d58402bdd7423c3274088b4e35a22922a107062a..4dc6b7adcaf5a34ffbe0b4aad5552a17F12171F316A8BC63000053CA /* WebVTTElement.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebVTTElement.cpp; sourceTree = "<group>"; };F12171F416A8BC63000053CA /* WebVTTElement.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebVTTElement.h; sourceTree = "<group>"; };F32BDCD52363AAC90073B6AE /* UserGestureEmulationScope.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UserGestureEmulationScope.cpp; sourceTree = "<group>"; };-@@ -28800,6 +28815,11 @@+@@ -28876,6 +28891,11 @@BC4A5324256055590028C592 /* TextDirectionSubmenuInclusionBehavior.h */,2D4F96F11A1ECC240098BF88 /* TextIndicator.cpp */,2D4F96F21A1ECC240098BF88 /* TextIndicator.h */,@@ -2420,7 +2406,7 @@ index d58402bdd7423c3274088b4e35a22922a107062a..4dc6b7adcaf5a34ffbe0b4aad5552a17F48570A42644C76D00C05F71 /* TranslationContextMenuInfo.h */,F4E1965F21F26E4E00285078 /* UndoItem.cpp */,2ECDBAD521D8906300F00ECD /* UndoItem.h */,-@@ -35771,6 +35791,8 @@+@@ -35855,6 +35875,8 @@29E4D8DF16B0940F00C84704 /* PlatformSpeechSynthesizer.h */,1AD8F81A11CAB9E900E93E54 /* PlatformStrategies.cpp */,1AD8F81911CAB9E900E93E54 /* PlatformStrategies.h */,@@ -2429,7 +2415,7 @@ index d58402bdd7423c3274088b4e35a22922a107062a..4dc6b7adcaf5a34ffbe0b4aad5552a17FE3DC9932D0C063C0021B6FC /* PlatformTZoneImpls.cpp */,0FD7C21D23CE41E30096D102 /* PlatformWheelEvent.cpp */,935C476A09AC4D4F00A6AAB4 /* PlatformWheelEvent.h */,-@@ -38569,6 +38591,7 @@+@@ -38674,6 +38696,7 @@AD6E71AB1668899D00320C13 /* DocumentSharedObjectPool.h */,6BDB5DC1227BD3B800919770 /* DocumentStorageAccess.cpp */,6BDB5DC0227BD3B800919770 /* DocumentStorageAccess.h */,@@ -2437,7 +2423,7 @@ index d58402bdd7423c3274088b4e35a22922a107062a..4dc6b7adcaf5a34ffbe0b4aad5552a177CE7FA5B1EF882300060C9D6 /* DocumentTouch.cpp */,7CE7FA591EF882300060C9D6 /* DocumentTouch.h */,A8185F3209765765005826D9 /* DocumentType.cpp */,-@@ -43482,6 +43505,8 @@+@@ -43613,6 +43636,8 @@F4E90A3C2B52038E002DA469 /* PlatformTextAlternatives.h in Headers */,0F7D07331884C56C00B4AF86 /* PlatformTextTrack.h in Headers */,074E82BB18A69F0E007EF54C /* PlatformTimeRanges.h in Headers */,@@ -2446,7 +2432,7 @@ index d58402bdd7423c3274088b4e35a22922a107062a..4dc6b7adcaf5a34ffbe0b4aad5552a17CDD08ABD277E542600EA3755 /* PlatformTrackConfiguration.h in Headers */,CD1F9B022700323D00617EB6 /* PlatformVideoColorPrimaries.h in Headers */,CD1F9B01270020B700617EB6 /* PlatformVideoColorSpace.h in Headers */,-@@ -44827,6 +44852,7 @@+@@ -44969,6 +44994,7 @@0F54DD081881D5F5003EEDBB /* Touch.h in Headers */,71B7EE0D21B5C6870031C1EF /* TouchAction.h in Headers */,0F54DD091881D5F5003EEDBB /* TouchEvent.h in Headers */,@@ -2454,7 +2440,7 @@ index d58402bdd7423c3274088b4e35a22922a107062a..4dc6b7adcaf5a34ffbe0b4aad5552a170F54DD0A1881D5F5003EEDBB /* TouchList.h in Headers */,070334D71459FFD5008D8D45 /* TrackBase.h in Headers */,BE88E0C21715CE2600658D98 /* TrackListBase.h in Headers */,-@@ -46007,6 +46033,8 @@+@@ -46169,6 +46195,8 @@2D22830323A8470700364B7E /* CursorMac.mm in Sources */,5CBD59592280E926002B22AA /* CustomHeaderFields.cpp in Sources */,07E4BDBF2A3A5FAB000D5509 /* DictationCaretAnimator.cpp in Sources */,@@ -2463,7 +2449,7 @@ index d58402bdd7423c3274088b4e35a22922a107062a..4dc6b7adcaf5a34ffbe0b4aad5552a177CE6CBFD187F394900D46BF5 /* FormatConverter.cpp in Sources */,4667EA3E2968D9DA00BAB1E2 /* GameControllerHapticEffect.mm in Sources */,46FE73D32968E52000B8064C /* GameControllerHapticEngines.mm in Sources */,-@@ -46098,6 +46126,9 @@+@@ -46260,6 +46288,9 @@CE88EE262414467B007F29C2 /* TextAlternativeWithRange.mm in Sources */,BE39137129B267F500FA5D4F /* TextTransformCocoa.cpp in Sources */,51DF6D800B92A18E00C2DC85 /* ThreadCheck.mm in Sources */,@@ -2474,10 +2460,10 @@ index d58402bdd7423c3274088b4e35a22922a107062a..4dc6b7adcaf5a34ffbe0b4aad5552a17538EC8021F96AF81004D22A8 /* UnifiedSource1.cpp in Sources */,538EC8051F96AF81004D22A8 /* UnifiedSource2-mm.mm in Sources */,diff --git a/Source/WebCore/accessibility/AccessibilityObject.cpp b/Source/WebCore/accessibility/AccessibilityObject.cpp-index c6efab7897b328d46bfbca84f84fca8ad39bff48..bc5826d14817244396ddae91e57dde1312a4407e 100644+index a38a54553f430b96fa7744a442676d6136f5eda9..4ff2eaeab053a186e5e6bacab94a6b3b129eb7ab 100644--- a/Source/WebCore/accessibility/AccessibilityObject.cpp+++ b/Source/WebCore/accessibility/AccessibilityObject.cpp-@@ -70,6 +70,7 @@+@@ -71,6 +71,7 @@#include "HTMLTableSectionElement.h"#include "HTMLTextAreaElement.h"#include "HitTestResult.h"@@ -2485,7 +2471,7 @@ index c6efab7897b328d46bfbca84f84fca8ad39bff48..bc5826d14817244396ddae91e57dde13#include "LocalFrame.h"#include "LocalizedStrings.h"#include "MathMLNames.h"-@@ -3987,7 +3988,12 @@ AccessibilityObjectInclusion AccessibilityObject::defaultObjectInclusion() const+@@ -3910,7 +3911,12 @@ AccessibilityObjectInclusion AccessibilityObject::defaultObjectInclusion() constif (roleValue() == AccessibilityRole::ApplicationDialog)return AccessibilityObjectInclusion::IncludeObject;@@ -2500,10 +2486,10 @@ index c6efab7897b328d46bfbca84f84fca8ad39bff48..bc5826d14817244396ddae91e57dde13bool AccessibilityObject::isWithinHiddenWebArea() constdiff --git a/Source/WebCore/bindings/js/WebCoreBuiltinNames.h b/Source/WebCore/bindings/js/WebCoreBuiltinNames.h-index 0a0523ff37b7a51dc2152f074fb57b17883bd80f..715881ff75557f4e9165b521061e4b7a35286eba 100644+index a9d9ee8f0cb26fd47f9fea85e0856d2849362e6c..e2c58e571f41da4f65388fd36a9de56c92a404a8 100644--- a/Source/WebCore/bindings/js/WebCoreBuiltinNames.h+++ b/Source/WebCore/bindings/js/WebCoreBuiltinNames.h-@@ -187,6 +187,8 @@ namespace WebCore {+@@ -189,6 +189,8 @@ namespace WebCore {macro(DelayNode) \macro(DeprecationReportBody) \macro(DigitalCredential) \@@ -2513,10 +2499,10 @@ index 0a0523ff37b7a51dc2152f074fb57b17883bd80f..715881ff75557f4e9165b521061e4b7amacro(DynamicsCompressorNode) \macro(ElementInternals) \diff --git a/Source/WebCore/css/query/MediaQueryFeatures.cpp b/Source/WebCore/css/query/MediaQueryFeatures.cpp-index 83e2a42d3f09289d61217f63a121611a92aae85d..f4dfda8e9dc1dd9ad221272f09e1bd7f49afa1e0 100644+index aec43490053f95341ef979385b5e6c1daf03a090..4e44b7e341c8247f916f8597092248d8ec884518 100644--- a/Source/WebCore/css/query/MediaQueryFeatures.cpp+++ b/Source/WebCore/css/query/MediaQueryFeatures.cpp-@@ -496,7 +496,11 @@ static const IdentifierSchema& forcedColorsFeatureSchema()+@@ -498,7 +498,11 @@ static const IdentifierSchema& forcedColorsFeatureSchema()"forced-colors"_s,FixedVector { CSSValueNone, CSSValueActive },OptionSet<MediaQueryDynamicDependency>(),@@ -2529,7 +2515,7 @@ index 83e2a42d3f09289d61217f63a121611a92aae85d..f4dfda8e9dc1dd9ad221272f09e1bd7freturn MatchingIdentifiers { CSSValueNone };}};-@@ -682,6 +686,9 @@ static const IdentifierSchema& prefersReducedMotionFeatureSchema()+@@ -686,6 +690,9 @@ static const IdentifierSchema& prefersReducedMotionFeatureSchema()[](auto& context) {bool userPrefersReducedMotion = [&] {Ref frame = *context.document->frame();@@ -2768,7 +2754,7 @@ index 7813532cc52d582c42aebc979a1ecd1137765f08..c01cbd53ad2430a6ffab9a80fc73e74a#endif // USE(LIBWPE)diff --git a/Source/WebCore/html/FileInputType.cpp b/Source/WebCore/html/FileInputType.cpp-index 28d2a4af93da12474d1b699f6f0c46522514e3bb..0f20c78e509cce10e4179a1be91173b3de16db10 100644+index 75de5d5611953b830cf07d940ca1eedb789d2a9c..6adabe7a8250e02bc6b1e9fa28b0575d6a5e4dd7 100644--- a/Source/WebCore/html/FileInputType.cpp+++ b/Source/WebCore/html/FileInputType.cpp@@ -37,6 +37,7 @@@@ -2780,30 +2766,19 @@ index 28d2a4af93da12474d1b699f6f0c46522514e3bb..0f20c78e509cce10e4179a1be91173b3#include "LocalizedStrings.h"#include "MIMETypeRegistry.h"@@ -160,6 +161,11 @@ void FileInputType::handleDOMActivateEvent(Event& event)- if (input.isDisabledFormControl())+ if (protectedElement()->isDisabledFormControl())return;+ bool intercept = false;-+ InspectorInstrumentation::runOpenPanel(input.document().frame(), element(), &intercept);++ InspectorInstrumentation::runOpenPanel(element()->document().frame(), element(), &intercept);+ if (intercept)+ return;+if (!UserGestureIndicator::processingUserGesture())return;-@@ -345,7 +351,9 @@ void FileInputType::setFiles(RefPtr<FileList>&& files, RequestIcon shouldRequest- pathsChanged = true;- else {- for (unsigned i = 0; i < length; ++i) {-- if (files->file(i).path() != m_fileList->file(i).path() || !FileSystem::fileIDsAreEqual(files->file(i).fileID(), m_fileList->file(i).fileID())) {-+ if (files->file(i).path() != m_fileList->file(i).path() || !FileSystem::fileIDsAreEqual(files->file(i).fileID(), m_fileList->file(i).fileID()) ||-+ // Files created from Blob have empty path.-+ (files->file(i).path().isEmpty() && files->file(i).name() != m_fileList->file(i).name())) {- pathsChanged = true;- break;- }diff --git a/Source/WebCore/inspector/InspectorController.cpp b/Source/WebCore/inspector/InspectorController.cpp-index 79d7f4b39f4bc4ec2535bb355e567e39bc1f9ffa..6d1c4513780476767b4c51c8dcd3afd30088176d 100644+index dac15af852ff335ffba6b4bff717682a99b52b48..29bceeebb5a3e1c6c5d9d782dd62530d75b57d9a 100644--- a/Source/WebCore/inspector/InspectorController.cpp+++ b/Source/WebCore/inspector/InspectorController.cpp@@ -295,6 +295,8 @@ void InspectorController::disconnectFrontend(FrontendChannel& frontendChannel)@@ -2904,10 +2879,10 @@ index 4f5c1e836876710a554455ec53733f72db63de58..774c4a66af84664a7a83ba0790d147f7} // namespace WebCorediff --git a/Source/WebCore/inspector/InspectorInstrumentation.cpp b/Source/WebCore/inspector/InspectorInstrumentation.cpp-index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8ea2728999 100644+index 3d97cbaf887e52fe5c269cd4bc8cf750de41ddcb..46dc1872991560e41cff9c8b1ede2b73708c3736 100644--- a/Source/WebCore/inspector/InspectorInstrumentation.cpp+++ b/Source/WebCore/inspector/InspectorInstrumentation.cpp-@@ -583,6 +583,12 @@ void InspectorInstrumentation::applyUserAgentOverrideImpl(InstrumentingAgents& i+@@ -595,6 +595,12 @@ void InspectorInstrumentation::applyUserAgentOverrideImpl(InstrumentingAgents& ipageAgent->applyUserAgentOverride(userAgent);}@@ -2920,7 +2895,7 @@ index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8evoid InspectorInstrumentation::applyEmulatedMediaImpl(InstrumentingAgents& instrumentingAgents, AtomString& media){if (auto* pageAgent = instrumentingAgents.enabledPageAgent())-@@ -666,6 +672,12 @@ void InspectorInstrumentation::didFailLoadingImpl(InstrumentingAgents& instrumen+@@ -678,6 +684,12 @@ void InspectorInstrumentation::didFailLoadingImpl(InstrumentingAgents& instrumenconsoleAgent->didFailLoading(identifier, error); // This should come AFTER resource notification, front-end relies on this.}@@ -2933,7 +2908,7 @@ index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8evoid InspectorInstrumentation::willLoadXHRSynchronouslyImpl(InstrumentingAgents& instrumentingAgents){if (auto* networkAgent = instrumentingAgents.enabledNetworkAgent())-@@ -698,20 +710,17 @@ void InspectorInstrumentation::didReceiveScriptResponseImpl(InstrumentingAgents&+@@ -710,20 +722,17 @@ void InspectorInstrumentation::didReceiveScriptResponseImpl(InstrumentingAgents&void InspectorInstrumentation::domContentLoadedEventFiredImpl(InstrumentingAgents& instrumentingAgents, LocalFrame& frame){@@ -2957,7 +2932,7 @@ index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8e}void InspectorInstrumentation::frameDetachedFromParentImpl(InstrumentingAgents& instrumentingAgents, LocalFrame& frame)-@@ -791,12 +800,6 @@ void InspectorInstrumentation::frameDocumentUpdatedImpl(InstrumentingAgents& ins+@@ -803,12 +812,6 @@ void InspectorInstrumentation::frameDocumentUpdatedImpl(InstrumentingAgents& inspageDOMDebuggerAgent->frameDocumentUpdated(frame);}@@ -2970,7 +2945,7 @@ index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8evoid InspectorInstrumentation::frameStartedLoadingImpl(InstrumentingAgents& instrumentingAgents, LocalFrame& frame){if (frame.isMainFrame()) {-@@ -827,10 +830,10 @@ void InspectorInstrumentation::frameStoppedLoadingImpl(InstrumentingAgents& inst+@@ -839,10 +842,10 @@ void InspectorInstrumentation::frameStoppedLoadingImpl(InstrumentingAgents& instinspectorPageAgent->frameStoppedLoading(frame);}@@ -2983,7 +2958,7 @@ index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8e}void InspectorInstrumentation::frameClearedScheduledNavigationImpl(InstrumentingAgents& instrumentingAgents, Frame& frame)-@@ -845,6 +848,12 @@ void InspectorInstrumentation::accessibilitySettingsDidChangeImpl(InstrumentingA+@@ -857,6 +860,12 @@ void InspectorInstrumentation::accessibilitySettingsDidChangeImpl(InstrumentingAinspectorPageAgent->accessibilitySettingsDidChange();}@@ -2996,7 +2971,7 @@ index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8e#if ENABLE(DARK_MODE_CSS)void InspectorInstrumentation::defaultAppearanceDidChangeImpl(InstrumentingAgents& instrumentingAgents){-@@ -897,6 +906,12 @@ void InspectorInstrumentation::interceptResponseImpl(InstrumentingAgents& instru+@@ -909,6 +918,12 @@ void InspectorInstrumentation::interceptResponseImpl(InstrumentingAgents& instrunetworkAgent->interceptResponse(response, identifier, WTFMove(handler));}@@ -3009,7 +2984,7 @@ index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8e// JavaScriptCore InspectorDebuggerAgent should know Console MessageTypes.static bool isConsoleAssertMessage(MessageSource source, MessageType type){-@@ -1015,6 +1030,12 @@ void InspectorInstrumentation::consoleStopRecordingCanvasImpl(InstrumentingAgent+@@ -1027,6 +1042,12 @@ void InspectorInstrumentation::consoleStopRecordingCanvasImpl(InstrumentingAgentcanvasAgent->consoleStopRecordingCanvas(context);}@@ -3022,7 +2997,7 @@ index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8evoid InspectorInstrumentation::didDispatchDOMStorageEventImpl(InstrumentingAgents& instrumentingAgents, const String& key, const String& oldValue, const String& newValue, StorageType storageType, const SecurityOrigin& securityOrigin){if (auto* domStorageAgent = instrumentingAgents.enabledDOMStorageAgent())-@@ -1305,6 +1326,36 @@ void InspectorInstrumentation::renderLayerDestroyedImpl(InstrumentingAgents& ins+@@ -1317,6 +1338,36 @@ void InspectorInstrumentation::renderLayerDestroyedImpl(InstrumentingAgents& inslayerTreeAgent->renderLayerDestroyed(renderLayer);}@@ -3059,7 +3034,7 @@ index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8eInstrumentingAgents& InspectorInstrumentation::instrumentingAgents(WorkerOrWorkletGlobalScope& globalScope){return globalScope.inspectorController().m_instrumentingAgents;-@@ -1321,6 +1372,13 @@ InstrumentingAgents& InspectorInstrumentation::instrumentingAgents(Page& page)+@@ -1333,6 +1384,13 @@ InstrumentingAgents& InspectorInstrumentation::instrumentingAgents(Page& page)return page.inspectorController().m_instrumentingAgents.get();}@@ -3074,7 +3049,7 @@ index 7e789f4b0704d574b3bf180b2417822d9ee33994..80e6b4bc7810af19265d24e0de861c8e{// Using RefPtr makes us hit the m_inRemovedLastRefFunction assert.diff --git a/Source/WebCore/inspector/InspectorInstrumentation.h b/Source/WebCore/inspector/InspectorInstrumentation.h-index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f3005f541c3 100644+index 0fb5a57841daca73bbc452b6bbe97d8bbb25500e..7aac51c58d0fc3640fcaf7f9cdf0776367020f9e 100644--- a/Source/WebCore/inspector/InspectorInstrumentation.h+++ b/Source/WebCore/inspector/InspectorInstrumentation.h@@ -31,6 +31,7 @@@@ -3101,7 +3076,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30class HTTPHeaderMap;class InspectorTimelineAgent;class InstrumentingAgents;-@@ -194,6 +197,7 @@ public:+@@ -196,6 +199,7 @@ public:static void didRecalculateStyle(Document&);static void didScheduleStyleRecalculation(Document&);static void applyUserAgentOverride(LocalFrame&, String&);@@ -3109,7 +3084,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30static void applyEmulatedMedia(LocalFrame&, AtomString&);static void flexibleBoxRendererBeganLayout(const RenderObject&);-@@ -206,6 +210,7 @@ public:+@@ -208,6 +212,7 @@ public:static void didReceiveData(LocalFrame*, ResourceLoaderIdentifier, const SharedBuffer*, int encodedDataLength);static void didFinishLoading(LocalFrame*, DocumentLoader*, ResourceLoaderIdentifier, const NetworkLoadMetrics&, ResourceLoader*);static void didFailLoading(LocalFrame*, DocumentLoader*, ResourceLoaderIdentifier, const ResourceError&);@@ -3117,7 +3092,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30static void willSendRequest(ServiceWorkerGlobalScope&, ResourceLoaderIdentifier, ResourceRequest&);static void didReceiveResourceResponse(ServiceWorkerGlobalScope&, ResourceLoaderIdentifier, const ResourceResponse&);-@@ -232,13 +237,13 @@ public:+@@ -234,13 +239,13 @@ public:static void frameDetachedFromParent(LocalFrame&);static void didCommitLoad(LocalFrame&, DocumentLoader*);static void frameDocumentUpdated(LocalFrame&);@@ -3133,7 +3108,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30#if ENABLE(DARK_MODE_CSS)static void defaultAppearanceDidChange(Page&);#endif-@@ -249,6 +254,7 @@ public:+@@ -251,6 +256,7 @@ public:static bool shouldInterceptResponse(const LocalFrame&, const ResourceResponse&);static void interceptRequest(ResourceLoader&, Function<void(const ResourceRequest&)>&&);static void interceptResponse(const LocalFrame&, const ResourceResponse&, ResourceLoaderIdentifier, CompletionHandler<void(const ResourceResponse&, RefPtr<FragmentedSharedBuffer>)>&&);@@ -3141,7 +3116,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30static void addMessageToConsole(Page&, std::unique_ptr<Inspector::ConsoleMessage>);static void addMessageToConsole(WorkerOrWorkletGlobalScope&, std::unique_ptr<Inspector::ConsoleMessage>);-@@ -270,6 +276,7 @@ public:+@@ -272,6 +278,7 @@ public:static void stopProfiling(Page&, const String& title);static void consoleStartRecordingCanvas(CanvasRenderingContext&, JSC::JSGlobalObject&, JSC::JSObject* options);static void consoleStopRecordingCanvas(CanvasRenderingContext&);@@ -3149,7 +3124,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30static void performanceMark(ScriptExecutionContext&, const String&, std::optional<MonotonicTime>);-@@ -323,6 +330,12 @@ public:+@@ -325,6 +332,12 @@ public:static void layerTreeDidChange(Page*);static void renderLayerDestroyed(Page*, const RenderLayer&);@@ -3162,7 +3137,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30static void frontendCreated();static void frontendDeleted();static bool hasFrontends() { return InspectorInstrumentationPublic::hasFrontends(); }-@@ -339,6 +352,8 @@ public:+@@ -341,6 +354,8 @@ public:static void registerInstrumentingAgents(InstrumentingAgents&);static void unregisterInstrumentingAgents(InstrumentingAgents&);@@ -3171,7 +3146,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30private:static void didClearWindowObjectInWorldImpl(InstrumentingAgents&, LocalFrame&, DOMWrapperWorld&);static bool isDebuggerPausedImpl(InstrumentingAgents&);-@@ -418,6 +433,7 @@ private:+@@ -422,6 +437,7 @@ private:static void didRecalculateStyleImpl(InstrumentingAgents&);static void didScheduleStyleRecalculationImpl(InstrumentingAgents&, Document&);static void applyUserAgentOverrideImpl(InstrumentingAgents&, String&);@@ -3179,7 +3154,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30static void applyEmulatedMediaImpl(InstrumentingAgents&, AtomString&);static void flexibleBoxRendererBeganLayoutImpl(InstrumentingAgents&, const RenderObject&);-@@ -432,6 +448,7 @@ private:+@@ -436,6 +452,7 @@ private:static void didReceiveDataImpl(InstrumentingAgents&, ResourceLoaderIdentifier, const SharedBuffer*, int encodedDataLength);static void didFinishLoadingImpl(InstrumentingAgents&, ResourceLoaderIdentifier, DocumentLoader*, const NetworkLoadMetrics&, ResourceLoader*);static void didFailLoadingImpl(InstrumentingAgents&, ResourceLoaderIdentifier, DocumentLoader*, const ResourceError&);@@ -3187,7 +3162,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30static void willLoadXHRSynchronouslyImpl(InstrumentingAgents&);static void didLoadXHRSynchronouslyImpl(InstrumentingAgents&);static void scriptImportedImpl(InstrumentingAgents&, ResourceLoaderIdentifier, const String& sourceString);-@@ -442,13 +459,13 @@ private:+@@ -446,13 +463,13 @@ private:static void frameDetachedFromParentImpl(InstrumentingAgents&, LocalFrame&);static void didCommitLoadImpl(InstrumentingAgents&, LocalFrame&, DocumentLoader*);static void frameDocumentUpdatedImpl(InstrumentingAgents&, LocalFrame&);@@ -3203,7 +3178,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30#if ENABLE(DARK_MODE_CSS)static void defaultAppearanceDidChangeImpl(InstrumentingAgents&);#endif-@@ -459,6 +476,7 @@ private:+@@ -463,6 +480,7 @@ private:static bool shouldInterceptResponseImpl(InstrumentingAgents&, const ResourceResponse&);static void interceptRequestImpl(InstrumentingAgents&, ResourceLoader&, Function<void(const ResourceRequest&)>&&);static void interceptResponseImpl(InstrumentingAgents&, const ResourceResponse&, ResourceLoaderIdentifier, CompletionHandler<void(const ResourceResponse&, RefPtr<FragmentedSharedBuffer>)>&&);@@ -3211,7 +3186,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30static void addMessageToConsoleImpl(InstrumentingAgents&, std::unique_ptr<Inspector::ConsoleMessage>);-@@ -473,6 +491,7 @@ private:+@@ -477,6 +495,7 @@ private:static void stopProfilingImpl(InstrumentingAgents&, const String& title);static void consoleStartRecordingCanvasImpl(InstrumentingAgents&, CanvasRenderingContext&, JSC::JSGlobalObject&, JSC::JSObject* options);static void consoleStopRecordingCanvasImpl(InstrumentingAgents&, CanvasRenderingContext&);@@ -3219,7 +3194,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30static void performanceMarkImpl(InstrumentingAgents&, const String& label, std::optional<MonotonicTime>);-@@ -526,6 +545,12 @@ private:+@@ -530,6 +549,12 @@ private:static void layerTreeDidChangeImpl(InstrumentingAgents&);static void renderLayerDestroyedImpl(InstrumentingAgents&, const RenderLayer&);@@ -3232,7 +3207,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30static InstrumentingAgents& instrumentingAgents(Page&);static InstrumentingAgents& instrumentingAgents(WorkerOrWorkletGlobalScope&);static InstrumentingAgents& instrumentingAgents(ServiceWorkerGlobalScope&);-@@ -1071,6 +1096,13 @@ inline void InspectorInstrumentation::applyUserAgentOverride(LocalFrame& frame,+@@ -1089,6 +1114,13 @@ inline void InspectorInstrumentation::applyUserAgentOverride(LocalFrame& frame,applyUserAgentOverrideImpl(*agents, userAgent);}@@ -3246,7 +3221,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30inline void InspectorInstrumentation::applyEmulatedMedia(LocalFrame& frame, AtomString& media){FAST_RETURN_IF_NO_FRONTENDS(void());-@@ -1173,6 +1205,13 @@ inline void InspectorInstrumentation::didFailLoading(ServiceWorkerGlobalScope& g+@@ -1191,6 +1223,13 @@ inline void InspectorInstrumentation::didFailLoading(ServiceWorkerGlobalScope& gdidFailLoadingImpl(instrumentingAgents(globalScope), identifier, nullptr, error);}@@ -3260,7 +3235,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30inline void InspectorInstrumentation::continueAfterXFrameOptionsDenied(LocalFrame& frame, ResourceLoaderIdentifier identifier, DocumentLoader& loader, const ResourceResponse& response){// Treat the same as didReceiveResponse.-@@ -1263,13 +1302,6 @@ inline void InspectorInstrumentation::frameDocumentUpdated(LocalFrame& frame)+@@ -1281,13 +1320,6 @@ inline void InspectorInstrumentation::frameDocumentUpdated(LocalFrame& frame)frameDocumentUpdatedImpl(*agents, frame);}@@ -3274,7 +3249,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30inline void InspectorInstrumentation::frameStartedLoading(LocalFrame& frame){FAST_RETURN_IF_NO_FRONTENDS(void());-@@ -1291,11 +1323,11 @@ inline void InspectorInstrumentation::frameStoppedLoading(LocalFrame& frame)+@@ -1309,11 +1341,11 @@ inline void InspectorInstrumentation::frameStoppedLoading(LocalFrame& frame)frameStoppedLoadingImpl(*agents, frame);}@@ -3288,7 +3263,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30}inline void InspectorInstrumentation::frameClearedScheduledNavigation(Frame& frame)-@@ -1311,6 +1343,13 @@ inline void InspectorInstrumentation::accessibilitySettingsDidChange(Page& page)+@@ -1329,6 +1361,13 @@ inline void InspectorInstrumentation::accessibilitySettingsDidChange(Page& page)accessibilitySettingsDidChangeImpl(instrumentingAgents(page));}@@ -3302,7 +3277,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30#if ENABLE(DARK_MODE_CSS)inline void InspectorInstrumentation::defaultAppearanceDidChange(Page& page){-@@ -1363,6 +1402,13 @@ inline void InspectorInstrumentation::interceptResponse(const LocalFrame& frame,+@@ -1381,6 +1420,13 @@ inline void InspectorInstrumentation::interceptResponse(const LocalFrame& frame,interceptResponseImpl(*agents, response, identifier, WTFMove(handler));}@@ -3316,7 +3291,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30inline void InspectorInstrumentation::didDispatchDOMStorageEvent(Page& page, const String& key, const String& oldValue, const String& newValue, StorageType storageType, const SecurityOrigin& securityOrigin){FAST_RETURN_IF_NO_FRONTENDS(void());-@@ -1679,6 +1725,11 @@ inline void InspectorInstrumentation::performanceMark(ScriptExecutionContext& co+@@ -1697,6 +1743,11 @@ inline void InspectorInstrumentation::performanceMark(ScriptExecutionContext& coperformanceMarkImpl(*agents, label, WTFMove(startTime));}@@ -3328,7 +3303,7 @@ index c338ad466f69c4b03121e0b17fbc9a4729654aff..6139fb2b5e0364bce1a5720200943f30inline void InspectorInstrumentation::didRequestAnimationFrame(ScriptExecutionContext& scriptExecutionContext, int callbackId){FAST_RETURN_IF_NO_FRONTENDS(void());-@@ -1735,6 +1786,42 @@ inline void InspectorInstrumentation::renderLayerDestroyed(Page* page, const Ren+@@ -1753,6 +1804,42 @@ inline void InspectorInstrumentation::renderLayerDestroyed(Page* page, const RenrenderLayerDestroyedImpl(*agents, renderLayer);}@@ -3424,7 +3399,7 @@ index c028341e84e59a6b1b16107fd74feb21f70b12ab..d385418ac34e8f315f201801a2c65226+}diff --git a/Source/WebCore/inspector/agents/InspectorDOMAgent.cpp b/Source/WebCore/inspector/agents/InspectorDOMAgent.cpp-index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0ca049ae40 100644+index 5bd7a42c19fd11234eea0520ebf61f7f820f765e..a70339c639682820de7ff09d62e8cfd42a7d7060 100644--- a/Source/WebCore/inspector/agents/InspectorDOMAgent.cpp+++ b/Source/WebCore/inspector/agents/InspectorDOMAgent.cpp@@ -56,6 +56,7 @@@@ -3450,7 +3425,7 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0c#include "HTMLMediaElement.h"#include "HTMLNames.h"#include "HTMLScriptElement.h"-@@ -103,12 +109,14 @@+@@ -104,12 +110,14 @@#include "Pasteboard.h"#include "PseudoElement.h"#include "RenderGrid.h"@@ -3465,7 +3440,7 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0c#include "StaticNodeList.h"#include "StyleProperties.h"#include "StyleResolver.h"-@@ -150,7 +158,8 @@ using namespace HTMLNames;+@@ -151,7 +159,8 @@ using namespace HTMLNames;static const size_t maxTextSize = 10000;static const UChar horizontalEllipsisUChar[] = { horizontalEllipsis, 0 };@@ -3475,7 +3450,7 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0c{if (!colorObject)return std::nullopt;-@@ -169,7 +178,7 @@ static std::optional<Color> parseColor(RefPtr<JSON::Object>&& colorObject)+@@ -170,7 +179,7 @@ static std::optional<Color> parseColor(RefPtr<JSON::Object>&& colorObject)static std::optional<Color> parseRequiredConfigColor(const String& fieldName, JSON::Object& configObject){@@ -3484,7 +3459,7 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0c}static Color parseOptionalConfigColor(const String& fieldName, JSON::Object& configObject)-@@ -196,6 +205,20 @@ static bool parseQuad(Ref<JSON::Array>&& quadArray, FloatQuad* quad)+@@ -197,6 +206,20 @@ static bool parseQuad(Ref<JSON::Array>&& quadArray, FloatQuad* quad)return true;}@@ -3505,7 +3480,7 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0cclass RevalidateStyleAttributeTask final : public CanMakeCheckedPtr<RevalidateStyleAttributeTask> {WTF_MAKE_TZONE_ALLOCATED(RevalidateStyleAttributeTask);WTF_OVERRIDE_DELETE_FOR_CHECKED_PTR(RevalidateStyleAttributeTask);-@@ -476,6 +499,20 @@ Node* InspectorDOMAgent::assertNode(Inspector::Protocol::ErrorString& errorStrin+@@ -477,6 +500,20 @@ Node* InspectorDOMAgent::assertNode(Inspector::Protocol::ErrorString& errorStrinreturn node.get();}@@ -3526,7 +3501,7 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0cDocument* InspectorDOMAgent::assertDocument(Inspector::Protocol::ErrorString& errorString, Inspector::Protocol::DOM::NodeId nodeId){RefPtr node = assertNode(errorString, nodeId);-@@ -1550,16 +1587,7 @@ Inspector::Protocol::ErrorStringOr<void> InspectorDOMAgent::highlightNode(std::o+@@ -1595,16 +1632,7 @@ Inspector::Protocol::ErrorStringOr<void> InspectorDOMAgent::highlightNode(std::oInspector::Protocol::ErrorStringOr<void> InspectorDOMAgent::highlightNode(std::optional<Inspector::Protocol::DOM::NodeId>&& nodeId, const Inspector::Protocol::Runtime::RemoteObjectId& objectId, Ref<JSON::Object>&& highlightInspectorObject, RefPtr<JSON::Object>&& gridOverlayInspectorObject, RefPtr<JSON::Object>&& flexOverlayInspectorObject, std::optional<bool>&& showRulers){Inspector::Protocol::ErrorString errorString;@@ -3544,7 +3519,7 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0cif (!node)return makeUnexpected(errorString);-@@ -1814,15 +1842,159 @@ Inspector::Protocol::ErrorStringOr<void> InspectorDOMAgent::setInspectedNode(Ins+@@ -1859,15 +1887,159 @@ Inspector::Protocol::ErrorStringOr<void> InspectorDOMAgent::setInspectedNode(Insreturn { };}@@ -3707,7 +3682,7 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0cif (!object)return makeUnexpected("Missing injected script for given nodeId"_s);-@@ -3088,7 +3260,7 @@ Inspector::Protocol::ErrorStringOr<Inspector::Protocol::DOM::NodeId> InspectorDO+@@ -3133,7 +3305,7 @@ Inspector::Protocol::ErrorStringOr<Inspector::Protocol::DOM::NodeId> InspectorDOreturn makeUnexpected("Missing node for given path"_s);}@@ -3716,7 +3691,7 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0c{Document* document = &node->document();if (auto* templateHost = document->templateDocumentHost())-@@ -3097,12 +3269,18 @@ RefPtr<Inspector::Protocol::Runtime::RemoteObject> InspectorDOMAgent::resolveNod+@@ -3142,12 +3314,18 @@ RefPtr<Inspector::Protocol::Runtime::RemoteObject> InspectorDOMAgent::resolveNodif (!frame)return nullptr;@@ -3738,11 +3713,11 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0c}Node* InspectorDOMAgent::scriptValueAsNode(JSC::JSValue value)-@@ -3210,4 +3388,89 @@ Inspector::Protocol::ErrorStringOr<Ref<Inspector::Protocol::DOM::MediaStats>> In+@@ -3255,4 +3433,53 @@ Inspector::Protocol::ErrorStringOr<Ref<Inspector::Protocol::DOM::MediaStats>> In#endif}-+void InspectorDOMAgent::setInputFiles(const String& objectId, RefPtr<JSON::Array>&& files, RefPtr<JSON::Array>&& paths, Ref<SetInputFilesCallback>&& callback) {++void InspectorDOMAgent::setInputFiles(const String& objectId, Ref<JSON::Array>&& paths, Ref<SetInputFilesCallback>&& callback) {+ InjectedScript injectedScript = m_injectedScriptManager.injectedScriptForObjectId(objectId);+ if (injectedScript.hasNoValue()) {+ callback->sendFailure("Can not find element's context for given id"_s);@@ -3760,76 +3735,40 @@ index a477bad0c14c9304b9c2f03aa4e690e8b27a7756..fcb712a41223ec4698337a8b17999e0c+ return;+ }+-+ if (!(bool(files) ^ bool(paths))) {-+ callback->sendFailure("Exactly one of files and paths should be specified"_s);-+ return;-+ }-++ HTMLInputElement* element = static_cast<HTMLInputElement*>(node);+ Vector<Ref<File>> fileObjects;-+ if (files) {-+ for (unsigned i = 0; i < files->length(); ++i) {-+ RefPtr<JSON::Value> item = files->get(i);-+ RefPtr<JSON::Object> obj = item->asObject();-+ if (!obj) {-+ callback->sendFailure("Invalid file payload format"_s);-+ return;-+ }-+-+ String name;-+ String type;-+ String data;-+ if (!obj->getString("name"_s, name) || !obj->getString("type"_s, type) || !obj->getString("data"_s, data)) {-+ callback->sendFailure("Invalid file payload format"_s);-+ return;-+ }-+-+ std::optional<Vector<uint8_t>> buffer = base64Decode(data);-+ if (!buffer) {-+ callback->sendFailure("Unable to decode given content"_s);++ if (element->hasAttributeWithoutSynchronization(webkitdirectoryAttr)) {++ auto directoryFileListCreator = DirectoryFileListCreator::create([element = RefPtr { element }, callback = WTFMove(callback)](Ref<FileList>&& fileList) mutable {++ ASSERT(isMainThread());++ element->setFiles(WTFMove(fileList));++ callback->sendSuccess();++ });++ Vector<FileChooserFileInfo> fileChooserFiles;++ for (size_t i = 0; i < paths->length(); ++i) {++ fileChooserFiles.append(FileChooserFileInfo { paths->get(i)->asString(), nullString(), { } });++ }++ directoryFileListCreator->start(m_document.get(), fileChooserFiles);++ } else {++ for (unsigned i = 0; i < paths->length(); ++i) {++ RefPtr<JSON::Value> item = paths->get(i);++ String path = item->asString();++ if (path.isEmpty()) {++ callback->sendFailure("Invalid file path"_s);+ return;+ }++ ScriptExecutionContext* context = element->scriptExecutionContext();-+ fileObjects.append(File::create(context, Blob::create(context, WTFMove(*buffer), type), name));++ fileObjects.append(File::create(context, path));+ }+ RefPtr<FileList> fileList = FileList::create(WTFMove(fileObjects));+ element->setFiles(WTFMove(fileList));+ callback->sendSuccess();-+ } else {-+ if (element->hasAttributeWithoutSynchronization(webkitdirectoryAttr)) {-+ auto directoryFileListCreator = DirectoryFileListCreator::create([element = RefPtr { element }, callback = WTFMove(callback)](Ref<FileList>&& fileList) mutable {-+ ASSERT(isMainThread());-+ element->setFiles(WTFMove(fileList));-+ callback->sendSuccess();-+ });-+ Vector<FileChooserFileInfo> fileChooserFiles;-+ for (size_t i = 0; i < paths->length(); ++i) {-+ fileChooserFiles.append(FileChooserFileInfo { paths->get(i)->asString(), nullString(), { } });-+ }-+ directoryFileListCreator->start(m_document.get(), fileChooserFiles);-+ } else {-+ for (unsigned i = 0; i < paths->length(); ++i) {-+ RefPtr<JSON::Value> item = paths->get(i);-+ String path = item->asString();-+ if (path.isEmpty()) {-+ callback->sendFailure("Invalid file path"_s);-+ return;-+ }-+-+ ScriptExecutionContext* context = element->scriptExecutionContext();-+ fileObjects.append(File::create(context, path));-+ }-+ RefPtr<FileList> fileList = FileList::create(WTFMove(fileObjects));-+ element->setFiles(WTFMove(fileList));-+ callback->sendSuccess();-+ }+ }+}+} // namespace WebCorediff --git a/Source/WebCore/inspector/agents/InspectorDOMAgent.h b/Source/WebCore/inspector/agents/InspectorDOMAgent.h-index 0d1406e0a1d061e2336bbd49c56328ce93351f14..4187fb453adebfd98f91ebbf99e38a072ef8942b 100644+index c8602dd6236d299df04b28b456b4d4ab6348c6eb..15128978fa8d64b6413b82ce9991dd708d50271b 100644--- a/Source/WebCore/inspector/agents/InspectorDOMAgent.h+++ b/Source/WebCore/inspector/agents/InspectorDOMAgent.h@@ -59,6 +59,7 @@ namespace WebCore {@@ -3848,7 +3787,7 @@ index 0d1406e0a1d061e2336bbd49c56328ce93351f14..4187fb453adebfd98f91ebbf99e38a07// We represent embedded doms as a part of the same hierarchy. Hence we treat children of frame owners differently.// We also skip whitespace text nodes conditionally. Following methods encapsulate these specifics.-@@ -137,7 +139,7 @@ public:+@@ -139,7 +141,7 @@ public:Inspector::Protocol::ErrorStringOr<std::tuple<String /* searchId */, int /* resultCount */>> performSearch(const String& query, RefPtr<JSON::Array>&& nodeIds, std::optional<bool>&& caseSensitive);Inspector::Protocol::ErrorStringOr<Ref<JSON::ArrayOf<Inspector::Protocol::DOM::NodeId>>> getSearchResults(const String& searchId, int fromIndex, int toIndex);Inspector::Protocol::ErrorStringOr<void> discardSearchResults(const String& searchId);@@ -3857,18 +3796,18 @@ index 0d1406e0a1d061e2336bbd49c56328ce93351f14..4187fb453adebfd98f91ebbf99e38a07Inspector::Protocol::ErrorStringOr<Ref<JSON::ArrayOf<String>>> getAttributes(Inspector::Protocol::DOM::NodeId);#if PLATFORM(IOS_FAMILY)Inspector::Protocol::ErrorStringOr<void> setInspectModeEnabled(bool, RefPtr<JSON::Object>&& highlightConfig, RefPtr<JSON::Object>&& gridOverlayConfig, RefPtr<JSON::Object>&& flexOverlayConfig);-@@ -174,6 +176,10 @@ public:+@@ -176,6 +178,10 @@ public:Inspector::Protocol::ErrorStringOr<void> setInspectedNode(Inspector::Protocol::DOM::NodeId);Inspector::Protocol::ErrorStringOr<void> setAllowEditingUserAgentShadowTrees(bool);Inspector::Protocol::ErrorStringOr<Ref<Inspector::Protocol::DOM::MediaStats>> getMediaStats(Inspector::Protocol::DOM::NodeId);+ Inspector::Protocol::ErrorStringOr<std::tuple<String /* contentFrameId */, String /* ownerFrameId */>> describeNode(const String& objectId);+ Inspector::Protocol::ErrorStringOr<void> scrollIntoViewIfNeeded(const String& objectId, RefPtr<JSON::Object>&& rect);+ Inspector::Protocol::ErrorStringOr<Ref<JSON::ArrayOf<Inspector::Protocol::DOM::Quad>>> getContentQuads(const String& objectId);-+ void setInputFiles(const String& objectId, RefPtr<JSON::Array>&& files, RefPtr<JSON::Array>&& paths, Ref<SetInputFilesCallback>&& callback);++ void setInputFiles(const String& objectId, Ref<JSON::Array>&& paths, Ref<SetInputFilesCallback>&& callback);// InspectorInstrumentationInspector::Protocol::DOM::NodeId identifierForNode(Node&);-@@ -215,7 +221,7 @@ public:+@@ -217,7 +223,7 @@ public:Node* nodeForId(Inspector::Protocol::DOM::NodeId);Inspector::Protocol::DOM::NodeId boundNodeId(const Node*);@@ -3877,7 +3816,7 @@ index 0d1406e0a1d061e2336bbd49c56328ce93351f14..4187fb453adebfd98f91ebbf99e38a07bool handleMousePress();void mouseDidMoveOverElement(const HitTestResult&, OptionSet<PlatformEventModifier>);void inspect(Node*);-@@ -227,12 +233,15 @@ public:+@@ -229,12 +235,15 @@ public:void reset();Node* assertNode(Inspector::Protocol::ErrorString&, Inspector::Protocol::DOM::NodeId);@@ -3893,7 +3832,7 @@ index 0d1406e0a1d061e2336bbd49c56328ce93351f14..4187fb453adebfd98f91ebbf99e38a07private:#if ENABLE(VIDEO)void mediaMetricsTimerFired();-@@ -262,7 +271,6 @@ private:+@@ -264,7 +273,6 @@ private:void processAccessibilityChildren(AXCoreObject&, JSON::ArrayOf<Inspector::Protocol::DOM::NodeId>&);Node* nodeForPath(const String& path);@@ -3902,18 +3841,18 @@ index 0d1406e0a1d061e2336bbd49c56328ce93351f14..4187fb453adebfd98f91ebbf99e38a07void discardBindings();diff --git a/Source/WebCore/inspector/agents/InspectorNetworkAgent.cpp b/Source/WebCore/inspector/agents/InspectorNetworkAgent.cpp-index 6db0a3c6a46a4be5cb6f9f0e6fcbc61ac552e438..cae87102e8228cb944cec4a6ebe83b7d3a0e29bc 100644+index 263890779b1a012b1ae1fe9145f4a7af494a581c..dc83cf514b03a80ceff036248147203898a4e113 100644--- a/Source/WebCore/inspector/agents/InspectorNetworkAgent.cpp+++ b/Source/WebCore/inspector/agents/InspectorNetworkAgent.cpp-@@ -59,6 +59,7 @@+@@ -58,6 +58,7 @@+ #include "LocalFrame.h"#include "MIMETypeRegistry.h"#include "MemoryCache.h"- #include "NetworkResourcesData.h"+#include "NetworkStateNotifier.h"#include "Page.h"#include "PlatformStrategies.h"#include "ProgressTracker.h"-@@ -345,8 +346,8 @@ static Ref<Inspector::Protocol::Network::Request> buildObjectForResourceRequest(+@@ -343,8 +344,8 @@ static Ref<Inspector::Protocol::Network::Request> buildObjectForResourceRequest(.release();if (request.httpBody() && !request.httpBody()->isEmpty()) {@@ -3924,7 +3863,7 @@ index 6db0a3c6a46a4be5cb6f9f0e6fcbc61ac552e438..cae87102e8228cb944cec4a6ebe83b7d}if (resourceLoader) {-@@ -399,6 +400,8 @@ RefPtr<Inspector::Protocol::Network::Response> InspectorNetworkAgent::buildObjec+@@ -397,6 +398,8 @@ RefPtr<Inspector::Protocol::Network::Response> InspectorNetworkAgent::buildObjec.setSource(responseSource(response.source())).release();@@ -3933,7 +3872,7 @@ index 6db0a3c6a46a4be5cb6f9f0e6fcbc61ac552e438..cae87102e8228cb944cec4a6ebe83b7dif (resourceLoader) {auto* metrics = response.deprecatedNetworkLoadMetricsOrNull();responseObject->setTiming(buildObjectForTiming(metrics ? *metrics : NetworkLoadMetrics::emptyMetrics(), *resourceLoader));-@@ -685,6 +688,9 @@ void InspectorNetworkAgent::didFailLoading(ResourceLoaderIdentifier identifier,+@@ -683,6 +686,9 @@ void InspectorNetworkAgent::didFailLoading(ResourceLoaderIdentifier identifier,String requestId = IdentifiersFactory::requestId(identifier.toUInt64());if (loader && m_resourcesData->resourceType(requestId) == InspectorPageAgent::DocumentResource) {@@ -3943,7 +3882,7 @@ index 6db0a3c6a46a4be5cb6f9f0e6fcbc61ac552e438..cae87102e8228cb944cec4a6ebe83b7dauto* frame = loader->frame();if (frame && frame->loader().documentLoader() && frame->document()) {m_resourcesData->addResourceSharedBuffer(requestId,-@@ -914,6 +920,7 @@ Inspector::Protocol::ErrorStringOr<void> InspectorNetworkAgent::disable()+@@ -912,6 +918,7 @@ Inspector::Protocol::ErrorStringOr<void> InspectorNetworkAgent::disable()m_instrumentingAgents.setEnabledNetworkAgent(nullptr);m_resourcesData->clear();m_extraRequestHeaders.clear();@@ -3951,7 +3890,7 @@ index 6db0a3c6a46a4be5cb6f9f0e6fcbc61ac552e438..cae87102e8228cb944cec4a6ebe83b7dcontinuePendingRequests();continuePendingResponses();-@@ -966,6 +973,7 @@ void InspectorNetworkAgent::continuePendingResponses()+@@ -957,6 +964,7 @@ void InspectorNetworkAgent::continuePendingResponses()Inspector::Protocol::ErrorStringOr<void> InspectorNetworkAgent::setExtraHTTPHeaders(Ref<JSON::Object>&& headers){@@ -3959,7 +3898,7 @@ index 6db0a3c6a46a4be5cb6f9f0e6fcbc61ac552e438..cae87102e8228cb944cec4a6ebe83b7dfor (auto& entry : headers.get()) {auto stringValue = entry.value->asString();if (!!stringValue)-@@ -1215,6 +1223,11 @@ void InspectorNetworkAgent::interceptResponse(const ResourceResponse& response,+@@ -1206,6 +1214,11 @@ void InspectorNetworkAgent::interceptResponse(const ResourceResponse& response,m_frontendDispatcher->responseIntercepted(requestId, resourceResponse.releaseNonNull());}@@ -3971,7 +3910,7 @@ index 6db0a3c6a46a4be5cb6f9f0e6fcbc61ac552e438..cae87102e8228cb944cec4a6ebe83b7dInspector::Protocol::ErrorStringOr<void> InspectorNetworkAgent::interceptContinue(const Inspector::Protocol::Network::RequestId& requestId, Inspector::Protocol::Network::NetworkStage networkStage){switch (networkStage) {-@@ -1244,6 +1257,9 @@ Inspector::Protocol::ErrorStringOr<void> InspectorNetworkAgent::interceptWithReq+@@ -1235,6 +1248,9 @@ Inspector::Protocol::ErrorStringOr<void> InspectorNetworkAgent::interceptWithReqreturn makeUnexpected("Missing pending intercept request for given requestId"_s);auto& loader = *pendingRequest->m_loader;@@ -3981,7 +3920,7 @@ index 6db0a3c6a46a4be5cb6f9f0e6fcbc61ac552e438..cae87102e8228cb944cec4a6ebe83b7dResourceRequest request = loader.request();if (!!url)request.setURL(URL({ }, url));-@@ -1339,14 +1355,23 @@ Inspector::Protocol::ErrorStringOr<void> InspectorNetworkAgent::interceptRequest+@@ -1330,14 +1346,23 @@ Inspector::Protocol::ErrorStringOr<void> InspectorNetworkAgent::interceptRequestresponse.setHTTPStatusCode(status);response.setHTTPStatusText(String { statusText });HTTPHeaderMap explicitHeaders;@@ -4007,7 +3946,7 @@ index 6db0a3c6a46a4be5cb6f9f0e6fcbc61ac552e438..cae87102e8228cb944cec4a6ebe83b7dif (loader->reachedTerminalState())return;-@@ -1409,6 +1434,12 @@ Inspector::Protocol::ErrorStringOr<void> InspectorNetworkAgent::setEmulatedCondi+@@ -1400,6 +1425,12 @@ Inspector::Protocol::ErrorStringOr<void> InspectorNetworkAgent::setEmulatedCondi#endif // ENABLE(INSPECTOR_NETWORK_THROTTLING)@@ -4021,19 +3960,19 @@ index 6db0a3c6a46a4be5cb6f9f0e6fcbc61ac552e438..cae87102e8228cb944cec4a6ebe83b7d{return startsWithLettersIgnoringASCIICase(mimeType, "text/"_s)diff --git a/Source/WebCore/inspector/agents/InspectorNetworkAgent.h b/Source/WebCore/inspector/agents/InspectorNetworkAgent.h-index eda400879afb10b687fcbb317c9fdbb3be9c94cd..f3a382c44b53e6b1507fc046e22bff684abd55f9 100644+index de6b2dd844943074c5a383c7b9b8ccba1c96419a..7a3404f2380b5e62f1c0523a70f8ef442014759d 100644--- a/Source/WebCore/inspector/agents/InspectorNetworkAgent.h+++ b/Source/WebCore/inspector/agents/InspectorNetworkAgent.h-@@ -34,6 +34,8 @@- #include "InspectorInstrumentation.h"+@@ -35,6 +35,8 @@#include "InspectorPageAgent.h"#include "InspectorWebAgentBase.h"+ #include "NetworkResourcesData.h"+#include "ResourceError.h"+#include "SharedBuffer.h"#include "WebSocket.h"+ #include <JavaScriptCore/ContentSearchUtilities.h>#include <JavaScriptCore/InspectorBackendDispatchers.h>- #include <JavaScriptCore/InspectorFrontendDispatchers.h>-@@ -102,6 +104,7 @@ public:+@@ -104,6 +106,7 @@ public:#if ENABLE(INSPECTOR_NETWORK_THROTTLING)Inspector::Protocol::ErrorStringOr<void> setEmulatedConditions(std::optional<int>&& bytesPerSecondLimit) final;#endif@@ -4041,7 +3980,7 @@ index eda400879afb10b687fcbb317c9fdbb3be9c94cd..f3a382c44b53e6b1507fc046e22bff68// InspectorInstrumentationvoid willRecalculateStyle();-@@ -133,6 +136,7 @@ public:+@@ -135,6 +138,7 @@ public:bool shouldInterceptResponse(const ResourceResponse&);void interceptResponse(const ResourceResponse&, ResourceLoaderIdentifier, CompletionHandler<void(const ResourceResponse&, RefPtr<FragmentedSharedBuffer>)>&&);void interceptRequest(ResourceLoader&, Function<void(const ResourceRequest&)>&&);@@ -4049,7 +3988,7 @@ index eda400879afb10b687fcbb317c9fdbb3be9c94cd..f3a382c44b53e6b1507fc046e22bff68void searchOtherRequests(const JSC::Yarr::RegularExpression&, Ref<JSON::ArrayOf<Inspector::Protocol::Page::SearchResult>>&);void searchInRequest(Inspector::Protocol::ErrorString&, const Inspector::Protocol::Network::RequestId&, const String& query, bool caseSensitive, bool isRegex, RefPtr<JSON::ArrayOf<Inspector::Protocol::GenericTypes::SearchMatch>>&);-@@ -259,6 +263,7 @@ private:+@@ -275,6 +279,7 @@ private:bool m_enabled { false };bool m_loadingXHRSynchronously { false };bool m_interceptionEnabled { false };@@ -4058,7 +3997,7 @@ index eda400879afb10b687fcbb317c9fdbb3be9c94cd..f3a382c44b53e6b1507fc046e22bff68} // namespace WebCorediff --git a/Source/WebCore/inspector/agents/InspectorPageAgent.cpp b/Source/WebCore/inspector/agents/InspectorPageAgent.cpp-index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1f9bb132cc 100644+index c7c930db458419ffdf3d10b9a7db0d3c2b9615a1..6253804039ea38105bb7647082752cafdd08d895 100644--- a/Source/WebCore/inspector/agents/InspectorPageAgent.cpp+++ b/Source/WebCore/inspector/agents/InspectorPageAgent.cpp@@ -32,19 +32,27 @@@@ -4272,7 +4211,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1fcase Inspector::Protocol::Page::Setting::WebSecurityEnabled:inspectedPageSettings.setWebSecurityEnabledInspectorOverride(value);return { };-@@ -919,15 +1023,16 @@ Inspector::Protocol::ErrorStringOr<void> InspectorPageAgent::setShowPaintRects(b+@@ -920,15 +1024,16 @@ Inspector::Protocol::ErrorStringOr<void> InspectorPageAgent::setShowPaintRects(breturn { };}@@ -4294,33 +4233,24 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1f}void InspectorPageAgent::frameNavigated(LocalFrame& frame)-@@ -935,13 +1040,38 @@ void InspectorPageAgent::frameNavigated(LocalFrame& frame)+@@ -936,13 +1041,29 @@ void InspectorPageAgent::frameNavigated(LocalFrame& frame)m_frontendDispatcher->frameNavigated(buildObjectForFrame(&frame));}+String InspectorPageAgent::serializeFrameID(FrameIdentifier frameID)+{-+ return makeString(frameID.processIdentifier().toUInt64(), '.', frameID.object().toUInt64());++ return makeString(frameID.toUInt64());+}++std::optional<FrameIdentifier> InspectorPageAgent::parseFrameID(String frameID)+{-+ size_t dotPos = frameID.find("."_s);-+ if (dotPos == notFound)-+ return std::nullopt;-++ if (!frameID.containsOnlyASCII())+ return std::nullopt;+-+ String processIDString = frameID.left(dotPos);-+ uint64_t pid = strtoull(processIDString.ascii().data(), 0, 10);-+ auto processID = ObjectIdentifier<WebCore::ProcessIdentifierType>(pid);-+ String frameIDString = frameID.substring(dotPos + 1);-+ uint64_t frameIDNumber = strtoull(frameIDString.ascii().data(), 0, 10);-+ return WebCore::FrameIdentifier {-+ ObjectIdentifier<WebCore::FrameIdentifierType>(frameIDNumber),-+ processID-+ };++WTF_ALLOW_UNSAFE_BUFFER_USAGE_BEGIN++ uint64_t frameIDNumber = strtoull(frameID.ascii().data(), 0, 10);++WTF_ALLOW_UNSAFE_BUFFER_USAGE_END++ return WebCore::FrameIdentifier(frameIDNumber);+}+void InspectorPageAgent::frameDetached(LocalFrame& frame)@@ -4336,7 +4266,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1f}Frame* InspectorPageAgent::frameForId(const Inspector::Protocol::Network::FrameId& frameId)-@@ -953,20 +1083,21 @@ String InspectorPageAgent::frameId(Frame* frame)+@@ -954,20 +1075,21 @@ String InspectorPageAgent::frameId(Frame* frame){if (!frame)return emptyString();@@ -4366,7 +4296,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1f}LocalFrame* InspectorPageAgent::assertFrame(Inspector::Protocol::ErrorString& errorString, const Inspector::Protocol::Network::FrameId& frameId)-@@ -977,11 +1108,6 @@ LocalFrame* InspectorPageAgent::assertFrame(Inspector::Protocol::ErrorString& er+@@ -978,11 +1100,6 @@ LocalFrame* InspectorPageAgent::assertFrame(Inspector::Protocol::ErrorString& erreturn frame;}@@ -4378,7 +4308,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1fvoid InspectorPageAgent::frameStartedLoading(LocalFrame& frame){m_frontendDispatcher->frameStartedLoading(frameId(&frame));-@@ -992,9 +1118,9 @@ void InspectorPageAgent::frameStoppedLoading(LocalFrame& frame)+@@ -993,9 +1110,9 @@ void InspectorPageAgent::frameStoppedLoading(LocalFrame& frame)m_frontendDispatcher->frameStoppedLoading(frameId(&frame));}@@ -4390,7 +4320,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1f}void InspectorPageAgent::frameClearedScheduledNavigation(Frame& frame)-@@ -1041,6 +1167,12 @@ void InspectorPageAgent::defaultUserPreferencesDidChange()+@@ -1042,6 +1159,12 @@ void InspectorPageAgent::defaultUserPreferencesDidChange()m_frontendDispatcher->defaultUserPreferencesDidChange(WTFMove(defaultUserPreferences));}@@ -4403,7 +4333,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1f#if ENABLE(DARK_MODE_CSS)void InspectorPageAgent::defaultAppearanceDidChange(){-@@ -1054,6 +1186,9 @@ void InspectorPageAgent::didClearWindowObjectInWorld(LocalFrame& frame, DOMWrapp+@@ -1055,6 +1178,9 @@ void InspectorPageAgent::didClearWindowObjectInWorld(LocalFrame& frame, DOMWrappreturn;if (m_bootstrapScript.isEmpty())@@ -4413,7 +4343,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1freturn;frame.script().evaluateIgnoringException(ScriptSourceCode(m_bootstrapScript, JSC::SourceTaintedOrigin::Untainted, URL { "web-inspector://bootstrap.js"_str }));-@@ -1101,6 +1236,51 @@ void InspectorPageAgent::didRecalculateStyle()+@@ -1102,6 +1228,51 @@ void InspectorPageAgent::didRecalculateStyle()protectedOverlay()->update();}@@ -4465,7 +4395,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1fRef<Inspector::Protocol::Page::Frame> InspectorPageAgent::buildObjectForFrame(LocalFrame* frame){ASSERT_ARG(frame, frame);-@@ -1194,6 +1374,12 @@ void InspectorPageAgent::applyUserAgentOverride(String& userAgent)+@@ -1195,6 +1366,12 @@ void InspectorPageAgent::applyUserAgentOverride(String& userAgent)userAgent = m_userAgentOverride;}@@ -4478,7 +4408,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1fvoid InspectorPageAgent::applyEmulatedMedia(AtomString& media){if (!m_emulatedMedia.isEmpty())-@@ -1221,11 +1407,13 @@ Inspector::Protocol::ErrorStringOr<String> InspectorPageAgent::snapshotNode(Insp+@@ -1222,11 +1399,13 @@ Inspector::Protocol::ErrorStringOr<String> InspectorPageAgent::snapshotNode(Inspreturn snapshot->toDataURL("image/png"_s, std::nullopt, PreserveResolution::Yes);}@@ -4493,7 +4423,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1fIntRect rectangle(x, y, width, height);RefPtr localMainFrame = m_inspectedPage->localMainFrame();-@@ -1239,6 +1427,43 @@ Inspector::Protocol::ErrorStringOr<String> InspectorPageAgent::snapshotRect(int+@@ -1240,6 +1419,43 @@ Inspector::Protocol::ErrorStringOr<String> InspectorPageAgent::snapshotRect(intreturn snapshot->toDataURL("image/png"_s, std::nullopt, PreserveResolution::Yes);}@@ -4537,7 +4467,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1f#if ENABLE(WEB_ARCHIVE) && USE(CF)Inspector::Protocol::ErrorStringOr<String> InspectorPageAgent::archive(){-@@ -1255,7 +1480,6 @@ Inspector::Protocol::ErrorStringOr<String> InspectorPageAgent::archive()+@@ -1256,7 +1472,6 @@ Inspector::Protocol::ErrorStringOr<String> InspectorPageAgent::archive()}#endif@@ -4545,7 +4475,7 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1fInspector::Protocol::ErrorStringOr<void> InspectorPageAgent::setScreenSizeOverride(std::optional<int>&& width, std::optional<int>&& height){if (width.has_value() != height.has_value())-@@ -1273,6 +1497,498 @@ Inspector::Protocol::ErrorStringOr<void> InspectorPageAgent::setScreenSizeOverri+@@ -1274,6 +1489,496 @@ Inspector::Protocol::ErrorStringOr<void> InspectorPageAgent::setScreenSizeOverrilocalMainFrame->setOverrideScreenSize(FloatSize(width.value_or(0), height.value_or(0)));return { };}@@ -4676,8 +4606,6 @@ index 322ae350279461c5c213a760444580421cb89682..6fc187ab25a6c76c41880fdf63acda1f+ return "Image"_s;+ case AccessibilityRole::ImageMap:+ return "ImageMap"_s;-+ case AccessibilityRole::ImageMapLink:-+ return "ImageMapLink"_s;+ case AccessibilityRole::Insertion:+ return "Insertion"_s;+ case AccessibilityRole::Label:@@ -5384,10 +5312,10 @@ index 8fb27c1045b8073d1487d5b61ccdec23a395bfd1..5008052f587ca4ba90da973c539188deprotected:static SameSiteInfo sameSiteInfo(const Document&, IsForDOMCookieAccess = IsForDOMCookieAccess::No);diff --git a/Source/WebCore/loader/DocumentLoader.cpp b/Source/WebCore/loader/DocumentLoader.cpp-index 858e5866d005b40ce61b79c607c4e5530f23f582..ec3d856897d821aeb4ba8616598932b19b1bcf3f 100644+index 0ed08d14f259f4c9ca92447222bb7bc5344f335b..8f04196baa58d2c9b627f59d5e2c0126bd2b4e01 100644--- a/Source/WebCore/loader/DocumentLoader.cpp+++ b/Source/WebCore/loader/DocumentLoader.cpp-@@ -773,8 +773,10 @@ void DocumentLoader::willSendRequest(ResourceRequest&& newRequest, const Resourc+@@ -774,8 +774,10 @@ void DocumentLoader::willSendRequest(ResourceRequest&& newRequest, const Resourcif (!didReceiveRedirectResponse)return completionHandler(WTFMove(newRequest));@@ -5398,7 +5326,7 @@ index 858e5866d005b40ce61b79c607c4e5530f23f582..ec3d856897d821aeb4ba8616598932b1switch (navigationPolicyDecision) {case NavigationPolicyDecision::IgnoreLoad:case NavigationPolicyDecision::LoadWillContinueInAnotherProcess:-@@ -1573,11 +1575,17 @@ void DocumentLoader::detachFromFrame(LoadWillContinueInAnotherProcess loadWillCo+@@ -1574,11 +1576,17 @@ void DocumentLoader::detachFromFrame(LoadWillContinueInAnotherProcess loadWillCoif (auto navigationID = std::exchange(m_navigationID, { }))frame->loader().client().documentLoaderDetached(*navigationID, loadWillContinueInAnotherProcess);@@ -5419,7 +5347,7 @@ index 858e5866d005b40ce61b79c607c4e5530f23f582..ec3d856897d821aeb4ba8616598932b1{m_navigationID = navigationID;diff --git a/Source/WebCore/loader/DocumentLoader.h b/Source/WebCore/loader/DocumentLoader.h-index 564f944a63868ced85f3c412a4df6dce8d257929..b2228742433ef7f478c20328e62e159d6a051b10 100644+index 3b8896bcc5661929a7f96fb7a01de99b36109dbf..8c3421c5e6a0c36f82c0d7a82f796ca90ba61be7 100644--- a/Source/WebCore/loader/DocumentLoader.h+++ b/Source/WebCore/loader/DocumentLoader.h@@ -224,6 +224,8 @@ public:@@ -5432,10 +5360,10 @@ index 564f944a63868ced85f3c412a4df6dce8d257929..b2228742433ef7f478c20328e62e159dWEBCORE_EXPORT RefPtr<FrameLoader> protectedFrameLoader() const;WEBCORE_EXPORT SubresourceLoader* mainResourceLoader() const;diff --git a/Source/WebCore/loader/FrameLoader.cpp b/Source/WebCore/loader/FrameLoader.cpp-index 7073bb8cdc33fcffd7864505cc9dbeb96202e140..d7bf4bb0695d20eb8e479a703a331ba345fb213b 100644+index 0a408b9d3b2c4daa271691041eb1f4fd897d3e93..650180483ace8b8d031d1d022e847409e948a9a4 100644--- a/Source/WebCore/loader/FrameLoader.cpp+++ b/Source/WebCore/loader/FrameLoader.cpp-@@ -1319,6 +1319,7 @@ void FrameLoader::loadInSameDocument(URL url, RefPtr<SerializedScriptValue> stat+@@ -1323,6 +1323,7 @@ void FrameLoader::loadInSameDocument(URL url, RefPtr<SerializedScriptValue> stat}m_client->dispatchDidNavigateWithinPage();@@ -5443,7 +5371,7 @@ index 7073bb8cdc33fcffd7864505cc9dbeb96202e140..d7bf4bb0695d20eb8e479a703a331ba3document->statePopped(stateObject ? stateObject.releaseNonNull() : SerializedScriptValue::nullValue());m_client->dispatchDidPopStateWithinPage();-@@ -1850,6 +1851,7 @@ void FrameLoader::loadWithDocumentLoader(DocumentLoader* loader, FrameLoadType t+@@ -1861,6 +1862,7 @@ void FrameLoader::loadWithDocumentLoader(DocumentLoader* loader, FrameLoadType tconst String& httpMethod = loader->request().httpMethod();if (shouldPerformFragmentNavigation(isFormSubmission, httpMethod, policyChecker().loadType(), newURL)) {@@ -5451,23 +5379,23 @@ index 7073bb8cdc33fcffd7864505cc9dbeb96202e140..d7bf4bb0695d20eb8e479a703a331ba3RefPtr oldDocumentLoader = m_documentLoader;NavigationAction action { frame->protectedDocument().releaseNonNull(), loader->request(), InitiatedByMainFrame::Unknown, loader->isRequestFromClientOrUserInput(), policyChecker().loadType(), isFormSubmission };-@@ -1887,7 +1889,9 @@ void FrameLoader::loadWithDocumentLoader(DocumentLoader* loader, FrameLoadType t+@@ -1898,7 +1900,9 @@ void FrameLoader::loadWithDocumentLoader(DocumentLoader* loader, FrameLoadType tauto policyDecisionMode = loader->triggeringAction().isFromNavigationAPI() ? PolicyDecisionMode::Synchronous : PolicyDecisionMode::Asynchronous;RELEASE_ASSERT(!isBackForwardLoadType(policyChecker().loadType()) || history().provisionalItem());+ InspectorInstrumentation::willCheckNavigationPolicy(m_frame);- policyChecker().checkNavigationPolicy(ResourceRequest(loader->request()), ResourceResponse { } /* redirectResponse */, loader, WTFMove(formState), [this, frame, allowNavigationToInvalidURL, completionHandler = completionHandlerCaller.release()] (const ResourceRequest& request, WeakPtr<FormState>&& weakFormState, NavigationPolicyDecision navigationPolicyDecision) mutable {+ policyChecker().checkNavigationPolicy(ResourceRequest(loader->request()), ResourceResponse { } /* redirectResponse */, loader, WTFMove(formState), [this, protectedThis = Ref { *this }, allowNavigationToInvalidURL, completionHandler = completionHandlerCaller.release()] (const ResourceRequest& request, WeakPtr<FormState>&& weakFormState, NavigationPolicyDecision navigationPolicyDecision) mutable {+ InspectorInstrumentation::didCheckNavigationPolicy(m_frame, navigationPolicyDecision != NavigationPolicyDecision::ContinueLoad);continueLoadAfterNavigationPolicy(request, RefPtr { weakFormState.get() }.get(), navigationPolicyDecision, allowNavigationToInvalidURL);completionHandler();}, policyDecisionMode);-@@ -3178,10 +3182,15 @@ String FrameLoader::userAgent(const URL& url) const+@@ -3210,10 +3214,15 @@ String FrameLoader::userAgent(const URL& url) constString FrameLoader::navigatorPlatform() const{+ String platform;+- auto customNavigatorPlatform = m_frame->mainFrame().customNavigatorPlatform();+ auto customNavigatorPlatform = m_frame->protectedMainFrame()->customNavigatorPlatform();if (!customNavigatorPlatform.isEmpty())- return customNavigatorPlatform;- return String();@@ -5479,7 +5407,7 @@ index 7073bb8cdc33fcffd7864505cc9dbeb96202e140..d7bf4bb0695d20eb8e479a703a331ba3}void FrameLoader::dispatchOnloadEvents()-@@ -3638,6 +3647,8 @@ void FrameLoader::receivedMainResourceError(const ResourceError& error, LoadWill+@@ -3672,6 +3681,8 @@ void FrameLoader::receivedMainResourceError(const ResourceError& error, LoadWillcheckCompleted();if (frame->page())checkLoadComplete(loadWillContinueInAnotherProcess);@@ -5488,7 +5416,7 @@ index 7073bb8cdc33fcffd7864505cc9dbeb96202e140..d7bf4bb0695d20eb8e479a703a331ba3}void FrameLoader::continueFragmentScrollAfterNavigationPolicy(const ResourceRequest& request, const SecurityOrigin* requesterOrigin, bool shouldContinue, NavigationHistoryBehavior historyHandling)-@@ -4522,9 +4533,6 @@ String FrameLoader::referrer() const+@@ -4566,9 +4577,6 @@ String FrameLoader::referrer() constvoid FrameLoader::dispatchDidClearWindowObjectsInAllWorlds(){@@ -5498,11 +5426,11 @@ index 7073bb8cdc33fcffd7864505cc9dbeb96202e140..d7bf4bb0695d20eb8e479a703a331ba3Vector<Ref<DOMWrapperWorld>> worlds;ScriptController::getAllWorlds(worlds);for (auto& world : worlds)-@@ -4534,13 +4542,12 @@ void FrameLoader::dispatchDidClearWindowObjectsInAllWorlds()+@@ -4578,13 +4586,12 @@ void FrameLoader::dispatchDidClearWindowObjectsInAllWorlds()void FrameLoader::dispatchDidClearWindowObjectInWorld(DOMWrapperWorld& world){Ref frame = m_frame.get();-- if (!frame->checkedScript()->canExecuteScripts(ReasonForCallingCanExecuteScripts::NotAboutToExecuteScript) || !frame->windowProxy().existingJSWindowProxy(world))+- if (!frame->checkedScript()->canExecuteScripts(ReasonForCallingCanExecuteScripts::NotAboutToExecuteScript) || !frame->protectedWindowProxy()->existingJSWindowProxy(world))- return;-- m_client->dispatchDidClearWindowObjectInWorld(world);@@ -5544,7 +5472,7 @@ index 5f70f737d06ced029e3b86a4dc93fd49e8ff4cae..15e6c42cbd4733b526493c3c7dfbea62}diff --git a/Source/WebCore/loader/ProgressTracker.cpp b/Source/WebCore/loader/ProgressTracker.cpp-index 171c80cd90bdc8cc16c5e037b25f07faef0dec4e..0869f1be1699dd1548a2e4df6612d7fff42e3093 100644+index a1554c16a0b836bcf87fea0f4e7831d9e0d7baf0..354e4fef6de9c77b7cad96cc428056ae4e2ff067 100644--- a/Source/WebCore/loader/ProgressTracker.cpp+++ b/Source/WebCore/loader/ProgressTracker.cpp@@ -163,6 +163,8 @@ void ProgressTracker::progressCompleted(LocalFrame& frame)@@ -5566,10 +5494,10 @@ index 171c80cd90bdc8cc16c5e037b25f07faef0dec4e..0869f1be1699dd1548a2e4df6612d7ff}diff --git a/Source/WebCore/loader/cache/CachedResourceLoader.cpp b/Source/WebCore/loader/cache/CachedResourceLoader.cpp-index 6fc201b47f8bb970faba58fa195cc2964b42e45c..f77592b2664d435e00bcf83820e4e8ccb110aeb6 100644+index fb3e38627c8c3491f4994a74c6785cc9767fea2c..000de0c2f725d894cbdfa000d79ed48290eba00a 100644--- a/Source/WebCore/loader/cache/CachedResourceLoader.cpp+++ b/Source/WebCore/loader/cache/CachedResourceLoader.cpp-@@ -1166,8 +1166,11 @@ ResourceErrorOr<CachedResourceHandle<CachedResource>> CachedResourceLoader::requ+@@ -1173,8 +1173,11 @@ ResourceErrorOr<CachedResourceHandle<CachedResource>> CachedResourceLoader::requrequest.updateReferrerPolicy(document ? document->referrerPolicy() : ReferrerPolicy::Default);@@ -5583,7 +5511,7 @@ index 6fc201b47f8bb970faba58fa195cc2964b42e45c..f77592b2664d435e00bcf83820e4e8ccif (RefPtr documentLoader = m_documentLoader.get()) {bool madeHTTPS { request.resourceRequest().wasSchemeOptimisticallyUpgraded() };-@@ -1801,8 +1804,9 @@ Vector<Ref<SVGImage>> CachedResourceLoader::allCachedSVGImages() const+@@ -1811,8 +1814,9 @@ Vector<Ref<SVGImage>> CachedResourceLoader::allCachedSVGImages() constResourceErrorOr<CachedResourceHandle<CachedResource>> CachedResourceLoader::preload(CachedResource::Type type, CachedResourceRequest&& request){@@ -5596,10 +5524,10 @@ index 6fc201b47f8bb970faba58fa195cc2964b42e45c..f77592b2664d435e00bcf83820e4e8ccRefPtr document = m_document.get();ASSERT(document);diff --git a/Source/WebCore/page/ChromeClient.h b/Source/WebCore/page/ChromeClient.h-index 5352cc44f68f9038f7bd64214853fae160f9ba9d..76a9c273cd758af99c2ed4645876b594c55b0ea1 100644+index 51ac3768b20683f26e3a568f390bfe8eba7e1fb5..f6f285ddbe261ccb807e1a57f93f202296f100d2 100644--- a/Source/WebCore/page/ChromeClient.h+++ b/Source/WebCore/page/ChromeClient.h-@@ -362,7 +362,7 @@ public:+@@ -364,7 +364,7 @@ public:#endif#if ENABLE(ORIENTATION_EVENTS)@@ -5609,10 +5537,10 @@ index 5352cc44f68f9038f7bd64214853fae160f9ba9d..76a9c273cd758af99c2ed4645876b594virtual RefPtr<ColorChooser> createColorChooser(ColorChooserClient&, const Color&) = 0;diff --git a/Source/WebCore/page/EventHandler.cpp b/Source/WebCore/page/EventHandler.cpp-index 408ddc7c6541d80568d126ea5ecdb17caf7b10d3..d588b0c5003f8e39cb03cbf28258b7657d86a04f 100644+index 47392ed5c5888954373a1916f757ee9ccf1edbbd..8fb82ad84ea589efaf6074e79ca5a0c2a4df14ca 100644--- a/Source/WebCore/page/EventHandler.cpp+++ b/Source/WebCore/page/EventHandler.cpp-@@ -4462,6 +4462,12 @@ bool EventHandler::handleDrag(const MouseEventWithHitTestResults& event, CheckDr+@@ -4460,6 +4460,12 @@ bool EventHandler::handleDrag(const MouseEventWithHitTestResults& event, CheckDrif (!document)return false;@@ -5625,7 +5553,7 @@ index 408ddc7c6541d80568d126ea5ecdb17caf7b10d3..d588b0c5003f8e39cb03cbf28258b765dragState().dataTransfer = DataTransfer::createForDrag(*document);auto hasNonDefaultPasteboardData = HasNonDefaultPasteboardData::No;-@@ -5053,6 +5059,7 @@ static HitTestResult hitTestResultInFrame(LocalFrame* frame, const LayoutPoint&+@@ -5054,6 +5060,7 @@ static HitTestResult hitTestResultInFrame(LocalFrame* frame, const LayoutPoint&return result;}@@ -5633,7 +5561,7 @@ index 408ddc7c6541d80568d126ea5ecdb17caf7b10d3..d588b0c5003f8e39cb03cbf28258b765HandleUserInputEventResult EventHandler::handleTouchEvent(const PlatformTouchEvent& event){Ref frame = m_frame.get();-@@ -5126,7 +5133,7 @@ HandleUserInputEventResult EventHandler::handleTouchEvent(const PlatformTouchEve+@@ -5127,7 +5134,7 @@ HandleUserInputEventResult EventHandler::handleTouchEvent(const PlatformTouchEve// Increment the platform touch id by 1 to avoid storing a key of 0 in the hashmap.unsigned touchPointTargetKey = point.id() + 1;@@ -5642,7 +5570,7 @@ index 408ddc7c6541d80568d126ea5ecdb17caf7b10d3..d588b0c5003f8e39cb03cbf28258b765bool pointerCancelled = false;#endifRefPtr<EventTarget> touchTarget;-@@ -5173,7 +5180,7 @@ HandleUserInputEventResult EventHandler::handleTouchEvent(const PlatformTouchEve+@@ -5174,7 +5181,7 @@ HandleUserInputEventResult EventHandler::handleTouchEvent(const PlatformTouchEve// we also remove it from the map.touchTarget = m_originatingTouchPointTargets.take(touchPointTargetKey);@@ -5651,7 +5579,7 @@ index 408ddc7c6541d80568d126ea5ecdb17caf7b10d3..d588b0c5003f8e39cb03cbf28258b765HitTestResult result = hitTestResultAtPoint(pagePoint, hitType | HitTestRequest::Type::AllowChildFrameContent);pointerTarget = result.targetElement();pointerCancelled = (pointerTarget != touchTarget);-@@ -5196,7 +5203,7 @@ HandleUserInputEventResult EventHandler::handleTouchEvent(const PlatformTouchEve+@@ -5197,7 +5204,7 @@ HandleUserInputEventResult EventHandler::handleTouchEvent(const PlatformTouchEveif (!targetFrame)continue;@@ -5660,7 +5588,7 @@ index 408ddc7c6541d80568d126ea5ecdb17caf7b10d3..d588b0c5003f8e39cb03cbf28258b765// FIXME: WPE currently does not send touch stationary events, so create a naive TouchReleased PlatformTouchPoint// on release if the hit test result changed since the previous TouchPressed or TouchMovedif (pointState == PlatformTouchPoint::TouchReleased && pointerCancelled) {-@@ -5286,6 +5293,7 @@ HandleUserInputEventResult EventHandler::handleTouchEvent(const PlatformTouchEve+@@ -5287,6 +5294,7 @@ HandleUserInputEventResult EventHandler::handleTouchEvent(const PlatformTouchEvereturn swallowedEvent;}@@ -5669,7 +5597,7 @@ index 408ddc7c6541d80568d126ea5ecdb17caf7b10d3..d588b0c5003f8e39cb03cbf28258b765#if ENABLE(TOUCH_EVENTS)diff --git a/Source/WebCore/page/FocusController.cpp b/Source/WebCore/page/FocusController.cpp-index 676ca3ed5df66159852331a1373cdef66295fd3f..ed0dbb2445822df19e3d013e1ebe2cbaaa8d20eb 100644+index f4a1e3408623e2b338149d1a129dc8075c764f59..571c4c6e9a873167bbc78b0708ffac44b7a8e641 100644--- a/Source/WebCore/page/FocusController.cpp+++ b/Source/WebCore/page/FocusController.cpp@@ -586,13 +586,14 @@ bool FocusController::relinquishFocusToChrome(FocusDirection direction)@@ -5690,10 +5618,10 @@ index 676ca3ed5df66159852331a1373cdef66295fd3f..ed0dbb2445822df19e3d013e1ebe2cba}diff --git a/Source/WebCore/page/FrameSnapshotting.cpp b/Source/WebCore/page/FrameSnapshotting.cpp-index 0c099f95827d6f9fe307704ef9d7754fbb3d24f7..8e36dd7dca078f2de0c1733c8d462d17b2a3d5c4 100644+index 3474800864049dcbe6c84746c4216e72a68fa48f..8f5d536921eeb41c77fe689c036dcb77e625e431 100644--- a/Source/WebCore/page/FrameSnapshotting.cpp+++ b/Source/WebCore/page/FrameSnapshotting.cpp-@@ -111,7 +111,7 @@ RefPtr<ImageBuffer> snapshotFrameRectWithClip(LocalFrame& frame, const IntRect&+@@ -115,7 +115,7 @@ RefPtr<ImageBuffer> snapshotFrameRectWithClip(LocalFrame& frame, const IntRect&// Other paint behaviors are set by paintContentsForSnapshot.frame.view()->setPaintBehavior(paintBehavior);@@ -5702,7 +5630,7 @@ index 0c099f95827d6f9fe307704ef9d7754fbb3d24f7..8e36dd7dca078f2de0c1733c8d462d17if (options.flags.contains(SnapshotFlags::PaintWith3xBaseScale))scaleFactor = 3;-@@ -130,6 +130,8 @@ RefPtr<ImageBuffer> snapshotFrameRectWithClip(LocalFrame& frame, const IntRect&+@@ -134,6 +134,8 @@ RefPtr<ImageBuffer> snapshotFrameRectWithClip(LocalFrame& frame, const IntRect&return nullptr;buffer->context().translate(-imageRect.location());@@ -5711,7 +5639,7 @@ index 0c099f95827d6f9fe307704ef9d7754fbb3d24f7..8e36dd7dca078f2de0c1733c8d462d17if (!clipRects.isEmpty()) {Path clipPath;-@@ -138,7 +140,10 @@ RefPtr<ImageBuffer> snapshotFrameRectWithClip(LocalFrame& frame, const IntRect&+@@ -142,7 +144,10 @@ RefPtr<ImageBuffer> snapshotFrameRectWithClip(LocalFrame& frame, const IntRect&buffer->context().clipPath(clipPath);}@@ -5724,14 +5652,14 @@ index 0c099f95827d6f9fe307704ef9d7754fbb3d24f7..8e36dd7dca078f2de0c1733c8d462d17}diff --git a/Source/WebCore/page/FrameSnapshotting.h b/Source/WebCore/page/FrameSnapshotting.h-index 3ab70c27fef52f5d933cd2338a7c2f96e2debc88..39fc13df5ce132f8d028cd5039c607fe8963ddcf 100644+index 713cb9c3c59bbad23ef0b821ab27b3d669a7dea8..12077ebf0978b6b52e6af4602767c09d9f3cd9de 100644--- a/Source/WebCore/page/FrameSnapshotting.h+++ b/Source/WebCore/page/FrameSnapshotting.h-@@ -56,6 +56,7 @@ enum class SnapshotFlags : uint16_t {- Accelerated = 1 << 8,- ExcludeReplacedContent = 1 << 9,- PaintWith3xBaseScale = 1 << 10,-+ OmitDeviceScaleFactor = 1 << 11,+@@ -58,6 +58,7 @@ enum class SnapshotFlags : uint16_t {+ PaintWith3xBaseScale = 1 << 10,+ ExcludeText = 1 << 11,+ FixedAndStickyLayersOnly = 1 << 12,++ OmitDeviceScaleFactor = 1 << 13,};struct SnapshotOptions {@@ -5757,7 +5685,7 @@ index adc6185687b6fcee3a49819d0149cde24a4485bf..a33e5db46933c514abce86e3f264de9b}diff --git a/Source/WebCore/page/LocalFrame.cpp b/Source/WebCore/page/LocalFrame.cpp-index 090657b2602a09708b6b859952b466fcca07f174..ce5df33671b65494c0d222ed9086d7fe828f3702 100644+index 54cab8376adfb6dd1e5ca32e170219290e4f0508..d212eece82066ba788d049e9aff212ff3493a6c3 100644--- a/Source/WebCore/page/LocalFrame.cpp+++ b/Source/WebCore/page/LocalFrame.cpp@@ -41,6 +41,7 @@@@ -5765,10 +5693,10 @@ index 090657b2602a09708b6b859952b466fcca07f174..ce5df33671b65494c0d222ed9086d7fe#include "Chrome.h"#include "ChromeClient.h"+#include "ComposedTreeIterator.h"+ #include "DiagnosticLoggingClient.h"+ #include "DiagnosticLoggingKeys.h"#include "DocumentLoader.h"- #include "DocumentType.h"- #include "Editing.h"-@@ -57,6 +58,7 @@+@@ -59,6 +60,7 @@#include "FrameSelection.h"#include "GraphicsContext.h"#include "GraphicsLayer.h"@@ -5776,15 +5704,15 @@ index 090657b2602a09708b6b859952b466fcca07f174..ce5df33671b65494c0d222ed9086d7fe#include "HTMLAttachmentElement.h"#include "HTMLFormControlElement.h"#include "HTMLFormElement.h"-@@ -79,6 +81,7 @@+@@ -81,6 +83,7 @@#include "Logging.h"#include "Navigator.h"#include "NodeList.h"+#include "NodeRenderStyle.h"#include "NodeTraversal.h"#include "Page.h"- #include "ProcessSyncClient.h"-@@ -202,6 +205,7 @@ LocalFrame::LocalFrame(Page& page, ClientCreator&& clientCreator, FrameIdentifie+ #include "PaymentSession.h"+@@ -205,6 +208,7 @@ LocalFrame::LocalFrame(Page& page, ClientCreator&& clientCreator, FrameIdentifievoid LocalFrame::init(){@@ -5792,7 +5720,7 @@ index 090657b2602a09708b6b859952b466fcca07f174..ce5df33671b65494c0d222ed9086d7feprotectedLoader()->init();}-@@ -431,7 +435,7 @@ void LocalFrame::orientationChanged()+@@ -442,7 +446,7 @@ void LocalFrame::orientationChanged()IntDegrees LocalFrame::orientation() const{if (RefPtr page = this->page())@@ -5801,9 +5729,9 @@ index 090657b2602a09708b6b859952b466fcca07f174..ce5df33671b65494c0d222ed9086d7fereturn 0;}#endif // ENABLE(ORIENTATION_EVENTS)-@@ -1501,6 +1505,364 @@ void LocalFrame::reportResourceMonitoringWarning()-- #endif+@@ -1549,6 +1553,364 @@ RefPtr<SecurityOrigin> LocalFrame::frameDocumentSecurityOrigin() const+ return nullptr;+ }+#if !PLATFORM(IOS_FAMILY)+@@ -6167,7 +6095,7 @@ index 090657b2602a09708b6b859952b466fcca07f174..ce5df33671b65494c0d222ed9086d7fe#undef FRAME_RELEASE_LOG_ERRORdiff --git a/Source/WebCore/page/LocalFrame.h b/Source/WebCore/page/LocalFrame.h-index 82f67e2e21e64b95800696a6bb22f15298866979..26a1bc0736e00964a5beb151bb53c430c36e029d 100644+index b46fd5f993569302c23b7302a493a37fd8c1f440..2d9bbfc639deba681ecb7465d87981a787901dac 100644--- a/Source/WebCore/page/LocalFrame.h+++ b/Source/WebCore/page/LocalFrame.h@@ -28,8 +28,10 @@@@ -6238,7 +6166,7 @@ index 82f67e2e21e64b95800696a6bb22f15298866979..26a1bc0736e00964a5beb151bb53c430ViewportArguments m_viewportArguments;diff --git a/Source/WebCore/page/Page.cpp b/Source/WebCore/page/Page.cpp-index 916d2cc402fb668d19143022b5e3c58838a8920d..0f389d033511bdc7ef92fb4bd8a7525f92a23daa 100644+index a9369054928a0c9c1f3aef0252c2da3d33d4ce7c..2b151666e718fb037471ab7005c62623c4ee332d 100644--- a/Source/WebCore/page/Page.cpp+++ b/Source/WebCore/page/Page.cpp@@ -655,6 +655,45 @@ void Page::setOverrideViewportArguments(const std::optional<ViewportArguments>&@@ -6287,7 +6215,7 @@ index 916d2cc402fb668d19143022b5e3c58838a8920d..0f389d033511bdc7ef92fb4bd8a7525fScrollingCoordinator* Page::scrollingCoordinator(){if (!m_scrollingCoordinator && m_settings->scrollingCoordinatorEnabled()) {-@@ -4211,6 +4250,26 @@ void Page::setUseDarkAppearanceOverride(std::optional<bool> valueOverride)+@@ -4214,6 +4253,26 @@ void Page::setUseDarkAppearanceOverride(std::optional<bool> valueOverride)appearanceDidChange();}@@ -6315,10 +6243,10 @@ index 916d2cc402fb668d19143022b5e3c58838a8920d..0f389d033511bdc7ef92fb4bd8a7525f{if (insets == m_fullscreenInsets)diff --git a/Source/WebCore/page/Page.h b/Source/WebCore/page/Page.h-index 11c3b26d33342999041fb464ad487cd7dc0e6891..41bfb065fe96f08c21f296e2565770dbf81d163e 100644+index 4e33885a4771eb8260c8cebb14991d780f95be3d..e413dde6db076f587cbf520f17bfa5078320f8cc 100644--- a/Source/WebCore/page/Page.h+++ b/Source/WebCore/page/Page.h-@@ -365,6 +365,9 @@ public:+@@ -366,6 +366,9 @@ public:const ViewportArguments* overrideViewportArguments() const { return m_overrideViewportArguments.get(); }WEBCORE_EXPORT void setOverrideViewportArguments(const std::optional<ViewportArguments>&);@@ -6328,7 +6256,7 @@ index 11c3b26d33342999041fb464ad487cd7dc0e6891..41bfb065fe96f08c21f296e2565770dbstatic void refreshPlugins(bool reload);WEBCORE_EXPORT PluginData& pluginData();WEBCORE_EXPORT Ref<PluginData> protectedPluginData();-@@ -462,6 +465,10 @@ public:+@@ -463,6 +466,10 @@ public:#if ENABLE(DRAG_SUPPORT)DragController& dragController() { return m_dragController.get(); }const DragController& dragController() const { return m_dragController.get(); }@@ -6339,7 +6267,7 @@ index 11c3b26d33342999041fb464ad487cd7dc0e6891..41bfb065fe96f08c21f296e2565770db#endifFocusController& focusController() const { return *m_focusController; }WEBCORE_EXPORT CheckedRef<FocusController> checkedFocusController() const;-@@ -647,6 +654,10 @@ public:+@@ -648,6 +655,10 @@ public:WEBCORE_EXPORT void setUseColorAppearance(bool useDarkAppearance, bool useElevatedUserInterfaceLevel);bool defaultUseDarkAppearance() const { return m_useDarkAppearance; }void setUseDarkAppearanceOverride(std::optional<bool>);@@ -6362,7 +6290,7 @@ index 11c3b26d33342999041fb464ad487cd7dc0e6891..41bfb065fe96f08c21f296e2565770db#if ENABLE(DEVICE_ORIENTATION) && PLATFORM(IOS_FAMILY)DeviceOrientationUpdateProvider* deviceOrientationUpdateProvider() const { return m_deviceOrientationUpdateProvider.get(); }#endif-@@ -1392,6 +1408,9 @@ private:+@@ -1389,6 +1405,9 @@ private:#if ENABLE(DRAG_SUPPORT)const UniqueRef<DragController> m_dragController;@@ -6372,7 +6300,7 @@ index 11c3b26d33342999041fb464ad487cd7dc0e6891..41bfb065fe96f08c21f296e2565770db#endifstd::unique_ptr<FocusController> m_focusController;#if ENABLE(CONTEXT_MENUS)-@@ -1469,6 +1488,8 @@ private:+@@ -1467,6 +1486,8 @@ private:bool m_useElevatedUserInterfaceLevel { false };bool m_useDarkAppearance { false };std::optional<bool> m_useDarkAppearanceOverride;@@ -6381,7 +6309,7 @@ index 11c3b26d33342999041fb464ad487cd7dc0e6891..41bfb065fe96f08c21f296e2565770db#if ENABLE(TEXT_AUTOSIZING)float m_textAutosizingWidth { 0 };-@@ -1651,6 +1672,11 @@ private:+@@ -1649,6 +1670,11 @@ private:#endifstd::unique_ptr<ViewportArguments> m_overrideViewportArguments;@@ -6394,7 +6322,7 @@ index 11c3b26d33342999041fb464ad487cd7dc0e6891..41bfb065fe96f08c21f296e2565770db#if ENABLE(DEVICE_ORIENTATION) && PLATFORM(IOS_FAMILY)RefPtr<DeviceOrientationUpdateProvider> m_deviceOrientationUpdateProvider;diff --git a/Source/WebCore/page/PageConsoleClient.cpp b/Source/WebCore/page/PageConsoleClient.cpp-index 33ef23f456d389c876f7d66732a1ae9bb2ed7662..f0d38ba2208975e9a31f634096caf20ecb7340be 100644+index ad70f3c37261ab24afc23f7136ae3feb1fcbe154..ecf31d4aaf2080e705e9caec75596104bdfce786 100644--- a/Source/WebCore/page/PageConsoleClient.cpp+++ b/Source/WebCore/page/PageConsoleClient.cpp@@ -456,4 +456,9 @@ Ref<Page> PageConsoleClient::protectedPage() const@@ -6514,10 +6442,10 @@ index 24ed7c019bea4df52f2883db0e40bdbc2dc74ebd..a788f534d9e0e8124153c7f380b4fdb2}diff --git a/Source/WebCore/page/csp/ContentSecurityPolicy.cpp b/Source/WebCore/page/csp/ContentSecurityPolicy.cpp-index 51933cf69017936dfa08823d4a1a778d3d64db71..2101a8ab75fc7adf5ebcbf245e2083a2b750271b 100644+index 4861e2276c172ea347cd31f68029b49df9350fe1..91c6eb5e3031f863d7b2483d9ba8be75c8718ea0 100644--- a/Source/WebCore/page/csp/ContentSecurityPolicy.cpp+++ b/Source/WebCore/page/csp/ContentSecurityPolicy.cpp-@@ -348,6 +348,8 @@ bool ContentSecurityPolicy::allowContentSecurityPolicySourceStarToMatchAnyProtoc+@@ -372,6 +372,8 @@ bool ContentSecurityPolicy::allowContentSecurityPolicySourceStarToMatchAnyProtoctemplate<typename Predicate, typename... Args>typename std::enable_if<!std::is_convertible<Predicate, ContentSecurityPolicy::ViolatedDirectiveCallback>::value, bool>::type ContentSecurityPolicy::allPoliciesWithDispositionAllow(Disposition disposition, Predicate&& predicate, Args&&... args) const{@@ -6526,7 +6454,7 @@ index 51933cf69017936dfa08823d4a1a778d3d64db71..2101a8ab75fc7adf5ebcbf245e2083a2bool isReportOnly = disposition == ContentSecurityPolicy::Disposition::ReportOnly;for (auto& policy : m_policies) {if (policy->isReportOnly() != isReportOnly)-@@ -361,6 +363,8 @@ typename std::enable_if<!std::is_convertible<Predicate, ContentSecurityPolicy::V+@@ -385,6 +387,8 @@ typename std::enable_if<!std::is_convertible<Predicate, ContentSecurityPolicy::Vtemplate<typename Predicate, typename... Args>bool ContentSecurityPolicy::allPoliciesWithDispositionAllow(Disposition disposition, ViolatedDirectiveCallback&& callback, Predicate&& predicate, Args&&... args) const{@@ -6535,7 +6463,7 @@ index 51933cf69017936dfa08823d4a1a778d3d64db71..2101a8ab75fc7adf5ebcbf245e2083a2bool isReportOnly = disposition == ContentSecurityPolicy::Disposition::ReportOnly;bool isAllowed = true;for (auto& policy : m_policies) {-@@ -377,6 +381,8 @@ bool ContentSecurityPolicy::allPoliciesWithDispositionAllow(Disposition disposit+@@ -401,6 +405,8 @@ bool ContentSecurityPolicy::allPoliciesWithDispositionAllow(Disposition disposittemplate<typename Predicate, typename... Args>bool ContentSecurityPolicy::allPoliciesAllow(NOESCAPE const ViolatedDirectiveCallback& callback, Predicate&& predicate, Args&&... args) const{@@ -6631,10 +6559,10 @@ index 0000000000000000000000000000000000000000..803239911006cfb3b03ea911c003f2d2++}diff --git a/Source/WebCore/platform/Cairo.cmake b/Source/WebCore/platform/Cairo.cmake-index 29492dd39b08db28aad2bf2439eb3e2bbcf25ad7..2b603cb8440b1b5057c87fcbd6909c61bae4ceb8 100644+index 96baa501801c5952d4b5b203dff278adb54aaa54..34c498f6050388d30e4190604e7af6f68b33fab9 100644--- a/Source/WebCore/platform/Cairo.cmake+++ b/Source/WebCore/platform/Cairo.cmake-@@ -14,6 +14,7 @@ list(APPEND WebCore_PRIVATE_FRAMEWORK_HEADERS+@@ -15,6 +15,7 @@ list(APPEND WebCore_PRIVATE_FRAMEWORK_HEADERSplatform/graphics/cairo/ImageBufferCairoBackend.hplatform/graphics/cairo/ImageBufferCairoImageSurfaceBackend.hplatform/graphics/cairo/ImageBufferCairoSurfaceBackend.h@@ -6688,6 +6616,19 @@ index 2f4e02e783ac512aeb76e0abe7e253b57bfda937..94e0c9335720324a746f300a26b17a28IntSize dragImageSize(DragImageRef){+diff --git a/Source/WebCore/platform/DragImage.h b/Source/WebCore/platform/DragImage.h+index 77286d8e715825c9c7c0d329480fc0fc497fe561..5ea53eb8b7e53dd5a5950c65a38c1d23bfe46681 100644+--- a/Source/WebCore/platform/DragImage.h++++ b/Source/WebCore/platform/DragImage.h+@@ -60,7 +60,7 @@ class Node;+ typedef RetainPtr<CGImageRef> DragImageRef;+ #elif PLATFORM(MAC)+ typedef RetainPtr<NSImage> DragImageRef;+-#elif PLATFORM(WIN)++#elif PLATFORM(WIN) && USE(CAIRO)+ typedef HBITMAP DragImageRef;+ #elif USE(CAIRO)+ typedef RefPtr<cairo_surface_t> DragImageRef;diff --git a/Source/WebCore/platform/Pasteboard.h b/Source/WebCore/platform/Pasteboard.hindex 1b1a1147d4948e9281a114281e95d57d3b0ccf27..e21ccb98542cc582ad2489d301cb29c2b0c03f4b 100644--- a/Source/WebCore/platform/Pasteboard.h@@ -6783,10 +6724,10 @@ index 63ffd6ca32c3baee03db2a9419c4f7e9de45388a..c60c7a8d1f110472117c8c4e969fd05f#endifdiff --git a/Source/WebCore/platform/PlatformScreen.cpp b/Source/WebCore/platform/PlatformScreen.cpp-index ef0abc9a93e878897ffc9d2497a3da0fca5b37b7..8868e20e3720ce33d3148cea5c3bcdaf2ff2c4e5 100644+index ef0abc9a93e878897ffc9d2497a3da0fca5b37b7..abd96c6d1a6c3ab9e0121c1e78f2f75a5f805b32 100644--- a/Source/WebCore/platform/PlatformScreen.cpp+++ b/Source/WebCore/platform/PlatformScreen.cpp-@@ -85,3 +85,25 @@ OptionSet<ContentsFormat> screenContentsFormatsForTesting()+@@ -85,3 +85,24 @@ OptionSet<ContentsFormat> screenContentsFormatsForTesting()} // namespace WebCore#endif // PLATFORM(COCOA) || PLATFORM(GTK) || (PLATFORM(WPE) && ENABLE(WPE_PLATFORM))@@ -6794,45 +6735,41 @@ index ef0abc9a93e878897ffc9d2497a3da0fca5b37b7..8868e20e3720ce33d3148cea5c3bcdaf+#if ENABLE(TOUCH_EVENTS)+namespace WebCore {+-+static std::optional<bool> screenHasTouchDeviceOverride = std::nullopt;++static std::optional<bool> _screenHasTouchDeviceOverride = std::nullopt;+++void setScreenHasTouchDeviceOverride(bool value) {-+ screenHasTouchDeviceOverride = value;++ _screenHasTouchDeviceOverride = value;++}++std::optional<bool> screenHasTouchDeviceOverride() {++ return _screenHasTouchDeviceOverride;+}++bool screenHasTouchDevice() {-+ if (screenHasTouchDeviceOverride)-+ return screenHasTouchDeviceOverride.value();++ if (screenHasTouchDeviceOverride())++ return screenHasTouchDeviceOverride().value();+ return platformScreenHasTouchDevice();+}-+bool screenIsTouchPrimaryInputDevice() {-+ if (screenHasTouchDeviceOverride)-+ return screenHasTouchDeviceOverride.value();-+ return platformScreenIsTouchPrimaryInputDevice();-+}++} // namespace WebCore+#endifdiff --git a/Source/WebCore/platform/PlatformScreen.h b/Source/WebCore/platform/PlatformScreen.h-index dfef4ecbfb44cc985d1d26eaceae855cb427c002..665da262aeb6524f48b2de2418a474a65d0ef754 100644+index 82a54ac2de2ddf4650e4b48db129fe25f6562264..d144ba15d18d2e892c25988dab27636135353a99 100644--- a/Source/WebCore/platform/PlatformScreen.h+++ b/Source/WebCore/platform/PlatformScreen.h-@@ -160,12 +160,16 @@ WEBCORE_EXPORT float screenScaleFactor(UIScreen * = nullptr);+@@ -160,10 +160,14 @@ WEBCORE_EXPORT float screenScaleFactor(UIScreen * = nullptr);#endif#if ENABLE(TOUCH_EVENTS)--#if PLATFORM(GTK) || PLATFORM(WPE)+-#if PLATFORM(GTK)+WEBCORE_EXPORT void setScreenHasTouchDeviceOverride(bool);++WEBCORE_EXPORT std::optional<bool> screenHasTouchDeviceOverride();+WEBCORE_EXPORT bool screenHasTouchDevice();- WEBCORE_EXPORT bool screenIsTouchPrimaryInputDevice();-+#if PLATFORM(GTK) || PLATFORM(WPE)++#if PLATFORM(GTK)+bool platformScreenHasTouchDevice();-+bool platformScreenIsTouchPrimaryInputDevice();#else-constexpr bool screenHasTouchDevice() { return true; }--constexpr bool screenIsTouchPrimaryInputDevice() { return true; }+constexpr bool platformScreenHasTouchDevice() { return true; }-+constexpr bool platformScreenIsTouchPrimaryInputDevice() { return true; }#endif#endif@@ -6863,11 +6800,11 @@ index 34715d27b529750fc866db87cd330b5184286771..3eefa218af075f76d98012cdeae7e4b3// create a PlatformTouchPoint of type TouchCancelled artificiallyPlatformTouchPoint(unsigned id, State state, IntPoint screenPos, IntPoint pos)diff --git a/Source/WebCore/platform/Skia.cmake b/Source/WebCore/platform/Skia.cmake-index 31460a79014b0a8b21fdfe71759af14ff2da46d7..f2594d701502102fed89d711694b64e05a863aaa 100644+index c39b57e01190b833be46452c3d964fe243c216d3..6e4af1509037697421cf0c80e2459da0bad79ba8 100644--- a/Source/WebCore/platform/Skia.cmake+++ b/Source/WebCore/platform/Skia.cmake-@@ -13,6 +13,7 @@ list(APPEND WebCore_PRIVATE_FRAMEWORK_HEADERS-+@@ -14,6 +14,7 @@ list(APPEND WebCore_PRIVATE_FRAMEWORK_HEADERS+ platform/graphics/skia/FontCascadeSkiaInlines.hplatform/graphics/skia/GraphicsContextSkia.hplatform/graphics/skia/ImageBufferSkiaBackend.h+ platform/graphics/skia/ImageBufferUtilitiesSkia.h@@ -7008,10 +6945,10 @@ index 3d0ab7eceaf2a6321685bc362eb9b25600fd98fd..2d7e9a399bf2e9dc3f373d5fa3db99fanamespace WebCore {diff --git a/Source/WebCore/platform/graphics/win/ComplexTextControllerUniscribe.cpp b/Source/WebCore/platform/graphics/win/ComplexTextControllerUniscribe.cpp-index 3f0b75a0702db1ed10334c80e4813094571f588c..ea5ff6b7e7bd4c3b8babebc294d7d7c94fc6afb6 100644+index 78ea08023ebd5f1b41b06cd843b6dce4ee80dd50..55fed94b774f033b4f75e2dee85dc27cf2e2689e 100644--- a/Source/WebCore/platform/graphics/win/ComplexTextControllerUniscribe.cpp+++ b/Source/WebCore/platform/graphics/win/ComplexTextControllerUniscribe.cpp-@@ -169,6 +169,33 @@ static Vector<unsigned> stringIndicesFromClusters(const Vector<WORD>& clusters,+@@ -168,6 +168,33 @@ static Vector<unsigned> stringIndicesFromClusters(const Vector<WORD>& clusters,return stringIndices;}@@ -7045,7 +6982,7 @@ index 3f0b75a0702db1ed10334c80e4813094571f588c..ea5ff6b7e7bd4c3b8babebc294d7d7c9void ComplexTextController::collectComplexTextRunsForCharacters(std::span<const UChar> cp, unsigned stringLocation, const Font* font){if (!font) {-@@ -198,6 +225,8 @@ void ComplexTextController::collectComplexTextRunsForCharacters(std::span<const+@@ -197,6 +224,8 @@ void ComplexTextController::collectComplexTextRunsForCharacters(std::span<const}items.resize(numItems + 1);@@ -7317,27 +7254,18 @@ index 2b7d3dc70fdfec767d8caa13966c4051ee73aead..7fa8e155bef817c837042c8d6c4dcb84{switch (val) {diff --git a/Source/WebCore/platform/gtk/PlatformScreenGtk.cpp b/Source/WebCore/platform/gtk/PlatformScreenGtk.cpp-index 9ea18000578dd47295b2ce4da7fa00b39b5cac81..41bdd2d741b469acb134220df7e0c10209bd9f62 100644+index 1339241aae69b657ffa40b603eea992c45db0e65..9194ff5f8308e5cf22fb250723ae4161142da45f 100644--- a/Source/WebCore/platform/gtk/PlatformScreenGtk.cpp+++ b/Source/WebCore/platform/gtk/PlatformScreenGtk.cpp-@@ -132,7 +132,7 @@ bool screenSupportsExtendedColor(Widget*)+@@ -121,7 +121,7 @@ bool screenSupportsExtendedColor(Widget*)}#if ENABLE(TOUCH_EVENTS)-bool screenHasTouchDevice()+bool platformScreenHasTouchDevice(){- auto* display = gdk_display_get_default();- if (!display)-@@ -142,7 +142,7 @@ bool screenHasTouchDevice()- return seat ? gdk_seat_get_capabilities(seat) & GDK_SEAT_CAPABILITY_TOUCH : true;+ return getScreenProperties().screenHasTouchDevice;}---bool screenIsTouchPrimaryInputDevice()-+bool platformScreenIsTouchPrimaryInputDevice()- {- auto* display = gdk_display_get_default();- if (!display)diff --git a/Source/WebCore/platform/libwpe/PasteboardLibWPE.cpp b/Source/WebCore/platform/libwpe/PasteboardLibWPE.cppindex ae439e30f1fb239d18e1164e8896dfb272c75673..4cf29eda13d1f2dc2f03750c0ef8985b17de7f50 100644--- a/Source/WebCore/platform/libwpe/PasteboardLibWPE.cpp@@ -7809,7 +7737,7 @@ index a8674916429908cabb86bd95dc5b3da217e1556b..6a464e2b0c1c45cd4e8effba678b8dde{switch (val) {diff --git a/Source/WebCore/platform/libwpe/PlatformPasteboardLibWPE.cpp b/Source/WebCore/platform/libwpe/PlatformPasteboardLibWPE.cpp-index 065c1b362537547bc732bd9ded7e801ddf938ef8..448321a8388b7075173061caf8c9b272997e02fd 100644+index 16b45d9d3f3787a348d2d26427ca2b03fd5cf3d5..448321a8388b7075173061caf8c9b272997e02fd 100644--- a/Source/WebCore/platform/libwpe/PlatformPasteboardLibWPE.cpp+++ b/Source/WebCore/platform/libwpe/PlatformPasteboardLibWPE.cpp@@ -31,10 +31,18 @@@@ -7839,7 +7767,7 @@ index 065c1b362537547bc732bd9ded7e801ddf938ef8..448321a8388b7075173061caf8c9b272- wpe_pasteboard_get_types(m_pasteboard, &pasteboardTypes);- for (auto& typeString : unsafeMakeSpan(pasteboardTypes.strings, pasteboardTypes.length)) {- const auto length = std::min(static_cast<size_t>(typeString.length), std::numeric_limits<size_t>::max());-- types.append(String({ typeString.data, length }));+- types.append(String(unsafeMakeSpan(typeString.data, length)));- }-- wpe_pasteboard_string_vector_free(&pasteboardTypes);@@ -7855,7 +7783,7 @@ index 065c1b362537547bc732bd9ded7e801ddf938ef8..448321a8388b7075173061caf8c9b272- return String();-- const auto length = std::min(static_cast<size_t>(string.length), std::numeric_limits<size_t>::max());-- String returnValue({ string.data, length });+- String returnValue(unsafeMakeSpan(string.data, length));-- wpe_pasteboard_string_free(&string);- return returnValue;@@ -7930,10 +7858,10 @@ index 1178c8fb001994bc9e6166376a367d9bc148913c..fcc6534568cad6b42a819a435f84ba2bm_commonHeaders.append(CommonHeader { name, value });}diff --git a/Source/WebCore/platform/network/NetworkStorageSession.h b/Source/WebCore/platform/network/NetworkStorageSession.h-index 8c57734966ccfaf38dbb7fd956e71f3d3f65a477..594e5031caba89142535a16c2fb132bb878aab21 100644+index 18e1d04c6f984c1c3502542399ab1b8eeba1f239..2ec3ed7e28cdf802c017ca705bab3bf769f69a21 100644--- a/Source/WebCore/platform/network/NetworkStorageSession.h+++ b/Source/WebCore/platform/network/NetworkStorageSession.h-@@ -200,6 +200,7 @@ public:+@@ -202,6 +202,7 @@ public:NetworkingContext* context() const;#endif@@ -8023,7 +7951,7 @@ index be9d60dc24eec83f9b7fad5c9bbcdffc2cbd3bb4..9fe86dc133adb69e21a1e9067ea0b2a1ResourceResponseBase::Source source;ResourceResponseBase::Type type;diff --git a/Source/WebCore/platform/network/cocoa/NetworkStorageSessionCocoa.mm b/Source/WebCore/platform/network/cocoa/NetworkStorageSessionCocoa.mm-index ab7a9d832f0573bd402c5643d3eee3aa3e3b33c6..7dcb122411c4b6bf45c05e3a6edf7b133c5d9e9e 100644+index d938386a2a7bb9a338b781706434fbee753a5ad4..96b8e6d3b7fc65fb6f04162e4975467b3cbd3cf4 100644--- a/Source/WebCore/platform/network/cocoa/NetworkStorageSessionCocoa.mm+++ b/Source/WebCore/platform/network/cocoa/NetworkStorageSessionCocoa.mm@@ -552,6 +552,22 @@ bool NetworkStorageSession::setCookieFromDOM(const URL& firstParty, const SameSi@@ -8036,14 +7964,14 @@ index ab7a9d832f0573bd402c5643d3eee3aa3e3b33c6..7dcb122411c4b6bf45c05e3a6edf7b13+ size_t count = cookieValues.size();+ auto* cookies = [NSMutableArray arrayWithCapacity:count];+ for (const auto& cookieValue : cookieValues) {-+ NSString* cookieString = (NSString *)cookieValue;++ NSString* cookieString = cookieValue.createNSString().autorelease();+ NSString* cookieKey = @"Set-Cookie";+ NSDictionary* headers = [NSDictionary dictionaryWithObjects:[NSArray arrayWithObject:cookieString] forKeys:[NSArray arrayWithObject:cookieKey]];-+ NSArray<NSHTTPCookie*>* parsedCookies = [NSHTTPCookie cookiesWithResponseHeaderFields:headers forURL:(NSURL *)url];++ NSArray<NSHTTPCookie*>* parsedCookies = [NSHTTPCookie cookiesWithResponseHeaderFields:headers forURL:url.createNSURL().get()];+ [cookies addObject:parsedCookies[0]];+ }-+ NSURL *cookieURL = url;-+ setHTTPCookiesForURL(cookieStorage().get(), cookies, cookieURL, firstParty, sameSiteInfo);++ NSURL *cookieURL = url.createNSURL().get();++ setHTTPCookiesForURL(cookieStorage().get(), cookies, cookieURL, firstParty.createNSURL().get(), sameSiteInfo);+}+static NSHTTPCookieAcceptPolicy httpCookieAcceptPolicy(CFHTTPCookieStorageRef cookieStorage)@@ -8143,10 +8071,10 @@ index 2d7a77d759aaea9a541030af5e6015a8ed9c97a4..a0c947d325c984045dbbdf2580d19a32WEBCORE_EXPORT void send(CurlStreamID, UniqueArray<uint8_t>&&, size_t);diff --git a/Source/WebCore/platform/network/curl/NetworkStorageSessionCurl.cpp b/Source/WebCore/platform/network/curl/NetworkStorageSessionCurl.cpp-index b422dee5926a14aab7a20ea4de9d51080b2b3fea..d5735a2097e18f5c94fa0695fde6ff7a4ffda823 100644+index 96289d8ae2e4feb60a91fab3f5cf1fc27b9e7c87..8c0b62c44a18571d1f3ea1ed81d59a0aae28d3f1 100644--- a/Source/WebCore/platform/network/curl/NetworkStorageSessionCurl.cpp+++ b/Source/WebCore/platform/network/curl/NetworkStorageSessionCurl.cpp-@@ -135,6 +135,12 @@ void NetworkStorageSession::setCookieAcceptPolicy(CookieAcceptPolicy policy) con+@@ -136,6 +136,12 @@ void NetworkStorageSession::setCookieAcceptPolicy(CookieAcceptPolicy policy) concookieDatabase().setAcceptPolicy(policy);}@@ -8160,10 +8088,10 @@ index b422dee5926a14aab7a20ea4de9d51080b2b3fea..d5735a2097e18f5c94fa0695fde6ff7a{switch (cookieDatabase().acceptPolicy()) {diff --git a/Source/WebCore/platform/network/soup/NetworkStorageSessionSoup.cpp b/Source/WebCore/platform/network/soup/NetworkStorageSessionSoup.cpp-index c191cdc193019db8efc2c597bb3c87b3a318bcd6..35ad719201c4505c43c20701dffce0adcfb241f6 100644+index 8750fc6d3ad81889da3d60685fc9a107bf4760c1..7a35cf7516b837084fafbfceae84147ab17bd161 100644--- a/Source/WebCore/platform/network/soup/NetworkStorageSessionSoup.cpp+++ b/Source/WebCore/platform/network/soup/NetworkStorageSessionSoup.cpp-@@ -528,6 +528,26 @@ void NetworkStorageSession::replaceCookies(const Vector<Cookie>& cookies)+@@ -551,6 +551,26 @@ void NetworkStorageSession::replaceCookies(const Vector<Cookie>& cookies)g_signal_emit(jar, signalId, 0, nullptr, nullptr);}@@ -8254,6 +8182,69 @@ index 0379437d84807e4a8d3846afac5ec8a70e743e70..5b0461bf12535d4900ffaddc2a878262{if (!m_dragDataMap.isEmpty() || !m_platformDragData)return m_dragDataMap;+diff --git a/Source/WebCore/platform/win/DragImageWin.cpp b/Source/WebCore/platform/win/DragImageWin.cpp+index dd24e15115aeff41f0f4452a9cac292d75bc0d5d..8df467c008bdb3de59d301b14c1c20b8bb0b6a41 100644+--- a/Source/WebCore/platform/win/DragImageWin.cpp++++ b/Source/WebCore/platform/win/DragImageWin.cpp+@@ -62,16 +62,22 @@ IntSize dragImageSize(DragImageRef image)+ {+ if (!image)+ return IntSize();+- BITMAP b;+- GetObject(image, sizeof(BITMAP), &b);+- return IntSize(b.bmWidth, b.bmHeight);++ return { image->width(), image->height() };+ }+++#if USE(CAIRO)+ void deleteDragImage(DragImageRef image)+ {+ if (image)+ ::DeleteObject(image);+ }++#else++void deleteDragImage(DragImageRef)++{++ // Since this is a RefPtr, there's nothing additional we need to do to++ // delete it. It will be released when it falls out of scope.++}++#endif++ DragImageRef dissolveDragImageToFraction(DragImageRef image, float)+ {+@@ -79,8 +85,9 @@ DragImageRef dissolveDragImageToFraction(DragImageRef image, float)+ return image;+ }++-DragImageRef createDragImageIconForCachedImageFilename(const String& filename)++DragImageRef createDragImageIconForCachedImageFilename(const String&)+ {++#if USE(CAIRO)+ SHFILEINFO shfi { };+ auto fname = filename.wideCharacters();+ if (FAILED(SHGetFileInfo(fname.data(), FILE_ATTRIBUTE_NORMAL, &shfi, sizeof(shfi), SHGFI_ICON | SHGFI_USEFILEATTRIBUTES)))+@@ -96,6 +103,9 @@ DragImageRef createDragImageIconForCachedImageFilename(const String& filename)+ DeleteObject(iconInfo.hbmMask);++ return iconInfo.hbmColor;++#else++ return nullptr;++#endif+ }++ #if USE(CAIRO)+@@ -221,9 +231,9 @@ DragImageRef createDragImageForColor(const Color&, const FloatRect&, float, Path+ }++ #if USE(SKIA)+-DragImageRef createDragImageFromImage(Image*, ImageOrientation, GraphicsClient*, float)++DragImageRef createDragImageFromImage(Image* image, ImageOrientation, GraphicsClient*, float)+ {+- return nullptr;++ return image->currentNativeImage()->platformImage();+ }++ DragImageRef scaleDragImage(DragImageRef, FloatSize)diff --git a/Source/WebCore/platform/win/KeyEventWin.cpp b/Source/WebCore/platform/win/KeyEventWin.cppindex d450bf9d0fd1f0bf8f28db483ac9d3d60fa9d114..72a59403a0b5493aea4a8e28eb15eac24b652b09 100644--- a/Source/WebCore/platform/win/KeyEventWin.cpp@@ -8507,25 +8498,6 @@ index 0000000000000000000000000000000000000000..5a20bfaacd42d27bee5f843483d6b60d+}++}-diff --git a/Source/WebCore/platform/wpe/PlatformScreenWPE.cpp b/Source/WebCore/platform/wpe/PlatformScreenWPE.cpp-index 77bdff686770e56f5445fa12216c6bff93bb5cfb..e16583ea6298864df9c8b82cb0686b2afb18ce95 100644---- a/Source/WebCore/platform/wpe/PlatformScreenWPE.cpp-+++ b/Source/WebCore/platform/wpe/PlatformScreenWPE.cpp-@@ -151,12 +151,12 @@ bool screenSupportsExtendedColor(Widget*)- }-- #if ENABLE(TOUCH_EVENTS)--bool screenHasTouchDevice()-+bool platformScreenHasTouchDevice()- {- return true;- }---bool screenIsTouchPrimaryInputDevice()-+bool platformScreenIsTouchPrimaryInputDevice()- {- return true;- }diff --git a/Source/WebCore/platform/wpe/SelectionData.cpp b/Source/WebCore/platform/wpe/SelectionData.cppnew file mode 100644index 0000000000000000000000000000000000000000..947bfe6576780038ecb87ea9bda116adb19dfd71@@ -8832,10 +8804,10 @@ index db95c8273bd0deb3f903a45d02fc07bbbd8ab305..bf88228b4c838b90d11d430cc9429d51WorkerOrWorkletGlobalScope& m_globalScope;};diff --git a/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.cpp b/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.cpp-index e185fc809df730737ff85c349ad17dce10d246f0..b1ccbc16b185ac76ecffb753b6aed2ae1eb8e39a 100644+index eb1ee28ea9a6bee86f68b4d0d4e16ae6dea32772..1968c70c80c1529ada0e76f1a5f45981924fa629 100644--- a/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.cpp+++ b/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.cpp-@@ -96,6 +96,8 @@+@@ -97,6 +97,8 @@#if PLATFORM(COCOA)#include <wtf/OSObjectPtr.h>@@ -8844,7 +8816,7 @@ index e185fc809df730737ff85c349ad17dce10d246f0..b1ccbc16b185ac76ecffb753b6aed2ae#endif#if ENABLE(APPLE_PAY_REMOTE_UI)-@@ -1232,6 +1234,14 @@ void NetworkConnectionToWebProcess::clearPageSpecificData(PageIdentifier pageID)+@@ -1231,6 +1233,14 @@ void NetworkConnectionToWebProcess::clearPageSpecificData(PageIdentifier pageID)storageSession->clearPageSpecificDataForResourceLoadStatistics(pageID);}@@ -8860,10 +8832,10 @@ index e185fc809df730737ff85c349ad17dce10d246f0..b1ccbc16b185ac76ecffb753b6aed2ae{if (auto* storageSession = protectedNetworkProcess()->storageSession(m_sessionID))diff --git a/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.h b/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.h-index 706ceb9edc7de45d731db75c656a7a9ad5780cbe..49a6735a5936a8b6daab556a7df89b254157e14f 100644+index 3f1539237c6c8d1cd832cd3ece2ba20939e01a41..1259c36e38d46c0ebfdf98be20f217433f831ca5 100644--- a/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.h+++ b/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.h-@@ -380,6 +380,8 @@ private:+@@ -388,6 +388,8 @@ private:void clearPageSpecificData(WebCore::PageIdentifier);@@ -8873,7 +8845,7 @@ index 706ceb9edc7de45d731db75c656a7a9ad5780cbe..49a6735a5936a8b6daab556a7df89b25void logUserInteraction(RegistrableDomain&&);diff --git a/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.messages.in b/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.messages.in-index a8f2e3cd5cef58c0e390a9cc8c3d18c9d24ffbda..fdbc166682cd3ec9fdbba737757331e46fd93364 100644+index b10706aafd037a2b92a68b0d2c474ec2e42cd2fe..f80792c02d880dbd61849233fdbc348f1eeffb33 100644--- a/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.messages.in+++ b/Source/WebKit/NetworkProcess/NetworkConnectionToWebProcess.messages.in@@ -80,6 +80,8 @@ messages -> NetworkConnectionToWebProcess WantsDispatchMessage {@@ -8886,10 +8858,10 @@ index a8f2e3cd5cef58c0e390a9cc8c3d18c9d24ffbda..fdbc166682cd3ec9fdbba737757331e4LogUserInteraction(WebCore::RegistrableDomain domain)ResourceLoadStatisticsUpdated(Vector<WebCore::ResourceLoadStatistics> statistics) -> ()diff --git a/Source/WebKit/NetworkProcess/NetworkProcess.cpp b/Source/WebKit/NetworkProcess/NetworkProcess.cpp-index 40718b455299eb28978d999d2088579564b06fd4..9ada150a661beda8b4411c5b6e669c72e0895a75 100644+index be181729d818871958a51ad54b95424be796cbd1..759be2137d58cfbc088e1e459fdfca5d329c3ff4 100644--- a/Source/WebKit/NetworkProcess/NetworkProcess.cpp+++ b/Source/WebKit/NetworkProcess/NetworkProcess.cpp-@@ -653,6 +653,12 @@ void NetworkProcess::registrableDomainsExemptFromWebsiteDataDeletion(PAL::Sessio+@@ -670,6 +670,12 @@ void NetworkProcess::registrableDomainsExemptFromWebsiteDataDeletion(PAL::SessiocompletionHandler({ });}@@ -8903,7 +8875,7 @@ index 40718b455299eb28978d999d2088579564b06fd4..9ada150a661beda8b4411c5b6e669c72{if (auto* session = networkSession(sessionID)) {diff --git a/Source/WebKit/NetworkProcess/NetworkProcess.h b/Source/WebKit/NetworkProcess/NetworkProcess.h-index c6b478b2564a0fb550118e43a9749101c2aa7361..2a45c0dc4e3947b84ed1da124c02ccfff7834cbb 100644+index aad6d1ad7d9735935f7d55d56ae8f3e8d0c5b852..a7421b51a4e8bbf9c695d2aca3ec6cfc98d14bf5 100644--- a/Source/WebKit/NetworkProcess/NetworkProcess.h+++ b/Source/WebKit/NetworkProcess/NetworkProcess.h@@ -84,6 +84,7 @@ class SessionID;@@ -8914,7 +8886,7 @@ index c6b478b2564a0fb550118e43a9749101c2aa7361..2a45c0dc4e3947b84ed1da124c02ccffclass CurlProxySettings;class ProtectionSpace;class NetworkStorageSession;-@@ -234,6 +235,9 @@ public:+@@ -235,6 +236,9 @@ public:void registrableDomainsWithLastAccessedTime(PAL::SessionID, CompletionHandler<void(std::optional<HashMap<RegistrableDomain, WallTime>>)>&&);void registrableDomainsExemptFromWebsiteDataDeletion(PAL::SessionID, CompletionHandler<void(HashSet<RegistrableDomain>)>&&);@@ -8925,10 +8897,10 @@ index c6b478b2564a0fb550118e43a9749101c2aa7361..2a45c0dc4e3947b84ed1da124c02ccffvoid clearUserInteraction(PAL::SessionID, RegistrableDomain&&, CompletionHandler<void()>&&);void deleteAndRestrictWebsiteDataForRegistrableDomains(PAL::SessionID, OptionSet<WebsiteDataType>, RegistrableDomainsToDeleteOrRestrictWebsiteDataFor&&, CompletionHandler<void(HashSet<RegistrableDomain>&&)>&&);diff --git a/Source/WebKit/NetworkProcess/NetworkProcess.messages.in b/Source/WebKit/NetworkProcess/NetworkProcess.messages.in-index 24124fdb6ad7f5447345764a8481342557ceba8e..204e00738921f21e70af8398a9350cd49a4640ce 100644+index 64312176007bfc3c06ae2d624dbbabc4007e0fdf..8dfd79c77f27f13aa23927c9b2c6610cd40885d5 100644--- a/Source/WebKit/NetworkProcess/NetworkProcess.messages.in+++ b/Source/WebKit/NetworkProcess/NetworkProcess.messages.in-@@ -90,6 +90,8 @@ messages -> NetworkProcess : AuxiliaryProcess WantsAsyncDispatchMessage {+@@ -91,6 +91,8 @@ messages -> NetworkProcess : AuxiliaryProcess WantsAsyncDispatchMessage {SetInspectionForServiceWorkersAllowed(PAL::SessionID sessionID, bool inspectable)@@ -8938,7 +8910,7 @@ index 24124fdb6ad7f5447345764a8481342557ceba8e..204e00738921f21e70af8398a9350cd4ClearUserInteraction(PAL::SessionID sessionID, WebCore::RegistrableDomain resourceDomain) -> ()DumpResourceLoadStatistics(PAL::SessionID sessionID) -> (String dumpedStatistics)diff --git a/Source/WebKit/NetworkProcess/NetworkSession.h b/Source/WebKit/NetworkProcess/NetworkSession.h-index 679cf1fc291f262f90d42f5d597361c67eb0f4c0..527015014b15f9efca45dd054f541b4be416eafe 100644+index 2a48fae7bd8cce5ee360df66e5bc49cb4d2b9c54..5fdec3ff3fb706a426717c95831ece36c43543ce 100644--- a/Source/WebKit/NetworkProcess/NetworkSession.h+++ b/Source/WebKit/NetworkProcess/NetworkSession.h@@ -207,6 +207,9 @@ public:@@ -8951,7 +8923,7 @@ index 679cf1fc291f262f90d42f5d597361c67eb0f4c0..527015014b15f9efca45dd054f541b4bvoid removeSoftUpdateLoader(ServiceWorkerSoftUpdateLoader* loader) { m_softUpdateLoaders.remove(loader); }void addNavigationPreloaderTask(ServiceWorkerFetchTask&);ServiceWorkerFetchTask* navigationPreloaderTaskFromFetchIdentifier(WebCore::FetchIdentifier);-@@ -343,6 +346,7 @@ protected:+@@ -345,6 +348,7 @@ protected:bool m_privateClickMeasurementDebugModeEnabled { false };std::optional<WebCore::PrivateClickMeasurement> m_ephemeralMeasurement;bool m_isRunningEphemeralMeasurementTest { false };@@ -8960,7 +8932,7 @@ index 679cf1fc291f262f90d42f5d597361c67eb0f4c0..527015014b15f9efca45dd054f541b4bHashSet<Ref<NetworkResourceLoader>> m_keptAliveLoads;diff --git a/Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm b/Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm-index 0d2fcd76b91d7f9afa8c2378ab1109f12386a6c2..ff01afba3686fd8f81e1ad914f0171d3fd40e0fb 100644+index 846603d498fa5f0cfe8829340ed810558df54b41..6edf57edc6d0c2d7ba79319ddb2765b856a8cddc 100644--- a/Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm+++ b/Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm@@ -805,6 +805,8 @@ - (void)URLSession:(NSURLSession *)session task:(NSURLSessionTask *)task didRece@@ -8972,9 +8944,9 @@ index 0d2fcd76b91d7f9afa8c2378ab1109f12386a6c2..ff01afba3686fd8f81e1ad914f0171d3negotiatedLegacyTLS = checkForLegacyTLS(task._incompleteTaskMetrics.transactionMetrics.lastObject);if (negotiatedLegacyTLS == NegotiatedLegacyTLS::Yes && task._preconnect)-@@ -1146,6 +1148,14 @@ - (void)URLSession:(NSURLSession *)session dataTask:(NSURLSessionDataTask *)data+@@ -1148,6 +1150,14 @@ - (void)URLSession:(NSURLSession *)session dataTask:(NSURLSessionDataTask *)data- resourceResponse.setDeprecatedNetworkLoadMetrics(WebCore::copyTimingData(taskMetrics, networkDataTask->networkLoadMetrics()));+ resourceResponse.setDeprecatedNetworkLoadMetrics(WebCore::copyTimingData(taskMetrics.get(), networkDataTask->networkLoadMetrics()));resourceResponse.setProxyName(WTFMove(proxyName));++ __block WebCore::HTTPHeaderMap requestHeaders;@@ -8986,9 +8958,9 @@ index 0d2fcd76b91d7f9afa8c2378ab1109f12386a6c2..ff01afba3686fd8f81e1ad914f0171d3+networkDataTask->didReceiveResponse(WTFMove(resourceResponse), negotiatedLegacyTLS, privateRelayed, [completionHandler = makeBlockPtr(completionHandler), taskIdentifier](WebCore::PolicyAction policyAction) {#if !LOG_DISABLED- LOG(NetworkSession, "%llu didReceiveResponse completionHandler (%d)", taskIdentifier, policyAction);+ LOG(NetworkSession, "%llu didReceiveResponse completionHandler (%s)", taskIdentifier, toString(policyAction).characters());diff --git a/Source/WebKit/NetworkProcess/curl/NetworkDataTaskCurl.cpp b/Source/WebKit/NetworkProcess/curl/NetworkDataTaskCurl.cpp-index 50cd0b45a2fa5be6f217b686b2ff703b74c06078..c2d6b10762def97a222197d1e6f45d31d3b7a49b 100644+index 1aa46419c05ba688a2ca79bfa48f4c7a9164375e..9b90036b16c587cd509bb35f067c9a9fddd8cfc2 100644--- a/Source/WebKit/NetworkProcess/curl/NetworkDataTaskCurl.cpp+++ b/Source/WebKit/NetworkProcess/curl/NetworkDataTaskCurl.cpp@@ -80,10 +80,18 @@ NetworkDataTaskCurl::NetworkDataTaskCurl(NetworkSession& session, NetworkDataTas@@ -9022,7 +8994,7 @@ index 50cd0b45a2fa5be6f217b686b2ff703b74c06078..c2d6b10762def97a222197d1e6f45d31handleCookieHeaders(request.resourceRequest(), receivedResponse);-@@ -294,6 +303,36 @@ bool NetworkDataTaskCurl::shouldRedirectAsGET(const ResourceRequest& request, bo+@@ -293,6 +302,35 @@ bool NetworkDataTaskCurl::shouldRedirectAsGET(const ResourceRequest& request, boreturn false;}@@ -9044,22 +9016,21 @@ index 50cd0b45a2fa5be6f217b686b2ff703b74c06078..c2d6b10762def97a222197d1e6f45d31+ return;+ }+-+ if (-1 == FileSystem::writeToFile(m_downloadDestinationFile, std::span<const uint8_t>(m_dataURLResult.value().data.data(), m_dataURLResult.value().data.size()))) {++ if (!m_downloadDestinationFile.write(std::span<const uint8_t>(m_dataURLResult.value().data.data(), m_dataURLResult.value().data.size()))) {+ deleteDownloadFile();+ download.didFail(ResourceError(CURLE_WRITE_ERROR, m_response.url()), std::span<const uint8_t>());+ return;+ }++ download.didReceiveData(m_dataURLResult.value().data.size(), 0, 0);-+ FileSystem::closeFile(m_downloadDestinationFile);-+ m_downloadDestinationFile = FileSystem::invalidPlatformFileHandle;++ m_downloadDestinationFile = { };+ download.didFinish();+}+void NetworkDataTaskCurl::invokeDidReceiveResponse(){didReceiveResponse(ResourceResponse(m_response), NegotiatedLegacyTLS::No, PrivateRelayed::No, std::nullopt, [this, protectedThis = Ref { *this }](PolicyAction policyAction) {-@@ -323,6 +362,8 @@ void NetworkDataTaskCurl::invokeDidReceiveResponse()+@@ -322,6 +360,8 @@ void NetworkDataTaskCurl::invokeDidReceiveResponse()download->didCreateDestination(m_pendingDownloadLocation);if (m_curlRequest)m_curlRequest->completeDidReceiveResponse();@@ -9068,7 +9039,7 @@ index 50cd0b45a2fa5be6f217b686b2ff703b74c06078..c2d6b10762def97a222197d1e6f45d31break;}default:-@@ -411,6 +452,8 @@ void NetworkDataTaskCurl::willPerformHTTPRedirection()+@@ -410,6 +450,8 @@ void NetworkDataTaskCurl::willPerformHTTPRedirection()m_curlRequest->setUserPass(m_initialCredential.user(), m_initialCredential.password());m_curlRequest->setAuthenticationScheme(ProtectionSpace::AuthenticationScheme::HTTPBasic);}@@ -9078,7 +9049,7 @@ index 50cd0b45a2fa5be6f217b686b2ff703b74c06078..c2d6b10762def97a222197d1e6f45d31if (m_state != State::Suspended) {m_state = State::Suspended;diff --git a/Source/WebKit/NetworkProcess/curl/NetworkDataTaskCurl.h b/Source/WebKit/NetworkProcess/curl/NetworkDataTaskCurl.h-index fc4d15308fcb12b084a65d058aec9e67fcf6021f..b1a689989c68798e6308b1da7b3bd7c066497114 100644+index 7babe41b8351f8adbffcf194310d4df41637b192..2d6f0055cfcb0ec8a4629ce41b19cecd17ab4fdc 100644--- a/Source/WebKit/NetworkProcess/curl/NetworkDataTaskCurl.h+++ b/Source/WebKit/NetworkProcess/curl/NetworkDataTaskCurl.h@@ -28,6 +28,7 @@@@ -9115,7 +9086,7 @@ index fc4d15308fcb12b084a65d058aec9e67fcf6021f..b1a689989c68798e6308b1da7b3bd7c0++ std::optional<WebCore::DataURLDecoder::Result> m_dataURLResult;+- FileSystem::PlatformFileHandle m_downloadDestinationFile { FileSystem::invalidPlatformFileHandle };+ FileSystem::FileHandle m_downloadDestinationFile;bool m_blockingCookies { false };diff --git a/Source/WebKit/NetworkProcess/curl/NetworkSessionCurl.cpp b/Source/WebKit/NetworkProcess/curl/NetworkSessionCurl.cpp@@ -9189,7 +9160,7 @@ index 0ef9f38c7662f922b7a8e4da81613799b0fddc68..45704b96df02cead2f21fd9484555027WebCore::CurlStreamScheduler& m_scheduler;diff --git a/Source/WebKit/NetworkProcess/mac/com.apple.WebKit.NetworkProcess.sb.in b/Source/WebKit/NetworkProcess/mac/com.apple.WebKit.NetworkProcess.sb.in-index a6d86f1388e8cae7c3939d1ecffb2c46eb5054c5..9e11224335211908fe8bf14edc4c22e9e4934582 100644+index 9ecb3e28299aa54a8ac309e74afb6944833e8eae..383bdd7533fad2fd58b4d0cceee4e68962aa8455 100644--- a/Source/WebKit/NetworkProcess/mac/com.apple.WebKit.NetworkProcess.sb.in+++ b/Source/WebKit/NetworkProcess/mac/com.apple.WebKit.NetworkProcess.sb.in@@ -451,9 +451,11 @@@@ -9269,10 +9240,10 @@ index c0c9bf6f4f1879efb8dfdd24951ef67ae373fa2f..48aeb8ac1324a58dc59bdb125c8ec4e3}diff --git a/Source/WebKit/PlatformGTK.cmake b/Source/WebKit/PlatformGTK.cmake-index 2f33b1c02a7d0e352a5662c19b44cfa7a161b8f5..263d65ba51319116f161db5918439c081cde43fd 100644+index 2990740be0d39d16ebbc625639c57200cdd700a8..78d25fe109ac96343d4aeedbc1e6b0087b34299a 100644--- a/Source/WebKit/PlatformGTK.cmake+++ b/Source/WebKit/PlatformGTK.cmake-@@ -320,6 +320,9 @@ list(APPEND WebKit_SYSTEM_INCLUDE_DIRECTORIES+@@ -321,6 +321,9 @@ list(APPEND WebKit_SYSTEM_INCLUDE_DIRECTORIES${GSTREAMER_PBUTILS_INCLUDE_DIRS}${GTK_INCLUDE_DIRS}${LIBSOUP_INCLUDE_DIRS}@@ -9282,7 +9253,7 @@ index 2f33b1c02a7d0e352a5662c19b44cfa7a161b8f5..263d65ba51319116f161db5918439c08)list(APPEND WebKit_INTERFACE_INCLUDE_DIRECTORIES-@@ -356,6 +359,9 @@ if (USE_LIBWEBRTC)+@@ -360,6 +363,9 @@ if (USE_LIBWEBRTC)list(APPEND WebKit_SYSTEM_INCLUDE_DIRECTORIES"${THIRDPARTY_DIR}/libwebrtc/Source/""${THIRDPARTY_DIR}/libwebrtc/Source/webrtc"@@ -9292,7 +9263,7 @@ index 2f33b1c02a7d0e352a5662c19b44cfa7a161b8f5..263d65ba51319116f161db5918439c08)endif ()-@@ -407,6 +413,12 @@ else ()+@@ -411,6 +417,12 @@ else ()set(WebKitGTK_ENUM_HEADER_TEMPLATE ${WEBKIT_DIR}/UIProcess/API/gtk/WebKitEnumTypesGtk3.h.in)endif ()@@ -9306,10 +9277,10 @@ index 2f33b1c02a7d0e352a5662c19b44cfa7a161b8f5..263d65ba51319116f161db5918439c08set(WebKitGTK_ENUM_GENERATION_HEADERS ${WebKitGTK_INSTALLED_HEADERS})list(REMOVE_ITEM WebKitGTK_ENUM_GENERATION_HEADERS ${WebKitGTK_DERIVED_SOURCES_DIR}/webkit/WebKitEnumTypes.h)diff --git a/Source/WebKit/PlatformWPE.cmake b/Source/WebKit/PlatformWPE.cmake-index 8376382ba17ea308210e2a46a60a90a2da2d013c..7935f07612a7ce44cae17e4a8650dcee36ceb49b 100644+index d55e9837af868c774cadcd6791ec07ccee1a97a0..649c0668818d6f2d70036bb18ff108060318d0fb 100644--- a/Source/WebKit/PlatformWPE.cmake+++ b/Source/WebKit/PlatformWPE.cmake-@@ -114,6 +114,8 @@ list(APPEND WebKit_SERIALIZATION_IN_FILES+@@ -121,6 +121,8 @@ list(APPEND WebKit_SERIALIZATION_IN_FILESShared/glib/UserMessage.serialization.inShared/soup/WebCoreArgumentCodersSoup.serialization.in@@ -9318,7 +9289,7 @@ index 8376382ba17ea308210e2a46a60a90a2da2d013c..7935f07612a7ce44cae17e4a8650dcee)list(APPEND WebKit_DERIVED_SOURCES-@@ -213,6 +215,7 @@ set(WPE_API_HEADER_TEMPLATES+@@ -220,6 +222,7 @@ set(WPE_API_HEADER_TEMPLATES${WEBKIT_DIR}/UIProcess/API/glib/WebKitWindowProperties.h.in${WEBKIT_DIR}/UIProcess/API/glib/WebKitWebsitePolicies.h.in${WEBKIT_DIR}/UIProcess/API/glib/webkit.h.in@@ -9326,7 +9297,7 @@ index 8376382ba17ea308210e2a46a60a90a2da2d013c..7935f07612a7ce44cae17e4a8650dcee)if (ENABLE_2022_GLIB_API)-@@ -423,7 +426,16 @@ list(APPEND WebKit_SYSTEM_INCLUDE_DIRECTORIES+@@ -430,7 +433,16 @@ list(APPEND WebKit_SYSTEM_INCLUDE_DIRECTORIES${GIO_UNIX_INCLUDE_DIRS}${GLIB_INCLUDE_DIRS}${LIBSOUP_INCLUDE_DIRS}@@ -9344,13 +9315,13 @@ index 8376382ba17ea308210e2a46a60a90a2da2d013c..7935f07612a7ce44cae17e4a8650dceelist(APPEND WebKit_LIBRARIESWPE::libwpediff --git a/Source/WebKit/PlatformWin.cmake b/Source/WebKit/PlatformWin.cmake-index e0e9b52c43ee0742f705159c1369f2938b9c4956..05fa7d93a721f200143e9d3ac45a75ce942afc88 100644+index 8429fc8b2e3721830edf197b3369f4f21bb70a9a..bb6779326529bfe16f47dd1b941f4e3d364cb4df 100644--- a/Source/WebKit/PlatformWin.cmake+++ b/Source/WebKit/PlatformWin.cmake@@ -54,8 +54,13 @@ list(APPEND WebKit_SOURCES- UIProcess/WebsiteData/win/WebsiteDataStoreWin.cppUIProcess/win/AutomationClientWin.cpp+ UIProcess/win/AutomationSessionClientWin.cpp++ UIProcess/win/InspectorTargetProxyWin.cpp+ UIProcess/win/InspectorPlaywrightAgentClientWin.cpp@@ -9369,7 +9340,7 @@ index e0e9b52c43ee0742f705159c1369f2938b9c4956..05fa7d93a721f200143e9d3ac45a75ceWebProcess/WebPage/AcceleratedSurface.cpp-@@ -120,8 +126,81 @@ list(APPEND WebKit_PUBLIC_FRAMEWORK_HEADERS+@@ -119,8 +125,81 @@ list(APPEND WebKit_PUBLIC_FRAMEWORK_HEADERSlist(APPEND WebKit_PRIVATE_LIBRARIEScomctl32@@ -9452,10 +9423,10 @@ index e0e9b52c43ee0742f705159c1369f2938b9c4956..05fa7d93a721f200143e9d3ac45a75ceWebProcess/EntryPoint/win/WebProcessMain.cppdiff --git a/Source/WebKit/Shared/AuxiliaryProcess.h b/Source/WebKit/Shared/AuxiliaryProcess.h-index 4510beb0b7403138abef4c9b5e892271fe8beaab..dae8f31ef187d7b086dd84d7e356839dc2811154 100644+index c36aaf218982ee54d433b023485ac36e7c45cb2b..1f07f8ebad02fd11a4d23a69ec5092122df73aa0 100644--- a/Source/WebKit/Shared/AuxiliaryProcess.h+++ b/Source/WebKit/Shared/AuxiliaryProcess.h-@@ -212,6 +212,11 @@ struct AuxiliaryProcessInitializationParameters {+@@ -216,6 +216,11 @@ struct AuxiliaryProcessInitializationParameters {IPC::Connection::Identifier connectionIdentifier;HashMap<String, String> extraInitializationData;WTF::AuxiliaryProcessType processType;@@ -9563,10 +9534,10 @@ index ea1eb9f00feaaecf73bdddc37c904e88f43bfa85..8a631e5293a11abd650958baad4e9678#endif};diff --git a/Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in b/Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in-index db25c4a2dbb7fd8f9e0885757655eed1ebf64d35..1c21752b0f3710d7dfb0c70421c17de740274439 100644+index c0ba2034b3d6a9fd9d807f1d67a62284c311c3dc..d688da2d022ded01cf9828fd6d56d0570fcc5735 100644--- a/Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in+++ b/Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in-@@ -2814,6 +2814,9 @@ class WebCore::AuthenticationChallenge {+@@ -2826,6 +2826,9 @@ class WebCore::AuthenticationChallenge {class WebCore::DragData {#if PLATFORM(COCOA)String pasteboardName();@@ -9576,7 +9547,7 @@ index db25c4a2dbb7fd8f9e0885757655eed1ebf64d35..1c21752b0f3710d7dfb0c70421c17de7#endifWebCore::IntPoint clientPosition();WebCore::IntPoint globalPosition();-@@ -3621,6 +3624,7 @@ enum class WebCore::WasPrivateRelayed : bool;+@@ -3624,6 +3627,7 @@ enum class WebCore::WasPrivateRelayed : bool;String httpStatusText;String httpVersion;WebCore::HTTPHeaderMap httpHeaderFields;@@ -9690,7 +9661,7 @@ index 8e4e2d6d5ebb08fba210fe0a328d45290348dd11..32a43192ec1e918c33b1b046b71d2ec5const String& text() const { return m_text; }diff --git a/Source/WebKit/Shared/WebMouseEvent.h b/Source/WebKit/Shared/WebMouseEvent.h-index fd4722dd38df74f259d8add02025549022a0a205..e1c33f6d766707170935b3e77e81098cc8e3786d 100644+index 20a6e465457151b02daa22e6bc059cf0e117ece5..ef4b1f737aaa683bc13c447aa4ca77e5cf0d64d7 100644--- a/Source/WebKit/Shared/WebMouseEvent.h+++ b/Source/WebKit/Shared/WebMouseEvent.h@@ -70,6 +70,7 @@ public:@@ -9702,10 +9673,10 @@ index fd4722dd38df74f259d8add02025549022a0a205..e1c33f6d766707170935b3e77e81098cvoid setPosition(const WebCore::IntPoint& position) { m_position = position; }const WebCore::IntPoint& globalPosition() const { return m_globalPosition; }diff --git a/Source/WebKit/Shared/WebPageCreationParameters.h b/Source/WebKit/Shared/WebPageCreationParameters.h-index 95aa13fdc5bd9d5ece8f3ff4279c0ebe03f3cdef..bde8a24fcce390b859f6241c9816eb6430376d6b 100644+index 40b760ec89270bb9a8c586d05cab205c8bd9e7cf..db59f464cc96f9db4800034509e048a1f4d237ac 100644--- a/Source/WebKit/Shared/WebPageCreationParameters.h+++ b/Source/WebKit/Shared/WebPageCreationParameters.h-@@ -309,6 +309,8 @@ struct WebPageCreationParameters {+@@ -301,6 +301,8 @@ struct WebPageCreationParameters {WebCore::ShouldRelaxThirdPartyCookieBlocking shouldRelaxThirdPartyCookieBlocking { WebCore::ShouldRelaxThirdPartyCookieBlocking::No };bool httpsUpgradeEnabled { true };@@ -9715,10 +9686,10 @@ index 95aa13fdc5bd9d5ece8f3ff4279c0ebe03f3cdef..bde8a24fcce390b859f6241c9816eb64#if ENABLE(APP_HIGHLIGHTS)WebCore::HighlightVisibility appHighlightsVisible { WebCore::HighlightVisibility::Hidden };diff --git a/Source/WebKit/Shared/WebPageCreationParameters.serialization.in b/Source/WebKit/Shared/WebPageCreationParameters.serialization.in-index 0c9594c44a6f1962642835b221b1c27d15cc33d7..b6898b100be0fe64aba87305711846f066bf9459 100644+index d137231cfb0f9d9632e788f8e08968ad514f2227..6647f08415b1f0b213e4162ca93697e39280c888 100644--- a/Source/WebKit/Shared/WebPageCreationParameters.serialization.in+++ b/Source/WebKit/Shared/WebPageCreationParameters.serialization.in-@@ -229,6 +229,8 @@ enum class WebCore::UserInterfaceLayoutDirection : bool;+@@ -223,6 +223,8 @@ enum class WebCore::UserInterfaceLayoutDirection : bool;bool httpsUpgradeEnabled;@@ -9728,7 +9699,7 @@ index 0c9594c44a6f1962642835b221b1c27d15cc33d7..b6898b100be0fe64aba87305711846f0WebCore::HighlightVisibility appHighlightsVisible;#endifdiff --git a/Source/WebKit/Shared/glib/ProcessExecutablePathGLib.cpp b/Source/WebKit/Shared/glib/ProcessExecutablePathGLib.cpp-index 40d482a1860598391363027e63b010b3ce32b014..e654ae5e7c54b788badd463b1f2b653160d0370e 100644+index 9899d60864664d1abff2b71c1c01e564e5dfb08c..391e0e42ca6a39f82b5a12c6aede069d61095ee2 100644--- a/Source/WebKit/Shared/glib/ProcessExecutablePathGLib.cpp+++ b/Source/WebKit/Shared/glib/ProcessExecutablePathGLib.cpp@@ -32,7 +32,7 @@@@ -9865,24 +9836,11 @@ index 053e9336017d8818b3cbea79ce7c145fd5c46274..5632498d6ef875df80fc68ec206a9d08else if (!strcmp(argv[i], "-configure-jsc-for-testing"))JSC::Config::configureForTesting();else if (!strcmp(argv[i], "-disable-jit"))-diff --git a/Source/WebKit/Shared/win/WebEventFactory.cpp b/Source/WebKit/Shared/win/WebEventFactory.cpp-index 23ec85c142892f8f9bee7d063c3ff0cafe6c53a5..4f0021ad12ded82b7ac958fc6c752410ce2ac764 100644---- a/Source/WebKit/Shared/win/WebEventFactory.cpp-+++ b/Source/WebKit/Shared/win/WebEventFactory.cpp-@@ -484,7 +484,7 @@ WebKeyboardEvent WebEventFactory::createWebKeyboardEvent(HWND hwnd, UINT message- #if ENABLE(TOUCH_EVENTS)- WebTouchEvent WebEventFactory::createWebTouchEvent()- {-- return WebTouchEvent();-+ return WebTouchEvent({ WebEventType::TouchMove, OptionSet<WebEventModifier> { }, WallTime::now()}, { }, { }, { });- }- #endif // ENABLE(TOUCH_EVENTS)-diff --git a/Source/WebKit/Sources.txt b/Source/WebKit/Sources.txt-index 1a8bb4ce0d39f7d03264bb010be3158f3bd87000..34e2d4d603fae0acc8ace9afb8e3ff549e87bf07 100644+index 8580135604e6c41c0d2adc22b37ce50366069788..dcbca0904ab9acff6bfcc5cffd6f821af682ecb5 100644--- a/Source/WebKit/Sources.txt+++ b/Source/WebKit/Sources.txt-@@ -389,6 +389,7 @@ Shared/XR/XRDeviceProxy.cpp+@@ -391,6 +391,7 @@ UIProcess/AboutSchemeHandler.cppUIProcess/AuxiliaryProcessProxy.cppUIProcess/BackgroundProcessResponsivenessTimer.cppUIProcess/BrowsingContextGroup.cpp@@ -9890,7 +9848,7 @@ index 1a8bb4ce0d39f7d03264bb010be3158f3bd87000..34e2d4d603fae0acc8ace9afb8e3ff54UIProcess/DeviceIdHashSaltStorage.cppUIProcess/DisplayLink.cppUIProcess/DisplayLinkProcessProxyClient.cpp-@@ -398,16 +399,20 @@ UIProcess/FrameLoadState.cpp+@@ -400,16 +401,20 @@ UIProcess/FrameLoadState.cppUIProcess/FrameProcess.cppUIProcess/GeolocationPermissionRequestManagerProxy.cppUIProcess/GeolocationPermissionRequestProxy.cpp@@ -9911,7 +9869,7 @@ index 1a8bb4ce0d39f7d03264bb010be3158f3bd87000..34e2d4d603fae0acc8ace9afb8e3ff54UIProcess/RemotePageDrawingAreaProxy.cppUIProcess/RemotePageFullscreenManagerProxy.cppUIProcess/RemotePageProxy.cpp-@@ -450,6 +455,8 @@ UIProcess/WebOpenPanelResultListenerProxy.cpp+@@ -452,6 +457,8 @@ UIProcess/WebOpenPanelResultListenerProxy.cppUIProcess/WebPageDiagnosticLoggingClient.cppUIProcess/WebPageGroup.cppUIProcess/WebPageInjectedBundleClient.cpp@@ -9920,7 +9878,7 @@ index 1a8bb4ce0d39f7d03264bb010be3158f3bd87000..34e2d4d603fae0acc8ace9afb8e3ff54UIProcess/WebPageProxy.cppUIProcess/WebPageProxyMessageReceiverRegistration.cppUIProcess/WebPageProxyTesting.cpp-@@ -596,7 +603,11 @@ UIProcess/Inspector/WebInspectorUtilities.cpp+@@ -598,7 +605,11 @@ UIProcess/Inspector/WebInspectorUtilities.cppUIProcess/Inspector/WebPageDebuggable.cppUIProcess/Inspector/WebPageInspectorController.cpp@@ -9933,10 +9891,10 @@ index 1a8bb4ce0d39f7d03264bb010be3158f3bd87000..34e2d4d603fae0acc8ace9afb8e3ff54UIProcess/Media/AudioSessionRoutingArbitratorProxy.cppUIProcess/Media/MediaUsageManager.cppdiff --git a/Source/WebKit/SourcesCocoa.txt b/Source/WebKit/SourcesCocoa.txt-index 19e2664300bd081ae5124d6b08055c028f04ebb2..5b851c95b75262264dec59503b74c2548b9ee737 100644+index 768e618630ca0090790320007cbcadad8e0d6452..536e02dc95c2adff1be74a1c2116ab8e8e98196c 100644--- a/Source/WebKit/SourcesCocoa.txt+++ b/Source/WebKit/SourcesCocoa.txt-@@ -270,6 +270,7 @@ UIProcess/API/Cocoa/_WKArchiveExclusionRule.mm+@@ -272,6 +272,7 @@ UIProcess/API/Cocoa/_WKArchiveExclusionRule.mmUIProcess/API/Cocoa/_WKAttachment.mmUIProcess/API/Cocoa/_WKAutomationSession.mmUIProcess/API/Cocoa/_WKAutomationSessionConfiguration.mm@@ -9944,7 +9902,7 @@ index 19e2664300bd081ae5124d6b08055c028f04ebb2..5b851c95b75262264dec59503b74c254UIProcess/API/Cocoa/_WKContentRuleListAction.mmUIProcess/API/Cocoa/_WKContextMenuElementInfo.mmUIProcess/API/Cocoa/_WKCustomHeaderFields.mm @no-unify-@@ -467,6 +468,7 @@ UIProcess/Inspector/ios/WKInspectorHighlightView.mm+@@ -468,6 +469,7 @@ UIProcess/Inspector/ios/WKInspectorHighlightView.mmUIProcess/Inspector/ios/WKInspectorNodeSearchGestureRecognizer.mmUIProcess/Inspector/mac/RemoteWebInspectorUIProxyMac.mm@@ -10042,7 +10000,7 @@ index 42931a643d8ff85469b5e162a42e9a09a8bdca3f..f962949675b8de7b79e6d56bb8bb3f34WebProcess/WebPage/AcceleratedSurface.cppdiff --git a/Source/WebKit/UIProcess/API/APIPageConfiguration.cpp b/Source/WebKit/UIProcess/API/APIPageConfiguration.cpp-index 0f27d0e97c1039ad5c95086c0e7eb72f4fe85db1..9ca848d9e0c78bce8b77721debf18deba76f4b2c 100644+index a9d9e1ecd35d4f3b55fa27ff913d054513d423a6..d7f083485598a5b458c09c278a7c0181272d0e93 100644--- a/Source/WebKit/UIProcess/API/APIPageConfiguration.cpp+++ b/Source/WebKit/UIProcess/API/APIPageConfiguration.cpp@@ -275,6 +275,11 @@ WebPageProxy* PageConfiguration::relatedPage() const@@ -10058,7 +10016,7 @@ index 0f27d0e97c1039ad5c95086c0e7eb72f4fe85db1..9ca848d9e0c78bce8b77721debf18deb{return m_data.pageToCloneSessionStorageFrom.get();diff --git a/Source/WebKit/UIProcess/API/APIPageConfiguration.h b/Source/WebKit/UIProcess/API/APIPageConfiguration.h-index ba3fed377d5f2a799fbf7b38a5bc2f03efbe7535..e4c41d0a444d12f80d0402591dfa39e8e68e4fd0 100644+index ceb054aec4899fa74d160c08e1009dba052488e7..e4c817a32510d006b95d0039d9dc763351831978 100644--- a/Source/WebKit/UIProcess/API/APIPageConfiguration.h+++ b/Source/WebKit/UIProcess/API/APIPageConfiguration.h@@ -160,6 +160,10 @@ public:@@ -10096,7 +10054,7 @@ index e256b905bf9727aa7c8a48012237a6a6bc9acdbc..4e855c441af6f235f0fd8dfdd57b9bd6copy->m_shouldTakeUIBackgroundAssertion = this->m_shouldTakeUIBackgroundAssertion;copy->m_shouldCaptureDisplayInUIProcess = this->m_shouldCaptureDisplayInUIProcess;diff --git a/Source/WebKit/UIProcess/API/APIProcessPoolConfiguration.h b/Source/WebKit/UIProcess/API/APIProcessPoolConfiguration.h-index d2e8261c6db000aa41697b3bb50e2bea149edcdf..500c38b81d6804f64ff891e32b2c72ed98c9a629 100644+index af4944e5a5d373bc51995b50d1ea7c70f64ef1b3..403cfdeda26db2b648e32aa0e5f3ef6e076634f6 100644--- a/Source/WebKit/UIProcess/API/APIProcessPoolConfiguration.h+++ b/Source/WebKit/UIProcess/API/APIProcessPoolConfiguration.h@@ -96,6 +96,16 @@ public:@@ -10128,10 +10086,10 @@ index d2e8261c6db000aa41697b3bb50e2bea149edcdf..500c38b81d6804f64ff891e32b2c72edbool m_shouldTakeUIBackgroundAssertion { true };bool m_shouldCaptureDisplayInUIProcess { DEFAULT_CAPTURE_DISPLAY_IN_UI_PROCESS };diff --git a/Source/WebKit/UIProcess/API/APIUIClient.h b/Source/WebKit/UIProcess/API/APIUIClient.h-index fdfb6489e3b5f8b70da8918e72612c74ada771f6..fe58191302f84065523d048463b0b6b2fe71c394 100644+index 4d3564df93fcad126ddd9b3ca851618976cd7571..826aad7a5675b4daf90d83d36a6f352751932f03 100644--- a/Source/WebKit/UIProcess/API/APIUIClient.h+++ b/Source/WebKit/UIProcess/API/APIUIClient.h-@@ -115,6 +115,7 @@ public:+@@ -114,6 +114,7 @@ public:virtual void runJavaScriptAlert(WebKit::WebPageProxy&, const WTF::String&, WebKit::WebFrameProxy*, WebKit::FrameInfoData&&, Function<void()>&& completionHandler) { completionHandler(); }virtual void runJavaScriptConfirm(WebKit::WebPageProxy&, const WTF::String&, WebKit::WebFrameProxy*, WebKit::FrameInfoData&&, Function<void(bool)>&& completionHandler) { completionHandler(false); }virtual void runJavaScriptPrompt(WebKit::WebPageProxy&, const WTF::String&, const WTF::String&, WebKit::WebFrameProxy*, WebKit::FrameInfoData&&, Function<void(const WTF::String&)>&& completionHandler) { completionHandler(WTF::String()); }@@ -10183,11 +10141,11 @@ index 026121d114c5fcad84c1396be8d692625beaa3bd..edd6e5cae033124c589959a42522fde0}#endifdiff --git a/Source/WebKit/UIProcess/API/C/WKPage.cpp b/Source/WebKit/UIProcess/API/C/WKPage.cpp-index 2e9502e5767eb93b7a2d6488a113e69f953f3e4a..56969ab93991ef77dc020e0d3f7b7e4e71324416 100644+index 55aeb95735a56d285d7faeb21e9cec6e4ce6762e..9ecc7e8b24a3550659e62e01e704ea0064a985aa 100644--- a/Source/WebKit/UIProcess/API/C/WKPage.cpp+++ b/Source/WebKit/UIProcess/API/C/WKPage.cpp-@@ -1899,6 +1899,13 @@ void WKPageSetPageUIClient(WKPageRef pageRef, const WKPageUIClientBase* wkClient- completionHandler(String());+@@ -1935,6 +1935,13 @@ void WKPageSetPageUIClient(WKPageRef pageRef, const WKPageUIClientBase* wkClient+ m_client.addMessageToConsole(toAPI(&page), toAPI(message.impl()), m_client.base.clientInfo);}+ void handleJavaScriptDialog(WebPageProxy& page, bool accept, const String& value) final {@@ -10200,7 +10158,7 @@ index 2e9502e5767eb93b7a2d6488a113e69f953f3e4a..56969ab93991ef77dc020e0d3f7b7e4evoid setStatusText(WebPageProxy* page, const String& text) final{if (!m_client.setStatusText)-@@ -1928,6 +1935,8 @@ void WKPageSetPageUIClient(WKPageRef pageRef, const WKPageUIClientBase* wkClient+@@ -1964,6 +1971,8 @@ void WKPageSetPageUIClient(WKPageRef pageRef, const WKPageUIClientBase* wkClient{if (!m_client.didNotHandleKeyEvent)return;@@ -10210,7 +10168,7 @@ index 2e9502e5767eb93b7a2d6488a113e69f953f3e4a..56969ab93991ef77dc020e0d3f7b7e4e}diff --git a/Source/WebKit/UIProcess/API/C/WKPageUIClient.h b/Source/WebKit/UIProcess/API/C/WKPageUIClient.h-index 1484f064ec89ee8c25c35df9f0a4462896699415..0622f4d5fc9144b9059395d9d0730a4ae00b7497 100644+index fc43c44a85a0fc6bf5f8c643bd120a16ce762914..ee86fd213d25682f9b6553ec7da99bc8a812212b 100644--- a/Source/WebKit/UIProcess/API/C/WKPageUIClient.h+++ b/Source/WebKit/UIProcess/API/C/WKPageUIClient.h@@ -98,6 +98,7 @@ typedef void (*WKPageRunBeforeUnloadConfirmPanelCallback)(WKPageRef page, WKStri@@ -10221,7 +10179,7 @@ index 1484f064ec89ee8c25c35df9f0a4462896699415..0622f4d5fc9144b9059395d9d0730a4atypedef void (*WKPageRequestStorageAccessConfirmCallback)(WKPageRef page, WKFrameRef frame, WKStringRef requestingDomain, WKStringRef currentDomain, WKPageRequestStorageAccessConfirmResultListenerRef listener, const void *clientInfo);typedef void (*WKPageTakeFocusCallback)(WKPageRef page, WKFocusDirection direction, const void *clientInfo);typedef void (*WKPageFocusCallback)(WKPageRef page, const void *clientInfo);-@@ -1364,6 +1365,7 @@ typedef struct WKPageUIClientV14 {+@@ -1365,6 +1366,7 @@ typedef struct WKPageUIClientV14 {// Version 14.WKPageRunWebAuthenticationPanelCallback runWebAuthenticationPanel;@@ -10229,7 +10187,7 @@ index 1484f064ec89ee8c25c35df9f0a4462896699415..0622f4d5fc9144b9059395d9d0730a4a} WKPageUIClientV14;typedef struct WKPageUIClientV15 {-@@ -1471,6 +1473,7 @@ typedef struct WKPageUIClientV15 {+@@ -1472,6 +1474,7 @@ typedef struct WKPageUIClientV15 {// Version 14.WKPageRunWebAuthenticationPanelCallback runWebAuthenticationPanel;@@ -10237,7 +10195,7 @@ index 1484f064ec89ee8c25c35df9f0a4462896699415..0622f4d5fc9144b9059395d9d0730a4a// Version 15.WKPageDecidePolicyForSpeechRecognitionPermissionRequestCallback decidePolicyForSpeechRecognitionPermissionRequest;-@@ -1582,6 +1585,7 @@ typedef struct WKPageUIClientV16 {+@@ -1583,6 +1586,7 @@ typedef struct WKPageUIClientV16 {// Version 14.WKPageRunWebAuthenticationPanelCallback runWebAuthenticationPanel;@@ -10245,7 +10203,7 @@ index 1484f064ec89ee8c25c35df9f0a4462896699415..0622f4d5fc9144b9059395d9d0730a4a// Version 15.WKPageDecidePolicyForSpeechRecognitionPermissionRequestCallback decidePolicyForSpeechRecognitionPermissionRequest;-@@ -1696,6 +1700,7 @@ typedef struct WKPageUIClientV17 {+@@ -1697,6 +1701,7 @@ typedef struct WKPageUIClientV17 {// Version 14.WKPageRunWebAuthenticationPanelCallback runWebAuthenticationPanel;@@ -10253,7 +10211,7 @@ index 1484f064ec89ee8c25c35df9f0a4462896699415..0622f4d5fc9144b9059395d9d0730a4a// Version 15.WKPageDecidePolicyForSpeechRecognitionPermissionRequestCallback decidePolicyForSpeechRecognitionPermissionRequest;-@@ -1810,6 +1815,7 @@ typedef struct WKPageUIClientV18 {+@@ -1811,6 +1816,7 @@ typedef struct WKPageUIClientV18 {// Version 14.WKPageRunWebAuthenticationPanelCallback runWebAuthenticationPanel;@@ -10261,7 +10219,7 @@ index 1484f064ec89ee8c25c35df9f0a4462896699415..0622f4d5fc9144b9059395d9d0730a4a// Version 15.WKPageDecidePolicyForSpeechRecognitionPermissionRequestCallback decidePolicyForSpeechRecognitionPermissionRequest;-@@ -1926,6 +1932,7 @@ typedef struct WKPageUIClientV19 {+@@ -1927,6 +1933,7 @@ typedef struct WKPageUIClientV19 {// Version 14.WKPageRunWebAuthenticationPanelCallback runWebAuthenticationPanel;@@ -10270,7 +10228,7 @@ index 1484f064ec89ee8c25c35df9f0a4462896699415..0622f4d5fc9144b9059395d9d0730a4a// Version 15.WKPageDecidePolicyForSpeechRecognitionPermissionRequestCallback decidePolicyForSpeechRecognitionPermissionRequest;diff --git a/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm b/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm-index 53350803b70ce91ba7d326b94435f7cbca375afa..4595ba4208f1a2e7864b2b0ed6e66db42c2d00a6 100644+index 3298711f75bd5be68290738a21de99c927e2d925..6943df0b1f4ee684db0b52f336b5d7f8922c2707 100644--- a/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm+++ b/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm@@ -712,6 +712,16 @@ - (void)_setMediaCaptureRequiresSecureConnection:(BOOL)requiresSecureConnection@@ -10291,7 +10249,7 @@ index 53350803b70ce91ba7d326b94435f7cbca375afa..4595ba4208f1a2e7864b2b0ed6e66db4{return _preferences->inactiveMediaCaptureStreamRepromptIntervalInMinutes();diff --git a/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h b/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h-index 34d46d52f796ed9b06fafabd03864229cdd307ab..a74a1ea9f9a55421bd569d958d7c0baa8618ca6d 100644+index 41525c8980f698aa4326e7d4d232311cee2c43d5..1f1745431c6cc7af66b47dd5d015c52389626e6f 100644--- a/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h+++ b/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h@@ -119,6 +119,7 @@ typedef NS_ENUM(NSInteger, _WKPitchCorrectionAlgorithm) {@@ -10303,7 +10261,7 @@ index 34d46d52f796ed9b06fafabd03864229cdd307ab..a74a1ea9f9a55421bd569d958d7c0baa@property (nonatomic, setter=_setICECandidateFilteringEnabled:) BOOL _iceCandidateFilteringEnabled WK_API_AVAILABLE(macos(10.13.4), ios(11.3));@property (nonatomic, setter=_setInactiveMediaCaptureStreamRepromptIntervalInMinutes:) double _inactiveMediaCaptureStreamRepromptIntervalInMinutes WK_API_AVAILABLE(macos(10.13.4), ios(11.3));diff --git a/Source/WebKit/UIProcess/API/Cocoa/WKUIDelegate.h b/Source/WebKit/UIProcess/API/Cocoa/WKUIDelegate.h-index ef512c7ba09298b2291d0248988574163ff2e7c8..d42e7f9f7b66840b68e61ce46b4bbd6254518ef7 100644+index 5f4e98c6ab6bb3cce607b96600cac66c70753224..1c2af77331d0da8d9ba232ba508b96e4f7276fe8 100644--- a/Source/WebKit/UIProcess/API/Cocoa/WKUIDelegate.h+++ b/Source/WebKit/UIProcess/API/Cocoa/WKUIDelegate.h@@ -149,6 +149,12 @@ WK_SWIFT_UI_ACTOR@@ -10320,10 +10278,10 @@ index ef512c7ba09298b2291d0248988574163ff2e7c8..d42e7f9f7b66840b68e61ce46b4bbd62/*! @abstract A delegate to request permission for microphone audio and camera video access.@param webView The web view invoking the delegate method.diff --git a/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStore.h b/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStore.h-index eff4cf557033561ab20762d93a58c2d71f5505f0..9418e2c51e50190dee2b5d7c854eacea8c5a4b76 100644+index 930357ac3469195e9f33d5ffce92777018bb0b13..f62555ec562f8416976d31692e8fb1751a04d458 100644--- a/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStore.h+++ b/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStore.h-@@ -126,6 +126,8 @@ WK_CLASS_AVAILABLE(macos(10.11), ios(9.0))+@@ -138,6 +138,8 @@ WK_CLASS_AVAILABLE(macos(10.11), ios(9.0))#endif#endif@@ -10333,7 +10291,7 @@ index eff4cf557033561ab20762d93a58c2d71f5505f0..9418e2c51e50190dee2b5d7c854eaceaNS_ASSUME_NONNULL_ENDdiff --git a/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStore.mm b/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStore.mm-index 97a87094e648a15e2501fb39a46bf0fbb4cb50d9..b08c212a0372175859645f7dba0c704fe865451c 100644+index 5b6b451a4ab86b3c280c107e5f7bec822155ccde..99eeb8633ab25d8f4f174440e328ba5287e3a2b8 100644--- a/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStore.mm+++ b/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStore.mm@@ -55,6 +55,7 @@@@ -10344,7 +10302,7 @@ index 97a87094e648a15e2501fb39a46bf0fbb4cb50d9..b08c212a0372175859645f7dba0c704f#import <WebCore/Credential.h>#import <WebCore/RegistrableDomain.h>#import <WebCore/ResourceResponse.h>-@@ -552,6 +553,11 @@ - (void)removeDataOfTypes:(NSSet *)dataTypes modifiedSince:(NSDate *)date comple+@@ -523,6 +524,11 @@ - (void)removeDataOfTypes:(NSSet *)dataTypes modifiedSince:(NSDate *)date comple});}@@ -10496,7 +10454,7 @@ index 426c7cbc897e22fd2e962dd3744959975d6ae6a0..f7a52359d7d42f970ef424b6c702b0ec@property (nonatomic) BOOL processSwapsOnNavigationWithinSameNonHTTPFamilyProtocol WK_API_AVAILABLE(macos(12.0), ios(15.0));@property (nonatomic) BOOL prewarmsProcessesAutomatically WK_API_AVAILABLE(macos(10.14.4), ios(12.2));diff --git a/Source/WebKit/UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm b/Source/WebKit/UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm-index 38b516d32edc4038508c664e0c4dc804cd477787..891dd8b2451ab771e451ea8ef74906d364e76007 100644+index 7ccfd9a46cd024c8f6644594b9d0cde8ae7e60db..921ec683dce77583f24d27a0b1b6f478242dfb42 100644--- a/Source/WebKit/UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm+++ b/Source/WebKit/UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm@@ -241,6 +241,16 @@ - (BOOL)processSwapsOnNavigation@@ -10529,7 +10487,7 @@ index 4974e14214e2bb3e982325b885bab33e54f83998..cacdf8c71fab248d38d2faf03f7affdctypedef NS_ENUM(NSInteger, _WKUserStyleLevel) {_WKUserStyleUserLevel,diff --git a/Source/WebKit/UIProcess/API/Cocoa/_WKWebPushSubscriptionData.mm b/Source/WebKit/UIProcess/API/Cocoa/_WKWebPushSubscriptionData.mm-index 0a78daba00961bf10564a0b53067960b71d8b61d..696408b77c82e205a134edf2ee17ff971af226f3 100644+index d139d35f09a999e2c85f48799a399d791d421ffd..f79c073291c6071c566220a40f7dd4bbc57192a1 100644--- a/Source/WebKit/UIProcess/API/Cocoa/_WKWebPushSubscriptionData.mm+++ b/Source/WebKit/UIProcess/API/Cocoa/_WKWebPushSubscriptionData.mm@@ -28,6 +28,9 @@@@ -10745,7 +10703,7 @@ index 0000000000000000000000000000000000000000..e0b1da48465c850f541532ed961d1b77+WebKit::WebPageProxy* webkitBrowserInspectorCreateNewPageInContext(WebKitWebContext*);+void webkitBrowserInspectorQuitApplication();diff --git a/Source/WebKit/UIProcess/API/glib/WebKitUIClient.cpp b/Source/WebKit/UIProcess/API/glib/WebKitUIClient.cpp-index 9b6d8db85df969e609de036fac67374226ecd48e..2b293d5f24e562f06859432580f2cdfe40f8b9a6 100644+index 1080e5d6a44b4d7ec649913c39af89aa702d2ee4..2ef7037a1778982275f4b1a5190a089295c8e59c 100644--- a/Source/WebKit/UIProcess/API/glib/WebKitUIClient.cpp+++ b/Source/WebKit/UIProcess/API/glib/WebKitUIClient.cpp@@ -101,6 +101,10 @@ private:@@ -10829,10 +10787,10 @@ index c1945fbe717a42afc1f51d64a80c7de3fa9009ba..ab63fe19b00ecbd64c9421e6eecad3e2#endif+int webkitWebContextExistingCount();diff --git a/Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp b/Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp-index 7d8de31fc7e373871e89ab41fc8f3a63fceea1c6..7d2785ed1798bd661d0f98e5ab68037d3cd02c51 100644+index df1381b577be94114401e1faaf1979183d82614f..7739fac45b41e07d39a6ac1568641b44f67d5f56 100644--- a/Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp+++ b/Source/WebKit/UIProcess/API/glib/WebKitWebView.cpp-@@ -37,6 +37,7 @@+@@ -39,6 +39,7 @@#include "WebContextMenuItem.h"#include "WebContextMenuItemData.h"#include "WebFrameProxy.h"@@ -10840,7 +10798,7 @@ index 7d8de31fc7e373871e89ab41fc8f3a63fceea1c6..7d2785ed1798bd661d0f98e5ab68037d#include "WebKitAuthenticationRequestPrivate.h"#include "WebKitBackForwardListPrivate.h"#include "WebKitContextMenuClient.h"-@@ -150,6 +151,7 @@ enum {+@@ -152,6 +153,7 @@ enum {CLOSE,SCRIPT_DIALOG,@@ -10848,7 +10806,7 @@ index 7d8de31fc7e373871e89ab41fc8f3a63fceea1c6..7d2785ed1798bd661d0f98e5ab68037dDECIDE_POLICY,PERMISSION_REQUEST,-@@ -518,6 +520,16 @@ GRefPtr<WebKitOptionMenu> WebKitWebViewClient::showOptionMenu(WebKitPopupMenu& p+@@ -520,6 +522,16 @@ GRefPtr<WebKitOptionMenu> WebKitWebViewClient::showOptionMenu(WebKitPopupMenu& pvoid WebKitWebViewClient::frameDisplayed(WKWPE::View&){@@ -10865,7 +10823,7 @@ index 7d8de31fc7e373871e89ab41fc8f3a63fceea1c6..7d2785ed1798bd661d0f98e5ab68037d{SetForScope inFrameDisplayedGuard(m_webView->priv->inFrameDisplayed, true);for (const auto& callback : m_webView->priv->frameDisplayedCallbacks) {-@@ -534,6 +546,18 @@ void WebKitWebViewClient::frameDisplayed(WKWPE::View&)+@@ -536,6 +548,18 @@ void WebKitWebViewClient::frameDisplayed(WKWPE::View&)}}@@ -10884,7 +10842,7 @@ index 7d8de31fc7e373871e89ab41fc8f3a63fceea1c6..7d2785ed1798bd661d0f98e5ab68037dvoid WebKitWebViewClient::willStartLoad(WKWPE::View&){webkitWebViewWillStartLoad(m_webView);-@@ -620,7 +644,7 @@ static gboolean webkitWebViewDecidePolicy(WebKitWebView*, WebKitPolicyDecision*+@@ -622,7 +646,7 @@ static gboolean webkitWebViewDecidePolicy(WebKitWebView*, WebKitPolicyDecision*static gboolean webkitWebViewPermissionRequest(WebKitWebView*, WebKitPermissionRequest* request){@@ -10893,7 +10851,7 @@ index 7d8de31fc7e373871e89ab41fc8f3a63fceea1c6..7d2785ed1798bd661d0f98e5ab68037dif (WEBKIT_IS_POINTER_LOCK_PERMISSION_REQUEST(request)) {webkit_permission_request_allow(request);return TRUE;-@@ -943,6 +967,10 @@ static void webkitWebViewConstructed(GObject* object)+@@ -945,6 +969,10 @@ static void webkitWebViewConstructed(GObject* object)priv->websitePolicies = adoptGRef(webkit_website_policies_new());Ref configuration = priv->relatedView && priv->relatedView->priv->configurationForNextRelatedView ? priv->relatedView->priv->configurationForNextRelatedView.releaseNonNull() : webkitWebViewCreatePageConfiguration(webView);@@ -10904,7 +10862,7 @@ index 7d8de31fc7e373871e89ab41fc8f3a63fceea1c6..7d2785ed1798bd661d0f98e5ab68037dwebkitWebViewCreatePage(webView, WTFMove(configuration));webkitWebContextWebViewCreated(priv->context.get(), webView);-@@ -1982,6 +2010,15 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass)+@@ -1984,6 +2012,15 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass)G_TYPE_BOOLEAN, 1,WEBKIT_TYPE_SCRIPT_DIALOG);@@ -10920,7 +10878,7 @@ index 7d8de31fc7e373871e89ab41fc8f3a63fceea1c6..7d2785ed1798bd661d0f98e5ab68037d/*** WebKitWebView::decide-policy:* @web_view: the #WebKitWebView on which the signal is emitted-@@ -2767,6 +2804,23 @@ void webkitWebViewRunJavaScriptBeforeUnloadConfirm(WebKitWebView* webView, const+@@ -2769,6 +2806,23 @@ void webkitWebViewRunJavaScriptBeforeUnloadConfirm(WebKitWebView* webView, constwebkit_script_dialog_unref(webView->priv->currentScriptDialog);}@@ -11107,7 +11065,7 @@ index 496079da90993ac37689b060b69ecd4a67c2b6a8..af30181ca922f16c0f6e245c70e5ce7dG_BEGIN_DECLSdiff --git a/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp b/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp-index 597dcdbd94e8899f60fc9a0566698fd142170926..8d7f77586e25d299c3043128536fd3801eccde4a 100644+index 2add5ab84105ad5e79635524b385fb5cb1de1a1b..0585e8474fc8cf42db262be75b514ea68fd5274b 100644--- a/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp+++ b/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp@@ -2873,6 +2873,11 @@ void webkitWebViewBaseResetClickCounter(WebKitWebViewBase* webkitWebViewBase)@@ -11196,7 +11154,7 @@ index 7636ad733e7be66a74f8fede966b0acb905a5842..cf54287353d1e529c6765e3caf8d283avirtual void didChangePageID(WKWPE::View&) { }virtual void didReceiveUserMessage(WKWPE::View&, WebKit::UserMessage&&, CompletionHandler<void(WebKit::UserMessage&&)>&& completionHandler) { completionHandler(WebKit::UserMessage()); }diff --git a/Source/WebKit/UIProcess/API/wpe/PageClientImpl.cpp b/Source/WebKit/UIProcess/API/wpe/PageClientImpl.cpp-index 76f77a9a50f721e2d71def6ca5c81ad68274653a..c9b583bd70d87586fd7ea727c20ada6f01dffb72 100644+index aec5bdaa6d2ceea13ad61e3996fd69f9f6a2dc55..ca51881ce7783979f9d36035093b571db93a9253 100644--- a/Source/WebKit/UIProcess/API/wpe/PageClientImpl.cpp+++ b/Source/WebKit/UIProcess/API/wpe/PageClientImpl.cpp@@ -35,9 +35,12 @@@@ -11244,7 +11202,7 @@ index 76f77a9a50f721e2d71def6ca5c81ad68274653a..c9b583bd70d87586fd7ea727c20ada6f}RefPtr<WebDateTimePicker> PageClientImpl::createDateTimePicker(WebPageProxy& page)-@@ -518,6 +527,64 @@ void PageClientImpl::selectionDidChange()+@@ -523,6 +532,64 @@ void PageClientImpl::selectionDidChange()m_view.selectionDidChange();}@@ -11309,7 +11267,7 @@ index 76f77a9a50f721e2d71def6ca5c81ad68274653a..c9b583bd70d87586fd7ea727c20ada6fWebKitWebResourceLoadManager* PageClientImpl::webResourceLoadManager(){return m_view.webResourceLoadManager();-@@ -528,4 +595,11 @@ void PageClientImpl::callAfterNextPresentationUpdate(CompletionHandler<void()>&&+@@ -533,4 +600,11 @@ void PageClientImpl::callAfterNextPresentationUpdate(CompletionHandler<void()>&&m_view.callAfterNextPresentationUpdate(WTFMove(callback));}@@ -11525,19 +11483,20 @@ index 2f1182cb91a00353eace0b71612df096391c2450..d71d7fc724b046fab41285bb8f390cb6void didChangePageID(WKWPE::View&) override;void didReceiveUserMessage(WKWPE::View&, WebKit::UserMessage&&, CompletionHandler<void(WebKit::UserMessage&&)>&&) override;diff --git a/Source/WebKit/UIProcess/Automation/WebAutomationSession.h b/Source/WebKit/UIProcess/Automation/WebAutomationSession.h-index 8c97bd6e955005ba6246715aac63c4d675f5a713..1440dd5233d20ada05fee01a1916ad784a745214 100644+index 6ae7054c30026bbaca91936c46ffff0760039d5a..5e97a1247dc43118c901b548f8dafa377e3f98ae 100644--- a/Source/WebKit/UIProcess/Automation/WebAutomationSession.h+++ b/Source/WebKit/UIProcess/Automation/WebAutomationSession.h-@@ -279,6 +279,8 @@ public:+@@ -285,6 +285,9 @@ public:void didDestroyFrame(WebCore::FrameIdentifier);+ static std::optional<String> platformGetBase64EncodedPNGData(const ViewSnapshot&);+- private:++private:RefPtr<WebPageProxy> webPageProxyForHandle(const String&);String handleForWebPageProxy(const WebPageProxy&);-@@ -329,7 +331,6 @@ private:++@@ -336,7 +339,6 @@ private:// Get base64-encoded PNG data from a bitmap.static std::optional<String> platformGetBase64EncodedPNGData(WebCore::ShareableBitmap::Handle&&);@@ -11546,7 +11505,7 @@ index 8c97bd6e955005ba6246715aac63c4d675f5a713..1440dd5233d20ada05fee01a1916ad78// Save base64-encoded file contents to a local file path and return the path.// This reuses the basename of the remote file path so that the filename exposed to DOM API remains the same.diff --git a/Source/WebKit/UIProcess/AuxiliaryProcessProxy.cpp b/Source/WebKit/UIProcess/AuxiliaryProcessProxy.cpp-index 601d3874b710ca87c18a2dbcfbfb7368ac61d602..26c9ae063679b6f97be8c6cce8432aad3e90b3a4 100644+index a4d1f15cd80b95ec8c82ac07cac3b8dfdae5916c..5182ffa031fd7278ea3bce5bb56e0a648f9223e2 100644--- a/Source/WebKit/UIProcess/AuxiliaryProcessProxy.cpp+++ b/Source/WebKit/UIProcess/AuxiliaryProcessProxy.cpp@@ -172,7 +172,11 @@ void AuxiliaryProcessProxy::getLaunchOptions(ProcessLauncher::LaunchOptions& lau@@ -11562,7 +11521,7 @@ index 601d3874b710ca87c18a2dbcfbfb7368ac61d602..26c9ae063679b6f97be8c6cce8432aadplatformGetLaunchOptions(launchOptions);}diff --git a/Source/WebKit/UIProcess/AuxiliaryProcessProxy.h b/Source/WebKit/UIProcess/AuxiliaryProcessProxy.h-index eed9d40f00e29fd1e36a2c7893639544439e53ce..eeb0b85018d13f46279eb5b9d281fdc34de92e02 100644+index 1bca45f83bccfd8f917fc8a49b39414d9a8b6548..bcf8c5e5acb0652d04201aa8a8a840537e17e66f 100644--- a/Source/WebKit/UIProcess/AuxiliaryProcessProxy.h+++ b/Source/WebKit/UIProcess/AuxiliaryProcessProxy.h@@ -296,13 +296,16 @@ protected:@@ -11584,14 +11543,18 @@ index eed9d40f00e29fd1e36a2c7893639544439e53ce..eeb0b85018d13f46279eb5b9d281fdc3// Connection::Clientdiff --git a/Source/WebKit/UIProcess/BackingStore.h b/Source/WebKit/UIProcess/BackingStore.h-index 945c62704e0b25f04e9ee4be88b21f88aeda8bd9..409c1c560b2462bf59f19dfee7941748b54fd22c 100644+index 945c62704e0b25f04e9ee4be88b21f88aeda8bd9..ff9a8ee47e2669260743ae2174801b1cc3c4c413 100644--- a/Source/WebKit/UIProcess/BackingStore.h+++ b/Source/WebKit/UIProcess/BackingStore.h-@@ -67,6 +67,7 @@ public:+@@ -67,6 +67,11 @@ public:float deviceScaleFactor() const { return m_deviceScaleFactor; }void paint(PlatformPaintContextPtr, const WebCore::IntRect&);++#if PLATFORM(GTK) || USE(CAIRO)+ RefPtr<cairo_surface_t> surface() const { return m_surface; }++#elif USE(SKIA)++ sk_sp<SkSurface> surface() const { return m_surface; }++#endifvoid incorporateUpdate(UpdateInfo&&);private:@@ -11719,10 +11682,10 @@ index 89d125f7742f81ead8c50f218ecb1771b8000636..baa6cf58ad502c6c033ee6293a6cc8d4namespace WebKit {diff --git a/Source/WebKit/UIProcess/Cocoa/UIDelegate.h b/Source/WebKit/UIProcess/Cocoa/UIDelegate.h-index 8d9915d0802f215ea2a3e298b8653636338250b9..50e0ad091bcfc6356708ccfaf242787188e49a82 100644+index 505b934da3a86e218d11e2db1406b0a0a4c7ec36..2e800a8f78fb6209de7f2950fbf84ae062633a4d 100644--- a/Source/WebKit/UIProcess/Cocoa/UIDelegate.h+++ b/Source/WebKit/UIProcess/Cocoa/UIDelegate.h-@@ -102,6 +102,7 @@ private:+@@ -103,6 +103,7 @@ private:void runJavaScriptAlert(WebPageProxy&, const WTF::String&, WebFrameProxy*, FrameInfoData&&, Function<void()>&& completionHandler) final;void runJavaScriptConfirm(WebPageProxy&, const WTF::String&, WebFrameProxy*, FrameInfoData&&, Function<void(bool)>&& completionHandler) final;void runJavaScriptPrompt(WebPageProxy&, const WTF::String&, const WTF::String&, WebFrameProxy*, FrameInfoData&&, Function<void(const WTF::String&)>&&) final;@@ -11730,7 +11693,7 @@ index 8d9915d0802f215ea2a3e298b8653636338250b9..50e0ad091bcfc6356708ccfaf2427871void presentStorageAccessConfirmDialog(const WTF::String& requestingDomain, const WTF::String& currentDomain, CompletionHandler<void(bool)>&&);void requestStorageAccessConfirm(WebPageProxy&, WebFrameProxy*, const WebCore::RegistrableDomain& requestingDomain, const WebCore::RegistrableDomain& currentDomain, std::optional<WebCore::OrganizationStorageAccessPromptQuirk>&&, CompletionHandler<void(bool)>&&) final;void decidePolicyForGeolocationPermissionRequest(WebPageProxy&, WebFrameProxy&, const FrameInfoData&, Function<void(bool)>&) final;-@@ -220,6 +221,7 @@ private:+@@ -221,6 +222,7 @@ private:bool webViewRunJavaScriptAlertPanelWithMessageInitiatedByFrameCompletionHandler : 1;bool webViewRunJavaScriptConfirmPanelWithMessageInitiatedByFrameCompletionHandler : 1;bool webViewRunJavaScriptTextInputPanelWithPromptDefaultTextInitiatedByFrameCompletionHandler : 1;@@ -11739,10 +11702,10 @@ index 8d9915d0802f215ea2a3e298b8653636338250b9..50e0ad091bcfc6356708ccfaf2427871bool webViewRequestStorageAccessPanelForDomainUnderCurrentDomainForQuirkDomainsCompletionHandler : 1;bool webViewRunBeforeUnloadConfirmPanelWithMessageInitiatedByFrameCompletionHandler : 1;diff --git a/Source/WebKit/UIProcess/Cocoa/UIDelegate.mm b/Source/WebKit/UIProcess/Cocoa/UIDelegate.mm-index da5818f79cb0f7a384af46f4d39eae4d2cf573df..44bf65e9a20428656d7eac39b9470c72e97987cf 100644+index 54b225795a14877140396f612330d5212bbf5fea..9c006877aa2a9d4804c71ad34766750fe74539b9 100644--- a/Source/WebKit/UIProcess/Cocoa/UIDelegate.mm+++ b/Source/WebKit/UIProcess/Cocoa/UIDelegate.mm-@@ -135,6 +135,7 @@ void UIDelegate::setDelegate(id <WKUIDelegate> delegate)+@@ -134,6 +134,7 @@ void UIDelegate::setDelegate(id<WKUIDelegate> delegate)m_delegateMethods.webViewRunJavaScriptAlertPanelWithMessageInitiatedByFrameCompletionHandler = [delegate respondsToSelector:@selector(webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:)];m_delegateMethods.webViewRunJavaScriptConfirmPanelWithMessageInitiatedByFrameCompletionHandler = [delegate respondsToSelector:@selector(webView:runJavaScriptConfirmPanelWithMessage:initiatedByFrame:completionHandler:)];m_delegateMethods.webViewRunJavaScriptTextInputPanelWithPromptDefaultTextInitiatedByFrameCompletionHandler = [delegate respondsToSelector:@selector(webView:runJavaScriptTextInputPanelWithPrompt:defaultText:initiatedByFrame:completionHandler:)];@@ -11750,7 +11713,7 @@ index da5818f79cb0f7a384af46f4d39eae4d2cf573df..44bf65e9a20428656d7eac39b9470c72m_delegateMethods.webViewRequestStorageAccessPanelUnderFirstPartyCompletionHandler = [delegate respondsToSelector:@selector(_webView:requestStorageAccessPanelForDomain:underCurrentDomain:completionHandler:)];m_delegateMethods.webViewRequestStorageAccessPanelForDomainUnderCurrentDomainForQuirkDomainsCompletionHandler = [delegate respondsToSelector:@selector(_webView:requestStorageAccessPanelForDomain:underCurrentDomain:forQuirkDomains:completionHandler:)];m_delegateMethods.webViewRunBeforeUnloadConfirmPanelWithMessageInitiatedByFrameCompletionHandler = [delegate respondsToSelector:@selector(_webView:runBeforeUnloadConfirmPanelWithMessage:initiatedByFrame:completionHandler:)];-@@ -466,6 +467,15 @@ void UIDelegate::UIClient::runJavaScriptPrompt(WebPageProxy& page, const WTF::St+@@ -494,6 +495,15 @@ void UIDelegate::UIClient::runJavaScriptPrompt(WebPageProxy& page, const WTF::St}).get()];}@@ -11760,14 +11723,14 @@ index da5818f79cb0f7a384af46f4d39eae4d2cf573df..44bf65e9a20428656d7eac39b9470c72+ auto delegate = m_uiDelegate->m_delegate.get();+ if (!delegate)+ return;-+ [delegate webView:m_uiDelegate->m_webView.get().get() handleJavaScriptDialog:accept value:value];++ [delegate webView:m_uiDelegate->m_webView.get().get() handleJavaScriptDialog:accept value:value.createNSString().get()];+}+void UIDelegate::UIClient::requestStorageAccessConfirm(WebPageProxy& webPageProxy, WebFrameProxy*, const WebCore::RegistrableDomain& requestingDomain, const WebCore::RegistrableDomain& currentDomain, std::optional<WebCore::OrganizationStorageAccessPromptQuirk>&& organizationStorageAccessPromptQuirk, CompletionHandler<void(bool)>&& completionHandler){RefPtr uiDelegate = m_uiDelegate.get();diff --git a/Source/WebKit/UIProcess/Cocoa/WebPageProxyCocoa.mm b/Source/WebKit/UIProcess/Cocoa/WebPageProxyCocoa.mm-index c0c9d8098ce76a6c2f7860165f990a854fbcc0e9..082322d49bf84f3b15e66c9cb89125d64f16d80a 100644+index 1f2f95479d04ad49499db7dae7954c1c54db6d3e..4aee549a4b5a371b35ce012bcdc258147ddeba8c 100644--- a/Source/WebKit/UIProcess/Cocoa/WebPageProxyCocoa.mm+++ b/Source/WebKit/UIProcess/Cocoa/WebPageProxyCocoa.mm@@ -42,7 +42,9 @@@@ -11779,13 +11742,13 @@ index c0c9d8098ce76a6c2f7860165f990a854fbcc0e9..082322d49bf84f3b15e66c9cb89125d6+#import "PasteboardTypes.h"#import "PlatformXRSystem.h"#import "PlaybackSessionManagerProxy.h"- #import "QuickLookThumbnailLoader.h"-@@ -326,11 +328,86 @@ bool WebPageProxy::scrollingUpdatesDisabledForTesting()+ #import "RemoteLayerTreeTransaction.h"+@@ -336,11 +338,86 @@ bool WebPageProxy::scrollingUpdatesDisabledForTesting()void WebPageProxy::startDrag(const DragItem& dragItem, ShareableBitmap::Handle&& dragImageHandle){+ if (m_interceptDrags) {-+ NSPasteboard *pasteboard = [NSPasteboard pasteboardWithName: m_overrideDragPasteboardName];++ NSPasteboard *pasteboard = [NSPasteboard pasteboardWithName: m_overrideDragPasteboardName.createNSString().get()];++ m_dragSelectionData = String([pasteboard name]);+ if (auto replyID = grantAccessToCurrentPasteboardData(String([pasteboard name]), [] () { }))@@ -11798,7 +11761,7 @@ index c0c9d8098ce76a6c2f7860165f990a854fbcc0e9..082322d49bf84f3b15e66c9cb89125d6+ dragCancelled();+ return;+ }-+ NSString *utiType = attachment->utiType();++ NSString *utiType = attachment->utiType().createNSString().get();+ if (!utiType.length) {+ dragCancelled();+ return;@@ -11806,7 +11769,7 @@ index c0c9d8098ce76a6c2f7860165f990a854fbcc0e9..082322d49bf84f3b15e66c9cb89125d6++ for (size_t index = 0; index < info.additionalTypesAndData.size(); ++index) {+ auto nsData = info.additionalTypesAndData[index].second->createNSData();-+ [pasteboard setData:nsData.get() forType:info.additionalTypesAndData[index].first];++ [pasteboard setData:nsData.get() forType:info.additionalTypesAndData[index].first.createNSString().get()];+ }+ } else {+ [pasteboard setString:@"" forType:PasteboardTypes::WebDummyPboardType];@@ -11869,19 +11832,19 @@ index c0c9d8098ce76a6c2f7860165f990a854fbcc0e9..082322d49bf84f3b15e66c9cb89125d6#if ENABLE(ATTACHMENT_ELEMENT)diff --git a/Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm b/Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm-index d14a7dfa79daabce7bd835aa76625937e6107aad..0907c8ac8e9407231df5661180d3766b5c263dfd 100644+index c20de41306158d48f4a761e93618acad0f2ae130..0bc1c2e90f4c80c9b506de3cfaf17ae06c173406 100644--- a/Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm+++ b/Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm-@@ -432,7 +432,7 @@ ALLOW_DEPRECATED_DECLARATIONS_END+@@ -434,7 +434,7 @@ ALLOW_DEPRECATED_DECLARATIONS_ENDauto screenProperties = WebCore::collectScreenProperties();parameters.screenProperties = WTFMove(screenProperties);#if PLATFORM(MAC)- parameters.useOverlayScrollbars = ([NSScroller preferredScrollerStyle] == NSScrollerStyleOverlay);+ parameters.useOverlayScrollbars = m_configuration->forceOverlayScrollbars() || ([NSScroller preferredScrollerStyle] == NSScrollerStyleOverlay);#endif-- #if (PLATFORM(IOS) || PLATFORM(VISION)) && HAVE(AGX_COMPILER_SERVICE)-@@ -841,8 +841,8 @@ void WebProcessPool::registerNotificationObservers()++ #if PLATFORM(VISION)+@@ -833,8 +833,8 @@ void WebProcessPool::registerNotificationObservers()}];m_scrollerStyleNotificationObserver = [[NSNotificationCenter defaultCenter] addObserverForName:NSPreferredScrollerStyleDidChangeNotification object:nil queue:[NSOperationQueue currentQueue] usingBlock:^(NSNotification *notification) {@@ -11893,7 +11856,7 @@ index d14a7dfa79daabce7bd835aa76625937e6107aad..0907c8ac8e9407231df5661180d3766bm_activationObserver = [[NSNotificationCenter defaultCenter] addObserverForName:NSApplicationDidBecomeActiveNotification object:NSApp queue:[NSOperationQueue currentQueue] usingBlock:^(NSNotification *notification) {diff --git a/Source/WebKit/UIProcess/CoordinatedGraphics/DrawingAreaProxyCoordinatedGraphics.cpp b/Source/WebKit/UIProcess/CoordinatedGraphics/DrawingAreaProxyCoordinatedGraphics.cpp-index 9b45c78e2fd36e825c4e67d8e824771128c8fe15..9f748e729fce8103278b3888552d5c374ed6bc67 100644+index 183a2dc44f4d2921e68a6ff5fd2fb0fb815753af..a17d0ed7d287694516305ba57a849ad8042e9287 100644--- a/Source/WebKit/UIProcess/CoordinatedGraphics/DrawingAreaProxyCoordinatedGraphics.cpp+++ b/Source/WebKit/UIProcess/CoordinatedGraphics/DrawingAreaProxyCoordinatedGraphics.cpp@@ -33,6 +33,7 @@@@ -11915,21 +11878,19 @@ index 9b45c78e2fd36e825c4e67d8e824771128c8fe15..9f748e729fce8103278b3888552d5c37#include <gtk/gtk.h>#endif-@@ -49,6 +52,13 @@+@@ -49,6 +52,11 @@#include <wtf/glib/RunLoopSourcePriority.h>#endif+#if PLATFORM(WIN)-+#include <cairo-win32.h>+#include <windows.h>+#include <WebCore/HWndDC.h>-+#include <WebCore/RefPtrCairo.h>+#endif+namespace WebKit {using namespace WebCore;-@@ -182,6 +192,11 @@ void DrawingAreaProxyCoordinatedGraphics::deviceScaleFactorDidChange(CompletionH+@@ -182,6 +190,11 @@ void DrawingAreaProxyCoordinatedGraphics::deviceScaleFactorDidChange(CompletionHsendWithAsyncReply(Messages::DrawingArea::SetDeviceScaleFactor(m_webPageProxy->deviceScaleFactor()), WTFMove(completionHandler));}@@ -11941,38 +11902,20 @@ index 9b45c78e2fd36e825c4e67d8e824771128c8fe15..9f748e729fce8103278b3888552d5c37void DrawingAreaProxyCoordinatedGraphics::setBackingStoreIsDiscardable(bool isBackingStoreDiscardable){#if !PLATFORM(WPE)-@@ -243,6 +258,45 @@ void DrawingAreaProxyCoordinatedGraphics::updateAcceleratedCompositingMode(uint6+@@ -243,6 +256,42 @@ void DrawingAreaProxyCoordinatedGraphics::updateAcceleratedCompositingMode(uint6updateAcceleratedCompositingMode(layerTreeContext);}-+#if PLATFORM(WIN)-+void DrawingAreaProxyCoordinatedGraphics::didChangeAcceleratedCompositingMode(bool enabled)-+{-+ m_isInAcceleratedCompositingMode = enabled;-+}-+#endif-+-+#if !PLATFORM(WPE)++#if PLATFORM(GTK)+void DrawingAreaProxyCoordinatedGraphics::captureFrame()+{+ RefPtr<cairo_surface_t> surface;-+#if PLATFORM(WIN)-+ HWndDC dc;-+ if (m_isInAcceleratedCompositingMode) {-+ dc.setHWnd(reinterpret_cast<HWND>(protectedWebPageProxy()->viewWidget()));-+ surface = adoptRef(cairo_win32_surface_create(dc));-+#else+ if (isInAcceleratedCompositingMode()) {-+# if PLATFORM(GTK)+ AcceleratedBackingStore* backingStore = webkitWebViewBaseGetAcceleratedBackingStore(WEBKIT_WEB_VIEW_BASE(protectedWebPageProxy()->viewWidget()));+ if (!backingStore)+ return;++ surface = backingStore->surface();-+# else-+ fprintf(stderr, "captureFrame() is not supported in accelerated compositing mode on this platform.\n");-+# endif-+#endif+ } else if (m_backingStore) {+ surface = m_backingStore->surface();+ }@@ -11982,12 +11925,27 @@ index 9b45c78e2fd36e825c4e67d8e824771128c8fe15..9f748e729fce8103278b3888552d5c37++ protectedWebPageProxy()->inspectorController().didPaint(surface.get());+}-+#endif++#endif // PLATFORM(GTK)++++#if PLATFORM(WIN)++void DrawingAreaProxyCoordinatedGraphics::captureFrame()++{++ if (!m_backingStore)++ return;++ auto surface = m_backingStore->surface();++ if (!surface)++ return;++ auto image = surface->makeImageSnapshot();++ if (!image)++ return;++ protectedWebPageProxy()->inspectorController().didPaint(WTFMove(image));++}++#endif // PLATFORM(WIN)+bool DrawingAreaProxyCoordinatedGraphics::alwaysUseCompositing() const{if (!m_webPageProxy)-@@ -310,6 +364,12 @@ void DrawingAreaProxyCoordinatedGraphics::didUpdateGeometry()+@@ -310,6 +359,12 @@ void DrawingAreaProxyCoordinatedGraphics::didUpdateGeometry()// we need to resend the new size here.if (m_lastSentSize != m_size)sendUpdateGeometry();@@ -12001,7 +11959,7 @@ index 9b45c78e2fd36e825c4e67d8e824771128c8fe15..9f748e729fce8103278b3888552d5c37#if !PLATFORM(WPE)diff --git a/Source/WebKit/UIProcess/CoordinatedGraphics/DrawingAreaProxyCoordinatedGraphics.h b/Source/WebKit/UIProcess/CoordinatedGraphics/DrawingAreaProxyCoordinatedGraphics.h-index 9c2bde0db0e4032a32e6ae02dc45af335df92f7a..7ae72e6c791c264ea7e0db4c93a0422b5b699e19 100644+index 9c2bde0db0e4032a32e6ae02dc45af335df92f7a..3f3a58ee9b0f5c0ddad84f41cf3acd6199d81c37 100644--- a/Source/WebKit/UIProcess/CoordinatedGraphics/DrawingAreaProxyCoordinatedGraphics.h+++ b/Source/WebKit/UIProcess/CoordinatedGraphics/DrawingAreaProxyCoordinatedGraphics.h@@ -29,6 +29,7 @@@@ -12023,17 +11981,7 @@ index 9c2bde0db0e4032a32e6ae02dc45af335df92f7a..7ae72e6c791c264ea7e0db4c93a0422bvoid dispatchAfterEnsuringDrawing(CompletionHandler<void()>&&);-@@ -86,6 +91,9 @@ private:- void exitAcceleratedCompositingMode(uint64_t backingStoreStateID, UpdateInfo&&) override;- void updateAcceleratedCompositingMode(uint64_t backingStoreStateID, const LayerTreeContext&) override;- void dispatchPresentationCallbacksAfterFlushingLayers(IPC::Connection&, Vector<IPC::AsyncReplyID>&&) override;-+#if PLATFORM(WIN)-+ void didChangeAcceleratedCompositingMode(bool enabled) override;-+#endif-- bool shouldSendWheelEventsToEventDispatcher() const override { return true; }--@@ -129,6 +137,7 @@ private:+@@ -129,6 +134,7 @@ private:// The last size we sent to the web process.WebCore::IntSize m_lastSentSize;@@ -12041,19 +11989,8 @@ index 9c2bde0db0e4032a32e6ae02dc45af335df92f7a..7ae72e6c791c264ea7e0db4c93a0422b#if !PLATFORM(WPE)bool m_isBackingStoreDiscardable { true };-@@ -137,6 +146,10 @@ private:- RunLoop::Timer m_discardBackingStoreTimer;- #endif- std::unique_ptr<DrawingMonitor> m_drawingMonitor;-+-+#if PLATFORM(WIN)-+ bool m_isInAcceleratedCompositingMode { false };-+#endif- };-- } // namespace WebKitdiff --git a/Source/WebKit/UIProcess/Downloads/DownloadProxy.cpp b/Source/WebKit/UIProcess/Downloads/DownloadProxy.cpp-index 5d0385c213e4951ca9bec3c17bd2135887348cb0..634193dc71e82245b5017709bb93cfb5fdfede83 100644+index 248a3bc1d03be7bca3c4324b93f13b452d91cc42..1ebb98bea247b882335569560d9fe8678f5d4793 100644--- a/Source/WebKit/UIProcess/Downloads/DownloadProxy.cpp+++ b/Source/WebKit/UIProcess/Downloads/DownloadProxy.cpp@@ -41,8 +41,10 @@@@ -12067,7 +12004,7 @@ index 5d0385c213e4951ca9bec3c17bd2135887348cb0..634193dc71e82245b5017709bb93cfb5#if PLATFORM(MAC)#include <pal/spi/mac/QuarantineSPI.h>-@@ -89,7 +91,10 @@ DownloadProxy::DownloadProxy(DownloadProxyMap& downloadProxyMap, WebsiteDataStor+@@ -66,7 +68,10 @@ DownloadProxy::DownloadProxy(DownloadProxyMap& downloadProxyMap, WebsiteDataStor#if HAVE(MODERN_DOWNLOADPROGRESS), m_assertion(ProcessAssertion::create(getCurrentProcessID(), "WebKit DownloadProxy DecideDestination"_s, ProcessAssertionType::FinishTaskInterruptable))#endif@@ -12078,7 +12015,7 @@ index 5d0385c213e4951ca9bec3c17bd2135887348cb0..634193dc71e82245b5017709bb93cfb5}DownloadProxy::~DownloadProxy()-@@ -109,12 +114,15 @@ void DownloadProxy::cancel(CompletionHandler<void(API::Data*)>&& completionHandl+@@ -86,12 +91,15 @@ void DownloadProxy::cancel(CompletionHandler<void(API::Data*)>&& completionHandl{m_downloadIsCancelled = true;if (m_dataStore) {@@ -12095,7 +12032,7 @@ index 5d0385c213e4951ca9bec3c17bd2135887348cb0..634193dc71e82245b5017709bb93cfb5if (RefPtr downloadProxyMap = protectedThis->m_downloadProxyMap.get())downloadProxyMap->downloadFinished(*protectedThis);});-@@ -186,6 +194,33 @@ void DownloadProxy::decideDestinationWithSuggestedFilename(const WebCore::Resour+@@ -163,6 +171,33 @@ void DownloadProxy::decideDestinationWithSuggestedFilename(const WebCore::ResoursuggestedFilename = m_suggestedFilename;suggestedFilename = MIMETypeRegistry::appendFileExtensionIfNecessary(suggestedFilename, response.mimeType());@@ -12129,8 +12066,8 @@ index 5d0385c213e4951ca9bec3c17bd2135887348cb0..634193dc71e82245b5017709bb93cfb5protectedClient()->decideDestinationWithSuggestedFilename(*this, response, ResourceResponseBase::sanitizeSuggestedFilename(suggestedFilename), [this, protectedThis = Ref { *this }, completionHandler = WTFMove(completionHandler)] (AllowOverwrite allowOverwrite, String destination) mutable {SandboxExtension::Handle sandboxExtensionHandle;if (!destination.isNull()) {-@@ -250,6 +285,8 @@ void DownloadProxy::didFinish()- m_client->didFinish(*this);+@@ -227,6 +262,8 @@ void DownloadProxy::didFinish()+ protectedClient()->didFinish(*this);if (m_downloadIsCancelled)return;+ if (auto* instrumentation = m_dataStore->downloadInstrumentation())@@ -12138,17 +12075,17 @@ index 5d0385c213e4951ca9bec3c17bd2135887348cb0..634193dc71e82245b5017709bb93cfb5// This can cause the DownloadProxy object to be deleted.if (RefPtr downloadProxyMap = m_downloadProxyMap.get())-@@ -264,6 +301,8 @@ void DownloadProxy::didFail(const ResourceError& error, std::span<const uint8_t>+@@ -241,6 +278,8 @@ void DownloadProxy::didFail(const ResourceError& error, std::span<const uint8_t>m_legacyResumeData = createData(resumeData);- m_client->didFail(*this, error, m_legacyResumeData.get());+ protectedClient()->didFail(*this, error, m_legacyResumeData.get());+ if (auto* instrumentation = m_dataStore->downloadInstrumentation())+ instrumentation->downloadFinished(m_uuid, error.localizedDescription());// This can cause the DownloadProxy object to be deleted.if (RefPtr downloadProxyMap = m_downloadProxyMap.get())diff --git a/Source/WebKit/UIProcess/Downloads/DownloadProxy.h b/Source/WebKit/UIProcess/Downloads/DownloadProxy.h-index d82b401d7d58a34fadd38c61ef3b0f521ed432e4..9403574a7d238282998065729ec9e9d165c37f2f 100644+index 9a92a8cde3b5d1da0fbbf5fe7c549cebb8a7f2f7..9ce201ca2d7aa002c7bd389f1fe03edfb306df5d 100644--- a/Source/WebKit/UIProcess/Downloads/DownloadProxy.h+++ b/Source/WebKit/UIProcess/Downloads/DownloadProxy.h@@ -166,6 +166,7 @@ private:@@ -12160,7 +12097,7 @@ index d82b401d7d58a34fadd38c61ef3b0f521ed432e4..9403574a7d238282998065729ec9e9d1} // namespace WebKitdiff --git a/Source/WebKit/UIProcess/DrawingAreaProxy.h b/Source/WebKit/UIProcess/DrawingAreaProxy.h-index e1f55b4a7fbc452ca1f2eb025b0c88ec9f4b845f..4e4238f4f656208c0f11822406172ea13a21e2d4 100644+index e1f55b4a7fbc452ca1f2eb025b0c88ec9f4b845f..beb3c7a6619b554bb3186a0de917f497ac0f47f8 100644--- a/Source/WebKit/UIProcess/DrawingAreaProxy.h+++ b/Source/WebKit/UIProcess/DrawingAreaProxy.h@@ -94,6 +94,7 @@ public:@@ -12171,29 +12108,6 @@ index e1f55b4a7fbc452ca1f2eb025b0c88ec9f4b845f..4e4238f4f656208c0f11822406172ea1virtual void minimumSizeForAutoLayoutDidChange() { }virtual void sizeToContentAutoSizeMaximumSizeDidChange() { }-@@ -181,6 +182,10 @@ private:- virtual void update(uint64_t /* backingStoreStateID */, UpdateInfo&&) { }- virtual void exitAcceleratedCompositingMode(uint64_t /* backingStoreStateID */, UpdateInfo&&) { }- #endif-+-+#if PLATFORM(WIN)-+ virtual void didChangeAcceleratedCompositingMode(bool) { }-+#endif- };-- } // namespace WebKit-diff --git a/Source/WebKit/UIProcess/DrawingAreaProxy.messages.in b/Source/WebKit/UIProcess/DrawingAreaProxy.messages.in-index b03ac2dcf12c771da4a2347b81e5ba93fbd5f6a4..b69c5d3244306e1d1c10206d499d9a833a3efeec 100644---- a/Source/WebKit/UIProcess/DrawingAreaProxy.messages.in-+++ b/Source/WebKit/UIProcess/DrawingAreaProxy.messages.in-@@ -35,4 +35,7 @@ messages -> DrawingAreaProxy {- Update(uint64_t stateID, struct WebKit::UpdateInfo updateInfo) CanDispatchOutOfOrder- ExitAcceleratedCompositingMode(uint64_t backingStoreStateID, struct WebKit::UpdateInfo updateInfo)- #endif-+#if PLATFORM(WIN)-+ DidChangeAcceleratedCompositingMode(bool enabled)-+#endif- }diff --git a/Source/WebKit/UIProcess/Inspector/Agents/CairoJpegEncoder.cpp b/Source/WebKit/UIProcess/Inspector/Agents/CairoJpegEncoder.cppnew file mode 100644index 0000000000000000000000000000000000000000..8d20e2aa36ba0f7996c20a6a02792c7f151bbed5@@ -12484,7 +12398,7 @@ index 0000000000000000000000000000000000000000..4ec8b96bbbddf8a7b042f53a8068754a+cairo_status_t cairo_image_surface_write_to_jpeg_mem(cairo_surface_t *sfc, unsigned char **data, size_t *len, int quality);diff --git a/Source/WebKit/UIProcess/Inspector/Agents/InspectorScreencastAgent.cpp b/Source/WebKit/UIProcess/Inspector/Agents/InspectorScreencastAgent.cppnew file mode 100644-index 0000000000000000000000000000000000000000..033bf77bca2de127e55cbf55a9e0b0c358fc81f9+index 0000000000000000000000000000000000000000..55a0cf8cd5be1cdd33165fe904a8f0ffd815f6d4--- /dev/null+++ b/Source/WebKit/UIProcess/Inspector/Agents/InspectorScreencastAgent.cpp@@ -0,0 +1,392 @@@@ -12593,7 +12507,7 @@ index 0000000000000000000000000000000000000000..033bf77bca2de127e55cbf55a9e0b0c3+void InspectorScreencastAgent::didPaint(sk_sp<SkImage>&& surface)+{+ sk_sp<SkImage> image(surface);-+#if PLATFORM(WPE)++#if PLATFORM(WPE) || PLATFORM(WIN)+ // Get actual image size (in device pixels).+ WebCore::IntSize displaySize(image->width(), image->height());+@@ -12866,7 +12780,7 @@ index 0000000000000000000000000000000000000000..033bf77bca2de127e55cbf55a9e0b0c3+}+#endif+-+#if (USE(CAIRO) && !PLATFORM(WPE)) || PLATFORM(GTK)++#if PLATFORM(GTK) || PLATFORM(WIN)+void InspectorScreencastAgent::encodeFrame()+{+ if (!m_encoder && !m_screencast)@@ -13667,7 +13581,7 @@ index 0000000000000000000000000000000000000000..e2ce910f3fd7f587add552275b7e7176++} // namespace WebKitdiff --git a/Source/WebKit/UIProcess/Inspector/InspectorTargetProxy.cpp b/Source/WebKit/UIProcess/Inspector/InspectorTargetProxy.cpp-index 77bdb25abf77bc0f7f00d3dbd57b0eb751c99488..6d3a93a009cff0f70f2b1a1e674827c24a26a947 100644+index 76cc869ca4d5fc311040a285d50a44f00273fd63..633f8323697f0c2f30311a35ac3876bf8e03b741 100644--- a/Source/WebKit/UIProcess/Inspector/InspectorTargetProxy.cpp+++ b/Source/WebKit/UIProcess/Inspector/InspectorTargetProxy.cpp@@ -28,7 +28,7 @@@@ -13695,7 +13609,7 @@ index 77bdb25abf77bc0f7f00d3dbd57b0eb751c99488..6d3a93a009cff0f70f2b1a1e674827c2target->m_provisionalPage = provisionalPage;return target;}-@@ -105,6 +105,31 @@ void InspectorTargetProxy::didCommitProvisionalTarget()+@@ -108,6 +108,31 @@ void InspectorTargetProxy::didCommitProvisionalTarget()m_provisionalPage = nullptr;}@@ -13761,7 +13675,7 @@ index edd6e7f1799279ed3d0eb81b6c2eef9f5b375134..d4231f84f3c52641f4d9e88559e8e1a4String m_identifier;Inspector::InspectorTargetType m_type;diff --git a/Source/WebKit/UIProcess/Inspector/WebPageInspectorController.cpp b/Source/WebKit/UIProcess/Inspector/WebPageInspectorController.cpp-index e4f2f719746ed69b1226be2d47b16666f2067772..96956711b594d80ea9cbdce11a6f62b2992530aa 100644+index 45eb87344ce4249eea90dc0a73a2c717f69f55fa..b79c9ce9e9fd3ceb41fe6f34861536ab0bdf2e54 100644--- a/Source/WebKit/UIProcess/Inspector/WebPageInspectorController.cpp+++ b/Source/WebKit/UIProcess/Inspector/WebPageInspectorController.cpp@@ -26,13 +26,22 @@@@ -14118,7 +14032,7 @@ index e4f2f719746ed69b1226be2d47b16666f2067772..96956711b594d80ea9cbdce11a6f62b2+} // namespace WebKitdiff --git a/Source/WebKit/UIProcess/Inspector/WebPageInspectorController.h b/Source/WebKit/UIProcess/Inspector/WebPageInspectorController.h-index 29457fc3c76c963bf50b44c011f64398efbae676..3e098aae8cd02d26aa32a6e15ed16e95695afaf7 100644+index c219e0a072057a8d40d8a30a1d404851d6c12d43..42e40b5ff6bd1b49d7662a1c7d60bfd4b8d61e29 100644--- a/Source/WebKit/UIProcess/Inspector/WebPageInspectorController.h+++ b/Source/WebKit/UIProcess/Inspector/WebPageInspectorController.h@@ -26,19 +26,43 @@@@ -14254,8 +14168,8 @@ index 29457fc3c76c963bf50b44c011f64398efbae676..3e098aae8cd02d26aa32a6e15ed16e95void addTarget(std::unique_ptr<InspectorTargetProxy>&&);+ void adjustPageSettings();- Ref<Inspector::FrontendRouter> m_frontendRouter;- Ref<Inspector::BackendDispatcher> m_backendDispatcher;+ const Ref<Inspector::FrontendRouter> m_frontendRouter;+ const Ref<Inspector::BackendDispatcher> m_backendDispatcher;@@ -101,9 +176,16 @@ private:CheckedPtr<Inspector::InspectorTargetAgent> m_targetAgent;HashMap<String, std::unique_ptr<InspectorTargetProxy>> m_targets;@@ -14506,7 +14420,7 @@ index 0000000000000000000000000000000000000000..d0e11ed81a6257c011df23d5870da740+} // namespace WebKitdiff --git a/Source/WebKit/UIProcess/InspectorPlaywrightAgent.cpp b/Source/WebKit/UIProcess/InspectorPlaywrightAgent.cppnew file mode 100644-index 0000000000000000000000000000000000000000..7535756c45428e307e27807d31884ae6c5216543+index 0000000000000000000000000000000000000000..59827ffa02a8a3c7890ab0b5a8f54244f6a0680b--- /dev/null+++ b/Source/WebKit/UIProcess/InspectorPlaywrightAgent.cpp@@ -0,0 +1,1011 @@@@ -15443,7 +15357,7 @@ index 0000000000000000000000000000000000000000..7535756c45428e307e27807d31884ae6+{+ if (!m_isEnabled)+ return;-+ String frameID = WebCore::InspectorPageAgent::serializeFrameID(*frameInfoData.frameID);++ String frameID = WebCore::InspectorPageAgent::serializeFrameID(frameInfoData.frameID);+ m_downloads.set(uuid, download);+ m_frontendDispatcher->downloadCreated(+ toPageProxyIDProtocolString(*page),@@ -15748,7 +15662,7 @@ index 0000000000000000000000000000000000000000..e7a3dcc533294bb6e12f65d79b5b716b++#endif // ENABLE(REMOTE_INSPECTOR)diff --git a/Source/WebKit/UIProcess/Launcher/glib/ProcessLauncherGLib.cpp b/Source/WebKit/UIProcess/Launcher/glib/ProcessLauncherGLib.cpp-index 9959b634faa60d620d4aac6635b31914bb063979..a8a38fe41b5fdc2836d068cc69940a5b21876e8d 100644+index 272e0a6edea50acd35032a854d625b5af5a1472e..486c807ba879ecf534db1ffb593709d117e0c35a 100644--- a/Source/WebKit/UIProcess/Launcher/glib/ProcessLauncherGLib.cpp+++ b/Source/WebKit/UIProcess/Launcher/glib/ProcessLauncherGLib.cpp@@ -168,6 +168,13 @@ void ProcessLauncher::launchProcess()@@ -15804,10 +15718,10 @@ index a108acd8a4503a07309fe8c54afc80b0f4175eae..1421d9a761042c31a6ecf3cc78ce3f0eBOOL result = ::CreateProcess(0, commandLine.data(), 0, 0, true, 0, 0, 0, &startupInfo, &processInformation);diff --git a/Source/WebKit/UIProcess/PageClient.h b/Source/WebKit/UIProcess/PageClient.h-index a5e7596eea86c6b7bdecf0a3adc906c3007a2f5d..2507c278685870936a6a26e9dd0d3474bcde51bc 100644+index 0cffbf89f6b402b9aaa65bf9edd7387f0aff65da..baa97c9400538243f96af3bde2482dbd3542b38d 100644--- a/Source/WebKit/UIProcess/PageClient.h+++ b/Source/WebKit/UIProcess/PageClient.h-@@ -75,6 +75,11 @@+@@ -74,6 +74,11 @@#include <WebCore/PlatformTextAlternatives.h>#endif@@ -15819,7 +15733,7 @@ index a5e7596eea86c6b7bdecf0a3adc906c3007a2f5d..2507c278685870936a6a26e9dd0d3474OBJC_CLASS AVPlayerViewController;OBJC_CLASS CALayer;OBJC_CLASS NSFileWrapper;-@@ -96,6 +101,12 @@ OBJC_CLASS WKView;+@@ -95,6 +100,12 @@ OBJC_CLASS WKView;#endif#endif@@ -15832,7 +15746,7 @@ index a5e7596eea86c6b7bdecf0a3adc906c3007a2f5d..2507c278685870936a6a26e9dd0d3474namespace API {class Attachment;class HitTestResult;-@@ -376,7 +387,20 @@ public:+@@ -380,7 +391,20 @@ public:virtual void selectionDidChange() = 0;#endif@@ -15987,7 +15901,7 @@ index 0000000000000000000000000000000000000000..a8a92a6c5f4b03724decc97828291f6f++#endif // ENABLE(FULLSCREEN_API)diff --git a/Source/WebKit/UIProcess/ProvisionalFrameProxy.cpp b/Source/WebKit/UIProcess/ProvisionalFrameProxy.cpp-index 3399db4087c395fbc516cc90f20f70d535a31c65..ec217611aa4a5823567c5cde84a211a2dcfb26be 100644+index 6a324ab3945475beed2774ab596645c72a6f658e..9045758645d48123c574a2ba7529a433c1a99f57 100644--- a/Source/WebKit/UIProcess/ProvisionalFrameProxy.cpp+++ b/Source/WebKit/UIProcess/ProvisionalFrameProxy.cpp@@ -25,6 +25,7 @@@@ -16306,7 +16220,7 @@ index 0000000000000000000000000000000000000000..6d04f9290135069359ce6bf872654648++#endif // ENABLE(REMOTE_INSPECTOR)diff --git a/Source/WebKit/UIProcess/WebContextMenuProxy.h b/Source/WebKit/UIProcess/WebContextMenuProxy.h-index c951d8577473371d8eb59ad651451737349c4389..b38cd0967ae45733a94594fd25900ddc1d49c3f6 100644+index 697a350812e1bf73dd44cc3d723a6a291f9d59d1..a8e1edd710d88f48632d51fd05aa964732d727d3 100644--- a/Source/WebKit/UIProcess/WebContextMenuProxy.h+++ b/Source/WebKit/UIProcess/WebContextMenuProxy.h@@ -49,6 +49,7 @@ public:@@ -16316,7 +16230,7 @@ index c951d8577473371d8eb59ad651451737349c4389..b38cd0967ae45733a94594fd25900ddc+ virtual void hide() {}WebPageProxy* page() const { return m_page.get(); }-+ RefPtr<WebPageProxy> protectedPage() const;diff --git a/Source/WebKit/UIProcess/WebPageInspectorEmulationAgent.cpp b/Source/WebKit/UIProcess/WebPageInspectorEmulationAgent.cppnew file mode 100644index 0000000000000000000000000000000000000000..0a8d10ae990997684766df46719c65aa8dd77f28@@ -17058,18 +16972,18 @@ index 0000000000000000000000000000000000000000..26a2a3c0791c334f811ec99a630314f8++} // namespace WebKitdiff --git a/Source/WebKit/UIProcess/WebPageProxy.cpp b/Source/WebKit/UIProcess/WebPageProxy.cpp-index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c65861c1847e8 100644+index 8596e12ab413647f88507c1bbfebcd5ca441a190..11ce2408b8358bc2ebe3abfc79c47662e991d7c0 100644--- a/Source/WebKit/UIProcess/WebPageProxy.cpp+++ b/Source/WebKit/UIProcess/WebPageProxy.cpp-@@ -200,6 +200,7 @@+@@ -203,6 +203,7 @@#include <WebCore/ArchiveError.h>#include <WebCore/BitmapImage.h>#include <WebCore/CaptureDeviceManager.h>+#include <WebCore/Color.h>#include <WebCore/CompositionHighlight.h>#include <WebCore/CrossSiteNavigationDataTransfer.h>- #include <WebCore/DOMPasteAccess.h>-@@ -210,6 +211,7 @@+ #include <WebCore/CryptoKey.h>+@@ -214,6 +215,7 @@#include <WebCore/DigitalCredentialRequestOptions.h>#include <WebCore/DigitalCredentialsRequestData.h>#include <WebCore/DigitalCredentialsResponseData.h>@@ -17077,7 +16991,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586#include <WebCore/DragController.h>#include <WebCore/DragData.h>#include <WebCore/ElementContext.h>-@@ -233,6 +235,7 @@+@@ -238,6 +240,7 @@#include <WebCore/ModalContainerTypes.h>#include <WebCore/NotImplemented.h>#include <WebCore/OrganizationStorageAccessPromptQuirk.h>@@ -17085,7 +16999,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586#include <WebCore/PerformanceLoggingClient.h>#include <WebCore/PermissionDescriptor.h>#include <WebCore/PermissionState.h>-@@ -240,10 +243,13 @@+@@ -245,10 +248,13 @@#include <WebCore/PublicSuffixStore.h>#include <WebCore/Quirks.h>#include <WebCore/RealtimeMediaSourceCenter.h>@@ -17099,7 +17013,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586#include <WebCore/SerializedCryptoKeyWrap.h>#include <WebCore/SerializedScriptValue.h>#include <WebCore/ShareData.h>-@@ -330,6 +336,9 @@+@@ -336,6 +342,9 @@#if USE(GBM)#include "AcceleratedBackingStoreDMABuf.h"#endif@@ -17109,7 +17023,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586#include <WebCore/SelectionData.h>#endif-@@ -455,6 +464,8 @@ static constexpr Seconds tryCloseTimeoutDelay = 50_ms;+@@ -461,6 +470,8 @@ static constexpr Seconds tryCloseTimeoutDelay = 50_ms;static constexpr Seconds audibleActivityClearDelay = 10_s;#endif@@ -17118,7 +17032,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586DEFINE_DEBUG_ONLY_GLOBAL(WTF::RefCountedLeakCounter, webPageProxyCounter, ("WebPageProxy"));#if PLATFORM(COCOA)-@@ -966,6 +977,10 @@ WebPageProxy::~WebPageProxy()+@@ -983,6 +994,10 @@ WebPageProxy::~WebPageProxy()#endifinternals().updatePlayingMediaDidChangeTimer.stop();@@ -17129,7 +17043,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586}Ref<WebPageProxy> WebPageProxy::Internals::protectedPage() const-@@ -1548,7 +1563,7 @@ void WebPageProxy::didAttachToRunningProcess()+@@ -1556,7 +1571,7 @@ void WebPageProxy::didAttachToRunningProcess()#if ENABLE(FULLSCREEN_API)ASSERT(!m_fullScreenManager);@@ -17138,7 +17052,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586#endif#if ENABLE(VIDEO_PRESENTATION_MODE)ASSERT(!m_playbackSessionManager);-@@ -1714,6 +1729,7 @@ void WebPageProxy::initializeWebPage(const Site& site, WebCore::SandboxFlags eff+@@ -1722,6 +1737,7 @@ void WebPageProxy::initializeWebPage(const Site& site, WebCore::SandboxFlags effif (preferences->siteIsolationEnabled())browsingContextGroup->addPage(*this);process->send(Messages::WebProcess::CreateWebPage(m_webPageID, creationParameters(process, *m_drawingArea, m_mainFrame->frameID(), std::nullopt)), 0);@@ -17146,7 +17060,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586#if ENABLE(WINDOW_PROXY_PROPERTY_ACCESS_NOTIFICATION)internals().frameLoadStateObserver = makeUniqueWithoutRefCountedCheck<WebPageProxyFrameLoadStateObserver>(*this);-@@ -2006,6 +2022,21 @@ Ref<WebProcessProxy> WebPageProxy::ensureProtectedRunningProcess()+@@ -1988,6 +2004,21 @@ Ref<WebProcessProxy> WebPageProxy::ensureProtectedRunningProcess()return ensureRunningProcess();}@@ -17168,18 +17082,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586RefPtr<API::Navigation> WebPageProxy::loadRequest(WebCore::ResourceRequest&& request, ShouldOpenExternalURLsPolicy shouldOpenExternalURLsPolicy, IsPerformingHTTPFallback isPerformingHTTPFallback, std::unique_ptr<NavigationActionData>&& lastNavigationAction, API::Object* userData){if (m_isClosed)-@@ -2062,8 +2093,8 @@ void WebPageProxy::loadRequestWithNavigationShared(Ref<WebProcessProxy>&& proces-- auto url = request.url();- #if PLATFORM(COCOA)-- bool urlIsInvalidButNotNull = !url.isValid() && !url.isNull();-- if (urlIsInvalidButNotNull && WTF::linkedOnOrAfterSDKWithBehavior(SDKAlignedBehavior::ConvertsInvalidURLsToNull)) {-+ bool urlIsInvalidButNotEmpty = !url.isValid() && !url.isEmpty();-+ if (urlIsInvalidButNotEmpty && WTF::linkedOnOrAfterSDKWithBehavior(SDKAlignedBehavior::ConvertsInvalidURLsToNull)) {- RunLoop::protectedMain()->dispatch([weakThis = WeakPtr { *this }, request, navigation = Ref { navigation }] {- RefPtr protectedThis = weakThis.get();- if (!protectedThis)-@@ -2116,11 +2147,29 @@ void WebPageProxy::loadRequestWithNavigationShared(Ref<WebProcessProxy>&& proces+@@ -2103,11 +2134,29 @@ void WebPageProxy::loadRequestWithNavigationShared(Ref<WebProcessProxy>&& procesnavigation->setIsLoadedWithNavigationShared(true);protectedProcess->markProcessAsRecentlyUsed();@@ -17213,7 +17116,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586});}-@@ -2671,6 +2720,61 @@ void WebPageProxy::setControlledByAutomation(bool controlled)+@@ -2661,6 +2710,63 @@ void WebPageProxy::setControlledByAutomation(bool controlled)protectedWebsiteDataStore()->protectedNetworkProcess()->send(Messages::NetworkProcess::SetSessionIsControlledByAutomation(m_websiteDataStore->sessionID(), m_controlledByAutomation), 0);}@@ -17269,13 +17172,15 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586++void WebPageProxy::logToStderr(const String& str)+{++WTF_ALLOW_UNSAFE_BUFFER_USAGE_BEGIN+ fprintf(stderr, "RENDERER: %s\n", str.utf8().data());++WTF_ALLOW_UNSAFE_BUFFER_USAGE_END+}+void WebPageProxy::createInspectorTarget(IPC::Connection& connection, const String& targetId, Inspector::InspectorTargetType type){MESSAGE_CHECK_BASE(!targetId.isEmpty(), connection);-@@ -2924,6 +3028,24 @@ void WebPageProxy::updateActivityState(OptionSet<ActivityState> flagsToUpdate)+@@ -2920,6 +3026,24 @@ void WebPageProxy::updateActivityState(OptionSet<ActivityState> flagsToUpdate)bool wasVisible = isViewVisible();RefPtr pageClient = this->pageClient();internals().activityState.remove(flagsToUpdate);@@ -17300,7 +17205,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586if (flagsToUpdate & ActivityState::IsFocused && pageClient->isViewFocused())internals().activityState.add(ActivityState::IsFocused);if (flagsToUpdate & ActivityState::WindowIsActive && pageClient->isViewWindowActive())-@@ -3706,7 +3828,7 @@ void WebPageProxy::performDragOperation(DragData& dragData, const String& dragSt+@@ -3683,7 +3807,7 @@ void WebPageProxy::performDragOperation(DragData& dragData, const String& dragStif (!hasRunningProcess())return;@@ -17309,7 +17214,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586URL url { dragData.asURL() };if (url.protocolIsFile())protectedLegacyMainFrameProcess()->assumeReadAccessToBaseURL(*this, url.string(), [] { });-@@ -3734,6 +3856,8 @@ void WebPageProxy::performDragControllerAction(DragControllerAction action, Drag+@@ -3711,6 +3835,8 @@ void WebPageProxy::performDragControllerAction(DragControllerAction action, Dragif (!hasRunningProcess())return;@@ -17318,7 +17223,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586auto completionHandler = [this, protectedThis = Ref { *this }, action, dragData] (std::optional<WebCore::DragOperation> dragOperation, WebCore::DragHandlingMethod dragHandlingMethod, bool mouseIsOverFileInput, unsigned numberOfItemsToBeAccepted, const IntRect& insertionRect, const IntRect& editableElementRect, std::optional<WebCore::RemoteUserInputEventData> remoteUserInputEventData) mutable {if (!m_pageClient)return;-@@ -3745,7 +3869,7 @@ void WebPageProxy::performDragControllerAction(DragControllerAction action, Drag+@@ -3722,7 +3848,7 @@ void WebPageProxy::performDragControllerAction(DragControllerAction action, DragdragData.setClientPosition(remoteUserInputEventData->transformedPoint);performDragControllerAction(action, dragData, remoteUserInputEventData->targetFrameID);};@@ -17327,7 +17232,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586ASSERT(dragData.platformData());sendWithAsyncReplyToProcessContainingFrame(frameID, Messages::WebPage::PerformDragControllerAction(action, dragData.clientPosition(), dragData.globalPosition(), dragData.draggingSourceOperationMask(), *dragData.platformData(), dragData.flags()), WTFMove(completionHandler));#else-@@ -3780,14 +3904,35 @@ void WebPageProxy::didPerformDragControllerAction(std::optional<WebCore::DragOpe+@@ -3757,14 +3883,35 @@ void WebPageProxy::didPerformDragControllerAction(std::optional<WebCore::DragOpesetDragCaretRect(insertionRect);if (RefPtr pageClient = this->pageClient())pageClient->didPerformDragControllerAction();@@ -17367,7 +17272,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586}didStartDrag();}-@@ -3809,6 +3954,24 @@ void WebPageProxy::dragEnded(const IntPoint& clientPosition, const IntPoint& glo+@@ -3786,6 +3933,24 @@ void WebPageProxy::dragEnded(const IntPoint& clientPosition, const IntPoint& glosetDragCaretRect({ });}@@ -17392,7 +17297,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586void WebPageProxy::didStartDrag(){if (!hasRunningProcess())-@@ -3816,6 +3979,26 @@ void WebPageProxy::didStartDrag()+@@ -3793,6 +3958,26 @@ void WebPageProxy::didStartDrag()discardQueuedMouseEvents();send(Messages::WebPage::DidStartDrag());@@ -17419,7 +17324,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586}void WebPageProxy::dragCancelled()-@@ -3981,26 +4164,47 @@ void WebPageProxy::processNextQueuedMouseEvent()+@@ -3958,26 +4143,47 @@ void WebPageProxy::processNextQueuedMouseEvent()process->startResponsivenessTimer();}@@ -17474,12 +17379,12 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586+ m_dragSelectionData = std::nullopt;+ dragEnded(event.position(), event.globalPosition(), m_dragSourceOperationMask);+ }-+ didReceiveEvent(eventType, true, std::nullopt);++ didReceiveEventIPC(process->connection(), eventType, true, std::nullopt);+ }}void WebPageProxy::doAfterProcessingAllPendingMouseEvents(WTF::Function<void ()>&& action)-@@ -4197,6 +4401,8 @@ void WebPageProxy::wheelEventHandlingCompleted(bool wasHandled)+@@ -4174,6 +4380,8 @@ void WebPageProxy::wheelEventHandlingCompleted(bool wasHandled)if (RefPtr automationSession = m_configuration->processPool().automationSession())automationSession->wheelEventsFlushedForPage(*this);@@ -17488,7 +17393,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586}void WebPageProxy::cacheWheelEventScrollingAccelerationCurve(const NativeWebWheelEvent& nativeWheelEvent)-@@ -4332,7 +4538,7 @@ static TrackingType mergeTrackingTypes(TrackingType a, TrackingType b)+@@ -4310,7 +4518,7 @@ static TrackingType mergeTrackingTypes(TrackingType a, TrackingType b)void WebPageProxy::updateTouchEventTracking(const WebTouchEvent& touchStartEvent){@@ -17497,7 +17402,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586for (auto& touchPoint : touchStartEvent.touchPoints()) {auto location = touchPoint.locationInRootView();auto update = [this, location](TrackingType& trackingType, EventTrackingRegions::EventType eventType) {-@@ -4971,6 +5177,7 @@ void WebPageProxy::receivedNavigationActionPolicyDecision(WebProcessProxy& proce+@@ -4972,6 +5180,7 @@ void WebPageProxy::receivedNavigationActionPolicyDecision(WebProcessProxy& procevoid WebPageProxy::receivedPolicyDecision(PolicyAction action, API::Navigation* navigation, RefPtr<API::WebsitePolicies>&& websitePolicies, Ref<API::NavigationAction>&& navigationAction, WillContinueLoadInNewProcess willContinueLoadInNewProcess, std::optional<SandboxExtension::Handle> sandboxExtensionHandle, std::optional<PolicyDecisionConsoleMessage>&& consoleMessage, CompletionHandler<void(PolicyDecision&&)>&& completionHandler){@@ -17505,7 +17410,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586if (!hasRunningProcess())return completionHandler(PolicyDecision { });-@@ -5967,6 +6174,7 @@ void WebPageProxy::viewScaleFactorDidChange(IPC::Connection& connection, double+@@ -5969,6 +6178,7 @@ void WebPageProxy::viewScaleFactorDidChange(IPC::Connection& connection, doubleMESSAGE_CHECK_BASE(scaleFactorIsValid(scaleFactor), connection);if (!legacyMainFrameProcess().hasConnection(connection))return;@@ -17513,15 +17418,15 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586forEachWebContentProcess([&] (auto& process, auto pageID) {if (&process == &legacyMainFrameProcess())-@@ -6609,6 +6817,7 @@ void WebPageProxy::didDestroyNavigationShared(Ref<WebProcessProxy>&& process, We+@@ -6606,6 +6816,7 @@ void WebPageProxy::didDestroyNavigationShared(Ref<WebProcessProxy>&& process, WeRefPtr protectedPageClient { pageClient() };protectedNavigationState()->didDestroyNavigation(process->coreProcessIdentifier(), navigationID);+ m_inspectorController->didDestroyNavigation(navigationID);}- void WebPageProxy::didStartProvisionalLoadForFrame(FrameIdentifier frameID, FrameInfoData&& frameInfo, ResourceRequest&& request, std::optional<WebCore::NavigationIdentifier> navigationID, URL&& url, URL&& unreachableURL, const UserData& userData, WallTime timestamp)-@@ -6947,6 +7156,8 @@ void WebPageProxy::didFailProvisionalLoadForFrameShared(Ref<WebProcessProxy>&& p+ void WebPageProxy::didStartProvisionalLoadForFrame(IPC::Connection& connection, FrameIdentifier frameID, FrameInfoData&& frameInfo, ResourceRequest&& request, std::optional<WebCore::NavigationIdentifier> navigationID, URL&& url, URL&& unreachableURL, const UserData& userData, WallTime timestamp)+@@ -6947,6 +7158,8 @@ void WebPageProxy::didFailProvisionalLoadForFrameShared(Ref<WebProcessProxy>&& pm_failingProvisionalLoadURL = { };@@ -17530,7 +17435,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586// If the provisional page's load fails then we destroy the provisional page.if (m_provisionalPage && m_provisionalPage->mainFrame() == &frame && willContinueLoading == WillContinueLoading::No)m_provisionalPage = nullptr;-@@ -8395,8 +8606,9 @@ void WebPageProxy::createNewPage(IPC::Connection& connection, WindowFeatures&& w+@@ -8405,8 +8618,9 @@ void WebPageProxy::createNewPage(IPC::Connection& connection, WindowFeatures&& wif (RefPtr page = originatingFrameInfo->page())openerAppInitiatedState = page->lastNavigationWasAppInitiated();@@ -17541,7 +17446,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586auto completionHandler = [this,protectedThis = Ref { *this },-@@ -8469,6 +8681,7 @@ void WebPageProxy::createNewPage(IPC::Connection& connection, WindowFeatures&& w+@@ -8486,6 +8700,7 @@ void WebPageProxy::createNewPage(IPC::Connection& connection, WindowFeatures&& wconfiguration->setOpenedMainFrameName(openedMainFrameName);if (!protectedPreferences()->siteIsolationEnabled())configuration->setRelatedPage(*this);@@ -17549,7 +17454,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586if (RefPtr openerFrame = WebFrameProxy::webFrame(originatingFrameInfoData.frameID); navigationActionData.hasOpener && openerFrame) {configuration->setOpenerInfo({ {-@@ -8491,6 +8704,7 @@ void WebPageProxy::createNewPage(IPC::Connection& connection, WindowFeatures&& w+@@ -8514,6 +8729,7 @@ void WebPageProxy::createNewPage(IPC::Connection& connection, WindowFeatures&& wvoid WebPageProxy::showPage(){m_uiClient->showPage(this);@@ -17557,7 +17462,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586}bool WebPageProxy::hasOpenedPage() const-@@ -8622,6 +8836,10 @@ void WebPageProxy::closePage()+@@ -8645,6 +8861,10 @@ void WebPageProxy::closePage()if (isClosed())return;@@ -17568,7 +17473,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586WEBPAGEPROXY_RELEASE_LOG(Process, "closePage:");if (RefPtr pageClient = this->pageClient())pageClient->clearAllEditCommands();-@@ -8660,6 +8878,8 @@ void WebPageProxy::runJavaScriptAlert(IPC::Connection& connection, FrameIdentifi+@@ -8683,6 +8903,8 @@ void WebPageProxy::runJavaScriptAlert(IPC::Connection& connection, FrameIdentifi}runModalJavaScriptDialog(WTFMove(frame), WTFMove(frameInfo), message, [reply = WTFMove(reply)](WebPageProxy& page, WebFrameProxy* frame, FrameInfoData&& frameInfo, const String& message, CompletionHandler<void()>&& completion) mutable {@@ -17577,7 +17482,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586page.m_uiClient->runJavaScriptAlert(page, message, frame, WTFMove(frameInfo), [reply = WTFMove(reply), completion = WTFMove(completion)]() mutable {reply();completion();-@@ -8682,6 +8902,8 @@ void WebPageProxy::runJavaScriptConfirm(IPC::Connection& connection, FrameIdenti+@@ -8705,6 +8927,8 @@ void WebPageProxy::runJavaScriptConfirm(IPC::Connection& connection, FrameIdentiif (RefPtr automationSession = configuration().processPool().automationSession())automationSession->willShowJavaScriptDialog(*this);}@@ -17586,7 +17491,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586runModalJavaScriptDialog(WTFMove(frame), WTFMove(frameInfo), message, [reply = WTFMove(reply)](WebPageProxy& page, WebFrameProxy* frame, FrameInfoData&& frameInfo, const String& message, CompletionHandler<void()>&& completion) mutable {page.m_uiClient->runJavaScriptConfirm(page, message, frame, WTFMove(frameInfo), [reply = WTFMove(reply), completion = WTFMove(completion)](bool result) mutable {-@@ -8706,6 +8928,8 @@ void WebPageProxy::runJavaScriptPrompt(IPC::Connection& connection, FrameIdentif+@@ -8729,6 +8953,8 @@ void WebPageProxy::runJavaScriptPrompt(IPC::Connection& connection, FrameIdentifif (RefPtr automationSession = configuration().processPool().automationSession())automationSession->willShowJavaScriptDialog(*this);}@@ -17595,7 +17500,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586runModalJavaScriptDialog(WTFMove(frame), WTFMove(frameInfo), message, [reply = WTFMove(reply), defaultValue](WebPageProxy& page, WebFrameProxy* frame, FrameInfoData&& frameInfo, const String& message, CompletionHandler<void()>&& completion) mutable {page.m_uiClient->runJavaScriptPrompt(page, message, defaultValue, frame, WTFMove(frameInfo), [reply = WTFMove(reply), completion = WTFMove(completion)](auto& result) mutable {-@@ -8841,6 +9065,8 @@ void WebPageProxy::runBeforeUnloadConfirmPanel(IPC::Connection& connection, Fram+@@ -8864,6 +9090,8 @@ void WebPageProxy::runBeforeUnloadConfirmPanel(IPC::Connection& connection, Framreturn;}}@@ -17603,8 +17508,8 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586+ m_inspectorDialogAgent->javascriptDialogOpening("beforeunload"_s, message);// Since runBeforeUnloadConfirmPanel() can spin a nested run loop we need to turn off the responsiveness timer and the tryClose timer.- protectedLegacyMainFrameProcess()->stopResponsivenessTimer();-@@ -9454,6 +9680,11 @@ void WebPageProxy::resourceLoadDidCompleteWithError(ResourceLoadInfo&& loadInfo,+ WebProcessProxy::fromConnection(connection)->stopResponsivenessTimer();+@@ -9481,6 +9709,11 @@ void WebPageProxy::resourceLoadDidCompleteWithError(ResourceLoadInfo&& loadInfo,}#if ENABLE(FULLSCREEN_API)@@ -17616,7 +17521,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586WebFullScreenManagerProxy* WebPageProxy::fullScreenManager(){return m_fullScreenManager.get();-@@ -9576,6 +9807,17 @@ void WebPageProxy::requestDOMPasteAccess(DOMPasteAccessCategory pasteAccessCateg+@@ -9608,6 +9841,17 @@ void WebPageProxy::requestDOMPasteAccess(IPC::Connection& connection, DOMPasteAc}}@@ -17634,7 +17539,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586protectedPageClient()->requestDOMPasteAccess(pasteAccessCategory, requiresInteraction, elementRect, originIdentifier, WTFMove(completionHandler));}-@@ -10605,6 +10847,8 @@ void WebPageProxy::mouseEventHandlingCompleted(std::optional<WebEventType> event+@@ -10634,6 +10878,8 @@ void WebPageProxy::mouseEventHandlingCompleted(std::optional<WebEventType> eventif (RefPtr automationSession = configuration().processPool().automationSession())automationSession->mouseEventsFlushedForPage(*this);didFinishProcessingAllPendingMouseEvents();@@ -17643,7 +17548,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586}}-@@ -10640,6 +10884,7 @@ void WebPageProxy::keyEventHandlingCompleted(std::optional<WebEventType> eventTy+@@ -10669,6 +10915,7 @@ void WebPageProxy::keyEventHandlingCompleted(std::optional<WebEventType> eventTyif (!canProcessMoreKeyEvents) {if (RefPtr automationSession = configuration().processPool().automationSession())automationSession->keyboardEventsFlushedForPage(*this);@@ -17651,7 +17556,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586}}-@@ -11064,7 +11309,10 @@ void WebPageProxy::dispatchProcessDidTerminate(WebProcessProxy& process, Process+@@ -11101,7 +11348,10 @@ void WebPageProxy::dispatchProcessDidTerminate(WebProcessProxy& process, Processif (protectedPreferences()->siteIsolationEnabled())protectedBrowsingContextGroup()->processDidTerminate(*this, process);@@ -17663,7 +17568,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586if (m_loaderClient)handledByClient = reason != ProcessTerminationReason::RequestedByClient && m_loaderClient->processDidCrash(*this);else-@@ -11719,6 +11967,8 @@ WebPageCreationParameters WebPageProxy::creationParameters(WebProcessProxy& proc+@@ -11752,6 +12002,8 @@ WebPageCreationParameters WebPageProxy::creationParameters(WebProcessProxy& procparameters.canUseCredentialStorage = m_canUseCredentialStorage;parameters.httpsUpgradeEnabled = preferences->upgradeKnownHostsToHTTPSEnabled() ? m_configuration->httpsUpgradeEnabled() : false;@@ -17672,7 +17577,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586#if ENABLE(APP_HIGHLIGHTS)parameters.appHighlightsVisible = appHighlightsVisibility() ? HighlightVisibility::Visible : HighlightVisibility::Hidden;-@@ -11882,8 +12132,42 @@ void WebPageProxy::allowGamepadAccess()+@@ -11917,8 +12169,42 @@ void WebPageProxy::allowGamepadAccess()#endif // ENABLE(GAMEPAD)@@ -17715,7 +17620,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586if (negotiatedLegacyTLS == NegotiatedLegacyTLS::Yes) {m_navigationClient->shouldAllowLegacyTLS(*this, authenticationChallenge.get(), [this, protectedThis = Ref { *this }, authenticationChallenge] (bool shouldAllowLegacyTLS) {if (shouldAllowLegacyTLS)-@@ -11979,6 +12263,12 @@ void WebPageProxy::requestGeolocationPermissionForFrame(IPC::Connection& connect+@@ -12014,6 +12300,12 @@ void WebPageProxy::requestGeolocationPermissionForFrame(IPC::Connection& connectrequest->deny();};@@ -17728,7 +17633,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586// FIXME: Once iOS migrates to the new WKUIDelegate SPI, clean this up// and make it one UIClient call that calls the completionHandler with false// if there is no delegate instead of returning the completionHandler-@@ -12043,6 +12333,12 @@ void WebPageProxy::queryPermission(const ClientOrigin& clientOrigin, const Permi+@@ -12078,6 +12370,12 @@ void WebPageProxy::queryPermission(const ClientOrigin& clientOrigin, const PermishouldChangeDeniedToPrompt = false;if (sessionID().isEphemeral()) {@@ -17741,7 +17646,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586completionHandler(shouldChangeDeniedToPrompt ? PermissionState::Prompt : PermissionState::Denied);return;}-@@ -12057,6 +12353,12 @@ void WebPageProxy::queryPermission(const ClientOrigin& clientOrigin, const Permi+@@ -12092,6 +12390,12 @@ void WebPageProxy::queryPermission(const ClientOrigin& clientOrigin, const Permireturn;}@@ -17755,7 +17660,7 @@ index 92eef3dd76340b6f1761c0bfbe6e7a0896f532f2..daae2e0dfdddf8d44b075b2ddc6c6586completionHandler(shouldChangeDeniedToPrompt ? PermissionState::Prompt : PermissionState::Denied);return;diff --git a/Source/WebKit/UIProcess/WebPageProxy.h b/Source/WebKit/UIProcess/WebPageProxy.h-index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1650efbe6 100644+index de568bc247847234de4bd8a34d80726a4fa22a53..85881e1a1a695907016c0924e3df38f072455f61 100644--- a/Source/WebKit/UIProcess/WebPageProxy.h+++ b/Source/WebKit/UIProcess/WebPageProxy.h@@ -26,6 +26,7 @@@@ -17795,7 +17700,7 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1class FloatRect;class FloatSize;class FontAttributeChanges;-@@ -729,6 +745,8 @@ public:+@@ -734,6 +750,8 @@ public:void setControlledByAutomation(bool);WebPageInspectorController& inspectorController() { return *m_inspectorController; }@@ -17804,15 +17709,15 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1#if PLATFORM(IOS_FAMILY)void showInspectorIndication();-@@ -763,6 +781,7 @@ public:+@@ -767,6 +785,7 @@ public:bool hasSleepDisabler() const;#if ENABLE(FULLSCREEN_API)+ void setFullScreenManagerClientOverride(std::unique_ptr<WebFullScreenManagerProxyClient>&&);WebFullScreenManagerProxy* fullScreenManager();+ RefPtr<WebFullScreenManagerProxy> protectedFullScreenManager();void setFullScreenClientForTesting(std::unique_ptr<WebKit::WebFullScreenManagerProxyClient>&&);--@@ -853,6 +872,12 @@ public:+@@ -858,6 +877,12 @@ public:void setPageLoadStateObserver(RefPtr<PageLoadStateObserverBase>&&);@@ -17825,7 +17730,7 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1void initializeWebPage(const WebCore::Site&, WebCore::SandboxFlags);void setDrawingArea(RefPtr<DrawingAreaProxy>&&);-@@ -884,6 +909,8 @@ public:+@@ -889,6 +914,8 @@ public:RefPtr<API::Navigation> loadRequest(WebCore::ResourceRequest&&, WebCore::ShouldOpenExternalURLsPolicy, WebCore::IsPerformingHTTPFallback);RefPtr<API::Navigation> loadRequest(WebCore::ResourceRequest&&, WebCore::ShouldOpenExternalURLsPolicy, WebCore::IsPerformingHTTPFallback, std::unique_ptr<NavigationActionData>&&, API::Object* userData = nullptr);@@ -17834,7 +17739,7 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1RefPtr<API::Navigation> loadFile(const String& fileURL, const String& resourceDirectoryURL, bool isAppInitiated = true, API::Object* userData = nullptr);RefPtr<API::Navigation> loadData(Ref<WebCore::SharedBuffer>&&, const String& MIMEType, const String& encoding, const String& baseURL, API::Object* userData = nullptr);RefPtr<API::Navigation> loadData(Ref<WebCore::SharedBuffer>&&, const String& MIMEType, const String& encoding, const String& baseURL, API::Object* userData, WebCore::ShouldOpenExternalURLsPolicy);-@@ -972,6 +999,7 @@ public:+@@ -977,6 +1004,7 @@ public:PageClient* pageClient() const;RefPtr<PageClient> protectedPageClient() const;@@ -17842,7 +17747,7 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1void setViewNeedsDisplay(const WebCore::Region&);void requestScroll(const WebCore::FloatPoint& scrollPosition, const WebCore::IntPoint& scrollOrigin, WebCore::ScrollIsAnimated);-@@ -1609,14 +1637,20 @@ public:+@@ -1617,14 +1645,20 @@ public:void didStartDrag();void dragCancelled();void setDragCaretRect(const WebCore::IntRect&);@@ -17864,7 +17769,7 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1#endifvoid processDidBecomeUnresponsive();-@@ -1869,6 +1903,7 @@ public:+@@ -1877,6 +1911,7 @@ public:void setViewportSizeForCSSViewportUnits(const WebCore::FloatSize&);WebCore::FloatSize viewportSizeForCSSViewportUnits() const;@@ -17872,7 +17777,7 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1void didReceiveAuthenticationChallengeProxy(Ref<AuthenticationChallengeProxy>&&, NegotiatedLegacyTLS);void negotiatedLegacyTLS();void didNegotiateModernTLS(const URL&);-@@ -1902,6 +1937,8 @@ public:+@@ -1910,6 +1945,8 @@ public:#if PLATFORM(COCOA) || PLATFORM(GTK)RefPtr<ViewSnapshot> takeViewSnapshot(std::optional<WebCore::IntRect>&&);RefPtr<ViewSnapshot> takeViewSnapshot(std::optional<WebCore::IntRect>&&, ForceSoftwareCapturingViewportSnapshot);@@ -17880,8 +17785,8 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1+ RefPtr<ViewSnapshot> takeViewSnapshot(std::optional<WebCore::IntRect>&&) { return nullptr; }#endif- void wrapCryptoKey(Vector<uint8_t>&&, CompletionHandler<void(std::optional<Vector<uint8_t>>&&)>&&);-@@ -2901,6 +2938,7 @@ private:+ void serializeAndWrapCryptoKey(IPC::Connection&, WebCore::CryptoKeyData&&, CompletionHandler<void(std::optional<Vector<uint8_t>>&&)>&&);+@@ -2919,6 +2956,7 @@ private:RefPtr<API::Navigation> launchProcessForReload();void requestNotificationPermission(const String& originString, CompletionHandler<void(bool allowed)>&&);@@ -17889,7 +17794,7 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1void didChangeContentSize(const WebCore::IntSize&);void didChangeIntrinsicContentSize(const WebCore::IntSize&);-@@ -3424,8 +3462,10 @@ RefPtr<SpeechRecognitionPermissionManager> protectedSpeechRecognitionPermissionM+@@ -3436,8 +3474,10 @@ private:String m_openedMainFrameName;RefPtr<WebInspectorUIProxy> m_inspector;@@ -17900,7 +17805,7 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1RefPtr<WebFullScreenManagerProxy> m_fullScreenManager;std::unique_ptr<API::FullscreenClient> m_fullscreenClient;#endif-@@ -3622,6 +3662,22 @@ RefPtr<SpeechRecognitionPermissionManager> protectedSpeechRecognitionPermissionM+@@ -3636,6 +3676,22 @@ private:std::optional<WebCore::DragOperation> m_currentDragOperation;bool m_currentDragIsOverFileInput { false };unsigned m_currentDragNumberOfFilesToBeAccepted { 0 };@@ -17923,7 +17828,7 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1#endifbool m_mainFrameHasHorizontalScrollbar { false };-@@ -3795,6 +3851,10 @@ RefPtr<SpeechRecognitionPermissionManager> protectedSpeechRecognitionPermissionM+@@ -3807,6 +3863,10 @@ private:RefPtr<API::Object> messageBody;};Vector<InjectedBundleMessage> m_pendingInjectedBundleMessages;@@ -17935,7 +17840,7 @@ index 5eb0a3d277ecd9a0ea9c2e4f1223205bff9cb5a4..b770b73fb96af5dd106c8e66d02590c1#if PLATFORM(IOS_FAMILY) && ENABLE(DEVICE_ORIENTATION)RefPtr<WebDeviceOrientationUpdateProviderProxy> m_webDeviceOrientationUpdateProviderProxy;diff --git a/Source/WebKit/UIProcess/WebPageProxy.messages.in b/Source/WebKit/UIProcess/WebPageProxy.messages.in-index d1b9a0bec55cf3c64792b6c0c527c973a6ef3cdd..4b132c98aabe3dffef13b01e6251bdb7305ce200 100644+index 0310e26fe8eb09a68db493035b108aa472dc573d..0182474dd3cb70bc87f239718ad52db972cc44ae 100644--- a/Source/WebKit/UIProcess/WebPageProxy.messages.in+++ b/Source/WebKit/UIProcess/WebPageProxy.messages.in@@ -35,6 +35,7 @@ messages -> WebPageProxy {@@ -17944,9 +17849,9 @@ index d1b9a0bec55cf3c64792b6c0c527c973a6ef3cdd..4b132c98aabe3dffef13b01e6251bdb7MouseDidMoveOverElement(struct WebKit::WebHitTestResultData hitTestResultData, OptionSet<WebKit::WebEventModifier> modifiers, WebKit::UserData userData)+ LogToStderr(String text)- DidReceiveEvent(enum:uint8_t WebKit::WebEventType eventType, bool handled, struct std::optional<WebCore::RemoteUserInputEventData> remoteUserInputEventData)+ DidReceiveEventIPC(enum:uint8_t WebKit::WebEventType eventType, bool handled, struct std::optional<WebCore::RemoteUserInputEventData> remoteUserInputEventData)SetCursor(WebCore::Cursor cursor)-@@ -336,10 +337,14 @@ messages -> WebPageProxy {+@@ -333,10 +334,14 @@ messages -> WebPageProxy {StartDrag(struct WebCore::DragItem dragItem, WebCore::ShareableBitmapHandle dragImage)SetPromisedDataForImage(String pasteboardName, WebCore::SharedMemory::Handle imageHandle, String filename, String extension, String title, String url, String visibleURL, WebCore::SharedMemory::Handle archiveHandle, String originIdentifier)#endif@@ -17963,7 +17868,7 @@ index d1b9a0bec55cf3c64792b6c0c527c973a6ef3cdd..4b132c98aabe3dffef13b01e6251bdb7DidHandleDragStartRequest(bool started)DidHandleAdditionalDragItemsRequest(bool added)diff --git a/Source/WebKit/UIProcess/WebProcessCache.cpp b/Source/WebKit/UIProcess/WebProcessCache.cpp-index 9153b4da4d4f8de14f27e9ee2e8c89059e9573f5..035009bdcf5651aedd9604e47dc02fbfcccc62a9 100644+index dc6f440403cccc5cd93f75806cffbf05cc56041c..e880beba2034cc2b87dcfb3e1e8bacf1bed78cf3 100644--- a/Source/WebKit/UIProcess/WebProcessCache.cpp+++ b/Source/WebKit/UIProcess/WebProcessCache.cpp@@ -100,6 +100,10 @@ bool WebProcessCache::canCacheProcess(WebProcessProxy& process) const@@ -17978,7 +17883,7 @@ index 9153b4da4d4f8de14f27e9ee2e8c89059e9573f5..035009bdcf5651aedd9604e47dc02fbf}diff --git a/Source/WebKit/UIProcess/WebProcessPool.cpp b/Source/WebKit/UIProcess/WebProcessPool.cpp-index c035cc55b3810bef6d30b753ee325905d8fbc6ab..d129f7ebbf7a9a5e97e09fd7ce6e58040a960abc 100644+index 4be8b8ead49ba2ab0ce16af74aa92fab01352358..8e310f0e3bcada1ec9383161b979660e29c50724 100644--- a/Source/WebKit/UIProcess/WebProcessPool.cpp+++ b/Source/WebKit/UIProcess/WebProcessPool.cpp@@ -445,10 +445,10 @@ void WebProcessPool::setAutomationClient(std::unique_ptr<API::AutomationClient>&@@ -18006,7 +17911,7 @@ index c035cc55b3810bef6d30b753ee325905d8fbc6ab..d129f7ebbf7a9a5e97e09fd7ce6e5804void WebProcessPool::fullKeyboardAccessModeChanged(bool fullKeyboardAccessEnabled){-@@ -947,7 +948,7 @@ void WebProcessPool::initializeNewWebProcess(WebProcessProxy& process, WebsiteDa+@@ -939,7 +940,7 @@ void WebProcessPool::initializeNewWebProcess(WebProcessProxy& process, WebsiteDa#endifparameters.cacheModel = LegacyGlobalSettings::singleton().cacheModel();@@ -18016,10 +17921,10 @@ index c035cc55b3810bef6d30b753ee325905d8fbc6ab..d129f7ebbf7a9a5e97e09fd7ce6e5804parameters.urlSchemesRegisteredAsEmptyDocument = copyToVector(m_schemesToRegisterAsEmptyDocument);diff --git a/Source/WebKit/UIProcess/WebProcessProxy.cpp b/Source/WebKit/UIProcess/WebProcessProxy.cpp-index 1ac3aeb44691040950f6992d77e6489d9c58744f..3b4ebb055f9d9e7b3c64bfbf830239a7d1baf770 100644+index 45a11c271082cd40635c6b21ee01c75bea749a4b..4ba89b3eafebfa67d8518ec99db6f23ae968df29 100644--- a/Source/WebKit/UIProcess/WebProcessProxy.cpp+++ b/Source/WebKit/UIProcess/WebProcessProxy.cpp-@@ -201,6 +201,11 @@ Vector<Ref<WebProcessProxy>> WebProcessProxy::allProcesses()+@@ -203,6 +203,11 @@ Vector<Ref<WebProcessProxy>> WebProcessProxy::allProcesses()});}@@ -18031,7 +17936,7 @@ index 1ac3aeb44691040950f6992d77e6489d9c58744f..3b4ebb055f9d9e7b3c64bfbf830239a7RefPtr<WebProcessProxy> WebProcessProxy::processForIdentifier(ProcessIdentifier identifier){return allProcessMap().get(identifier);-@@ -568,6 +573,26 @@ void WebProcessProxy::getLaunchOptions(ProcessLauncher::LaunchOptions& launchOpt+@@ -572,6 +577,26 @@ void WebProcessProxy::getLaunchOptions(ProcessLauncher::LaunchOptions& launchOptif (WebKit::isInspectorProcessPool(protectedProcessPool()))launchOptions.extraInitializationData.add<HashTranslatorASCIILiteral>("inspector-process"_s, "1"_s);@@ -18059,10 +17964,10 @@ index 1ac3aeb44691040950f6992d77e6489d9c58744f..3b4ebb055f9d9e7b3c64bfbf830239a7if (isPrewarmed())diff --git a/Source/WebKit/UIProcess/WebProcessProxy.h b/Source/WebKit/UIProcess/WebProcessProxy.h-index b82965d62515b10373be40b28e4ba567821d5994..e05268412a251474c64fc4b3bafa25363bc87057 100644+index 4471fdf4a46180f78cea1cf035671bfe3c83b8e2..0858fe7f56eb3d8648467f5b82c2d77d6c958b77 100644--- a/Source/WebKit/UIProcess/WebProcessProxy.h+++ b/Source/WebKit/UIProcess/WebProcessProxy.h-@@ -184,6 +184,7 @@ public:+@@ -185,6 +185,7 @@ public:static void forWebPagesWithOrigin(PAL::SessionID, const WebCore::SecurityOriginData&, NOESCAPE const Function<void(WebPageProxy&)>&);static Vector<std::pair<WebCore::ProcessIdentifier, WebCore::RegistrableDomain>> allowedFirstPartiesForCookies();@@ -18071,10 +17976,10 @@ index b82965d62515b10373be40b28e4ba567821d5994..e05268412a251474c64fc4b3bafa2536void initializeWebProcess(WebProcessCreationParameters&&);diff --git a/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp b/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp-index 7b9780cb47d824cc47054333aad47754d6a0725c..34bb946afd3de5354e5a3759506537d2dd1af586 100644+index ef4db4e5e75286a260646226dd48108810b1607e..bf1111ed48e9d3cb74b59d4258faefb814028540 100644--- a/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp+++ b/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp-@@ -314,7 +314,8 @@ SOAuthorizationCoordinator& WebsiteDataStore::soAuthorizationCoordinator(const W+@@ -319,7 +319,8 @@ SOAuthorizationCoordinator& WebsiteDataStore::soAuthorizationCoordinator(const Wstatic Ref<NetworkProcessProxy> networkProcessForSession(PAL::SessionID sessionID){@@ -18084,7 +17989,7 @@ index 7b9780cb47d824cc47054333aad47754d6a0725c..34bb946afd3de5354e5a3759506537d2if (sessionID.isEphemeral()) {// Reuse a previous persistent session network process for ephemeral sessions.for (auto& dataStore : allDataStores().values()) {-@@ -2507,6 +2508,12 @@ void WebsiteDataStore::originDirectoryForTesting(WebCore::ClientOrigin&& origin,+@@ -2511,6 +2512,12 @@ void WebsiteDataStore::originDirectoryForTesting(WebCore::ClientOrigin&& origin,protectedNetworkProcess()->websiteDataOriginDirectoryForTesting(m_sessionID, WTFMove(origin), type, WTFMove(completionHandler));}@@ -18098,7 +18003,7 @@ index 7b9780cb47d824cc47054333aad47754d6a0725c..34bb946afd3de5354e5a3759506537d2void WebsiteDataStore::hasAppBoundSession(CompletionHandler<void(bool)>&& completionHandler) const{diff --git a/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.h b/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.h-index 0439774485211a729ccd8b0c041c41547ea28625..e09aff8b56357687de4a417b1bdd644907bb8c23 100644+index f1a113cc08f6543ab22be75a03823f49a3f52017..3d98a33003ae86f2ac5982ba2deb5eb3238b1385 100644--- a/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.h+++ b/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.h@@ -98,6 +98,7 @@ class DeviceIdHashSaltStorage;@@ -18132,7 +18037,7 @@ index 0439774485211a729ccd8b0c041c41547ea28625..e09aff8b56357687de4a417b1bdd6449class WebsiteDataStore : public API::ObjectImpl<API::Object::Type::WebsiteDataStore>, public CanMakeWeakPtr<WebsiteDataStore> {public:static Ref<WebsiteDataStore> defaultDataStore();-@@ -319,11 +329,13 @@ public:+@@ -318,11 +328,13 @@ public:const WebCore::CurlProxySettings& networkProxySettings() const { return m_proxySettings; }#endif@@ -18160,7 +18065,7 @@ index 0439774485211a729ccd8b0c041c41547ea28625..e09aff8b56357687de4a417b1bdd6449void resetQuota(CompletionHandler<void()>&&);void resetStoragePersistedState(CompletionHandler<void()>&&);#if PLATFORM(IOS_FAMILY)-@@ -614,9 +632,11 @@ private:+@@ -616,9 +634,11 @@ private:WebCore::CurlProxySettings m_proxySettings;#endif@@ -18173,7 +18078,7 @@ index 0439774485211a729ccd8b0c041c41547ea28625..e09aff8b56357687de4a417b1bdd6449WebCore::SoupNetworkProxySettings m_networkProxySettings;String m_cookiePersistentStoragePath;SoupCookiePersistentStorageType m_cookiePersistentStorageType { SoupCookiePersistentStorageType::SQLite };-@@ -643,6 +663,10 @@ private:+@@ -645,6 +665,10 @@ private:RefPtr<API::HTTPCookieStore> m_cookieStore;RefPtr<NetworkProcessProxy> m_networkProcess;@@ -18185,7 +18090,7 @@ index 0439774485211a729ccd8b0c041c41547ea28625..e09aff8b56357687de4a417b1bdd6449std::unique_ptr<SOAuthorizationCoordinator> m_soAuthorizationCoordinator;#endifdiff --git a/Source/WebKit/UIProcess/geoclue/GeoclueGeolocationProvider.cpp b/Source/WebKit/UIProcess/geoclue/GeoclueGeolocationProvider.cpp-index ac64c2a3cb5d1e8e46ba1835623a5c12825e3ea1..6ad7a5adc5198ae035c5cb815b6db8f033910f3a 100644+index 19934de3173ecc0507c5e59956bcf6730a8a88b4..bc0e52f6f28caeca8b9b7aab14b7ff991d7e6b41 100644--- a/Source/WebKit/UIProcess/geoclue/GeoclueGeolocationProvider.cpp+++ b/Source/WebKit/UIProcess/geoclue/GeoclueGeolocationProvider.cpp@@ -114,6 +114,14 @@ void GeoclueGeolocationProvider::stop()@@ -18500,6 +18405,31 @@ index 0000000000000000000000000000000000000000..441442d899e4088f5c24ae9f70c3e4ff+} // namespace API++#endif // ENABLE(REMOTE_INSPECTOR)+diff --git a/Source/WebKit/UIProcess/glib/SystemSettingsManagerProxy.cpp b/Source/WebKit/UIProcess/glib/SystemSettingsManagerProxy.cpp+index c6e25e57892c2a0e1350b207ce53b6d2c3d6258a..bd91f75db5a05ba0a6f5a982c03980ecc57479ca 100644+--- a/Source/WebKit/UIProcess/glib/SystemSettingsManagerProxy.cpp++++ b/Source/WebKit/UIProcess/glib/SystemSettingsManagerProxy.cpp+@@ -27,6 +27,7 @@+ #include "config.h"+ #include "SystemSettingsManagerProxy.h"+++#include "SystemSettingsManager.h"+ #include "SystemSettingsManagerMessages.h"+ #include "WebProcessPool.h"+ #include <WebCore/SystemSettings.h>+diff --git a/Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp b/Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp+index 51ba8b585ca37a2eed54bce5218e1c92c2844cc6..dc04a2ca0b0ac2333036b897dd18d5303c5237c6 100644+--- a/Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp++++ b/Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp+@@ -124,6 +124,8 @@ static OptionSet<AvailableInputDevices> availableInputDevices()+ return toAvailableInputDevices(gdk_seat_get_capabilities(seat));+ }+ #endif++ if (!WebCore::screenHasTouchDeviceOverride() || !WebCore::screenHasTouchDeviceOverride().value())++ return AvailableInputDevices::Mouse;+ #if ENABLE(TOUCH_EVENTS)+ return AvailableInputDevices::Touchscreen;+ #elsediff --git a/Source/WebKit/UIProcess/gtk/AcceleratedBackingStore.h b/Source/WebKit/UIProcess/gtk/AcceleratedBackingStore.hindex 5529f52048b24290f424e877cd9dbfb890e02ffb..c2b76b6188dd9596c4a1f31c137daff7d7644c7f 100644--- a/Source/WebKit/UIProcess/gtk/AcceleratedBackingStore.h@@ -18522,7 +18452,7 @@ index 5529f52048b24290f424e877cd9dbfb890e02ffb..c2b76b6188dd9596c4a1f31c137daff7virtual void unrealize() { };virtual int renderHostFileDescriptor() { return -1; }diff --git a/Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreDMABuf.cpp b/Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreDMABuf.cpp-index 461ce4fddb98edbf06be61d4b47f3256439f70a8..64b0c2e09a1ae8487bc8b2610f209a228a6988f6 100644+index 395a409b6302d4146606fc0b45a15cff63c7f327..666d9629e0155e8c03b0672f7a9274de7f04d642 100644--- a/Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreDMABuf.cpp+++ b/Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreDMABuf.cpp@@ -812,4 +812,30 @@ RefPtr<WebCore::NativeImage> AcceleratedBackingStoreDMABuf::bufferAsNativeImageF@@ -18557,7 +18487,7 @@ index 461ce4fddb98edbf06be61d4b47f3256439f70a8..64b0c2e09a1ae8487bc8b2610f209a22+} // namespace WebKitdiff --git a/Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreDMABuf.h b/Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreDMABuf.h-index aedb88b1031475a603b6d15eb4fc042153c9b8c1..e6aca4b0e577dd2c729d262ff9b3d4d8fb27ef23 100644+index 63dfbed03bd898c822d426a5449141fec2841226..eaf141843da3f02c5ba6fd0322f3175248a7195b 100644--- a/Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreDMABuf.h+++ b/Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreDMABuf.h@@ -98,6 +98,7 @@ private:@@ -18570,7 +18500,7 @@ index aedb88b1031475a603b6d15eb4fc042153c9b8c1..e6aca4b0e577dd2c729d262ff9b3d4d8RendererBufferFormat bufferFormat() const override;@@ -253,6 +254,9 @@ private:RefPtr<Buffer> m_committedBuffer;- WebCore::Region m_pendingDamageRegion;+ Rects m_pendingDamageRects;HashMap<uint64_t, RefPtr<Buffer>> m_buffers;+// Playwright begin+ RefPtr<cairo_surface_t> m_flippedSurface;@@ -18633,10 +18563,10 @@ index 0000000000000000000000000000000000000000..bf78de1915940c2d3292514cf0fe4e68++} // namespace WebKitdiff --git a/Source/WebKit/UIProcess/gtk/SystemSettingsManagerProxyGtk.cpp b/Source/WebKit/UIProcess/gtk/SystemSettingsManagerProxyGtk.cpp-index aa702b018d881739fb464246e7c7d7236adfe97b..f711e1608e6d8b988d2d0bc99893d5b0137a07ae 100644+index 9ef483a6b0ab1558c059304d727311ea7984184d..f532d2d2dbe2d7cb66323b6ea5fe2daace15d7b8 100644--- a/Source/WebKit/UIProcess/gtk/SystemSettingsManagerProxyGtk.cpp+++ b/Source/WebKit/UIProcess/gtk/SystemSettingsManagerProxyGtk.cpp-@@ -117,6 +117,8 @@ int SystemSettingsManagerProxy::xftDPI() const+@@ -126,6 +126,8 @@ int SystemSettingsManagerProxy::xftDPI() constbool SystemSettingsManagerProxy::followFontSystemSettings() const{@@ -18928,7 +18858,7 @@ index 0000000000000000000000000000000000000000..2aabc02a4b5432f68a6e85fd96897756+} // namespace APIdiff --git a/Source/WebKit/UIProcess/mac/InspectorPlaywrightAgentClientMac.mm b/Source/WebKit/UIProcess/mac/InspectorPlaywrightAgentClientMac.mmnew file mode 100644-index 0000000000000000000000000000000000000000..a5c8b963636b24d4bb8ad090e4a19aedecbf56c3+index 0000000000000000000000000000000000000000..a4b23bf4cf7c4cb6ef9d25d4121b20a611809479--- /dev/null+++ b/Source/WebKit/UIProcess/mac/InspectorPlaywrightAgentClientMac.mm@@ -0,0 +1,96 @@@@ -18999,7 +18929,7 @@ index 0000000000000000000000000000000000000000..a5c8b963636b24d4bb8ad090e4a19aed++std::unique_ptr<BrowserContext> InspectorPlaywrightAgentClientMac::createBrowserContext(WTF::String& error, const WTF::String& proxyServer, const WTF::String& proxyBypassList)+{-+ _WKBrowserContext* wkBrowserContext = [[delegate_ createBrowserContext:proxyServer WithBypassList:proxyBypassList] autorelease];++ _WKBrowserContext* wkBrowserContext = [[delegate_ createBrowserContext:proxyServer.createNSString().get() WithBypassList:proxyBypassList.createNSString().get()] autorelease];+ auto browserContext = std::make_unique<BrowserContext>();+ browserContext->processPool = &static_cast<WebProcessPool&>([[wkBrowserContext processPool] _apiObject]);+ browserContext->dataStore = &static_cast<WebsiteDataStore&>([[wkBrowserContext dataStore] _apiObject]);@@ -19077,10 +19007,10 @@ index 0000000000000000000000000000000000000000..8adbd51bfecad2a273117588bf50f8f7++#endifdiff --git a/Source/WebKit/UIProcess/mac/PageClientImplMac.h b/Source/WebKit/UIProcess/mac/PageClientImplMac.h-index 51744982af6f55f269d407cfb82638a4eaba8a5c..3cb319ef5fd54de9397f8065a8b05ca7ff82ccee 100644+index 8fc87c386fd82cdedc06ad1601d76919c6c27467..b5b2833b603e6996cf18c3416fde156940378f31 100644--- a/Source/WebKit/UIProcess/mac/PageClientImplMac.h+++ b/Source/WebKit/UIProcess/mac/PageClientImplMac.h-@@ -60,6 +60,8 @@ class PageClientImpl final : public PageClientImplCocoa+@@ -61,6 +61,8 @@ class PageClientImpl final : public PageClientImplCocoaWTF_OVERRIDE_DELETE_FOR_CHECKED_PTR(PageClientImpl);#endifpublic:@@ -19089,7 +19019,7 @@ index 51744982af6f55f269d407cfb82638a4eaba8a5c..3cb319ef5fd54de9397f8065a8b05ca7PageClientImpl(NSView *, WKWebView *);virtual ~PageClientImpl();-@@ -175,6 +177,9 @@ private:+@@ -176,6 +178,9 @@ private:void updateAcceleratedCompositingMode(const LayerTreeContext&) override;void didFirstLayerFlush(const LayerTreeContext&) override;@@ -19099,7 +19029,7 @@ index 51744982af6f55f269d407cfb82638a4eaba8a5c..3cb319ef5fd54de9397f8065a8b05ca7RefPtr<ViewSnapshot> takeViewSnapshot(std::optional<WebCore::IntRect>&&) override;RefPtr<ViewSnapshot> takeViewSnapshot(std::optional<WebCore::IntRect>&&, ForceSoftwareCapturingViewportSnapshot) override;void wheelEventWasNotHandledByWebCore(const NativeWebWheelEvent&) override;-@@ -228,6 +233,10 @@ private:+@@ -229,6 +234,10 @@ private:void beganExitFullScreen(const WebCore::IntRect& initialFrame, const WebCore::IntRect& finalFrame, CompletionHandler<void()>&&) override;#endif@@ -19111,10 +19041,10 @@ index 51744982af6f55f269d407cfb82638a4eaba8a5c..3cb319ef5fd54de9397f8065a8b05ca7void navigationGestureWillEnd(bool willNavigate, WebBackForwardListItem&) override;void navigationGestureDidEnd(bool willNavigate, WebBackForwardListItem&) override;diff --git a/Source/WebKit/UIProcess/mac/PageClientImplMac.mm b/Source/WebKit/UIProcess/mac/PageClientImplMac.mm-index 6f5fd6287d435161dd7a7269fccc32cada2aabd5..79f171aaba64bca6a6bc853edb5b77effbabf664 100644+index 5a5366f3f439d4727ca7dab149e0a523ccc27ce2..e02ab71cdf13af0d9b7b1aa04667c1dce54ed340 100644--- a/Source/WebKit/UIProcess/mac/PageClientImplMac.mm+++ b/Source/WebKit/UIProcess/mac/PageClientImplMac.mm-@@ -116,6 +116,13 @@ namespace WebKit {+@@ -110,6 +110,13 @@ namespace WebKit {using namespace WebCore;@@ -19128,7 +19058,7 @@ index 6f5fd6287d435161dd7a7269fccc32cada2aabd5..79f171aaba64bca6a6bc853edb5b77efPageClientImpl::PageClientImpl(NSView *view, WKWebView *webView): PageClientImplCocoa(webView), m_view(view)-@@ -169,6 +176,9 @@ NSWindow *PageClientImpl::activeWindow() const+@@ -163,6 +170,9 @@ NSWindow *PageClientImpl::activeWindow() constbool PageClientImpl::isViewWindowActive(){@@ -19136,9 +19066,9 @@ index 6f5fd6287d435161dd7a7269fccc32cada2aabd5..79f171aaba64bca6a6bc853edb5b77ef+ return true;+ASSERT(hasProcessPrivilege(ProcessPrivilege::CanCommunicateWithWindowServer));- NSWindow *activeViewWindow = activeWindow();- return activeViewWindow.isKeyWindow || (activeViewWindow && [NSApp keyWindow] == activeViewWindow);-@@ -176,6 +186,9 @@ bool PageClientImpl::isViewWindowActive()+ RetainPtr activeViewWindow = activeWindow();+ return activeViewWindow.get().isKeyWindow || (activeViewWindow && [NSApp keyWindow] == activeViewWindow.get());+@@ -170,6 +180,9 @@ bool PageClientImpl::isViewWindowActive()bool PageClientImpl::isViewFocused(){@@ -19148,17 +19078,17 @@ index 6f5fd6287d435161dd7a7269fccc32cada2aabd5..79f171aaba64bca6a6bc853edb5b77ef// FIXME: This is called from the WebPageProxy constructor before we have a WebViewImpl.// Once WebViewImpl and PageClient merge, this won't be a problem.if (!m_impl)-@@ -199,6 +212,9 @@ void PageClientImpl::makeFirstResponder()+@@ -193,6 +206,9 @@ void PageClientImpl::makeFirstResponder()bool PageClientImpl::isViewVisible(){+ if (_headless)+ return true;+- NSView *activeView = this->activeView();- NSWindow *activeViewWindow = activeWindow();+ RetainPtr activeView = this->activeView();+ RetainPtr activeViewWindow = activeWindow();-@@ -282,7 +298,8 @@ void PageClientImpl::didRelaunchProcess()+@@ -267,7 +283,8 @@ void PageClientImpl::didRelaunchProcess()void PageClientImpl::preferencesDidChange(){@@ -19168,7 +19098,7 @@ index 6f5fd6287d435161dd7a7269fccc32cada2aabd5..79f171aaba64bca6a6bc853edb5b77ef}void PageClientImpl::toolTipChanged(const String& oldToolTip, const String& newToolTip)-@@ -489,6 +506,8 @@ IntRect PageClientImpl::rootViewToAccessibilityScreen(const IntRect& rect)+@@ -475,6 +492,8 @@ IntRect PageClientImpl::rootViewToAccessibilityScreen(const IntRect& rect)void PageClientImpl::doneWithKeyEvent(const NativeWebKeyboardEvent& event, bool eventWasHandled){@@ -19177,16 +19107,16 @@ index 6f5fd6287d435161dd7a7269fccc32cada2aabd5..79f171aaba64bca6a6bc853edb5b77efm_impl->doneWithKeyEvent(event.nativeEvent(), eventWasHandled);}-@@ -508,6 +527,8 @@ void PageClientImpl::computeHasVisualSearchResults(const URL& imageURL, Shareabl+@@ -494,6 +513,8 @@ void PageClientImpl::computeHasVisualSearchResults(const URL& imageURL, ShareablRefPtr<WebPopupMenuProxy> PageClientImpl::createPopupMenuProxy(WebPageProxy& page){+ if (_headless)+ return nullptr;- return WebPopupMenuProxyMac::create(m_view, page.popupMenuClient());+ return WebPopupMenuProxyMac::create(m_view.get().get(), page.popupMenuClient());}-@@ -643,6 +664,12 @@ CALayer *PageClientImpl::footerBannerLayer() const+@@ -634,6 +655,12 @@ CALayer *PageClientImpl::footerBannerLayer() constreturn m_impl->footerBannerLayer();}@@ -19199,7 +19129,7 @@ index 6f5fd6287d435161dd7a7269fccc32cada2aabd5..79f171aaba64bca6a6bc853edb5b77efRefPtr<ViewSnapshot> PageClientImpl::takeViewSnapshot(std::optional<WebCore::IntRect>&&){return m_impl->takeViewSnapshot();-@@ -858,6 +885,13 @@ void PageClientImpl::beganExitFullScreen(const IntRect& initialFrame, const IntR+@@ -850,6 +877,13 @@ void PageClientImpl::beganExitFullScreen(const IntRect& initialFrame, const IntR#endif // ENABLE(FULLSCREEN_API)@@ -19213,7 +19143,7 @@ index 6f5fd6287d435161dd7a7269fccc32cada2aabd5..79f171aaba64bca6a6bc853edb5b77efvoid PageClientImpl::navigationGestureDidBegin(){m_impl->dismissContentRelativeChildWindowsWithAnimation(true);-@@ -1036,6 +1070,9 @@ void PageClientImpl::requestScrollToRect(const WebCore::FloatRect& targetRect, c+@@ -1030,6 +1064,9 @@ void PageClientImpl::requestScrollToRect(const WebCore::FloatRect& targetRect, cbool PageClientImpl::windowIsFrontWindowUnderMouse(const NativeWebMouseEvent& event){@@ -19247,7 +19177,7 @@ index f46895285dbc84c624537a194814c18f771a0c08..29ef9e5afa13b8d2b47b7f2dd4ce3784}+#endifdiff --git a/Source/WebKit/UIProcess/mac/WebContextMenuProxyMac.h b/Source/WebKit/UIProcess/mac/WebContextMenuProxyMac.h-index 1904f5ddedb75ee74aa84154fb9af248646c2fa2..af987387cc6537c225dd80515560c840319157f2 100644+index a3c53c0bf913385d4d2d92900360d5f7d75927f8..e5570ef599ff1b59224648c353f8ab16f8fe7f88 100644--- a/Source/WebKit/UIProcess/mac/WebContextMenuProxyMac.h+++ b/Source/WebKit/UIProcess/mac/WebContextMenuProxyMac.h@@ -81,6 +81,7 @@ private:@@ -19259,10 +19189,10 @@ index 1904f5ddedb75ee74aa84154fb9af248646c2fa2..af987387cc6537c225dd80515560c840bool showAfterPostProcessingContextData();diff --git a/Source/WebKit/UIProcess/mac/WebContextMenuProxyMac.mm b/Source/WebKit/UIProcess/mac/WebContextMenuProxyMac.mm-index c962b29e655a421e3199505d2aa8546a83dbd583..85dc988495ba9b4eef48ee501afb5f854b687678 100644+index 4cee7041f9b93d553b452447b33459832a5e4e36..2d5d79246c57be84ebf86f3935cd4583bf0cecdc 100644--- a/Source/WebKit/UIProcess/mac/WebContextMenuProxyMac.mm+++ b/Source/WebKit/UIProcess/mac/WebContextMenuProxyMac.mm-@@ -538,6 +538,12 @@ RetainPtr<NSMenuItem> WebContextMenuProxyMac::createShareMenuItem(ShareMenuItemT+@@ -540,6 +540,12 @@ RetainPtr<NSMenuItem> WebContextMenuProxyMac::createShareMenuItem(ShareMenuItemT}#endif@@ -19467,10 +19397,18 @@ index 0000000000000000000000000000000000000000..dd52991f936aa1c046b404801ee97237++} // namespace WebKitdiff --git a/Source/WebKit/UIProcess/mac/WebViewImpl.h b/Source/WebKit/UIProcess/mac/WebViewImpl.h-index 13b4e79c748071d02fedd8bced9ef0304943c51d..5830a3a3145b103a041cd2ff6666f8eff7666e3b 100644+index a0e1fc432a9b4b8938051d39725a1ec36ebd7a1b..f2a331f460879e43e9b069f50a099f10bbf8b8d8 100644--- a/Source/WebKit/UIProcess/mac/WebViewImpl.h+++ b/Source/WebKit/UIProcess/mac/WebViewImpl.h-@@ -566,6 +566,9 @@ public:+@@ -35,6 +35,7 @@+ #include "WKLayoutMode.h"+ #include "WKTextAnimationType.h"+ #include <WebCore/DOMPasteAccess.h>++#include <WebCore/FrameIdentifier.h>+ #include <WebCore/FocusDirection.h>+ #include <WebCore/KeypressCommand.h>+ #include <WebCore/PlatformPlaybackSessionInterface.h>+@@ -569,6 +570,9 @@ public:void provideDataForPasteboard(NSPasteboard *, NSString *type);NSArray *namesOfPromisedFilesDroppedAtDestination(NSURL *dropDestination);@@ -19481,10 +19419,10 @@ index 13b4e79c748071d02fedd8bced9ef0304943c51d..5830a3a3145b103a041cd2ff6666f8efRefPtr<ViewSnapshot> takeViewSnapshot(ForceSoftwareCapturingViewportSnapshot);void saveBackForwardSnapshotForCurrentItem();diff --git a/Source/WebKit/UIProcess/mac/WebViewImpl.mm b/Source/WebKit/UIProcess/mac/WebViewImpl.mm-index 9fe23e004a89f08ca6583181b01a72b5025c1d93..3028a0946be2d5fe51d92fd1de5bc0668bbb55c8 100644+index 1b42ae3cb6cdabee9830a1fb2ff55b9ae2325eb4..6998642cf147ec1af6e3feeb66d8688381791214 100644--- a/Source/WebKit/UIProcess/mac/WebViewImpl.mm+++ b/Source/WebKit/UIProcess/mac/WebViewImpl.mm-@@ -2415,6 +2415,11 @@ WebCore::DestinationColorSpace WebViewImpl::colorSpace()+@@ -2462,6 +2462,11 @@ WebCore::DestinationColorSpace WebViewImpl::colorSpace()if (!m_colorSpace)m_colorSpace = [NSColorSpace sRGBColorSpace];}@@ -19496,7 +19434,7 @@ index 9fe23e004a89f08ca6583181b01a72b5025c1d93..3028a0946be2d5fe51d92fd1de5bc066ASSERT(m_colorSpace);return WebCore::DestinationColorSpace { [m_colorSpace CGColorSpace] };-@@ -4587,6 +4592,17 @@ static RetainPtr<CGImageRef> takeWindowSnapshot(CGSWindowID windowID, bool captu+@@ -4707,6 +4712,17 @@ static RetainPtr<CGImageRef> takeWindowSnapshot(CGSWindowID windowID, bool captureturn WebCore::cgWindowListCreateImage(CGRectNull, kCGWindowListOptionIncludingWindow, windowID, imageOptions);}@@ -20424,10 +20362,10 @@ index 9b688ad328317fea4fd96ce66e9714bad8f0f937..402a36a9c565e13ec298aa7f014f0d92} // namespace WebKitdiff --git a/Source/WebKit/WebKit.xcodeproj/project.pbxproj b/Source/WebKit/WebKit.xcodeproj/project.pbxproj-index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02fb0a39f7 100644+index 07fb026a2a1ee93222d022a603b0057efbf848de..bedb13e953248741f32c61f8476e021233ce7e40 100644--- a/Source/WebKit/WebKit.xcodeproj/project.pbxproj+++ b/Source/WebKit/WebKit.xcodeproj/project.pbxproj-@@ -1542,6 +1542,7 @@+@@ -1546,6 +1546,7 @@5CABDC8722C40FED001EDE8E /* APIMessageListener.h in Headers */ = {isa = PBXBuildFile; fileRef = 5CABDC8322C40FA7001EDE8E /* APIMessageListener.h */; };5CADDE05215046BD0067D309 /* WKWebProcess.h in Headers */ = {isa = PBXBuildFile; fileRef = 5C74300E21500492004BFA17 /* WKWebProcess.h */; settings = {ATTRIBUTES = (Private, ); }; };5CAECB6627465AE400AB78D0 /* UnifiedSource115.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5CAECB5E27465AE300AB78D0 /* UnifiedSource115.cpp */; };@@ -20435,7 +20373,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b025CAF7AA726F93AB00003F19E /* adattributiond.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5CAF7AA526F93A950003F19E /* adattributiond.cpp */; };5CAFDE452130846300B1F7E1 /* _WKInspector.h in Headers */ = {isa = PBXBuildFile; fileRef = 5CAFDE422130843500B1F7E1 /* _WKInspector.h */; settings = {ATTRIBUTES = (Private, ); }; };5CAFDE472130846A00B1F7E1 /* _WKInspectorInternal.h in Headers */ = {isa = PBXBuildFile; fileRef = 5CAFDE442130843600B1F7E1 /* _WKInspectorInternal.h */; };-@@ -2323,6 +2324,18 @@+@@ -2328,6 +2329,18 @@DF0C5F28252ECB8E00D921DB /* WKDownload.h in Headers */ = {isa = PBXBuildFile; fileRef = DF0C5F24252ECB8D00D921DB /* WKDownload.h */; settings = {ATTRIBUTES = (Public, ); }; };DF0C5F2A252ECB8E00D921DB /* WKDownloadDelegate.h in Headers */ = {isa = PBXBuildFile; fileRef = DF0C5F26252ECB8E00D921DB /* WKDownloadDelegate.h */; settings = {ATTRIBUTES = (Public, ); }; };DF0C5F2B252ED44000D921DB /* WKDownloadInternal.h in Headers */ = {isa = PBXBuildFile; fileRef = DF0C5F25252ECB8E00D921DB /* WKDownloadInternal.h */; };@@ -20454,7 +20392,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02DF462E0F23F22F5500EFF35F /* WKHTTPCookieStorePrivate.h in Headers */ = {isa = PBXBuildFile; fileRef = DF462E0E23F22F5300EFF35F /* WKHTTPCookieStorePrivate.h */; settings = {ATTRIBUTES = (Private, ); }; };DF462E1223F338BE00EFF35F /* WKContentWorldPrivate.h in Headers */ = {isa = PBXBuildFile; fileRef = DF462E1123F338AD00EFF35F /* WKContentWorldPrivate.h */; settings = {ATTRIBUTES = (Private, ); }; };DF7A231C291B088D00B98DF3 /* WKSnapshotConfigurationPrivate.h in Headers */ = {isa = PBXBuildFile; fileRef = DF7A231B291B088D00B98DF3 /* WKSnapshotConfigurationPrivate.h */; settings = {ATTRIBUTES = (Private, ); }; };-@@ -2422,6 +2435,8 @@+@@ -2427,6 +2440,8 @@E5BEF6822130C48000F31111 /* WebDataListSuggestionsDropdownIOS.h in Headers */ = {isa = PBXBuildFile; fileRef = E5BEF6802130C47F00F31111 /* WebDataListSuggestionsDropdownIOS.h */; };E5CB07DC20E1678F0022C183 /* WKFormColorControl.h in Headers */ = {isa = PBXBuildFile; fileRef = E5CB07DA20E1678F0022C183 /* WKFormColorControl.h */; };E5CBA76427A318E100DF7858 /* UnifiedSource120.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5CBA75F27A3187800DF7858 /* UnifiedSource120.cpp */; };@@ -20463,8 +20401,8 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02E5CBA76527A318E100DF7858 /* UnifiedSource118.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5CBA76127A3187900DF7858 /* UnifiedSource118.cpp */; };E5CBA76627A318E100DF7858 /* UnifiedSource116.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5CBA76327A3187B00DF7858 /* UnifiedSource116.cpp */; };E5CBA76727A318E100DF7858 /* UnifiedSource119.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E5CBA76027A3187900DF7858 /* UnifiedSource119.cpp */; };-@@ -2447,6 +2462,9 @@- ED82A7F2128C6FAF004477B3 /* WKBundlePageOverlay.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A22F0FF1289FCD90085E74F /* WKBundlePageOverlay.h */; settings = {ATTRIBUTES = (Private, ); }; };+@@ -2456,6 +2471,9 @@+ EEA52F492D7055A700D578B5 /* WKStageMode.swift in Sources */ = {isa = PBXBuildFile; fileRef = EE0D3CDC2D3709BE00072978 /* WKStageMode.swift */; };EEFE72792D64FE5600DC6214 /* StageModeInteractionState.h in Headers */ = {isa = PBXBuildFile; fileRef = EEFE72782D64FE5600DC6214 /* StageModeInteractionState.h */; };F404455C2D5CFB56000E587E /* AppKitSoftLink.h in Headers */ = {isa = PBXBuildFile; fileRef = F404455A2D5CFB56000E587E /* AppKitSoftLink.h */; };+ F303B849249A8D640031DE5C /* ScreencastEncoder.h in Headers */ = {isa = PBXBuildFile; fileRef = F303B848249A8D3A0031DE5C /* ScreencastEncoder.h */; };@@ -20473,7 +20411,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02F409BA181E6E64BC009DA28E /* WKDragDestinationAction.h in Headers */ = {isa = PBXBuildFile; fileRef = F409BA171E6E64B3009DA28E /* WKDragDestinationAction.h */; settings = {ATTRIBUTES = (Private, ); }; };F40C3B712AB401C5007A3567 /* WKDatePickerPopoverController.h in Headers */ = {isa = PBXBuildFile; fileRef = F40C3B6F2AB40167007A3567 /* WKDatePickerPopoverController.h */; };F41145682CD939E0004CDBD1 /* _WKTouchEventGenerator.h in Headers */ = {isa = PBXBuildFile; fileRef = F41145652CD939E0004CDBD1 /* _WKTouchEventGenerator.h */; settings = {ATTRIBUTES = (Private, ); }; };-@@ -6307,6 +6325,7 @@+@@ -6365,6 +6383,7 @@5CABDC8522C40FCC001EDE8E /* WKMessageListener.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKMessageListener.h; sourceTree = "<group>"; };5CABE07A28F60E8A00D83FD9 /* WebPushMessage.serialization.in */ = {isa = PBXFileReference; lastKnownFileType = text; path = WebPushMessage.serialization.in; sourceTree = "<group>"; };5CADDE0D2151AA010067D309 /* AuthenticationChallengeDisposition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AuthenticationChallengeDisposition.h; sourceTree = "<group>"; };@@ -20481,7 +20419,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b025CAECB5E27465AE300AB78D0 /* UnifiedSource115.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = UnifiedSource115.cpp; sourceTree = "<group>"; };5CAF7AA426F93A750003F19E /* adattributiond */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = adattributiond; sourceTree = BUILT_PRODUCTS_DIR; };5CAF7AA526F93A950003F19E /* adattributiond.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = adattributiond.cpp; sourceTree = "<group>"; };-@@ -8025,6 +8044,19 @@+@@ -8090,6 +8109,19 @@DF0C5F24252ECB8D00D921DB /* WKDownload.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKDownload.h; sourceTree = "<group>"; };DF0C5F25252ECB8E00D921DB /* WKDownloadInternal.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKDownloadInternal.h; sourceTree = "<group>"; };DF0C5F26252ECB8E00D921DB /* WKDownloadDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKDownloadDelegate.h; sourceTree = "<group>"; };@@ -20501,7 +20439,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02DF462E0E23F22F5300EFF35F /* WKHTTPCookieStorePrivate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKHTTPCookieStorePrivate.h; sourceTree = "<group>"; };DF462E1123F338AD00EFF35F /* WKContentWorldPrivate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKContentWorldPrivate.h; sourceTree = "<group>"; };DF58C6311371AC5800F9A37C /* NativeWebWheelEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NativeWebWheelEvent.h; sourceTree = "<group>"; };-@@ -8198,6 +8230,8 @@+@@ -8263,6 +8295,8 @@E5CBA76127A3187900DF7858 /* UnifiedSource118.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = UnifiedSource118.cpp; sourceTree = "<group>"; };E5CBA76227A3187900DF7858 /* UnifiedSource117.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = UnifiedSource117.cpp; sourceTree = "<group>"; };E5CBA76327A3187B00DF7858 /* UnifiedSource116.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = UnifiedSource116.cpp; sourceTree = "<group>"; };@@ -20510,10 +20448,10 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02E5DEFA6726F8F42600AB68DB /* PhotosUISPI.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PhotosUISPI.h; sourceTree = "<group>"; };EB0D312D275AE13300863D8F /* com.apple.webkit.webpushd.mac.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = com.apple.webkit.webpushd.mac.plist; sourceTree = "<group>"; };EB0D312E275AE13300863D8F /* com.apple.webkit.webpushd.ios.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = com.apple.webkit.webpushd.ios.plist; sourceTree = "<group>"; };-@@ -8234,6 +8268,14 @@- F036978715F4BF0500C3A80E /* WebColorPicker.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebColorPicker.cpp; sourceTree = "<group>"; };+@@ -8305,6 +8339,14 @@F404455A2D5CFB56000E587E /* AppKitSoftLink.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppKitSoftLink.h; sourceTree = "<group>"; };F404455B2D5CFB56000E587E /* AppKitSoftLink.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = AppKitSoftLink.mm; sourceTree = "<group>"; };+ F4063DDE2D71481E00F3FE6E /* LLVMProfiling.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = LLVMProfiling.h; sourceTree = "<group>"; };+ F303B847249A8D3A0031DE5C /* ScreencastEncoder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScreencastEncoder.cpp; sourceTree = "<group>"; };+ F303B848249A8D3A0031DE5C /* ScreencastEncoder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScreencastEncoder.h; sourceTree = "<group>"; };+ F31E2DA424C76E4B004B2775 /* WebMFileWriter.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebMFileWriter.cpp; sourceTree = "<group>"; };@@ -20525,7 +20463,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02F409BA171E6E64B3009DA28E /* WKDragDestinationAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKDragDestinationAction.h; sourceTree = "<group>"; };F40C3B6F2AB40167007A3567 /* WKDatePickerPopoverController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = WKDatePickerPopoverController.h; path = ios/forms/WKDatePickerPopoverController.h; sourceTree = "<group>"; };F40C3B702AB40167007A3567 /* WKDatePickerPopoverController.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; name = WKDatePickerPopoverController.mm; path = ios/forms/WKDatePickerPopoverController.mm; sourceTree = "<group>"; };-@@ -8592,6 +8634,7 @@+@@ -8710,6 +8752,7 @@3766F9EE189A1241003CF19B /* JavaScriptCore.framework in Frameworks */,3766F9F1189A1254003CF19B /* libicucore.dylib in Frameworks */,7B9FC5BB28A5233B007570E7 /* libWebKitPlatform.a in Frameworks */,@@ -20533,7 +20471,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b023766F9EF189A1244003CF19B /* QuartzCore.framework in Frameworks */,37694525184FC6B600CDE21F /* Security.framework in Frameworks */,37BEC4DD1948FC6A008B4286 /* WebCore.framework in Frameworks */,-@@ -11661,6 +11704,7 @@+@@ -11841,6 +11884,7 @@99788ACA1F421DCA00C08000 /* _WKAutomationSessionConfiguration.mm */,990D28A81C6404B000986977 /* _WKAutomationSessionDelegate.h */,990D28AF1C65203900986977 /* _WKAutomationSessionInternal.h */,@@ -20541,7 +20479,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b025C4609E222430E4C009943C2 /* _WKContentRuleListAction.h */,5C4609E322430E4D009943C2 /* _WKContentRuleListAction.mm */,5C4609E422430E4D009943C2 /* _WKContentRuleListActionInternal.h */,-@@ -13028,6 +13072,7 @@+@@ -13218,6 +13262,7 @@E34B110C27C46BC6006D2F2E /* libWebCoreTestShim.dylib */,E34B110F27C46D09006D2F2E /* libWebCoreTestSupport.dylib */,DDE992F4278D06D900F60D26 /* libWebKitAdditions.a */,@@ -20549,7 +20487,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b0257A9FF15252C6AEF006A2040 /* libWTF.a */,5750F32A2032D4E500389347 /* LocalAuthentication.framework */,570DAAB0230273D200E8FC04 /* NearField.framework */,-@@ -13609,6 +13654,12 @@+@@ -13799,6 +13844,12 @@children = (9197940423DBC4BB00257892 /* InspectorBrowserAgent.cpp */,9197940323DBC4BB00257892 /* InspectorBrowserAgent.h */,@@ -20562,7 +20500,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02);path = Agents;sourceTree = "<group>";-@@ -13617,6 +13668,7 @@+@@ -13807,6 +13858,7 @@isa = PBXGroup;children = (A5D3504D1D78F0D2005124A9 /* RemoteWebInspectorUIProxyMac.mm */,@@ -20570,7 +20508,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b021CA8B935127C774E00576C2B /* WebInspectorUIProxyMac.mm */,99A7ACE326012919006D57FD /* WKInspectorResourceURLSchemeHandler.h */,99A7ACE42601291A006D57FD /* WKInspectorResourceURLSchemeHandler.mm */,-@@ -14353,6 +14405,7 @@+@@ -14560,6 +14612,7 @@E1513C65166EABB200149FCB /* AuxiliaryProcessProxy.h */,46A2B6061E5675A200C3DEDA /* BackgroundProcessResponsivenessTimer.cpp */,46A2B6071E5675A200C3DEDA /* BackgroundProcessResponsivenessTimer.h */,@@ -20578,7 +20516,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b025C6D69352AC3935D0099BDAF /* BrowsingContextGroup.cpp */,5C6D69362AC3935D0099BDAF /* BrowsingContextGroup.h */,5CA98549210BEB5A0057EB6B /* BrowsingWarning.h */,-@@ -14377,6 +14430,8 @@+@@ -14584,6 +14637,8 @@BC06F43912DBCCFB002D78DE /* GeolocationPermissionRequestProxy.cpp */,BC06F43812DBCCFB002D78DE /* GeolocationPermissionRequestProxy.h */,2DD5A72A1EBF09A7009BA597 /* HiddenPageThrottlingAutoIncreasesCounter.h */,@@ -20587,15 +20525,15 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b025CEABA2B2333251400797797 /* LegacyGlobalSettings.cpp */,5CEABA2A2333247700797797 /* LegacyGlobalSettings.h */,31607F3819627002009B87DA /* LegacySessionStateCoding.h */,-@@ -14410,6 +14465,7 @@- 1A0C227D2451130A00ED614D /* QuickLookThumbnailingSoftLink.mm */,- 1AEE57232409F142002005D6 /* QuickLookThumbnailLoader.h */,- 1AEE57242409F142002005D6 /* QuickLookThumbnailLoader.mm */,+@@ -14613,6 +14668,7 @@+ 4683569B21E81CC7006E27A3 /* ProvisionalPageProxy.cpp */,+ 4683569A21E81CC7006E27A3 /* ProvisionalPageProxy.h */,+ 411B89CB27B2B89600F9EBD3 /* QueryPermissionResultCallback.h */,+ D71A94392370F060002C4D9E /* RemoteInspectorPipe.h */,5CCB54DC2A4FEA6A0005FAA8 /* RemotePageDrawingAreaProxy.cpp */,5CCB54DB2A4FEA6A0005FAA8 /* RemotePageDrawingAreaProxy.h */,FABBBC802D35AC6800820017 /* RemotePageFullscreenManagerProxy.cpp */,-@@ -14512,6 +14568,8 @@+@@ -14716,6 +14772,8 @@BC7B6204129A0A6700D174A4 /* WebPageGroup.h */,2D9EA3101A96D9EB002D2807 /* WebPageInjectedBundleClient.cpp */,2D9EA30E1A96CBFF002D2807 /* WebPageInjectedBundleClient.h */,@@ -20604,7 +20542,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b029B7F8A502C785725000057F3 /* WebPageLoadTiming.h */,BC111B0B112F5E4F00337BAB /* WebPageProxy.cpp */,BC032DCB10F4389F0058C15A /* WebPageProxy.h */,-@@ -14690,6 +14748,7 @@+@@ -14894,6 +14952,7 @@BC646C1911DD399F006455B0 /* WKBackForwardListItemRef.h */,BC646C1611DD399F006455B0 /* WKBackForwardListRef.cpp */,BC646C1711DD399F006455B0 /* WKBackForwardListRef.h */,@@ -20612,7 +20550,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02BCB9E24A1120E15C00A137E0 /* WKContext.cpp */,BCB9E2491120E15C00A137E0 /* WKContext.h */,1AE52F9319201F6B00A1FA37 /* WKContextConfigurationRef.cpp */,-@@ -15265,6 +15324,9 @@+@@ -15468,6 +15527,9 @@07EF07592745A8160066EA04 /* DisplayCaptureSessionManager.h */,07EF07582745A8160066EA04 /* DisplayCaptureSessionManager.mm */,7AFA6F682A9F57C50055322A /* DisplayLinkMac.cpp */,@@ -20622,7 +20560,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b021AFDE65B1954E8D500C48FFA /* LegacySessionStateCoding.cpp */,0FCB4E5818BBE3D9000FCFC9 /* PageClientImplMac.h */,0FCB4E5918BBE3D9000FCFC9 /* PageClientImplMac.mm */,-@@ -15288,6 +15350,8 @@+@@ -15491,6 +15553,8 @@E568B92120A3AC6A00E3C856 /* WebDataListSuggestionsDropdownMac.mm */,E55CD20124D09F1F0042DB9C /* WebDateTimePickerMac.h */,E55CD20224D09F1F0042DB9C /* WebDateTimePickerMac.mm */,@@ -20631,7 +20569,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02BC857E8512B71EBB00EDEB2E /* WebPageProxyMac.mm */,BC5750951268F3C6006F0F12 /* WebPopupMenuProxyMac.h */,BC5750961268F3C6006F0F12 /* WebPopupMenuProxyMac.mm */,-@@ -16361,6 +16425,7 @@+@@ -16577,6 +16641,7 @@99788ACB1F421DDA00C08000 /* _WKAutomationSessionConfiguration.h in Headers */,990D28AC1C6420CF00986977 /* _WKAutomationSessionDelegate.h in Headers */,990D28B11C65208D00986977 /* _WKAutomationSessionInternal.h in Headers */,@@ -20639,7 +20577,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b025C4609E7224317B4009943C2 /* _WKContentRuleListAction.h in Headers */,5C4609E8224317BB009943C2 /* _WKContentRuleListActionInternal.h in Headers */,9B4CE9512CD99B7C00351173 /* _WKContentWorldConfiguration.h in Headers */,-@@ -16669,6 +16734,7 @@+@@ -16885,6 +16950,7 @@E170876C16D6CA6900F99226 /* BlobRegistryProxy.h in Headers */,4F601432155C5AA2001FBDE0 /* BlockingResponseMap.h in Headers */,1A5705111BE410E600874AF1 /* BlockSPI.h in Headers */,@@ -20647,7 +20585,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b025CA9854A210BEB640057EB6B /* BrowsingWarning.h in Headers */,A7E69BCC2B2117A100D43D3F /* BufferAndBackendInfo.h in Headers */,BC3065FA1259344E00E71278 /* CacheModel.h in Headers */,-@@ -16853,7 +16919,11 @@+@@ -17067,7 +17133,11 @@BC14DF77120B5B7900826C0C /* InjectedBundleScriptWorld.h in Headers */,CE550E152283752200D28791 /* InsertTextOptions.h in Headers */,9197940523DBC4BB00257892 /* InspectorBrowserAgent.h in Headers */,@@ -20659,7 +20597,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02A5E391FD2183C1F800C8FB31 /* InspectorTargetProxy.h in Headers */,C5BCE5DF1C50766A00CDE3FA /* InteractionInformationAtPosition.h in Headers */,2D4D2C811DF60BF3002EB10C /* InteractionInformationRequest.h in Headers */,-@@ -17115,6 +17185,7 @@+@@ -17328,6 +17398,7 @@0F6E7C532C4C386800F1DB85 /* RemoteDisplayListRecorderMessages.h in Headers */,F451C0FE2703B263002BA03B /* RemoteDisplayListRecorderProxy.h in Headers */,A78A5FE42B0EB39E005036D3 /* RemoteImageBufferSetIdentifier.h in Headers */,@@ -20667,15 +20605,15 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b022D47B56D1810714E003A3AEE /* RemoteLayerBackingStore.h in Headers */,2DDF731518E95060004F5A66 /* RemoteLayerBackingStoreCollection.h in Headers */,1AB16AEA164B3A8800290D62 /* RemoteLayerTreeContext.h in Headers */,-@@ -17170,6 +17241,7 @@+@@ -17384,6 +17455,7 @@E1E552C516AE065F004ED653 /* SandboxInitializationParameters.h in Headers */,E36FF00327F36FBD004BE21A /* SandboxStateVariables.h in Headers */,7BAB111025DD02B3008FC479 /* ScopedActiveMessageReceiveQueue.h in Headers */,+ F303B849249A8D640031DE5C /* ScreencastEncoder.h in Headers */,+ 6D4DF20C2D824242001F964C /* ScreenTimeWebsiteDataSupport.h in Headers */,463BB93A2B9D08D80098C5C3 /* ScriptMessageHandlerIdentifier.h in Headers */,F4E28A362C923814008120DD /* ScriptTelemetry.h in Headers */,- E4D54D0421F1D72D007E3C36 /* ScrollingTreeFrameScrollingNodeRemoteIOS.h in Headers */,-@@ -17530,6 +17602,8 @@+@@ -17745,6 +17817,8 @@939EF87029D112EE00F23AEE /* WebPageInlines.h in Headers */,9197940823DBC4CB00257892 /* WebPageInspectorAgentBase.h in Headers */,A513F5402154A5D700662841 /* WebPageInspectorController.h in Headers */,@@ -20684,7 +20622,7 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b02A543E30C215C8A8D00279CD9 /* WebPageInspectorTarget.h in Headers */,A543E30D215C8A9000279CD9 /* WebPageInspectorTargetController.h in Headers */,A543E307215AD13700279CD9 /* WebPageInspectorTargetFrontendChannel.h in Headers */,-@@ -20064,7 +20138,43 @@+@@ -20348,7 +20422,43 @@522F792928D50EBB0069B45B /* HidService.mm in Sources */,2749F6442146561B008380BF /* InjectedBundleNodeHandle.cpp in Sources */,2749F6452146561E008380BF /* InjectedBundleRangeHandle.cpp in Sources */,@@ -20728,20 +20666,20 @@ index 53f900a15956048fd25f9b0d54d6b74580612abb..133eaf568fa054d93ebf3a41e8f78b021C5DC45F2909B05A0061EC62 /* JSWebExtensionWrapperCocoa.mm in Sources */,C14D37FE24ACE086007FF014 /* LaunchServicesDatabaseManager.mm in Sources */,C1710CF724AA643200D7C112 /* LaunchServicesDatabaseObserver.mm in Sources */,-@@ -20425,6 +20535,8 @@+@@ -20746,6 +20856,8 @@074E87E12CF8EA3D0059E469 /* WebPage+NavigationDeciding.swift in Sources */,078B04A02CF18EAB00B453A6 /* WebPage+NavigationPreferences.swift in Sources */,07CB79962CE9435700199C49 /* WebPage.swift in Sources */,+ D79902B1236E9404005D6F7E /* WebPageInspectorEmulationAgentMac.mm in Sources */,+ D79902B3236E9404005D6F7E /* WebPageInspectorInputAgentMac.mm in Sources */,7CE9CE101FA0767A000177DE /* WebPageUpdatePreferences.cpp in Sources */,+ 079A4DA12D72CC0D00CA387F /* WebPageWebView.swift in Sources */,7CEB00DD1FA69ABE0065473B /* WebPreferencesFeatures.cpp in Sources */,- 7CF1907125338F3800ABE183 /* WebPreferencesGetterSetters.cpp in Sources */,diff --git a/Source/WebKit/WebProcess/Network/WebLoaderStrategy.cpp b/Source/WebKit/WebProcess/Network/WebLoaderStrategy.cpp-index ac0032c3bf918b6dcadd21c18700f1adb74e9a78..4f55fe73551265aa22f743e7ec006e2c9b213463 100644+index ae80809efafab3264b06e7bac45771c72d4408b8..849694aea1738dac5e2a0741f31def13c34c8608 100644--- a/Source/WebKit/WebProcess/Network/WebLoaderStrategy.cpp+++ b/Source/WebKit/WebProcess/Network/WebLoaderStrategy.cpp-@@ -247,6 +247,11 @@ void WebLoaderStrategy::scheduleLoad(ResourceLoader& resourceLoader, CachedResou+@@ -269,6 +269,11 @@ void WebLoaderStrategy::scheduleLoad(ResourceLoader& resourceLoader, CachedResou}#endif@@ -20753,40 +20691,39 @@ index ac0032c3bf918b6dcadd21c18700f1adb74e9a78..4f55fe73551265aa22f743e7ec006e2c#if ENABLE(PDFJS)if (tryLoadingUsingPDFJSHandler(resourceLoader, trackingParameters))return;-@@ -256,12 +261,16 @@ void WebLoaderStrategy::scheduleLoad(ResourceLoader& resourceLoader, CachedResou- return;+@@ -283,12 +288,16 @@ void WebLoaderStrategy::scheduleLoad(ResourceLoader& resourceLoader, CachedResou+ }if (InspectorInstrumentationWebKit::shouldInterceptRequest(resourceLoader)) {-- InspectorInstrumentationWebKit::interceptRequest(resourceLoader, [this, protectedResourceLoader = Ref { resourceLoader }, trackingParameters, shouldClearReferrerOnHTTPSToHTTPRedirect, resource](const ResourceRequest& request) {+- InspectorInstrumentationWebKit::interceptRequest(resourceLoader, [this, protectedThis = Ref { *this }, protectedResourceLoader = Ref { resourceLoader }, trackingParameters, shouldClearReferrerOnHTTPSToHTTPRedirect, resource](const ResourceRequest& request) {- auto& resourceLoader = protectedResourceLoader.get();- WEBLOADERSTRATEGY_RELEASE_LOG("scheduleLoad: intercepted URL will be scheduled with the NetworkProcess");-- scheduleLoadFromNetworkProcess(resourceLoader, request, trackingParameters, shouldClearReferrerOnHTTPSToHTTPRedirect, maximumBufferingTime(resource));+- scheduleLoadFromNetworkProcess(resourceLoader, request, *trackingParameters, shouldClearReferrerOnHTTPSToHTTPRedirect, maximumBufferingTime(resource));- });- return;+ bool isMainFrameNavigation = resourceLoader.frame() && resourceLoader.frame()->isMainFrame() && resourceLoader.options().mode == FetchOptions::Mode::Navigate;+ // Do not intercept navigation request which could already have been intercepted and resumed.+ if (!(isMainFrameNavigation && m_existingNetworkResourceLoadIdentifierToResume)) {-+ InspectorInstrumentationWebKit::interceptRequest(resourceLoader, [this, protectedResourceLoader = Ref { resourceLoader }, trackingParameters, shouldClearReferrerOnHTTPSToHTTPRedirect, resource](const ResourceRequest& request) {++ InspectorInstrumentationWebKit::interceptRequest(resourceLoader, [this, protectedThis = Ref { *this }, protectedResourceLoader = Ref { resourceLoader }, trackingParameters, shouldClearReferrerOnHTTPSToHTTPRedirect, resource](const ResourceRequest& request) {+ auto& resourceLoader = protectedResourceLoader.get();+ WEBLOADERSTRATEGY_RELEASE_LOG("scheduleLoad: intercepted URL will be scheduled with the NetworkProcess");-+ scheduleLoadFromNetworkProcess(resourceLoader, request, trackingParameters, shouldClearReferrerOnHTTPSToHTTPRedirect, maximumBufferingTime(resource));++ scheduleLoadFromNetworkProcess(resourceLoader, request, *trackingParameters, shouldClearReferrerOnHTTPSToHTTPRedirect, maximumBufferingTime(resource));+ });+ return;+ }}WEBLOADERSTRATEGY_RELEASE_LOG_FORWARDABLE(WEBLOADERSTRATEGY_SCHEDULELOAD);-@@ -383,7 +392,8 @@ static void addParametersShared(const LocalFrame* frame, NetworkResourceLoadPara+@@ -413,7 +422,7 @@ static void addParametersShared(const LocalFrame* frame, NetworkResourceLoadParaparameters.linkPreconnectEarlyHintsEnabled = mainFrame->settings().linkPreconnectEarlyHintsEnabled();}-void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceLoader, const ResourceRequest& request, const WebResourceLoader::TrackingParameters& trackingParameters, bool shouldClearReferrerOnHTTPSToHTTPRedirect, Seconds maximumBufferingTime)-+// static+bool WebLoaderStrategy::fillParametersForNetworkProcessLoad(ResourceLoader& resourceLoader, const ResourceRequest& request, const WebResourceLoader::TrackingParameters& trackingParameters, bool shouldClearReferrerOnHTTPSToHTTPRedirect, Seconds maximumBufferingTime, NetworkResourceLoadParameters& loadParameters){auto identifier = *resourceLoader.identifier();-@@ -395,10 +405,10 @@ void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceL+@@ -425,10 +434,10 @@ void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceL&& resourceLoader.frameLoader()->notifier().isInitialRequestIdentifier(identifier)? MainFrameMainResource::Yes : MainFrameMainResource::No;if (!page->allowsLoadFromURL(request.url(), mainFrameMainResource)) {@@ -20799,15 +20736,22 @@ index ac0032c3bf918b6dcadd21c18700f1adb74e9a78..4f55fe73551265aa22f743e7ec006e2c}}-@@ -408,7 +418,6 @@ void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceL+@@ -438,14 +447,6 @@ void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceLLOG(NetworkScheduling, "(WebProcess) WebLoaderStrategy::scheduleLoad, url '%s' will be scheduled with the NetworkProcess with priority %d, storedCredentialsPolicy %i", resourceLoader.url().string().latin1().data(), static_cast<int>(resourceLoader.request().priority()), (int)storedCredentialsPolicy);-- NetworkResourceLoadParameters loadParameters;+- NetworkResourceLoadParameters loadParameters {+- trackingParameters.webPageProxyID,+- trackingParameters.pageID,+- trackingParameters.frameID,+- request+- };+- loadParameters.createSandboxExtensionHandlesIfNecessary();+-loadParameters.identifier = identifier;- loadParameters.webPageProxyID = trackingParameters.webPageProxyID;- loadParameters.webPageID = trackingParameters.pageID;-@@ -499,14 +508,11 @@ void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceL+ loadParameters.parentPID = legacyPresentingApplicationPID();+ loadParameters.contentSniffingPolicy = contentSniffingPolicy;+@@ -529,14 +530,11 @@ void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceLif (loadParameters.options.mode != FetchOptions::Mode::Navigate) {ASSERT(loadParameters.sourceOrigin);@@ -20825,25 +20769,33 @@ index ac0032c3bf918b6dcadd21c18700f1adb74e9a78..4f55fe73551265aa22f743e7ec006e2cloadParameters.isMainFrameNavigation = isMainFrameNavigation;if (loadParameters.isMainFrameNavigation && document)-@@ -547,6 +553,17 @@ void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceL- }+@@ -583,6 +581,25 @@ void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceL+ if (RefPtr frameLoader = resourceLoader.frameLoader())+ loadParameters.requiredCookiesVersion = frameLoader->requiredCookiesVersion();- ASSERT((loadParameters.webPageID && loadParameters.webFrameID) || loadParameters.clientCredentialPolicy == ClientCredentialPolicy::CannotAskClientForCredentials);+ return true;+}++void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceLoader, const ResourceRequest& request, const WebResourceLoader::TrackingParameters& trackingParameters, bool shouldClearReferrerOnHTTPSToHTTPRedirect, Seconds maximumBufferingTime)+{-+ NetworkResourceLoadParameters loadParameters;++ NetworkResourceLoadParameters loadParameters {++ trackingParameters.webPageProxyID,++ trackingParameters.pageID,++ trackingParameters.frameID,++ request++ };++ loadParameters.createSandboxExtensionHandlesIfNecessary();+++ if (!fillParametersForNetworkProcessLoad(resourceLoader, request, trackingParameters, shouldClearReferrerOnHTTPSToHTTPRedirect, maximumBufferingTime, loadParameters)) {+ WEBLOADERSTRATEGY_RELEASE_LOG_ERROR("scheduleLoad: no sourceOrigin (priority=%d)", static_cast<int>(resourceLoader.request().priority()));+ scheduleInternallyFailedLoad(resourceLoader);+ return;+ }-++std::optional<NetworkResourceLoadIdentifier> existingNetworkResourceLoadIdentifierToResume;if (loadParameters.isMainFrameNavigation)-@@ -562,7 +579,7 @@ void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceL+ existingNetworkResourceLoadIdentifierToResume = std::exchange(m_existingNetworkResourceLoadIdentifierToResume, std::nullopt);+@@ -597,7 +614,7 @@ void WebLoaderStrategy::scheduleLoadFromNetworkProcess(ResourceLoader& resourceL}auto loader = WebResourceLoader::create(resourceLoader, trackingParameters);@@ -20852,7 +20804,7 @@ index ac0032c3bf918b6dcadd21c18700f1adb74e9a78..4f55fe73551265aa22f743e7ec006e2c}void WebLoaderStrategy::scheduleInternallyFailedLoad(WebCore::ResourceLoader& resourceLoader)-@@ -966,7 +983,7 @@ void WebLoaderStrategy::didFinishPreconnection(WebCore::ResourceLoaderIdentifier+@@ -1015,7 +1032,7 @@ void WebLoaderStrategy::didFinishPreconnection(WebCore::ResourceLoaderIdentifierbool WebLoaderStrategy::isOnLine() const{@@ -20861,7 +20813,7 @@ index ac0032c3bf918b6dcadd21c18700f1adb74e9a78..4f55fe73551265aa22f743e7ec006e2c}void WebLoaderStrategy::addOnlineStateChangeListener(Function<void(bool)>&& listener)-@@ -993,6 +1010,11 @@ void WebLoaderStrategy::isResourceLoadFinished(CachedResource& resource, Complet+@@ -1042,6 +1059,11 @@ void WebLoaderStrategy::isResourceLoadFinished(CachedResource& resource, Completvoid WebLoaderStrategy::setOnLineState(bool isOnLine){@@ -20873,7 +20825,7 @@ index ac0032c3bf918b6dcadd21c18700f1adb74e9a78..4f55fe73551265aa22f743e7ec006e2cif (m_isOnLine == isOnLine)return;-@@ -1001,6 +1023,12 @@ void WebLoaderStrategy::setOnLineState(bool isOnLine)+@@ -1050,6 +1072,12 @@ void WebLoaderStrategy::setOnLineState(bool isOnLine)listener(isOnLine);}@@ -20887,24 +20839,24 @@ index ac0032c3bf918b6dcadd21c18700f1adb74e9a78..4f55fe73551265aa22f743e7ec006e2c{WebProcess::singleton().ensureNetworkProcessConnection().connection().send(Messages::NetworkConnectionToWebProcess::SetCaptureExtraNetworkLoadMetricsEnabled(enabled), 0);diff --git a/Source/WebKit/WebProcess/Network/WebLoaderStrategy.h b/Source/WebKit/WebProcess/Network/WebLoaderStrategy.h-index dc88916914daebf7c421dc56c2be70fd47727a96..829fdad0490a5e4db8822fbc48c5f19a2c2e0703 100644+index 6492031de6ed6effab3f28e5321419f3390f7651..678139fc26f26e2224a70b0087ddb849280b8ace 100644--- a/Source/WebKit/WebProcess/Network/WebLoaderStrategy.h+++ b/Source/WebKit/WebProcess/Network/WebLoaderStrategy.h-@@ -44,6 +44,7 @@ struct FetchOptions;- namespace WebKit {+@@ -26,6 +26,7 @@+ #pragma once- class NetworkProcessConnection;-+class NetworkResourceLoadParameters;- class WebFrame;- class WebPage;- class WebProcess;+ #include "NetworkResourceLoadIdentifier.h"++#include "NetworkResourceLoadParameters.h"+ #include "WebResourceLoader.h"+ #include <WebCore/LoaderStrategy.h>+ #include <WebCore/ResourceError.h>@@ -96,6 +97,9 @@ public:bool isOnLine() const final;void addOnlineStateChangeListener(Function<void(bool)>&&) final;void setOnLineState(bool);+ void setEmulateOfflineState(bool) final;+-+ static bool fillParametersForNetworkProcessLoad(WebCore::ResourceLoader&, const WebCore::ResourceRequest&, const WebResourceLoader::TrackingParameters&, bool shouldClearReferrerOnHTTPSToHTTPRedirect, Seconds maximumBufferingTime, NetworkResourceLoadParameters&);++ bool fillParametersForNetworkProcessLoad(WebCore::ResourceLoader&, const WebCore::ResourceRequest&, const WebResourceLoader::TrackingParameters&, bool shouldClearReferrerOnHTTPSToHTTPRedirect, Seconds maximumBufferingTime, NetworkResourceLoadParameters&);void setExistingNetworkResourceLoadIdentifierToResume(std::optional<NetworkResourceLoadIdentifier> existingNetworkResourceLoadIdentifierToResume) { m_existingNetworkResourceLoadIdentifierToResume = existingNetworkResourceLoadIdentifierToResume; }@@ -20917,7 +20869,7 @@ index dc88916914daebf7c421dc56c2be70fd47727a96..829fdad0490a5e4db8822fbc48c5f19a} // namespace WebKitdiff --git a/Source/WebKit/WebProcess/Network/WebResourceLoader.cpp b/Source/WebKit/WebProcess/Network/WebResourceLoader.cpp-index f0c21a35614b000e0a835ef4a4038feb0224842b..f9aecb9ed77192c00a3173521f72bd840ea6b571 100644+index 9add95853b90e6cae9dd4627ab8bf9a9006bc7a8..f3af1c6680d1dc6d8f6db951a26a526d7079cd95 100644--- a/Source/WebKit/WebProcess/Network/WebResourceLoader.cpp+++ b/Source/WebKit/WebProcess/Network/WebResourceLoader.cpp@@ -202,9 +202,6 @@ void WebResourceLoader::didReceiveResponse(ResourceResponse&& response, PrivateR@@ -20940,17 +20892,17 @@ index f0c21a35614b000e0a835ef4a4038feb0224842b..f9aecb9ed77192c00a3173521f72bd84}diff --git a/Source/WebKit/WebProcess/WebCoreSupport/WebChromeClient.cpp b/Source/WebKit/WebProcess/WebCoreSupport/WebChromeClient.cpp-index 33b01034cea7fc023ba4bef55142ae2700d5e48c..0b0236832df43047a7808af0d422a4572231dc5e 100644+index e532ffcbe13d86fa0de4fbb2c63214615539ba2d..77cf20de73c57756eea1c10349fa666ce733b304 100644--- a/Source/WebKit/WebProcess/WebCoreSupport/WebChromeClient.cpp+++ b/Source/WebKit/WebProcess/WebCoreSupport/WebChromeClient.cpp-@@ -490,6 +490,8 @@ void WebChromeClient::addMessageToConsole(MessageSource source, MessageLevel lev+@@ -491,6 +491,8 @@ void WebChromeClient::addMessageToConsole(MessageSource source, MessageLevel lev{// Notify the bundle client.auto page = protectedPage();+ if (level == MessageLevel::Error)+ page->send(Messages::WebPageProxy::LogToStderr(message));+ // FIXME: Remove this after rdar://143399667 is fixed.page->injectedBundleUIClient().willAddMessageToConsole(page.ptr(), source, level, message, lineNumber, columnNumber, sourceID);- }diff --git a/Source/WebKit/WebProcess/WebCoreSupport/WebDragClient.cpp b/Source/WebKit/WebProcess/WebCoreSupport/WebDragClient.cppindex dd03326b1ad54e1d363d722cfe86bb779fbeead1..f54d631dc4034c995cbd74ec6b545c3c7dd25990 100644@@ -20966,7 +20918,7 @@ index dd03326b1ad54e1d363d722cfe86bb779fbeead1..f54d631dc4034c995cbd74ec6b545c3c{}diff --git a/Source/WebKit/WebProcess/WebCoreSupport/mac/WebDragClientMac.mm b/Source/WebKit/WebProcess/WebCoreSupport/mac/WebDragClientMac.mm-index 2713e431893efd17c95d163f14aec45b27e0d6fc..b96b1d9cba20af611837915412fa4202667e800d 100644+index 6bd8b7c5de08a061c0a155f4783affe9050b8103..610f2b7870588de14f6b658967a9f9acb1a01baa 100644--- a/Source/WebKit/WebProcess/WebCoreSupport/mac/WebDragClientMac.mm+++ b/Source/WebKit/WebProcess/WebCoreSupport/mac/WebDragClientMac.mm@@ -128,7 +128,8 @@ static WebCore::CachedImage* cachedImage(Element& element)@@ -21106,7 +21058,7 @@ index 0000000000000000000000000000000000000000..226b3bf6bd83d2606a0aeb627ae9302f++#endif // ENABLE(DRAG_SUPPORT)diff --git a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp-index ac7fa01ba9a3828cf4c48cacc862aab95145093e..3246812f8ebb8833b2172f9f5f00dff6053387c9 100644+index ac7fa01ba9a3828cf4c48cacc862aab95145093e..89414a407a49d30b937f26cd9cd570c59c51aab3 100644--- a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp+++ b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp@@ -39,6 +39,7 @@@@ -21117,32 +21069,8 @@ index ac7fa01ba9a3828cf4c48cacc862aab95145093e..3246812f8ebb8833b2172f9f5f00dff6#include <WebCore/LocalFrame.h>#include <WebCore/LocalFrameView.h>#include <WebCore/Page.h>-@@ -562,6 +563,11 @@ void DrawingAreaCoordinatedGraphics::enterAcceleratedCompositingMode(GraphicsLay- m_scrollOffset = IntSize();- m_displayTimer.stop();- m_isWaitingForDidUpdate = false;-+// Playwright begin-+#if PLATFORM(WIN)-+ didChangeAcceleratedCompositingMode(true);-+#endif-+// Playwright end- }-- void DrawingAreaCoordinatedGraphics::sendEnterAcceleratedCompositingModeIfNeeded()-@@ -619,6 +625,11 @@ void DrawingAreaCoordinatedGraphics::exitAcceleratedCompositingMode()- // UI process, we still need to let it know about the new contents, so send an Update message.- send(Messages::DrawingAreaProxy::Update(0, WTFMove(updateInfo)));- }-+// Playwright begin-+#if PLATFORM(WIN)-+ didChangeAcceleratedCompositingMode(false);-+#endif-+// Playwright end- }-- void DrawingAreaCoordinatedGraphics::scheduleDisplay()diff --git a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h-index f19473587ec9f1ce8fb2e249feaf1e45b0ec1b80..0908807628b0f96925d3b669b6962f3553f422ca 100644+index 2b955369c53a76ca65613a549bff0d490db48a4c..f67651d2cc64a7f164ff91ad5f613a661976bdbb 100644--- a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h+++ b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h@@ -138,6 +138,7 @@ public:@@ -21154,7 +21082,7 @@ index f19473587ec9f1ce8fb2e249feaf1e45b0ec1b80..0908807628b0f96925d3b669b6962f35void updateRootLayer();WebCore::FloatRect visibleContentsRect() const;diff --git a/Source/WebKit/WebProcess/WebPage/DrawingArea.cpp b/Source/WebKit/WebProcess/WebPage/DrawingArea.cpp-index 5ba445d43ad37ff55f239660cddeada7abe2a6e8..ee3bfd8a34d4e7ea4d632cd8524457f5fb57ef15 100644+index c07ca9e847d03c27877cf650b67b96b3c3f7bddb..b966edc8778d4a68c6e5bae0c0883ab3bfd0a387 100644--- a/Source/WebKit/WebProcess/WebPage/DrawingArea.cpp+++ b/Source/WebKit/WebProcess/WebPage/DrawingArea.cpp@@ -27,6 +27,7 @@@@ -21165,34 +21093,6 @@ index 5ba445d43ad37ff55f239660cddeada7abe2a6e8..ee3bfd8a34d4e7ea4d632cd8524457f5#include "Logging.h"#include "WebPage.h"#include "WebPageCreationParameters.h"-@@ -115,6 +116,13 @@ void DrawingArea::tryMarkLayersVolatile(CompletionHandler<void(bool)>&& completi- completionFunction(true);- }--+#if PLATFORM(WIN)-+void DrawingArea::didChangeAcceleratedCompositingMode(bool enabled)-+{-+ send(Messages::DrawingAreaProxy::DidChangeAcceleratedCompositingMode(enabled));-+}-+#endif-+- void DrawingArea::removeMessageReceiverIfNeeded()- {- if (m_hasRemovedMessageReceiver)-diff --git a/Source/WebKit/WebProcess/WebPage/DrawingArea.h b/Source/WebKit/WebProcess/WebPage/DrawingArea.h-index 6c61c9a0ee5b7a11408d5a0a06f37035e9601e25..a5ddf926e95182bd3575147aff2123f3e6a77109 100644---- a/Source/WebKit/WebProcess/WebPage/DrawingArea.h-+++ b/Source/WebKit/WebProcess/WebPage/DrawingArea.h-@@ -172,6 +172,9 @@ public:- virtual bool enterAcceleratedCompositingModeIfNeeded() = 0;- virtual void backgroundColorDidChange() { };- #endif-+#if PLATFORM(WIN)-+ void didChangeAcceleratedCompositingMode(bool enabled);-+#endif-- #if PLATFORM(WPE) && USE(GBM) && ENABLE(WPE_PLATFORM)- virtual void preferredBufferFormatsDidChange() { }diff --git a/Source/WebKit/WebProcess/WebPage/WebCookieJar.cpp b/Source/WebKit/WebProcess/WebPage/WebCookieJar.cppindex 70a6c3c9ed0fcf42393df2c0fb66eb50d290030d..06fb88ca78db70de4bd4ed9cdf33172bee1a958e 100644--- a/Source/WebKit/WebProcess/WebPage/WebCookieJar.cpp@@ -21232,10 +21132,10 @@ index f9c1d07d4e1f4b5421a627a179ed4f86cf1a1b92..9a8089ed85eebbfb8af0804dfbc0698bvoid setOptInCookiePartitioningEnabled(bool);#endifdiff --git a/Source/WebKit/WebProcess/WebPage/WebPage.cpp b/Source/WebKit/WebProcess/WebPage/WebPage.cpp-index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba155ecaf80 100644+index 4f0c774675bcc9adc7fddd608953bde8840e30dd..224289ffe67a7e16f93d8373eb573849dfb38b06 100644--- a/Source/WebKit/WebProcess/WebPage/WebPage.cpp+++ b/Source/WebKit/WebProcess/WebPage/WebPage.cpp-@@ -241,6 +241,7 @@+@@ -243,6 +243,7 @@#include <WebCore/ImageAnalysisQueue.h>#include <WebCore/ImageOverlay.h>#include <WebCore/InspectorController.h>@@ -21243,7 +21143,7 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1#include <WebCore/JSDOMExceptionHandling.h>#include <WebCore/KeyboardEvent.h>#include <WebCore/LegacySchemeRegistry.h>-@@ -1156,6 +1157,12 @@ WebPage::WebPage(PageIdentifier pageID, WebPageCreationParameters&& parameters)+@@ -1152,6 +1153,12 @@ WebPage::WebPage(PageIdentifier pageID, WebPageCreationParameters&& parameters)setLinkDecorationFilteringData(WTFMove(parameters.linkDecorationFilteringData));setAllowedQueryParametersForAdvancedPrivacyProtections(WTFMove(parameters.allowedQueryParametersForAdvancedPrivacyProtections));#endif@@ -21279,7 +21179,7 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1void WebPage::loadRequest(LoadParameters&& loadParameters){WEBPAGE_RELEASE_LOG_FORWARDABLE(Loading, WEBPAGE_LOADREQUEST, loadParameters.navigationID ? loadParameters.navigationID->toUInt64() : 0, static_cast<unsigned>(loadParameters.shouldTreatAsContinuingLoad), loadParameters.request.isAppInitiated(), loadParameters.existingNetworkResourceLoadIdentifierToResume ? loadParameters.existingNetworkResourceLoadIdentifierToResume->toUInt64() : 0);-@@ -2289,7 +2312,9 @@ void WebPage::stopLoading()+@@ -2290,7 +2313,9 @@ void WebPage::stopLoading()void WebPage::stopLoadingDueToProcessSwap(){SetForScope isStoppingLoadingDueToProcessSwap(m_isStoppingLoadingDueToProcessSwap, true);@@ -21289,7 +21189,7 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1}bool WebPage::defersLoading() const-@@ -2865,7 +2890,7 @@ void WebPage::viewportPropertiesDidChange(const ViewportArguments& viewportArgum+@@ -2866,7 +2891,7 @@ void WebPage::viewportPropertiesDidChange(const ViewportArguments& viewportArgum#if PLATFORM(IOS_FAMILY)if (m_viewportConfiguration.setViewportArguments(viewportArguments))viewportConfigurationChanged();@@ -21298,7 +21198,7 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1// Adjust view dimensions when using fixed layout.RefPtr localMainFrame = this->localMainFrame();RefPtr view = localMainFrame ? localMainFrame->view() : nullptr;-@@ -3652,6 +3677,13 @@ void WebPage::flushDeferredScrollEvents()+@@ -3623,6 +3648,13 @@ void WebPage::flushDeferredScrollEvents()protectedCorePage()->flushDeferredScrollEvents();}@@ -21312,7 +21212,7 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1void WebPage::flushDeferredDidReceiveMouseEvent(){if (auto info = std::exchange(m_deferredDidReceiveMouseEvent, std::nullopt))-@@ -3913,6 +3945,97 @@ void WebPage::touchEvent(const WebTouchEvent& touchEvent, CompletionHandler<void+@@ -3884,6 +3916,97 @@ void WebPage::touchEvent(const WebTouchEvent& touchEvent, CompletionHandler<voidcompletionHandler(touchEvent.type(), handled);}@@ -21410,7 +21310,7 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1#endifvoid WebPage::cancelPointer(WebCore::PointerID pointerId, const WebCore::IntPoint& documentPoint)-@@ -4001,6 +4124,16 @@ void WebPage::sendMessageToTargetBackend(const String& targetId, const String& m+@@ -3972,6 +4095,16 @@ void WebPage::sendMessageToTargetBackend(const String& targetId, const String& mm_inspectorTargetController->sendMessageToTargetBackend(targetId, message);}@@ -21427,7 +21327,7 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1void WebPage::insertNewlineInQuotedContent(){RefPtr frame = protectedCorePage()->checkedFocusController()->focusedOrMainFrame();-@@ -4251,6 +4384,7 @@ void WebPage::setMainFrameDocumentVisualUpdatesAllowed(bool allowed)+@@ -4215,6 +4348,7 @@ void WebPage::setMainFrameDocumentVisualUpdatesAllowed(bool allowed)void WebPage::show(){send(Messages::WebPageProxy::ShowPage());@@ -21435,7 +21335,7 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1}void WebPage::setIsTakingSnapshotsForApplicationSuspension(bool isTakingSnapshotsForApplicationSuspension)-@@ -5439,7 +5573,7 @@ NotificationPermissionRequestManager* WebPage::notificationPermissionRequestMana+@@ -5426,7 +5560,7 @@ RefPtr<NotificationPermissionRequestManager> WebPage::protectedNotificationPermi#if ENABLE(DRAG_SUPPORT)@@ -21444,8 +21344,8 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1void WebPage::performDragControllerAction(DragControllerAction action, const IntPoint& clientPosition, const IntPoint& globalPosition, OptionSet<DragOperation> draggingSourceOperationMask, SelectionData&& selectionData, OptionSet<DragApplicationFlags> flags, CompletionHandler<void(std::optional<DragOperation>, DragHandlingMethod, bool, unsigned, IntRect, IntRect, std::optional<RemoteUserInputEventData>)>&& completionHandler){if (!m_page)-@@ -7914,6 +8048,10 @@ void WebPage::didCommitLoad(WebFrame* frame)- #endif+@@ -7913,6 +8047,10 @@ void WebPage::didCommitLoad(WebFrame* frame)+ m_needsFixedContainerEdgesUpdate = true;flushDeferredDidReceiveMouseEvent();+// Playwright begin@@ -21455,9 +21355,9 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1}void WebPage::didFinishDocumentLoad(WebFrame& frame)-@@ -8233,6 +8371,9 @@ Ref<DocumentLoader> WebPage::createDocumentLoader(LocalFrame& frame, const Resou- WebsitePoliciesData::applyToDocumentLoader(WTFMove(*m_internals->pendingWebsitePolicies), documentLoader);- m_internals->pendingWebsitePolicies = std::nullopt;+@@ -8222,6 +8360,9 @@ Ref<DocumentLoader> WebPage::createDocumentLoader(LocalFrame& frame, const Resou+ m_allowsContentJavaScriptFromMostRecentNavigation = m_internals->pendingWebsitePolicies->allowsContentJavaScript;+ WebsitePoliciesData::applyToDocumentLoader(*std::exchange(m_internals->pendingWebsitePolicies, std::nullopt), documentLoader);}+ } else if (m_pendingFrameNavigationID) {+ documentLoader->setNavigationID(*m_pendingFrameNavigationID);@@ -21466,10 +21366,10 @@ index a790490171adbb2bd153e84f37df524099d11496..6aa0bc62374ce01171b04d7025105ba1return documentLoader;diff --git a/Source/WebKit/WebProcess/WebPage/WebPage.h b/Source/WebKit/WebProcess/WebPage/WebPage.h-index 889f9a1c62a652c3de5e5edb14c9781932b8ef7b..1a708ef7835d63cdaf60db1eb4d5ade6808152b0 100644+index 8bd2bc55df904c4d23bf47d38981581faf89b2af..c0f2d51469875510b65b252b2ba4c15ef252b9c6 100644--- a/Source/WebKit/WebProcess/WebPage/WebPage.h+++ b/Source/WebKit/WebProcess/WebPage/WebPage.h-@@ -43,6 +43,7 @@+@@ -45,6 +45,7 @@#include <WebCore/MediaKeySystemRequest.h>#include <WebCore/NowPlayingMetadataObserver.h>#include <WebCore/OwnerPermissionsPolicyData.h>@@ -21477,7 +21377,7 @@ index 889f9a1c62a652c3de5e5edb14c9781932b8ef7b..1a708ef7835d63cdaf60db1eb4d5ade6#include <WebCore/PageIdentifier.h>#include <WebCore/PageOverlay.h>#include <WebCore/PlatformLayerIdentifier.h>-@@ -1256,11 +1257,11 @@ public:+@@ -1272,11 +1273,11 @@ public:void clearSelection();void restoreSelectionInFocusedEditableElement();@@ -21491,7 +21391,7 @@ index 889f9a1c62a652c3de5e5edb14c9781932b8ef7b..1a708ef7835d63cdaf60db1eb4d5ade6void performDragControllerAction(std::optional<WebCore::FrameIdentifier>, DragControllerAction, WebCore::DragData&&, CompletionHandler<void(std::optional<WebCore::DragOperation>, WebCore::DragHandlingMethod, bool, unsigned, WebCore::IntRect, WebCore::IntRect, std::optional<WebCore::RemoteUserInputEventData>)>&&);void performDragOperation(WebCore::DragData&&, SandboxExtensionHandle&&, Vector<SandboxExtensionHandle>&&, CompletionHandler<void(bool)>&&);#endif-@@ -1275,6 +1276,9 @@ public:+@@ -1291,6 +1292,9 @@ public:void didStartDrag();void dragCancelled();OptionSet<WebCore::DragSourceAction> allowedDragSourceActions() const { return m_allowedDragSourceActions; }@@ -21501,7 +21401,7 @@ index 889f9a1c62a652c3de5e5edb14c9781932b8ef7b..1a708ef7835d63cdaf60db1eb4d5ade6#endif#if ENABLE(MODEL_PROCESS)-@@ -1361,8 +1365,11 @@ public:+@@ -1377,8 +1381,11 @@ public:void gestureEvent(WebCore::FrameIdentifier, const WebGestureEvent&, CompletionHandler<void(std::optional<WebEventType>, bool, std::optional<WebCore::RemoteUserInputEventData>)>&&);#endif@@ -21514,7 +21414,7 @@ index 889f9a1c62a652c3de5e5edb14c9781932b8ef7b..1a708ef7835d63cdaf60db1eb4d5ade6void dynamicViewportSizeUpdate(const DynamicViewportSizeUpdate&);bool scaleWasSetByUIProcess() const { return m_scaleWasSetByUIProcess; }void willStartUserTriggeredZooming();-@@ -1513,6 +1520,8 @@ public:+@@ -1531,6 +1538,8 @@ public:void connectInspector(const String& targetId, Inspector::FrontendChannel::ConnectionType);void disconnectInspector(const String& targetId);void sendMessageToTargetBackend(const String& targetId, const String& message);@@ -21523,7 +21423,7 @@ index 889f9a1c62a652c3de5e5edb14c9781932b8ef7b..1a708ef7835d63cdaf60db1eb4d5ade6void insertNewlineInQuotedContent();-@@ -1930,6 +1939,7 @@ public:+@@ -1949,6 +1958,7 @@ public:void showContextMenuFromFrame(const FrameInfoData&, const ContextMenuContextData&, const UserData&);#endifvoid loadRequest(LoadParameters&&);@@ -21531,7 +21431,7 @@ index 889f9a1c62a652c3de5e5edb14c9781932b8ef7b..1a708ef7835d63cdaf60db1eb4d5ade6void setObscuredContentInsets(const WebCore::FloatBoxExtent&);-@@ -2121,6 +2131,7 @@ private:+@@ -2145,6 +2155,7 @@ private:void updatePotentialTapSecurityOrigin(const WebTouchEvent&, bool wasHandled);#elif ENABLE(TOUCH_EVENTS)void touchEvent(const WebTouchEvent&, CompletionHandler<void(std::optional<WebEventType>, bool)>&&);@@ -21539,7 +21439,7 @@ index 889f9a1c62a652c3de5e5edb14c9781932b8ef7b..1a708ef7835d63cdaf60db1eb4d5ade6#endifvoid cancelPointer(WebCore::PointerID, const WebCore::IntPoint&);-@@ -2884,6 +2895,7 @@ private:+@@ -2913,6 +2924,7 @@ private:UserActivity m_userActivity;Markable<WebCore::NavigationIdentifier> m_pendingNavigationID;@@ -21548,10 +21448,10 @@ index 889f9a1c62a652c3de5e5edb14c9781932b8ef7b..1a708ef7835d63cdaf60db1eb4d5ade6bool m_mainFrameProgressCompleted { false };bool m_shouldDispatchFakeMouseMoveEvents { true };diff --git a/Source/WebKit/WebProcess/WebPage/WebPage.messages.in b/Source/WebKit/WebProcess/WebPage/WebPage.messages.in-index d38d0ecfb0e77838cc6d24b199c8be5d30d13953..1b6ddebd36f1a53a1d34a9157dffc9e8147dae19 100644+index 16e97e9e8d9158d290c98231e2a2a9c3b3d2f567..49d4d7eaaba21b3460dd84583a48501deb337664 100644--- a/Source/WebKit/WebProcess/WebPage/WebPage.messages.in+++ b/Source/WebKit/WebProcess/WebPage/WebPage.messages.in-@@ -57,10 +57,13 @@ messages -> WebPage WantsAsyncDispatchMessage {+@@ -58,10 +58,13 @@ messages -> WebPage WantsAsyncDispatchMessage {MouseEvent(WebCore::FrameIdentifier frameID, WebKit::WebMouseEvent event, std::optional<Vector<WebKit::SandboxExtensionHandle>> sandboxExtensions)SetLastKnownMousePosition(WebCore::FrameIdentifier frameID, WebCore::IntPoint eventPoint, WebCore::IntPoint globalPoint);@@ -21563,10 +21463,10 @@ index d38d0ecfb0e77838cc6d24b199c8be5d30d13953..1b6ddebd36f1a53a1d34a9157dffc9e8SetSceneIdentifier(String sceneIdentifier)SetViewportConfigurationViewLayoutSize(WebCore::FloatSize size, double scaleFactor, double minimumEffectiveDeviceWidth)- SetDeviceOrientation(WebCore::IntDegrees deviceOrientation)- SetOverrideViewportArguments(std::optional<WebCore::ViewportArguments> arguments)+ SetOverrideViewportArguments(struct std::optional<WebCore::ViewportArguments> arguments)DynamicViewportSizeUpdate(struct WebKit::DynamicViewportSizeUpdate target)-@@ -152,6 +155,7 @@ messages -> WebPage WantsAsyncDispatchMessage {+@@ -153,6 +156,7 @@ messages -> WebPage WantsAsyncDispatchMessage {ConnectInspector(String targetId, Inspector::FrontendChannel::ConnectionType connectionType)DisconnectInspector(String targetId)SendMessageToTargetBackend(String targetId, String message)@@ -21574,15 +21474,15 @@ index d38d0ecfb0e77838cc6d24b199c8be5d30d13953..1b6ddebd36f1a53a1d34a9157dffc9e8#if ENABLE(REMOTE_INSPECTOR)SetIndicating(bool indicating);-@@ -162,6 +166,7 @@ messages -> WebPage WantsAsyncDispatchMessage {+@@ -163,6 +167,7 @@ messages -> WebPage WantsAsyncDispatchMessage {#endif#if !ENABLE(IOS_TOUCH_EVENTS) && ENABLE(TOUCH_EVENTS)- TouchEvent(WebKit::WebTouchEvent event) -> (std::optional<WebKit::WebEventType> eventType, bool handled)+ TouchEvent(WebKit::WebTouchEvent event) -> (enum:uint8_t std::optional<WebKit::WebEventType> eventType, bool handled)+ FakeTouchTap(WebCore::IntPoint position, uint8_t modifiers) -> () Async#endifCancelPointer(WebCore::PointerID pointerId, WebCore::IntPoint documentPoint)-@@ -189,6 +194,7 @@ messages -> WebPage WantsAsyncDispatchMessage {+@@ -190,6 +195,7 @@ messages -> WebPage WantsAsyncDispatchMessage {CreateProvisionalFrame(struct WebKit::ProvisionalFrameCreationParameters creationParameters)DestroyProvisionalFrame(WebCore::FrameIdentifier frameID);LoadDidCommitInAnotherProcess(WebCore::FrameIdentifier frameID, std::optional<WebCore::LayerHostingContextIdentifier> layerHostingContextIdentifier)@@ -21590,20 +21490,20 @@ index d38d0ecfb0e77838cc6d24b199c8be5d30d13953..1b6ddebd36f1a53a1d34a9157dffc9e8LoadRequestWaitingForProcessLaunch(struct WebKit::LoadParameters loadParameters, URL resourceDirectoryURL, WebKit::WebPageProxyIdentifier pageID, bool checkAssumedReadAccessToResourceURL)LoadData(struct WebKit::LoadParameters loadParameters)LoadSimulatedRequestAndResponse(struct WebKit::LoadParameters loadParameters, WebCore::ResourceResponse simulatedResponse)-@@ -352,10 +358,10 @@ messages -> WebPage WantsAsyncDispatchMessage {+@@ -351,10 +357,10 @@ messages -> WebPage WantsAsyncDispatchMessage {RemoveLayerForFindOverlay() -> ()# Drag and drop.-#if PLATFORM(GTK) && ENABLE(DRAG_SUPPORT)+#if (PLATFORM(GTK) || PLATFORM(WPE)) && ENABLE(DRAG_SUPPORT)- PerformDragControllerAction(enum:uint8_t WebKit::DragControllerAction action, WebCore::IntPoint clientPosition, WebCore::IntPoint globalPosition, OptionSet<WebCore::DragOperation> draggingSourceOperationMask, WebCore::SelectionData selection, OptionSet<WebCore::DragApplicationFlags> flags) -> (std::optional<WebCore::DragOperation> dragOperation, enum:uint8_t WebCore::DragHandlingMethod dragHandlingMethod, bool mouseIsOverFileInput, unsigned numberOfItemsToBeAccepted, WebCore::IntRect insertionRect, WebCore::IntRect editableElementRect, struct std::optional<WebCore::RemoteUserInputEventData> remoteUserInputEventData)+ PerformDragControllerAction(enum:uint8_t WebKit::DragControllerAction action, WebCore::IntPoint clientPosition, WebCore::IntPoint globalPosition, OptionSet<WebCore::DragOperation> draggingSourceOperationMask, WebCore::SelectionData selection, OptionSet<WebCore::DragApplicationFlags> flags) -> (enum:uint8_t std::optional<WebCore::DragOperation> dragOperation, enum:uint8_t WebCore::DragHandlingMethod dragHandlingMethod, bool mouseIsOverFileInput, unsigned numberOfItemsToBeAccepted, WebCore::IntRect insertionRect, WebCore::IntRect editableElementRect, struct std::optional<WebCore::RemoteUserInputEventData> remoteUserInputEventData)#endif-#if !PLATFORM(GTK) && ENABLE(DRAG_SUPPORT)+#if !PLATFORM(GTK) && !PLATFORM(WPE) && ENABLE(DRAG_SUPPORT)- PerformDragControllerAction(std::optional<WebCore::FrameIdentifier> frameID, enum:uint8_t WebKit::DragControllerAction action, WebCore::DragData dragData) -> (std::optional<WebCore::DragOperation> dragOperation, enum:uint8_t WebCore::DragHandlingMethod dragHandlingMethod, bool mouseIsOverFileInput, unsigned numberOfItemsToBeAccepted, WebCore::IntRect insertionRect, WebCore::IntRect editableElementRect, struct std::optional<WebCore::RemoteUserInputEventData> remoteUserInputEventData)+ PerformDragControllerAction(std::optional<WebCore::FrameIdentifier> frameID, enum:uint8_t WebKit::DragControllerAction action, WebCore::DragData dragData) -> (enum:uint8_t std::optional<WebCore::DragOperation> dragOperation, enum:uint8_t WebCore::DragHandlingMethod dragHandlingMethod, bool mouseIsOverFileInput, unsigned numberOfItemsToBeAccepted, WebCore::IntRect insertionRect, WebCore::IntRect editableElementRect, struct std::optional<WebCore::RemoteUserInputEventData> remoteUserInputEventData)PerformDragOperation(WebCore::DragData dragData, WebKit::SandboxExtensionHandle sandboxExtensionHandle, Vector<WebKit::SandboxExtensionHandle> sandboxExtensionsForUpload) -> (bool handled)#endif-@@ -371,6 +377,10 @@ messages -> WebPage WantsAsyncDispatchMessage {+@@ -370,6 +376,10 @@ messages -> WebPage WantsAsyncDispatchMessage {StageModeSessionDidEnd(std::optional<WebCore::ElementIdentifier> elementID)#endif@@ -21614,16 +21514,54 @@ index d38d0ecfb0e77838cc6d24b199c8be5d30d13953..1b6ddebd36f1a53a1d34a9157dffc9e8#if PLATFORM(IOS_FAMILY) && ENABLE(DRAG_SUPPORT)RequestDragStart(WebCore::IntPoint clientPosition, WebCore::IntPoint globalPosition, OptionSet<WebCore::DragSourceAction> allowedActionsMask)RequestAdditionalItemsForDragSession(WebCore::IntPoint clientPosition, WebCore::IntPoint globalPosition, OptionSet<WebCore::DragSourceAction> allowedActionsMask)+diff --git a/Source/WebKit/WebProcess/WebPage/glib/WebPageGLib.cpp b/Source/WebKit/WebProcess/WebPage/glib/WebPageGLib.cpp+index 40ec42bb4f998774a2ce4a19e82f68512ad2ebb8..080794e14bfbb3a336d8a89791baee0e1aec3c75 100644+--- a/Source/WebKit/WebProcess/WebPage/glib/WebPageGLib.cpp++++ b/Source/WebKit/WebProcess/WebPage/glib/WebPageGLib.cpp+@@ -210,16 +210,23 @@ String WebPage::platformUserAgent(const URL& url) const++ bool WebPage::hoverSupportedByPrimaryPointingDevice() const+ {++ if (screenHasTouchDeviceOverride())++ return !screenHasTouchDeviceOverride().value();+ return WebProcess::singleton().primaryPointingDevice() == AvailableInputDevices::Mouse;+ }++ bool WebPage::hoverSupportedByAnyAvailablePointingDevice() const+ {++ if (screenHasTouchDeviceOverride())++ return !screenHasTouchDeviceOverride().value();+ return WebProcess::singleton().availableInputDevices().contains(AvailableInputDevices::Mouse);+ }++ std::optional<PointerCharacteristics> WebPage::pointerCharacteristicsOfPrimaryPointingDevice() const+ {++ if (screenHasTouchDeviceOverride() && screenHasTouchDeviceOverride().value())++ return PointerCharacteristics::Coarse;+++ const auto& primaryPointingDevice = WebProcess::singleton().primaryPointingDevice();+ if (primaryPointingDevice == AvailableInputDevices::Mouse)+ return PointerCharacteristics::Fine;+@@ -230,6 +237,9 @@ std::optional<PointerCharacteristics> WebPage::pointerCharacteristicsOfPrimaryPo++ OptionSet<PointerCharacteristics> WebPage::pointerCharacteristicsOfAllAvailablePointingDevices() const+ {++ if (screenHasTouchDeviceOverride() && screenHasTouchDeviceOverride().value())++ return PointerCharacteristics::Coarse;+++ OptionSet<PointerCharacteristics> pointerCharacteristics;+ const auto& availableInputs = WebProcess::singleton().availableInputDevices();+ if (availableInputs.contains(AvailableInputDevices::Mouse))diff --git a/Source/WebKit/WebProcess/WebPage/mac/WebPageMac.mm b/Source/WebKit/WebProcess/WebPage/mac/WebPageMac.mm-index 740a118cfe40d803ecccbf2025efa7b813d9b918..c8acb88dd1f3b47332e3928035f74b8bd3c57049 100644+index 932e27ac30ca12459321e4bc1386e7489f647831..ae8dafebd63dbc78c4000dad9f86f3f2208b69b9 100644--- a/Source/WebKit/WebProcess/WebPage/mac/WebPageMac.mm+++ b/Source/WebKit/WebProcess/WebPage/mac/WebPageMac.mm-@@ -696,21 +696,37 @@ String WebPage::platformUserAgent(const URL&) const+@@ -703,21 +703,37 @@ String WebPage::platformUserAgent(const URL&) constbool WebPage::hoverSupportedByPrimaryPointingDevice() const{+#if ENABLE(TOUCH_EVENTS)-+ return !screenIsTouchPrimaryInputDevice();++ return !screenHasTouchDevice();+#elsereturn true;+#endif@@ -21641,7 +21579,7 @@ index 740a118cfe40d803ecccbf2025efa7b813d9b918..c8acb88dd1f3b47332e3928035f74b8bstd::optional<PointerCharacteristics> WebPage::pointerCharacteristicsOfPrimaryPointingDevice() const{+#if ENABLE(TOUCH_EVENTS)-+ if (screenIsTouchPrimaryInputDevice())++ if (screenHasTouchDevice())+ return PointerCharacteristics::Coarse;+#endifreturn PointerCharacteristics::Fine;@@ -21657,7 +21595,7 @@ index 740a118cfe40d803ecccbf2025efa7b813d9b918..c8acb88dd1f3b47332e3928035f74b8b}diff --git a/Source/WebKit/WebProcess/WebPage/win/WebPageWin.cpp b/Source/WebKit/WebProcess/WebPage/win/WebPageWin.cpp-index f17f5d719d892309ed9c7093384945866b5117b9..1dba47bbf0dbd0362548423a74b380346dbea147 100644+index f17f5d719d892309ed9c7093384945866b5117b9..adffe0aa4440c626879e3f5701dd5fea4b2d1a0f 100644--- a/Source/WebKit/WebProcess/WebPage/win/WebPageWin.cpp+++ b/Source/WebKit/WebProcess/WebPage/win/WebPageWin.cpp@@ -43,6 +43,7 @@@@ -21673,7 +21611,7 @@ index f17f5d719d892309ed9c7093384945866b5117b9..1dba47bbf0dbd0362548423a74b38034bool WebPage::hoverSupportedByPrimaryPointingDevice() const{+#if ENABLE(TOUCH_EVENTS)-+ return !screenIsTouchPrimaryInputDevice();++ return !screenHasTouchDevice();+#elsereturn true;+#endif@@ -21691,7 +21629,7 @@ index f17f5d719d892309ed9c7093384945866b5117b9..1dba47bbf0dbd0362548423a74b38034std::optional<PointerCharacteristics> WebPage::pointerCharacteristicsOfPrimaryPointingDevice() const{+#if ENABLE(TOUCH_EVENTS)-+ if (screenIsTouchPrimaryInputDevice())++ if (screenHasTouchDevice())+ return PointerCharacteristics::Coarse;+#endifreturn PointerCharacteristics::Fine;@@ -21707,10 +21645,10 @@ index f17f5d719d892309ed9c7093384945866b5117b9..1dba47bbf0dbd0362548423a74b38034}diff --git a/Source/WebKit/WebProcess/WebProcess.cpp b/Source/WebKit/WebProcess/WebProcess.cpp-index aeaaf015db254f2562085e003a84c29ea8636611..6779f7b116db8f9a0686bef70965cdf9a7d2d6f4 100644+index 757208df2beb144defe64fe4181d972f823ec89a..5c1bc069b031a5787515e787ed9abe441c124971 100644--- a/Source/WebKit/WebProcess/WebProcess.cpp+++ b/Source/WebKit/WebProcess/WebProcess.cpp-@@ -91,6 +91,7 @@+@@ -93,6 +93,7 @@#include "WebsiteData.h"#include "WebsiteDataStoreParameters.h"#include "WebsiteDataType.h"@@ -21718,7 +21656,7 @@ index aeaaf015db254f2562085e003a84c29ea8636611..6779f7b116db8f9a0686bef70965cdf9#include <JavaScriptCore/JSLock.h>#include <JavaScriptCore/MemoryStatistics.h>#include <JavaScriptCore/WasmFaultSignalHandler.h>-@@ -378,6 +379,14 @@ void WebProcess::initializeProcess(const AuxiliaryProcessInitializationParameter+@@ -388,6 +389,14 @@ void WebProcess::initializeProcess(const AuxiliaryProcessInitializationParameter{JSC::Options::AllowUnfinalizedAccessScope scope;JSC::Options::allowNonSPTagging() = false;@@ -21733,7 +21671,7 @@ index aeaaf015db254f2562085e003a84c29ea8636611..6779f7b116db8f9a0686bef70965cdf9JSC::Options::notifyOptionsChanged();}-@@ -385,6 +394,8 @@ void WebProcess::initializeProcess(const AuxiliaryProcessInitializationParameter+@@ -395,6 +404,8 @@ void WebProcess::initializeProcess(const AuxiliaryProcessInitializationParameterplatformInitializeProcess(parameters);updateCPULimit();@@ -21742,16 +21680,17 @@ index aeaaf015db254f2562085e003a84c29ea8636611..6779f7b116db8f9a0686bef70965cdf9}void WebProcess::initializeConnection(IPC::Connection* connection)-@@ -953,6 +964,7 @@ void WebProcess::createWebPage(PageIdentifier pageID, WebPageCreationParameters&+@@ -975,6 +986,8 @@ void WebProcess::createWebPage(PageIdentifier pageID, WebPageCreationParameters&accessibilityRelayProcessSuspended(false);}ASSERT(result.iterator->value);+++ result.iterator->value->didAddWebPageToWebProcess();}void WebProcess::removeWebPage(PageIdentifier pageID)diff --git a/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm b/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm-index 60dc8836dbd8ed1f3f4a2e476d91be6ca7ab0840..20dcdedb9e4eb742c213193eddaa947ac10ec219 100644+index c0fa99b99c2d0464f976bed096ee774db8a7e3c9..7b9fb12ef6198e8a052efe0e6d37768ad161d3aa 100644--- a/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm+++ b/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm@@ -4223,7 +4223,7 @@ ALLOW_DEPRECATED_DECLARATIONS_END@@ -21764,10 +21703,10 @@ index 60dc8836dbd8ed1f3f4a2e476d91be6ca7ab0840..20dcdedb9e4eb742c213193eddaa947a- (void)touch:(WebEvent *)event{diff --git a/Source/WebKitLegacy/mac/WebView/WebView.mm b/Source/WebKitLegacy/mac/WebView/WebView.mm-index e3a23565b11b4dc4eafa3616e15d04e528de8f94..366cf2dd2348350b6dd133ce660ca5b1f73d88d3 100644+index e7d231ff9a7a975d442f9b790a0aad2d666e9972..263d30a59c67e4bd930a1961941a9742760df4d3 100644--- a/Source/WebKitLegacy/mac/WebView/WebView.mm+++ b/Source/WebKitLegacy/mac/WebView/WebView.mm-@@ -3991,7 +3991,7 @@ + (void)_doNotStartObservingNetworkReachability+@@ -3992,7 +3992,7 @@ + (void)_doNotStartObservingNetworkReachability}#endif // PLATFORM(IOS_FAMILY)@@ -21776,7 +21715,7 @@ index e3a23565b11b4dc4eafa3616e15d04e528de8f94..366cf2dd2348350b6dd133ce660ca5b1- (NSArray *)_touchEventRegions{-@@ -4033,7 +4033,7 @@ - (NSArray *)_touchEventRegions+@@ -4034,7 +4034,7 @@ - (NSArray *)_touchEventRegions}).autorelease();}@@ -21817,12 +21756,12 @@ index 0000000000000000000000000000000000000000..dd6a53e2d57318489b7e49dd7373706d+ LIBVPX_LIBRARIES+)diff --git a/Source/cmake/OptionsGTK.cmake b/Source/cmake/OptionsGTK.cmake-index d46ee01c5af78d95469d7cfdb7144e8863f00d5a..4a6d5d34007183f28853e6c5192f282b3925a7ae 100644+index dc6bd15038f36e65b47974960a414b0d7c170e63..da2dba81c6cb4617cc2b946f24060ec8fcf46c87 100644--- a/Source/cmake/OptionsGTK.cmake+++ b/Source/cmake/OptionsGTK.cmake-@@ -8,6 +8,10 @@ SET_PROJECT_VERSION(2 47 4)- set(USER_AGENT_BRANDING "" CACHE STRING "Branding to add to user agent string")+@@ -9,6 +9,10 @@ set(USER_AGENT_BRANDING "" CACHE STRING "Branding to add to user agent string")+ # Update Source/WTF/wtf/Platform.h to match required GLib versions.find_package(GLIB 2.70.0 REQUIRED COMPONENTS gio gio-unix gobject gthread gmodule)++set(CMAKE_THREAD_PREFER_PTHREAD TRUE)@@ -21831,7 +21770,7 @@ index d46ee01c5af78d95469d7cfdb7144e8863f00d5a..4a6d5d34007183f28853e6c5192f282bfind_package(Cairo 1.16.0 REQUIRED)find_package(LibGcrypt 1.7.0 REQUIRED)find_package(Libtasn1 REQUIRED)-@@ -23,6 +27,10 @@ find_package(ZLIB REQUIRED)+@@ -24,6 +28,10 @@ find_package(ZLIB REQUIRED)find_package(WebP REQUIRED COMPONENTS demux)find_package(ATSPI 2.5.3)@@ -21842,7 +21781,7 @@ index d46ee01c5af78d95469d7cfdb7144e8863f00d5a..4a6d5d34007183f28853e6c5192f282binclude(GStreamerDefinitions)include(FindGLibCompileResources)-@@ -70,6 +78,10 @@ WEBKIT_OPTION_DEFINE(USE_SYSTEM_UNIFDEF "Whether to use a system-provided unifde+@@ -71,6 +79,10 @@ WEBKIT_OPTION_DEFINE(USE_SYSTEM_UNIFDEF "Whether to use a system-provided unifdeWEBKIT_OPTION_DEPEND(USE_SYSTEM_SYSPROF_CAPTURE USE_SYSPROF_CAPTURE)@@ -21853,7 +21792,7 @@ index d46ee01c5af78d95469d7cfdb7144e8863f00d5a..4a6d5d34007183f28853e6c5192f282bSET_AND_EXPOSE_TO_BUILD(ENABLE_DEVELOPER_MODE ${DEVELOPER_MODE})if (DEVELOPER_MODE)WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_API_TESTS PRIVATE ON)-@@ -148,6 +160,20 @@ endif ()+@@ -149,6 +161,20 @@ endif ()WEBKIT_OPTION_DEPEND(ENABLE_GPU_PROCESS USE_GBM)@@ -21875,10 +21814,10 @@ index d46ee01c5af78d95469d7cfdb7144e8863f00d5a..4a6d5d34007183f28853e6c5192f282b# Finalize the value for all options. Do not attempt to use an option beforediff --git a/Source/cmake/OptionsWPE.cmake b/Source/cmake/OptionsWPE.cmake-index bb046a1110023fbd6641943d4b677d1fc68cdea5..d34028c618600a172225246db9286e2a7ab1b9eb 100644+index 8c12c0a16e14d3d537704114afc15f6935e17dcd..0c70ff37d45230597a5210e166d242a78bfb8730 100644--- a/Source/cmake/OptionsWPE.cmake+++ b/Source/cmake/OptionsWPE.cmake-@@ -22,6 +22,9 @@ find_package(WebP REQUIRED COMPONENTS demux)+@@ -23,6 +23,9 @@ find_package(WebP REQUIRED COMPONENTS demux)find_package(WPE REQUIRED)find_package(ZLIB REQUIRED)@@ -21888,7 +21827,7 @@ index bb046a1110023fbd6641943d4b677d1fc68cdea5..d34028c618600a172225246db9286e2aWEBKIT_OPTION_BEGIN()SET_AND_EXPOSE_TO_BUILD(ENABLE_DEVELOPER_MODE ${DEVELOPER_MODE})-@@ -84,6 +87,21 @@ if (WPE_VERSION VERSION_GREATER_EQUAL 1.13.90)+@@ -85,6 +88,21 @@ if (WPE_VERSION VERSION_GREATER_EQUAL 1.13.90)WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_GAMEPAD PUBLIC ON)endif ()@@ -21910,7 +21849,7 @@ index bb046a1110023fbd6641943d4b677d1fc68cdea5..d34028c618600a172225246db9286e2a# Public options specific to the WPE port. Do not add any options here unless# there is a strong reason we should support changing the value of the option,# and the option is not relevant to other WebKit ports.-@@ -119,6 +137,11 @@ WEBKIT_OPTION_DEPEND(USE_QT6 ENABLE_WPE_PLATFORM)+@@ -120,6 +138,11 @@ WEBKIT_OPTION_DEPEND(USE_QT6 ENABLE_WPE_PLATFORM)WEBKIT_OPTION_DEPEND(USE_SKIA_OPENTYPE_SVG USE_SKIA)WEBKIT_OPTION_DEPEND(USE_SYSTEM_SYSPROF_CAPTURE USE_SYSPROF_CAPTURE)@@ -21923,10 +21862,10 @@ index bb046a1110023fbd6641943d4b677d1fc68cdea5..d34028c618600a172225246db9286e2aWEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_BUBBLEWRAP_SANDBOX PUBLIC ON)WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_MEMORY_SAMPLER PRIVATE ON)diff --git a/Source/cmake/OptionsWin.cmake b/Source/cmake/OptionsWin.cmake-index b43e68ea44419ed9ea7f539df747cff5d9e4bb36..f62b9a303ad3aba3f04220f1ca9dd208cf3380d4 100644+index ee7c004624e7da8e0a7af18356fc9a378f82020a..9fcabed645095932d997ed5a69a9a5534ac3cb35 100644--- a/Source/cmake/OptionsWin.cmake+++ b/Source/cmake/OptionsWin.cmake-@@ -76,6 +76,27 @@ find_package(ZLIB 1.2.11 REQUIRED)+@@ -73,6 +73,27 @@ find_package(ZLIB 1.2.11 REQUIRED)find_package(LibPSL 0.20.2 REQUIRED)find_package(WebP REQUIRED COMPONENTS demux)@@ -21954,7 +21893,7 @@ index b43e68ea44419ed9ea7f539df747cff5d9e4bb36..f62b9a303ad3aba3f04220f1ca9dd208WEBKIT_OPTION_BEGIN()# FIXME: Most of these options should not be public.-@@ -133,6 +154,14 @@ WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_FTPDIR PRIVATE OFF)+@@ -131,6 +152,14 @@ WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_FTPDIR PRIVATE OFF)SET_AND_EXPOSE_TO_BUILD(ENABLE_WEBDRIVER_KEYBOARD_INTERACTIONS ON)SET_AND_EXPOSE_TO_BUILD(ENABLE_WEBDRIVER_MOUSE_INTERACTIONS ON)@@ -21970,7 +21909,7 @@ index b43e68ea44419ed9ea7f539df747cff5d9e4bb36..f62b9a303ad3aba3f04220f1ca9dd208set(USE_ANGLE_EGL ON)diff --git a/Source/cmake/WebKitCompilerFlags.cmake b/Source/cmake/WebKitCompilerFlags.cmake-index 4882f3de3d9cb011a666563f0bc0e142a705518f..d3f674bf78792088a60a631c245a1fa86dca4d53 100644+index de1cb6c496ccce806010ec1da8f6a4d6d731e0c1..17ea31b9623d939fc2db0249b04caeb8f78fd725 100644--- a/Source/cmake/WebKitCompilerFlags.cmake+++ b/Source/cmake/WebKitCompilerFlags.cmake@@ -122,7 +122,7 @@ macro(WEBKIT_ADD_TARGET_CXX_FLAGS _target)@@ -22385,10 +22324,10 @@ index 8433f5360dc4a5f43b68b67192fb3d9bf5064cf1..9fa8f53e90fe5a32be1c8e7a9daa6404g_clear_object(&interfaceSettings);diff --git a/Tools/MiniBrowser/wpe/main.cpp b/Tools/MiniBrowser/wpe/main.cpp-index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f66566471ad9733f 100644+index 6a898a5bd79a4e6f2f26be7f63347cef7a5c0ab4..d895941dab0f7a0bdfafcf60f203aa82c46874a6 100644--- a/Tools/MiniBrowser/wpe/main.cpp+++ b/Tools/MiniBrowser/wpe/main.cpp-@@ -49,6 +49,9 @@ static gboolean headlessMode;+@@ -52,6 +52,9 @@ static gboolean headlessMode;static gboolean privateMode;static gboolean automationMode;static gboolean ignoreTLSErrors;@@ -22398,7 +22337,7 @@ index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f6656647static const char* contentFilter;static const char* cookiesFile;static const char* cookiesPolicy;-@@ -127,6 +130,9 @@ static const GOptionEntry commandLineOptions[] =+@@ -130,6 +133,9 @@ static const GOptionEntry commandLineOptions[] =#endif{ "size", 's', 0, G_OPTION_ARG_CALLBACK, reinterpret_cast<gpointer>(parseWindowSize), "Specify the window size to use, e.g. --size=\"800x600\"", nullptr },{ "version", 'v', 0, G_OPTION_ARG_NONE, &printVersion, "Print the WPE version", nullptr },@@ -22408,7 +22347,7 @@ index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f6656647{ G_OPTION_REMAINING, 0, 0, G_OPTION_ARG_FILENAME_ARRAY, &uriArguments, nullptr, "[URL]" },{ nullptr, 0, 0, G_OPTION_ARG_NONE, nullptr, nullptr, nullptr }};-@@ -285,15 +291,38 @@ static void filterSavedCallback(WebKitUserContentFilterStore *store, GAsyncResul+@@ -288,15 +294,38 @@ static void filterSavedCallback(WebKitUserContentFilterStore *store, GAsyncResulg_main_loop_quit(data->mainLoop);}@@ -22449,7 +22388,7 @@ index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f6656647{auto backend = createViewBackend(defaultWindowWidthLegacyAPI, defaultWindowHeightLegacyAPI);WebKitWebViewBackend* viewBackend = nullptr;-@@ -308,12 +337,27 @@ static WebKitWebView* createWebView(WebKitWebView* webView, WebKitNavigationActi+@@ -311,12 +340,27 @@ static WebKitWebView* createWebView(WebKitWebView* webView, WebKitNavigationActi}, backend.release());}@@ -22483,18 +22422,23 @@ index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f6656647#if ENABLE_WPE_PLATFORMif (auto* wpeView = webkit_web_view_get_wpe_view(newWebView)) {-@@ -328,6 +372,10 @@ static WebKitWebView* createWebView(WebKitWebView* webView, WebKitNavigationActi-- g_hash_table_add(openViews, newWebView);+@@ -328,9 +372,13 @@ static WebKitWebView* createWebView(WebKitWebView* webView, WebKitNavigationActi+ g_signal_connect(newWebView, "create", G_CALLBACK(createWebView), user_data);+ g_signal_connect(newWebView, "close", G_CALLBACK(webViewClose), user_data);+-++// Playwright begin+ g_signal_connect(newWebView, "load-failed", G_CALLBACK(webViewLoadFailed), nullptr);+ g_signal_connect(newWebView, "script-dialog", G_CALLBACK(scriptDialog), nullptr);+ g_signal_connect(newWebView, "script-dialog-handled", G_CALLBACK(scriptDialogHandled), nullptr);+ g_signal_connect(newWebView, "decide-policy", G_CALLBACK(webViewDecidePolicy), nullptr);++// Playwright end+ g_hash_table_add(openViews, newWebView);+-return newWebView;}-@@ -415,13 +463,105 @@ void loadConfigFile(WPESettings* settings)+@@ -418,13 +466,105 @@ void loadConfigFile(WPESettings* settings)}#endif@@ -22601,7 +22545,7 @@ index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f6656647webkit_network_session_set_itp_enabled(networkSession, enableITP);if (proxy) {-@@ -448,10 +588,18 @@ static void activate(GApplication* application, WPEToolingBackends::ViewBackend*+@@ -451,10 +591,18 @@ static void activate(GApplication* application, WPEToolingBackends::ViewBackend*webkit_cookie_manager_set_persistent_storage(cookieManager, cookiesFile, storageType);}}@@ -22622,7 +22566,7 @@ index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f6656647webkit_website_data_manager_set_itp_enabled(manager, enableITP);if (proxy) {-@@ -482,6 +630,7 @@ static void activate(GApplication* application, WPEToolingBackends::ViewBackend*+@@ -485,6 +633,7 @@ static void activate(GApplication* application, WPEToolingBackends::ViewBackend*}#endif@@ -22630,7 +22574,7 @@ index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f6656647WebKitUserContentManager* userContentManager = nullptr;if (contentFilter) {GFile* contentFilterFile = g_file_new_for_commandline_arg(contentFilter);-@@ -560,6 +709,15 @@ static void activate(GApplication* application, WPEToolingBackends::ViewBackend*+@@ -563,6 +712,15 @@ static void activate(GApplication* application, WPEToolingBackends::ViewBackend*"autoplay", WEBKIT_AUTOPLAY_ALLOW,nullptr);@@ -22646,7 +22590,7 @@ index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f6656647auto* webView = WEBKIT_WEB_VIEW(g_object_new(WEBKIT_TYPE_WEB_VIEW,"backend", viewBackend,"web-context", webContext,-@@ -606,8 +764,6 @@ static void activate(GApplication* application, WPEToolingBackends::ViewBackend*+@@ -609,12 +767,16 @@ static void activate(GApplication* application, WPEToolingBackends::ViewBackend*}#endif@@ -22655,7 +22599,17 @@ index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f6656647g_signal_connect(webContext, "automation-started", G_CALLBACK(automationStartedCallback), webView);g_signal_connect(webView, "permission-request", G_CALLBACK(decidePermissionRequest), nullptr);g_signal_connect(webView, "create", G_CALLBACK(createWebView), application);-@@ -619,16 +775,11 @@ static void activate(GApplication* application, WPEToolingBackends::ViewBackend*+ g_signal_connect(webView, "close", G_CALLBACK(webViewClose), application);++// Playwright begin++ g_signal_connect(webView, "load-failed", G_CALLBACK(webViewLoadFailed), nullptr);++ g_signal_connect(webView, "script-dialog", G_CALLBACK(scriptDialog), nullptr);++ g_signal_connect(webView, "script-dialog-handled", G_CALLBACK(scriptDialogHandled), nullptr);++ g_signal_connect(webView, "decide-policy", G_CALLBACK(webViewDecidePolicy), nullptr);++// Playwright end+ g_hash_table_add(openViews, webView);++ WebKitColor color;+@@ -622,16 +784,11 @@ static void activate(GApplication* application, WPEToolingBackends::ViewBackend*webkit_web_view_set_background_color(webView, &color);if (uriArguments) {@@ -22677,7 +22631,7 @@ index f5403031c914d7fedeb4649c4891beb7d681007e..eb1fe97ebb4e55eb1d4443e5f6656647webkit_web_view_load_uri(webView, "https://wpewebkit.org");g_object_unref(webContext);-@@ -725,8 +876,14 @@ int main(int argc, char *argv[])+@@ -728,8 +885,14 @@ int main(int argc, char *argv[])}}@@ -22705,10 +22659,10 @@ index 1067b31bc989748dfcc5502209d36d001b9b239e..7629263fb8bc93dca6dfc01c75eed8d2+ add_subdirectory(Playwright/win)+endif ()diff --git a/Tools/Scripts/build-webkit b/Tools/Scripts/build-webkit-index ad5ecfe242d13ef1b363215361ae15091a3ffd2a..417325f1742625caf6aff22c9d0b1f5ac061743b 100755+index df483701f5b9c69718669fff32bb35475c7bf0c9..5cff91cb4618417691586a5771291eec9f89bee3 100755--- a/Tools/Scripts/build-webkit+++ b/Tools/Scripts/build-webkit-@@ -273,7 +273,7 @@ if (isAppleCocoaWebKit()) {+@@ -274,7 +274,7 @@ if (isAppleCocoaWebKit()) {push @projects, ("Source/WebKit");if (!isEmbeddedWebKit()) {@@ -22733,19 +22687,27 @@ index 9e53f459e444b9c10fc5248f0e8059df6c1e0041..c17c875a7dd3ca05c4489578ab32378b"${WebKitTestRunner_DIR}/InjectedBundle/Bindings/AccessibilityController.idl""${WebKitTestRunner_DIR}/InjectedBundle/Bindings/AccessibilityTextMarker.idl"diff --git a/Tools/WebKitTestRunner/TestController.cpp b/Tools/WebKitTestRunner/TestController.cpp-index ea8a7dc0d6b63e28ca39e8ecb77fa6c2c3889d32..b3c292fb5db977649e90fbc598626d27ab39a349 100644+index ce8aa4f20d8e0f14a51ae27d8d9440b55e0ea433..cf93f834e135f932ffba7e7101052fcbd9e6b4b2 100644--- a/Tools/WebKitTestRunner/TestController.cpp+++ b/Tools/WebKitTestRunner/TestController.cpp-@@ -1087,6 +1087,7 @@ void TestController::createWebViewWithOptions(const TestOptions& options)- 0, // requestStorageAccessConfirm+@@ -711,6 +711,7 @@ PlatformWebView* TestController::createOtherPlatformWebView(PlatformWebView* par+ nullptr, // requestStorageAccessConfirm+ nullptr, // shouldAllowDeviceOrientationAndMotionAccess+ nullptr, // runWebAuthenticationPanel++ 0, // handleJavaScriptDialog+ nullptr, // decidePolicyForSpeechRecognitionPermissionRequest+ nullptr, // decidePolicyForMediaKeySystemPermissionRequest+ nullptr, // queryPermission+@@ -1186,6 +1187,7 @@ void TestController::createWebViewWithOptions(const TestOptions& options)+ nullptr, // requestStorageAccessConfirmshouldAllowDeviceOrientationAndMotionAccess,runWebAuthenticationPanel,+ 0, // handleJavaScriptDialog- 0,+ nullptr, // decidePolicyForSpeechRecognitionPermissionRequestdecidePolicyForMediaKeySystemPermissionRequest,queryPermission,diff --git a/Tools/WebKitTestRunner/mac/EventSenderProxy.mm b/Tools/WebKitTestRunner/mac/EventSenderProxy.mm-index 0435d345aadde9eaa3a4b7e8625e0872db8c1840..856c36909fd15a178bf1e929aec3d391196f7d36 100644+index 9419696018c076d0e5b4ef04ea7c58be9504cd96..06c537e3c022517449068a11ea59400413e8f4dc 100644--- a/Tools/WebKitTestRunner/mac/EventSenderProxy.mm+++ b/Tools/WebKitTestRunner/mac/EventSenderProxy.mm@@ -961,4 +961,51 @@ void EventSenderProxy::waitForPendingMouseEvents()@@ -22801,7 +22763,7 @@ index 0435d345aadde9eaa3a4b7e8625e0872db8c1840..856c36909fd15a178bf1e929aec3d391+} // namespace WTRdiff --git a/Tools/jhbuild/jhbuild-minimal.modules b/Tools/jhbuild/jhbuild-minimal.modules-index 3a0b7425900b14ce2aa0d48aa914cd69bff1f332..22fb1ab2ea76e1e253c79ba1fa3fa448f7584b43 100644+index 3a0b7425900b14ce2aa0d48aa914cd69bff1f332..0ce07cc1368c6f521b51d6300dca9c4d078beef3 100644--- a/Tools/jhbuild/jhbuild-minimal.modules+++ b/Tools/jhbuild/jhbuild-minimal.modules@@ -67,8 +67,8 @@@@ -22834,6 +22796,17 @@ index 3a0b7425900b14ce2aa0d48aa914cd69bff1f332..22fb1ab2ea76e1e253c79ba1fa3fa448<dependencies><dep package="glib"/><dep package="glib-networking"/>+@@ -194,8 +193,8 @@+ </dependencies>+ <branch module="GNOME/libsoup.git"+ repo="github.com"+- tag="3.6.0"+- version="3.6.0"++ tag="3.6.5"++ version="3.6.5"+ checkoutdir="libsoup-${version}"/>+ </meson>+diff --git a/Tools/wpe/backends/fdo/HeadlessViewBackendFdo.cpp b/Tools/wpe/backends/fdo/HeadlessViewBackendFdo.cppindex df22308266c6f69d24a60905f8d05e4e80f21b9b..2d0838070dc10793418cbb648b095a5ffa76f1b8 100644--- a/Tools/wpe/backends/fdo/HeadlessViewBackendFdo.cpp@@ -22897,7 +22870,7 @@ index df22308266c6f69d24a60905f8d05e4e80f21b9b..2d0838070dc10793418cbb648b095a5fstatic cairo_user_data_key_t bufferKey;cairo_surface_set_user_data(m_snapshot, &bufferKey, buffer,diff --git a/WebKit.xcworkspace/contents.xcworkspacedata b/WebKit.xcworkspace/contents.xcworkspacedata-index a0f02e61be7e667c6ba164ca578109af36ac28d9..8f5af2e82c167ba6798fb7fde24a9f641f6554a5 100644+index 3ad442a8691847c6921c5f66a805b7b0523b1e27..95407368a95d2f7d6fb697110912014cabe29afa 100644--- a/WebKit.xcworkspace/contents.xcworkspacedata+++ b/WebKit.xcworkspace/contents.xcworkspacedata@@ -4,6 +4,9 @@