LSWSkyrixFrame.m (opengroupware-5.5rc2) | : | LSWSkyrixFrame.m (opengroupware-5.5rc3) | ||
---|---|---|---|---|
skipping to change at line 292 | skipping to change at line 292 | |||
if (showAMPM == -1) { | if (showAMPM == -1) { | |||
id ud = [[self session] userDefaults]; | id ud = [[self session] userDefaults]; | |||
showAMPM = [ud boolForKey:@"scheduler_AMPM_dates"] ? 1 : 0; | showAMPM = [ud boolForKey:@"scheduler_AMPM_dates"] ? 1 : 0; | |||
} | } | |||
tz = [[self session] timeZone]; | tz = [[self session] timeZone]; | |||
d = [NSCalendarDate dateWithTimeIntervalSinceNow: | d = [NSCalendarDate dateWithTimeIntervalSinceNow: | |||
[self activeSessionTimeOut]]; | [self activeSessionTimeOut]]; | |||
[d setTimeZone:tz]; | [d setTimeZone:tz]; | |||
if (showAMPM) { | if (showAMPM) { | |||
int hour; | NSInteger hour; | |||
BOOL am = YES; | BOOL am = YES; | |||
hour = [d hourOfDay]; | hour = [d hourOfDay]; | |||
if (hour > 11) am = NO; | if (hour > 11) am = NO; | |||
hour = hour % 12; | hour = hour % 12; | |||
if (!hour) hour = 12; | if (!hour) hour = 12; | |||
return [NSString stringWithFormat:@"%02i:%02i %@ %@", | return [NSString stringWithFormat:@"%02"PRIiPTR":%02"PRIiPTR" %@ %@", | |||
hour, [d minuteOfHour], am ? @"AM" : @"PM", | hour, [d minuteOfHour], am ? @"AM" : @"PM", | |||
[tz abbreviation]]; | [tz abbreviation]]; | |||
} | } | |||
return [NSString stringWithFormat:@"%02i:%02i %@", | return [NSString stringWithFormat:@"%02"PRIiPTR":%02"PRIiPTR" %@", | |||
[d hourOfDay], [d minuteOfHour], [tz abbreviation]]; | [d hourOfDay], [d minuteOfHour], [tz abbreviation]]; | |||
} | } | |||
/* actions */ | /* actions */ | |||
- (id)logout { | - (id)logout { | |||
NSUserDefaults *ud; | NSUserDefaults *ud; | |||
BOOL logLogout; | BOOL logLogout; | |||
ud = [[self session] userDefaults]; | ud = [[self session] userDefaults]; | |||
End of changes. 3 change blocks. | ||||
3 lines changed or deleted | 3 lines changed or added |