| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009, 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2009, 2010 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2009 Joseph Pecoraro | 3 * Copyright (C) 2009 Joseph Pecoraro |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 129 /** | 129 /** |
| 130 * @enum {string} | 130 * @enum {string} |
| 131 */ | 131 */ |
| 132 WebInspector.DOMNode.ShadowRootTypes = { | 132 WebInspector.DOMNode.ShadowRootTypes = { |
| 133 UserAgent: "user-agent", | 133 UserAgent: "user-agent", |
| 134 Author: "author" | 134 Author: "author" |
| 135 } | 135 } |
| 136 | 136 |
| 137 WebInspector.DOMNode.prototype = { | 137 WebInspector.DOMNode.prototype = { |
| 138 /** | 138 /** |
| 139 * @return {!WebInspector.DOMModel} |
| 140 */ |
| 141 domModel: function() |
| 142 { |
| 143 return this._domModel; |
| 144 }, |
| 145 |
| 146 /** |
| 139 * @return {?Array.<!WebInspector.DOMNode>} | 147 * @return {?Array.<!WebInspector.DOMNode>} |
| 140 */ | 148 */ |
| 141 children: function() | 149 children: function() |
| 142 { | 150 { |
| 143 return this._children ? this._children.slice() : null; | 151 return this._children ? this._children.slice() : null; |
| 144 }, | 152 }, |
| 145 | 153 |
| 146 /** | 154 /** |
| 147 * @return {boolean} | 155 * @return {boolean} |
| 148 */ | 156 */ |
| (...skipping 628 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 777 { | 785 { |
| 778 if (!url) | 786 if (!url) |
| 779 return url; | 787 return url; |
| 780 for (var frameOwnerCandidate = this; frameOwnerCandidate; frameOwnerCand
idate = frameOwnerCandidate.parentNode) { | 788 for (var frameOwnerCandidate = this; frameOwnerCandidate; frameOwnerCand
idate = frameOwnerCandidate.parentNode) { |
| 781 if (frameOwnerCandidate.baseURL) | 789 if (frameOwnerCandidate.baseURL) |
| 782 return WebInspector.ParsedURL.completeURL(frameOwnerCandidate.ba
seURL, url); | 790 return WebInspector.ParsedURL.completeURL(frameOwnerCandidate.ba
seURL, url); |
| 783 } | 791 } |
| 784 return null; | 792 return null; |
| 785 }, | 793 }, |
| 786 | 794 |
| 795 /** |
| 796 * @param {string=} mode |
| 797 * @param {!RuntimeAgent.RemoteObjectId=} objectId |
| 798 */ |
| 799 highlight: function(mode, objectId) |
| 800 { |
| 801 this._domModel.highlightDOMNode(this.id, mode, objectId); |
| 802 }, |
| 803 |
| 804 highlightForTwoSeconds: function() |
| 805 { |
| 806 this._domModel.highlightDOMNodeForTwoSeconds(this.id); |
| 807 }, |
| 808 |
| 809 reveal: function() |
| 810 { |
| 811 WebInspector.Revealer.reveal(this); |
| 812 }, |
| 813 |
| 787 __proto__: WebInspector.TargetAware.prototype | 814 __proto__: WebInspector.TargetAware.prototype |
| 788 } | 815 } |
| 789 | 816 |
| 790 /** | 817 /** |
| 791 * @extends {WebInspector.DOMNode} | 818 * @extends {WebInspector.DOMNode} |
| 792 * @constructor | 819 * @constructor |
| 793 * @param {!WebInspector.DOMModel} domModel | 820 * @param {!WebInspector.DOMModel} domModel |
| 794 * @param {!DOMAgent.Node} payload | 821 * @param {!DOMAgent.Node} payload |
| 795 */ | 822 */ |
| 796 WebInspector.DOMDocument = function(domModel, payload) | 823 WebInspector.DOMDocument = function(domModel, payload) |
| (...skipping 889 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1686 setInspectModeEnabled: function(enabled, inspectUAShadowDOM, config, callbac
k) | 1713 setInspectModeEnabled: function(enabled, inspectUAShadowDOM, config, callbac
k) |
| 1687 { | 1714 { |
| 1688 DOMAgent.setInspectModeEnabled(enabled, inspectUAShadowDOM, config, call
back); | 1715 DOMAgent.setInspectModeEnabled(enabled, inspectUAShadowDOM, config, call
back); |
| 1689 } | 1716 } |
| 1690 } | 1717 } |
| 1691 | 1718 |
| 1692 /** | 1719 /** |
| 1693 * @type {!WebInspector.DOMModel} | 1720 * @type {!WebInspector.DOMModel} |
| 1694 */ | 1721 */ |
| 1695 WebInspector.domModel; | 1722 WebInspector.domModel; |
| OLD | NEW |