Web Inspector: Change the InspectorOverlay to use native rather than canvas
authordrousso@apple.com <drousso@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 25 Feb 2019 04:41:53 +0000 (04:41 +0000)
committerdrousso@apple.com <drousso@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 25 Feb 2019 04:41:53 +0000 (04:41 +0000)
commitd16a7e32b28291de5f64677d24d7dfcada0785dc
tree0b721578b60df6e86d96d92d45627c551e5f5299
parent451fc4868dbf6f75d5011065b4895d32463a0c61
Web Inspector: Change the InspectorOverlay to use native rather than canvas
https://bugs.webkit.org/show_bug.cgi?id=105023
<rdar://problem/13443692>

Reviewed by Brian Burg.

.:

* ManualTests/inspector/overlay-nodes.html: Added.
* ManualTests/inspector/overlay-rulers.html: Added.

Source/JavaScriptCore:

* inspector/protocol/OverlayTypes.json: Removed.
Now that the overlay is entirely generated in C++, we no longer need the special prototol
types for transferring data to a JavaScript context.

* inspector/protocol/Debugger.json:
* inspector/agents/InspectorDebuggerAgent.h:
* inspector/agents/InspectorDebuggerAgent.cpp:
(Inspector::InspectorDebuggerAgent::setOverlayMessage): Deleted.
Remove `Debugger.setOverlayMessage` command as it hasn't been used and is no longer supported.

* CMakeLists.txt:
* DerivedSources-input.xcfilelist:
* DerivedSources.make:

Source/WebCore:

Should be no change in observed functionality.

* inspector/InspectorOverlay.h:
* inspector/InspectorOverlay.cpp:
(WebCore::truncateWithEllipsis): Added.
(WebCore::localPointToRootPoint): Added.
(WebCore::contentsQuadToCoordinateSystem):
(WebCore::effectiveElementForNode): Added.
(WebCore::quadToPath): Added.
(WebCore::drawOutlinedQuadWithClip): Added.
(WebCore::drawOutlinedQuad): Added.
(WebCore::drawFragmentHighlight): Added.
(WebCore::drawShapeHighlight): Added.
(WebCore::InspectorOverlay::paint):
(WebCore::InspectorOverlay::setIndicating):
(WebCore::InspectorOverlay::shouldShowOverlay const):
(WebCore::InspectorOverlay::update):
(WebCore::InspectorOverlay::setShowPaintRects): Added.
(WebCore::InspectorOverlay::showPaintRect):
(WebCore::InspectorOverlay::updatePaintRectsTimerFired):
(WebCore::InspectorOverlay::drawNodeHighlight):
(WebCore::InspectorOverlay::drawQuadHighlight):
(WebCore::InspectorOverlay::drawPaintRects):
(WebCore::InspectorOverlay::drawBounds): Added.
(WebCore::InspectorOverlay::drawRulers):
(WebCore::InspectorOverlay::drawElementTitle): Added.
(WebCore::contentsQuadToPage): Deleted.
(WebCore::InspectorOverlay::setPausedInDebuggerMessage): Deleted.
(WebCore::buildObjectForPoint): Deleted.
(WebCore::buildObjectForRect): Deleted.
(WebCore::buildArrayForQuad): Deleted.
(WebCore::buildObjectForHighlight): Deleted.
(WebCore::buildObjectForSize): Deleted.
(WebCore::InspectorOverlay::setShowingPaintRects): Deleted.
(WebCore::buildArrayForRendererFragments): Deleted.
(WebCore::localPointToRoot): Deleted.
(WebCore::appendPathCommandAndPoints): Deleted.
(WebCore::appendPathSegment): Deleted.
(WebCore::buildObjectForShapeOutside): Deleted.
(WebCore::buildObjectForElementData): Deleted.
(WebCore::InspectorOverlay::buildHighlightObjectForNode const): Deleted.
(WebCore::InspectorOverlay::buildObjectForHighlightedNodes const): Deleted.
(WebCore::InspectorOverlay::drawPausedInDebuggerMessage): Deleted.
(WebCore::InspectorOverlay::overlayPage): Deleted.
(WebCore::InspectorOverlay::forcePaint): Deleted.
(WebCore::InspectorOverlay::reset): Deleted.
(WebCore::evaluateCommandInOverlay): Deleted.
(WebCore::InspectorOverlay::evaluateInOverlay): Deleted.
(WebCore::InspectorOverlay::freePage): Deleted.

