Commit 88fba9f8 authored by Tim Janik's avatar Tim Janik Committed by Tim Janik
Browse files

totaly binary incomnpatible change:


Mon Jul  6 18:30:48 1998  Tim Janik  <timj@gtk.org>

        * gtk/gtkbutton.h:
        * gtk/gtkbutton.c: GtkButtons are now derived from GtkBin. we mirror
        GTK_BIN (button)->child to button->child to keep source compatibility.

        * gtk/gtkoptionmenu.c:
        * gtk/gtkclist.c:
        * gtkcheckbutton.c: don't refer to button->child, but
        GTK_BIN (button)->child instead.
parent da093071
Mon Jul 6 18:30:48 1998 Tim Janik <timj@gtk.org>
* gtk/gtkbutton.h:
* gtk/gtkbutton.c: GtkButtons are now derived from GtkBin. we mirror
GTK_BIN (button)->child to button->child to keep source compatibility.
* gtk/gtkoptionmenu.c:
* gtk/gtkclist.c:
* gtkcheckbutton.c: don't refer to button->child, but
GTK_BIN (button)->child instead.
Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org> Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org>
* docs/gtkfaq.sgml: update anon CVS info * docs/gtkfaq.sgml: update anon CVS info
......
Mon Jul 6 18:30:48 1998 Tim Janik <timj@gtk.org>
* gtk/gtkbutton.h:
* gtk/gtkbutton.c: GtkButtons are now derived from GtkBin. we mirror
GTK_BIN (button)->child to button->child to keep source compatibility.
* gtk/gtkoptionmenu.c:
* gtk/gtkclist.c:
* gtkcheckbutton.c: don't refer to button->child, but
GTK_BIN (button)->child instead.
Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org> Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org>
* docs/gtkfaq.sgml: update anon CVS info * docs/gtkfaq.sgml: update anon CVS info
......
Mon Jul 6 18:30:48 1998 Tim Janik <timj@gtk.org>
* gtk/gtkbutton.h:
* gtk/gtkbutton.c: GtkButtons are now derived from GtkBin. we mirror
GTK_BIN (button)->child to button->child to keep source compatibility.
* gtk/gtkoptionmenu.c:
* gtk/gtkclist.c:
* gtkcheckbutton.c: don't refer to button->child, but
GTK_BIN (button)->child instead.
Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org> Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org>
* docs/gtkfaq.sgml: update anon CVS info * docs/gtkfaq.sgml: update anon CVS info
......
Mon Jul 6 18:30:48 1998 Tim Janik <timj@gtk.org>
* gtk/gtkbutton.h:
* gtk/gtkbutton.c: GtkButtons are now derived from GtkBin. we mirror
GTK_BIN (button)->child to button->child to keep source compatibility.
* gtk/gtkoptionmenu.c:
* gtk/gtkclist.c:
* gtkcheckbutton.c: don't refer to button->child, but
GTK_BIN (button)->child instead.
Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org> Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org>
* docs/gtkfaq.sgml: update anon CVS info * docs/gtkfaq.sgml: update anon CVS info
......
Mon Jul 6 18:30:48 1998 Tim Janik <timj@gtk.org>
* gtk/gtkbutton.h:
* gtk/gtkbutton.c: GtkButtons are now derived from GtkBin. we mirror
GTK_BIN (button)->child to button->child to keep source compatibility.
* gtk/gtkoptionmenu.c:
* gtk/gtkclist.c:
* gtkcheckbutton.c: don't refer to button->child, but
GTK_BIN (button)->child instead.
Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org> Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org>
* docs/gtkfaq.sgml: update anon CVS info * docs/gtkfaq.sgml: update anon CVS info
......
Mon Jul 6 18:30:48 1998 Tim Janik <timj@gtk.org>
* gtk/gtkbutton.h:
* gtk/gtkbutton.c: GtkButtons are now derived from GtkBin. we mirror
GTK_BIN (button)->child to button->child to keep source compatibility.
* gtk/gtkoptionmenu.c:
* gtk/gtkclist.c:
* gtkcheckbutton.c: don't refer to button->child, but
GTK_BIN (button)->child instead.
Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org> Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org>
* docs/gtkfaq.sgml: update anon CVS info * docs/gtkfaq.sgml: update anon CVS info
......
Mon Jul 6 18:30:48 1998 Tim Janik <timj@gtk.org>
* gtk/gtkbutton.h:
* gtk/gtkbutton.c: GtkButtons are now derived from GtkBin. we mirror
GTK_BIN (button)->child to button->child to keep source compatibility.
* gtk/gtkoptionmenu.c:
* gtk/gtkclist.c:
* gtkcheckbutton.c: don't refer to button->child, but
GTK_BIN (button)->child instead.
Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org> Mon Jul 6 12:06:23 BST 1998 Tony Gale <gale@gtk.org>
* docs/gtkfaq.sgml: update anon CVS info * docs/gtkfaq.sgml: update anon CVS info
......
...@@ -206,9 +206,6 @@ Additions: ...@@ -206,9 +206,6 @@ Additions:
cause confusing presses to be sent to containers that actually cause confusing presses to be sent to containers that actually
want to get events on themselves. want to get events on themselves.
* Buttons's should derive from Bin's. (GTK 2.0 change, breaks
lots of stuff)
* New signals to handle accelerators: accel_before and accel_after (or * New signals to handle accelerators: accel_before and accel_after (or
somesuch) to pre and post process accelerator calls. [Yosh] somesuch) to pre and post process accelerator calls. [Yosh]
......
...@@ -203,61 +203,61 @@ gtk_bin_expose (GtkWidget *widget, ...@@ -203,61 +203,61 @@ gtk_bin_expose (GtkWidget *widget,
static void static void
gtk_bin_add (GtkContainer *container, gtk_bin_add (GtkContainer *container,
GtkWidget *widget) GtkWidget *child)
{ {
GtkBin *bin; GtkBin *bin;
g_return_if_fail (container != NULL); g_return_if_fail (container != NULL);
g_return_if_fail (GTK_IS_BIN (container)); g_return_if_fail (GTK_IS_BIN (container));
g_return_if_fail (widget != NULL); g_return_if_fail (child != NULL);
g_return_if_fail (GTK_IS_WIDGET (child));
bin = GTK_BIN (container); bin = GTK_BIN (container);
g_return_if_fail (bin->child == NULL); g_return_if_fail (bin->child == NULL);
gtk_widget_set_parent (widget, GTK_WIDGET (container)); gtk_widget_set_parent (child, GTK_WIDGET (bin));
bin->child = child;
if (GTK_WIDGET_VISIBLE (widget->parent))
if (GTK_WIDGET_VISIBLE (child->parent))
{ {
if (GTK_WIDGET_REALIZED (widget->parent) && if (GTK_WIDGET_REALIZED (child->parent) &&
!GTK_WIDGET_REALIZED (widget)) !GTK_WIDGET_REALIZED (child))
gtk_widget_realize (widget); gtk_widget_realize (child);
if (GTK_WIDGET_MAPPED (widget->parent) && if (GTK_WIDGET_MAPPED (child->parent) &&
!GTK_WIDGET_MAPPED (widget)) !GTK_WIDGET_MAPPED (child))
gtk_widget_map (widget); gtk_widget_map (child);
} }
bin->child = widget; if (GTK_WIDGET_VISIBLE (child) && GTK_WIDGET_VISIBLE (container))
gtk_widget_queue_resize (child);
if (GTK_WIDGET_VISIBLE (widget) && GTK_WIDGET_VISIBLE (container))
gtk_widget_queue_resize (widget);
} }
static void static void
gtk_bin_remove (GtkContainer *container, gtk_bin_remove (GtkContainer *container,
GtkWidget *widget) GtkWidget *child)
{ {
GtkBin *bin; GtkBin *bin;
gboolean widget_was_visible;
g_return_if_fail (container != NULL); g_return_if_fail (container != NULL);
g_return_if_fail (GTK_IS_BIN (container)); g_return_if_fail (GTK_IS_BIN (container));
g_return_if_fail (widget != NULL); g_return_if_fail (child != NULL);
g_return_if_fail (GTK_IS_WIDGET (child));
bin = GTK_BIN (container); bin = GTK_BIN (container);
g_return_if_fail (bin->child == child);
if (bin->child == widget) widget_was_visible = GTK_WIDGET_VISIBLE (child);
{
gboolean widget_was_visible = GTK_WIDGET_VISIBLE (widget); gtk_widget_unparent (child);
bin->child = NULL;
gtk_widget_unparent (widget);
bin->child = NULL; /* queue resize regardless of GTK_WIDGET_VISIBLE (container),
* since that's what is needed by toplevels, which derive from GtkBin.
/* queue resize regardless of GTK_WIDGET_VISIBLE (container), */
* since that's what is needed by toplevels, which derive from GtkBin. if (widget_was_visible)
*/ gtk_widget_queue_resize (GTK_WIDGET (container));
if (widget_was_visible)
gtk_widget_queue_resize (GTK_WIDGET (container));
}
} }
static void static void
......
...@@ -52,8 +52,6 @@ static void gtk_button_set_arg (GtkObject *object, ...@@ -52,8 +52,6 @@ static void gtk_button_set_arg (GtkObject *object,
static void gtk_button_get_arg (GtkObject *object, static void gtk_button_get_arg (GtkObject *object,
GtkArg *arg, GtkArg *arg,
guint arg_id); guint arg_id);
static void gtk_button_map (GtkWidget *widget);
static void gtk_button_unmap (GtkWidget *widget);
static void gtk_button_realize (GtkWidget *widget); static void gtk_button_realize (GtkWidget *widget);
static void gtk_button_size_request (GtkWidget *widget, static void gtk_button_size_request (GtkWidget *widget,
GtkRequisition *requisition); GtkRequisition *requisition);
...@@ -83,9 +81,6 @@ static void gtk_button_add (GtkContainer *container, ...@@ -83,9 +81,6 @@ static void gtk_button_add (GtkContainer *container,
GtkWidget *widget); GtkWidget *widget);
static void gtk_button_remove (GtkContainer *container, static void gtk_button_remove (GtkContainer *container,
GtkWidget *widget); GtkWidget *widget);
static void gtk_button_foreach (GtkContainer *container,
GtkCallback callback,
gpointer callback_data);
static void gtk_real_button_pressed (GtkButton *button); static void gtk_real_button_pressed (GtkButton *button);
static void gtk_real_button_released (GtkButton *button); static void gtk_real_button_released (GtkButton *button);
static void gtk_real_button_enter (GtkButton *button); static void gtk_real_button_enter (GtkButton *button);
...@@ -93,7 +88,7 @@ static void gtk_real_button_leave (GtkButton *button); ...@@ -93,7 +88,7 @@ static void gtk_real_button_leave (GtkButton *button);
static GtkType gtk_button_child_type (GtkContainer *container); static GtkType gtk_button_child_type (GtkContainer *container);
static GtkContainerClass *parent_class; static GtkBinClass *parent_class = NULL;
static guint button_signals[LAST_SIGNAL] = { 0 }; static guint button_signals[LAST_SIGNAL] = { 0 };
...@@ -116,7 +111,7 @@ gtk_button_get_type (void) ...@@ -116,7 +111,7 @@ gtk_button_get_type (void)
(GtkClassInitFunc) NULL, (GtkClassInitFunc) NULL,
}; };
button_type = gtk_type_unique (gtk_container_get_type (), &button_info); button_type = gtk_type_unique (GTK_TYPE_BIN, &button_info);
gtk_type_set_chunk_alloc (button_type, 16); gtk_type_set_chunk_alloc (button_type, 16);
} }
...@@ -134,7 +129,7 @@ gtk_button_class_init (GtkButtonClass *klass) ...@@ -134,7 +129,7 @@ gtk_button_class_init (GtkButtonClass *klass)
widget_class = (GtkWidgetClass*) klass; widget_class = (GtkWidgetClass*) klass;
container_class = (GtkContainerClass*) klass; container_class = (GtkContainerClass*) klass;
parent_class = gtk_type_class (gtk_container_get_type ()); parent_class = gtk_type_class (GTK_TYPE_BIN);
gtk_object_add_arg_type ("GtkButton::label", GTK_TYPE_STRING, GTK_ARG_READWRITE, ARG_LABEL); gtk_object_add_arg_type ("GtkButton::label", GTK_TYPE_STRING, GTK_ARG_READWRITE, ARG_LABEL);
...@@ -180,8 +175,6 @@ gtk_button_class_init (GtkButtonClass *klass) ...@@ -180,8 +175,6 @@ gtk_button_class_init (GtkButtonClass *klass)
object_class->get_arg = gtk_button_get_arg; object_class->get_arg = gtk_button_get_arg;
widget_class->activate_signal = button_signals[CLICKED]; widget_class->activate_signal = button_signals[CLICKED];
widget_class->map = gtk_button_map;
widget_class->unmap = gtk_button_unmap;
widget_class->realize = gtk_button_realize; widget_class->realize = gtk_button_realize;
widget_class->draw = gtk_button_draw; widget_class->draw = gtk_button_draw;
widget_class->draw_focus = gtk_button_draw_focus; widget_class->draw_focus = gtk_button_draw_focus;
...@@ -198,7 +191,6 @@ gtk_button_class_init (GtkButtonClass *klass) ...@@ -198,7 +191,6 @@ gtk_button_class_init (GtkButtonClass *klass)
container_class->add = gtk_button_add; container_class->add = gtk_button_add;
container_class->remove = gtk_button_remove; container_class->remove = gtk_button_remove;
container_class->foreach = gtk_button_foreach;
container_class->child_type = gtk_button_child_type; container_class->child_type = gtk_button_child_type;
klass->pressed = gtk_real_button_pressed; klass->pressed = gtk_real_button_pressed;
...@@ -212,6 +204,7 @@ static void ...@@ -212,6 +204,7 @@ static void
gtk_button_init (GtkButton *button) gtk_button_init (GtkButton *button)
{ {
GTK_WIDGET_SET_FLAGS (button, GTK_CAN_FOCUS); GTK_WIDGET_SET_FLAGS (button, GTK_CAN_FOCUS);
GTK_WIDGET_UNSET_FLAGS (button, GTK_NO_WINDOW);
button->child = NULL; button->child = NULL;
button->in_button = FALSE; button->in_button = FALSE;
...@@ -222,7 +215,7 @@ gtk_button_init (GtkButton *button) ...@@ -222,7 +215,7 @@ gtk_button_init (GtkButton *button)
static GtkType static GtkType
gtk_button_child_type (GtkContainer *container) gtk_button_child_type (GtkContainer *container)
{ {
if (!GTK_BUTTON (container)->child) if (!GTK_BIN (container)->child)
return GTK_TYPE_WIDGET; return GTK_TYPE_WIDGET;
else else
return GTK_TYPE_NONE; return GTK_TYPE_NONE;
...@@ -242,11 +235,8 @@ gtk_button_set_arg (GtkObject *object, ...@@ -242,11 +235,8 @@ gtk_button_set_arg (GtkObject *object,
GtkWidget *label; GtkWidget *label;
case ARG_LABEL: case ARG_LABEL:
if (button->child) if (GTK_BIN (button)->child)
{ gtk_container_remove (GTK_CONTAINER (button), GTK_BIN (button)->child);
gtk_widget_unparent (button->child);
button->child = NULL;
}
label = gtk_label_new (GTK_VALUE_STRING(*arg) ? GTK_VALUE_STRING(*arg) : ""); label = gtk_label_new (GTK_VALUE_STRING(*arg) ? GTK_VALUE_STRING(*arg) : "");
gtk_widget_show (label); gtk_widget_show (label);
...@@ -270,8 +260,8 @@ gtk_button_get_arg (GtkObject *object, ...@@ -270,8 +260,8 @@ gtk_button_get_arg (GtkObject *object,
switch (arg_id) switch (arg_id)
{ {
case ARG_LABEL: case ARG_LABEL:
if (button->child && GTK_IS_LABEL (button->child)) if (GTK_BIN (button)->child && GTK_IS_LABEL (GTK_BIN (button)->child))
GTK_VALUE_STRING (*arg) = g_strdup (GTK_LABEL (button->child)->label); GTK_VALUE_STRING (*arg) = g_strdup (GTK_LABEL (GTK_BIN (button)->child)->label);
else else
GTK_VALUE_STRING (*arg) = NULL; GTK_VALUE_STRING (*arg) = NULL;
break; break;
...@@ -352,35 +342,6 @@ gtk_button_get_relief(GtkButton *button) ...@@ -352,35 +342,6 @@ gtk_button_get_relief(GtkButton *button)
return button->relief; return button->relief;
} }
static void
gtk_button_map (GtkWidget *widget)
{
GtkButton *button;
g_return_if_fail (widget != NULL);
g_return_if_fail (GTK_IS_BUTTON (widget));
GTK_WIDGET_SET_FLAGS (widget, GTK_MAPPED);
gdk_window_show (widget->window);
button = GTK_BUTTON (widget);
if (button->child &&
GTK_WIDGET_VISIBLE (button->child) &&
!GTK_WIDGET_MAPPED (button->child))
gtk_widget_map (button->child);
}
static void
gtk_button_unmap (GtkWidget *widget)
{
g_return_if_fail (widget != NULL);
g_return_if_fail (GTK_IS_BUTTON (widget));
GTK_WIDGET_UNSET_FLAGS (widget, GTK_MAPPED);
gdk_window_hide (widget->window);
}
static void static void
gtk_button_realize (GtkWidget *widget) gtk_button_realize (GtkWidget *widget)
{ {
...@@ -446,12 +407,12 @@ gtk_button_size_request (GtkWidget *widget, ...@@ -446,12 +407,12 @@ gtk_button_size_request (GtkWidget *widget,
DEFAULT_SPACING); DEFAULT_SPACING);
} }
if (button->child && GTK_WIDGET_VISIBLE (button->child)) if (GTK_BIN (button)->child && GTK_WIDGET_VISIBLE (GTK_BIN (button)->child))
{ {
gtk_widget_size_request (button->child, &button->child->requisition); gtk_widget_size_request (GTK_BIN (button)->child, &GTK_BIN (button)->child->requisition);
requisition->width += button->child->requisition.width; requisition->width += GTK_BIN (button)->child->requisition.width;
requisition->height += button->child->requisition.height; requisition->height += GTK_BIN (button)->child->requisition.height;
} }
} }
...@@ -479,7 +440,7 @@ gtk_button_size_allocate (GtkWidget *widget, ...@@ -479,7 +440,7 @@ gtk_button_size_allocate (GtkWidget *widget,
button = GTK_BUTTON (widget); button = GTK_BUTTON (widget);
if (button->child && GTK_WIDGET_VISIBLE (button->child)) if (GTK_BIN (button)->child && GTK_WIDGET_VISIBLE (GTK_BIN (button)->child))
{ {
child_allocation.x = (CHILD_SPACING + GTK_WIDGET (widget)->style->klass->xthickness); child_allocation.x = (CHILD_SPACING + GTK_WIDGET (widget)->style->klass->xthickness);
child_allocation.y = (CHILD_SPACING + GTK_WIDGET (widget)->style->klass->ythickness); child_allocation.y = (CHILD_SPACING + GTK_WIDGET (widget)->style->klass->ythickness);
...@@ -501,7 +462,7 @@ gtk_button_size_allocate (GtkWidget *widget, ...@@ -501,7 +462,7 @@ gtk_button_size_allocate (GtkWidget *widget,
(GTK_WIDGET (widget)->style->klass->xthickness * 2 + DEFAULT_SPACING)); (GTK_WIDGET (widget)->style->klass->xthickness * 2 + DEFAULT_SPACING));
} }
gtk_widget_size_allocate (button->child, &child_allocation); gtk_widget_size_allocate (GTK_BIN (button)->child, &child_allocation);
} }
} }
...@@ -646,8 +607,8 @@ gtk_button_draw (GtkWidget *widget, ...@@ -646,8 +607,8 @@ gtk_button_draw (GtkWidget *widget,
gtk_button_paint (widget, &tmp_area); gtk_button_paint (widget, &tmp_area);
if (button->child && gtk_widget_intersect (button->child, &tmp_area, &child_area)) if (GTK_BIN (button)->child && gtk_widget_intersect (GTK_BIN (button)->child, &tmp_area, &child_area))
gtk_widget_draw (button->child, &child_area); gtk_widget_draw (GTK_BIN (button)->child, &child_area);
gtk_widget_draw_default (widget); gtk_widget_draw_default (widget);
gtk_widget_draw_focus (widget); gtk_widget_draw_focus (widget);
...@@ -785,9 +746,9 @@ gtk_button_expose (GtkWidget *widget, ...@@ -785,9 +746,9 @@ gtk_button_expose (GtkWidget *widget,
gtk_button_paint (widget, &event->area); gtk_button_paint (widget, &event->area);
child_event = *event; child_event = *event;
if (button->child && GTK_WIDGET_NO_WINDOW (button->child) && if (GTK_BIN (button)->child && GTK_WIDGET_NO_WINDOW (GTK_BIN (button)->child) &&
gtk_widget_intersect (button->child, &event->area, &child_event.area)) gtk_widget_intersect (GTK_BIN (button)->child, &event->area, &child_event.area))
gtk_widget_event (button->child, (GdkEvent*) &child_event); gtk_widget_event (GTK_BIN (button)->child, (GdkEvent*) &child_event);
gtk_widget_draw_default (widget); gtk_widget_draw_default (widget);
gtk_widget_draw_focus (widget); gtk_widget_draw_focus (widget);
...@@ -925,78 +886,26 @@ static void ...@@ -925,78 +886,26 @@ static void
gtk_button_add (GtkContainer *container, gtk_button_add (GtkContainer *container,
GtkWidget *widget) GtkWidget *widget)
{ {
GtkButton *button;
g_return_if_fail (container != NULL); g_return_if_fail (container != NULL);
g_return_if_fail (GTK_IS_BUTTON (container));
g_return_if_fail (widget != NULL); g_return_if_fail (widget != NULL);
g_return_if_fail (gtk_widget_basic (widget));
button = GTK_BUTTON (container);
if (!button->child) if (GTK_CONTAINER_CLASS (parent_class)->add)
{ GTK_CONTAINER_CLASS (parent_class)->add (container, widget);
gtk_widget_set_parent (widget, GTK_WIDGET (container));
if (GTK_WIDGET_VISIBLE (widget->parent))
{
if (GTK_WIDGET_REALIZED (widget->parent) &&
!GTK_WIDGET_REALIZED (widget))
gtk_widget_realize (widget);
if (GTK_WIDGET_MAPPED (widget->parent) &&
!GTK_WIDGET_MAPPED (widget))
gtk_widget_map (widget);
}
button->child = widget;
if (GTK_WIDGET_VISIBLE (widget) && GTK_WIDGET_VISIBLE (container)) GTK_BUTTON (container)->child = GTK_BIN (container)->child;
gtk_widget_queue_resize (widget);
}
} }
static void static void
gtk_button_remove (GtkContainer *container, gtk_button_remove (GtkContainer *container,
GtkWidget *widget) GtkWidget *widget)
{ {
GtkButton *button;
g_return_if_fail (container != NULL); g_return_if_fail (container != NULL);
g_return_if_fail (GTK_IS_BUTTON (container));
g_return_if_fail (widget != NULL); g_return_if_fail (widget != NULL);
button = GTK_BUTTON (container); if (GTK_CONTAINER_CLASS (parent_class)->remove)
GTK_CONTAINER_CLASS (parent_class)->remove (container, widget);
if (button->child == widget)
{
gboolean widget_was_visible = GTK_WIDGET_VISIBLE(widget);
gtk_widget_unparent (widget);
button->child = NULL;
if (widget_was_visible && GTK_WIDGET_VISIBLE (container))
gtk_widget_queue_resize (GTK_WIDGET (container));
}
}
static void
gtk_button_foreach (GtkContainer *container,
GtkCallback callback,
gpointer callback_data)
{
GtkButton *button;
g_return_if_fail (container != NULL);
g_return_if_fail (GTK_IS_BUTTON (container));
g_return_if_fail (callback != NULL);
button = GTK_BUTTON (container);
if (button->child) GTK_BUTTON (container)->child = GTK_BIN (container)->child;
(* callback) (button->child, callback_data);
} }
static void static void
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@