diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 05:43:14 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 05:43:14 +0000 |
commit | 8dd16259287f58f9273002717ec4d27e97127719 (patch) | |
tree | 3863e62a53829a84037444beab3abd4ed9dfc7d0 /gfx/webrender_bindings/WebRenderAPI.cpp | |
parent | Releasing progress-linux version 126.0.1-1~progress7.99u1. (diff) | |
download | firefox-8dd16259287f58f9273002717ec4d27e97127719.tar.xz firefox-8dd16259287f58f9273002717ec4d27e97127719.zip |
Merging upstream version 127.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'gfx/webrender_bindings/WebRenderAPI.cpp')
-rw-r--r-- | gfx/webrender_bindings/WebRenderAPI.cpp | 38 |
1 files changed, 22 insertions, 16 deletions
diff --git a/gfx/webrender_bindings/WebRenderAPI.cpp b/gfx/webrender_bindings/WebRenderAPI.cpp index 09a024a897..105c2dff98 100644 --- a/gfx/webrender_bindings/WebRenderAPI.cpp +++ b/gfx/webrender_bindings/WebRenderAPI.cpp @@ -537,7 +537,25 @@ bool WebRenderAPI::CheckIsRemoteTextureReady( layers::CompositorThread()->Dispatch(runnable.forget()); }; + bool isReady = true; + while (!aList->mList.empty() && isReady) { + auto& front = aList->mList.front(); + isReady &= layers::RemoteTextureMap::Get()->CheckRemoteTextureReady( + front, callback); + if (isReady) { + aList->mList.pop(); + } + } + + if (isReady) { + return true; + } + +#ifndef DEBUG const auto maxWaitDurationMs = 10000; +#else + const auto maxWaitDurationMs = 30000; +#endif const auto now = TimeStamp::Now(); const auto waitDurationMs = static_cast<uint32_t>((now - aTimeStamp).ToMilliseconds()); @@ -548,20 +566,7 @@ bool WebRenderAPI::CheckIsRemoteTextureReady( gfxCriticalNote << "RemoteTexture ready timeout"; } - bool isReady = true; - while (!aList->mList.empty() && isReady) { - auto& front = aList->mList.front(); - isReady &= layers::RemoteTextureMap::Get()->CheckRemoteTextureReady( - front, callback); - if (isTimeout) { - isReady = true; - } - if (isReady) { - aList->mList.pop(); - } - } - - return isReady; + return false; } void WebRenderAPI::WaitRemoteTextureReady( @@ -1256,11 +1261,12 @@ wr::WrSpatialId DisplayListBuilder::DefineStickyFrame( const float* aRightMargin, const float* aBottomMargin, const float* aLeftMargin, const StickyOffsetBounds& aVerticalBounds, const StickyOffsetBounds& aHorizontalBounds, - const wr::LayoutVector2D& aAppliedOffset, wr::SpatialTreeItemKey aKey) { + const wr::LayoutVector2D& aAppliedOffset, wr::SpatialTreeItemKey aKey, + const WrAnimationProperty* aAnimation) { auto spatialId = wr_dp_define_sticky_frame( mWrState, mCurrentSpaceAndClipChain.space, aContentRect, aTopMargin, aRightMargin, aBottomMargin, aLeftMargin, aVerticalBounds, - aHorizontalBounds, aAppliedOffset, aKey); + aHorizontalBounds, aAppliedOffset, aKey, aAnimation); WRDL_LOG("DefineSticky id=%zu c=%s t=%s r=%s b=%s l=%s v=%s h=%s a=%s\n", mWrState, spatialId.id, ToString(aContentRect).c_str(), |