diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:13:27 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:13:27 +0000 |
commit | 40a355a42d4a9444dc753c04c6608dade2f06a23 (patch) | |
tree | 871fc667d2de662f171103ce5ec067014ef85e61 /gfx/layers/wr/WebRenderImageHost.cpp | |
parent | Adding upstream version 124.0.1. (diff) | |
download | firefox-40a355a42d4a9444dc753c04c6608dade2f06a23.tar.xz firefox-40a355a42d4a9444dc753c04c6608dade2f06a23.zip |
Adding upstream version 125.0.1.upstream/125.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'gfx/layers/wr/WebRenderImageHost.cpp')
-rw-r--r-- | gfx/layers/wr/WebRenderImageHost.cpp | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/gfx/layers/wr/WebRenderImageHost.cpp b/gfx/layers/wr/WebRenderImageHost.cpp index e3bbd5d50f..5016bc30f8 100644 --- a/gfx/layers/wr/WebRenderImageHost.cpp +++ b/gfx/layers/wr/WebRenderImageHost.cpp @@ -198,8 +198,11 @@ void WebRenderImageHost::UseRemoteTexture() { while (!mPendingRemoteTextureWrappers.empty()) { auto* wrapper = mPendingRemoteTextureWrappers.front()->AsRemoteTextureHostWrapper(); - mWaitingReadyCallback = RemoteTextureMap::Get()->GetRemoteTexture( - wrapper, readyCallback, mWaitForRemoteTextureOwner); + if (mWaitForRemoteTextureOwner) { + RemoteTextureMap::Get()->WaitForRemoteTextureOwner(wrapper); + } + mWaitingReadyCallback = + RemoteTextureMap::Get()->GetRemoteTexture(wrapper, readyCallback); MOZ_ASSERT_IF(mWaitingReadyCallback, !wrapper->IsReadyForRendering()); if (!wrapper->IsReadyForRendering()) { break; @@ -213,9 +216,9 @@ void WebRenderImageHost::UseRemoteTexture() { mPendingRemoteTextureWrappers.pop_front(); MOZ_ASSERT(mPendingRemoteTextureWrappers.empty()); - std::function<void(const RemoteTextureInfo&)> function; - RemoteTextureMap::Get()->GetRemoteTexture(wrapper, std::move(function), - mWaitForRemoteTextureOwner); + if (mWaitForRemoteTextureOwner) { + RemoteTextureMap::Get()->WaitForRemoteTextureOwner(wrapper); + } mWaitForRemoteTextureOwner = false; } |