qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Kyle Hubert" <khubert@gmail.com>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] QEMU 0.9.0 patch
Date: Mon, 26 Mar 2007 14:02:21 -0700	[thread overview]
Message-ID: <9a158e2e0703261402k44392f0btadfa63badbf47a88@mail.gmail.com> (raw)

I don't have the current source repository, I'm running off of the
0.9.0 source release. However, I felt that there was a bug with having
the VM in fullscreen mode and still allowing the ctrl-alt modifiers to
release the mouse. With SDL, this is rather useless and only requires
the user to grab the mouse again. I'm not positive, but I believe
there may be a bug if you switch the grab mode in fullscreen and exit
fullscreen, then you don't fall back into your previous state.

Everything appears to work with the following patch. Is it possible to
get this submitted?

-Kyle

--- sdl.c.orig      2007-02-05 15:01:54.000000000 -0800
+++ sdl.c       2007-03-26 13:51:24.000000000 -0700
@@ -393,18 +393,20 @@ static void sdl_refresh(DisplayState *ds
                         gui_key_modifier_pressed = 0;
                         if (gui_keysym == 0) {
                             /* exit/enter grab if pressing Ctrl-Alt */
-                            if (!gui_grab) {
-                                /* if the application is not active,
-                                   do not try to enter grab state. It
-                                   prevents
-                                   'SDL_WM_GrabInput(SDL_GRAB_ON)'
-                                   from blocking all the application
-                                   (SDL bug). */
-                                if (SDL_GetAppState() & SDL_APPACTIVE)
-                                    sdl_grab_start();
-                            } else {
-                                sdl_grab_end();
-                            }
+                           if (!gui_fullscreen) {
+                               if (!gui_grab) {
+                                   /* if the application is not active,
+                                      do not try to enter grab state. It
+                                      prevents
+                                      'SDL_WM_GrabInput(SDL_GRAB_ON)'
+                                      from blocking all the application
+                                      (SDL bug). */
+                                   if (SDL_GetAppState() & SDL_APPACTIVE)
+                                       sdl_grab_start();
+                               } else {
+                                   sdl_grab_end();
+                               }
+                           }
                             /* SDL does not send back all the
                                modifiers key, so we must correct it */
                             reset_keys();

                 reply	other threads:[~2007-03-26 21:04 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=9a158e2e0703261402k44392f0btadfa63badbf47a88@mail.gmail.com \
    --to=khubert@gmail.com \
    --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).