Index: third_party/WebKit/Source/devtools/front_end/resources/ApplicationCacheItemsView.js |
diff --git a/third_party/WebKit/Source/devtools/front_end/resources/ApplicationCacheItemsView.js b/third_party/WebKit/Source/devtools/front_end/resources/ApplicationCacheItemsView.js |
index fe25f6c203e5be04f32ff4ad5d740b1ed37674fd..a4e896bd562f3c021b8fb34a1e8b8afd0b97c08c 100644 |
--- a/third_party/WebKit/Source/devtools/front_end/resources/ApplicationCacheItemsView.js |
+++ b/third_party/WebKit/Source/devtools/front_end/resources/ApplicationCacheItemsView.js |
@@ -186,11 +186,11 @@ WebInspector.ApplicationCacheItemsView.prototype = { |
_createDataGrid: function() |
{ |
- var columns = [ |
- {title: WebInspector.UIString("Resource"), sort: WebInspector.DataGrid.Order.Ascending, sortable: true}, |
- {title: WebInspector.UIString("Type"), sortable: true}, |
- {title: WebInspector.UIString("Size"), align: WebInspector.DataGrid.Align.Right, sortable: true} |
- ]; |
+ var columns = /** @type {!Array<!WebInspector.DataGrid.ColumnDescriptor>} */ ([ |
+ {id: "resource", title: WebInspector.UIString("Resource"), sort: WebInspector.DataGrid.Order.Ascending, sortable: true}, |
+ {id: "type", title: WebInspector.UIString("Type"), sortable: true}, |
+ {id: "size", title: WebInspector.UIString("Size"), align: WebInspector.DataGrid.Align.Right, sortable: true} |
+ ]); |
this._dataGrid = new WebInspector.DataGrid(columns); |
this._dataGrid.asWidget().show(this.element); |
this._dataGrid.addEventListener(WebInspector.DataGrid.Events.SortingChanged, this._populateDataGrid, this); |
@@ -211,7 +211,7 @@ WebInspector.ApplicationCacheItemsView.prototype = { |
} |
var comparator; |
- switch (parseInt(this._dataGrid.sortColumnIdentifier(), 10)) { |
+ switch (parseInt(this._dataGrid.sortColumnId(), 10)) { |
dgozman
2016/10/25 18:42:40
Compare to new ids instead.
allada
2016/10/25 18:56:14
Done.
|
case 0: comparator = localeCompare.bind(null, "name"); break; |
case 1: comparator = localeCompare.bind(null, "type"); break; |
case 2: comparator = numberCompare.bind(null, "size"); break; |