Bug 1389743 - Only reconstruct frames synchronously from ContentRemoved when called from frame construction

Tag #1375
This commit is contained in:
Matt A. Tobin 2020-04-17 06:14:10 -04:00 committed by Roy Tam
commit f63cd76698
9 changed files with 201 additions and 285 deletions

View file

@ -1249,8 +1249,10 @@ if (!mDestroyedFrames) {
// We could also have problems with triggering of CSS transitions
// on elements whose frames are reconstructed, since we depend on
// the reconstruction happening synchronously.
frameConstructor->RecreateFramesForContent(content, false,
nsCSSFrameConstructor::REMOVE_FOR_RECONSTRUCTION, nullptr);
frameConstructor->RecreateFramesForContent(
content,
nsCSSFrameConstructor::InsertionKind::Sync,
nsCSSFrameConstructor::REMOVE_FOR_RECONSTRUCTION);
} else {
NS_ASSERTION(frame, "This shouldn't happen");