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

Popular posts from this blog

c++ - Function signature as a function template parameter -

algorithm - What are some ways to combine a number of (potentially incompatible) sorted sub-sets of a total set into a (partial) ordering of the total set? -

How to call a javascript function after the page loads with a chrome extension? -