2 * gnm-radiobutton.c: Implements a special radiobutton
4 * Copyright (c) 2009 Morten Welinder <terra@gnome.org>
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, see <https://www.gnu.org/licenses/>.
20 #include <gnumeric-config.h>
21 #include <widgets/gnm-radiobutton.h>
22 #include <gsf/gsf-impl-utils.h>
24 typedef GtkRadioButtonClass GnmRadioButtonClass
;
27 gnm_radiobutton_class_init (GnmRadioButtonClass
*class)
29 GtkButtonClass
*button_class
= GTK_BUTTON_CLASS (class);
31 if (gdk_screen_get_default ()) {
32 GtkWidget
*tb
= gtk_toggle_button_new ();
34 button_class
->clicked
= GTK_BUTTON_GET_CLASS(tb
)->clicked
;
36 g_object_ref_sink (tb
);
37 gtk_widget_destroy (tb
);
44 GSF_CLASS (GnmRadioButton
, gnm_radiobutton
,
45 gnm_radiobutton_class_init
, NULL
, GTK_TYPE_RADIO_BUTTON
)