2004-10-06 Helge Hess <helge.hess@opengroupware.org>
+ * started SOGoDraftsFolder (v0.9.27)
+
* v0.9.26
* SOGoMailConnectionEntry.m: added caching of sorted UIDs sets
SOGoMailFolder.m \
SOGoMailObject.m \
SOGoMailBodyPart.m \
+ \
+ SOGoDraftsFolder.m \
Mailer_RESOURCE_FILES += \
Version \
--- /dev/null
+/*
+ Copyright (C) 2004 SKYRIX Software AG
+
+ This file is part of OpenGroupware.org.
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+// $Id$
+
+#ifndef __Mailer_SOGoDraftsFolder_H__
+#define __Mailer_SOGoDraftsFolder_H__
+
+#include <SOGo/SoObjects/Mailer/SOGoMailBaseObject.h>
+
+/*
+ SOGoDraftsFolder
+ Parent object: SOGoMailAccount
+ Child objects: SOGoMailFolder
+
+ The SOGoDraftsFolder is used for composing new messages.
+*/
+
+@interface SOGoDraftsFolder : SOGoMailBaseObject
+{
+}
+
+@end
+
+#endif /* __Mailer_SOGoDraftsFolder_H__ */
--- /dev/null
+/*
+ Copyright (C) 2004 SKYRIX Software AG
+
+ This file is part of OpenGroupware.org.
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+// $Id$
+
+#include "SOGoDraftsFolder.h"
+#include "common.h"
+
+@implementation SOGoDraftsFolder
+
+@end /* SOGoDraftsFolder */
#include "SOGoMailAccount.h"
#include "SOGoMailFolder.h"
+#include "SOGoDraftsFolder.h"
#include "common.h"
@implementation SOGoMailAccount
/* listing the available folders */
- (NSArray *)toManyRelationshipKeys {
- // TODO: hardcoded, if we want to support shared folders, need to change */
- return [NSArray arrayWithObjects:@"INBOX", nil];
+ // TODO: hardcoded, if we want to support shared fldrs, this needs to change
+ return [NSArray arrayWithObjects:@"INBOX", @"Drafts", nil];
}
/* hierarchy */
inContainer:self] autorelease];
}
+- (id)lookupDraftsFolder:(NSString *)_key inContext:(id)_ctx {
+ return [[[SOGoDraftsFolder alloc] initWithName:_key
+ inContainer:self] autorelease];
+}
+
- (id)lookupName:(NSString *)_key inContext:(id)_ctx acquire:(BOOL)_flag {
id obj;
if ((obj = [super lookupName:_key inContext:_ctx acquire:NO]) != nil)
return obj;
+ if ([_key isEqualToString:@"Drafts"]) {
+ if ((obj = [self lookupDraftsFolder:_key inContext:_ctx]) != nil)
+ return obj;
+ }
+
if ((obj = [self lookupImap4Folder:_key inContext:_ctx]) != nil)
return obj;
uids = [entry cachedUIDsForURL:_url qualifier:_qualifier sortOrdering:_so];
if (uids != nil) {
- [self logWithFormat:@"REUSE UID CACHE!"];
+ if (debugCache) [self logWithFormat:@"reusing uid cache!"];
return [uids isNotNull] ? uids : nil;
}
# $Id$
-SUBMINOR_VERSION:=26
+SUBMINOR_VERSION:=27