qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Jim C. Brown" <jbrown106@phreaker.net>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] no-sdl-grab patch
Date: Thu, 15 Jul 2004 19:23:38 -0400	[thread overview]
Message-ID: <20040715232338.GA6710@jbrown.mylinuxbox.org> (raw)
In-Reply-To: <20040715225908.GA6237@jbrown.mylinuxbox.org>

[-- Attachment #1: Type: text/plain, Size: 422 bytes --]

On Thu, Jul 15, 2004 at 06:59:08PM -0400, Jim C. Brown wrote:
> I'm looking into adding this into the monitor, so you can toggle this in a
> running qemu session.
> 

Simplier than I thought. Attached is the patch to toggle it in the monitor.
Just type "sdl_grab_toggle" or "sdl" for short. Apply on top of my previous
patch.

-- 
Infinite complexity begets infinite beauty.
Infinite precision begets infinite perfection.

[-- Attachment #2: qemu.diff --]
[-- Type: text/plain, Size: 739 bytes --]

--- fresh.qemu/monitor.c	Thu Jul 15 13:17:52 2004
+++ qemu/monitor.c	Thu Jul 15 19:11:17 2004
@@ -681,6 +681,12 @@
     qemu_system_reset_request();
 }
 
+static void do_sdl_grab_toggle(void)
+{
+	grab_with_sdl = !grab_with_sdl;
+	term_printf("Grab with SDL is now set to: %s\n", grab_with_sdl ? "On" : "Off");
+}
+
 static term_cmd_t term_cmds[] = {
     { "help|?", "s?", do_help, 
       "[cmd]", "show the help" },
@@ -723,6 +729,8 @@
       "keys", "send keys to the VM (e.g. 'sendkey ctrl-alt-f1')" },
     { "system_reset", "", do_system_reset, 
       "", "reset the system" },
+    { "sdl|sdl_grab_toggle", "", do_sdl_grab_toggle,
+      "", "toggles SDL mouse grabbing vs mouse pointer following" },
     { NULL, NULL, }, 
 };
 

      reply	other threads:[~2004-07-15 23:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-15 22:59 [Qemu-devel] no-sdl-grab patch Jim C. Brown
2004-07-15 23:23 ` Jim C. Brown [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040715232338.GA6710@jbrown.mylinuxbox.org \
    --to=jbrown106@phreaker.net \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).