Re: Debugging after mouse pointer grabbed
- From: "Shahms E. King" <shahms shahms com>
- To: gtk-devel-list gnome org
- Subject: Re: Debugging after mouse pointer grabbed
- Date: 10 Jul 2002 16:09:38 -0700
I found this poking around the XF86 man pages the other day that might
be useful (not generic across other X servers, but if you just need to
debug a program under XF86 this should work):
Option "AllowDeactivateGrabs" "boolean"
This option enables the use of the
Ctrl+Alt+Keypad-Divide
key sequence to desactivate any active keyboard
and mouse grabs. Default: off.
Option "AllowClosedownGrabs" "boolean"
This option enables the use of the
Ctrl+Alt+Keypad-Multiply key sequence to kill
clients with an active
keyboard or mouse grab as well as killing any application
that may have locked the server, normally using
the XGrabServer(3) Xlib function. Default: off.
Note that the options AllowDeactivateGrabs and AllowClosedownGrabs
will allow users to remove the grab used by screen saver/locker
programs. An API was written to such cases. If you enable this
option, make sure your screen saver/locker is updated.
--Shahms
On Wed, 2002-07-10 at 09:16, Karl Koehler wrote:
> > Sorry, I should have been more clear: the question was not "how do I
> > debug ______ in gdb when the mouse pointer stays grabbed?" (actually,
> > I've had to do this a few times w/ nautilus using multiple machines),
> > the question is "how do I make an IDE that does not force users to do this".
> [ .. ]
> > Is there some way we could have programs normally grab the mouse, but
> > automatically release it when a breakpoint is hit? (say, have a GTK call
> > the debugger can activate that releases any mouse grab).
> The program being debugged maybe won't release the mouse if things are
> not ok. So, the question melts down to: 'How can XUngrabPointer() be
> called on the programs behalf ?'.
> First, the IDE could test if the pointer is grabbed by calling
> XGrabPointer() itself. If the value is not GrabSuccess,
> the IDE could:
> a) Find out the windows of the program being debugged, and unmap them,
> thus releasing the grab
> b) temporarily map a big, override-redirect window over the client.
> c) ( unsafe ) make the debugger call XUngrabPointer() or the gtk
> equivalent.
> Note it cannot make the call itself, because it does not hold the grab.
>
> Karl
>
>
> _______________________________________________
> gtk-devel-list mailing list
> gtk-devel-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtk-devel-list
>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]