diff --git a/ChangeLog b/ChangeLog index a379bb64b..3e2a6bc81 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,22 @@ +2007-11-07 Wolfgang Sourdeau + + * SoObjects/SOGo/SOGoParentFolder.m: no longer a subclass of + SOGoObject, but of SOGoFolder instead. + + * SoObjects/SOGo/SOGoUserFolder.m: no longer a subclass of + SOGoGCSFolder, but of SOGoFolder instead. + + * SoObjects/Appointments/SOGoAppointmentFolder.m + ([SOGoAppointmentFolder -lookupCalendarFolderForUID:uid]): fixed + to take the new SOGoParentFolder class into account. Also, create + the personal folder if it doesn't exist. + + * SoObjects/SOGo/SOGoFolder.[hm]: new class module implementing + the parent of all SOGo containers. + + * SoObjects/SOGo/SOGoGCSFolder.[hm]: SOGoFolder class renamed to + SOGoGCSFolder. + 2007-11-06 Wolfgang Sourdeau * UI/MailerUI/UIxMailToSelection.m ([UIxMailToSelection diff --git a/SoObjects/Appointments/SOGoAppointmentFolder.h b/SoObjects/Appointments/SOGoAppointmentFolder.h index 5f5ee41d6..27a24c9ad 100644 --- a/SoObjects/Appointments/SOGoAppointmentFolder.h +++ b/SoObjects/Appointments/SOGoAppointmentFolder.h @@ -36,7 +36,7 @@ create two different vevent-files with the same uid in the store. */ -#import "SOGo/SOGoFolder.h" +#import "SOGo/SOGoGCSFolder.h" @class NSArray; @class NSCalendarDate; @@ -47,7 +47,7 @@ @class GCSFolder; #import -@interface SOGoAppointmentFolder : SOGoFolder +@interface SOGoAppointmentFolder : SOGoGCSFolder { NSTimeZone *timeZone; NSMutableDictionary *uidToFilename; diff --git a/SoObjects/Appointments/SOGoFreeBusyObject.h b/SoObjects/Appointments/SOGoFreeBusyObject.h index f58039eb2..24fcb14b6 100644 --- a/SoObjects/Appointments/SOGoFreeBusyObject.h +++ b/SoObjects/Appointments/SOGoFreeBusyObject.h @@ -24,7 +24,7 @@ #ifndef __Appointments_SOGoFreeBusyObject_H_ #define __Appointments_SOGoFreeBusyObject_H_ -#include +#include /* SOGoFreeBusyObject @@ -34,7 +34,7 @@ @class NSArray, NSCalendarDate; -@interface SOGoFreeBusyObject : SOGoContentObject +@interface SOGoFreeBusyObject : SOGoObject { } diff --git a/SoObjects/Contacts/NSObject+CardDAV.m b/SoObjects/Contacts/NSObject+CardDAV.m index 1a1df88b0..2fed99dcb 100644 --- a/SoObjects/Contacts/NSObject+CardDAV.m +++ b/SoObjects/Contacts/NSObject+CardDAV.m @@ -20,17 +20,18 @@ * Boston, MA 02111-1307, USA. */ -#import "SOGoContactFolder.h" -#import "SOGoContactGCSEntry.h" - -#import #import -#import -#import -#import + #import #import #import +#import +#import +#import +#import + +#import "SOGoContactFolder.h" +#import "SOGoContactGCSEntry.h" @implementation NSObject (CardDAV) @@ -42,7 +43,7 @@ NSDictionary *currentFilter, *contact; NSEnumerator *contacts; NSString *baseURL; - id o; + SOGoObject *o; o = (id)self; baseURL = [o baseURLInContext: context]; diff --git a/SoObjects/Contacts/SOGoContactLDAPFolder.m b/SoObjects/Contacts/SOGoContactLDAPFolder.m index 13772500e..65e4d11c8 100644 --- a/SoObjects/Contacts/SOGoContactLDAPFolder.m +++ b/SoObjects/Contacts/SOGoContactLDAPFolder.m @@ -43,8 +43,6 @@ @class WOContext; - - @implementation SOGoContactLDAPFolder - (void) appendObject: (NSDictionary *) object @@ -59,7 +57,8 @@ componentClass = [SOGoContactLDIFEntry class]; - component = [componentClass contactEntryWithName: name withLDIFEntry: object inContainer: self]; + component = [componentClass contactEntryWithName: name + withLDIFEntry: object inContainer: self]; [r appendContentString: @" \r\n"]; [r appendContentString: @" "]; diff --git a/SoObjects/Mailer/SOGoMailAccount.m b/SoObjects/Mailer/SOGoMailAccount.m index f702e21fb..4f2f59110 100644 --- a/SoObjects/Mailer/SOGoMailAccount.m +++ b/SoObjects/Mailer/SOGoMailAccount.m @@ -479,14 +479,16 @@ static NSString *otherUsersFolderName = @""; // TODO: add English default s = [self nameInContainer]; r = [s rangeOfString:@"@"]; - if (r.length > 0) { - login = [s substringToIndex:r.location]; - host = [s substringFromIndex:(r.location + r.length)]; - } - else { - login = nil; - host = s; - } + if (r.length > 0) + { + login = [s substringToIndex:r.location]; + host = [s substringFromIndex:(r.location + r.length)]; + } + else + { + login = nil; + host = s; + } r = [host rangeOfString:@"."]; if (r.length > 0) diff --git a/SoObjects/SOGo/SOGoContentObject.m b/SoObjects/SOGo/SOGoContentObject.m index 00ed0779e..442513663 100644 --- a/SoObjects/SOGo/SOGoContentObject.m +++ b/SoObjects/SOGo/SOGoContentObject.m @@ -29,7 +29,7 @@ #import #import -#import "SOGoFolder.h" +#import "SOGoGCSFolder.h" #import "SOGoUser.h" #import "SOGoPermissions.h" #import "SOGoContentObject.h" diff --git a/SoObjects/SOGo/SOGoObject.m b/SoObjects/SOGo/SOGoObject.m index abb9acb1f..18aec4014 100644 --- a/SoObjects/SOGo/SOGoObject.m +++ b/SoObjects/SOGo/SOGoObject.m @@ -1017,4 +1017,11 @@ static BOOL kontactGroupDAV = YES; return ms; } +- (NSString *) loggingPrefix +{ + return [NSString stringWithFormat:@"<0x%08X[%@]:%@>", + self, NSStringFromClass([self class]), + [self nameInContainer]]; +} + @end /* SOGoObject */ diff --git a/UI/Common/UIxFolderActions.h b/UI/Common/UIxFolderActions.h index 8794bbeab..96b6cbc15 100644 --- a/UI/Common/UIxFolderActions.h +++ b/UI/Common/UIxFolderActions.h @@ -31,11 +31,11 @@ @class NSMutableDictionary; @class LDAPUserManager; -@class SOGoFolder; +@class SOGoGCSFolder; @interface UIxFolderActions : WODirectAction { - SOGoFolder *clientObject; + SOGoGCSFolder *clientObject; LDAPUserManager *um; NSUserDefaults *ud; NSString *owner; diff --git a/UI/Contacts/UIxContactEditor.m b/UI/Contacts/UIxContactEditor.m index 6f3954112..40842b648 100644 --- a/UI/Contacts/UIxContactEditor.m +++ b/UI/Contacts/UIxContactEditor.m @@ -581,7 +581,7 @@ Update: remember that there are group folders as well. */ NSString *uri, *objectId, *nextMethod; - id co; + SOGoObject *co; co = [self clientObject]; if ([co respondsToSelector: @selector (globallyUniqueObjectId)]) diff --git a/UI/MainUI/product.plist b/UI/MainUI/product.plist index 9c0bba206..664e4cf52 100644 --- a/UI/MainUI/product.plist +++ b/UI/MainUI/product.plist @@ -49,7 +49,7 @@ }; }; SOGoParentFolder = { - superclass = "SOGoObject"; + superclass = "SOGoFolder"; protectedBy = "Access Contents Information"; defaultRoles = { "Access Contents Information" = ( "Authenticated" );