[maemo-developers] Missing button_release_event messages?

From: Martin Grimme martin.grimme at gmail.com
Date: Thu Nov 8 13:46:32 EET 2007
Hi,

I have noticed that when you release the button (finger, stylus, etc.), Gtk
emits a
motion-notify event with the same pointer coordinates again. By comparing
these values with
the ones from the previous motion-notify-event, you can detect button
releasing, too.
Gtk on my desktop computer behaves differently, so maybe this is a Hildon or
touchscreen issue.

Cheers,
Martin


2007/11/8, Chris Lord <chris at openedhand.com>:
>
> It could be that the motion hint is set on the widget - this stops
> motion events being reported until the app has had time to handle them
> so you don't get a back-log of events... I might (in fact, probably) be
> remembering incorrectly, but previous hildon gtk had a patch so it was
> set by default I think?
>
> Either way, something to check out - Have a look at
> gtk_widget_add_events, GdkEventMask and GDK_POINTER_MOTION_HINT_MASK.
> I've not tried python, but I certainly didn't have this problem in C.
>
> --Chris
>
> On Wed, 2007-11-07 at 22:32 -0800, George Nachman wrote:
> > I've written an app in PyMaemo that is very sensitive to getting
> > OnButtonUp events on time and I noticed that if I touch the screen
> > with my finger, move it, and let it up all very quickly that I don't
> > get the button_release_event message. I do get a button_press_event
> > and maybe a motion_notify_event, but GTK never tells me I released the
> > button. If I then tap on the screen I immediately get a
> > button_release_event, motion_notify_event, and button_press_event in
> > very quick succession.
> >
> > My program runs in a full-screen window, so I don't believe something
> > else could be getting my button_release_event--and besides, I do get
> > it when I tap on the screen later on, anyway.
> >
> > Has anyone ever heard of this? Could I just be doing something silly?
> >
> > Thanks,
> > George
> > _______________________________________________
> > maemo-developers mailing list
> > maemo-developers at maemo.org
> > https://lists.maemo.org/mailman/listinfo/maemo-developers
>
> _______________________________________________
> maemo-developers mailing list
> maemo-developers at maemo.org
> https://lists.maemo.org/mailman/listinfo/maemo-developers
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.maemo.org/pipermail/maemo-developers/attachments/20071108/9f27e991/attachment.htm 
More information about the maemo-developers mailing list