aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui
diff options
context:
space:
mode:
authorJP Rosevear <jpr@ximian.com>2002-07-25 02:21:13 +0800
committerJP Rosevear <jpr@src.gnome.org>2002-07-25 02:21:13 +0800
commitdbb7b4fd11c47b3bcce2146035d306a11ce18c5d (patch)
tree570876046ca78ff284e08091d12f648568806d03 /calendar/gui
parent9a222768c20736a48d9967e617270733598b477e (diff)
downloadgsoc2013-evolution-dbb7b4fd11c47b3bcce2146035d306a11ce18c5d.tar.gz
gsoc2013-evolution-dbb7b4fd11c47b3bcce2146035d306a11ce18c5d.tar.zst
gsoc2013-evolution-dbb7b4fd11c47b3bcce2146035d306a11ce18c5d.zip
set status to in progress if the percent is between 0 and 100
2002-07-24 JP Rosevear <jpr@ximian.com> * gui/calendar-model.c (set_percent): set status to in progress if the percent is between 0 and 100 (set_status): if the value is set to in process, change the percent to 50 svn path=/trunk/; revision=17574
Diffstat (limited to 'calendar/gui')
-rw-r--r--calendar/gui/calendar-model.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/calendar/gui/calendar-model.c b/calendar/gui/calendar-model.c
index 55663f254c..c2416344ff 100644
--- a/calendar/gui/calendar-model.c
+++ b/calendar/gui/calendar-model.c
@@ -839,7 +839,6 @@ calendar_model_value_at (ETableModel *etm, int col, int row)
case CAL_COMPONENT_FIELD_ICON:
{
ItipAddress *ia;
- CalComponentOrganizer organizer;
GSList *attendees = NULL, *sl;
gint retval = 0;
@@ -1087,8 +1086,11 @@ set_percent (CalComponent *comp, const void *value)
if (percent == 100)
ensure_task_complete (comp, -1);
- else
+ else {
ensure_task_not_complete (comp);
+ if (percent > 0)
+ cal_component_set_status (comp, ICAL_STATUS_INPROCESS);
+ }
}
}
@@ -1195,6 +1197,10 @@ set_status (CalComponent *comp, const char *value)
percent = 0;
cal_component_set_percent (comp, &percent);
cal_component_set_completed (comp, NULL);
+ } else if (status == ICAL_STATUS_INPROCESS) {
+ ensure_task_not_complete (comp);
+ percent = 50;
+ cal_component_set_percent (comp, &percent);
} else if (status == ICAL_STATUS_COMPLETED) {
ensure_task_complete (comp, -1);
}