This change: - Splits preferences and settings - Pushes settings to the frontend on load - Stores settings on each change - Stores showInheritedStyles as setting.
Created attachment 45340 [details] [PATCH] Proposed fix
style-queue ran check-webkit-style on attachment 45340 [details] without any errors.
Comment on attachment 45340 [details] [PATCH] Proposed fix > + this._installSetting("eventListenersFilter", "event-listeners-filter", "all"); > + this._installSetting("colorFormat", "color-format", "hex"); > + this._installSetting("resourcesLargeRows", "resources-large-rows", true); > + this._installSetting("watchExpressions", "watch-expressions", []); > + this._installSetting("lastViewedScriptFile", "last-viewed-script-file"); > + this._installSetting("showInheritedComputedStyleProperties", "show-inherited-computed-style-properties", false); > + this._installSetting("showUserAgentStyles", "show-user-agent-styles", true); I think it is weird that this class knows all the settings. I guess these are default values and like the old Settings object on WebInspector? So I guess it is the same. Just seemed weird at first…
(In reply to comment #3) > (From update of attachment 45340 [details]) > > + this._installSetting("eventListenersFilter", "event-listeners-filter", "all"); > > + this._installSetting("colorFormat", "color-format", "hex"); > > + this._installSetting("resourcesLargeRows", "resources-large-rows", true); > > + this._installSetting("watchExpressions", "watch-expressions", []); > > + this._installSetting("lastViewedScriptFile", "last-viewed-script-file"); > > + this._installSetting("showInheritedComputedStyleProperties", "show-inherited-computed-style-properties", false); > > + this._installSetting("showUserAgentStyles", "show-user-agent-styles", true); > > I think it is weird that this class knows all the settings. I guess these are > default values and like the old Settings object on WebInspector? So I guess it > is the same. Just seemed weird at first… I just wanted them to be in single place so that we knew what is persisted. I am fine with converting _installSetting into public registerSetting in the future!
Committing to http://svn.webkit.org/repository/webkit/trunk ... D LayoutTests/inspector/settings-set-get-expected.txt D LayoutTests/inspector/settings-set-get.html M LayoutTests/ChangeLog M WebCore/ChangeLog M WebCore/WebCore.gypi M WebCore/WebCore.vcproj/WebCore.vcproj M WebCore/inspector/InspectorBackend.cpp M WebCore/inspector/InspectorBackend.h M WebCore/inspector/InspectorBackend.idl M WebCore/inspector/InspectorController.cpp M WebCore/inspector/InspectorController.h M WebCore/inspector/InspectorFrontend.cpp M WebCore/inspector/InspectorFrontend.h M WebCore/inspector/InspectorFrontendHost.cpp M WebCore/inspector/InspectorFrontendHost.h M WebCore/inspector/InspectorFrontendHost.idl M WebCore/inspector/front-end/EventListenersSidebarPane.js M WebCore/inspector/front-end/InspectorBackendStub.js M WebCore/inspector/front-end/InspectorFrontendHostStub.js M WebCore/inspector/front-end/ResourcesPanel.js M WebCore/inspector/front-end/ScriptsPanel.js A WebCore/inspector/front-end/Settings.js M WebCore/inspector/front-end/StylesSidebarPane.js M WebCore/inspector/front-end/WatchExpressionsSidebarPane.js M WebCore/inspector/front-end/WebKit.qrc M WebCore/inspector/front-end/inspector.html M WebCore/inspector/front-end/inspector.js Committed r52547