| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 /** | 4 /** |
| 5 * @unrestricted | 5 * @unrestricted |
| 6 */ | 6 */ |
| 7 Network.NetworkLogViewColumns = class { | 7 Network.NetworkLogViewColumns = class { |
| 8 /** | 8 /** |
| 9 * @param {!Network.NetworkLogView} networkLogView | 9 * @param {!Network.NetworkLogView} networkLogView |
| 10 * @param {!Network.NetworkTransferTimeCalculator} timeCalculator | 10 * @param {!Network.NetworkTransferTimeCalculator} timeCalculator |
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 151 | 151 |
| 152 /** | 152 /** |
| 153 * @param {!Event} event | 153 * @param {!Event} event |
| 154 * @this {Network.NetworkLogViewColumns} | 154 * @this {Network.NetworkLogViewColumns} |
| 155 */ | 155 */ |
| 156 function handleContextMenu(event) { | 156 function handleContextMenu(event) { |
| 157 var logEntry = this._waterfallColumn.getLogEntryFromPoint(event.offsetX, e
vent.offsetY); | 157 var logEntry = this._waterfallColumn.getLogEntryFromPoint(event.offsetX, e
vent.offsetY); |
| 158 if (!logEntry) | 158 if (!logEntry) |
| 159 return; | 159 return; |
| 160 var contextMenu = new UI.ContextMenu(event); | 160 var contextMenu = new UI.ContextMenu(event); |
| 161 this._networkLogView.handleContextMenuForRequest(contextMenu, logEntry.req
uest()); | 161 this._networkLogView.handleContextMenuForLogEntry(contextMenu, logEntry); |
| 162 contextMenu.show(); | 162 contextMenu.show(); |
| 163 } | 163 } |
| 164 } | 164 } |
| 165 | 165 |
| 166 /** | 166 /** |
| 167 * @param {boolean} shouldConsume | 167 * @param {boolean} shouldConsume |
| 168 * @param {!Event} event | 168 * @param {!Event} event |
| 169 */ | 169 */ |
| 170 _onMouseWheel(shouldConsume, event) { | 170 _onMouseWheel(shouldConsume, event) { |
| 171 if (shouldConsume) | 171 if (shouldConsume) |
| (...skipping 20 matching lines...) Expand all Loading... |
| 192 } | 192 } |
| 193 } | 193 } |
| 194 | 194 |
| 195 _redrawWaterfallColumn() { | 195 _redrawWaterfallColumn() { |
| 196 if (!this._waterfallRequestsAreStale) { | 196 if (!this._waterfallRequestsAreStale) { |
| 197 this._updateScrollerWidthIfNeeded(); | 197 this._updateScrollerWidthIfNeeded(); |
| 198 this._waterfallColumn.update( | 198 this._waterfallColumn.update( |
| 199 this._activeScroller.scrollTop, this._eventDividersShown ? this._event
Dividers : undefined); | 199 this._activeScroller.scrollTop, this._eventDividersShown ? this._event
Dividers : undefined); |
| 200 return; | 200 return; |
| 201 } | 201 } |
| 202 var nodes = this._networkLogView.flatNodesList(); | 202 var nodes = this._networkLogView.flatenChildren(); |
| 203 this._waterfallColumn.update(this._activeScroller.scrollTop, this._eventDivi
ders, nodes); | 203 this._waterfallColumn.update(this._activeScroller.scrollTop, this._eventDivi
ders, nodes); |
| 204 } | 204 } |
| 205 | 205 |
| 206 /** | 206 /** |
| 207 * @param {?Network.NetworkLogEntry} logEntry | 207 * @param {?Network.NetworkLogEntry} logEntry |
| 208 * @param {boolean} highlightInitiatorChain | 208 * @param {boolean} highlightInitiatorChain |
| 209 */ | 209 */ |
| 210 setHoveredLogEntry(logEntry, highlightInitiatorChain) { | 210 setHoveredLogEntry(logEntry, highlightInitiatorChain) { |
| 211 this._waterfallColumn.setHoveredLogEntry(logEntry, highlightInitiatorChain); | 211 this._waterfallColumn.setHoveredLogEntry(logEntry, highlightInitiatorChain); |
| 212 } | 212 } |
| (...skipping 604 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 817 /** | 817 /** |
| 818 * @enum {string} | 818 * @enum {string} |
| 819 */ | 819 */ |
| 820 Network.NetworkLogViewColumns.WaterfallSortIds = { | 820 Network.NetworkLogViewColumns.WaterfallSortIds = { |
| 821 StartTime: 'startTime', | 821 StartTime: 'startTime', |
| 822 ResponseTime: 'responseReceivedTime', | 822 ResponseTime: 'responseReceivedTime', |
| 823 EndTime: 'endTime', | 823 EndTime: 'endTime', |
| 824 Duration: 'duration', | 824 Duration: 'duration', |
| 825 Latency: 'latency' | 825 Latency: 'latency' |
| 826 }; | 826 }; |
| OLD | NEW |