fix windows/mac + rename async_drop to terminate

This commit is contained in:
Ferdinand Schober
2024-07-10 22:33:37 +02:00
parent ebf7897caa
commit ae3ea2c497
9 changed files with 26 additions and 13 deletions

View File

@@ -59,7 +59,7 @@ pub fn new(
CaptureEvent::Destroy(h) => capture.destroy(h).await?,
CaptureEvent::Restart => {
let clients = server.client_manager.borrow().get_client_states().map(|(h, (c,_))| (h, c.pos)).collect::<Vec<_>>();
capture.async_drop().await?;
capture.terminate().await?;
capture = input_capture::create(backend).await?;
for (handle, pos) in clients {
capture.create(handle, pos.into()).await?;