chrome-devtools-frontend 1.0.927127 → 1.0.928589
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AUTHORS +1 -0
- package/config/gni/all_devtools_files.gni +0 -1
- package/config/gni/devtools_grd_files.gni +30 -4
- package/config/gni/devtools_image_files.gni +1 -0
- package/front_end/Images/src/ic_preview_feature.svg +3 -0
- package/front_end/Tests.js +2 -3
- package/front_end/core/common/Settings.ts +26 -45
- package/front_end/core/host/UserMetrics.ts +2 -2
- package/front_end/core/i18n/locales/en-US.json +60 -15
- package/front_end/core/i18n/locales/en-XL.json +60 -15
- package/front_end/core/platform/keyboard-utilities.ts +1 -0
- package/front_end/core/root/Runtime.ts +62 -61
- package/front_end/core/sdk/AccessibilityModel.ts +73 -73
- package/front_end/core/sdk/CPUProfileDataModel.ts +14 -14
- package/front_end/core/sdk/CPUProfilerModel.ts +33 -33
- package/front_end/core/sdk/CPUThrottlingManager.ts +8 -8
- package/front_end/core/sdk/CSSFontFace.ts +10 -10
- package/front_end/core/sdk/CSSMatchedStyles.ts +114 -114
- package/front_end/core/sdk/CSSMedia.ts +22 -22
- package/front_end/core/sdk/CSSMetadata.ts +53 -49
- package/front_end/core/sdk/CSSModel.ts +139 -135
- package/front_end/core/sdk/CSSProperty.ts +18 -18
- package/front_end/core/sdk/CSSRule.ts +15 -15
- package/front_end/core/sdk/CSSStyleDeclaration.ts +49 -47
- package/front_end/core/sdk/CSSStyleSheetHeader.ts +12 -12
- package/front_end/core/sdk/ChildTargetManager.ts +41 -40
- package/front_end/core/sdk/CompilerSourceMappingContentProvider.ts +10 -10
- package/front_end/core/sdk/Connections.ts +81 -81
- package/front_end/core/sdk/ConsoleModel.ts +68 -68
- package/front_end/core/sdk/Cookie.ts +48 -48
- package/front_end/core/sdk/CookieModel.ts +13 -13
- package/front_end/core/sdk/CookieParser.ts +45 -45
- package/front_end/core/sdk/DOMDebuggerModel.ts +131 -131
- package/front_end/core/sdk/DOMModel.ts +264 -252
- package/front_end/core/sdk/DebuggerModel.ts +209 -205
- package/front_end/core/sdk/EmulationModel.ts +76 -76
- package/front_end/core/sdk/FilmStripModel.ts +29 -29
- package/front_end/core/sdk/FrameManager.ts +43 -42
- package/front_end/core/sdk/HeapProfilerModel.ts +36 -36
- package/front_end/core/sdk/IsolateManager.ts +82 -82
- package/front_end/core/sdk/IssuesModel.ts +6 -6
- package/front_end/core/sdk/LayerTreeBase.ts +37 -37
- package/front_end/core/sdk/LogModel.ts +5 -5
- package/front_end/core/sdk/NetworkManager.ts +229 -225
- package/front_end/core/sdk/NetworkRequest.ts +368 -360
- package/front_end/core/sdk/OverlayColorGenerator.ts +9 -9
- package/front_end/core/sdk/OverlayModel.ts +155 -153
- package/front_end/core/sdk/OverlayPersistentHighlighter.ts +100 -101
- package/front_end/core/sdk/PageResourceLoader.ts +30 -30
- package/front_end/core/sdk/PaintProfiler.ts +16 -16
- package/front_end/core/sdk/PerformanceMetricsModel.ts +12 -12
- package/front_end/core/sdk/ProfileTreeModel.ts +3 -3
- package/front_end/core/sdk/RemoteObject.ts +108 -104
- package/front_end/core/sdk/Resource.ts +85 -84
- package/front_end/core/sdk/ResourceTreeModel.ts +150 -145
- package/front_end/core/sdk/RuntimeModel.ts +38 -34
- package/front_end/core/sdk/SDKModel.ts +3 -3
- package/front_end/core/sdk/ScreenCaptureModel.ts +19 -19
- package/front_end/core/sdk/Script.ts +29 -29
- package/front_end/core/sdk/SecurityOriginManager.ts +19 -19
- package/front_end/core/sdk/ServerTiming.ts +2 -2
- package/front_end/core/sdk/ServiceWorkerCacheModel.ts +43 -43
- package/front_end/core/sdk/ServiceWorkerManager.ts +72 -68
- package/front_end/core/sdk/SourceMap.ts +40 -36
- package/front_end/core/sdk/SourceMapManager.ts +57 -57
- package/front_end/core/sdk/Target.ts +64 -63
- package/front_end/core/sdk/TargetManager.ts +60 -56
- package/front_end/core/sdk/TracingManager.ts +39 -39
- package/front_end/core/sdk/TracingModel.ts +125 -125
- package/front_end/core/sdk/WebAuthnModel.ts +9 -9
- package/front_end/entrypoints/lighthouse_worker/{LighthouseService.js → LighthouseService.ts} +20 -45
- package/front_end/entrypoints/lighthouse_worker/{lighthouse_worker.js → lighthouse_worker.ts} +0 -0
- package/front_end/entrypoints/main/MainImpl.ts +7 -2
- package/front_end/legacy_test_runner/elements_test_runner/ElementsTestRunner.js +4 -4
- package/front_end/legacy_test_runner/sdk_test_runner/sdk_test_runner.js +1 -1
- package/front_end/models/bindings/DebuggerWorkspaceBinding.ts +0 -6
- package/front_end/models/issues_manager/GenericIssue.ts +86 -0
- package/front_end/models/issues_manager/Issue.ts +24 -0
- package/front_end/models/issues_manager/IssuesManager.ts +18 -6
- package/front_end/models/issues_manager/descriptions/genericCrossOriginPortalPostMessageError.md +3 -0
- package/front_end/models/issues_manager/issues_manager.ts +2 -0
- package/front_end/models/javascript_metadata/NativeFunctions.js +5422 -1
- package/front_end/panels/console/ConsoleSidebar.ts +0 -3
- package/front_end/panels/elements/ElementsTreeElement.ts +53 -61
- package/front_end/panels/elements/ElementsTreeOutline.ts +0 -1
- package/front_end/panels/elements/components/LayoutPane.ts +5 -1
- package/front_end/panels/issues/GenericIssueDetailsView.ts +68 -0
- package/front_end/panels/issues/IssueAggregator.ts +16 -0
- package/front_end/panels/issues/IssueKindView.ts +95 -0
- package/front_end/panels/issues/IssueView.ts +6 -0
- package/front_end/panels/issues/IssuesPane.ts +81 -18
- package/front_end/panels/issues/issuesTree.css +8 -3
- package/front_end/panels/lighthouse/LighthouseController.ts +3 -1
- package/front_end/panels/network/NetworkItemView.ts +1 -1
- package/front_end/panels/network/networkLogView.css +5 -0
- package/front_end/panels/sensors/LocationsSettingsTab.ts +1 -1
- package/front_end/panels/settings/SettingsScreen.ts +1 -0
- package/front_end/panels/settings/settingsScreen.css +24 -0
- package/front_end/panels/snippets/SnippetsQuickOpen.ts +8 -3
- package/front_end/panels/sources/TabbedEditorContainer.ts +1 -1
- package/front_end/panels/sources/sources-meta.ts +22 -7
- package/front_end/third_party/codemirror.next/chunk/codemirror.js +1 -1
- package/front_end/third_party/codemirror.next/package.json +4 -4
- package/front_end/ui/components/code_highlighter/CodeHighlighter.ts +137 -0
- package/front_end/ui/components/code_highlighter/codeHighlighter.css +51 -0
- package/front_end/ui/components/code_highlighter/code_highlighter.ts +11 -0
- package/front_end/ui/components/docs/text_editor/basic.html +28 -0
- package/front_end/ui/components/docs/text_editor/basic.ts +14 -0
- package/front_end/ui/components/docs/text_prompt/basic.html +35 -0
- package/front_end/ui/components/docs/text_prompt/basic.ts +19 -0
- package/front_end/ui/components/issue_counter/IssueLinkIcon.ts +1 -0
- package/front_end/ui/components/render_coordinator/RenderCoordinator.ts +17 -0
- package/front_end/ui/components/request_link_icon/RequestLinkIcon.ts +1 -0
- package/front_end/ui/components/text_editor/TextEditor.ts +161 -0
- package/front_end/ui/components/text_editor/config.ts +264 -0
- package/front_end/{panels/console/components/components.ts → ui/components/text_editor/text_editor.ts} +2 -5
- package/front_end/ui/components/text_editor/theme.ts +113 -0
- package/front_end/ui/components/text_prompt/TextPrompt.ts +144 -0
- package/front_end/ui/components/text_prompt/textPrompt.css +33 -0
- package/front_end/ui/components/text_prompt/text_prompt.ts +9 -0
- package/front_end/ui/legacy/ARIAUtils.ts +14 -11
- package/front_end/ui/legacy/TabbedPane.ts +32 -3
- package/front_end/ui/legacy/UIUtils.ts +3 -1
- package/front_end/ui/legacy/View.ts +6 -0
- package/front_end/ui/legacy/ViewManager.ts +5 -1
- package/front_end/ui/legacy/ViewRegistration.ts +5 -0
- package/front_end/ui/legacy/XLink.ts +1 -1
- package/front_end/ui/legacy/closeButton.css +6 -0
- package/front_end/ui/legacy/components/quick_open/CommandMenu.ts +8 -3
- package/front_end/ui/legacy/components/quick_open/FilteredListWidget.ts +38 -38
- package/front_end/ui/legacy/components/quick_open/HelpQuickOpen.ts +10 -4
- package/front_end/ui/legacy/components/quick_open/QuickOpen.ts +23 -6
- package/front_end/ui/legacy/components/quick_open/filteredListWidget.css +14 -16
- package/front_end/ui/legacy/filter.css +1 -0
- package/front_end/ui/legacy/tabbedPane.css +24 -0
- package/front_end/ui/legacy/toolbar.css +5 -0
- package/inspector_overlay/main.ts +2 -1
- package/inspector_overlay/tool_screenshot.ts +8 -1
- package/package.json +1 -1
- package/scripts/build/rollup.config.js +9 -0
- package/scripts/migration/class-fields/migrate.js +56 -0
- package/scripts/migration/class-fields/package.json +5 -0
- package/front_end/panels/console/components/SidebarDeprecation.ts +0 -58
- package/front_end/panels/console/components/sidebarDeprecation.css +0 -17
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
// Copyright 2021 The Chromium Authors. All rights reserved.
|
|
2
|
+
// Use of this source code is governed by a BSD-style license that can be
|
|
3
|
+
// found in the LICENSE file.
|
|
4
|
+
|
|
1
5
|
/*
|
|
2
6
|
* Copyright (C) 2011 Google Inc. All rights reserved.
|
|
3
7
|
*
|
|
@@ -11,7 +15,7 @@
|
|
|
11
15
|
* copyright notice, this list of conditions and the following disclaimer
|
|
12
16
|
* in the documentation and/or other materials provided with the
|
|
13
17
|
* distribution.
|
|
14
|
-
* * Neither the name of Google Inc. nor the names of its
|
|
18
|
+
* * Neither the #name of Google Inc. nor the names of its
|
|
15
19
|
* contributors may be used to endorse or promote products derived from
|
|
16
20
|
* this software without specific prior written permission.
|
|
17
21
|
*
|
|
@@ -48,17 +52,17 @@ import {SecurityOriginManager} from './SecurityOriginManager.js';
|
|
|
48
52
|
|
|
49
53
|
export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
50
54
|
readonly agent: ProtocolProxyApi.PageApi;
|
|
51
|
-
|
|
55
|
+
readonly #securityOriginManager: SecurityOriginManager;
|
|
52
56
|
readonly framesInternal: Map<string, ResourceTreeFrame>;
|
|
53
|
-
|
|
54
|
-
|
|
57
|
+
#cachedResourcesProcessed: boolean;
|
|
58
|
+
#pendingReloadOptions: {
|
|
55
59
|
ignoreCache: (boolean|undefined),
|
|
56
60
|
scriptToEvaluateOnLoad: (string|undefined),
|
|
57
61
|
}|null;
|
|
58
|
-
|
|
62
|
+
#reloadSuspensionCount: number;
|
|
59
63
|
isInterstitialShowing: boolean;
|
|
60
64
|
mainFrame: ResourceTreeFrame|null;
|
|
61
|
-
|
|
65
|
+
#pendingBackForwardCacheNotUsedEvents: Set<Protocol.Page.BackForwardCacheNotUsedEvent>;
|
|
62
66
|
|
|
63
67
|
constructor(target: Target) {
|
|
64
68
|
super(target);
|
|
@@ -70,14 +74,14 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
70
74
|
}
|
|
71
75
|
this.agent = target.pageAgent();
|
|
72
76
|
this.agent.invoke_enable();
|
|
73
|
-
this
|
|
74
|
-
this
|
|
77
|
+
this.#securityOriginManager = (target.model(SecurityOriginManager) as SecurityOriginManager);
|
|
78
|
+
this.#pendingBackForwardCacheNotUsedEvents = new Set<Protocol.Page.BackForwardCacheNotUsedEvent>();
|
|
75
79
|
target.registerPageDispatcher(new PageDispatcher(this));
|
|
76
80
|
|
|
77
81
|
this.framesInternal = new Map();
|
|
78
|
-
this
|
|
79
|
-
this
|
|
80
|
-
this
|
|
82
|
+
this.#cachedResourcesProcessed = false;
|
|
83
|
+
this.#pendingReloadOptions = null;
|
|
84
|
+
this.#reloadSuspensionCount = 0;
|
|
81
85
|
this.isInterstitialShowing = false;
|
|
82
86
|
this.mainFrame = null;
|
|
83
87
|
|
|
@@ -137,7 +141,7 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
137
141
|
this.addFramesRecursively(null, mainFramePayload);
|
|
138
142
|
this.target().setInspectedURL(mainFramePayload.frame.url);
|
|
139
143
|
}
|
|
140
|
-
this
|
|
144
|
+
this.#cachedResourcesProcessed = true;
|
|
141
145
|
const runtimeModel = this.target().model(RuntimeModel);
|
|
142
146
|
if (runtimeModel) {
|
|
143
147
|
runtimeModel.setExecutionContextComparator(this.executionContextComparator.bind(this));
|
|
@@ -147,7 +151,7 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
147
151
|
}
|
|
148
152
|
|
|
149
153
|
cachedResourcesLoaded(): boolean {
|
|
150
|
-
return this
|
|
154
|
+
return this.#cachedResourcesProcessed;
|
|
151
155
|
}
|
|
152
156
|
|
|
153
157
|
private addFrame(frame: ResourceTreeFrame, _aboutToNavigate?: boolean): void {
|
|
@@ -164,7 +168,7 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
164
168
|
stackTrace?: Protocol.Runtime.StackTrace): ResourceTreeFrame|null {
|
|
165
169
|
const sameTargetParentFrame = parentFrameId ? (this.framesInternal.get(parentFrameId) || null) : null;
|
|
166
170
|
// Do nothing unless cached resource tree is processed - it will overwrite everything.
|
|
167
|
-
if (!this
|
|
171
|
+
if (!this.#cachedResourcesProcessed && sameTargetParentFrame) {
|
|
168
172
|
return null;
|
|
169
173
|
}
|
|
170
174
|
if (this.framesInternal.has(frameId)) {
|
|
@@ -187,7 +191,7 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
187
191
|
const sameTargetParentFrame =
|
|
188
192
|
framePayload.parentId ? (this.framesInternal.get(framePayload.parentId) || null) : null;
|
|
189
193
|
// Do nothing unless cached resource tree is processed - it will overwrite everything.
|
|
190
|
-
if (!this
|
|
194
|
+
if (!this.#cachedResourcesProcessed && sameTargetParentFrame) {
|
|
191
195
|
return;
|
|
192
196
|
}
|
|
193
197
|
let frame: (ResourceTreeFrame|null) = this.framesInternal.get(framePayload.id) || null;
|
|
@@ -242,7 +246,7 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
242
246
|
|
|
243
247
|
frameDetached(frameId: Protocol.Page.FrameId, isSwap: boolean): void {
|
|
244
248
|
// Do nothing unless cached resource tree is processed - it will overwrite everything.
|
|
245
|
-
if (!this
|
|
249
|
+
if (!this.#cachedResourcesProcessed) {
|
|
246
250
|
return;
|
|
247
251
|
}
|
|
248
252
|
|
|
@@ -261,7 +265,7 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
261
265
|
}
|
|
262
266
|
|
|
263
267
|
private onRequestFinished(event: Common.EventTarget.EventTargetEvent<NetworkRequest>): void {
|
|
264
|
-
if (!this
|
|
268
|
+
if (!this.#cachedResourcesProcessed) {
|
|
265
269
|
return;
|
|
266
270
|
}
|
|
267
271
|
|
|
@@ -277,7 +281,7 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
277
281
|
}
|
|
278
282
|
|
|
279
283
|
private onRequestUpdateDropped(event: Common.EventTarget.EventTargetEvent<RequestUpdateDroppedEventData>): void {
|
|
280
|
-
if (!this
|
|
284
|
+
if (!this.#cachedResourcesProcessed) {
|
|
281
285
|
return;
|
|
282
286
|
}
|
|
283
287
|
|
|
@@ -318,7 +322,7 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
318
322
|
}
|
|
319
323
|
|
|
320
324
|
resourceForURL(url: string): Resource|null {
|
|
321
|
-
// Workers call into this with no frames available.
|
|
325
|
+
// Workers call into this with no #frames available.
|
|
322
326
|
return this.mainFrame ? this.mainFrame.resourceForURL(url) : null;
|
|
323
327
|
}
|
|
324
328
|
|
|
@@ -360,28 +364,28 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
360
364
|
}
|
|
361
365
|
|
|
362
366
|
suspendReload(): void {
|
|
363
|
-
this
|
|
367
|
+
this.#reloadSuspensionCount++;
|
|
364
368
|
}
|
|
365
369
|
|
|
366
370
|
resumeReload(): void {
|
|
367
|
-
this
|
|
368
|
-
console.assert(this
|
|
369
|
-
if (!this
|
|
370
|
-
const {ignoreCache, scriptToEvaluateOnLoad} = this
|
|
371
|
+
this.#reloadSuspensionCount--;
|
|
372
|
+
console.assert(this.#reloadSuspensionCount >= 0, 'Unbalanced call to ResourceTreeModel.resumeReload()');
|
|
373
|
+
if (!this.#reloadSuspensionCount && this.#pendingReloadOptions) {
|
|
374
|
+
const {ignoreCache, scriptToEvaluateOnLoad} = this.#pendingReloadOptions;
|
|
371
375
|
this.reloadPage(ignoreCache, scriptToEvaluateOnLoad);
|
|
372
376
|
}
|
|
373
377
|
}
|
|
374
378
|
|
|
375
379
|
reloadPage(ignoreCache?: boolean, scriptToEvaluateOnLoad?: string): void {
|
|
376
380
|
// Only dispatch PageReloadRequested upon first reload request to simplify client logic.
|
|
377
|
-
if (!this
|
|
381
|
+
if (!this.#pendingReloadOptions) {
|
|
378
382
|
this.dispatchEventToListeners(Events.PageReloadRequested, this);
|
|
379
383
|
}
|
|
380
|
-
if (this
|
|
381
|
-
this
|
|
384
|
+
if (this.#reloadSuspensionCount) {
|
|
385
|
+
this.#pendingReloadOptions = {ignoreCache, scriptToEvaluateOnLoad};
|
|
382
386
|
return;
|
|
383
387
|
}
|
|
384
|
-
this
|
|
388
|
+
this.#pendingReloadOptions = null;
|
|
385
389
|
const networkManager = this.target().model(NetworkManager);
|
|
386
390
|
if (networkManager) {
|
|
387
391
|
networkManager.clearRequests();
|
|
@@ -513,9 +517,9 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
513
517
|
|
|
514
518
|
private updateSecurityOrigins(): void {
|
|
515
519
|
const data = this.getSecurityOriginData();
|
|
516
|
-
this
|
|
520
|
+
this.#securityOriginManager.setMainSecurityOrigin(
|
|
517
521
|
data.mainSecurityOrigin || '', data.unreachableMainSecurityOrigin || '');
|
|
518
|
-
this
|
|
522
|
+
this.#securityOriginManager.updateSecurityOrigins(data.securityOrigins);
|
|
519
523
|
}
|
|
520
524
|
|
|
521
525
|
getMainSecurityOrigin(): string|null {
|
|
@@ -528,7 +532,7 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
528
532
|
this.mainFrame.setBackForwardCacheDetails(event);
|
|
529
533
|
this.dispatchEventToListeners(Events.BackForwardCacheDetailsUpdated, this.mainFrame);
|
|
530
534
|
} else {
|
|
531
|
-
this
|
|
535
|
+
this.#pendingBackForwardCacheNotUsedEvents.add(event);
|
|
532
536
|
}
|
|
533
537
|
}
|
|
534
538
|
|
|
@@ -536,10 +540,10 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
|
|
|
536
540
|
if (!frame.isMainFrame()) {
|
|
537
541
|
return;
|
|
538
542
|
}
|
|
539
|
-
for (const event of this
|
|
543
|
+
for (const event of this.#pendingBackForwardCacheNotUsedEvents) {
|
|
540
544
|
if (frame.id === event.frameId && frame.loaderId === event.loaderId) {
|
|
541
545
|
frame.setBackForwardCacheDetails(event);
|
|
542
|
-
this
|
|
546
|
+
this.#pendingBackForwardCacheNotUsedEvents.delete(event);
|
|
543
547
|
// No need to dispatch the `BackForwardCacheDetailsUpdated` event here,
|
|
544
548
|
// as this method call is followed by a `MainFrameNavigated` event.
|
|
545
549
|
return;
|
|
@@ -591,24 +595,24 @@ export type EventTypes = {
|
|
|
591
595
|
};
|
|
592
596
|
|
|
593
597
|
export class ResourceTreeFrame {
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
598
|
+
#model: ResourceTreeModel;
|
|
599
|
+
#sameTargetParentFrameInternal: ResourceTreeFrame|null;
|
|
600
|
+
readonly #idInternal: Protocol.Page.FrameId;
|
|
597
601
|
crossTargetParentFrameId: string|null;
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
602
|
+
#loaderIdInternal: string;
|
|
603
|
+
#nameInternal: string|null|undefined;
|
|
604
|
+
#urlInternal: string;
|
|
605
|
+
#domainAndRegistryInternal: string;
|
|
606
|
+
#securityOriginInternal: string|null;
|
|
607
|
+
#mimeType: string|null;
|
|
608
|
+
#unreachableUrlInternal: string;
|
|
609
|
+
#adFrameStatusInternal?: Protocol.Page.AdFrameStatus;
|
|
610
|
+
#secureContextType: Protocol.Page.SecureContextType|null;
|
|
611
|
+
#crossOriginIsolatedContextType: Protocol.Page.CrossOriginIsolatedContextType|null;
|
|
612
|
+
#gatedAPIFeatures: Protocol.Page.GatedAPIFeatures[]|null;
|
|
613
|
+
#creationStackTrace: Protocol.Runtime.StackTrace|null;
|
|
614
|
+
#creationStackTraceTarget: Target|null;
|
|
615
|
+
#childFramesInternal: Set<ResourceTreeFrame>;
|
|
612
616
|
resourcesMap: Map<string, Resource>;
|
|
613
617
|
backForwardCacheDetails: {
|
|
614
618
|
restoredFromCache: boolean|undefined,
|
|
@@ -618,144 +622,144 @@ export class ResourceTreeFrame {
|
|
|
618
622
|
constructor(
|
|
619
623
|
model: ResourceTreeModel, parentFrame: ResourceTreeFrame|null, frameId: Protocol.Page.FrameId,
|
|
620
624
|
payload: Protocol.Page.Frame|null, creationStackTrace: Protocol.Runtime.StackTrace|null) {
|
|
621
|
-
this
|
|
622
|
-
this
|
|
623
|
-
this
|
|
625
|
+
this.#model = model;
|
|
626
|
+
this.#sameTargetParentFrameInternal = parentFrame;
|
|
627
|
+
this.#idInternal = frameId;
|
|
624
628
|
this.crossTargetParentFrameId = null;
|
|
625
629
|
|
|
626
|
-
this
|
|
627
|
-
this
|
|
628
|
-
this
|
|
629
|
-
this
|
|
630
|
-
this
|
|
631
|
-
this
|
|
632
|
-
this
|
|
633
|
-
this
|
|
634
|
-
this
|
|
635
|
-
this
|
|
636
|
-
this
|
|
630
|
+
this.#loaderIdInternal = (payload && payload.loaderId) || '';
|
|
631
|
+
this.#nameInternal = payload && payload.name;
|
|
632
|
+
this.#urlInternal = (payload && payload.url) || '';
|
|
633
|
+
this.#domainAndRegistryInternal = (payload && payload.domainAndRegistry) || '';
|
|
634
|
+
this.#securityOriginInternal = payload && payload.securityOrigin;
|
|
635
|
+
this.#mimeType = payload && payload.mimeType;
|
|
636
|
+
this.#unreachableUrlInternal = (payload && payload.unreachableUrl) || '';
|
|
637
|
+
this.#adFrameStatusInternal = payload?.adFrameStatus;
|
|
638
|
+
this.#secureContextType = payload && payload.secureContextType;
|
|
639
|
+
this.#crossOriginIsolatedContextType = payload && payload.crossOriginIsolatedContextType;
|
|
640
|
+
this.#gatedAPIFeatures = payload && payload.gatedAPIFeatures;
|
|
637
641
|
|
|
638
|
-
this
|
|
639
|
-
this
|
|
642
|
+
this.#creationStackTrace = creationStackTrace;
|
|
643
|
+
this.#creationStackTraceTarget = null;
|
|
640
644
|
|
|
641
|
-
this
|
|
645
|
+
this.#childFramesInternal = new Set();
|
|
642
646
|
|
|
643
647
|
this.resourcesMap = new Map();
|
|
644
648
|
|
|
645
|
-
if (this
|
|
646
|
-
this
|
|
649
|
+
if (this.#sameTargetParentFrameInternal) {
|
|
650
|
+
this.#sameTargetParentFrameInternal.#childFramesInternal.add(this);
|
|
647
651
|
}
|
|
648
652
|
}
|
|
649
653
|
|
|
650
654
|
isSecureContext(): boolean {
|
|
651
|
-
return this
|
|
655
|
+
return this.#secureContextType !== null && this.#secureContextType.startsWith('Secure');
|
|
652
656
|
}
|
|
653
657
|
|
|
654
658
|
getSecureContextType(): Protocol.Page.SecureContextType|null {
|
|
655
|
-
return this
|
|
659
|
+
return this.#secureContextType;
|
|
656
660
|
}
|
|
657
661
|
|
|
658
662
|
isCrossOriginIsolated(): boolean {
|
|
659
|
-
return this
|
|
663
|
+
return this.#crossOriginIsolatedContextType !== null && this.#crossOriginIsolatedContextType.startsWith('Isolated');
|
|
660
664
|
}
|
|
661
665
|
|
|
662
666
|
getCrossOriginIsolatedContextType(): Protocol.Page.CrossOriginIsolatedContextType|null {
|
|
663
|
-
return this
|
|
667
|
+
return this.#crossOriginIsolatedContextType;
|
|
664
668
|
}
|
|
665
669
|
|
|
666
670
|
getGatedAPIFeatures(): Protocol.Page.GatedAPIFeatures[]|null {
|
|
667
|
-
return this
|
|
671
|
+
return this.#gatedAPIFeatures;
|
|
668
672
|
}
|
|
669
673
|
|
|
670
674
|
getCreationStackTraceData():
|
|
671
675
|
{creationStackTrace: Protocol.Runtime.StackTrace|null, creationStackTraceTarget: Target} {
|
|
672
676
|
return {
|
|
673
|
-
creationStackTrace: this
|
|
674
|
-
creationStackTraceTarget: this
|
|
677
|
+
creationStackTrace: this.#creationStackTrace,
|
|
678
|
+
creationStackTraceTarget: this.#creationStackTraceTarget || this.resourceTreeModel().target(),
|
|
675
679
|
};
|
|
676
680
|
}
|
|
677
681
|
|
|
678
682
|
navigate(framePayload: Protocol.Page.Frame): void {
|
|
679
|
-
this
|
|
680
|
-
this
|
|
681
|
-
this
|
|
682
|
-
this
|
|
683
|
-
this
|
|
684
|
-
this
|
|
685
|
-
this
|
|
686
|
-
this
|
|
687
|
-
this
|
|
688
|
-
this
|
|
689
|
-
this
|
|
683
|
+
this.#loaderIdInternal = framePayload.loaderId;
|
|
684
|
+
this.#nameInternal = framePayload.name;
|
|
685
|
+
this.#urlInternal = framePayload.url;
|
|
686
|
+
this.#domainAndRegistryInternal = framePayload.domainAndRegistry;
|
|
687
|
+
this.#securityOriginInternal = framePayload.securityOrigin;
|
|
688
|
+
this.#mimeType = framePayload.mimeType;
|
|
689
|
+
this.#unreachableUrlInternal = framePayload.unreachableUrl || '';
|
|
690
|
+
this.#adFrameStatusInternal = framePayload?.adFrameStatus;
|
|
691
|
+
this.#secureContextType = framePayload.secureContextType;
|
|
692
|
+
this.#crossOriginIsolatedContextType = framePayload.crossOriginIsolatedContextType;
|
|
693
|
+
this.#gatedAPIFeatures = framePayload.gatedAPIFeatures;
|
|
690
694
|
this.backForwardCacheDetails = {restoredFromCache: undefined, explanations: []};
|
|
691
695
|
|
|
692
|
-
const mainResource = this.resourcesMap.get(this
|
|
696
|
+
const mainResource = this.resourcesMap.get(this.#urlInternal);
|
|
693
697
|
this.resourcesMap.clear();
|
|
694
698
|
this.removeChildFrames();
|
|
695
|
-
if (mainResource && mainResource.loaderId === this
|
|
699
|
+
if (mainResource && mainResource.loaderId === this.#loaderIdInternal) {
|
|
696
700
|
this.addResource(mainResource);
|
|
697
701
|
}
|
|
698
702
|
}
|
|
699
703
|
|
|
700
704
|
resourceTreeModel(): ResourceTreeModel {
|
|
701
|
-
return this
|
|
705
|
+
return this.#model;
|
|
702
706
|
}
|
|
703
707
|
|
|
704
708
|
get id(): Protocol.Page.FrameId {
|
|
705
|
-
return this
|
|
709
|
+
return this.#idInternal;
|
|
706
710
|
}
|
|
707
711
|
|
|
708
712
|
get name(): string {
|
|
709
|
-
return this
|
|
713
|
+
return this.#nameInternal || '';
|
|
710
714
|
}
|
|
711
715
|
|
|
712
716
|
get url(): string {
|
|
713
|
-
return this
|
|
717
|
+
return this.#urlInternal;
|
|
714
718
|
}
|
|
715
719
|
|
|
716
720
|
domainAndRegistry(): string {
|
|
717
|
-
return this
|
|
721
|
+
return this.#domainAndRegistryInternal;
|
|
718
722
|
}
|
|
719
723
|
|
|
720
724
|
get securityOrigin(): string|null {
|
|
721
|
-
return this
|
|
725
|
+
return this.#securityOriginInternal;
|
|
722
726
|
}
|
|
723
727
|
|
|
724
728
|
unreachableUrl(): string {
|
|
725
|
-
return this
|
|
729
|
+
return this.#unreachableUrlInternal;
|
|
726
730
|
}
|
|
727
731
|
|
|
728
732
|
get loaderId(): string {
|
|
729
|
-
return this
|
|
733
|
+
return this.#loaderIdInternal;
|
|
730
734
|
}
|
|
731
735
|
|
|
732
736
|
adFrameType(): Protocol.Page.AdFrameType {
|
|
733
|
-
return this
|
|
737
|
+
return this.#adFrameStatusInternal?.adFrameType || Protocol.Page.AdFrameType.None;
|
|
734
738
|
}
|
|
735
739
|
|
|
736
740
|
adFrameStatus(): Protocol.Page.AdFrameStatus|undefined {
|
|
737
|
-
return this
|
|
741
|
+
return this.#adFrameStatusInternal;
|
|
738
742
|
}
|
|
739
743
|
|
|
740
744
|
get childFrames(): ResourceTreeFrame[] {
|
|
741
|
-
return [...this
|
|
745
|
+
return [...this.#childFramesInternal];
|
|
742
746
|
}
|
|
743
747
|
|
|
744
748
|
/**
|
|
745
|
-
* Returns the parent frame if both frames are part of the same process/target.
|
|
749
|
+
* Returns the parent frame if both #frames are part of the same process/target.
|
|
746
750
|
*/
|
|
747
751
|
sameTargetParentFrame(): ResourceTreeFrame|null {
|
|
748
|
-
return this
|
|
752
|
+
return this.#sameTargetParentFrameInternal;
|
|
749
753
|
}
|
|
750
754
|
|
|
751
755
|
/**
|
|
752
|
-
* Returns the parent frame if both frames are part of different processes/targets (child is an OOPIF).
|
|
756
|
+
* Returns the parent frame if both #frames are part of different processes/targets (child is an OOPIF).
|
|
753
757
|
*/
|
|
754
758
|
crossTargetParentFrame(): ResourceTreeFrame|null {
|
|
755
759
|
if (!this.crossTargetParentFrameId) {
|
|
756
760
|
return null;
|
|
757
761
|
}
|
|
758
|
-
const parentTarget = this
|
|
762
|
+
const parentTarget = this.#model.target().parentTarget();
|
|
759
763
|
if (!parentTarget) {
|
|
760
764
|
return null;
|
|
761
765
|
}
|
|
@@ -763,11 +767,11 @@ export class ResourceTreeFrame {
|
|
|
763
767
|
if (!parentModel) {
|
|
764
768
|
return null;
|
|
765
769
|
}
|
|
766
|
-
// Note that parent model has already processed cached resources:
|
|
770
|
+
// Note that parent #model has already processed cached resources:
|
|
767
771
|
// - when parent target was created, we issued getResourceTree call;
|
|
768
772
|
// - strictly after we issued setAutoAttach call;
|
|
769
773
|
// - both of them were handled in renderer in the same order;
|
|
770
|
-
// - cached resource tree got processed on parent model;
|
|
774
|
+
// - cached resource tree got processed on parent #model;
|
|
771
775
|
// - child target was created as a result of setAutoAttach call.
|
|
772
776
|
return parentModel.framesInternal.get(this.crossTargetParentFrameId) || null;
|
|
773
777
|
}
|
|
@@ -785,7 +789,7 @@ export class ResourceTreeFrame {
|
|
|
785
789
|
* of an out-of-process iframe (OOPIF).
|
|
786
790
|
*/
|
|
787
791
|
isMainFrame(): boolean {
|
|
788
|
-
return !this
|
|
792
|
+
return !this.#sameTargetParentFrameInternal;
|
|
789
793
|
}
|
|
790
794
|
|
|
791
795
|
/**
|
|
@@ -793,17 +797,18 @@ export class ResourceTreeFrame {
|
|
|
793
797
|
* tab.
|
|
794
798
|
*/
|
|
795
799
|
isTopFrame(): boolean {
|
|
796
|
-
return !this
|
|
800
|
+
return !this.#model.target().parentTarget() && !this.#sameTargetParentFrameInternal &&
|
|
801
|
+
!this.crossTargetParentFrameId;
|
|
797
802
|
}
|
|
798
803
|
|
|
799
804
|
removeChildFrame(frame: ResourceTreeFrame, isSwap: boolean): void {
|
|
800
|
-
this
|
|
805
|
+
this.#childFramesInternal.delete(frame);
|
|
801
806
|
frame.remove(isSwap);
|
|
802
807
|
}
|
|
803
808
|
|
|
804
809
|
private removeChildFrames(): void {
|
|
805
|
-
const frames = this
|
|
806
|
-
this
|
|
810
|
+
const frames = this.#childFramesInternal;
|
|
811
|
+
this.#childFramesInternal = new Set();
|
|
807
812
|
for (const frame of frames) {
|
|
808
813
|
frame.remove(false);
|
|
809
814
|
}
|
|
@@ -811,8 +816,8 @@ export class ResourceTreeFrame {
|
|
|
811
816
|
|
|
812
817
|
remove(isSwap: boolean): void {
|
|
813
818
|
this.removeChildFrames();
|
|
814
|
-
this
|
|
815
|
-
this
|
|
819
|
+
this.#model.framesInternal.delete(this.id);
|
|
820
|
+
this.#model.dispatchEventToListeners(Events.FrameDetached, {frame: this, isSwap});
|
|
816
821
|
}
|
|
817
822
|
|
|
818
823
|
addResource(resource: Resource): void {
|
|
@@ -821,7 +826,7 @@ export class ResourceTreeFrame {
|
|
|
821
826
|
return;
|
|
822
827
|
}
|
|
823
828
|
this.resourcesMap.set(resource.url, resource);
|
|
824
|
-
this
|
|
829
|
+
this.#model.dispatchEventToListeners(Events.ResourceAdded, resource);
|
|
825
830
|
}
|
|
826
831
|
|
|
827
832
|
addRequest(request: NetworkRequest): void {
|
|
@@ -831,10 +836,10 @@ export class ResourceTreeFrame {
|
|
|
831
836
|
return;
|
|
832
837
|
}
|
|
833
838
|
resource = new Resource(
|
|
834
|
-
this
|
|
839
|
+
this.#model, request, request.url(), request.documentURL, request.frameId, request.loaderId,
|
|
835
840
|
request.resourceType(), request.mimeType, null, null);
|
|
836
841
|
this.resourcesMap.set(resource.url, resource);
|
|
837
|
-
this
|
|
842
|
+
this.#model.dispatchEventToListeners(Events.ResourceAdded, resource);
|
|
838
843
|
}
|
|
839
844
|
|
|
840
845
|
resources(): Resource[] {
|
|
@@ -846,7 +851,7 @@ export class ResourceTreeFrame {
|
|
|
846
851
|
if (resource) {
|
|
847
852
|
return resource;
|
|
848
853
|
}
|
|
849
|
-
for (const frame of this
|
|
854
|
+
for (const frame of this.#childFramesInternal) {
|
|
850
855
|
const resource = frame.resourceForURL(url);
|
|
851
856
|
if (resource) {
|
|
852
857
|
return resource;
|
|
@@ -862,7 +867,7 @@ export class ResourceTreeFrame {
|
|
|
862
867
|
}
|
|
863
868
|
}
|
|
864
869
|
|
|
865
|
-
for (const frame of this
|
|
870
|
+
for (const frame of this.#childFramesInternal) {
|
|
866
871
|
if (frame.callForFrameResources(callback)) {
|
|
867
872
|
return true;
|
|
868
873
|
}
|
|
@@ -874,12 +879,12 @@ export class ResourceTreeFrame {
|
|
|
874
879
|
if (this.isTopFrame()) {
|
|
875
880
|
return i18n.i18n.lockedString('top');
|
|
876
881
|
}
|
|
877
|
-
const subtitle = new Common.ParsedURL.ParsedURL(this
|
|
882
|
+
const subtitle = new Common.ParsedURL.ParsedURL(this.#urlInternal).displayName;
|
|
878
883
|
if (subtitle) {
|
|
879
|
-
if (!this
|
|
884
|
+
if (!this.#nameInternal) {
|
|
880
885
|
return subtitle;
|
|
881
886
|
}
|
|
882
|
-
return this
|
|
887
|
+
return this.#nameInternal + ' (' + subtitle + ')';
|
|
883
888
|
}
|
|
884
889
|
return i18n.i18n.lockedString('iframe');
|
|
885
890
|
}
|
|
@@ -889,7 +894,7 @@ export class ResourceTreeFrame {
|
|
|
889
894
|
if (!parentFrame) {
|
|
890
895
|
return null;
|
|
891
896
|
}
|
|
892
|
-
return parentFrame.resourceTreeModel().domModel().getOwnerNodeForFrame(this
|
|
897
|
+
return parentFrame.resourceTreeModel().domModel().getOwnerNodeForFrame(this.#idInternal);
|
|
893
898
|
}
|
|
894
899
|
|
|
895
900
|
async getOwnerDOMNodeOrDocument(): Promise<DOMNode|null> {
|
|
@@ -907,7 +912,7 @@ export class ResourceTreeFrame {
|
|
|
907
912
|
const parentFrame = this.parentFrame();
|
|
908
913
|
const parentTarget = this.resourceTreeModel().target().parentTarget();
|
|
909
914
|
const highlightFrameOwner = async(domModel: DOMModel): Promise<void> => {
|
|
910
|
-
const deferredNode = await domModel.getOwnerNodeForFrame(this
|
|
915
|
+
const deferredNode = await domModel.getOwnerNodeForFrame(this.#idInternal);
|
|
911
916
|
if (deferredNode) {
|
|
912
917
|
domModel.overlayModel().highlightInOverlay({deferredNode, selectorList: ''}, 'all', true);
|
|
913
918
|
}
|
|
@@ -925,7 +930,7 @@ export class ResourceTreeFrame {
|
|
|
925
930
|
}
|
|
926
931
|
}
|
|
927
932
|
|
|
928
|
-
// For the top frame there is no owner node. Highlight the whole document instead.
|
|
933
|
+
// For the top frame there is no owner node. Highlight the whole #document instead.
|
|
929
934
|
const document = await this.resourceTreeModel().domModel().requestDocument();
|
|
930
935
|
if (document) {
|
|
931
936
|
this.resourceTreeModel().domModel().overlayModel().highlightInOverlay(
|
|
@@ -935,7 +940,7 @@ export class ResourceTreeFrame {
|
|
|
935
940
|
|
|
936
941
|
async getPermissionsPolicyState(): Promise<Protocol.Page.PermissionsPolicyFeatureState[]|null> {
|
|
937
942
|
const response = await this.resourceTreeModel().target().pageAgent().invoke_getPermissionsPolicyState(
|
|
938
|
-
{frameId: this
|
|
943
|
+
{frameId: this.#idInternal});
|
|
939
944
|
if (response.getError()) {
|
|
940
945
|
return null;
|
|
941
946
|
}
|
|
@@ -944,7 +949,7 @@ export class ResourceTreeFrame {
|
|
|
944
949
|
|
|
945
950
|
async getOriginTrials(): Promise<Protocol.Page.OriginTrial[]> {
|
|
946
951
|
const response =
|
|
947
|
-
await this.resourceTreeModel().target().pageAgent().invoke_getOriginTrials({frameId: this
|
|
952
|
+
await this.resourceTreeModel().target().pageAgent().invoke_getOriginTrials({frameId: this.#idInternal});
|
|
948
953
|
if (response.getError()) {
|
|
949
954
|
return [];
|
|
950
955
|
}
|
|
@@ -954,8 +959,8 @@ export class ResourceTreeFrame {
|
|
|
954
959
|
setCreationStackTrace(creationStackTraceData:
|
|
955
960
|
{creationStackTrace: Protocol.Runtime.StackTrace|null, creationStackTraceTarget: Target}):
|
|
956
961
|
void {
|
|
957
|
-
this
|
|
958
|
-
this
|
|
962
|
+
this.#creationStackTrace = creationStackTraceData.creationStackTrace;
|
|
963
|
+
this.#creationStackTraceTarget = creationStackTraceData.creationStackTraceTarget;
|
|
959
964
|
}
|
|
960
965
|
|
|
961
966
|
setBackForwardCacheDetails(event: Protocol.Page.BackForwardCacheNotUsedEvent): void {
|
|
@@ -969,41 +974,41 @@ export class ResourceTreeFrame {
|
|
|
969
974
|
}
|
|
970
975
|
|
|
971
976
|
export class PageDispatcher implements ProtocolProxyApi.PageDispatcher {
|
|
972
|
-
|
|
977
|
+
#resourceTreeModel: ResourceTreeModel;
|
|
973
978
|
constructor(resourceTreeModel: ResourceTreeModel) {
|
|
974
|
-
this
|
|
979
|
+
this.#resourceTreeModel = resourceTreeModel;
|
|
975
980
|
}
|
|
976
981
|
backForwardCacheNotUsed(params: Protocol.Page.BackForwardCacheNotUsedEvent): void {
|
|
977
|
-
this
|
|
982
|
+
this.#resourceTreeModel.onBackForwardCacheNotUsed(params);
|
|
978
983
|
}
|
|
979
984
|
|
|
980
985
|
domContentEventFired({timestamp}: Protocol.Page.DomContentEventFiredEvent): void {
|
|
981
|
-
this
|
|
986
|
+
this.#resourceTreeModel.dispatchEventToListeners(Events.DOMContentLoaded, timestamp);
|
|
982
987
|
}
|
|
983
988
|
|
|
984
989
|
loadEventFired({timestamp}: Protocol.Page.LoadEventFiredEvent): void {
|
|
985
|
-
this
|
|
986
|
-
Events.Load, {resourceTreeModel: this
|
|
990
|
+
this.#resourceTreeModel.dispatchEventToListeners(
|
|
991
|
+
Events.Load, {resourceTreeModel: this.#resourceTreeModel, loadTime: timestamp});
|
|
987
992
|
}
|
|
988
993
|
|
|
989
994
|
lifecycleEvent({frameId, name}: Protocol.Page.LifecycleEventEvent): void {
|
|
990
|
-
this
|
|
995
|
+
this.#resourceTreeModel.dispatchEventToListeners(Events.LifecycleEvent, {frameId, name});
|
|
991
996
|
}
|
|
992
997
|
|
|
993
998
|
frameAttached({frameId, parentFrameId, stack}: Protocol.Page.FrameAttachedEvent): void {
|
|
994
|
-
this
|
|
999
|
+
this.#resourceTreeModel.frameAttached(frameId, parentFrameId, stack);
|
|
995
1000
|
}
|
|
996
1001
|
|
|
997
1002
|
frameNavigated({frame, type}: Protocol.Page.FrameNavigatedEvent): void {
|
|
998
|
-
this
|
|
1003
|
+
this.#resourceTreeModel.frameNavigated(frame, type);
|
|
999
1004
|
}
|
|
1000
1005
|
|
|
1001
1006
|
documentOpened({frame}: Protocol.Page.DocumentOpenedEvent): void {
|
|
1002
|
-
this
|
|
1007
|
+
this.#resourceTreeModel.documentOpened(frame);
|
|
1003
1008
|
}
|
|
1004
1009
|
|
|
1005
1010
|
frameDetached({frameId, reason}: Protocol.Page.FrameDetachedEvent): void {
|
|
1006
|
-
this
|
|
1011
|
+
this.#resourceTreeModel.frameDetached(frameId, reason === Protocol.Page.FrameDetachedEventReason.Swap);
|
|
1007
1012
|
}
|
|
1008
1013
|
|
|
1009
1014
|
frameStartedLoading({}: Protocol.Page.FrameStartedLoadingEvent): void {
|
|
@@ -1025,12 +1030,12 @@ export class PageDispatcher implements ProtocolProxyApi.PageDispatcher {
|
|
|
1025
1030
|
}
|
|
1026
1031
|
|
|
1027
1032
|
frameResized(): void {
|
|
1028
|
-
this
|
|
1033
|
+
this.#resourceTreeModel.dispatchEventToListeners(Events.FrameResized);
|
|
1029
1034
|
}
|
|
1030
1035
|
|
|
1031
1036
|
javascriptDialogOpening({hasBrowserHandler}: Protocol.Page.JavascriptDialogOpeningEvent): void {
|
|
1032
1037
|
if (!hasBrowserHandler) {
|
|
1033
|
-
this
|
|
1038
|
+
this.#resourceTreeModel.agent.invoke_handleJavaScriptDialog({accept: false});
|
|
1034
1039
|
}
|
|
1035
1040
|
}
|
|
1036
1041
|
|
|
@@ -1044,13 +1049,13 @@ export class PageDispatcher implements ProtocolProxyApi.PageDispatcher {
|
|
|
1044
1049
|
}
|
|
1045
1050
|
|
|
1046
1051
|
interstitialShown(): void {
|
|
1047
|
-
this
|
|
1048
|
-
this
|
|
1052
|
+
this.#resourceTreeModel.isInterstitialShowing = true;
|
|
1053
|
+
this.#resourceTreeModel.dispatchEventToListeners(Events.InterstitialShown);
|
|
1049
1054
|
}
|
|
1050
1055
|
|
|
1051
1056
|
interstitialHidden(): void {
|
|
1052
|
-
this
|
|
1053
|
-
this
|
|
1057
|
+
this.#resourceTreeModel.isInterstitialShowing = false;
|
|
1058
|
+
this.#resourceTreeModel.dispatchEventToListeners(Events.InterstitialHidden);
|
|
1054
1059
|
}
|
|
1055
1060
|
|
|
1056
1061
|
windowOpen({}: Protocol.Page.WindowOpenEvent): void {
|