Bug 1573343 - Destroy mFullWindowRenderTarget in a different place. r=mattwoodrow

Differential Revision: https://phabricator.services.mozilla.com/D42415

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Markus Stange 2019-08-19 22:41:27 +00:00
Родитель d417bf03ed
Коммит 529ee470f1
1 изменённых файлов: 4 добавлений и 6 удалений

Просмотреть файл

@ -992,6 +992,10 @@ void BasicCompositor::BeginFrame(
mFullWindowRenderTarget =
new BasicCompositingRenderTarget(drawTarget, rect);
}
} else if (mFullWindowRenderTarget) {
// If we are no longer recording a profile, we can drop the render target
// if it exists.
mFullWindowRenderTarget = nullptr;
}
gfxUtils::ClipToRegion(mRenderTarget->mDrawTarget,
@ -1034,12 +1038,6 @@ void BasicCompositor::EndFrame() {
mRenderTarget->mDrawTarget->SetTransform(gfx::Matrix());
TryToEndRemoteDrawing();
// If we are no longer recording a profile, we can drop the render target if
// it exists.
if (mFullWindowRenderTarget && !ShouldRecordFrames()) {
mFullWindowRenderTarget = nullptr;
}
}
void BasicCompositor::TryToEndRemoteDrawing(bool aForceToEnd) {