Refactor use of pithos objects to accommodate
[pithos-macos] / pithos-macos / PithosPreferencesController.h
index 4017bbc..262e418 100644 (file)
@@ -2,7 +2,7 @@
 //  PithosPreferencesController.h
 //  pithos-macos
 //
-// Copyright 2011 GRNET S.A. All rights reserved.
+// Copyright 2011-2013 GRNET S.A. All rights reserved.
 //
 // Redistribution and use in source and binary forms, with or
 // without modification, are permitted provided that the following
 // or implied, of GRNET S.A.
 
 #import <Cocoa/Cocoa.h>
-@class PithosBrowserController;
+@class PithosAccount;
+@class PithosEmptyNode;
 
-@interface PithosPreferencesController : NSWindowController <NSWindowDelegate> {
-    PithosBrowserController *pithosBrowserController;
+@interface PithosPreferencesController : NSWindowController <NSWindowDelegate, NSOutlineViewDataSource> {
+    PithosAccount *selectedPithosAccount;
     
-    NSTextField *authenticationUserTextField;
-    NSTextField *authenticationTokenTextField;
-    NSButton *authenticationRenewCheckBox;
+    IBOutlet NSArrayController *accountsArrayController;
     
-    NSDictionaryController *groupsDictionaryController;
-    NSDictionaryController *selectedGroupMembersDictionaryController;
+    BOOL accountRemoveEnable;
+    
+    NSString *authURLString;
+    BOOL manual;
+    NSString *pithosObjectStoreURLString;
+    NSString *astakosAccountURLString;
+    NSString *astakosWebloginURLString;
+    NSString *authUser;
+    NSString *authToken;
+    NSString *displayname;
+    BOOL ignoreSSLErrors;
+    BOOL retrieveTokenEnable;
+    BOOL authorizationSaveEnable;
+    BOOL authorizationCancelEnable;
+    
+    BOOL syncActive;
+    BOOL syncSkipHidden;
+    NSString *syncDirectoryPath;
+    NSMutableDictionary *syncAccountsDictionary;
+    BOOL syncApplyEnable;
+    BOOL syncCancelEnable;
+    IBOutlet NSOutlineView *syncAccountsOutlineView;
+    PithosEmptyNode *syncAccountsMyAccountNode;
+    NSMutableDictionary *syncAccountsRootFilesNodes;
+    
+    IBOutlet NSDictionaryController *groupsDictionaryController;
+    IBOutlet NSDictionaryController *selectedGroupMembersDictionaryController;
 }
 
-@property (nonatomic, assign) IBOutlet PithosBrowserController *pithosBrowserController;
+@property (nonatomic, strong) PithosAccount *selectedPithosAccount;
+
+@property (nonatomic, assign) BOOL accountRemoveEnable;
 
-@property (nonatomic, assign) IBOutlet NSTextField *authenticationUserTextField;
-@property (nonatomic, assign) IBOutlet NSTextField *authenticationTokenTextField;
-@property (nonatomic, assign) IBOutlet NSButton *authenticationRenewCheckBox;
+@property (nonatomic, copy) NSString *authURLString;
+@property (nonatomic, assign) BOOL manual;
+@property (nonatomic, copy) NSString *pithosObjectStoreURLString;
+@property (nonatomic, copy) NSString *astakosAccountURLString;
+@property (nonatomic, copy) NSString *astakosWebloginURLString;
+@property (nonatomic, copy) NSString *authUser;
+@property (nonatomic, copy) NSString *authToken;
+@property (nonatomic, copy) NSString *displayname;
+@property (nonatomic, assign) BOOL ignoreSSLErrors;
+@property (nonatomic, assign) BOOL retrieveTokenEnable;
+@property (nonatomic, assign) BOOL authorizationSaveEnable;
+@property (nonatomic, assign) BOOL authorizationCancelEnable;
 
-@property (nonatomic, assign) IBOutlet NSDictionaryController *groupsDictionaryController;
-@property (nonatomic, assign) IBOutlet NSDictionaryController *selectedGroupMembersDictionaryController;
+@property (nonatomic, assign) BOOL syncActive;
+@property (nonatomic, assign) BOOL syncSkipHidden;
+@property (nonatomic, copy) NSString *syncDirectoryPath;
+@property (nonatomic, copy) NSMutableDictionary *syncAccountsDictionary;
+@property (nonatomic, assign) BOOL syncApplyEnable;
+@property (nonatomic, assign) BOOL syncCancelEnable;
+@property (nonatomic, strong) NSMutableDictionary *syncAccountsRootFilesNodes;
 
+//- (IBAction)toolbarItemSelected:(id)sender;
 
-- (IBAction)toolbarItemSelected:(id)sender;
+- (IBAction)addAccount:(id)sender;
+- (IBAction)removeAccount:(id)sender;
+- (IBAction)retrieveToken:(id)sender;
+- (IBAction)authorizationSave:(id)sender;
+- (IBAction)authorizationCancel:(id)sender;
+- (IBAction)syncApply:(id)sender;
+- (IBAction)syncCancel:(id)sender;
+- (IBAction)syncRefresh:(id)sender;
+- (IBAction)groupsApply:(id)sender;
+- (IBAction)groupsRevert:(id)sender;
 
-- (IBAction)authenticationLogin:(id)sender;
 
 @end