RESOLVED FIXED 144404
Web Inspector: Split Storage from Resources tab
https://bugs.webkit.org/show_bug.cgi?id=144404
Summary Web Inspector: Split Storage from Resources tab
Timothy Hatcher
Reported 2015-04-29 12:15:55 PDT
Add a Storage tab.
Attachments
Patch (30.50 KB, patch)
2015-04-29 12:16 PDT, Timothy Hatcher
no flags
Patch (50.11 KB, patch)
2015-04-29 12:36 PDT, Timothy Hatcher
joepeck: review+
timothy: commit-queue-
Timothy Hatcher
Comment 1 2015-04-29 12:16:52 PDT
Joseph Pecoraro
Comment 2 2015-04-29 12:25:31 PDT
Comment on attachment 251976 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=251976&action=review I think this patch is actually missing WebInspector.StorageTabContentView, so StorageTabContentView.js. > Source/WebInspectorUI/UserInterface/Controllers/ApplicationCacheManager.js:59 > + get applicationCacheObjects() > + { > + var applicationCacheObjects = []; > + for (var id in this._applicationCacheObjects) > + applicationCacheObjects.push(this._applicationCacheObjects[id]); > + return applicationCacheObjects; > + } This code looks weird because this._applicationCacheObjects is initialized to an array up above. Should it be an object? Or better yet a Map (no `delete`, and this would be [...map.values()]). > Source/WebInspectorUI/UserInterface/Views/DatabaseTableContentView.js:93 > + this._dataGrid = undefined; What is this for? (Unfortunately the patch review tool is not giving me context).
Timothy Hatcher
Comment 3 2015-04-29 12:32:11 PDT
Comment on attachment 251976 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=251976&action=review >> Source/WebInspectorUI/UserInterface/Controllers/ApplicationCacheManager.js:59 >> + } > > This code looks weird because this._applicationCacheObjects is initialized to an array up above. Should it be an object? Or better yet a Map (no `delete`, and this would be [...map.values()]). _applicationCacheObjects is treated as a map object below! I'll fix the _applicationCacheObjects = [] to be _applicationCacheObjects = {}. I save converting it to Map until later. >> Source/WebInspectorUI/UserInterface/Views/DatabaseTableContentView.js:93 >> + this._dataGrid = undefined; > > What is this for? (Unfortunately the patch review tool is not giving me context). Sorry. It fixes an exception. Seems this._dataGrid can be allocated but this._dataGrid.element is null/undefined.
Timothy Hatcher
Comment 4 2015-04-29 12:36:00 PDT
Joseph Pecoraro
Comment 5 2015-04-29 14:37:19 PDT
Comment on attachment 251977 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=251977&action=review r=me, commit-queue won't work at the moment, patch is not applying. > Source/WebInspectorUI/UserInterface/Views/StorageSidebarPanel.js:290 > + this._localStorageRootTreeElement = null; > + this._sessionStorageRootTreeElement = null; > + this._databaseRootTreeElement = null; > + this._databaseHostTreeElementMap = {}; > + this._indexedDatabaseRootTreeElement = null; > + this._indexedDatabaseHostTreeElementMap = {}; > + this._cookieStorageRootTreeElement = null; > + this._applicationCacheRootTreeElement = null; > + this._applicationCacheURLTreeElementMap = {}; This is repeated in the constructor. I wonder if it should be a helper, like _reset. > Source/WebInspectorUI/UserInterface/Views/StorageTabContentView.js:50 > + return representedObject instanceof WebInspector.DOMStorageObject || representedObject instanceof WebInspector.CookieStorageObject || > + representedObject instanceof WebInspector.DatabaseTableObject || representedObject instanceof WebInspector.DatabaseObject || > + representedObject instanceof WebInspector.ApplicationCacheFrame || representedObject instanceof WebInspector.IndexedDatabaseObjectStore || > + representedObject instanceof WebInspector.IndexedDatabaseObjectStoreIndex; Style: I think we normally put the "||" on the start of the next line instead of at the end of the previous.
Timothy Hatcher
Comment 6 2015-04-29 15:03:18 PDT
Note You need to log in before you can comment on or make changes to this bug.