aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table/e-table-column-specification.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@ximian.com>2001-10-03 21:47:56 +0800
committerChris Lahey <clahey@src.gnome.org>2001-10-03 21:47:56 +0800
commit2e93b3da0b04b8f262891ebf38827b2d21f80905 (patch)
tree558cec578eea4edff7c667b6d4bf8c19fae42b2e /widgets/table/e-table-column-specification.c
parentd3798ab87ef00d8c3944b362bd4960b33d95f4d3 (diff)
downloadgsoc2013-evolution-2e93b3da0b04b8f262891ebf38827b2d21f80905.tar.gz
gsoc2013-evolution-2e93b3da0b04b8f262891ebf38827b2d21f80905.tar.zst
gsoc2013-evolution-2e93b3da0b04b8f262891ebf38827b2d21f80905.zip
Pick which field of the row to select based on priority.
2001-10-03 Christopher James Lahey <clahey@ximian.com> * e-table-click-to-add.c (set_initial_selection): Pick which field of the row to select based on priority. * e-table-col.c, e-table-col.h: Added the priority field to this class. Adapted the _new functions appropriately. * e-table-column-specification.c, e-table-column-specification.h: Added the priority field to this class. * e-table-utils.c (et_col_spec_to_col): Handle the priority field here. svn path=/trunk/; revision=13370
Diffstat (limited to 'widgets/table/e-table-column-specification.c')
-rw-r--r--widgets/table/e-table-column-specification.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/widgets/table/e-table-column-specification.c b/widgets/table/e-table-column-specification.c
index 68c19188b1..ad1122dec9 100644
--- a/widgets/table/e-table-column-specification.c
+++ b/widgets/table/e-table-column-specification.c
@@ -60,6 +60,7 @@ etcs_init (ETableColumnSpecification *specification)
specification->cell = NULL;
specification->compare = NULL;
+ specification->priority = 0;
}
E_MAKE_TYPE(e_table_column_specification, "ETableColumnSpecification", ETableColumnSpecification, etcs_class_init, etcs_init, PARENT_TYPE);
@@ -88,6 +89,7 @@ e_table_column_specification_load_from_node (ETableColumnSpecification *etcs,
etcs->cell = e_xml_get_string_prop_by_name(node, "cell");
etcs->compare = e_xml_get_string_prop_by_name(node, "compare");
+ etcs->priority = e_xml_get_integer_prop_by_name_with_default (node, "priority", 0);
if (etcs->title == NULL)
etcs->title = g_strdup("");
@@ -113,6 +115,8 @@ e_table_column_specification_save_to_node (ETableColumnSpecification *specificat
e_xml_set_string_prop_by_name(node, "cell", specification->cell);
e_xml_set_string_prop_by_name(node, "compare", specification->compare);
+ if (specification->priority != 0)
+ e_xml_set_integer_prop_by_name (node, "priority", specification->priority);
return node;
}