Bug 1458414 - Call DiscardCompositorAnimations() after BuildWebRenderCommands(). r?kats
Since
bug 1457448 we can clear discarded animations on the same transaction where we send
animations to the compositor.
MozReview-Commit-ID: 4BYsCgA98S0
--- a/gfx/layers/wr/WebRenderLayerManager.cpp
+++ b/gfx/layers/wr/WebRenderLayerManager.cpp
@@ -259,31 +259,32 @@ WebRenderLayerManager::EndTransactionWit
#ifdef XP_WIN
gfxDWriteFont::UpdateClearTypeUsage();
#endif
// Since we don't do repeat transactions right now, just set the time
mAnimationReadyTime = TimeStamp::Now();
WrBridge()->BeginTransaction();
- DiscardCompositorAnimations();
LayoutDeviceIntSize size = mWidget->GetClientSize();
wr::LayoutSize contentSize { (float)size.width, (float)size.height };
wr::DisplayListBuilder builder(WrBridge()->GetPipeline(), contentSize, mLastDisplayListSize);
wr::IpcResourceUpdateQueue resourceUpdates(WrBridge());
mWebRenderCommandBuilder.BuildWebRenderCommands(builder,
resourceUpdates,
aDisplayList,
aDisplayListBuilder,
mScrollData,
contentSize,
aFilters);
+ DiscardCompositorAnimations();
+
mWidget->AddWindowOverlayWebRenderCommands(WrBridge(), builder, resourceUpdates);
mWindowOverlayChanged = false;
if (AsyncPanZoomEnabled()) {
mScrollData.SetFocusTarget(mFocusTarget);
mFocusTarget = FocusTarget();
if (mIsFirstPaint) {