screencopy: Use send_success_when_ready for other forms of capture

A little annoying to add a `loop_handle` argument to `render_output`,
but generally straightforward.
This commit is contained in:
Ian Douglas Scott 2025-08-20 15:31:18 -07:00 committed by Victoria Brekenfeld
parent 10c05bc1d4
commit 905d021552
4 changed files with 28 additions and 13 deletions

View file

@ -471,8 +471,12 @@ pub fn render_workspace_to_buffer(
}
};
if let Some(PendingImageCopyData { frame, damage, .. }) = result {
frame.success(transform, damage, common.clock.now())
if let Some(pending_image_copy_data) = result {
pending_image_copy_data.send_success_when_ready(
transform,
&common.event_loop_handle,
common.clock.now(),
);
}
}
@ -702,8 +706,12 @@ pub fn render_window_to_buffer(
},
};
if let Some(PendingImageCopyData { frame, damage, .. }) = result {
frame.success(Transform::Normal, damage, common.clock.now())
if let Some(pending_image_copy_data) = result {
pending_image_copy_data.send_success_when_ready(
Transform::Normal,
&common.event_loop_handle,
common.clock.now(),
);
}
}
@ -858,7 +866,11 @@ pub fn render_cursor_to_buffer(
}
};
if let Some(PendingImageCopyData { frame, damage, .. }) = result {
frame.success(Transform::Normal, damage, common.clock.now())
if let Some(pending_image_copy_data) = result {
pending_image_copy_data.send_success_when_ready(
Transform::Normal,
&common.event_loop_handle,
common.clock.now(),
);
}
}