aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table/e-table-model.c
diff options
context:
space:
mode:
Diffstat (limited to 'widgets/table/e-table-model.c')
-rw-r--r--widgets/table/e-table-model.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/widgets/table/e-table-model.c b/widgets/table/e-table-model.c
index 62a45d966e..5045f68b02 100644
--- a/widgets/table/e-table-model.c
+++ b/widgets/table/e-table-model.c
@@ -85,6 +85,18 @@ e_table_model_is_cell_editable (ETableModel *e_table_model, int col, int row)
return ETM_CLASS (e_table_model)->is_cell_editable (e_table_model, col, row);
}
+gint
+e_table_model_append_row (ETableModel *e_table_model)
+{
+ g_return_val_if_fail (e_table_model != NULL, -1);
+ g_return_val_if_fail (E_IS_TABLE_MODEL (e_table_model), -1);
+
+ if (ETM_CLASS (e_table_model)->append_row)
+ return ETM_CLASS (e_table_model)->append_row (e_table_model);
+ else
+ return -1;
+}
+
void *
e_table_model_duplicate_value (ETableModel *e_table_model, int col, const void *value)
{
@@ -131,6 +143,18 @@ e_table_model_value_is_empty (ETableModel *e_table_model, int col, const void *v
return FALSE;
}
+char *
+e_table_model_value_to_string (ETableModel *e_table_model, int col, const void *value)
+{
+ g_return_val_if_fail (e_table_model != NULL, NULL);
+ g_return_val_if_fail (E_IS_TABLE_MODEL (e_table_model), NULL);
+
+ if (ETM_CLASS (e_table_model)->value_to_string)
+ return ETM_CLASS (e_table_model)->value_to_string (e_table_model, col, value);
+ else
+ return g_strdup("");
+}
+
static void
e_table_model_destroy (GtkObject *object)
{
@@ -193,10 +217,13 @@ e_table_model_class_init (GtkObjectClass *object_class)
klass->value_at = NULL;
klass->set_value_at = NULL;
klass->is_cell_editable = NULL;
+ klass->append_row = NULL;
+
klass->duplicate_value = NULL;
klass->free_value = NULL;
klass->initialize_value = NULL;
klass->value_is_empty = NULL;
+ klass->value_to_string = NULL;
klass->model_changed = NULL;
klass->model_row_changed = NULL;
klass->model_cell_changed = NULL;