RESOLVED WONTFIX 112666
Web Inspector: [DataGrid] Persist column widths.
https://bugs.webkit.org/show_bug.cgi?id=112666
Summary Web Inspector: [DataGrid] Persist column widths.
Eugene Klyuchnikov
Reported 2013-03-19 00:47:11 PDT
Column widths are often reset when user navigates between tools. Column widths should be persisted (at least while inspector is open). Related issue: Local Storage panel is not behaving properly when adding a new Key value. https://code.google.com/p/chromium/issues/detail?id=178067
Attachments
Patch (11.40 KB, patch)
2013-03-27 04:03 PDT, Eugene Klyuchnikov
no flags
Patch (11.41 KB, patch)
2013-03-27 23:42 PDT, Eugene Klyuchnikov
pfeldman: review-
Eugene Klyuchnikov
Comment 1 2013-03-22 00:53:15 PDT
Correction: Original issue: DevTools: column resizing isn't retained. https://code.google.com/p/chromium/issues/detail?id=129635
Eugene Klyuchnikov
Comment 2 2013-03-27 04:03:55 PDT
Pavel Feldman
Comment 3 2013-03-27 07:28:51 PDT
Comment on attachment 195268 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=195268&action=review > Source/WebCore/inspector/front-end/DataGrid.js:600 > + setFamily: function(family) { setName Here and below: { should be on the next line > Source/WebCore/inspector/front-end/DataGrid.js:603 > + this._saveColumnWeights(); Why would you load and then save? > Source/WebCore/inspector/front-end/RequestCookiesView.js:-91 > - this._cookiesTable.updateWidths(); Why did this go?
Eugene Klyuchnikov
Comment 4 2013-03-27 23:36:10 PDT
Comment on attachment 195268 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=195268&action=review >> Source/WebCore/inspector/front-end/DataGrid.js:600 >> + setFamily: function(family) { > > setName > Here and below: { should be on the next line OK. Done. >> Source/WebCore/inspector/front-end/DataGrid.js:603 >> + this._saveColumnWeights(); > > Why would you load and then save? Just to make sure that column widths are "persisted". I'll delete this. >> Source/WebCore/inspector/front-end/RequestCookiesView.js:-91 >> - this._cookiesTable.updateWidths(); > > Why did this go? It is useless, because column widths do not depend on table content.
Eugene Klyuchnikov
Comment 5 2013-03-27 23:42:48 PDT
Pavel Feldman
Comment 6 2013-03-28 05:06:31 PDT
> It is useless, because column widths do not depend on table content. They used to depend on it. Is it not the case anymore?
Pavel Feldman
Comment 7 2013-03-28 05:15:04 PDT
Comment on attachment 195490 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=195490&action=review > Source/WebCore/inspector/front-end/DOMStorageItemsView.js:184 > + {id: "key", title: WebInspector.UIString("Key"), editable: true, weight: 30}, Why 30/70? > Source/WebCore/inspector/front-end/DOMStorageItemsView.js:202 > + dataGrid.setName("keyValue"); Should be "DOMStorageItemsView" > Source/WebCore/inspector/front-end/DataGrid.js:617 > + this.applyColumnWeights(); This looks like a change in behavior: you now apply column weights upon setName. > Source/WebCore/inspector/front-end/DataGrid.js:634 > + this._loadColumnWeights(); You want it to be reset upon each unhide (panel switch)? Does not sound right to me.
Eugene Klyuchnikov
Comment 8 2013-03-29 02:44:47 PDT
Comment on attachment 195490 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=195490&action=review >> Source/WebCore/inspector/front-end/DOMStorageItemsView.js:184 >> + {id: "key", title: WebInspector.UIString("Key"), editable: true, weight: 30}, > > Why 30/70? Doesn't it look better than 50/50? >> Source/WebCore/inspector/front-end/DOMStorageItemsView.js:202 >> + dataGrid.setName("keyValue"); > > Should be "DOMStorageItemsView" Done >> Source/WebCore/inspector/front-end/DataGrid.js:617 >> + this.applyColumnWeights(); > > This looks like a change in behavior: you now apply column weights upon setName. Does it look strange? User expects to see column widths he already set. >> Source/WebCore/inspector/front-end/DataGrid.js:634 >> + this._loadColumnWeights(); > > You want it to be reset upon each unhide (panel switch)? Does not sound right to me. Not reset, but updated. When user changes column widths in data grid, he expects that all data grids with same name should be updated. I can make a shortcut, and update width only if setting value has been changed. But even so we are to check it when view unhides.
Eugene Klyuchnikov
Comment 9 2013-03-29 02:53:11 PDT
(In reply to comment #6) > > It is useless, because column widths do not depend on table content. > > They used to depend on it. Is it not the case anymore? Either user adjusts column widths or application do. Now user is in charge.
Note You need to log in before you can comment on or make changes to this bug.