| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 152 popoverContentElement = createElementWithClass('div', 'object-popover-
content'); | 152 popoverContentElement = createElementWithClass('div', 'object-popover-
content'); |
| 153 UI.appendStyle(popoverContentElement, 'object_ui/objectPopover.css'); | 153 UI.appendStyle(popoverContentElement, 'object_ui/objectPopover.css'); |
| 154 var titleElement = popoverContentElement.createChild('div', 'monospace
object-popover-title'); | 154 var titleElement = popoverContentElement.createChild('div', 'monospace
object-popover-title'); |
| 155 titleElement.createChild('span').textContent = description; | 155 titleElement.createChild('span').textContent = description; |
| 156 var section = new ObjectUI.ObjectPropertiesSection(result, '', this._l
azyLinkifier()); | 156 var section = new ObjectUI.ObjectPropertiesSection(result, '', this._l
azyLinkifier()); |
| 157 section.element.classList.add('object-popover-tree'); | 157 section.element.classList.add('object-popover-tree'); |
| 158 section.titleLessMode(); | 158 section.titleLessMode(); |
| 159 popoverContentElement.appendChild(section.element); | 159 popoverContentElement.appendChild(section.element); |
| 160 } | 160 } |
| 161 popover.setMaxContentSize(new UI.Size(300, 250)); | 161 popover.setMaxContentSize(new UI.Size(300, 250)); |
| 162 popover.setSizeBehavior(UI.GlassPane.SizeBehavior.SetMaxSize); | 162 popover.setSizeBehavior(UI.GlassPane.SizeBehavior.SetExactSize); |
| 163 popover.showForAnchor(popoverContentElement, anchorElement); | 163 popover.showForAnchor(popoverContentElement, anchorElement); |
| 164 } | 164 } |
| 165 } | 165 } |
| 166 this._disposed = false; | 166 this._disposed = false; |
| 167 this._queryObject(element, didQueryObject.bind(this), this._popoverObjectGro
up); | 167 this._queryObject(element, didQueryObject.bind(this), this._popoverObjectGro
up); |
| 168 } | 168 } |
| 169 | 169 |
| 170 _onHideObjectPopover() { | 170 _onHideObjectPopover() { |
| 171 this._disposed = true; | 171 this._disposed = true; |
| 172 if (this._resultHighlightedAsDOM) { | 172 if (this._resultHighlightedAsDOM) { |
| (...skipping 16 matching lines...) Expand all Loading... |
| 189 * @return {!Components.Linkifier} | 189 * @return {!Components.Linkifier} |
| 190 */ | 190 */ |
| 191 _lazyLinkifier() { | 191 _lazyLinkifier() { |
| 192 if (!this._linkifier) | 192 if (!this._linkifier) |
| 193 this._linkifier = new Components.Linkifier(); | 193 this._linkifier = new Components.Linkifier(); |
| 194 return this._linkifier; | 194 return this._linkifier; |
| 195 } | 195 } |
| 196 }; | 196 }; |
| 197 | 197 |
| 198 ObjectUI.ObjectPopoverHelper.MaxPopoverTextLength = 10000; | 198 ObjectUI.ObjectPopoverHelper.MaxPopoverTextLength = 10000; |
| OLD | NEW |