Fixed repetitive events issues
parent
0c2e2f28f7
commit
ba258ca806
|
@ -34,6 +34,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|||
#import <Foundation/NSDictionary.h>
|
||||
#import <Foundation/NSString.h>
|
||||
|
||||
#import <NGCards/iCalEvent.h>
|
||||
#import <NGCards/iCalByDayMask.h>
|
||||
|
||||
#import "NSCalendarDate+ActiveSync.h"
|
||||
|
@ -77,11 +78,20 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|||
occurrences = [[self byDayMask] weekDayOccurrences];
|
||||
v = 0;
|
||||
|
||||
if (occurrences)
|
||||
{
|
||||
for (i = 0; i < 7; i++)
|
||||
{
|
||||
if (occurrences[0][i])
|
||||
v += (1 << i);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// No byDayMask, we take the event's start date to compute the DayOfWeek
|
||||
// 0 == Sunday, 6 == Saturday
|
||||
v = (1 << [[[self parent] startDate] dayOfWeek]);
|
||||
}
|
||||
|
||||
[s appendFormat: @"<Recurrence_DayOfWeek xmlns=\"Calendar:\">%d</Recurrence_DayOfWeek>", v];
|
||||
[s appendFormat: @"<Recurrence_Interval xmlns=\"Calendar:\">%d</Recurrence_Interval>", [self repeatInterval]];
|
||||
|
@ -125,6 +135,13 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|||
// FIXME
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Simple reccurrence rule of type "Monthly"
|
||||
type = 2;
|
||||
[s appendFormat: @"<Recurrence_DayOfMonth xmlns=\"Calendar:\">%d</Recurrence_DayOfMonth>",
|
||||
[[[self parent] startDate] dayOfMonth]];
|
||||
}
|
||||
}
|
||||
else if ([self frequency] == iCalRecurrenceFrequenceYearly)
|
||||
{
|
||||
|
|
1
NEWS
1
NEWS
|
@ -8,6 +8,7 @@ Enhancements
|
|||
Bug fixes
|
||||
- avoid crashing when we forward an email with no Subject header
|
||||
- we no longer try to include attachments when replying to a mail
|
||||
- fixed ActiveSync repetitive events issues with "Weekly" and "Monthly" ones
|
||||
|
||||
2.2.4 (2014-05-29)
|
||||
------------------
|
||||
|
|
Loading…
Reference in New Issue