| Index: third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js
|
| diff --git a/third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js b/third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js
|
| index 8043805990e102c3c5bb16cff7684376d1c72c34..e13de2835a9130dd2f03d9e1adf8cd16a4d8df89 100644
|
| --- a/third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js
|
| +++ b/third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js
|
| @@ -1408,19 +1408,18 @@ WebInspector.TimelineUIUtils._aggregatedStatsForTraceEvent = function(total, mod
|
| */
|
| WebInspector.TimelineUIUtils.buildPicturePreviewContent = function(event, target, callback)
|
| {
|
| - new WebInspector.LayerPaintEvent(event, target).loadSnapshot(onSnapshotLoaded);
|
| + new WebInspector.LayerPaintEvent(event, target).snapshotPromise().then(onSnapshotLoaded);
|
| /**
|
| - * @param {?Array.<number>} rect
|
| - * @param {?WebInspector.PaintProfilerSnapshot} snapshot
|
| + * @param {?{rect: !Array<number>, snapshot: !WebInspector.PaintProfilerSnapshot}} snapshotWithRect
|
| */
|
| - function onSnapshotLoaded(rect, snapshot)
|
| + function onSnapshotLoaded(snapshotWithRect)
|
| {
|
| - if (!snapshot) {
|
| + if (!snapshotWithRect) {
|
| callback();
|
| return;
|
| }
|
| - snapshot.requestImage(null, null, 1, onGotImage);
|
| - snapshot.dispose();
|
| + snapshotWithRect.snapshot.requestImage(null, null, 1, onGotImage);
|
| + snapshotWithRect.snapshot.dispose();
|
| }
|
|
|
| /**
|
|
|