Commit Graph

2 Commits

Author SHA1 Message Date
Ryan Lortie
81e76746ff GtkActionHelper: two small fixups in _set_target_value()
First, ensure we always consume floating values, as documented.

Second (and more serious), don't try to query the action if the
action name is not set yet.  This will cause crashes...
2012-08-22 00:54:57 -04:00
Ryan Lortie
652f16dd98 introduce private GtkActionHelper
The current process of implementing GActionObserver is annoying and the
GSimpleActionObserver interface leaves a lot to be desired.  Introduce a
new class, GtkActionHelper that gives you pretty much everything you'd
want to do as an implementor of GtkActionable.

The GtkActionHelper also features an "application" mode that is not
associated with a particular GtkWidget but rather with whatever widget
happens to be the active window of the given GtkApplication at a
particular point in time.  This will be useful for the Mac OS menubar.
2012-08-20 13:11:01 -04:00