Index: third_party/WebKit/Source/devtools/front_end/timeline_model/TimelineFrameModel.js |
diff --git a/third_party/WebKit/Source/devtools/front_end/timeline_model/TimelineFrameModel.js b/third_party/WebKit/Source/devtools/front_end/timeline_model/TimelineFrameModel.js |
index 26792154384c1ab891daf8d919cbbc7b1ebc08ea..5351a44a412fae75442cff7a01990815f03962c8 100644 |
--- a/third_party/WebKit/Source/devtools/front_end/timeline_model/TimelineFrameModel.js |
+++ b/third_party/WebKit/Source/devtools/front_end/timeline_model/TimelineFrameModel.js |
@@ -505,10 +505,11 @@ TimelineModel.LayerPaintEvent = class { |
* @return !Promise<?{rect: !Array<number>, snapshot: !SDK.PaintProfilerSnapshot}>} |
*/ |
snapshotPromise() { |
+ var paintProfilerModel = this._target && this._target.model(SDK.PaintProfilerModel); |
return this.picturePromise().then(picture => { |
- if (!picture || !this._target) |
+ if (!picture || !paintProfilerModel) |
return null; |
- return SDK.PaintProfilerSnapshot.load(this._target, picture.serializedPicture) |
+ return paintProfilerModel.loadSnapshot(picture.serializedPicture) |
.then(snapshot => snapshot ? {rect: picture.rect, snapshot: snapshot} : null); |
}); |
} |