diff options
Diffstat (limited to 'widgets/table/e-table-specification.c')
-rw-r--r-- | widgets/table/e-table-specification.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/widgets/table/e-table-specification.c b/widgets/table/e-table-specification.c index f44212755b..e562f85ccb 100644 --- a/widgets/table/e-table-specification.c +++ b/widgets/table/e-table-specification.c @@ -62,6 +62,7 @@ etsp_init (ETableSpecification *etsp) etsp->click_to_add = FALSE; etsp->draw_grid = FALSE; etsp->cursor_mode = E_TABLE_CURSOR_SIMPLE; + etsp->selection_mode = GTK_SELECTION_MULTIPLE; etsp->click_to_add_message_ = NULL; } @@ -117,6 +118,17 @@ e_table_specification_load_from_node (ETableSpecification *specification, specification->click_to_add = e_xml_get_bool_prop_by_name(node, "click-to-add"); specification->draw_grid = e_xml_get_bool_prop_by_name(node, "draw-grid"); + specification->selection_mode = GTK_SELECTION_MULTIPLE; + temp = e_xml_get_string_prop_by_name(node, "selection-mode"); + if (temp && !strcasecmp(temp, "single")) { + specification->selection_mode = GTK_SELECTION_SINGLE; + } else if (temp && !strcasecmp(temp, "browse")) { + specification->selection_mode = GTK_SELECTION_BROWSE; + } else if (temp && !strcasecmp(temp, "extended")) { + specification->selection_mode = GTK_SELECTION_EXTENDED; + } + g_free(temp); + specification->cursor_mode = E_TABLE_CURSOR_SIMPLE; temp = e_xml_get_string_prop_by_name(node, "cursor-mode"); if (temp && !strcasecmp(temp, "line")) { |