aboutsummaryrefslogtreecommitdiff
path: root/ui/spice-display.c
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2021-01-25 15:10:36 +0400
committerMarc-André Lureau <marcandre.lureau@redhat.com>2021-12-21 10:50:21 +0400
commitac32b2fff127843355b4f7e7ac9f93dd4a395adf (patch)
tree796c3741bb0b7b985c7882a896340088d38f966c /ui/spice-display.c
parent4f4181499170dcf80182745b319607802ea32896 (diff)
ui: associate GL context outside of display listener registration
Consoles can have an associated GL context, without listeners (they may be added or removed later on). Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Acked-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'ui/spice-display.c')
-rw-r--r--ui/spice-display.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/ui/spice-display.c b/ui/spice-display.c
index 52d9f3260a..2c204bceee 100644
--- a/ui/spice-display.c
+++ b/ui/spice-display.c
@@ -1156,6 +1156,9 @@ static void qemu_spice_display_init_one(QemuConsole *con)
qemu_spice_create_host_memslot(ssd);
+ if (spice_opengl) {
+ qemu_console_set_display_gl_ctx(con, &ssd->dcl);
+ }
register_displaychangelistener(&ssd->dcl);
}