Monotone-Parent: 27dc3c974ed1585b54e4d58d5ab193527645b95b
Monotone-Revision: dc04eb7c603c80427d9ac15ee5747b6d6ed6ff48 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2011-02-07T15:27:22 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
parent
bfea0c43b9
commit
c0974b8f2e
|
@ -4,6 +4,10 @@
|
|||
MAPIStoreMailContext and make use of the trash folder as module
|
||||
folder.
|
||||
|
||||
* OpenChange/MAPIStoreDraftsContext.m: now a subclass of
|
||||
MAPIStoreMailContext and make use of the drafts folder as module
|
||||
folder.
|
||||
|
||||
2011-02-06 Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
|
||||
* OpenChange/MAPIStoreMailMessageTable.m (-setSordOrder):
|
||||
|
|
|
@ -23,9 +23,9 @@
|
|||
#ifndef MAPISTOREDRAFTSCONTEXT_H
|
||||
#define MAPISTOREDRAFTSCONTEXT_H
|
||||
|
||||
#import "MAPIStoreFSBaseContext.h"
|
||||
#import "MAPIStoreMailContext.h"
|
||||
|
||||
@interface MAPIStoreDraftsContext : MAPIStoreFSBaseContext
|
||||
@interface MAPIStoreDraftsContext : MAPIStoreMailContext
|
||||
|
||||
@end
|
||||
|
||||
|
|
|
@ -22,8 +22,15 @@
|
|||
|
||||
#import <Foundation/NSString.h>
|
||||
|
||||
#import <NGObjWeb/WOContext+SoObjects.h>
|
||||
|
||||
#import "MAPIStoreMapping.h"
|
||||
|
||||
#import <Mailer/SOGoMailAccount.h>
|
||||
|
||||
#import "MAPIApplication.h"
|
||||
#import "MAPIStoreAuthenticator.h"
|
||||
|
||||
#import "MAPIStoreDraftsContext.h"
|
||||
|
||||
@implementation MAPIStoreDraftsContext
|
||||
|
@ -39,4 +46,40 @@
|
|||
withID: 0x1e0001];
|
||||
}
|
||||
|
||||
- (void) setupModuleFolder
|
||||
{
|
||||
SOGoUserFolder *userFolder;
|
||||
SOGoMailAccounts *accountsFolder;
|
||||
SOGoMailAccount *accountFolder;
|
||||
SOGoFolder *currentContainer;
|
||||
|
||||
userFolder = [SOGoUserFolder objectWithName: [authenticator username]
|
||||
inContainer: MAPIApp];
|
||||
[parentFoldersBag addObject: userFolder];
|
||||
// [self logWithFormat: @"userFolder: %@", userFolder];
|
||||
[woContext setClientObject: userFolder];
|
||||
|
||||
accountsFolder = [userFolder lookupName: @"Mail"
|
||||
inContext: woContext
|
||||
acquire: NO];
|
||||
[parentFoldersBag addObject: accountsFolder];
|
||||
// [self logWithFormat: @"accountsFolder: %@", accountsFolder];
|
||||
[woContext setClientObject: accountsFolder];
|
||||
|
||||
accountFolder = [accountsFolder lookupName: @"0"
|
||||
inContext: woContext
|
||||
acquire: NO];
|
||||
[parentFoldersBag addObject: accountFolder];
|
||||
[woContext setClientObject: accountFolder];
|
||||
|
||||
moduleFolder = [accountFolder draftsFolderInContext: nil];
|
||||
[moduleFolder retain];
|
||||
currentContainer = [moduleFolder container];
|
||||
while (currentContainer != (SOGoFolder *) accountFolder)
|
||||
{
|
||||
[parentFoldersBag addObject: currentContainer];
|
||||
currentContainer = [currentContainer container];
|
||||
}
|
||||
}
|
||||
|
||||
@end
|
||||
|
|
Loading…
Reference in a new issue