#include <stdio.h>
#include <gtk/gtk.h>
-void destroy( GtkWidget *widget,
- gpointer data )
+static void destroy( GtkWidget *widget,
+ gpointer data )
{
gtk_main_quit ();
}
button = gtk_button_new_with_label ("close");
g_signal_connect_swapped (G_OBJECT (button), "clicked",
G_CALLBACK (gtk_widget_destroy),
- window);
+ G_OBJECT (window));
/* this makes it so the button is the default. */
- GTK_WIDGET_SET_FLAGS (button, GTK_CAN_DEFAULT);
+ gtk_widget_set_can_default (button, TRUE);
gtk_box_pack_start (GTK_BOX (GTK_DIALOG (window)->action_area), button, TRUE, TRUE, 0);
/* This grabs this button to be the default button. Simply hitting