forked from cocoabits/MASPreferences
-
Notifications
You must be signed in to change notification settings - Fork 1
/
MASPreferencesWindowController.h
45 lines (37 loc) · 1.77 KB
/
MASPreferencesWindowController.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
//
// You create an application Preferences window using code like this:
// _preferencesWindowController = [[MASPreferencesWindowController alloc] initWithViewControllers:controllers
// title:title]
//
// To open the Preferences window:
// [_preferencesWindowController showWindow:sender]
//
#import "MASPreferencesViewController.h"
extern NSString *const kMASPreferencesWindowControllerDidChangeViewNotification;
__attribute__((__visibility__("default")))
#if MAC_OS_X_VERSION_MAX_ALLOWED > MAC_OS_X_VERSION_10_5
@interface MASPreferencesWindowController : NSWindowController <NSToolbarDelegate, NSWindowDelegate>
#else
@interface MASPreferencesWindowController : NSWindowController
#endif
{
@private
NSMutableArray *_viewControllers;
NSMutableDictionary *_minimumViewRects;
NSString *_title;
NSViewController <MASPreferencesViewController> *_selectedViewController;
IBOutlet NSToolbar *toolbar;
}
@property (nonatomic, readonly) NSMutableArray *viewControllers;
@property (nonatomic, readonly) NSUInteger indexOfSelectedController;
@property (nonatomic, readonly, retain) NSViewController <MASPreferencesViewController> *selectedViewController;
@property (nonatomic, readonly) NSString *title;
@property (nonatomic, assign) IBOutlet NSToolbar *toolbar;
- (id)initWithViewControllers:(NSArray *)viewControllers;
- (id)initWithViewControllers:(NSArray *)viewControllers title:(NSString *)title;
- (void)addViewController:(NSViewController <MASPreferencesViewController> *) viewController;
- (void)selectControllerAtIndex:(NSUInteger)controllerIndex;
- (void)selectControllerWithIdentifier:(NSString *)identifier;
- (IBAction)goNextTab:(id)sender;
- (IBAction)goPreviousTab:(id)sender;
@end