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

Unified Diff: Source/devtools/front_end/network/NetworkPanel.js

Issue 634543002: DevTools: NetworkPanel: update hovered row labels when graph is updated. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/devtools/front_end/network/NetworkPanel.js
diff --git a/Source/devtools/front_end/network/NetworkPanel.js b/Source/devtools/front_end/network/NetworkPanel.js
index b74e9678710ee0d2b30cfed4f8c3a615ec366324..7576f404099d8a5f7e734c3af921691643d8b811 100644
--- a/Source/devtools/front_end/network/NetworkPanel.js
+++ b/Source/devtools/front_end/network/NetworkPanel.js
@@ -2555,6 +2555,8 @@ WebInspector.NetworkDataGridNode = function(parentView, request)
this._staleGraph = true;
}
+WebInspector.NetworkDataGridNode._hoveredRowSymbol = Symbol("hoveredRow");
+
WebInspector.NetworkDataGridNode.prototype = {
/**
* @return {!WebInspector.NetworkRequest}
@@ -2717,7 +2719,16 @@ WebInspector.NetworkDataGridNode.prototype = {
this._labelRightElement = this._barAreaElement.createChild("div", "network-graph-label");
- cell.addEventListener("mouseover", this._refreshLabelPositions.bind(this), false);
+ cell.addEventListener("mouseover", this._onMouseOver.bind(this), false);
+ },
+
+ /**
+ * @param {!Event} event
+ */
+ _onMouseOver: function(event)
+ {
+ this._refreshLabelPositions();
+ this._parentView[WebInspector.NetworkDataGridNode._hoveredRowSymbol] = this;
},
/**
@@ -2907,6 +2918,9 @@ WebInspector.NetworkDataGridNode.prototype = {
this._labelLeftElement.title = tooltip;
this._labelRightElement.title = tooltip;
this._barRightElement.title = tooltip;
+
+ if (this._parentView[WebInspector.NetworkDataGridNode._hoveredRowSymbol] === this)
+ this._refreshLabelPositions();
},
_refreshLabelPositions: function()
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698