(fix) enhance display of all-day invitations (fixes #4145)

Conflicts:
	SoObjects/Appointments/SOGoAptMailNotification.m
This commit is contained in:
Ludovic Marcotte
2017-04-12 16:13:40 -04:00
parent 0af81b0831
commit d87dc6cdf2
5 changed files with 40 additions and 15 deletions
+8 -10
View File
@@ -238,21 +238,19 @@
return [[self dateFormatter] formattedTime: [self endCalendarDate]];
}
- (BOOL) isEndDateOnSameDay
{
NSCalendarDate *aDate;
if ([[self inEvent] isAllDay])
aDate = [[self endCalendarDate] dateByAddingYears:0 months:0 days:0 hours:0 minutes:0 seconds:-1];
else
aDate = [self endCalendarDate];
return [[self startCalendarDate] isDateOnSameDay: aDate];
}
- (NSTimeInterval) duration
{
return [[self endCalendarDate] timeIntervalSinceDate:[self startCalendarDate]];
}
- (BOOL) isEndDateOnSameDay
{
if ([[self inEvent] isAllDay])
return [self duration] <= 86400;
return [[self startCalendarDate] isDateOnSameDay: [self endCalendarDate]];
}
/* calendar folder support */
- (SOGoAppointmentFolder *) calendarFolder