forked from gnachman/iTerm2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ContextMenuActionPrefsController.h
47 lines (36 loc) · 1.37 KB
/
ContextMenuActionPrefsController.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
46
47
//
// ContextMenuActionPrefsController.h
// iTerm
//
// Created by George Nachman on 11/18/11.
// Copyright 2011 Georgetech. All rights reserved.
//
#import <Cocoa/Cocoa.h>
typedef enum {
kOpenFileContextMenuAction,
kOpenUrlContextMenuAction,
kRunCommandContextMenuAction,
kRunCoprocessContextMenuAction
} ContextMenuActions;
@protocol ContextMenuActionPrefsDelegate
- (void)contextMenuActionsChanged:(NSArray *)newActions;
@end
@interface ContextMenuActionPrefsController : NSWindowController <NSWindowDelegate, NSTableViewDelegate, NSTableViewDataSource> {
IBOutlet NSTableView *tableView_;
IBOutlet NSTableColumn *titleColumn_;
IBOutlet NSTableColumn *actionColumn_;
IBOutlet NSTableColumn *parameterColumn_;
NSMutableArray *model_;
NSObject<ContextMenuActionPrefsDelegate> *delegate_;
BOOL hasSelection_;
}
@property (nonatomic, assign) NSObject<ContextMenuActionPrefsDelegate> *delegate;
@property (nonatomic, assign) BOOL hasSelection;
+ (ContextMenuActions)actionForActionDict:(NSDictionary *)dict;
+ (NSString *)titleForActionDict:(NSDictionary *)dict withCaptureComponents:(NSArray *)components;
+ (NSString *)parameterForActionDict:(NSDictionary *)dict withCaptureComponents:(NSArray *)components;
- (IBAction)ok:(id)sender;
- (void)setActions:(NSArray *)newActions;
- (IBAction)add:(id)sender;
- (IBAction)remove:(id)sender;
@end