VirtualBox

source: vbox/trunk/src/VBox/Additions/x11/x11include/xorg-server-1.6.99-20090831/dixstruct.h@ 32915

Last change on this file since 32915 was 22658, checked in by vboxsync, 15 years ago

export Xorg 1.6.99 headers to OSE

  • Property svn:eol-style set to native
File size: 5.6 KB
Line 
1/***********************************************************
2Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.
3
4 All Rights Reserved
5
6Permission to use, copy, modify, and distribute this software and its
7documentation for any purpose and without fee is hereby granted,
8provided that the above copyright notice appear in all copies and that
9both that copyright notice and this permission notice appear in
10supporting documentation, and that the name of Digital not be
11used in advertising or publicity pertaining to distribution of the
12software without specific, written prior permission.
13
14DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
15ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
16DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
17ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
18WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
19ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
20SOFTWARE.
21
22******************************************************************/
23
24#ifndef DIXSTRUCT_H
25#define DIXSTRUCT_H
26
27#include "dix.h"
28#include "resource.h"
29#include "cursor.h"
30#include "gc.h"
31#include "pixmap.h"
32#include "privates.h"
33#include <X11/Xmd.h>
34
35/*
36 * direct-mapped hash table, used by resource manager to store
37 * translation from client ids to server addresses.
38 */
39
40extern _X_EXPORT CallbackListPtr ClientStateCallback;
41
42typedef struct {
43 ClientPtr client;
44 xConnSetupPrefix *prefix;
45 xConnSetup *setup;
46} NewClientInfoRec;
47
48typedef void (*ReplySwapPtr) (
49 ClientPtr /* pClient */,
50 int /* size */,
51 void * /* pbuf */);
52
53extern _X_EXPORT void ReplyNotSwappd (
54 ClientPtr /* pClient */,
55 int /* size */,
56 void * /* pbuf */);
57
58typedef enum {ClientStateInitial,
59 ClientStateAuthenticating,
60 ClientStateRunning,
61 ClientStateRetained,
62 ClientStateGone,
63 ClientStateCheckingSecurity,
64 ClientStateCheckedSecurity} ClientState;
65
66#ifdef XFIXES
67typedef struct _saveSet {
68 struct _Window *windowPtr;
69 Bool toRoot;
70 Bool map;
71} SaveSetElt;
72#define SaveSetWindow(ss) ((ss).windowPtr)
73#define SaveSetToRoot(ss) ((ss).toRoot)
74#define SaveSetShouldMap(ss) ((ss).map)
75#define SaveSetAssignWindow(ss,w) ((ss).windowPtr = (w))
76#define SaveSetAssignToRoot(ss,tr) ((ss).toRoot = (tr))
77#define SaveSetAssignMap(ss,m) ((ss).map = (m))
78#else
79typedef struct _Window *SaveSetElt;
80#define SaveSetWindow(ss) (ss)
81#define SaveSetToRoot(ss) FALSE
82#define SaveSetShouldMap(ss) TRUE
83#define SaveSetAssignWindow(ss,w) ((ss) = (w))
84#define SaveSetAssignToRoot(ss,tr)
85#define SaveSetAssignMap(ss,m)
86#endif
87
88/* The unused_ members are ABI spacing. Please reuse them. */
89typedef struct _Client {
90 int index;
91 Mask clientAsMask;
92 pointer requestBuffer;
93 pointer osPrivate; /* for OS layer, including scheduler */
94 Bool swapped;
95 ReplySwapPtr pSwapReplyFunc;
96 XID errorValue;
97 int sequence;
98 int closeDownMode;
99 int clientGone;
100 int noClientException; /* this client died or needs to be
101 * killed */
102 SaveSetElt *saveSet;
103 int numSaved;
104 void *unused_screenPrivate[16];
105 int (**requestVector) (
106 ClientPtr /* pClient */);
107 CARD32 req_len; /* length of current request */
108 Bool big_requests; /* supports large requests */
109 int priority;
110 ClientState clientState;
111 PrivateRec *devPrivates;
112 unsigned short xkbClientFlags;
113 unsigned short mapNotifyMask;
114 unsigned short newKeyboardNotifyMask;
115 unsigned short vMajor,vMinor;
116 KeyCode minKC,maxKC;
117
118 unsigned long replyBytesRemaining;
119 void *unused_appgroup;
120 void *unused_fontResFunc;
121 int smart_priority;
122 long smart_start_tick;
123 long smart_stop_tick;
124 long smart_check_tick;
125
126 DeviceIntPtr clientPtr;
127} ClientRec;
128
129/*
130 * Scheduling interface
131 */
132extern _X_EXPORT long SmartScheduleTime;
133extern _X_EXPORT long SmartScheduleInterval;
134extern _X_EXPORT long SmartScheduleSlice;
135extern _X_EXPORT long SmartScheduleMaxSlice;
136extern _X_EXPORT Bool SmartScheduleDisable;
137extern _X_EXPORT void SmartScheduleStartTimer(void);
138extern _X_EXPORT void SmartScheduleStopTimer(void);
139#define SMART_MAX_PRIORITY (20)
140#define SMART_MIN_PRIORITY (-20)
141
142extern _X_EXPORT Bool SmartScheduleInit(void);
143
144
145/* This prototype is used pervasively in Xext, dix */
146#define DISPATCH_PROC(func) int func(ClientPtr /* client */)
147
148typedef struct _WorkQueue {
149 struct _WorkQueue *next;
150 Bool (*function) (
151 ClientPtr /* pClient */,
152 pointer /* closure */
153);
154 ClientPtr client;
155 pointer closure;
156} WorkQueueRec;
157
158extern _X_EXPORT TimeStamp currentTime;
159extern _X_EXPORT TimeStamp lastDeviceEventTime;
160
161extern _X_EXPORT int CompareTimeStamps(
162 TimeStamp /*a*/,
163 TimeStamp /*b*/);
164
165extern _X_EXPORT TimeStamp ClientTimeToServerTime(CARD32 /*c*/);
166
167typedef struct _CallbackRec {
168 CallbackProcPtr proc;
169 pointer data;
170 Bool deleted;
171 struct _CallbackRec *next;
172} CallbackRec, *CallbackPtr;
173
174typedef struct _CallbackList {
175 int inCallback;
176 Bool deleted;
177 int numDeleted;
178 CallbackPtr list;
179} CallbackListRec;
180
181/* proc vectors */
182
183extern _X_EXPORT int (* InitialVector[3]) (ClientPtr /*client*/);
184
185extern _X_EXPORT int (* ProcVector[256]) (ClientPtr /*client*/);
186
187extern _X_EXPORT int (* SwappedProcVector[256]) (ClientPtr /*client*/);
188
189extern _X_EXPORT ReplySwapPtr ReplySwapVector[256];
190
191extern _X_EXPORT int ProcBadRequest(ClientPtr /*client*/);
192
193#endif /* DIXSTRUCT_H */
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette