Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> | 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> |
| 4 * Copyright (C) 2009 Joseph Pecoraro | 4 * Copyright (C) 2009 Joseph Pecoraro |
| 5 * | 5 * |
| 6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
| 7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
| 8 * are met: | 8 * are met: |
| 9 * | 9 * |
| 10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
| (...skipping 926 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 937 if (position === "right") | 937 if (position === "right") |
| 938 vertically = false; | 938 vertically = false; |
| 939 else if (position === "bottom") | 939 else if (position === "bottom") |
| 940 vertically = true; | 940 vertically = true; |
| 941 else | 941 else |
| 942 vertically = WebInspector.inspectorView.element.offsetWidth < 680; | 942 vertically = WebInspector.inspectorView.element.offsetWidth < 680; |
| 943 | 943 |
| 944 if (this.sidebarPaneView && vertically === !this._splitWidget.isVertical ()) | 944 if (this.sidebarPaneView && vertically === !this._splitWidget.isVertical ()) |
| 945 return; | 945 return; |
| 946 | 946 |
| 947 var extensionSidebarPanes = WebInspector.extensionServer.sidebarPanes(); | 947 if (this.sidebarPaneView && this.sidebarPaneView.shouldHideOnDetach()) |
| 948 if (this.sidebarPaneView && extensionSidebarPanes.length) | |
| 949 return; // We can't reparent extension iframes. | 948 return; // We can't reparent extension iframes. |
| 950 | 949 |
| 950 var extensionSidebarPanes = WebInspector.extensionServer.sidebarPanes(); | |
|
caseq
2015/08/17 22:02:42
nuke this?
| |
| 951 if (this.sidebarPaneView) { | 951 if (this.sidebarPaneView) { |
| 952 this.sidebarPaneView.detach(); | 952 this.sidebarPaneView.detach(); |
| 953 this._splitWidget.uninstallResizer(this.sidebarPaneView.headerElemen t()); | 953 this._splitWidget.uninstallResizer(this.sidebarPaneView.headerElemen t()); |
| 954 } | 954 } |
| 955 | 955 |
| 956 this._splitWidget.setVertical(!vertically); | 956 this._splitWidget.setVertical(!vertically); |
| 957 | 957 |
| 958 var computedPane = new WebInspector.SidebarPane(WebInspector.UIString("C omputed")); | 958 var computedPane = new WebInspector.SidebarPane(WebInspector.UIString("C omputed")); |
| 959 computedPane.element.classList.add("composite"); | 959 computedPane.element.classList.add("composite"); |
| 960 computedPane.element.classList.add("fill"); | 960 computedPane.element.classList.add("fill"); |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1054 { | 1054 { |
| 1055 var pane = /** @type {!WebInspector.ExtensionSidebarPane} */ (event.data ); | 1055 var pane = /** @type {!WebInspector.ExtensionSidebarPane} */ (event.data ); |
| 1056 this._addExtensionSidebarPane(pane); | 1056 this._addExtensionSidebarPane(pane); |
| 1057 }, | 1057 }, |
| 1058 | 1058 |
| 1059 /** | 1059 /** |
| 1060 * @param {!WebInspector.ExtensionSidebarPane} pane | 1060 * @param {!WebInspector.ExtensionSidebarPane} pane |
| 1061 */ | 1061 */ |
| 1062 _addExtensionSidebarPane: function(pane) | 1062 _addExtensionSidebarPane: function(pane) |
| 1063 { | 1063 { |
| 1064 if (pane.panelName() === this.name) { | 1064 if (pane.panelName() === this.name) |
| 1065 this.setHideOnDetach(); | |
| 1066 this._extensionSidebarPanesContainer.addPane(pane); | 1065 this._extensionSidebarPanesContainer.addPane(pane); |
| 1067 } | |
| 1068 }, | 1066 }, |
| 1069 | 1067 |
| 1070 /** | 1068 /** |
| 1071 * @param {?WebInspector.Widget} widget | 1069 * @param {?WebInspector.Widget} widget |
| 1072 */ | 1070 */ |
| 1073 setWidgetBelowDOM: function(widget) | 1071 setWidgetBelowDOM: function(widget) |
| 1074 { | 1072 { |
| 1075 if (widget) { | 1073 if (widget) { |
| 1076 this._elementsPanelTreeOutilneSplit.setSidebarWidget(widget); | 1074 this._elementsPanelTreeOutilneSplit.setSidebarWidget(widget); |
| 1077 this._elementsPanelTreeOutilneSplit.showBoth(true); | 1075 this._elementsPanelTreeOutilneSplit.showBoth(true); |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1252 /** | 1250 /** |
| 1253 * @override | 1251 * @override |
| 1254 * @param {!WebInspector.DOMNode} node | 1252 * @param {!WebInspector.DOMNode} node |
| 1255 * @return {?string} | 1253 * @return {?string} |
| 1256 */ | 1254 */ |
| 1257 decorate: function(node) | 1255 decorate: function(node) |
| 1258 { | 1256 { |
| 1259 return WebInspector.UIString("Element is hidden"); | 1257 return WebInspector.UIString("Element is hidden"); |
| 1260 } | 1258 } |
| 1261 } | 1259 } |
| OLD | NEW |