mirror of
https://github.com/scratchfoundation/scratch-paint.git
synced 2024-12-23 05:52:42 -05:00
Queue perform snapshot (#430)
This commit is contained in:
parent
a75262463b
commit
fd6268c940
1 changed files with 4 additions and 1 deletions
|
@ -250,7 +250,10 @@ class PaperCanvas extends React.Component {
|
||||||
.subtract(itemWidth, itemHeight));
|
.subtract(itemWidth, itemHeight));
|
||||||
}
|
}
|
||||||
|
|
||||||
performSnapshot(paperCanvas.props.undoSnapshot, Formats.VECTOR_SKIP_CONVERT);
|
// Without the callback, the transforms sometimes don't finish applying before the
|
||||||
|
// snapshot is taken.
|
||||||
|
window.setTimeout(
|
||||||
|
() => performSnapshot(paperCanvas.props.undoSnapshot, Formats.VECTOR_SKIP_CONVERT), 0);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue