| 1 |
#import "MainController.h" |
| 2 |
#import "DummyOutlineDataSource.h" |
| 3 |
#import "ToolbarItemSource.h" |
| 4 |
#import "IconedCell.h" |
| 5 |
#import "ComposeToolbarItemSource.h" |
| 6 |
|
| 7 |
@implementation MainController |
| 8 |
-(void)awakeFromNib{ |
| 9 |
DummyOutlineDataSource *ds; |
| 10 |
NSToolbar *toolbar; |
| 11 |
ToolbarItemSource *toolbarItemSource; |
| 12 |
ComposeToolbarItemSource *composeToolbarItemSource; |
| 13 |
|
| 14 |
ds = [[DummyOutlineDataSource alloc] init]; |
| 15 |
[folderTree setDataSource:ds]; |
| 16 |
|
| 17 |
toolbar = [[NSToolbar alloc] initWithIdentifier:@"myToolBar"]; |
| 18 |
toolbarItemSource = [[ToolbarItemSource alloc] initWithController:self]; |
| 19 |
[toolbar setDelegate:toolbarItemSource]; |
| 20 |
[window setToolbar:toolbar]; |
| 21 |
[toolbar release]; |
| 22 |
|
| 23 |
toolbar = [[NSToolbar alloc] initWithIdentifier:@"componentToolBar"]; |
| 24 |
composeToolbarItemSource = [[ComposeToolbarItemSource alloc] initWithController:self]; |
| 25 |
[toolbar setDelegate:composeToolbarItemSource]; |
| 26 |
[composeWindow setToolbar:toolbar]; |
| 27 |
[toolbar release]; |
| 28 |
|
| 29 |
} |
| 30 |
- (void)applicationDidFinishLaunching:(NSNotification*)notif |
| 31 |
{ |
| 32 |
NSTableColumn* tableColumn; |
| 33 |
IconedCell* iconedCell; |
| 34 |
// �t�H���_�c���[���A�A�C�R��+�������\���������������ACell�����X���s���B |
| 35 |
tableColumn = [folderTree tableColumnWithIdentifier:@"folderview"]; |
| 36 |
iconedCell = [[[IconedCell alloc] init] autorelease]; |
| 37 |
[tableColumn setDataCell:iconedCell]; |
| 38 |
} |
| 39 |
-(IBAction)createNewMessage:(id)sender{ |
| 40 |
[composeWindow makeKeyAndOrderFront:nil]; |
| 41 |
} |
| 42 |
-(IBAction)findMessage:(id)sender{ |
| 43 |
[searchWindow makeKeyAndOrderFront:nil]; |
| 44 |
} |
| 45 |
|
| 46 |
@end |