Index: third_party/WebKit/Source/devtools/front_end/network/NetworkWaterfallColumn.js |
diff --git a/third_party/WebKit/Source/devtools/front_end/network/NetworkWaterfallColumn.js b/third_party/WebKit/Source/devtools/front_end/network/NetworkWaterfallColumn.js |
index fd8bdcb6ed220b6fe5d945b445dc7a9b8fa6beca..2a87beca6471ef7519d73b9ea309d05dd77bb0b4 100644 |
--- a/third_party/WebKit/Source/devtools/front_end/network/NetworkWaterfallColumn.js |
+++ b/third_party/WebKit/Source/devtools/front_end/network/NetworkWaterfallColumn.js |
@@ -3,10 +3,9 @@ |
// found in the LICENSE file. |
Network.NetworkWaterfallColumn = class extends UI.VBox { |
/** |
- * @param {number} rowHeight |
* @param {!Network.NetworkTimeCalculator} calculator |
*/ |
- constructor(rowHeight, calculator) { |
+ constructor(calculator) { |
// TODO(allada) Make this a shadowDOM when the NetworkWaterfallColumn gets moved into NetworkLogViewColumns. |
super(false); |
this.registerRequiredCSS('network/networkWaterfallColumn.css'); |
@@ -24,10 +23,12 @@ Network.NetworkWaterfallColumn = class extends UI.VBox { |
this._rightPadding = 0; |
this._scrollTop = 0; |
- this._rowHeight = rowHeight; |
this._headerHeight = 0; |
this._calculator = calculator; |
+ this._rawRowHeight = 0; |
allada
2017/05/16 21:40:07
I think a short comment explaining the difference
pfeldman
2017/05/16 22:34:16
Done.
|
+ this._rowHeight = 0; |
+ |
this._offsetWidth = 0; |
this._offsetHeight = 0; |
this._startTime = this._calculator.minimumBoundary(); |
@@ -248,7 +249,12 @@ Network.NetworkWaterfallColumn = class extends UI.VBox { |
* @param {number} height |
*/ |
setRowHeight(height) { |
- this._rowHeight = height; |
+ this._rawRowHeight = height; |
+ this._updateRowHeight(); |
+ } |
+ |
+ _updateRowHeight() { |
+ this._rowHeight = Math.floor(this._rawRowHeight * window.devicePixelRatio) / window.devicePixelRatio; |
} |
/** |
@@ -330,6 +336,7 @@ Network.NetworkWaterfallColumn = class extends UI.VBox { |
*/ |
onResize() { |
super.onResize(); |
+ this._updateRowHeight(); |
this._calculateCanvasSize(); |
this.scheduleDraw(); |
} |