-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSWToolbar.h
37 lines (27 loc) · 929 Bytes
/
SWToolbar.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
//
// SWToolbar.h
// This file is part of the "SWApplicationSupport" project, and is distributed under the MIT License.
//
// Created by Samuel Williams on 21/03/06.
// Copyright 2006 Samuel Williams. All rights reserved.
//
#import <Cocoa/Cocoa.h>
@interface SWToolbar : NSObject {
IBOutlet NSWindow *window;
NSMutableDictionary *items;
NSToolbar *toolbar;
}
- (IBAction) toggle:(id)sender;
- (IBAction) customize:(id)sender;
- (void) addItem: (NSToolbarItem*)item;
/* Used in subclasses awakeFromNib to setup the toolbar */
- (void) setupToolbar;
- (void) addDefaultItems; /* Spaces and lines */
- (void) finishSetup;
@end
@interface NSToolbarItem (SWToolbar)
+ (NSToolbarItem*) toolbarItemWithIdentifier: (id)identifier;
- (NSToolbarItem*) setName: (id)name andDescription: (id)description;
- (NSToolbarItem*) setTarget: (id)target andAction: (SEL)action;
- (NSToolbarItem*) setImageNamed: (id)name;
@end