mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-10-06 04:20:33 +00:00
Now able to set Active Sync metadata in the user settings
This commit is contained in:
@@ -1,8 +1,6 @@
|
|||||||
/* SOGoUserSettings.h - this file is part of SOGo
|
/* SOGoUserSettings.h - this file is part of SOGo
|
||||||
*
|
*
|
||||||
* Copyright (C) 2009 Inverse inc.
|
* Copyright (C) 2009-2013 Inverse inc.
|
||||||
*
|
|
||||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
|
||||||
*
|
*
|
||||||
* This file is free software; you can redistribute it and/or modify
|
* This file is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@@ -26,6 +24,7 @@
|
|||||||
#import "SOGoDefaultsSource.h"
|
#import "SOGoDefaultsSource.h"
|
||||||
|
|
||||||
@class NSArray;
|
@class NSArray;
|
||||||
|
@class NSMutableDictionary;
|
||||||
@class NSString;
|
@class NSString;
|
||||||
|
|
||||||
@interface SOGoUserSettings : SOGoDefaultsSource
|
@interface SOGoUserSettings : SOGoDefaultsSource
|
||||||
@@ -35,6 +34,13 @@
|
|||||||
- (NSArray *) subscribedCalendars;
|
- (NSArray *) subscribedCalendars;
|
||||||
- (NSArray *) subscribedAddressBooks;
|
- (NSArray *) subscribedAddressBooks;
|
||||||
|
|
||||||
|
|
||||||
|
/* Microsoft Active Sync support */
|
||||||
|
- (void) setMicrosoftActiveSyncMetadata: (NSDictionary *) theMetadata
|
||||||
|
forDevice: (NSString *) theDeviceID;
|
||||||
|
|
||||||
|
- (NSMutableDictionary *) microsoftActiveSyncMetadataForDevice: (NSString *) theDevice;
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
#endif /* SOGOUSERSETTINGS_H */
|
#endif /* SOGOUSERSETTINGS_H */
|
||||||
|
|||||||
@@ -1,8 +1,6 @@
|
|||||||
/* SOGoUserSettings.m - this file is part of SOGo
|
/* SOGoUserSettings.m - this file is part of SOGo
|
||||||
*
|
*
|
||||||
* Copyright (C) 2009-2011 Inverse inc.
|
* Copyright (C) 2009-2013 Inverse inc.
|
||||||
*
|
|
||||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
|
||||||
*
|
*
|
||||||
* This file is free software; you can redistribute it and/or modify
|
* This file is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@@ -71,4 +69,28 @@ static Class SOGoUserProfileKlass = Nil;
|
|||||||
return [self _subscribedFoldersForModule: @"Contacts"];
|
return [self _subscribedFoldersForModule: @"Contacts"];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Microsoft Active Sync support */
|
||||||
|
- (void) setMicrosoftActiveSyncMetadata: (NSDictionary *) theMetadata
|
||||||
|
forDevice: (NSString *) theDeviceID
|
||||||
|
{
|
||||||
|
if (theMetadata && theDeviceID)
|
||||||
|
{
|
||||||
|
NSMutableDictionary *d;
|
||||||
|
|
||||||
|
d = [NSMutableDictionary dictionaryWithDictionary: [self dictionaryForKey: @"SOGoMicrosoftActiveSyncMetadata"]];
|
||||||
|
[d setObject: theMetadata forKey: theDeviceID];
|
||||||
|
|
||||||
|
[self setObject: d forKey: @"SOGoMicrosoftActiveSyncMetadata"];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
- (NSMutableDictionary *) microsoftActiveSyncMetadataForDevice: (NSString *) theDevice
|
||||||
|
{
|
||||||
|
NSDictionary *d;
|
||||||
|
|
||||||
|
d = [self dictionaryForKey: @"SOGoMicrosoftActiveSyncMetadata"];
|
||||||
|
|
||||||
|
return [NSMutableDictionary dictionaryWithDictionary: [d objectForKey: theDevice]];
|
||||||
|
}
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|||||||
Reference in New Issue
Block a user