qemu-display: add Interfaces to ConsoleListener

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
This commit is contained in:
Marc-André Lureau 2023-05-11 23:27:14 +04:00
parent 5ab24ab8a8
commit e642e14d5a

View File

@ -151,6 +151,8 @@ pub trait ConsoleListenerHandler: 'static + Send + Sync {
async fn cursor_define(&mut self, cursor: Cursor);
fn disconnected(&mut self);
fn interfaces(&self) -> Vec<String>;
}
#[derive(Debug)]
@ -289,6 +291,11 @@ impl<H: ConsoleListenerHandler> ConsoleListener<H> {
})
.await;
}
#[dbus_interface(property)]
fn interfaces(&self) -> Vec<String> {
self.handler.interfaces()
}
}
impl<H: ConsoleListenerHandler> ConsoleListener<H> {