Monotone-Parent: e89a46b719b80b6d34d9e7a110754e60344dd669

Monotone-Revision: bc440bc0c22c32437dc043e9566760ddd30fea67

Monotone-Author: wsourdeau@inverse.ca
Monotone-Date: 2012-01-26T19:56:24
Monotone-Branch: ca.inverse.sogo
maint-2.0.2
Wolfgang Sourdeau 2012-01-26 19:56:24 +00:00
parent 83709fd892
commit ada80546fd
4 changed files with 22 additions and 1 deletions

View File

@ -1,5 +1,10 @@
2012-01-26 Wolfgang Sourdeau <wsourdeau@inverse.ca>
* OpenChange/MAPIStoreFolder.m (supportsSubFolders): new
overridable method that returns whether the current folder can
contain subfolders, nowithstanding the right of the current user
to create or access them.
* OpenChange/MAPIStoreSOGo.m (sogo_backend_list_contexts): new
backend method.

View File

@ -295,4 +295,9 @@ static NSString *MAPIStoreRightFolderContact = @"RightsFolderContact";
return [self _testRoleForActiveUser: MAPIStoreRightCreateSubfolders];
}
- (BOOL) supportsSubFolders
{
return YES;
}
@end

View File

@ -1141,7 +1141,8 @@ Class NSExceptionK, MAPIStoreFAIMessageK, MAPIStoreMessageTableK, MAPIStoreFAIMe
access |= 0x02;
if (userIsOwner || [self subscriberCanDeleteMessages])
access |= 0x04;
if (userIsOwner || [self subscriberCanCreateSubFolders])
if ((userIsOwner || [self subscriberCanCreateSubFolders])
&& [self supportsSubFolders])
access |= 0x08;
if (userIsOwner || [self subscriberCanCreateMessages])
access |= 0x10;
@ -1595,4 +1596,9 @@ Class NSExceptionK, MAPIStoreFAIMessageK, MAPIStoreMessageTableK, MAPIStoreFAIMe
return NO;
}
- (BOOL) supportsSubFolders
{
return NO;
}
@end

View File

@ -1179,6 +1179,11 @@ _parseCOPYUID (NSString *line, NSArray **destUIDsP)
return childFolder;
}
- (BOOL) supportsSubFolders
{
return !usesAltNameSpace;
}
@end
@implementation MAPIStoreSentItemsFolder : MAPIStoreMailFolder