X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=gtk%2Fgtktoggletoolbutton.c;h=0ed568cbe182d3f5213c5fbd43e1b2d01fa990f9;hb=e1edc998a2e9c557030d207533932b3120e13fe5;hp=bf6a071a28e9070d07e03f31b286d0096656e45a;hpb=3eb197b51fbcfab20abc618c7081bb400844996e;p=~andy%2Fgtk diff --git a/gtk/gtktoggletoolbutton.c b/gtk/gtktoggletoolbutton.c index bf6a071a2..0ed568cbe 100644 --- a/gtk/gtktoggletoolbutton.c +++ b/gtk/gtktoggletoolbutton.c @@ -14,9 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. + * License along with this library. If not, see . */ #include "config.h" @@ -32,6 +30,21 @@ #include "gtkprivate.h" +/** + * SECTION:gtktoggletoolbutton + * @Short_description: A GtkToolItem containing a toggle button + * @Title: GtkToggleToolButton + * @See_also: #GtkToolbar, #GtkToolButton, #GtkSeparatorToolItem + * + * A #GtkToggleToolButton is a #GtkToolItem that contains a toggle + * button. + * + * Use gtk_toggle_tool_button_new() to create a new + * #GtkToggleToolButton. Use gtk_toggle_tool_button_new_from_stock() to + * create a new #GtkToggleToolButton containing a stock item. + */ + + #define MENU_ID "gtk-toggle-tool-button-menu-id" enum { @@ -291,7 +304,9 @@ static void button_toggled (GtkWidget *widget, GtkToggleToolButton *toggle_tool_button) { - gboolean toggle_active = GTK_TOGGLE_BUTTON (widget)->active; + gboolean toggle_active; + + toggle_active = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget)); if (toggle_tool_button->priv->active != toggle_active) {