Xlib and mouse events
Benjamin BOUCHER
boucher.bn at gmail.com
Wed Aug 20 05:21:22 PDT 2008
I tried xev and, correct me if I'm wrong, it can't get mouse clicks on other
windows that the one it created itself.
I just made some tests and it can't even get mouse motions events on it, (it
detects only mouse motions events on borders and titlebar) probably because
my app is a JAVA one (using libVLC through JNA which il a lib that allows to
run native code in JAVA).
Btw, xed behavior seems normal to me because, as we can read in the Xlib doc
:
"Only one client at a time can select a
*ButtonPress<http://tronche.com/gui/x/xlib/events/keyboard-pointer/keyboard-pointer.html>
* event, which is associated with the event mask
*ButtonPressMask<http://tronche.com/gui/x/xlib/events/processing-overview.html#ButtonPressMask>
*."
Since libVLC get these events, what I want to do seems impossible... :(
On Wed, Aug 20, 2008 at 1:10 PM, Samuel Thibault <
samuel.thibault at ens-lyon.org> wrote:
> Benjamin BOUCHER, le Wed 20 Aug 2008 13:02:22 +0200, a écrit :
> > I want to make a C program which capture all mouse events, not only those
> from
> > a window I created myself, is it possible ?
>
> You'll probably be happy reading the source code of xev.
>
> Samuel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.x.org/archives/xorg/attachments/20080820/2f2ee006/attachment.html>
More information about the xorg
mailing list