mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 17:23:56 -06:00
ui/console: message surface tweaks.
ui/cocoa: bugfixes and cleanups. -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEoDKM/7k6F6eZAf59TLbY7tPocTgFAmBAnCUACgkQTLbY7tPo cTj0dA//ZLetPdIEfGHmNMsGGw1/atXXWtyX3/W2WlNLgGda3lhRqcL0Zyqx0LV6 b4uzPB65ySY/BkSuRlMorZ+GRyTiNWOc+6nieMFdFOPCC7XmNvbVSf+oDspLeuDy zfxqasEI6PUyLiA+HVjyD+VeI3QbQSGJ9WmkeZTR9Rwivh8koawXcndAjsGSED92 W0piI+iXuWxbT+mny3IbZXGNLqQI0bdDUeJFnBxZeYD4TY9R937ZsV6FNmLgUlPD gPTZP0YsrKqhYPaOYYy2U1YYreR6Qxbdmdg7jyroX/n4n4CIUx3f8eDc7aCKhkkC kIPwukP748KznkJWHTqSM6fhtJPj27LE0vX0vH0bMM5FolMhKWEMRCV0UhT8Y6z+ UqB3cRqB+r0vBMOaP+DyWyb8W4zWulPtdZr11KWv6x3Jv8+G5yC3ZUfuzpOUxHjT Q/l6tZmwnS/1ZXCuAyB/sZzzfiDlf7tv31QF2KrDeuvTdEb9oHqivkaxhJzbsUXD WkvoN858b+1jRCLCra2vjhNbKvEujlP2dlCpjOPUQFZ9pYx57WxcS7dNHZv2+nem +6m4RVeihZf8SZpaJQz2Xl3ZBecX8C2MMrsq3O+7TjWY4T45IltjXq31rMEBv3NQ F47AxY+P5RHzKb3Rq61HqXw+jvxNlslG0tPk/mz9pCgPE3efpQM= =TxNe -----END PGP SIGNATURE----- Merge remote-tracking branch 'remotes/kraxel/tags/ui-20210304-pull-request' into staging ui/console: message surface tweaks. ui/cocoa: bugfixes and cleanups. # gpg: Signature made Thu 04 Mar 2021 08:36:53 GMT # gpg: using RSA key A0328CFFB93A17A79901FE7D4CB6D8EED3E87138 # gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" [full] # gpg: aka "Gerd Hoffmann <gerd@kraxel.org>" [full] # gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>" [full] # Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138 * remotes/kraxel/tags/ui-20210304-pull-request: virtio-gpu: Do not distinguish the primary console ui/console: Pass placeholder surface to displays ui/console: Add placeholder flag to message surface ui/cocoa: Replace fprintf with error_report configure: Improve OpenGL dependency detections ui/cocoa: Fix stride resolution of pixman image ui/gtk: vte: fix sending multiple characeters ui/cocoa: Remove the uses of full screen APIs Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
commit
fe352f5c00
21 changed files with 131 additions and 123 deletions
|
@ -193,10 +193,8 @@ vhost_user_gpu_handle_display(VhostUserGPU *g, VhostUserGpuMsg *msg)
|
|||
s = &g->parent_obj.scanout[m->scanout_id];
|
||||
con = s->con;
|
||||
|
||||
if (m->scanout_id == 0 && m->width == 0) {
|
||||
s->ds = qemu_create_message_surface(640, 480,
|
||||
"Guest disabled display.");
|
||||
dpy_gfx_replace_surface(con, s->ds);
|
||||
if (m->width == 0) {
|
||||
dpy_gfx_replace_surface(con, NULL);
|
||||
} else {
|
||||
s->ds = qemu_create_displaysurface(m->width, m->height);
|
||||
/* replace surface on next update */
|
||||
|
|
|
@ -179,10 +179,8 @@ static void virgl_cmd_set_scanout(VirtIOGPU *g,
|
|||
info.width, info.height,
|
||||
ss.r.x, ss.r.y, ss.r.width, ss.r.height);
|
||||
} else {
|
||||
if (ss.scanout_id != 0) {
|
||||
dpy_gfx_replace_surface(
|
||||
g->parent_obj.scanout[ss.scanout_id].con, NULL);
|
||||
}
|
||||
dpy_gfx_replace_surface(
|
||||
g->parent_obj.scanout[ss.scanout_id].con, NULL);
|
||||
dpy_gl_scanout_disable(g->parent_obj.scanout[ss.scanout_id].con);
|
||||
}
|
||||
g->parent_obj.scanout[ss.scanout_id].resource_id = ss.resource_id;
|
||||
|
@ -595,9 +593,7 @@ void virtio_gpu_virgl_reset(VirtIOGPU *g)
|
|||
|
||||
virgl_renderer_reset();
|
||||
for (i = 0; i < g->parent_obj.conf.max_outputs; i++) {
|
||||
if (i != 0) {
|
||||
dpy_gfx_replace_surface(g->parent_obj.scanout[i].con, NULL);
|
||||
}
|
||||
dpy_gfx_replace_surface(g->parent_obj.scanout[i].con, NULL);
|
||||
dpy_gl_scanout_disable(g->parent_obj.scanout[i].con);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -193,9 +193,6 @@ virtio_gpu_base_device_realize(DeviceState *qdev,
|
|||
for (i = 0; i < g->conf.max_outputs; i++) {
|
||||
g->scanout[i].con =
|
||||
graphic_console_init(DEVICE(g), i, &virtio_gpu_ops, g);
|
||||
if (i > 0) {
|
||||
dpy_gfx_replace_surface(g->scanout[i].con, NULL);
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
|
|
|
@ -325,7 +325,6 @@ static void virtio_gpu_disable_scanout(VirtIOGPU *g, int scanout_id)
|
|||
{
|
||||
struct virtio_gpu_scanout *scanout = &g->parent_obj.scanout[scanout_id];
|
||||
struct virtio_gpu_simple_resource *res;
|
||||
DisplaySurface *ds = NULL;
|
||||
|
||||
if (scanout->resource_id == 0) {
|
||||
return;
|
||||
|
@ -336,13 +335,7 @@ static void virtio_gpu_disable_scanout(VirtIOGPU *g, int scanout_id)
|
|||
res->scanout_bitmask &= ~(1 << scanout_id);
|
||||
}
|
||||
|
||||
if (scanout_id == 0) {
|
||||
/* primary head */
|
||||
ds = qemu_create_message_surface(scanout->width ?: 640,
|
||||
scanout->height ?: 480,
|
||||
"Guest disabled display.");
|
||||
}
|
||||
dpy_gfx_replace_surface(scanout->con, ds);
|
||||
dpy_gfx_replace_surface(scanout->con, NULL);
|
||||
scanout->resource_id = 0;
|
||||
scanout->ds = NULL;
|
||||
scanout->width = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue