From df08e926e4ac496e75974620162e59cf323f623a Mon Sep 17 00:00:00 2001 From: Christopher James Lahey Date: Mon, 6 Mar 2000 06:08:56 +0000 Subject: Add a "row_selection" signal. 2000-03-06 Christopher James Lahey * e-table.c, e-table.h: Add a "row_selection" signal. * test-table.c: Test the new "row_selection" signal. * e-table-group-container.c, e-table-group-leaf.c: Implement the "row_selection" property properly. * e-table-group.c, e-table-group.h: Add a "row_selection" signal. svn path=/trunk/; revision=2069 --- widgets/e-table/e-table-group.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'widgets/e-table/e-table-group.c') diff --git a/widgets/e-table/e-table-group.c b/widgets/e-table/e-table-group.c index ef89efd9bd..ce7f1945f6 100644 --- a/widgets/e-table/e-table-group.c +++ b/widgets/e-table/e-table-group.c @@ -29,6 +29,7 @@ static GnomeCanvasGroupClass *etg_parent_class; enum { + ROW_SELECTION, RESIZE, LAST_SIGNAL }; @@ -228,6 +229,17 @@ e_table_group_resize (ETableGroup *e_table_group) etg_signals [RESIZE]); } +void +e_table_group_row_selection (ETableGroup *e_table_group, gint row, gboolean selected) +{ + g_return_if_fail (e_table_group != NULL); + g_return_if_fail (E_IS_TABLE_GROUP (e_table_group)); + + gtk_signal_emit (GTK_OBJECT (e_table_group), + etg_signals [ROW_SELECTION], + row, selected); +} + ETableHeader * e_table_group_get_header (ETableGroup *etg) { @@ -339,6 +351,7 @@ etg_class_init (GtkObjectClass *object_class) item_class->event = etg_event; klass->resize = NULL; + klass->row_selection = NULL; klass->add = NULL; klass->remove = NULL; @@ -355,6 +368,14 @@ etg_class_init (GtkObjectClass *object_class) etg_parent_class = gtk_type_class (PARENT_TYPE); + etg_signals [ROW_SELECTION] = + gtk_signal_new ("row_selection", + GTK_RUN_LAST, + object_class->type, + GTK_SIGNAL_OFFSET (ETableGroupClass, row_selection), + gtk_marshal_NONE__INT_INT, + GTK_TYPE_NONE, 2, GTK_TYPE_INT, GTK_TYPE_INT); + etg_signals [RESIZE] = gtk_signal_new ("resize", GTK_RUN_LAST, -- cgit