| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 | 4 |
| 5 /** | 5 /** |
| 6 * @constructor | 6 * @constructor |
| 7 * @param {!WebInspector.TracingTimelineFrameModel} frameModel | 7 * @param {!WebInspector.TracingTimelineFrameModel} frameModel |
| 8 * @extends {WebInspector.SplitWidget} | 8 * @extends {WebInspector.SplitWidget} |
| 9 */ | 9 */ |
| 10 WebInspector.TimelinePaintProfilerView = function(frameModel) | 10 WebInspector.TimelinePaintProfilerView = function(frameModel) |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 * @param {!WebInspector.Target} target | 42 * @param {!WebInspector.Target} target |
| 43 * @param {!WebInspector.TracingModel.Event} event | 43 * @param {!WebInspector.TracingModel.Event} event |
| 44 * @return {boolean} | 44 * @return {boolean} |
| 45 */ | 45 */ |
| 46 setEvent: function(target, event) | 46 setEvent: function(target, event) |
| 47 { | 47 { |
| 48 this._disposeSnapshot(); | 48 this._disposeSnapshot(); |
| 49 this._target = target; | 49 this._target = target; |
| 50 this._event = event; | 50 this._event = event; |
| 51 | 51 |
| 52 this._updateWhenVisible = true; | 52 if (this.isShowing()) |
| 53 this._update(); |
| 54 else |
| 55 this._updateWhenVisible = true; |
| 53 | 56 |
| 54 if (this._event.name === WebInspector.TimelineModel.RecordType.Paint) | 57 if (this._event.name === WebInspector.TimelineModel.RecordType.Paint) |
| 55 return !!event.picture; | 58 return !!event.picture; |
| 56 if (this._event.name === WebInspector.TimelineModel.RecordType.RasterTas
k) | 59 if (this._event.name === WebInspector.TimelineModel.RecordType.RasterTas
k) |
| 57 return this._frameModel.hasRasterTile(this._event); | 60 return this._frameModel.hasRasterTile(this._event); |
| 58 return false; | 61 return false; |
| 59 }, | 62 }, |
| 60 | 63 |
| 61 _update: function() | 64 _update: function() |
| 62 { | 65 { |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 197 * @param {?DOMAgent.Rect} maskRectangle | 200 * @param {?DOMAgent.Rect} maskRectangle |
| 198 */ | 201 */ |
| 199 setMask: function(maskRectangle) | 202 setMask: function(maskRectangle) |
| 200 { | 203 { |
| 201 this._maskRectangle = maskRectangle; | 204 this._maskRectangle = maskRectangle; |
| 202 this._maskElement.classList.toggle("hidden", !maskRectangle); | 205 this._maskElement.classList.toggle("hidden", !maskRectangle); |
| 203 }, | 206 }, |
| 204 | 207 |
| 205 __proto__: WebInspector.Widget.prototype | 208 __proto__: WebInspector.Widget.prototype |
| 206 }; | 209 }; |
| OLD | NEW |