| 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 872 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 883 showMetrics.call(this, true); | 883 showMetrics.call(this, true); |
| 884 else if (tabId === WebInspector.UIString("Styles")) | 884 else if (tabId === WebInspector.UIString("Styles")) |
| 885 showMetrics.call(this, false); | 885 showMetrics.call(this, false); |
| 886 } | 886 } |
| 887 | 887 |
| 888 this.sidebarPaneView = WebInspector.viewManager.createTabbedLocation(()
=> WebInspector.viewManager.showView("elements")); | 888 this.sidebarPaneView = WebInspector.viewManager.createTabbedLocation(()
=> WebInspector.viewManager.showView("elements")); |
| 889 var tabbedPane = this.sidebarPaneView.tabbedPane(); | 889 var tabbedPane = this.sidebarPaneView.tabbedPane(); |
| 890 tabbedPane.element.addEventListener("contextmenu", this._sidebarContextM
enuEventFired.bind(this), false); | 890 tabbedPane.element.addEventListener("contextmenu", this._sidebarContextM
enuEventFired.bind(this), false); |
| 891 if (this._popoverHelper) | 891 if (this._popoverHelper) |
| 892 this._popoverHelper.hidePopover(); | 892 this._popoverHelper.hidePopover(); |
| 893 this._popoverHelper = new WebInspector.PopoverHelper(tabbedPane.element,
this._getPopoverAnchor.bind(this), this._showPopover.bind(this)); | 893 this._popoverHelper = new WebInspector.PopoverHelper(tabbedPane.element)
; |
| 894 this._popoverHelper.initializeCallbacks(this._getPopoverAnchor.bind(this
), this._showPopover.bind(this)); |
| 894 this._popoverHelper.setTimeout(0); | 895 this._popoverHelper.setTimeout(0); |
| 895 | 896 |
| 896 if (horizontally) { | 897 if (horizontally) { |
| 897 // Styles and computed are merged into a single tab. | 898 // Styles and computed are merged into a single tab. |
| 898 this._splitWidget.installResizer(tabbedPane.headerElement()); | 899 this._splitWidget.installResizer(tabbedPane.headerElement()); |
| 899 | 900 |
| 900 var stylesView = new WebInspector.SimpleView(WebInspector.UIString("
Styles")); | 901 var stylesView = new WebInspector.SimpleView(WebInspector.UIString("
Styles")); |
| 901 stylesView.element.classList.add("flex-auto"); | 902 stylesView.element.classList.add("flex-auto"); |
| 902 | 903 |
| 903 var splitWidget = new WebInspector.SplitWidget(true, true, "stylesPa
neSplitViewState", 215); | 904 var splitWidget = new WebInspector.SplitWidget(true, true, "stylesPa
neSplitViewState", 215); |
| (...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1121 /** | 1122 /** |
| 1122 * @override | 1123 * @override |
| 1123 * @param {!WebInspector.DOMNode} node | 1124 * @param {!WebInspector.DOMNode} node |
| 1124 * @return {?{title: string, color: string}} | 1125 * @return {?{title: string, color: string}} |
| 1125 */ | 1126 */ |
| 1126 decorate: function(node) | 1127 decorate: function(node) |
| 1127 { | 1128 { |
| 1128 return { color: "orange", title: WebInspector.UIString("Element state: %
s", ":" + WebInspector.CSSModel.fromNode(node).pseudoState(node).join(", :")) }; | 1129 return { color: "orange", title: WebInspector.UIString("Element state: %
s", ":" + WebInspector.CSSModel.fromNode(node).pseudoState(node).join(", :")) }; |
| 1129 } | 1130 } |
| 1130 }; | 1131 }; |
| OLD | NEW |