From: Harald Braumann <harry@unheit.net>
To: kvm@vger.kernel.org
Subject: Don't confine mouse on grab
Date: Fri, 23 Apr 2010 22:17:25 +0200 [thread overview]
Message-ID: <20100423201725.GF25023@sbs288.lan> (raw)
Hi,
I'd like to propose a small change in the grab behaviour of the SDL
window:
Currently, when the mouse is moved over the window, the guest mouse is
moved as well and the guest receives keyboard input (using absolute
mouse here and focus-follow-mouse). However, the keyboard is not
grabbed, and so the guest doesn't receive all key combinations (very
bad, when you try to close a window in the guest and instead the whole
SDL window is closed). You have to click or use a key combination to
grab. Now, when the grab is active, also the pointer is confined
inside the SDL window. You have to again use a key combination to get
out.
The better behaviour, I think would be the following:
Whenever the SDL window gets the focus, it should grab the keyboard
without confining the pointer. Then you could use all the key
combinations in the guest and you could still change the focus by
moving the mouse out and to another window. VMware does it like this,
VirtualBox, I think, as well, and also the rdesktop client.
However, I've checked the SDL documentation and it seems it only
provides SDL_WM_GrabInput which grabs the keyboard *and* confines the
mouse. So maybe SDL would need to be extended for this to work. If
that is in fact the case, a work-around would be, to never do a
grab. My window manager can be configured to deliver (almost) all key
combinations to certain windows, so I could still get the desired
behaviour.
Cheers,
harry
reply other threads:[~2010-04-23 20:24 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=20100423201725.GF25023@sbs288.lan \
--to=harry@unheit.net \
--cc=kvm@vger.kernel.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