added the missing method on_delete (window)

This commit is contained in:
mrsmola 2007-02-25 14:44:15 +00:00
parent 49b25105c2
commit 93bca4f779
3 changed files with 19 additions and 0 deletions

View File

@ -229,3 +229,14 @@ on_b_inc_training_clicked (GtkButton *button,
}
}
gboolean
on_window_training_camp_delete_event (GtkWidget *widget,
GdkEvent *event,
gpointer user_data)
{
on_b_cancel_clicked(NULL, NULL);
return TRUE;
}

View File

@ -61,3 +61,8 @@ on_b_dec_training_clicked (GtkButton *button,
void
on_b_inc_training_clicked (GtkButton *button,
gpointer user_data);
gboolean
on_window_training_camp_delete_event (GtkWidget *widget,
GdkEvent *event,
gpointer user_data);

View File

@ -194,6 +194,9 @@ create_window_training_camp (void)
gtk_radio_button_set_group (GTK_RADIO_BUTTON (rb_camp1), rb_camp2_group);
rb_camp2_group = gtk_radio_button_get_group (GTK_RADIO_BUTTON (rb_camp1));
g_signal_connect ((gpointer) window_training_camp, "delete_event",
G_CALLBACK (on_window_training_camp_delete_event),
NULL);
g_signal_connect ((gpointer) b_cancel, "clicked",
G_CALLBACK (on_b_cancel_clicked),
NULL);