mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-07-05 16:35:10 +00:00
Monotone-Parent: 38a512204cb4c49fbc144379e8587aaea3394a3a
Monotone-Revision: 62820f08c88e6bd9bf5b0d9c61b83fb3d1a337e8 Monotone-Author: flachapelle@inverse.ca Monotone-Date: 2008-08-25T19:13:18 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
@@ -87,26 +87,23 @@ _intValueFromHex (NSString *hexString)
|
||||
|
||||
- (NSArray *) calendars
|
||||
{
|
||||
NSArray *folders, *roles;
|
||||
NSArray *folders;
|
||||
SOGoAppointmentFolders *co;
|
||||
SOGoAppointmentFolder *folder;
|
||||
NSMutableDictionary *calendar;
|
||||
unsigned int count, max;
|
||||
NSString *folderName, *fDisplayName;
|
||||
NSNumber *isActive;
|
||||
SOGoUser *user;
|
||||
|
||||
if (!calendars)
|
||||
{
|
||||
co = [self clientObject];
|
||||
user = [[self context] activeUser];
|
||||
folders = [co subFolders];
|
||||
max = [folders count];
|
||||
calendars = [[NSMutableArray alloc] initWithCapacity: max];
|
||||
for (count = 0; count < max; count++)
|
||||
{
|
||||
folder = [folders objectAtIndex: count];
|
||||
roles = [user rolesForObject: folder inContext: [self context]];
|
||||
calendar = [NSMutableDictionary dictionary];
|
||||
folderName = [folder nameInContainer];
|
||||
fDisplayName = [folder displayName];
|
||||
@@ -121,8 +118,6 @@ _intValueFromHex (NSString *hexString)
|
||||
[calendar setObject: isActive forKey: @"active"];
|
||||
[calendar setObject: [folder ownerInContext: context]
|
||||
forKey: @"owner"];
|
||||
[calendar setObject: [roles componentsJoinedByString: @","]
|
||||
forKey: @"roles"];
|
||||
[calendars addObject: calendar];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user