summaryrefslogtreecommitdiffstats
path: root/gfx/layers/wr/WebRenderBridgeParent.cpp
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-15 03:34:42 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-15 03:34:42 +0000
commitda4c7e7ed675c3bf405668739c3012d140856109 (patch)
treecdd868dba063fecba609a1d819de271f0d51b23e /gfx/layers/wr/WebRenderBridgeParent.cpp
parentAdding upstream version 125.0.3. (diff)
downloadfirefox-da4c7e7ed675c3bf405668739c3012d140856109.tar.xz
firefox-da4c7e7ed675c3bf405668739c3012d140856109.zip
Adding upstream version 126.0.upstream/126.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'gfx/layers/wr/WebRenderBridgeParent.cpp')
-rw-r--r--gfx/layers/wr/WebRenderBridgeParent.cpp16
1 files changed, 10 insertions, 6 deletions
diff --git a/gfx/layers/wr/WebRenderBridgeParent.cpp b/gfx/layers/wr/WebRenderBridgeParent.cpp
index 83139b6af6..68e0c7af8c 100644
--- a/gfx/layers/wr/WebRenderBridgeParent.cpp
+++ b/gfx/layers/wr/WebRenderBridgeParent.cpp
@@ -1919,6 +1919,10 @@ mozilla::ipc::IPCResult WebRenderBridgeParent::RecvClearCachedResources() {
wr::AsUint64(mPipelineId), wr::AsUint64(mApi->GetId()),
IsRootWebRenderBridgeParent());
+ if (!IsRootWebRenderBridgeParent()) {
+ mApi->FlushPendingWrTransactionEventsWithoutWait();
+ }
+
// Clear resources
wr::TransactionBuilder txn(mApi);
txn.SetLowPriority(true);
@@ -2618,17 +2622,17 @@ void WebRenderBridgeParent::ScheduleGenerateFrame(wr::RenderReasons aReasons) {
}
void WebRenderBridgeParent::FlushRendering(wr::RenderReasons aReasons,
- bool aWaitForPresent) {
+ bool aBlocking) {
if (mDestroyed) {
return;
}
- // This gets called during e.g. window resizes, so we need to flush the
- // scene (which has the display list at the new window size).
- FlushSceneBuilds();
- FlushFrameGeneration(aReasons);
- if (aWaitForPresent) {
+ if (aBlocking) {
+ FlushSceneBuilds();
+ FlushFrameGeneration(aReasons);
FlushFramePresentation();
+ } else {
+ ScheduleGenerateFrame(aReasons);
}
}