aboutsummaryrefslogtreecommitdiffstats
path: root/components/shared/webrender/rendering_context.rs
diff options
context:
space:
mode:
authorNgo Iok Ui (Wu Yu Wei) <yuweiwu@pm.me>2024-08-06 15:06:21 +0900
committerGitHub <noreply@github.com>2024-08-06 06:06:21 +0000
commit3f339d6856283dc4839f6378df5df1ddbedcb5d6 (patch)
tree48335454fccf69435762e03a42c3d685860ce4eb /components/shared/webrender/rendering_context.rs
parent23df681479e20d099abae2852c2107b395fb09a1 (diff)
downloadservo-3f339d6856283dc4839f6378df5df1ddbedcb5d6.tar.gz
servo-3f339d6856283dc4839f6378df5df1ddbedcb5d6.zip
webrender_traits: update closure in with_front_buffer to FnOnce (#32946)
Signed-off-by: Wu Wayne <yuweiwu@pm.me>
Diffstat (limited to 'components/shared/webrender/rendering_context.rs')
-rw-r--r--components/shared/webrender/rendering_context.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/components/shared/webrender/rendering_context.rs b/components/shared/webrender/rendering_context.rs
index 96aa4cb32ee..c9f4057fd58 100644
--- a/components/shared/webrender/rendering_context.rs
+++ b/components/shared/webrender/rendering_context.rs
@@ -169,7 +169,7 @@ impl RenderingContext {
/// Invoke a closure with the surface associated with the current front buffer.
/// This can be used to create a surfman::SurfaceTexture to blit elsewhere.
- pub fn with_front_buffer<F: FnMut(&Device, Surface) -> Surface>(&self, mut f: F) {
+ pub fn with_front_buffer<F: FnOnce(&Device, Surface) -> Surface>(&self, f: F) {
let device = &mut self.0.device.borrow_mut();
let context = &mut self.0.context.borrow_mut();
let surface = device