1
0
mirror of https://gitlab.com/marcandre.lureau/qemu-display.git synced 2025-04-14 08:44:46 +00:00

qemu-display: impl AsRef for ScanoutMmap

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
This commit is contained in:
Marc-André Lureau 2025-01-07 10:59:53 +04:00
parent 71048ddeff
commit 5266d8f5d8

View File

@ -88,10 +88,6 @@ impl ScanoutMap {
}
impl ScanoutMmap {
pub fn as_ref(&self) -> &[u8] {
self.mmap.as_ref()
}
pub fn stride(&self) -> u32 {
self.scanout.stride
}
@ -101,6 +97,12 @@ impl ScanoutMmap {
}
}
impl AsRef<[u8]> for ScanoutMmap {
fn as_ref(&self) -> &[u8] {
self.mmap.as_ref()
}
}
#[derive(Debug, Copy, Clone)]
pub struct UpdateMap {
pub x: i32,