Commit 10ca134a authored by pfeldman@chromium.org's avatar pfeldman@chromium.org

DevTools: minor UI / menu tweaks reducing the clutter.

Review URL: https://codereview.chromium.org/206413004

git-svn-id: svn://svn.chromium.org/blink/trunk@169804 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent d8660fd8
...@@ -5,7 +5,6 @@ ...@@ -5,7 +5,6 @@
function test() function test()
{ {
WebInspector.settings.showRenderingViewInDrawer.set(true);
InspectorTest.dumpLoadedModules(); InspectorTest.dumpLoadedModules();
InspectorTest.completeTest(); InspectorTest.completeTest();
} }
......
...@@ -374,17 +374,8 @@ WebInspector.ElementsPanel.prototype = { ...@@ -374,17 +374,8 @@ WebInspector.ElementsPanel.prototype = {
_contextMenuEventFired: function(event) _contextMenuEventFired: function(event)
{ {
function toggleWordWrap()
{
WebInspector.settings.domWordWrap.set(!WebInspector.settings.domWordWrap.get());
}
var contextMenu = new WebInspector.ContextMenu(event); var contextMenu = new WebInspector.ContextMenu(event);
this.treeOutline.populateContextMenu(contextMenu, event); this.treeOutline.populateContextMenu(contextMenu, event);
contextMenu.appendSeparator();
contextMenu.appendCheckboxItem(WebInspector.UIString(WebInspector.useLowerCaseMenuTitles() ? "Word wrap" : "Word Wrap"), toggleWordWrap, WebInspector.settings.domWordWrap.get());
contextMenu.show(); contextMenu.show();
}, },
......
...@@ -1437,7 +1437,6 @@ WebInspector.ElementsTreeElement.prototype = { ...@@ -1437,7 +1437,6 @@ WebInspector.ElementsTreeElement.prototype = {
contextMenu.appendItem(WebInspector.UIString("Copy XPath"), this._copyXPath.bind(this)); contextMenu.appendItem(WebInspector.UIString("Copy XPath"), this._copyXPath.bind(this));
if (isEditable) if (isEditable)
contextMenu.appendItem(WebInspector.UIString(WebInspector.useLowerCaseMenuTitles() ? "Delete node" : "Delete Node"), this.remove.bind(this)); contextMenu.appendItem(WebInspector.UIString(WebInspector.useLowerCaseMenuTitles() ? "Delete node" : "Delete Node"), this.remove.bind(this));
contextMenu.appendItem(WebInspector.UIString(WebInspector.useLowerCaseMenuTitles() ? "Inspect DOM properties" : "Inspect DOM Properties"), this._inspectDOMProperties.bind(this));
}, },
_startEditing: function() _startEditing: function()
...@@ -2336,34 +2335,6 @@ WebInspector.ElementsTreeElement.prototype = { ...@@ -2336,34 +2335,6 @@ WebInspector.ElementsTreeElement.prototype = {
InspectorFrontendHost.copyText(WebInspector.DOMPresentationUtils.xPath(this._node, true)); InspectorFrontendHost.copyText(WebInspector.DOMPresentationUtils.xPath(this._node, true));
}, },
_inspectDOMProperties: function()
{
WebInspector.RemoteObject.resolveNode(this._node, "console", callback);
/**
* @param {?WebInspector.RemoteObject} nodeObject
*/
function callback(nodeObject)
{
if (!nodeObject)
return;
var message = new WebInspector.ConsoleMessage(
WebInspector.ConsoleMessage.MessageSource.ConsoleAPI,
WebInspector.ConsoleMessage.MessageLevel.Log,
"",
WebInspector.ConsoleMessage.MessageType.Dir,
undefined,
undefined,
undefined,
undefined,
undefined,
[nodeObject]);
WebInspector.console.addMessage(message);
WebInspector.console.show();
}
},
_highlightSearchResults: function() _highlightSearchResults: function()
{ {
if (!this._searchQuery || !this._searchHighlightsVisible) if (!this._searchQuery || !this._searchHighlightsVisible)
......
...@@ -383,16 +383,8 @@ WebInspector.Main.prototype = { ...@@ -383,16 +383,8 @@ WebInspector.Main.prototype = {
{ {
WebInspector.inspectorView.showInitialPanel(); WebInspector.inspectorView.showInitialPanel();
if (WebInspector.overridesSupport.hasActiveOverrides()) { if (WebInspector.overridesSupport.hasActiveOverrides())
if (!WebInspector.settings.showEmulationViewInDrawer.get())
WebInspector.settings.showEmulationViewInDrawer.set(true);
WebInspector.inspectorView.showViewInDrawer("emulation", true); WebInspector.inspectorView.showViewInDrawer("emulation", true);
}
if (WebInspector.settings.showPaintRects.get() || WebInspector.settings.showDebugBorders.get() || WebInspector.settings.continuousPainting.get() ||
WebInspector.settings.showFPSCounter.get() || WebInspector.settings.showScrollBottleneckRects.get()) {
WebInspector.settings.showRenderingViewInDrawer.set(true);
}
WebInspector.settings.showMetricsRulers.addChangeListener(showRulersChanged); WebInspector.settings.showMetricsRulers.addChangeListener(showRulersChanged);
function showRulersChanged() function showRulersChanged()
......
...@@ -107,8 +107,6 @@ WebInspector.Settings = function() ...@@ -107,8 +107,6 @@ WebInspector.Settings = function()
this.showWhitespacesInEditor = this.createSetting("showWhitespacesInEditor", false); this.showWhitespacesInEditor = this.createSetting("showWhitespacesInEditor", false);
this.skipStackFramesSwitch = this.createSetting("skipStackFramesSwitch", false); this.skipStackFramesSwitch = this.createSetting("skipStackFramesSwitch", false);
this.skipStackFramesPattern = this.createSetting("skipStackFramesPattern", ""); this.skipStackFramesPattern = this.createSetting("skipStackFramesPattern", "");
this.showEmulationViewInDrawer = this.createSetting("showEmulationViewInDrawer", true);
this.showRenderingViewInDrawer = this.createSetting("showRenderingViewInDrawer", true);
this.pauseOnExceptionEnabled = this.createSetting("pauseOnExceptionEnabled", false); this.pauseOnExceptionEnabled = this.createSetting("pauseOnExceptionEnabled", false);
this.pauseOnCaughtException = this.createSetting("pauseOnCaughtException", false); this.pauseOnCaughtException = this.createSetting("pauseOnCaughtException", false);
this.enableAsyncStackTraces = this.createSetting("enableAsyncStackTraces", false); this.enableAsyncStackTraces = this.createSetting("enableAsyncStackTraces", false);
......
...@@ -284,10 +284,6 @@ WebInspector.GenericSettingsTab = function() ...@@ -284,10 +284,6 @@ WebInspector.GenericSettingsTab = function()
this._updateScriptDisabledCheckbox(); this._updateScriptDisabledCheckbox();
p = this._appendSection(WebInspector.UIString("Appearance")); p = this._appendSection(WebInspector.UIString("Appearance"));
p.appendChild(WebInspector.SettingsUI.createSettingCheckbox(WebInspector.UIString("Show 'Emulation' view in console drawer."), WebInspector.settings.showEmulationViewInDrawer));
this._appendDrawerNote(p.lastElementChild);
p.appendChild(WebInspector.SettingsUI.createSettingCheckbox(WebInspector.UIString("Show 'Rendering' view in console drawer."), WebInspector.settings.showRenderingViewInDrawer));
this._appendDrawerNote(p.lastElementChild);
var splitVerticallyTitle = WebInspector.UIString("Split panels vertically when docked to %s", WebInspector.experimentsSettings.dockToLeft.isEnabled() ? "left or right" : "right"); var splitVerticallyTitle = WebInspector.UIString("Split panels vertically when docked to %s", WebInspector.experimentsSettings.dockToLeft.isEnabled() ? "left or right" : "right");
p.appendChild(WebInspector.SettingsUI.createSettingCheckbox(splitVerticallyTitle, WebInspector.settings.splitVerticallyWhenDockedToRight)); p.appendChild(WebInspector.SettingsUI.createSettingCheckbox(splitVerticallyTitle, WebInspector.settings.splitVerticallyWhenDockedToRight));
var panelShortcutTitle = WebInspector.UIString("Enable %s + 1-9 shortcut to switch panels", WebInspector.isMac() ? "Cmd" : "Ctrl"); var panelShortcutTitle = WebInspector.UIString("Enable %s + 1-9 shortcut to switch panels", WebInspector.isMac() ? "Cmd" : "Ctrl");
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
#elements-crumbs { #elements-crumbs {
flex: 0 0 19px; flex: 0 0 19px;
background-color: rgb(236, 236, 236); background-color: white;
border-top: 1px solid #ccc; border-top: 1px solid #ccc;
overflow: hidden; overflow: hidden;
} }
......
...@@ -50,7 +50,6 @@ var allDescriptors = [ ...@@ -50,7 +50,6 @@ var allDescriptors = [
name: "emulation", name: "emulation",
title: "Emulation", title: "Emulation",
order: "10", order: "10",
setting: "showEmulationViewInDrawer",
className: "WebInspector.OverridesView" className: "WebInspector.OverridesView"
}, },
{ {
...@@ -58,7 +57,6 @@ var allDescriptors = [ ...@@ -58,7 +57,6 @@ var allDescriptors = [
name: "rendering", name: "rendering",
title: "Rendering", title: "Rendering",
order: "11", order: "11",
setting: "showRenderingViewInDrawer",
className: "WebInspector.RenderingOptionsView" className: "WebInspector.RenderingOptionsView"
}, },
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment