On Mon, May 2, 2016 at 8:17 PM Mario Wenzel <maw...@gmail.com> wrote:

> So my questions are:
>
* How do I find out from the button-release-event, whether the icon was
> double-clicked?
>

 There is no builtin support for double-clicks, so you'll have to implement
it yourself:
You need to record the time and location of the last release event, and
then check whether the next event is close enough to be considered a
double-click. Use either
ClutterSettings:double-click-time/ClutterSettings:double-click-distance or
GtkSettings:gtk-double-click-time/GtkSettings:double-click-distance for the
thresholds to be consistent with other components.



> * Is there a way to check library versions from within lg/gjs?
>

 Not generically. If a library defines a version symbol like
CLUTTER_VERSION, it will be available to introspection (Clutter.VERSION)
though.


> * Why is get_event_type not available? Or am I looking at the wrong
> get_button()? Where is the correct one documented?
>

gnome-shell is based on Clutter rather than Gdk/Gtk+, so you are indeed
looking at the wrong get_button() - you want ClutterEvent instead of
GdkEvent. Both APIs are very similar, but the method to get the event type
is called event_type() in Clutter.
_______________________________________________
gnome-shell-list mailing list
gnome-shell-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gnome-shell-list

Reply via email to