diff options
author | Christopher James Lahey <clahey@helixcode.com> | 2000-08-26 17:15:32 +0800 |
---|---|---|
committer | Chris Lahey <clahey@src.gnome.org> | 2000-08-26 17:15:32 +0800 |
commit | 20925d94eb5649df410820e67017a299ce5d867d (patch) | |
tree | 34a29bc7dc4aca4cae7fd97e5aa5a97497f4926b /widgets/table/e-table-config.c | |
parent | 4c768a32bf0d07dea885d7e23da66762a7d2c82a (diff) | |
download | gsoc2013-evolution-20925d94eb5649df410820e67017a299ce5d867d.tar.gz gsoc2013-evolution-20925d94eb5649df410820e67017a299ce5d867d.tar.zst gsoc2013-evolution-20925d94eb5649df410820e67017a299ce5d867d.zip |
Added some g_return_if_fails and g_return_val_if_fails.
2000-08-25 Christopher James Lahey <clahey@helixcode.com>
* e-table-col.c, e-table-config.c, e-table-header.c,
e-table-text-model.c: Added some g_return_if_fails and
g_return_val_if_fails.
svn path=/trunk/; revision=5056
Diffstat (limited to 'widgets/table/e-table-config.c')
-rw-r--r-- | widgets/table/e-table-config.c | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/widgets/table/e-table-config.c b/widgets/table/e-table-config.c index 5d078f8f86..d124fe5d2d 100644 --- a/widgets/table/e-table-config.c +++ b/widgets/table/e-table-config.c @@ -150,7 +150,10 @@ e_table_gui_config (ETable *etable) GladeXML *gui; GnomeDialog *dialog; ConfigData *config_data; - + + g_return_val_if_fail(etable != NULL, NULL); + g_return_val_if_fail(E_IS_TABLE(etable), NULL); + glade_gnome_init (); gui = glade_xml_new (ETABLE_GLADEDIR "/e-table-config.glade", NULL); if (!gui) @@ -193,16 +196,26 @@ e_table_gui_destroy_config_data (GtkWidget *widget) gtk_object_destroy (GTK_OBJECT (cd->gui)); g_free (cd); } - + void e_table_gui_config_accept (GtkWidget *widget, ETable *etable) { + g_return_if_fail(etable != NULL); + g_return_if_fail(E_IS_TABLE(etable)); + g_return_if_fail(widget != NULL); + g_return_if_fail(GTK_IS_WIDGET(widget)); + e_table_gui_destroy_config_data (widget); } void e_table_gui_config_cancel (GtkWidget *widget, ETable *etable) { + g_return_if_fail(etable != NULL); + g_return_if_fail(E_IS_TABLE(etable)); + g_return_if_fail(widget != NULL); + g_return_if_fail(GTK_IS_WIDGET(widget)); + e_table_gui_destroy_config_data (widget); } @@ -212,6 +225,10 @@ e_table_do_gui_config (GtkWidget *parent, ETable *etable) GnomeDialog *dialog; int r; + g_return_if_fail(etable != NULL); + g_return_if_fail(E_IS_TABLE(etable)); + g_return_if_fail(parent == NULL || GTK_IS_WINDOW(parent)); + dialog = GNOME_DIALOG (e_table_gui_config (etable)); if (!dialog) return; |