Bug 128783

Summary: Web Inspector: DataGrid should have an API to set sort column and direction
Product: WebKit Reporter: BJ Burg <bburg>
Component: Web InspectorAssignee: BJ Burg <bburg>
Status: RESOLVED FIXED    
Severity: Normal CC: joepeck, timothy, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
the patch timothy: review+

Description BJ Burg 2014-02-13 17:42:40 PST
Some tables (such as DOMStorageView) should have a default sort column rather than displaying rows in a possibly undefined order. However, the code to update the actual sort column and direction is stuck within a click event handler.
Comment 1 Radar WebKit Bug Importer 2014-02-13 17:43:22 PST
<rdar://problem/16066438>
Comment 2 BJ Burg 2014-03-11 16:27:42 PDT
Created attachment 226446 [details]
the patch
Comment 3 Timothy Hatcher 2014-03-12 11:07:46 PDT
Comment on attachment 226446 [details]
the patch

View in context: https://bugs.webkit.org/attachment.cgi?id=226446&action=review

> Source/WebInspectorUI/UserInterface/Views/ApplicationCacheFrameContentView.js:204
> +        switch (this._dataGrid.sortColumnIdentifier || "url") {
> +            case "url": comparator = localeCompare.bind(this, "url"); break;

Just use default:?

> Source/WebInspectorUI/UserInterface/Views/CookieStorageContentView.js:82
> +            var columns = { name: {}, value: {}, domain: {}, path: {}, expires: {}, size: {}, http: {}, secure: {}};

No space after {.

> Source/WebInspectorUI/UserInterface/Views/CookieStorageContentView.js:141
> +            };
> +            if (cookie.type !== WebInspector.CookieType.Request)

Add a newline.
Comment 4 BJ Burg 2014-03-12 11:18:58 PDT
Committed r165487: <http://trac.webkit.org/changeset/165487>