* SUMMARY Convert sidebars to use View base class, make details section a first-class concept. It would be nice to be able to write this.addDetailsSection(detailsSection) instead of this.element.appendChild(this._myDetailsSection.element), from within sidebar classes.
<rdar://problem/23472088>
To reduce the scope of this patch, improvements to sidebar details sections will be tracked under a separate issue: https://bugs.webkit.org/show_bug.cgi?id=151126.
Created attachment 265262 [details] [Patch] Proposed Fix
Comment on attachment 265262 [details] [Patch] Proposed Fix View in context: https://bugs.webkit.org/attachment.cgi?id=265262&action=review > Source/WebInspectorUI/UserInterface/Views/Sidebar.js:203 > + this._collapsed = flag; flag || false; > Source/WebInspectorUI/UserInterface/Views/Sidebar.js:205 > + this.element.classList.add(WebInspector.Sidebar.CollapsedStyleClassName); These lines can be replaced with classList.toggle(). > Source/WebInspectorUI/UserInterface/Views/SidebarPanel.js:75 > + this._selected = flag; flag || false; > Source/WebInspectorUI/UserInterface/Views/SidebarPanel.js:76 > + this.element.classList.toggle("selected"); Would be safer to pass _selected as the second argument to toggle. > Source/WebInspectorUI/UserInterface/Views/SidebarPanel.js:81 > + return this.parentView; Nice!
Created attachment 265317 [details] [Patch] Proposed Fix
Comment on attachment 265317 [details] [Patch] Proposed Fix Clearing flags on attachment: 265317 Committed r192327: <http://trac.webkit.org/changeset/192327>
All reviewed patches have been landed. Closing bug.