Author: juha
Date: 2006-10-08 16:11:42 +0000 (Sun, 08 Oct 2006)
New Revision: 23318

Modified:
   xfcalendar/trunk/src/ical-code.c
Log:
fixed error in showing more than 1 day in even list window.
    after ical fixes, icaltime_add does not work with dates anymore.


Modified: xfcalendar/trunk/src/ical-code.c
===================================================================
--- xfcalendar/trunk/src/ical-code.c    2006-10-08 13:39:13 UTC (rev 23317)
+++ xfcalendar/trunk/src/ical-code.c    2006-10-08 16:11:42 UTC (rev 23318)
@@ -1847,7 +1847,6 @@
     struct icaltimetype 
               asdate, aedate    /* period to check */
             , nsdate, nedate;   /* repeating event occurrency start and end */
-    struct icaldurationtype aduration;
     xfical_period per; /* event start and end times with duration */
     icalcomponent *c=NULL;
     icalproperty *p = NULL;
@@ -1861,13 +1860,9 @@
 
     /* setup period to test */
     asdate = icaltime_from_string(a_day);
-    if (days) { /* more than one day to check */
-        aduration = icaldurationtype_null_duration();
-        aduration.days = days;
-        aedate = icaltime_add(asdate, aduration);
-    }
-    else /* only one day */
-        aedate = asdate;
+    aedate = asdate;
+    if (days)  /* more than one day to check */
+        icaltime_adjust(&aedate, days, 0, 0, 0);
 
     if (first)
         ci = icalcomponent_begin_component(ical, ICAL_VEVENT_COMPONENT);

_______________________________________________
Xfce4-commits mailing list
Xfce4-commits@xfce.org
http://foo-projects.org/mailman/listinfo/xfce4-commits

Reply via email to