| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 /** @typedef {!{ | 4 /** @typedef {!{ |
| 5 rect: !Protocol.DOM.Rect, | 5 rect: !Protocol.DOM.Rect, |
| 6 snapshot: !SDK.PaintProfilerSnapshot | 6 snapshot: !SDK.PaintProfilerSnapshot |
| 7 }} | 7 }} |
| 8 */ | 8 */ |
| 9 SDK.SnapshotWithRect; | 9 SDK.SnapshotWithRect; |
| 10 | 10 |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 139 | 139 |
| 140 /** | 140 /** |
| 141 * @unrestricted | 141 * @unrestricted |
| 142 */ | 142 */ |
| 143 SDK.LayerTreeBase = class { | 143 SDK.LayerTreeBase = class { |
| 144 /** | 144 /** |
| 145 * @param {?SDK.Target} target | 145 * @param {?SDK.Target} target |
| 146 */ | 146 */ |
| 147 constructor(target) { | 147 constructor(target) { |
| 148 this._target = target; | 148 this._target = target; |
| 149 this._domModel = target ? SDK.DOMModel.fromTarget(target) : null; | 149 this._domModel = target ? target.model(SDK.DOMModel) : null; |
| 150 this._layersById = {}; | 150 this._layersById = {}; |
| 151 this._root = null; | 151 this._root = null; |
| 152 this._contentRoot = null; | 152 this._contentRoot = null; |
| 153 /** @type {!Map<number, ?SDK.DOMNode>} */ | 153 /** @type {!Map<number, ?SDK.DOMNode>} */ |
| 154 this._backendNodeIdToNode = new Map(); | 154 this._backendNodeIdToNode = new Map(); |
| 155 } | 155 } |
| 156 | 156 |
| 157 /** | 157 /** |
| 158 * @return {?SDK.Target} | 158 * @return {?SDK.Target} |
| 159 */ | 159 */ |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 260 } | 260 } |
| 261 | 261 |
| 262 /** | 262 /** |
| 263 * @param {number} id | 263 * @param {number} id |
| 264 * @return {?SDK.DOMNode} | 264 * @return {?SDK.DOMNode} |
| 265 */ | 265 */ |
| 266 _nodeForId(id) { | 266 _nodeForId(id) { |
| 267 return this._domModel ? this._domModel.nodeForId(id) : null; | 267 return this._domModel ? this._domModel.nodeForId(id) : null; |
| 268 } | 268 } |
| 269 }; | 269 }; |
| OLD | NEW |