mirror of
https://gitlab.com/marcandre.lureau/qemu-display.git
synced 2024-12-22 13:45:18 +00:00
qemu-rdp: actually register dbus clipboard handler
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
This commit is contained in:
parent
dc080909fe
commit
9def4f259c
@ -207,7 +207,7 @@ async fn rdp_clipboard_receive_task(mut rx: Receiver<ClipboardEvent>, cb: Clipbo
|
|||||||
Some(ClipboardEvent::Register) => {
|
Some(ClipboardEvent::Register) => {
|
||||||
debug!("Register -> dbus");
|
debug!("Register -> dbus");
|
||||||
|
|
||||||
clipboard.proxy.register().await
|
clipboard.register(cb.clone()).await
|
||||||
}
|
}
|
||||||
Some(ClipboardEvent::Grab {
|
Some(ClipboardEvent::Grab {
|
||||||
selection,
|
selection,
|
||||||
@ -228,12 +228,16 @@ async fn rdp_clipboard_receive_task(mut rx: Receiver<ClipboardEvent>, cb: Clipbo
|
|||||||
|
|
||||||
let mimes: Vec<&str> = mimes.iter().map(AsRef::as_ref).collect();
|
let mimes: Vec<&str> = mimes.iter().map(AsRef::as_ref).collect();
|
||||||
|
|
||||||
clipboard.proxy.grab(selection, serial, &mimes).await
|
clipboard
|
||||||
|
.proxy
|
||||||
|
.grab(selection, serial, &mimes)
|
||||||
|
.await
|
||||||
|
.map_err(Into::into)
|
||||||
}
|
}
|
||||||
Some(ClipboardEvent::Release { selection }) => {
|
Some(ClipboardEvent::Release { selection }) => {
|
||||||
debug!("Release -> dbus");
|
debug!("Release -> dbus");
|
||||||
|
|
||||||
clipboard.proxy.release(selection).await
|
clipboard.proxy.release(selection).await.map_err(Into::into)
|
||||||
}
|
}
|
||||||
Some(ClipboardEvent::Request { selection, request }) => {
|
Some(ClipboardEvent::Request { selection, request }) => {
|
||||||
debug!(?request, "Request -> dbus");
|
debug!(?request, "Request -> dbus");
|
||||||
@ -278,7 +282,7 @@ async fn rdp_clipboard_receive_task(mut rx: Receiver<ClipboardEvent>, cb: Clipbo
|
|||||||
};
|
};
|
||||||
|
|
||||||
if let Err(e) = res {
|
if let Err(e) = res {
|
||||||
error!(?e, "input handling error");
|
error!(?e, "clipboard task handling error");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user