mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-05 00:33:55 -06:00
console: rework DisplaySurface handling [dcl/ui side]
Replace the dpy_gfx_resize and dpy_gfx_setdata DisplayChangeListener callbacks with a dpy_gfx_switch callback which notifies the ui code when the framebuffer backing storage changes. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
da229ef3b3
commit
c12aeb860c
9 changed files with 43 additions and 55 deletions
13
ui/cocoa.m
13
ui/cocoa.m
|
@ -988,8 +988,9 @@ static void cocoa_update(DisplayChangeListener *dcl,
|
|||
[cocoaView setNeedsDisplayInRect:rect];
|
||||
}
|
||||
|
||||
static void cocoa_resize(DisplayChangeListener *dcl,
|
||||
DisplayState *ds)
|
||||
static void cocoa_switch(DisplayChangeListener *dcl,
|
||||
DisplayState *ds,
|
||||
DisplaySurface *surface)
|
||||
{
|
||||
COCOA_DEBUG("qemu_cocoa: cocoa_resize\n");
|
||||
|
||||
|
@ -1023,11 +1024,6 @@ static void cocoa_refresh(DisplayChangeListener *dcl,
|
|||
vga_hw_update();
|
||||
}
|
||||
|
||||
static void cocoa_setdata(DisplayState *ds)
|
||||
{
|
||||
[cocoaView updateDataOffset:ds];
|
||||
}
|
||||
|
||||
static void cocoa_cleanup(void)
|
||||
{
|
||||
COCOA_DEBUG("qemu_cocoa: cocoa_cleanup\n");
|
||||
|
@ -1037,8 +1033,7 @@ static void cocoa_cleanup(void)
|
|||
static const DisplayChangeListenerOps dcl_ops = {
|
||||
.dpy_name = "cocoa",
|
||||
.dpy_gfx_update = cocoa_update;
|
||||
.dpy_gfx_resize = cocoa_resize;
|
||||
.dpy_gfx_setdata = cocoa_setdata;
|
||||
.dpy_gfx_switch = cocoa_switch;
|
||||
.dpy_refresh = cocoa_refresh;
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue