Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(99)

Unified Diff: third_party/WebKit/Source/core/inspector/InspectorDOMAgent.cpp

Issue 1403853002: Devtools: DOM inspection follows inspect cursor (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/inspector/InspectorDOMAgent.cpp
diff --git a/third_party/WebKit/Source/core/inspector/InspectorDOMAgent.cpp b/third_party/WebKit/Source/core/inspector/InspectorDOMAgent.cpp
index 71742fce16c26ee45a2a12ce73c2a16953d2d1d3..7e0d3fee9979cf111c82fdc4ee6412ca409ba42d 100644
--- a/third_party/WebKit/Source/core/inspector/InspectorDOMAgent.cpp
+++ b/third_party/WebKit/Source/core/inspector/InspectorDOMAgent.cpp
@@ -1110,6 +1110,21 @@ void InspectorDOMAgent::inspect(Node* inspectedNode)
frontend()->inspectNodeRequested(backendNodeId);
}
+void InspectorDOMAgent::nodeHighlightedInOverlay(Node* node)
+{
+ if (!frontend() || !enabled())
+ return;
+
+ while (node && !node->isElementNode() && !node->isDocumentNode() && !node->isDocumentFragment())
+ node = node->parentOrShadowHostNode();
+
+ if (!node)
+ return;
+
+ int nodeId = pushNodePathToFrontend(node);
+ frontend()->nodeHighlightRequested(nodeId);
+}
+
void InspectorDOMAgent::setSearchingForNode(ErrorString* errorString, SearchMode searchMode, JSONObject* highlightInspectorObject)
{
if (m_client)

Powered by Google App Engine
This is Rietveld 408576698