aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui
diff options
context:
space:
mode:
authorChenthill Palanisamy <pchen@src.gnome.org>2006-01-05 15:17:43 +0800
committerChenthill Palanisamy <pchen@src.gnome.org>2006-01-05 15:17:43 +0800
commit02871e3c454b8adbc672404e77b459114344ea15 (patch)
tree7598fc5d24a74d5301c1eafb62054bf90fc98dbe /calendar/gui
parent26ffb596c39b80acb420d1448a0c28f976a2270b (diff)
downloadgsoc2013-evolution-02871e3c454b8adbc672404e77b459114344ea15.tar
gsoc2013-evolution-02871e3c454b8adbc672404e77b459114344ea15.tar.gz
gsoc2013-evolution-02871e3c454b8adbc672404e77b459114344ea15.tar.bz2
gsoc2013-evolution-02871e3c454b8adbc672404e77b459114344ea15.tar.lz
gsoc2013-evolution-02871e3c454b8adbc672404e77b459114344ea15.tar.xz
gsoc2013-evolution-02871e3c454b8adbc672404e77b459114344ea15.tar.zst
gsoc2013-evolution-02871e3c454b8adbc672404e77b459114344ea15.zip
fixes #258786
svn path=/trunk/; revision=31060
Diffstat (limited to 'calendar/gui')
-rw-r--r--calendar/gui/e-cal-popup.c12
-rw-r--r--calendar/gui/e-calendar-table.c2
2 files changed, 12 insertions, 2 deletions
diff --git a/calendar/gui/e-cal-popup.c b/calendar/gui/e-cal-popup.c
index eb542459a7..2f80f7d34a 100644
--- a/calendar/gui/e-cal-popup.c
+++ b/calendar/gui/e-cal-popup.c
@@ -569,8 +569,18 @@ e_cal_popup_target_new_select(ECalPopup *eabp, struct _ECalModel *model, GPtrArr
mask &= ~E_CAL_POPUP_SELECT_ANY;
if (t->events->len == 1)
mask &= ~E_CAL_POPUP_SELECT_ONE;
- else
+ else {
mask &= ~E_CAL_POPUP_SELECT_MANY;
+ /* Now check for any incomplete tasks and set the flags*/
+ int i=0;
+ for (; i < t->events->len; i++) {
+ ECalModelComponent *comp_data = (ECalModelComponent *)t->events->pdata[i];
+ if (!icalcomponent_get_first_property (comp_data->icalcomp, ICAL_COMPLETED_PROPERTY)) {
+ mask &= ~E_CAL_POPUP_SELECT_NOTCOMPLETE;
+ break;
+ }
+ }
+ }
if (icalcomponent_get_first_property (comp_data->icalcomp, ICAL_URL_PROPERTY))
mask &= ~E_CAL_POPUP_SELECT_HASURL;
diff --git a/calendar/gui/e-calendar-table.c b/calendar/gui/e-calendar-table.c
index 8caa27d6d6..b6788c6cb8 100644
--- a/calendar/gui/e-calendar-table.c
+++ b/calendar/gui/e-calendar-table.c
@@ -1189,7 +1189,7 @@ static EPopupItem tasks_popup_items [] = {
{ E_POPUP_ITEM, "80.assign", N_("_Assign Task"), e_calendar_table_on_assign, NULL, NULL, E_CAL_POPUP_SELECT_ONE, E_CAL_POPUP_SELECT_EDITABLE|E_CAL_POPUP_SELECT_ASSIGNABLE },
{ E_POPUP_ITEM, "90.forward", N_("_Forward as iCalendar"), e_calendar_table_on_forward, NULL, "stock_mail-forward", E_CAL_POPUP_SELECT_ONE },
{ E_POPUP_ITEM, "a0.markonecomplete", N_("_Mark as Complete"), mark_as_complete_cb, NULL, NULL, E_CAL_POPUP_SELECT_ONE, E_CAL_POPUP_SELECT_EDITABLE | E_CAL_POPUP_SELECT_NOTCOMPLETE},
- { E_POPUP_ITEM, "b0.markmanycomplete", N_("_Mark Selected Tasks as Complete"), mark_as_complete_cb, NULL, NULL, E_CAL_POPUP_SELECT_MANY, E_CAL_POPUP_SELECT_EDITABLE },
+ { E_POPUP_ITEM, "b0.markmanycomplete", N_("_Mark Selected Tasks as Complete"), mark_as_complete_cb, NULL, NULL, E_CAL_POPUP_SELECT_MANY, E_CAL_POPUP_SELECT_EDITABLE | E_CAL_POPUP_SELECT_NOTCOMPLETE },
{ E_POPUP_BAR, "c0.bar" },