5
* Copyright (c) 2001 Andreas Monitzer. All Rights Reserved.
6
* Copyright (c) 2002-2003 Torrey T. Lyons. All Rights Reserved.
8
* Permission is hereby granted, free of charge, to any person obtaining a
9
* copy of this software and associated documentation files (the
10
* "Software"), to deal in the Software without restriction, including
11
* without limitation the rights to use, copy, modify, merge, publish,
12
* distribute, sublicense, and/or sell copies of the Software, and to
13
* permit persons to whom the Software is furnished to do so, subject to
14
* the following conditions:
16
* The above copyright notice and this permission notice shall be included
17
* in all copies or substantial portions of the Software.
19
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
20
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
21
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
22
* IN NO EVENT SHALL THE ABOVE LISTED COPYRIGHT HOLDER(S) BE LIABLE FOR ANY
23
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
24
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
25
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
27
* Except as contained in this notice, the name(s) of the above copyright
28
* holders shall not be used in advertising or otherwise to promote the
29
* sale, use or other dealings in this Software without prior written
32
/* $XFree86: xc/programs/Xserver/hw/darwin/quartz/XServer.h,v 1.8 2003/01/23 00:34:26 torrey Exp $ */
38
#import <Cocoa/Cocoa.h>
40
@interface XServer : NSObject {
43
NSRecursiveLock *serverLock;
45
BOOL rootlessMenuBarVisible;
51
BOOL sendServerEvents;
55
IBOutlet NSWindow *modeWindow;
56
IBOutlet NSButton *startupModeButton;
57
IBOutlet NSButton *startFullScreenButton;
58
IBOutlet NSButton *startRootlessButton;
59
IBOutlet NSWindow *helpWindow;
60
IBOutlet NSButton *startupHelpButton;
61
IBOutlet NSPanel *switchWindow;
66
- (BOOL)translateEvent:(NSEvent *)anEvent;
67
- (BOOL)getMousePosition:(xEvent *)xe fromEvent:(NSEvent *)anEvent;
69
+ (void)append:(NSString *)value toEnv:(NSString *)name;
73
- (BOOL)startXClients;
76
- (void)showServer:(BOOL)show;
77
- (void)forceShowServer:(BOOL)show;
78
- (void)setRootClip:(BOOL)enable;
79
- (void)readPasteboard;
80
- (void)writePasteboard;
82
- (void)sendXEvent:(xEvent *)xe;
83
- (void)sendShowHide:(BOOL)show;
84
- (void)clientProcessDone:(int)clientStatus;
86
// Aqua interface actions
87
- (IBAction)startFullScreen:(id)sender;
88
- (IBAction)startRootless:(id)sender;
89
- (IBAction)closeHelpAndShow:(id)sender;
90
- (IBAction)showAction:(id)sender;
92
// NSApplication delegate
93
- (NSApplicationTerminateReply)applicationShouldTerminate:(NSApplication *)sender;
94
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification;
95
- (BOOL)applicationShouldHandleReopen:(NSApplication *)theApplication hasVisibleWindows:(BOOL)flag;
96
- (void)applicationWillResignActive:(NSNotification *)aNotification;
97
- (void)applicationWillBecomeActive:(NSNotification *)aNotification;
100
- (void)handlePortMessage:(NSPortMessage *)portMessage;