aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/e-calendar-table.c
diff options
context:
space:
mode:
authorChenthill Palanisamy <pchen@src.gnome.org>2005-07-02 22:54:44 +0800
committerChenthill Palanisamy <pchen@src.gnome.org>2005-07-02 22:54:44 +0800
commitcb9a6f71878dc639b0711d97ec3bc8e16d4ffcf6 (patch)
treee583bf6e4342672df9191e9869ad7e812da7ed22 /calendar/gui/e-calendar-table.c
parent10315aabac9f3cab20fc54527af82b06b8588ff9 (diff)
downloadgsoc2013-evolution-cb9a6f71878dc639b0711d97ec3bc8e16d4ffcf6.tar
gsoc2013-evolution-cb9a6f71878dc639b0711d97ec3bc8e16d4ffcf6.tar.gz
gsoc2013-evolution-cb9a6f71878dc639b0711d97ec3bc8e16d4ffcf6.tar.bz2
gsoc2013-evolution-cb9a6f71878dc639b0711d97ec3bc8e16d4ffcf6.tar.lz
gsoc2013-evolution-cb9a6f71878dc639b0711d97ec3bc8e16d4ffcf6.tar.xz
gsoc2013-evolution-cb9a6f71878dc639b0711d97ec3bc8e16d4ffcf6.tar.zst
gsoc2013-evolution-cb9a6f71878dc639b0711d97ec3bc8e16d4ffcf6.zip
show the progress indication in the view while downloading calendar items
from EDS svn path=/trunk/; revision=29618
Diffstat (limited to 'calendar/gui/e-calendar-table.c')
-rw-r--r--calendar/gui/e-calendar-table.c21
1 files changed, 15 insertions, 6 deletions
diff --git a/calendar/gui/e-calendar-table.c b/calendar/gui/e-calendar-table.c
index f68c3a317d..5b11c4420a 100644
--- a/calendar/gui/e-calendar-table.c
+++ b/calendar/gui/e-calendar-table.c
@@ -691,7 +691,7 @@ delete_selected_components (ECalendarTable *cal_table)
objs = get_selected_objects (cal_table);
- e_calendar_table_set_status_message (cal_table, _("Deleting selected objects"));
+ e_calendar_table_set_status_message (cal_table, _("Deleting selected objects"), -1);
for (l = objs; l; l = l->next) {
ECalModelComponent *comp_data = (ECalModelComponent *) l->data;
@@ -703,7 +703,7 @@ delete_selected_components (ECalendarTable *cal_table)
g_clear_error (&error);
}
- e_calendar_table_set_status_message (cal_table, NULL);
+ e_calendar_table_set_status_message (cal_table, NULL, -1);
g_slist_free (objs);
}
@@ -870,7 +870,7 @@ clipboard_get_text_cb (GtkClipboard *clipboard, const gchar *text, ECalendarTabl
client = e_cal_model_get_default_client (cal_table->model);
- e_calendar_table_set_status_message (cal_table, _("Updating objects"));
+ e_calendar_table_set_status_message (cal_table, _("Updating objects"), -1);
if (kind == ICAL_VCALENDAR_COMPONENT) {
icalcomponent_kind child_kind;
@@ -916,7 +916,7 @@ clipboard_get_text_cb (GtkClipboard *clipboard, const gchar *text, ECalendarTabl
g_object_unref (comp);
}
- e_calendar_table_set_status_message (cal_table, NULL);
+ e_calendar_table_set_status_message (cal_table, NULL, -1);
}
/**
@@ -1343,7 +1343,7 @@ e_calendar_table_set_activity_handler (ECalendarTable *cal_table, EActivityHandl
}
void
-e_calendar_table_set_status_message (ECalendarTable *cal_table, const gchar *message)
+e_calendar_table_set_status_message (ECalendarTable *cal_table, const gchar *message, int percent)
{
g_return_if_fail (E_IS_CALENDAR_TABLE (cal_table));
@@ -1366,6 +1366,15 @@ e_calendar_table_set_status_message (ECalendarTable *cal_table, const gchar *mes
g_free (client_id);
} else {
- e_activity_handler_operation_progressing (cal_table->activity_handler, cal_table->activity_id, message, -1.0);
+
+ double progress;
+
+ if (percent < 0)
+ progress = -1.0;
+ else {
+ progress = ((double) percent / 100);
+ }
+
+ e_activity_handler_operation_progressing (cal_table->activity_handler, cal_table->activity_id, message, progress);
}
}