aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/e-table/test-table.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@helixcode.com>2000-03-06 14:08:56 +0800
committerChris Lahey <clahey@src.gnome.org>2000-03-06 14:08:56 +0800
commitdf08e926e4ac496e75974620162e59cf323f623a (patch)
tree2b134fb9dee077bbc940ae9be3bde37fefaed9f3 /widgets/e-table/test-table.c
parent053267fc5d7a087b315612a43fc493083309f465 (diff)
downloadgsoc2013-evolution-df08e926e4ac496e75974620162e59cf323f623a.tar.gz
gsoc2013-evolution-df08e926e4ac496e75974620162e59cf323f623a.tar.zst
gsoc2013-evolution-df08e926e4ac496e75974620162e59cf323f623a.zip
Add a "row_selection" signal.
2000-03-06 Christopher James Lahey <clahey@helixcode.com> * 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
Diffstat (limited to 'widgets/e-table/test-table.c')
-rw-r--r--widgets/e-table/test-table.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/widgets/e-table/test-table.c b/widgets/e-table/test-table.c
index 7bb54b668a..341013e92c 100644
--- a/widgets/e-table/test-table.c
+++ b/widgets/e-table/test-table.c
@@ -279,6 +279,15 @@ save_spec (GtkWidget *button, ETable *e_table)
}
static void
+row_selection_test (ETable *table, int row, gboolean selected)
+{
+ if ( selected )
+ g_print ("Row %d selected\n", row);
+ else
+ g_print ("Row %d unselected\n", row);
+}
+
+static void
do_e_table_demo (const char *spec)
{
GtkWidget *e_table, *window, *frame, *vbox, *button;
@@ -314,6 +323,8 @@ do_e_table_demo (const char *spec)
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
frame = gtk_frame_new (NULL);
e_table = e_table_new (full_header, e_table_model, spec);
+ gtk_signal_connect(GTK_OBJECT(e_table), "row_selection",
+ GTK_SIGNAL_FUNC(row_selection_test), NULL);
button = gtk_button_new_with_label("Save spec");
gtk_signal_connect (GTK_OBJECT (button), "clicked",