[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 4/8] sdl2: add UI to toggle head 1 on/off
From: |
Dave Airlie |
Subject: |
[Qemu-devel] [PATCH 4/8] sdl2: add UI to toggle head 1 on/off |
Date: |
Tue, 10 Dec 2013 14:05:54 +1000 |
From: Dave Airlie <address@hidden>
This just adds ctrl-alt-n to toggle head 1 on/off for testing and demo purposes.
Signed-off-by: Dave Airlie <address@hidden>
---
ui/sdl2.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/ui/sdl2.c b/ui/sdl2.c
index dd8cd2b..c52dcd9 100644
--- a/ui/sdl2.c
+++ b/ui/sdl2.c
@@ -522,6 +522,13 @@ static void handle_keydown(SDL_Event *ev)
if (gui_key_modifier_pressed) {
keycode = sdl_keyevent_to_keycode(&ev->key);
switch (keycode) {
+ case 0x31:
+ /* spawn a new connected monitor if we have one */
+ if (sdl2_console[1].surface)
+ graphic_hw_notify_state(sdl2_console[1].dcl.con, 0, 0, 0, 0);
+ else
+ graphic_hw_notify_state(sdl2_console[1].dcl.con, 0, 0, 1024,
768);
+ break;
case 0x21: /* 'f' key on US keyboard */
toggle_full_screen(scon);
gui_keysym = 1;
--
1.8.3.1
- [Qemu-devel] [RFC] sdl2 + virtio-gpu repost, Dave Airlie, 2013/12/09
- [Qemu-devel] [PATCH 1/8] ui/sdl2 : initial port to SDL 2.0 (v2.0), Dave Airlie, 2013/12/09
- [Qemu-devel] [PATCH 2/8] console: add state notifiers for ui<->display, Dave Airlie, 2013/12/09
- [Qemu-devel] [PATCH 3/8] sdl2: add display notify change support, Dave Airlie, 2013/12/09
- [Qemu-devel] [PATCH 4/8] sdl2: add UI to toggle head 1 on/off,
Dave Airlie <=
- [Qemu-devel] [PATCH 5/8] console: add ability to wrap a console., Dave Airlie, 2013/12/09
- [Qemu-devel] [PATCH 6/8] virtio-gpu: v0.2 of the virtio based GPU code., Dave Airlie, 2013/12/09
- [Qemu-devel] [PATCH 7/8] virtio-vga: v1, Dave Airlie, 2013/12/09
- [Qemu-devel] [PATCH 8/8] HACK: just to make things start easier with libvirt, Dave Airlie, 2013/12/09
- Re: [Qemu-devel] [RFC] sdl2 + virtio-gpu repost, Dave Airlie, 2013/12/09
- Re: [Qemu-devel] [RFC] sdl2 + virtio-gpu repost, Stefan Weil, 2013/12/10