qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] user definable hotkeys to send instructions to the host


From: Jim C. Brown
Subject: Re: [Qemu-devel] user definable hotkeys to send instructions to the host OS?
Date: Mon, 7 Nov 2005 01:02:46 -0500
User-agent: Mutt/1.4.2.1i

On Sun, Nov 06, 2005 at 10:17:39PM -0700, Phil Rasch wrote:
> I would like to be able to program a hotkey that would allow me to shift from 
> a fullscreen qemu session to another workspace or X display with access to 
> the host OS. I think I can construct the instructions (to X or gdm/kdm etc) 
> to instruct the window manager to do what I want, but the problem is that 
> qemu seems to grab all the keystrokes and not pass anything to the host OS. 
> All my attempts seem to be intercepted by qemu, and not passed to the OS.
> 

Of course. qemu grabs the keyboard. It wouldn't be accurate emulation otherwise.

> Can anybody suggest a way to do what I want, or is it going to take some 
> hacking on the source? If so, can you suggest the starting point? If people 
> think it would be useful to others I would be happy to try to provide a 
> patch.
> 

My -no-sdl-grab patch essentially did this, since it prevented SDL from grabbing
the mouse (and in the process, I believe keyboard grabs were blocked as well,
if memory serves me correctly).

If you want the mouse to be grabbed, but not the keyboard, then you will need
to edit the SDL source code or run qemu under a different graphics toolkit like
GTK.

If you just want the hotkey, but don't mind anything else being grabbed, you
can get away with hacking sdl.c so that for a particular hotkey combination,
a message is sent (maybe it somehow sends a keystroke to another X process,
maybe it runs a command on the host, maybe it does something else).

> Thanks in advance for your advice.
> 
> Phil

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




reply via email to

[Prev in Thread] Current Thread [Next in Thread]