Support sudden and automatic termination.
[enjoyable.git] / NJMappingsController.h
1 //
2 // NJMappingsController.h
3 // Enjoy
4 //
5 // Created by Sam McCall on 4/05/09.
6 // Copyright 2009 University of Otago. All rights reserved.
7 //
8
9 @class NJMapping;
10 @class NJOutputController;
11
12 @interface NJMappingsController : NSObject <NSTableViewDataSource,
13 NSTableViewDelegate,
14 NSOpenSavePanelDelegate,
15 NSPopoverDelegate,
16 NSFastEnumeration>
17 {
18 IBOutlet NSButton *removeButton;
19 IBOutlet NSTableView *tableView;
20 IBOutlet NJOutputController *outputController;
21 IBOutlet NSButton *popoverActivate;
22 IBOutlet NSPopover *popover;
23 }
24
25 @property (nonatomic, readonly) NJMapping *currentMapping;
26 @property (nonatomic, readonly) NSArray *mappings;
27
28 - (NJMapping *)objectForKeyedSubscript:(NSString *)name;
29 - (NJMapping *)objectAtIndexedSubscript:(NSUInteger)idx;
30 - (void)activateMapping:(NJMapping *)mapping;
31 - (void)activateMappingForProcess:(NSString *)processName;
32 - (void)save;
33 - (void)load;
34
35 - (IBAction)mappingPressed:(id)sender;
36 - (IBAction)addPressed:(id)sender;
37 - (IBAction)removePressed:(id)sender;
38 - (IBAction)importPressed:(id)sender;
39 - (IBAction)exportPressed:(id)sender;
40
41 @end