VirtualBox

source: vbox/trunk/src/VBox/Additions/x11/x11include/xextproto-7.1.1/X11/extensions/xtestext1proto.h@ 104387

最後變更 在這個檔案從104387是 22660,由 vboxsync 提交於 15 年 前

export more X11 stuff to OSE

  • 屬性 svn:eol-style 設為 native
檔案大小: 7.7 KB
 
1/*
2 * xtestext1.h
3 *
4 * X11 Input Synthesis Extension include file
5 */
6
7/*
8Copyright 1986, 1987, 1988, 1998 The Open Group
9
10Permission to use, copy, modify, distribute, and sell this software and its
11documentation for any purpose is hereby granted without fee, provided that
12the above copyright notice appear in all copies and that both that
13copyright notice and this permission notice appear in supporting
14documentation.
15
16The above copyright notice and this permission notice shall be included in
17all copies or substantial portions of the Software.
18
19THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
22OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
23AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
24CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
25
26Except as contained in this notice, the name of The Open Group shall not be
27used in advertising or otherwise to promote the sale, use or other dealings
28in this Software without prior written authorization from The Open Group.
29
30
31Copyright 1986, 1987, 1988 by Hewlett-Packard Corporation
32
33Permission to use, copy, modify, and distribute this
34software and its documentation for any purpose and without
35fee is hereby granted, provided that the above copyright
36notice appear in all copies and that both that copyright
37notice and this permission notice appear in supporting
38documentation, and that the name of Hewlett-Packard not be used in
39advertising or publicity pertaining to distribution of the
40software without specific, written prior permission.
41
42Hewlett-Packard makes no representations about the
43suitability of this software for any purpose. It is provided
44"as is" without express or implied warranty.
45
46This software is not subject to any license of the American
47Telephone and Telegraph Company or of the Regents of the
48University of California.
49
50*/
51
52#ifndef _XTESTEXT1PROTO_H
53#define _XTESTEXT1PROTO_H 1
54
55#include <X11/extensions/xtestext1const.h>
56
57/*
58 * the typedefs for CARD8, CARD16, and CARD32 are defined in Xmd.h
59 */
60
61/*
62 * XTest request type values
63 *
64 * used in the XTest extension protocol requests
65 */
66#define X_TestFakeInput 1
67#define X_TestGetInput 2
68#define X_TestStopInput 3
69#define X_TestReset 4
70#define X_TestQueryInputSize 5
71
72/*
73 * This defines the maximum size of a list of input actions
74 * to be sent to the server. It should always be a multiple of
75 * 4 so that the entire xTestFakeInputReq structure size is a
76 * multiple of 4.
77 */
78
79typedef struct {
80 CARD8 reqType; /* always XTestReqCode */
81 CARD8 XTestReqType; /* always X_TestFakeInput */
82 CARD16 length B16; /* 2 + XTestMAX_ACTION_LIST_SIZE/4 */
83 CARD32 ack B32;
84 CARD8 action_list[XTestMAX_ACTION_LIST_SIZE];
85} xTestFakeInputReq;
86#define sz_xTestFakeInputReq (XTestMAX_ACTION_LIST_SIZE + 8)
87
88typedef struct {
89 CARD8 reqType; /* always XTestReqCode */
90 CARD8 XTestReqType; /* always X_TestGetInput */
91 CARD16 length B16; /* 2 */
92 CARD32 mode B32;
93} xTestGetInputReq;
94#define sz_xTestGetInputReq 8
95
96typedef struct {
97 CARD8 reqType; /* always XTestReqCode */
98 CARD8 XTestReqType; /* always X_TestStopInput */
99 CARD16 length B32; /* 1 */
100} xTestStopInputReq;
101#define sz_xTestStopInputReq 4
102
103typedef struct {
104 CARD8 reqType; /* always XTestReqCode */
105 CARD8 XTestReqType; /* always X_TestReset */
106 CARD16 length B16; /* 1 */
107} xTestResetReq;
108#define sz_xTestResetReq 4
109
110typedef struct {
111 CARD8 reqType; /* always XTestReqCode */
112 CARD8 XTestReqType; /* always X_TestQueryInputSize */
113 CARD16 length B16; /* 1 */
114} xTestQueryInputSizeReq;
115#define sz_xTestQueryInputSizeReq 4
116
117/*
118 * This is the definition of the reply for the xTestQueryInputSize
119 * request. It should remain the same minimum size as other replies
120 * (32 bytes).
121 */
122typedef struct {
123 CARD8 type; /* always X_Reply */
124 CARD8 pad1;
125 CARD16 sequenceNumber B16;
126 CARD32 length B32; /* always 0 */
127 CARD32 size_return B32;
128 CARD32 pad2 B32;
129 CARD32 pad3 B32;
130 CARD32 pad4 B32;
131 CARD32 pad5 B32;
132 CARD32 pad6 B32;
133} xTestQueryInputSizeReply;
134
135/*
136 * This is the definition for the input action wire event structure.
137 * This event is sent to the client when the server has one or
138 * more user input actions to report to the client. It must
139 * remain the same size as all other wire events (32 bytes).
140 */
141typedef struct {
142 CARD8 type; /* always XTestInputActionType */
143 CARD8 pad00;
144 CARD16 sequenceNumber B16;
145 CARD8 actions[XTestACTIONS_SIZE];
146} xTestInputActionEvent;
147
148/*
149 * This is the definition for the xTestFakeAck wire event structure.
150 * This event is sent to the client when the server has completely
151 * processed its input action buffer, and is ready for more.
152 * It must remain the same size as all other wire events (32 bytes).
153 */
154typedef struct {
155 CARD8 type; /* always XTestFakeAckType */
156 CARD8 pad00;
157 CARD16 sequenceNumber B16;
158 CARD32 pad02 B32;
159 CARD32 pad03 B32;
160 CARD32 pad04 B32;
161 CARD32 pad05 B32;
162 CARD32 pad06 B32;
163 CARD32 pad07 B32;
164 CARD32 pad08 B32;
165} xTestFakeAckEvent;
166
167/*
168 * These are the definitions for key/button motion input actions.
169 */
170typedef struct {
171 CARD8 header; /* which device, key up/down */
172 CARD8 keycode; /* which key/button to move */
173 CARD16 delay_time B16; /* how long to delay (in ms) */
174} XTestKeyInfo;
175
176/*
177 * This is the definition for pointer jump input actions.
178 */
179typedef struct {
180 CARD8 header; /* which pointer */
181 CARD8 pad1; /* unused padding byte */
182 CARD16 jumpx B16; /* x coord to jump to */
183 CARD16 jumpy B16; /* y coord to jump to */
184 CARD16 delay_time B16; /* how long to delay (in ms) */
185} XTestJumpInfo;
186
187/*
188 * These are the definitions for pointer relative motion input
189 * actions.
190 *
191 * The sign bits for the x and y relative motions are contained
192 * in the header byte. The x and y relative motions are packed
193 * into one byte to make things fit in 32 bits. If the relative
194 * motion range is larger than +/-15, use the pointer jump action.
195 */
196
197typedef struct {
198 CARD8 header; /* which pointer */
199 CARD8 motion_data; /* x,y relative motion */
200 CARD16 delay_time B16; /* how long to delay (in ms) */
201} XTestMotionInfo;
202
203/*
204 * These are the definitions for a long delay input action. It is
205 * used when more than XTestSHORT_DELAY_TIME milliseconds of delay
206 * (approximately one minute) is needed.
207 *
208 * The device ID for a delay is always set to XTestDELAY_DEVICE_ID.
209 * This guarantees that a header byte with a value of 0 is not
210 * a valid header, so it can be used as a flag to indicate that
211 * there are no more input actions in an XTestInputAction event.
212 */
213
214typedef struct {
215 CARD8 header; /* always XTestDELAY_DEVICE_ID */
216 CARD8 pad1; /* unused padding byte */
217 CARD16 pad2 B16; /* unused padding word */
218 CARD32 delay_time B32; /* how long to delay (in ms) */
219} XTestDelayInfo;
220
221#endif /* _XTESTEXT1PROTO_H */
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

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