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 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
76 crumbsContainer.id = "elements-crumbs"; | 76 crumbsContainer.id = "elements-crumbs"; |
77 this._breadcrumbs = new WebInspector.ElementsBreadcrumbs(); | 77 this._breadcrumbs = new WebInspector.ElementsBreadcrumbs(); |
78 this._breadcrumbs.show(crumbsContainer); | 78 this._breadcrumbs.show(crumbsContainer); |
79 this._breadcrumbs.addEventListener(WebInspector.ElementsBreadcrumbs.Events.N
odeSelected, this._crumbNodeSelected, this); | 79 this._breadcrumbs.addEventListener(WebInspector.ElementsBreadcrumbs.Events.N
odeSelected, this._crumbNodeSelected, this); |
80 | 80 |
81 this.sidebarPanes = {}; | 81 this.sidebarPanes = {}; |
82 /** @type !Array<!WebInspector.ElementsSidebarViewWrapperPane> */ | 82 /** @type !Array<!WebInspector.ElementsSidebarViewWrapperPane> */ |
83 this._elementsSidebarViewWrappers = []; | 83 this._elementsSidebarViewWrappers = []; |
84 var sharedSidebarModel = new WebInspector.SharedSidebarModel(); | 84 var sharedSidebarModel = new WebInspector.SharedSidebarModel(); |
85 this.sidebarPanes.platformFonts = WebInspector.PlatformFontsWidget.createSid
ebarWrapper(sharedSidebarModel); | 85 this.sidebarPanes.platformFonts = WebInspector.PlatformFontsWidget.createSid
ebarWrapper(sharedSidebarModel); |
86 this.sidebarPanes.styles = new WebInspector.StylesSidebarPane(this._showStyl
esSidebar.bind(this)); | 86 this.sidebarPanes.styles = new WebInspector.StylesSidebarPane(); |
87 | 87 |
88 this.sidebarPanes.computedStyle = WebInspector.ComputedStyleWidget.createSid
ebarWrapper(this.sidebarPanes.styles, sharedSidebarModel); | 88 this.sidebarPanes.computedStyle = WebInspector.ComputedStyleWidget.createSid
ebarWrapper(this.sidebarPanes.styles, sharedSidebarModel); |
89 | 89 |
90 this.sidebarPanes.styles.addEventListener(WebInspector.StylesSidebarPane.Eve
nts.SelectorEditingStarted, this._onEditingSelectorStarted.bind(this)); | 90 this.sidebarPanes.styles.addEventListener(WebInspector.StylesSidebarPane.Eve
nts.SelectorEditingStarted, this._onEditingSelectorStarted.bind(this)); |
91 this.sidebarPanes.styles.addEventListener(WebInspector.StylesSidebarPane.Eve
nts.SelectorEditingEnded, this._onEditingSelectorEnded.bind(this)); | 91 this.sidebarPanes.styles.addEventListener(WebInspector.StylesSidebarPane.Eve
nts.SelectorEditingEnded, this._onEditingSelectorEnded.bind(this)); |
92 | 92 |
93 this.sidebarPanes.metrics = new WebInspector.MetricsSidebarPane(); | 93 this.sidebarPanes.metrics = new WebInspector.MetricsSidebarPane(); |
94 this.sidebarPanes.properties = WebInspector.PropertiesWidget.createSidebarWr
apper(); | 94 this.sidebarPanes.properties = WebInspector.PropertiesWidget.createSidebarWr
apper(); |
95 this.sidebarPanes.domBreakpoints = WebInspector.domBreakpointsSidebarPane.cr
eateProxy(this); | 95 this.sidebarPanes.domBreakpoints = WebInspector.domBreakpointsSidebarPane.cr
eateProxy(this); |
96 this.sidebarPanes.eventListeners = WebInspector.EventListenersWidget.createS
idebarWrapper(); | 96 this.sidebarPanes.eventListeners = WebInspector.EventListenersWidget.createS
idebarWrapper(); |
(...skipping 841 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
938 contextMenu.appendApplicableItems(/** @type {!Object} */ (event.deepElem
entFromPoint())); | 938 contextMenu.appendApplicableItems(/** @type {!Object} */ (event.deepElem
entFromPoint())); |
939 contextMenu.show(); | 939 contextMenu.show(); |
940 }, | 940 }, |
941 | 941 |
942 _showUAShadowDOMChanged: function() | 942 _showUAShadowDOMChanged: function() |
943 { | 943 { |
944 for (var i = 0; i < this._treeOutlines.length; ++i) | 944 for (var i = 0; i < this._treeOutlines.length; ++i) |
945 this._treeOutlines[i].update(); | 945 this._treeOutlines[i].update(); |
946 }, | 946 }, |
947 | 947 |
948 _showStylesSidebar: function() | |
949 { | |
950 this.sidebarPaneView.selectTab(this.sidebarPanes.styles.title()); | |
951 }, | |
952 | |
953 _updateSidebarPosition: function() | 948 _updateSidebarPosition: function() |
954 { | 949 { |
955 var vertically; | 950 var vertically; |
956 var position = WebInspector.moduleSetting("sidebarPosition").get(); | 951 var position = WebInspector.moduleSetting("sidebarPosition").get(); |
957 if (position === "right") | 952 if (position === "right") |
958 vertically = false; | 953 vertically = false; |
959 else if (position === "bottom") | 954 else if (position === "bottom") |
960 vertically = true; | 955 vertically = true; |
961 else | 956 else |
962 vertically = WebInspector.inspectorView.element.offsetWidth < 680; | 957 vertically = WebInspector.inspectorView.element.offsetWidth < 680; |
(...skipping 388 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1351 if (enabled) | 1346 if (enabled) |
1352 return; | 1347 return; |
1353 | 1348 |
1354 var selectedNode = this._treeOutline.selectedDOMNode(); | 1349 var selectedNode = this._treeOutline.selectedDOMNode(); |
1355 if (selectedNode) | 1350 if (selectedNode) |
1356 WebInspector.DefaultDOMNodeHighlighter.prototype.highlightDOMNode.ca
ll(this, selectedNode, config); | 1351 WebInspector.DefaultDOMNodeHighlighter.prototype.highlightDOMNode.ca
ll(this, selectedNode, config); |
1357 }, | 1352 }, |
1358 | 1353 |
1359 __proto__: WebInspector.DefaultDOMNodeHighlighter.prototype | 1354 __proto__: WebInspector.DefaultDOMNodeHighlighter.prototype |
1360 } | 1355 } |
OLD | NEW |