propagate from branch 'ca.inverse.sogo.1_3_18' (head 52bc1ab2a2dcc4de7809fd592d0e9c41c556cf17)

to branch 'ca.inverse.sogo' (head 263be06669bfcef33b9cb13a1171fdb0d4d5ec57)

Monotone-Parent: 263be06669bfcef33b9cb13a1171fdb0d4d5ec57
Monotone-Parent: 52bc1ab2a2dcc4de7809fd592d0e9c41c556cf17
Monotone-Revision: ec64b102b590c4a7b217fe508a46ad302e12adce

Monotone-Author: flachapelle@inverse.ca
Monotone-Date: 2012-08-22T13:52:16
Monotone-Branch: ca.inverse.sogo
maint-2.0.2
Francis Lachapelle 2012-08-22 13:52:16 +00:00
commit c2b564df12
3 changed files with 22 additions and 12 deletions

View File

@ -1,3 +1,14 @@
2012-08-22 Francis Lachapelle <flachapelle@inverse.ca>
* iCalWeeklyRecurrenceCalculator.m
(-recurrenceRangesWithinCalendarDateRange:): fixed validation of
the interval when a day mask is used on multiple days.
2012-08-21 Francis Lachapelle <flachapelle@inverse.ca>
* iCalRepeatableEntityObject.m (-exceptionDatesWithTimeZone:): we
now consider the timezone of the EXDATE, if defined.
2012-07-26 Wolfgang Sourdeau <wsourdeau@inverse.ca>
* iCalTimeZonePeriod.m (-recurrenceRule): new accessor for the
@ -5,7 +16,7 @@
(-startDate): made method public.
(-compare:): new method that compare two periods based on their
startDate, for timezone definitions which have a "standard" or
"daylight" period for more that one years.
"daylight" period for more that one year.
2012-05-30 Francis Lachapelle <flachapelle@inverse.ca>

View File

@ -33,6 +33,7 @@
#import "iCalDateTime.h"
#import "iCalEvent.h"
#import "iCalTimeZone.h"
#import "iCalTimeZonePeriod.h"
#import "iCalRecurrenceRule.h"
#import "iCalRecurrenceCalculator.h"
#import "iCalRepeatableEntityObject.h"
@ -258,19 +259,19 @@
while ((dateString = [dateList nextObject]))
{
exDates = [(iCalDateTime*) dateString valuesAtIndex: 0 forKey: @""];
for (i = 0; i < [exDates count]; i++)
exDates = [(iCalDateTime*) dateString dateTimes];
for (i = 0; i < [exDates count]; i++)
{
dateString = [exDates objectAtIndex: i];
exDate = [exDates objectAtIndex: i];
// Example: timezone is -0400, date is 2012-05-24 (00:00:00 +0000),
// and changes to 2012-05-24 04:00:00 +0000
if ([theTimeZone isKindOfClass: [iCalTimeZone class]])
{
exDate = [(iCalTimeZone *) theTimeZone computedDateForString: dateString];
exDate = [(iCalTimeZone *) theTimeZone computedDateForDate: exDate];
}
else
{
// Example: timezone is -0400, date is 2012-05-24 (00:00:00 +0000),
// and changes to 2012-05-24 04:00:00 +0000
exDate = [dateString asCalendarDate];
offset = [(NSTimeZone *) theTimeZone secondsFromGMTForDate: exDate];
exDate = (NSCalendarDate *) [exDate dateByAddingYears:0 months:0 days:0 hours:0 minutes:0
seconds:-offset];

View File

@ -118,8 +118,8 @@
currentStartDate = [firStart copy];
[currentStartDate autorelease];
ranges = [NSMutableArray array];
i = 0;
count = 0;
i = [currentStartDate dayOfWeek]; // Set the first day of the week as Sunday and ignore WKST
if (dayMask == nil)
{
@ -158,7 +158,7 @@
[startDate compare: currentStartDate] == NSOrderedSame)
{
// If the rule count is defined, stop once the count is reached.
if (i == 0)
if ([currentStartDate compare: firStart] == NSOrderedSame)
{
// Always add the start date of the recurring event if within
// the lookup range.
@ -166,8 +166,6 @@
}
else
{
// The following always set the first day of the week as the day
// of the master event start date, ie WKST is ignored.
week = i / 7;
if ((week % interval) == 0 &&