* inspector/agents/InspectorPageAgent.cpp:
(WebCore::InspectorPageAgent::disable):
(WebCore::InspectorPageAgent::setShowPaintRects):
Drive-by: rename `setShowingPaintRects` to better match the protocol.
* inspector/agents/page/PageDebuggerAgent.h:
* inspector/agents/page/PageDebuggerAgent.cpp:
(WebCore::PageDebuggerAgent::PageDebuggerAgent):
(WebCore::PageDebuggerAgent::setOverlayMessage): Deleted.
Remove `Debugger.setOverlayMessage` command as it hasn't been used and is no longer supported.

* inspector/InspectorController.h:
* inspector/InspectorController.cpp:
(WebCore::InspectorController::createLazyAgents):
(WebCore::InspectorController::disconnectFrontend):
(WebCore::InspectorController::disconnectAllFrontends):
(WebCore::InspectorController::buildObjectForHighlightedNodes const): Deleted.

* testing/Internals.h:
* testing/Internals.idl:
* testing/Internals.cpp:
(WebCore::Internals::inspectorHighlightObject): Deleted.

* inspector/InspectorOverlayPage.css: Removed.
* inspector/InspectorOverlayPage.html: Removed.
* inspector/InspectorOverlayPage.js: Removed.

* CMakeLists.txt:
* DerivedSources-input.xcfilelist:
* DerivedSources-output.xcfilelist:
* DerivedSources.make:
* WebCore.xcodeproj/project.pbxproj:

Source/WebInspectorUI:

* UserInterface/Base/Main.js:
(WI.initializeTarget):

* UserInterface/Protocol/Legacy/10.0/InspectorBackendCommands.js:
* UserInterface/Protocol/Legacy/10.3/InspectorBackendCommands.js:
* UserInterface/Protocol/Legacy/11.0/InspectorBackendCommands.js:
* UserInterface/Protocol/Legacy/11.3/InspectorBackendCommands.js:
* UserInterface/Protocol/Legacy/12.0/InspectorBackendCommands.js:
* UserInterface/Protocol/Legacy/12.2/InspectorBackendCommands.js:
* UserInterface/Protocol/Legacy/8.0/InspectorBackendCommands.js:
* UserInterface/Protocol/Legacy/9.0/InspectorBackendCommands.js:
* UserInterface/Protocol/Legacy/9.3/InspectorBackendCommands.js:
* Versions/Inspector-iOS-10.0.json:
* Versions/Inspector-iOS-10.3.json:
* Versions/Inspector-iOS-11.0.json:
* Versions/Inspector-iOS-11.3.json:
* Versions/Inspector-iOS-12.0.json:
* Versions/Inspector-iOS-12.2.json:
* Versions/Inspector-iOS-8.0.json:
* Versions/Inspector-iOS-9.0.json:
* Versions/Inspector-iOS-9.3.json:
Remove `Debugger.setOverlayMessage` command as it hasn't been used and is no longer supported.

LayoutTests:

