From 342de51c7d93f94c9b19444547cac2a5f6441c2f Mon Sep 17 00:00:00 2001 From: JP Rosevear Date: Mon, 4 Jun 2001 19:46:35 +0000 Subject: update the blocked/selected days if the starting day of the appointment 2001-06-04 JP Rosevear * gui/dialogs/recurrence-page.c (recurrence_page_set_dates): update the blocked/selected days if the starting day of the appointment changes, fixes #2188 * gui/dialogs/task-details-page.h: tidy proto svn path=/trunk/; revision=10113 --- calendar/gui/dialogs/recurrence-page.c | 14 ++++++++++++++ calendar/gui/dialogs/task-details-page.h | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) (limited to 'calendar/gui') diff --git a/calendar/gui/dialogs/recurrence-page.c b/calendar/gui/dialogs/recurrence-page.c index b4a998f353..77b22a97ac 100644 --- a/calendar/gui/dialogs/recurrence-page.c +++ b/calendar/gui/dialogs/recurrence-page.c @@ -1695,6 +1695,7 @@ recurrence_page_set_dates (CompEditorPage *page, CompEditorPageDates *dates) RecurrencePagePrivate *priv; CalComponentDateTime dt; struct icaltimetype icaltime; + guint8 mask; rpage = RECURRENCE_PAGE (page); priv = rpage->priv; @@ -1716,6 +1717,19 @@ recurrence_page_set_dates (CompEditorPage *page, CompEditorPageDates *dates) *dt.value = icaltime_from_timet (dates->end, FALSE); cal_component_set_dtend (priv->comp, &dt); } + + /* Update the weekday picker if necessary */ + mask = get_start_weekday_mask (priv->comp); + if (mask == priv->weekday_blocked_day_mask) + return; + + priv->weekday_day_mask = priv->weekday_day_mask | mask; + priv->weekday_blocked_day_mask = mask; + + weekday_picker_set_days (priv->weekday_picker, + priv->weekday_day_mask); + weekday_picker_set_blocked_days (priv->weekday_picker, + priv->weekday_blocked_day_mask); } diff --git a/calendar/gui/dialogs/task-details-page.h b/calendar/gui/dialogs/task-details-page.h index d285eb9cc0..555e7d162d 100644 --- a/calendar/gui/dialogs/task-details-page.h +++ b/calendar/gui/dialogs/task-details-page.h @@ -52,7 +52,7 @@ typedef struct { GtkType task_details_page_get_type (void); -TaskDetailsPage *task_details_page_construct (TaskDetailsPage *epage); +TaskDetailsPage *task_details_page_construct (TaskDetailsPage *tdpage); TaskDetailsPage *task_details_page_new (void); -- cgit