Chromium Code Reviews| 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 15 matching lines...) Expand all Loading... | |
| 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 29 */ | 29 */ |
| 30 | 30 |
| 31 /** | 31 /** |
| 32 * @constructor | 32 * @constructor |
| 33 * @extends {WebInspector.PopoverHelper} | 33 * @extends {WebInspector.PopoverHelper} |
| 34 * @param {!Element} panelElement | 34 * @param {!Element} panelElement |
| 35 * @param {function(!Element, !Event):!Element|undefined} getAnchor | 35 * @param {function(!Element, !Event):!Element|undefined} getAnchor |
| 36 * @param {function(!Element, function(!WebInspector.RemoteObject, boolean, !Ele ment=):undefined, string):undefined} queryObject | 36 * @param {function(!Element, function(!WebInspector.RemoteObject, boolean=, !El ement=):undefined, string):undefined} queryObject |
|
caseq
2014/06/11 16:03:21
is this really necessary?
malch
2014/06/11 16:32:58
Added it because of the lint error. Removed it.
On
| |
| 37 * @param {function()=} onHide | 37 * @param {function()=} onHide |
| 38 * @param {boolean=} disableOnClick | 38 * @param {boolean=} disableOnClick |
| 39 */ | 39 */ |
| 40 WebInspector.ObjectPopoverHelper = function(panelElement, getAnchor, queryObject , onHide, disableOnClick) | 40 WebInspector.ObjectPopoverHelper = function(panelElement, getAnchor, queryObject , onHide, disableOnClick) |
| 41 { | 41 { |
| 42 WebInspector.PopoverHelper.call(this, panelElement, getAnchor, this._showObj ectPopover.bind(this), this._onHideObjectPopover.bind(this), disableOnClick); | 42 WebInspector.PopoverHelper.call(this, panelElement, getAnchor, this._showObj ectPopover.bind(this), this._onHideObjectPopover.bind(this), disableOnClick); |
| 43 this._queryObject = queryObject; | 43 this._queryObject = queryObject; |
| 44 this._onHideCallback = onHide; | 44 this._onHideCallback = onHide; |
| 45 this._popoverObjectGroup = "popover"; | 45 this._popoverObjectGroup = "popover"; |
| 46 panelElement.addEventListener("scroll", this.hidePopover.bind(this), true); | 46 panelElement.addEventListener("scroll", this.hidePopover.bind(this), true); |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 86 if (link) | 86 if (link) |
| 87 title.appendChild(link); | 87 title.appendChild(link); |
| 88 | 88 |
| 89 container.appendChild(popoverContentElement); | 89 container.appendChild(popoverContentElement); |
| 90 | 90 |
| 91 popover.show(container, anchorElement); | 91 popover.show(container, anchorElement); |
| 92 } | 92 } |
| 93 | 93 |
| 94 /** | 94 /** |
| 95 * @param {!WebInspector.RemoteObject} result | 95 * @param {!WebInspector.RemoteObject} result |
| 96 * @param {boolean} wasThrown | 96 * @param {boolean=} wasThrown |
| 97 * @param {!Element=} anchorOverride | 97 * @param {!Element=} anchorOverride |
| 98 * @this {WebInspector.ObjectPopoverHelper} | 98 * @this {WebInspector.ObjectPopoverHelper} |
| 99 */ | 99 */ |
| 100 function showObjectPopover(result, wasThrown, anchorOverride) | 100 function showObjectPopover(result, wasThrown, anchorOverride) |
| 101 { | 101 { |
| 102 if (popover.disposed) | 102 if (popover.disposed) |
| 103 return; | 103 return; |
| 104 if (wasThrown) { | 104 if (wasThrown) { |
| 105 this.hidePopover(); | 105 this.hidePopover(); |
| 106 return; | 106 return; |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 174 if (properties[i].value.description) | 174 if (properties[i].value.description) |
| 175 this._titleElement.textContent += "#" + properties[i].value. description; | 175 this._titleElement.textContent += "#" + properties[i].value. description; |
| 176 break; | 176 break; |
| 177 } | 177 } |
| 178 } | 178 } |
| 179 this._sectionUpdateProperties(properties, rootTreeElementConstructor, ro otPropertyComparer); | 179 this._sectionUpdateProperties(properties, rootTreeElementConstructor, ro otPropertyComparer); |
| 180 }, | 180 }, |
| 181 | 181 |
| 182 __proto__: WebInspector.PopoverHelper.prototype | 182 __proto__: WebInspector.PopoverHelper.prototype |
| 183 } | 183 } |
| OLD | NEW |