Detect recurring events when rendering a calendar.
authorArt Cancro <ajc@citadel.org>
Mon, 14 Jul 2008 16:04:33 +0000 (16:04 +0000)
committerArt Cancro <ajc@citadel.org>
Mon, 14 Jul 2008 16:04:33 +0000 (16:04 +0000)
webcit/calendar.c

index e91012eefcab1e131935a2354a2f2c79d7c2a9fb..28e0602b380df3846945a64d62dcd7a24107ca1c 100644 (file)
@@ -459,12 +459,26 @@ void display_individual_cal(icalcomponent *cal, long msgnum, char *from, int unr
            Cal, 
            delete_cal);
 
-       /* Right about here is probably where we want to add code to handle recurring events.
+#ifdef TECH_PREVIEW
+
+       /* handle recurring events (unfinished) */
+
+       /*
         * Just let libical iterate the recurrence, and keep looping back to the top of this function,
         * adding new hash entries that all point back to the same msgnum, until either the iteration
         * stops or some outer bound is reached.  The display code *should* automatically do the right
         * thing (but we'll have to see).
+
+       icalproperty *rrule = icalcomponent_get_first_property(Cal->cal, ICAL_RRULE_PROPERTY);
+       if (!rrule) return;
+       struct icalrecurrencetype recur = icalproperty_get_rrule(rrule);
+
+       lprintf(9, "recurrence detected -- need to handle this\n");
+
         */
+
+#endif /* TECH_PREVIEW */
+
 }