Web Inspector: Page: re-add enable/disable after r248454
authordrousso@apple.com <drousso@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 21 Aug 2019 16:50:14 +0000 (16:50 +0000)
committerdrousso@apple.com <drousso@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 21 Aug 2019 16:50:14 +0000 (16:50 +0000)
commit51be88b372aa0cfce9f10e5cf4c6632146e8ba46
treef164f19a53dad9aac63ec37a7bf239b63b20d12e
parent0a7c8b7f167669440bbdc8617e350ded28230ad7
Web Inspector: Page: re-add enable/disable after r248454
https://bugs.webkit.org/show_bug.cgi?id=200947

Reviewed by Joseph Pecoraro.

Source/JavaScriptCore:

We shouldn't design the agent system with only Web Inspector in mind. Other clients may want
to have different functionality, not being told about frames creation/updates/destruction.
In these cases, we should have graceful error message failures for other agents that rely on
the Page agent.

* inspector/protocol/Page.json:

Source/WebCore:

We shouldn't design the agent system with only Web Inspector in mind. Other clients may want
to have different functionality, not being told about frames creation/updates/destruction.
In these cases, we should have graceful error message failures for other agents that rely on
the Page agent.

* inspector/agents/InspectorPageAgent.h:
* inspector/agents/InspectorPageAgent.cpp:
(WebCore::InspectorPageAgent::didCreateFrontendAndBackend):
(WebCore::InspectorPageAgent::willDestroyFrontendAndBackend):
(WebCore::InspectorPageAgent::enable): Added.
(WebCore::InspectorPageAgent::disable): Added.

* inspector/agents/InspectorApplicationCacheAgent.cpp:
(WebCore::InspectorApplicationCacheAgent::updateApplicationCacheStatus):
(WebCore::InspectorApplicationCacheAgent::getFramesWithManifests):
(WebCore::InspectorApplicationCacheAgent::assertFrameWithDocumentLoader):
* inspector/agents/InspectorCSSAgent.cpp:
(WebCore::InspectorCSSAgent::createStyleSheet):
* inspector/agents/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::highlightSelector):
(WebCore::InspectorDOMAgent::highlightFrame):
(WebCore::InspectorDOMAgent::buildObjectForNode):
* inspector/agents/InspectorTimelineAgent.cpp:
(WebCore::InspectorTimelineAgent::setFrameIdentifier):
* inspector/agents/page/PageNetworkAgent.cpp:
(WebCore::PageNetworkAgent::loaderIdentifier):
(WebCore::PageNetworkAgent::frameIdentifier):
(WebCore::PageNetworkAgent::scriptExecutionContext):
* inspector/agents/page/PageRuntimeAgent.cpp:
(WebCore::PageRuntimeAgent::didCreateMainWorldContext):
(WebCore::PageRuntimeAgent::reportExecutionContextCreation):

Source/WebInspectorUI:

We shouldn't design the agent system with only Web Inspector in mind. Other clients may want
to have different functionality, not being told about frames creation/updates/destruction.
In these cases, we should have graceful error message failures for other agents that rely on
the Page agent.

* UserInterface/Controllers/NetworkManager.js:
(WI.NetworkManager.prototype.initializeTarget):

LayoutTests:

* http/tests/inspector/page/loading-iframe-document-node.html:
* inspector/css/getMatchedStylesForNode.html:
* inspector/css/getMatchedStylesForNode-expected.txt:
* inspector/page/archive.html:
* inspector/page/frameScheduledNavigation.html:
* inspector/page/frameScheduledNavigation-async-delegates.html:
* inspector/page/frameStartedLoading.html:
* inspector/page/media-query-list-listener-exception.html:
* inspector/timeline/line-column.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248943 268f45cc-cd09-0410-ab3c-d52691b4dbfc
23 files changed:
LayoutTests/ChangeLog
LayoutTests/http/tests/inspector/page/loading-iframe-document-node.html
LayoutTests/inspector/css/getMatchedStylesForNode-expected.txt
LayoutTests/inspector/css/getMatchedStylesForNode.html
LayoutTests/inspector/page/archive.html
LayoutTests/inspector/page/frameScheduledNavigation-async-delegates.html
LayoutTests/inspector/page/frameScheduledNavigation.html
LayoutTests/inspector/page/frameStartedLoading.html
LayoutTests/inspector/page/media-query-list-listener-exception.html
LayoutTests/inspector/timeline/line-column.html
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/inspector/protocol/Page.json
Source/WebCore/ChangeLog
Source/WebCore/inspector/agents/InspectorApplicationCacheAgent.cpp
Source/WebCore/inspector/agents/InspectorCSSAgent.cpp
Source/WebCore/inspector/agents/InspectorDOMAgent.cpp
Source/WebCore/inspector/agents/InspectorPageAgent.cpp
Source/WebCore/inspector/agents/InspectorPageAgent.h
Source/WebCore/inspector/agents/InspectorTimelineAgent.cpp
Source/WebCore/inspector/agents/page/PageNetworkAgent.cpp
Source/WebCore/inspector/agents/page/PageRuntimeAgent.cpp
Source/WebInspectorUI/ChangeLog
Source/WebInspectorUI/UserInterface/Controllers/NetworkManager.js