| 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 269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 280 this._waterfallColumnSortIcon.classList.remove('sort-ascending', 'sort-des
cending'); | 280 this._waterfallColumnSortIcon.classList.remove('sort-ascending', 'sort-des
cending'); |
| 281 | 281 |
| 282 if (this._dataGrid.sortOrder() === UI.DataGrid.Order.Ascending) | 282 if (this._dataGrid.sortOrder() === UI.DataGrid.Order.Ascending) |
| 283 this._waterfallColumnSortIcon.classList.add('sort-ascending'); | 283 this._waterfallColumnSortIcon.classList.add('sort-ascending'); |
| 284 else | 284 else |
| 285 this._waterfallColumnSortIcon.classList.add('sort-descending'); | 285 this._waterfallColumnSortIcon.classList.add('sort-descending'); |
| 286 | 286 |
| 287 this._waterfallRequestsAreStale = true; | 287 this._waterfallRequestsAreStale = true; |
| 288 var sortFunction = Network.NetworkDataGridNode.RequestPropertyComparator.b
ind(null, this._activeWaterfallSortId); | 288 var sortFunction = Network.NetworkDataGridNode.RequestPropertyComparator.b
ind(null, this._activeWaterfallSortId); |
| 289 this._dataGrid.sortNodes(sortFunction, !this._dataGrid.isSortOrderAscendin
g()); | 289 this._dataGrid.sortNodes(sortFunction, !this._dataGrid.isSortOrderAscendin
g()); |
| 290 this._networkLogView.dataGridSorted(); |
| 290 return; | 291 return; |
| 291 } | 292 } |
| 292 | 293 |
| 293 var columnConfig = this._columns.find(columnConfig => columnConfig.id === co
lumnId); | 294 var columnConfig = this._columns.find(columnConfig => columnConfig.id === co
lumnId); |
| 294 if (!columnConfig || !columnConfig.sortingFunction) | 295 if (!columnConfig || !columnConfig.sortingFunction) |
| 295 return; | 296 return; |
| 296 | 297 |
| 297 this._dataGrid.sortNodes(columnConfig.sortingFunction, !this._dataGrid.isSor
tOrderAscending()); | 298 this._dataGrid.sortNodes(columnConfig.sortingFunction, !this._dataGrid.isSor
tOrderAscending()); |
| 298 this._networkLogView.dataGridSorted(); | 299 this._networkLogView.dataGridSorted(); |
| 299 } | 300 } |
| (...skipping 516 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 816 /** | 817 /** |
| 817 * @enum {string} | 818 * @enum {string} |
| 818 */ | 819 */ |
| 819 Network.NetworkLogViewColumns.WaterfallSortIds = { | 820 Network.NetworkLogViewColumns.WaterfallSortIds = { |
| 820 StartTime: 'startTime', | 821 StartTime: 'startTime', |
| 821 ResponseTime: 'responseReceivedTime', | 822 ResponseTime: 'responseReceivedTime', |
| 822 EndTime: 'endTime', | 823 EndTime: 'endTime', |
| 823 Duration: 'duration', | 824 Duration: 'duration', |
| 824 Latency: 'latency' | 825 Latency: 'latency' |
| 825 }; | 826 }; |
| OLD | NEW |