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

Unified Diff: third_party/WebKit/Source/devtools/front_end/network/NetworkLogView.js

Issue 2514123002: [Devtools] Moved NetworkWaterfallColumn to use NetworkLogEntry (Closed)
Patch Set: changes Created 4 years, 1 month 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/devtools/front_end/network/NetworkLogView.js
diff --git a/third_party/WebKit/Source/devtools/front_end/network/NetworkLogView.js b/third_party/WebKit/Source/devtools/front_end/network/NetworkLogView.js
index 64c699010a1d2e3797b9893b9eafcc8fd35cf388..7c41cb9129e6dcc6a7784e9d7e9c1abe89d089fa 100644
--- a/third_party/WebKit/Source/devtools/front_end/network/NetworkLogView.js
+++ b/third_party/WebKit/Source/devtools/front_end/network/NetworkLogView.js
@@ -86,6 +86,7 @@ Network.NetworkLogView = class extends UI.VBox {
this._filters = [];
/** @type {?Network.NetworkLogView.Filter} */
this._timeFilter = null;
+ this._hoveredNode = null;
this._currentMatchedRequestNode = null;
this._currentMatchedRequestIndex = -1;
@@ -531,12 +532,13 @@ Network.NetworkLogView = class extends UI.VBox {
}
/**
- * @param {?SDK.NetworkRequest} request
+ * @param {?Network.NetworkLogEntry} logEntry
* @param {boolean} highlightInitiatorChain
*/
- setHoveredRequest(request, highlightInitiatorChain) {
- this._setHoveredNode(request ? this._nodesByRequestId.get(request.requestId) : null, highlightInitiatorChain);
- this._highlightInitiatorChain((request && highlightInitiatorChain) ? request : null);
+ setHoveredLogEntry(logEntry, highlightInitiatorChain) {
+ // TODO(allada) Move this into LogEntry/NetworkDataGridNode.
+ this._setHoveredNode(/** @type {?Network.NetworkDataGridNode} */ (logEntry), highlightInitiatorChain);
+ this._highlightInitiatorChain((logEntry && highlightInitiatorChain) ? logEntry.request() : null);
}
/**
@@ -549,7 +551,7 @@ Network.NetworkLogView = class extends UI.VBox {
this._hoveredNode = node;
if (this._hoveredNode)
this._hoveredNode.element().classList.add('hover');
- this._columns.setHoveredRequest(this._hoveredNode ? this._hoveredNode.request() : null, !!highlightInitiatorChain);
+ this._columns.setHoveredLogEntry(this._hoveredNode, !!highlightInitiatorChain);
}
/**
@@ -778,6 +780,13 @@ Network.NetworkLogView = class extends UI.VBox {
this._columns.willHide();
}
+ /**
+ * @return {!Array<!Network.NetworkDataGridNode>}
+ */
+ flatNodesList() {
+ return this._dataGrid.flatNodesList();
+ }
+
_refresh() {
this._needsRefresh = false;

Powered by Google App Engine
This is Rietveld 408576698