pygtk - With GTK+ 3, how can I make a GtkScale trigger "value-changed" on mouse release? -
i have gtkscale
, i'd fire value-changed
events when mouse button release, i.e. not while you're dragging scale around.
in gtk+ 2, there function called gtk_range_set_update_policy
called with:
gtk_range_set_update_policy(scale, gtk_update_discontinuous)
but function has been removed. idea on how gtk+ 3?
(the project i'm working on in python pygobject, answers in c or (most) other languages ok.)
oh, got now. pretty obvious know do. anonymous pointed in right direction!
on button-press-event
, set flag avoids value-change
code (actually switched use change-value
event instead). on button-release-event
unset it. obvious. :-)
Comments
Post a Comment