* http/tests/inspector/dom/shapes-test.js: Removed.
* inspector/dom/hideHighlight.html: Removed.
* inspector/dom/hideHighlight-expected.txt: Removed.
* inspector/dom/highlight-shape-outside.html: Removed.
* inspector/dom/highlight-shape-outside-expected.txt: Removed.
* inspector/dom/highlight-shape-outside-margin.html: Removed.
* inspector/dom/highlight-shape-outside-margin-expected.txt: Removed.
* inspector/dom/highlightFrame.html: Removed.
* inspector/dom/highlightFrame-expected.txt: Removed.
* inspector/dom/highlightNode.html: Removed.
* inspector/dom/highlightNode-expected.txt: Removed.
* inspector/dom/highlightNodeList.html: Removed.
* inspector/dom/highlightNodeList-expected.txt: Removed.
* inspector/dom/highlightSelector.html: Removed.
* inspector/dom/highlightSelector-expected.txt: Removed.
* platform/mac/TestExpectations:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@242019 268f45cc-cd09-0410-ab3c-d52691b4dbfc
67 files changed:
ChangeLog
LayoutTests/ChangeLog
LayoutTests/http/tests/inspector/dom/shapes-test.js [deleted file]
LayoutTests/inspector/dom/hideHighlight-expected.txt [deleted file]
LayoutTests/inspector/dom/hideHighlight.html [deleted file]
LayoutTests/inspector/dom/highlight-shape-outside-expected.txt [deleted file]
LayoutTests/inspector/dom/highlight-shape-outside-margin-expected.txt [deleted file]
LayoutTests/inspector/dom/highlight-shape-outside-margin.html [deleted file]
LayoutTests/inspector/dom/highlight-shape-outside.html [deleted file]
LayoutTests/inspector/dom/highlightFrame-expected.txt [deleted file]
LayoutTests/inspector/dom/highlightFrame.html [deleted file]
LayoutTests/inspector/dom/highlightNode-expected.txt [deleted file]
LayoutTests/inspector/dom/highlightNode.html [deleted file]
LayoutTests/inspector/dom/highlightNodeList-expected.txt [deleted file]
LayoutTests/inspector/dom/highlightNodeList.html [deleted file]
LayoutTests/inspector/dom/highlightSelector-expected.txt [deleted file]
LayoutTests/inspector/dom/highlightSelector.html [deleted file]
LayoutTests/platform/mac/TestExpectations
ManualTests/inspector/overlay-nodes.html [new file with mode: 0644]
ManualTests/inspector/overlay-rulers.html [new file with mode: 0644]
Source/JavaScriptCore/CMakeLists.txt
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/DerivedSources-input.xcfilelist
Source/JavaScriptCore/DerivedSources.make
Source/JavaScriptCore/inspector/agents/InspectorDebuggerAgent.cpp
Source/JavaScriptCore/inspector/agents/InspectorDebuggerAgent.h
Source/JavaScriptCore/inspector/protocol/Debugger.json
Source/JavaScriptCore/inspector/protocol/OverlayTypes.json [deleted file]
Source/WebCore/CMakeLists.txt
Source/WebCore/ChangeLog
Source/WebCore/DerivedSources-input.xcfilelist
Source/WebCore/DerivedSources-output.xcfilelist
Source/WebCore/DerivedSources.make
Source/WebCore/WebCore.xcodeproj/project.pbxproj
Source/WebCore/inspector/InspectorController.cpp
Source/WebCore/inspector/InspectorController.h
Source/WebCore/inspector/InspectorOverlay.cpp
Source/WebCore/inspector/InspectorOverlay.h
Source/WebCore/inspector/InspectorOverlayPage.css [deleted file]
Source/WebCore/inspector/InspectorOverlayPage.html [deleted file]
Source/WebCore/inspector/InspectorOverlayPage.js [deleted file]
Source/WebCore/inspector/agents/InspectorPageAgent.cpp
Source/WebCore/inspector/agents/page/PageDebuggerAgent.cpp
Source/WebCore/inspector/agents/page/PageDebuggerAgent.h
Source/WebCore/testing/Internals.cpp
Source/WebCore/testing/Internals.h
Source/WebCore/testing/Internals.idl
Source/WebInspectorUI/ChangeLog
Source/WebInspectorUI/UserInterface/Base/Main.js
Source/WebInspectorUI/UserInterface/Protocol/Legacy/10.0/InspectorBackendCommands.js
Source/WebInspectorUI/UserInterface/Protocol/Legacy/10.3/InspectorBackendCommands.js
Source/WebInspectorUI/UserInterface/Protocol/Legacy/11.0/InspectorBackendCommands.js
Source/WebInspectorUI/UserInterface/Protocol/Legacy/11.3/InspectorBackendCommands.js
Source/WebInspectorUI/UserInterface/Protocol/Legacy/12.0/InspectorBackendCommands.js
Source/WebInspectorUI/UserInterface/Protocol/Legacy/12.2/InspectorBackendCommands.js
Source/WebInspectorUI/UserInterface/Protocol/Legacy/8.0/InspectorBackendCommands.js
Source/WebInspectorUI/UserInterface/Protocol/Legacy/9.0/InspectorBackendCommands.js
Source/WebInspectorUI/UserInterface/Protocol/Legacy/9.3/InspectorBackendCommands.js
Source/WebInspectorUI/Versions/Inspector-iOS-10.0.json
Source/WebInspectorUI/Versions/Inspector-iOS-10.3.json
Source/WebInspectorUI/Versions/Inspector-iOS-11.0.json
Source/WebInspectorUI/Versions/Inspector-iOS-11.3.json
Source/WebInspectorUI/Versions/Inspector-iOS-12.0.json
Source/WebInspectorUI/Versions/Inspector-iOS-12.2.json
Source/WebInspectorUI/Versions/Inspector-iOS-8.0.json
Source/WebInspectorUI/Versions/Inspector-iOS-9.0.json
Source/WebInspectorUI/Versions/Inspector-iOS-9.3.json