forked from stweil/OSXvnc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
VNCController.h
192 lines (138 loc) · 5.17 KB
/
VNCController.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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
//
// VNCController.h
// OSXvnc
//
// Created by Jonathan Gillaspie on Fri Aug 02 2002.
// Copyright (c) 2002 Redstone Software, Inc. All rights reserved.
//
#import <Cocoa/Cocoa.h>
#import "NSAuthorization.h"
@interface VNCController : NSObject {
IBOutlet NSMenuItem *startServerMenuItem;
IBOutlet NSMenuItem *stopServerMenuItem;
IBOutlet NSMenuItem *serverMenuItem;
IBOutlet NSWindow *statusWindow;
IBOutlet NSWindow *preferenceWindow;
IBOutlet NSWindow *reverseConnectionWindow;
// System Server UI
IBOutlet NSMenuItem *systemServerMenu;
IBOutlet NSWindow *systemServerWindow;
IBOutlet NSTextField *systemServerDisplayNameField;
IBOutlet NSPopUpButton *systemServerDisplayNumberField;
IBOutlet NSTextField *systemServerPortField;
IBOutlet NSMatrix *systemServerAuthenticationType;
IBOutlet NSTextField *systemServerPasswordField;
IBOutlet NSButton *systemServerLimitToLocalConnections;
IBOutlet NSButton *disableStartupButton;
IBOutlet NSButton *setStartupButton;
IBOutlet NSTextField *startupItemStatusMessageField;
// Control Panel
IBOutlet NSBox *hostNamesBox;
IBOutlet NSTextField *hostNamesField;
IBOutlet NSBox *ipAddressesBox;
IBOutlet NSMatrix *ipAddressesView;
IBOutlet NSTextField *displayNumText;
IBOutlet NSTextField *portNumText;
IBOutlet NSTextView *statusMessageField;
IBOutlet NSButton *startServerButton;
IBOutlet NSButton *stopServerButton;
// Preferences Interface
IBOutlet NSTabView *optionsTabView;
IBOutlet NSTextField *preferencesMessageTestField;
// Connection
IBOutlet NSTextField *displayNameField;
IBOutlet NSPopUpButton *displayNumberField;
IBOutlet NSTextField *portField;
IBOutlet NSMatrix *authenticationType;
IBOutlet NSTextField *passwordField;
IBOutlet NSButton *limitToLocalConnections;
// Device
IBOutlet NSButton *allowSleepCheckbox;
IBOutlet NSButton *allowDimmingCheckbox;
IBOutlet NSButton *allowScreenSaverCheckbox;
IBOutlet NSPopUpButton *keyboardLayout;
IBOutlet NSButton *swapMouseButtonsCheckbox;
// Advanced
IBOutlet NSPopUpButton *protocolVersion;
IBOutlet NSTextField *otherArguments;
IBOutlet NSButton *openGLCheckbox;
IBOutlet NSPopUpButton *keyboardEvents;
IBOutlet NSPopUpButton *eventSourcePopup;
// Sharing
IBOutlet NSMatrix *sharingMatrix;
IBOutlet NSButton *dontDisconnectCheckbox;
IBOutlet NSButton *disableRemoteEventsCheckbox;
IBOutlet NSButton *disableRichClipboardCheckbox;
IBOutlet NSButton *allowRendezvousCheckbox;
// Startup
IBOutlet NSButton *startServerOnLaunchCheckbox;
IBOutlet NSButton *terminateOnFastUserSwitch;
IBOutlet NSButton *serverKeepAliveCheckbox;
// Reverse Connections UI
IBOutlet NSTextField *connectHost;
IBOutlet NSTextField *connectPort;
IBOutlet NSTextField *reverseConnectionMessageField;
// Initial Settings UI
IBOutlet NSWindow *initialWindow;
IBOutlet NSTextField *initialPasswordText;
IBOutlet NSMatrix *initialAuthenticationType;
IBOutlet NSButton *initialDoneButton;
//int port;
BOOL systemServerIsConfigured;
BOOL alwaysShared;
BOOL neverShared;
BOOL userStopped;
BOOL relaunchServer;
BOOL doNotLoadProxy;
BOOL waitingForHostInfo;
NSTask *controller;
NSFileHandle *serverOutput;
NSString *passwordFile;
NSString *logFile;
NSAuthorization *myAuthorization;
NSDate *lastLaunchTime;
NSMutableArray *bundleArray;
NSArray *clientList;
NSString *hostName;
NSString *automaticReverseHost;
NSString *automaticReversePort;
}
- (instancetype) init;
@property (NS_NONATOMIC_IOSONLY, readonly, strong) NSWindow *window;
@property (NS_NONATOMIC_IOSONLY, readonly) int runningPortNum;
- (void) awakeFromNib;
- (void) loadUIForSystemServer;
- (void) loadUIForPort: (NSInteger) port;
- (void) loadUserDefaults: sender;
- (void) saveUserDefaults: sender;
- (IBAction) validateInitialAuthentication: sender;
- (IBAction) setInitialAuthentication: sender;
- (NSMutableArray *) formCommandLineForSystemServer: (BOOL) isSystemServer;
- (IBAction) startServer: sender;
- (IBAction) stopServer: sender;
- (void) serverStopped: (NSNotification *) aNotification;
- (IBAction) changeDisplayNumber: sender;
- (IBAction) changePort: sender;
- (IBAction) changeSharing: sender;
- (IBAction) changeAuthenticationType: sender;
- (IBAction) changePassword: sender;
- (IBAction) changeDisplayName: sender;
- (IBAction) optionChanged: sender;
- (IBAction) changeSystemServerPort: sender;
- (IBAction) changeSystemServerAuthentication: sender;
- (IBAction) reverseConnection: sender;
- (IBAction) cancelConnectHost: sender;
- (IBAction) connectHost: sender;
- (void) checkForRestart;
- (void) applicationWillTerminate: (NSNotification *) notification;
- (BOOL) validateMenuItem: (NSMenuItem *) menuItem ;
// Menu Items
- (IBAction) openFirewall:(id) sender;
- (IBAction) openLog:(id) sender;
- (IBAction) openGPL:(id) sender;
- (IBAction) openReleaseNotes:(id) sender;
- (IBAction) openFile:(id) sender;
- (IBAction) installAsService: sender;
- (IBAction) removeService: sender;
- (IBAction) terminateRequest: sender;
@end