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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/network/NetworkLogViewColumns.js

Issue 2652893008: DevTools: fix network waterfall sorting icon (Closed)
Patch Set: Created 3 years, 11 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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/devtools/front_end/network/networkLogView.css » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 245 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 } 256 }
257 257
258 sortByCurrentColumn() { 258 sortByCurrentColumn() {
259 this._sortHandler(); 259 this._sortHandler();
260 } 260 }
261 261
262 _sortHandler() { 262 _sortHandler() {
263 var columnId = this._dataGrid.sortColumnId(); 263 var columnId = this._dataGrid.sortColumnId();
264 this._networkLogView.removeAllNodeHighlights(); 264 this._networkLogView.removeAllNodeHighlights();
265 this._waterfallRequestsAreStale = true; 265 this._waterfallRequestsAreStale = true;
266 this._waterfallColumnSortIcon.classList.remove('sort-ascending', 'sort-desce nding');
267
266 if (columnId === 'waterfall') { 268 if (columnId === 'waterfall') {
267 this._waterfallColumnSortIcon.classList.remove('sort-ascending', 'sort-des cending');
268
269 if (this._dataGrid.sortOrder() === DataGrid.DataGrid.Order.Ascending) 269 if (this._dataGrid.sortOrder() === DataGrid.DataGrid.Order.Ascending)
270 this._waterfallColumnSortIcon.classList.add('sort-ascending'); 270 this._waterfallColumnSortIcon.classList.add('sort-ascending');
271 else 271 else
272 this._waterfallColumnSortIcon.classList.add('sort-descending'); 272 this._waterfallColumnSortIcon.classList.add('sort-descending');
273 273
274 var sortFunction = Network.NetworkRequestNode.RequestPropertyComparator.bi nd(null, this._activeWaterfallSortId); 274 var sortFunction = Network.NetworkRequestNode.RequestPropertyComparator.bi nd(null, this._activeWaterfallSortId);
275 this._dataGrid.sortNodes(sortFunction, !this._dataGrid.isSortOrderAscendin g()); 275 this._dataGrid.sortNodes(sortFunction, !this._dataGrid.isSortOrderAscendin g());
276 this._networkLogView.dataGridSorted(); 276 this._networkLogView.dataGridSorted();
277 return; 277 return;
278 } 278 }
(...skipping 524 matching lines...) Expand 10 before | Expand all | Expand 10 after
803 /** 803 /**
804 * @enum {string} 804 * @enum {string}
805 */ 805 */
806 Network.NetworkLogViewColumns.WaterfallSortIds = { 806 Network.NetworkLogViewColumns.WaterfallSortIds = {
807 StartTime: 'startTime', 807 StartTime: 'startTime',
808 ResponseTime: 'responseReceivedTime', 808 ResponseTime: 'responseReceivedTime',
809 EndTime: 'endTime', 809 EndTime: 'endTime',
810 Duration: 'duration', 810 Duration: 'duration',
811 Latency: 'latency' 811 Latency: 'latency'
812 }; 812 };
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/devtools/front_end/network/networkLogView.css » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698