Re: Debugging after mouse pointer grabbed
- From: Karl Koehler <koehler or uni-bonn de>
- To: snickell stanford edu
- Cc: gtk-devel-list mail gnome org
- Subject: Re: Debugging after mouse pointer grabbed
- Date: Wed, 10 Jul 2002 18:16:05 +0200 (MSZ)
> 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
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]