3 * Wine server protocol definition
5 * Copyright (C
) 2001 Alexandre Julliard
7 * This file is used by tools
/make_requests to build the
8 * protocol structures in include
/wine
/server_protocol.h
10 * This library is free software
; you can redistribute it and
/or
11 * modify it under the terms of the GNU Lesser General Public
12 * License as published by the Free Software Foundation
; either
13 * version
2.1 of the License
, or (at your option
) any later version.
15 * This library is distributed in the hope that it will be useful
,
16 * but WITHOUT ANY WARRANTY
; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU
18 * Lesser General Public License for more details.
20 * You should have received a copy of the GNU Lesser General Public
21 * License along with this library
; if not
, write to the Free Software
22 * Foundation
, Inc.
, 51 Franklin St
, Fifth Floor
, Boston
, MA
02110-1301, USA
25 @HEADER
/* start of C declarations
*/
34 typedef unsigned int obj_handle_t
;
35 typedef unsigned int user_handle_t
;
36 typedef unsigned short atom_t
;
37 typedef unsigned int process_id_t
;
38 typedef unsigned int thread_id_t
;
39 typedef unsigned int data_size_t
;
40 typedef unsigned int ioctl_code_t
;
41 typedef unsigned long lparam_t
;
42 typedef unsigned __int64 file_pos_t
;
46 int req
; /* request code
*/
47 data_size_t request_size
; /* request variable part size
*/
48 data_size_t reply_size
; /* reply variable part maximum size
*/
53 unsigned int error
; /* error result
*/
54 data_size_t reply_size
; /* reply variable part size
*/
57 /* placeholder structure for the maximum allowed request size
*/
58 /* this is used to construct the generic_request union
*/
59 struct request_max_size
61 int pad
[16]; /* the max request size is
16 ints
*/
64 #define FIRST_USER_HANDLE
0x0020 /* first possible value for low word of user handle
*/
65 #define LAST_USER_HANDLE
0xffef /* last possible value for low word of user handle
*/
68 /* definitions of the event data depending on the event code
*/
69 struct debug_event_exception
71 EXCEPTION_RECORD record
; /* exception record
*/
72 int first
; /* first chance exception?
*/
74 struct debug_event_create_thread
76 obj_handle_t handle
; /* handle to the new thread
*/
77 void
*teb
; /* thread
teb (in debugged process address space
) */
78 void
*start
; /* thread startup routine
*/
80 struct debug_event_create_process
82 obj_handle_t file
; /* handle to the process exe file
*/
83 obj_handle_t process
; /* handle to the new process
*/
84 obj_handle_t thread
; /* handle to the new thread
*/
85 void
*base
; /* base of executable image
*/
86 int dbg_offset
; /* offset of debug info in file
*/
87 int dbg_size
; /* size of debug info
*/
88 void
*teb
; /* thread
teb (in debugged process address space
) */
89 void
*start
; /* thread startup routine
*/
90 void
*name
; /* image
name (optional
) */
91 int unicode
; /* is it Unicode?
*/
93 struct debug_event_exit
95 int exit_code
; /* thread or process exit code
*/
97 struct debug_event_load_dll
99 obj_handle_t handle
; /* file handle for the dll
*/
100 void
*base
; /* base address of the dll
*/
101 int dbg_offset
; /* offset of debug info in file
*/
102 int dbg_size
; /* size of debug info
*/
103 void
*name
; /* image
name (optional
) */
104 int unicode
; /* is it Unicode?
*/
106 struct debug_event_unload_dll
108 void
*base
; /* base address of the dll
*/
110 struct debug_event_output_string
112 void
*string
; /* string to
display (in debugged process address space
) */
113 int unicode
; /* is it Unicode?
*/
114 int length
; /* string length
*/
116 struct debug_event_rip_info
121 union debug_event_data
123 struct debug_event_exception exception
;
124 struct debug_event_create_thread create_thread
;
125 struct debug_event_create_process create_process
;
126 struct debug_event_exit exit
;
127 struct debug_event_load_dll load_dll
;
128 struct debug_event_unload_dll unload_dll
;
129 struct debug_event_output_string output_string
;
130 struct debug_event_rip_info rip_info
;
133 /* debug event data
*/
136 int code
; /* event code
*/
137 union debug_event_data info
; /* event information
*/
140 /* structure used in sending an fd from client to server
*/
143 thread_id_t tid
; /* thread id
*/
144 int fd
; /* file descriptor on client
-side
*/
147 /* structure sent by the server on the wait fifo
*/
150 void
*cookie
; /* magic cookie that was passed in select_request
*/
151 int signaled
; /* wait result
*/
154 /* NT
-style timeout
, in
100ns units
, negative means relative timeout
*/
155 typedef __int64 timeout_t
;
156 #define
TIMEOUT_INFINITE (((timeout_t
)0x7fffffff) << 32 |
0xffffffff)
158 /* structure returned in the list of window properties
*/
161 atom_t atom
; /* property atom
*/
162 short string
; /* was atom a string originally?
*/
163 obj_handle_t handle
; /* handle stored in property
*/
166 /* structure to specify window rectangles
*/
175 /* structure for parameters of async I
/O calls
*/
178 void
*callback
; /* client
-side callback to call upon end of async
*/
179 void
*iosb
; /* I
/O status block in client addr space
*/
180 void
*arg
; /* opaque user data to pass to callback
*/
181 void
*apc
; /* user apc to call
*/
182 obj_handle_t event
; /* event to signal when done
*/
183 unsigned long cvalue
; /* completion value to use for completion events
*/
186 /* structures for extra message data
*/
188 struct callback_msg_data
190 void
*callback
; /* callback function
*/
191 lparam_t data
; /* user data for callback
*/
192 lparam_t result
; /* message result
*/
195 struct winevent_msg_data
197 user_handle_t hook
; /* hook handle
*/
198 thread_id_t tid
; /* thread id
*/
199 void
*hook_proc
; /* hook proc address
*/
200 /* followed by module name if any
*/
205 unsigned char bytes
[1]; /* raw data for sent messages
*/
206 struct callback_msg_data callback
;
207 struct winevent_msg_data winevent
;
210 /* structure for console char
/attribute info
*/
219 unsigned int low_part
;
223 #define MAX_ACL_LEN
65535
225 struct security_descriptor
227 unsigned int control
; /* SE_ flags
*/
228 data_size_t owner_len
;
229 data_size_t group_len
;
230 data_size_t sacl_len
;
231 data_size_t dacl_len
;
232 /* VARARG(owner
,SID
); */
233 /* VARARG(group
,SID
); */
234 /* VARARG(sacl
,ACL
); */
235 /* VARARG(dacl
,ACL
); */
238 struct object_attributes
240 obj_handle_t rootdir
; /* root directory
*/
241 data_size_t sd_len
; /* length of security_descriptor data. may be
0 */
242 data_size_t name_len
; /* length of the name string. may be
0 */
243 /* VARARG(sd
,security_descriptor
); */
244 /* VARARG(name
,unicode_str
); */
250 /* unsigned int attributes
[count
]; */
251 /* VARARG(sids
,SID
); */
277 enum apc_type type
; /* APC_USER
*/
278 void (__stdcall
*func
)(unsigned long
,unsigned long
,unsigned long
);
279 unsigned long args
[3]; /* arguments for user function
*/
283 enum apc_type type
; /* APC_TIMER
*/
284 void (__stdcall
*func
)(void
*, unsigned int
, unsigned int
);
285 timeout_t time
; /* absolute time of expiration
*/
286 void
*arg
; /* user argument
*/
290 enum apc_type type
; /* APC_ASYNC_IO
*/
291 unsigned
int (*func)(void*, void*, unsigned int, unsigned long *);
292 void
*user
; /* user pointer
*/
293 void
*sb
; /* status block
*/
294 unsigned int status
; /* I
/O status
*/
298 enum apc_type type
; /* APC_VIRTUAL_ALLOC
*/
299 void
*addr
; /* requested address
*/
300 unsigned long size
; /* allocation size
*/
301 unsigned int zero_bits
; /* allocation alignment
*/
302 unsigned int op_type
; /* type of operation
*/
303 unsigned int prot
; /* memory protection flags
*/
307 enum apc_type type
; /* APC_VIRTUAL_FREE
*/
308 void
*addr
; /* requested address
*/
309 unsigned long size
; /* allocation size
*/
310 unsigned int op_type
; /* type of operation
*/
314 enum apc_type type
; /* APC_VIRTUAL_QUERY
*/
315 const void
*addr
; /* requested address
*/
319 enum apc_type type
; /* APC_VIRTUAL_PROTECT
*/
320 void
*addr
; /* requested address
*/
321 unsigned long size
; /* requested address
*/
322 unsigned int prot
; /* new protection flags
*/
326 enum apc_type type
; /* APC_VIRTUAL_FLUSH
*/
327 const void
*addr
; /* requested address
*/
328 unsigned long size
; /* requested address
*/
332 enum apc_type type
; /* APC_VIRTUAL_LOCK
*/
333 void
*addr
; /* requested address
*/
334 unsigned long size
; /* requested address
*/
338 enum apc_type type
; /* APC_VIRTUAL_UNLOCK
*/
339 void
*addr
; /* requested address
*/
340 unsigned long size
; /* requested address
*/
344 enum apc_type type
; /* APC_MAP_VIEW
*/
345 obj_handle_t handle
; /* mapping handle
*/
346 void
*addr
; /* requested address
*/
347 unsigned long size
; /* allocation size
*/
348 file_pos_t offset
; /* file offset
*/
349 unsigned int zero_bits
; /* allocation alignment
*/
350 unsigned int alloc_type
;/* allocation type
*/
351 unsigned int prot
; /* memory protection flags
*/
355 enum apc_type type
; /* APC_UNMAP_VIEW
*/
356 void
*addr
; /* view address
*/
360 enum apc_type type
; /* APC_CREATE_THREAD
*/
361 void (__stdcall
*func
)(void*)
; /* start function
*/
362 void
*arg
; /* argument for start function
*/
363 unsigned long reserve
; /* reserve size for thread stack
*/
364 unsigned long commit
; /* commit size for thread stack
*/
365 int suspend
; /* suspended thread?
*/
374 enum apc_type type
; /* APC_ASYNC_IO
*/
375 unsigned int status
; /* new status of async operation
*/
376 unsigned long total
; /* bytes transferred
*/
380 enum apc_type type
; /* APC_VIRTUAL_ALLOC
*/
381 unsigned int status
; /* status returned by call
*/
382 void
*addr
; /* resulting address
*/
383 unsigned long size
; /* resulting size
*/
387 enum apc_type type
; /* APC_VIRTUAL_FREE
*/
388 unsigned int status
; /* status returned by call
*/
389 void
*addr
; /* resulting address
*/
390 unsigned long size
; /* resulting size
*/
394 enum apc_type type
; /* APC_VIRTUAL_QUERY
*/
395 unsigned int status
; /* status returned by call
*/
396 void
*base
; /* resulting base address
*/
397 void
*alloc_base
;/* resulting allocation base
*/
398 unsigned long size
; /* resulting region size
*/
399 unsigned int state
; /* resulting region state
*/
400 unsigned int prot
; /* resulting region protection
*/
401 unsigned int alloc_prot
;/* resulting allocation protection
*/
402 unsigned int alloc_type
;/* resulting region allocation type
*/
406 enum apc_type type
; /* APC_VIRTUAL_PROTECT
*/
407 unsigned int status
; /* status returned by call
*/
408 void
*addr
; /* resulting address
*/
409 unsigned long size
; /* resulting size
*/
410 unsigned int prot
; /* old protection flags
*/
414 enum apc_type type
; /* APC_VIRTUAL_FLUSH
*/
415 unsigned int status
; /* status returned by call
*/
416 const void
*addr
; /* resulting address
*/
417 unsigned long size
; /* resulting size
*/
421 enum apc_type type
; /* APC_VIRTUAL_LOCK
*/
422 unsigned int status
; /* status returned by call
*/
423 void
*addr
; /* resulting address
*/
424 unsigned long size
; /* resulting size
*/
428 enum apc_type type
; /* APC_VIRTUAL_UNLOCK
*/
429 unsigned int status
; /* status returned by call
*/
430 void
*addr
; /* resulting address
*/
431 unsigned long size
; /* resulting size
*/
435 enum apc_type type
; /* APC_MAP_VIEW
*/
436 unsigned int status
; /* status returned by call
*/
437 void
*addr
; /* resulting address
*/
438 unsigned long size
; /* resulting size
*/
442 enum apc_type type
; /* APC_MAP_VIEW
*/
443 unsigned int status
; /* status returned by call
*/
447 enum apc_type type
; /* APC_CREATE_THREAD
*/
448 unsigned int status
; /* status returned by call
*/
449 thread_id_t tid
; /* thread id
*/
450 obj_handle_t handle
; /* handle to new thread
*/
454 /****************************************************************/
455 /* Request declarations
*/
457 /* Create a new process from the context of the parent
*/
459 int inherit_all
; /* inherit all handles from parent
*/
460 unsigned int create_flags
; /* creation flags
*/
461 int socket_fd
; /* file descriptor for process socket
*/
462 obj_handle_t exe_file
; /* file handle for main exe
*/
463 obj_handle_t hstdin
; /* handle for stdin
*/
464 obj_handle_t hstdout
; /* handle for stdout
*/
465 obj_handle_t hstderr
; /* handle for stderr
*/
466 unsigned int process_access
; /* access rights for process object
*/
467 unsigned int process_attr
; /* attributes for process object
*/
468 unsigned int thread_access
; /* access rights for thread object
*/
469 unsigned int thread_attr
; /* attributes for thread object
*/
470 VARARG(info
,startup_info
); /* startup information
*/
471 VARARG(env
,unicode_str
); /* environment for new process
*/
473 obj_handle_t info
; /* new process info handle
*/
474 process_id_t pid
; /* process id
*/
475 obj_handle_t phandle
; /* process
handle (in the current process
) */
476 thread_id_t tid
; /* thread id
*/
477 obj_handle_t thandle
; /* thread
handle (in the current process
) */
481 /* Retrieve information about a newly started process
*/
482 @
REQ(get_new_process_info
)
483 obj_handle_t info
; /* info handle returned from new_process_request
*/
485 int success
; /* did the process start successfully?
*/
486 int exit_code
; /* process exit code if failed
*/
490 /* Create a new thread from the context of the parent
*/
492 unsigned int access
; /* wanted access rights
*/
493 unsigned int attributes
; /* object attributes
*/
494 int suspend
; /* new thread should be suspended on creation
*/
495 int request_fd
; /* fd for request pipe
*/
497 thread_id_t tid
; /* thread id
*/
498 obj_handle_t handle
; /* thread
handle (in the current process
) */
502 /* Retrieve the new process startup info
*/
503 @
REQ(get_startup_info
)
505 obj_handle_t exe_file
; /* file handle for main exe
*/
506 obj_handle_t hstdin
; /* handle for stdin
*/
507 obj_handle_t hstdout
; /* handle for stdout
*/
508 obj_handle_t hstderr
; /* handle for stderr
*/
509 VARARG(info
,startup_info
); /* startup information
*/
510 VARARG(env
,unicode_str
); /* environment
*/
514 /* Signal the end of the process initialization
*/
515 @
REQ(init_process_done
)
516 void
* module
; /* main module base address
*/
517 void
* entry
; /* process entry point
*/
518 int gui
; /* is it a GUI process?
*/
522 /* Initialize a thread
; called from the child after
fork()/clone() */
524 int unix_pid
; /* Unix pid of new thread
*/
525 int unix_tid
; /* Unix tid of new thread
*/
526 int debug_level
; /* new debug level
*/
527 void
* teb
; /* TEB of new
thread (in thread address space
) */
528 void
* peb
; /* address of
PEB (in thread address space
) */
529 void
* entry
; /* thread entry
point (in thread address space
) */
530 void
* ldt_copy
; /* address of LDT
copy (in thread address space
) */
531 int reply_fd
; /* fd for reply pipe
*/
532 int wait_fd
; /* fd for blocking calls pipe
*/
534 process_id_t pid
; /* process id of the new thread
's process */
535 thread_id_t tid; /* thread id of the new thread */
536 data_size_t info_size; /* total size of startup info */
537 timeout_t server_start; /* server start time */
538 int version; /* protocol version */
542 /* Terminate a process */
543 @REQ(terminate_process)
544 obj_handle_t handle; /* process handle to terminate */
545 int exit_code; /* process exit code */
547 int self; /* suicide? */
551 /* Terminate a thread */
552 @REQ(terminate_thread)
553 obj_handle_t handle; /* thread handle to terminate */
554 int exit_code; /* thread exit code */
556 int self; /* suicide? */
557 int last; /* last thread in this process? */
561 /* Retrieve information about a process */
562 @REQ(get_process_info)
563 obj_handle_t handle; /* process handle */
565 process_id_t pid; /* server process id */
566 process_id_t ppid; /* server process id of parent */
567 int exit_code; /* process exit code */
568 int priority; /* priority class */
569 unsigned int affinity; /* process affinity mask */
570 void* peb; /* PEB address in process address space */
571 timeout_t start_time; /* process start time */
572 timeout_t end_time; /* process end time */
576 /* Set a process informations */
577 @REQ(set_process_info)
578 obj_handle_t handle; /* process handle */
579 int mask; /* setting mask (see below) */
580 int priority; /* priority class */
581 unsigned int affinity; /* affinity mask */
583 #define SET_PROCESS_INFO_PRIORITY 0x01
584 #define SET_PROCESS_INFO_AFFINITY 0x02
587 /* Retrieve information about a thread */
588 @REQ(get_thread_info)
589 obj_handle_t handle; /* thread handle */
590 thread_id_t tid_in; /* thread id (optional) */
592 process_id_t pid; /* server process id */
593 thread_id_t tid; /* server thread id */
594 void* teb; /* thread teb pointer */
595 int exit_code; /* thread exit code */
596 int priority; /* thread priority level */
597 unsigned int affinity; /* thread affinity mask */
598 timeout_t creation_time; /* thread creation time */
599 timeout_t exit_time; /* thread exit time */
600 int last; /* last thread in process */
604 /* Set a thread informations */
605 @REQ(set_thread_info)
606 obj_handle_t handle; /* thread handle */
607 int mask; /* setting mask (see below) */
608 int priority; /* priority class */
609 unsigned int affinity; /* affinity mask */
610 obj_handle_t token; /* impersonation token */
612 #define SET_THREAD_INFO_PRIORITY 0x01
613 #define SET_THREAD_INFO_AFFINITY 0x02
614 #define SET_THREAD_INFO_TOKEN 0x04
617 /* Retrieve information about a module */
619 obj_handle_t handle; /* process handle */
620 void* base_address; /* base address of module */
623 data_size_t size; /* module size */
624 data_size_t filename_len; /* buffer len in bytes required to store filename */
625 VARARG(filename,unicode_str); /* file name of module */
629 /* Suspend a thread */
631 obj_handle_t handle; /* thread handle */
633 int count; /* new suspend count */
637 /* Resume a thread */
639 obj_handle_t handle; /* thread handle */
641 int count; /* new suspend count */
645 /* Notify the server that a dll has been loaded */
647 obj_handle_t handle; /* file handle */
648 void* base; /* base address */
649 void* name; /* ptr to ptr to name (in process addr space) */
650 data_size_t size; /* dll size */
651 int dbg_offset; /* debug info offset */
652 int dbg_size; /* debug info size */
653 VARARG(filename,unicode_str); /* file name of dll */
657 /* Notify the server that a dll is being unloaded */
659 void* base; /* base address */
663 /* Queue an APC for a thread or process */
665 obj_handle_t thread; /* thread handle */
666 obj_handle_t process; /* process handle */
667 apc_call_t call; /* call arguments */
669 obj_handle_t handle; /* APC handle */
670 int self; /* run APC in caller itself? */
674 /* Get the result of an APC call */
676 obj_handle_t handle; /* handle to the APC */
678 apc_result_t result; /* result of the APC */
682 /* Close a handle for the current process */
684 obj_handle_t handle; /* handle to close */
688 /* Set a handle information */
689 @REQ(set_handle_info)
690 obj_handle_t handle; /* handle we are interested in */
691 int flags; /* new handle flags */
692 int mask; /* mask for flags to set */
694 int old_flags; /* old flag value */
698 /* Duplicate a handle */
700 obj_handle_t src_process; /* src process handle */
701 obj_handle_t src_handle; /* src handle to duplicate */
702 obj_handle_t dst_process; /* dst process handle */
703 unsigned int access; /* wanted access rights */
704 unsigned int attributes; /* object attributes */
705 unsigned int options; /* duplicate options (see below) */
707 obj_handle_t handle; /* duplicated handle in dst process */
708 int self; /* is the source the current process? */
709 int closed; /* whether the source handle has been closed */
711 #define DUP_HANDLE_CLOSE_SOURCE DUPLICATE_CLOSE_SOURCE
712 #define DUP_HANDLE_SAME_ACCESS DUPLICATE_SAME_ACCESS
713 #define DUP_HANDLE_MAKE_GLOBAL 0x80000000 /* Not a Windows flag */
716 /* Open a handle to a process */
718 process_id_t pid; /* process id to open */
719 unsigned int access; /* wanted access rights */
720 unsigned int attributes; /* object attributes */
722 obj_handle_t handle; /* handle to the process */
726 /* Open a handle to a thread */
728 thread_id_t tid; /* thread id to open */
729 unsigned int access; /* wanted access rights */
730 unsigned int attributes; /* object attributes */
732 obj_handle_t handle; /* handle to the thread */
736 /* Wait for handles */
738 int flags; /* wait flags (see below) */
739 void* cookie; /* magic cookie to return to client */
740 obj_handle_t signal; /* object to signal (0 if none) */
741 obj_handle_t prev_apc; /* handle to previous APC */
742 timeout_t timeout; /* timeout */
743 VARARG(result,apc_result); /* result of previous APC */
744 VARARG(handles,handles); /* handles to select on */
746 obj_handle_t apc_handle; /* handle to next APC */
747 timeout_t timeout; /* timeout converted to absolute */
748 apc_call_t call; /* APC call arguments */
751 #define SELECT_ALERTABLE 2
752 #define SELECT_INTERRUPTIBLE 4
755 /* Create an event */
757 unsigned int access; /* wanted access rights */
758 unsigned int attributes; /* object attributes */
759 int manual_reset; /* manual reset event */
760 int initial_state; /* initial state of the event */
761 VARARG(objattr,object_attributes); /* object attributes */
763 obj_handle_t handle; /* handle to the event */
766 /* Event operation */
768 obj_handle_t handle; /* handle to event */
769 int op; /* event operation (see below) */
771 enum event_op { PULSE_EVENT, SET_EVENT, RESET_EVENT };
776 unsigned int access; /* wanted access rights */
777 unsigned int attributes; /* object attributes */
778 obj_handle_t rootdir; /* root directory */
779 VARARG(name,unicode_str); /* object name */
781 obj_handle_t handle; /* handle to the event */
787 unsigned int access; /* wanted access rights */
788 unsigned int attributes; /* object attributes */
789 int owned; /* initially owned? */
790 VARARG(objattr,object_attributes); /* object attributes */
792 obj_handle_t handle; /* handle to the mutex */
796 /* Release a mutex */
798 obj_handle_t handle; /* handle to the mutex */
800 unsigned int prev_count; /* value of internal counter, before release */
806 unsigned int access; /* wanted access rights */
807 unsigned int attributes; /* object attributes */
808 obj_handle_t rootdir; /* root directory */
809 VARARG(name,unicode_str); /* object name */
811 obj_handle_t handle; /* handle to the mutex */
815 /* Create a semaphore */
816 @REQ(create_semaphore)
817 unsigned int access; /* wanted access rights */
818 unsigned int attributes; /* object attributes */
819 unsigned int initial; /* initial count */
820 unsigned int max; /* maximum count */
821 VARARG(objattr,object_attributes); /* object attributes */
823 obj_handle_t handle; /* handle to the semaphore */
827 /* Release a semaphore */
828 @REQ(release_semaphore)
829 obj_handle_t handle; /* handle to the semaphore */
830 unsigned int count; /* count to add to semaphore */
832 unsigned int prev_count; /* previous semaphore count */
836 /* Open a semaphore */
838 unsigned int access; /* wanted access rights */
839 unsigned int attributes; /* object attributes */
840 obj_handle_t rootdir; /* root directory */
841 VARARG(name,unicode_str); /* object name */
843 obj_handle_t handle; /* handle to the semaphore */
849 unsigned int access; /* wanted access rights */
850 unsigned int attributes; /* object attributes */
851 unsigned int sharing; /* sharing flags */
852 int create; /* file create action */
853 unsigned int options; /* file options */
854 unsigned int attrs; /* file attributes for creation */
855 VARARG(objattr,object_attributes); /* object attributes */
856 VARARG(filename,string); /* file name */
858 obj_handle_t handle; /* handle to the file */
862 /* Open a file object */
863 @REQ(open_file_object)
864 unsigned int access; /* wanted access rights */
865 unsigned int attributes; /* open attributes */
866 obj_handle_t rootdir; /* root directory */
867 unsigned int sharing; /* sharing flags */
868 unsigned int options; /* file options */
869 VARARG(filename,unicode_str); /* file name */
871 obj_handle_t handle; /* handle to the file */
875 /* Allocate a file handle for a Unix fd */
876 @REQ(alloc_file_handle)
877 unsigned int access; /* wanted access rights */
878 unsigned int attributes; /* object attributes */
879 int fd; /* file descriptor on the client side */
881 obj_handle_t handle; /* handle to the file */
885 /* Get a Unix fd to access a file */
887 obj_handle_t handle; /* handle to the file */
889 int type; /* file type (see below) */
890 int removable; /* is file removable? */
891 unsigned int access; /* file access rights */
892 unsigned int options; /* file open options */
896 FD_TYPE_INVALID, /* invalid file (no associated fd) */
897 FD_TYPE_FILE, /* regular file */
898 FD_TYPE_DIR, /* directory */
899 FD_TYPE_SOCKET, /* socket */
900 FD_TYPE_SERIAL, /* serial port */
901 FD_TYPE_PIPE, /* named pipe */
902 FD_TYPE_MAILSLOT, /* mailslot */
903 FD_TYPE_CHAR, /* unspecified char device */
904 FD_TYPE_DEVICE, /* Windows device file */
909 /* Flush a file buffers */
911 obj_handle_t handle; /* handle to the file */
913 obj_handle_t event; /* event set when finished */
917 /* Lock a region of a file */
919 obj_handle_t handle; /* handle to the file */
920 file_pos_t offset; /* offset of start of lock */
921 file_pos_t count; /* count of bytes to lock */
922 int shared; /* shared or exclusive lock? */
923 int wait; /* do we want to wait? */
925 obj_handle_t handle; /* handle to wait on */
926 int overlapped; /* is it an overlapped I/O handle? */
930 /* Unlock a region of a file */
932 obj_handle_t handle; /* handle to the file */
933 file_pos_t offset; /* offset of start of unlock */
934 file_pos_t count; /* count of bytes to unlock */
938 /* Create a socket */
940 unsigned int access; /* wanted access rights */
941 unsigned int attributes; /* object attributes */
942 int family; /* family, see socket manpage */
943 int type; /* type, see socket manpage */
944 int protocol; /* protocol, see socket manpage */
945 unsigned int flags; /* socket flags */
947 obj_handle_t handle; /* handle to the new socket */
951 /* Accept a socket */
953 obj_handle_t lhandle; /* handle to the listening socket */
954 unsigned int access; /* wanted access rights */
955 unsigned int attributes; /* object attributes */
957 obj_handle_t handle; /* handle to the new socket */
961 /* Set socket event parameters */
962 @REQ(set_socket_event)
963 obj_handle_t handle; /* handle to the socket */
964 unsigned int mask; /* event mask */
965 obj_handle_t event; /* event object */
966 user_handle_t window; /* window to send the message to */
967 unsigned int msg; /* message to send */
971 /* Get socket event parameters */
972 @REQ(get_socket_event)
973 obj_handle_t handle; /* handle to the socket */
974 int service; /* clear pending? */
975 obj_handle_t c_event; /* event to clear */
977 unsigned int mask; /* event mask */
978 unsigned int pmask; /* pending events */
979 unsigned int state; /* status bits */
980 VARARG(errors,ints); /* event errors */
984 /* Reenable pending socket events */
985 @REQ(enable_socket_event)
986 obj_handle_t handle; /* handle to the socket */
987 unsigned int mask; /* events to re-enable */
988 unsigned int sstate; /* status bits to set */
989 unsigned int cstate; /* status bits to clear */
992 @REQ(set_socket_deferred)
993 obj_handle_t handle; /* handle to the socket */
994 obj_handle_t deferred; /* handle to the socket for which accept() is deferred */
997 /* Allocate a console (only used by a console renderer) */
999 unsigned int access; /* wanted access rights */
1000 unsigned int attributes; /* object attributes */
1001 process_id_t pid; /* pid of process which shall be attached to the console */
1003 obj_handle_t handle_in; /* handle to console input */
1004 obj_handle_t event; /* handle to renderer events change notification */
1008 /* Free the console of the current process */
1013 #define CONSOLE_RENDERER_NONE_EVENT 0x00
1014 #define CONSOLE_RENDERER_TITLE_EVENT 0x01
1015 #define CONSOLE_RENDERER_ACTIVE_SB_EVENT 0x02
1016 #define CONSOLE_RENDERER_SB_RESIZE_EVENT 0x03
1017 #define CONSOLE_RENDERER_UPDATE_EVENT 0x04
1018 #define CONSOLE_RENDERER_CURSOR_POS_EVENT 0x05
1019 #define CONSOLE_RENDERER_CURSOR_GEOM_EVENT 0x06
1020 #define CONSOLE_RENDERER_DISPLAY_EVENT 0x07
1021 #define CONSOLE_RENDERER_EXIT_EVENT 0x08
1022 struct console_renderer_event
1057 /* retrieve console events for the renderer */
1058 @REQ(get_console_renderer_events)
1059 obj_handle_t handle; /* handle to console input events */
1061 VARARG(data,bytes); /* the various console_renderer_events */
1065 /* Open a handle to the process console */
1067 obj_handle_t from; /* 0 (resp 1) input (resp output) of current process console */
1068 /* otherwise console_in handle to get active screen buffer? */
1069 unsigned int access; /* wanted access rights */
1070 unsigned int attributes; /* object attributes */
1071 int share; /* share mask (only for output handles) */
1073 obj_handle_t handle; /* handle to the console */
1077 /* Get the input queue wait event */
1078 @REQ(get_console_wait_event)
1080 obj_handle_t handle;
1083 /* Get a console mode (input or output) */
1084 @REQ(get_console_mode)
1085 obj_handle_t handle; /* handle to the console */
1087 int mode; /* console mode */
1091 /* Set a console mode (input or output) */
1092 @REQ(set_console_mode)
1093 obj_handle_t handle; /* handle to the console */
1094 int mode; /* console mode */
1098 /* Set info about a console (input only) */
1099 @REQ(set_console_input_info)
1100 obj_handle_t handle; /* handle to console input, or 0 for process' console
*/
1101 int mask
; /* setting
mask (see below
) */
1102 obj_handle_t active_sb
; /* active screen buffer
*/
1103 int history_mode
; /* whether we duplicate lines in history
*/
1104 int history_size
; /* number of lines in history
*/
1105 int edition_mode
; /* index to the edition mode flavors
*/
1106 int input_cp
; /* console input codepage
*/
1107 int output_cp
; /* console output codepage
*/
1108 user_handle_t win
; /* console window if backend supports it
*/
1109 VARARG(title
,unicode_str
); /* console title
*/
1111 #define SET_CONSOLE_INPUT_INFO_ACTIVE_SB
0x01
1112 #define SET_CONSOLE_INPUT_INFO_TITLE
0x02
1113 #define SET_CONSOLE_INPUT_INFO_HISTORY_MODE
0x04
1114 #define SET_CONSOLE_INPUT_INFO_HISTORY_SIZE
0x08
1115 #define SET_CONSOLE_INPUT_INFO_EDITION_MODE
0x10
1116 #define SET_CONSOLE_INPUT_INFO_INPUT_CODEPAGE
0x20
1117 #define SET_CONSOLE_INPUT_INFO_OUTPUT_CODEPAGE
0x40
1118 #define SET_CONSOLE_INPUT_INFO_WIN
0x80
1121 /* Get info about a
console (input only
) */
1122 @
REQ(get_console_input_info
)
1123 obj_handle_t handle
; /* handle to console input
, or
0 for process
' console */
1125 int history_mode; /* whether we duplicate lines in history */
1126 int history_size; /* number of lines in history */
1127 int history_index; /* number of used lines in history */
1128 int edition_mode; /* index to the edition mode flavors */
1129 int input_cp; /* console input codepage */
1130 int output_cp; /* console output codepage */
1131 user_handle_t win; /* console window if backend supports it */
1132 VARARG(title,unicode_str); /* console title */
1136 /* appends a string to console's history
*/
1137 @
REQ(append_console_input_history
)
1138 obj_handle_t handle
; /* handle to console input
, or
0 for process
' console */
1139 VARARG(line,unicode_str); /* line to add */
1143 /* appends a string to console's history
*/
1144 @
REQ(get_console_input_history
)
1145 obj_handle_t handle
; /* handle to console input
, or
0 for process
' console */
1146 int index; /* index to get line from */
1148 int total; /* total length of line in Unicode chars */
1149 VARARG(line,unicode_str); /* line to add */
1153 /* creates a new screen buffer on process' console
*/
1154 @
REQ(create_console_output
)
1155 obj_handle_t handle_in
; /* handle to console input
, or
0 for process
' console */
1156 unsigned int access; /* wanted access rights */
1157 unsigned int attributes; /* object attributes */
1158 unsigned int share; /* sharing credentials */
1160 obj_handle_t handle_out; /* handle to the screen buffer */
1164 /* Set info about a console (output only) */
1165 @REQ(set_console_output_info)
1166 obj_handle_t handle; /* handle to the console */
1167 int mask; /* setting mask (see below) */
1168 short int cursor_size; /* size of cursor (percentage filled) */
1169 short int cursor_visible;/* cursor visibility flag */
1170 short int cursor_x; /* position of cursor (x, y) */
1172 short int width; /* width of the screen buffer */
1173 short int height; /* height of the screen buffer */
1174 short int attr; /* default attribute */
1175 short int win_left; /* window actually displayed by renderer */
1176 short int win_top; /* the rect area is expressed withing the */
1177 short int win_right; /* boundaries of the screen buffer */
1178 short int win_bottom;
1179 short int max_width; /* maximum size (width x height) for the window */
1180 short int max_height;
1182 #define SET_CONSOLE_OUTPUT_INFO_CURSOR_GEOM 0x01
1183 #define SET_CONSOLE_OUTPUT_INFO_CURSOR_POS 0x02
1184 #define SET_CONSOLE_OUTPUT_INFO_SIZE 0x04
1185 #define SET_CONSOLE_OUTPUT_INFO_ATTR 0x08
1186 #define SET_CONSOLE_OUTPUT_INFO_DISPLAY_WINDOW 0x10
1187 #define SET_CONSOLE_OUTPUT_INFO_MAX_SIZE 0x20
1190 /* Get info about a console (output only) */
1191 @REQ(get_console_output_info)
1192 obj_handle_t handle; /* handle to the console */
1194 short int cursor_size; /* size of cursor (percentage filled) */
1195 short int cursor_visible;/* cursor visibility flag */
1196 short int cursor_x; /* position of cursor (x, y) */
1198 short int width; /* width of the screen buffer */
1199 short int height; /* height of the screen buffer */
1200 short int attr; /* default attribute */
1201 short int win_left; /* window actually displayed by renderer */
1202 short int win_top; /* the rect area is expressed withing the */
1203 short int win_right; /* boundaries of the screen buffer */
1204 short int win_bottom;
1205 short int max_width; /* maximum size (width x height) for the window */
1206 short int max_height;
1209 /* Add input records to a console input queue */
1210 @REQ(write_console_input)
1211 obj_handle_t handle; /* handle to the console input */
1212 VARARG(rec,input_records); /* input records */
1214 int written; /* number of records written */
1218 /* Fetch input records from a console input queue */
1219 @REQ(read_console_input)
1220 obj_handle_t handle; /* handle to the console input */
1221 int flush; /* flush the retrieved records from the queue? */
1223 int read; /* number of records read */
1224 VARARG(rec,input_records); /* input records */
1228 /* write data (chars and/or attributes) in a screen buffer */
1229 @REQ(write_console_output)
1230 obj_handle_t handle; /* handle to the console output */
1231 int x; /* position where to start writing */
1233 int mode; /* char info (see below) */
1234 int wrap; /* wrap around at end of line? */
1235 VARARG(data,bytes); /* info to write */
1237 int written; /* number of char infos actually written */
1238 int width; /* width of screen buffer */
1239 int height; /* height of screen buffer */
1243 CHAR_INFO_MODE_TEXT, /* characters only */
1244 CHAR_INFO_MODE_ATTR, /* attributes only */
1245 CHAR_INFO_MODE_TEXTATTR, /* both characters and attributes */
1246 CHAR_INFO_MODE_TEXTSTDATTR /* characters but use standard attributes */
1250 /* fill a screen buffer with constant data (chars and/or attributes) */
1251 @REQ(fill_console_output)
1252 obj_handle_t handle; /* handle to the console output */
1253 int x; /* position where to start writing */
1255 int mode; /* char info mode */
1256 int count; /* number to write */
1257 int wrap; /* wrap around at end of line? */
1258 char_info_t data; /* data to write */
1260 int written; /* number of char infos actually written */
1264 /* read data (chars and/or attributes) from a screen buffer */
1265 @REQ(read_console_output)
1266 obj_handle_t handle; /* handle to the console output */
1267 int x; /* position (x,y) where to start reading */
1269 int mode; /* char info mode */
1270 int wrap; /* wrap around at end of line? */
1272 int width; /* width of screen buffer */
1273 int height; /* height of screen buffer */
1278 /* move a rect (of data) in screen buffer content */
1279 @REQ(move_console_output)
1280 obj_handle_t handle; /* handle to the console output */
1281 short int x_src; /* position (x, y) of rect to start moving from */
1283 short int x_dst; /* position (x, y) of rect to move to */
1285 short int w; /* size of the rect (width, height) to move */
1290 /* Sends a signal to a process group */
1291 @REQ(send_console_signal)
1292 int signal; /* the signal to send */
1293 process_id_t group_id; /* the group to send the signal to */
1297 /* enable directory change notifications */
1298 @REQ(read_directory_changes)
1299 unsigned int filter; /* notification filter */
1300 obj_handle_t handle; /* handle to the directory */
1301 int subtree; /* watch the subtree? */
1302 int want_data; /* flag indicating whether change data should be collected */
1303 async_data_t async; /* async I/O parameters */
1308 obj_handle_t handle;
1310 int action; /* type of change */
1311 VARARG(name,string); /* name of directory entry that changed */
1315 /* Create a file mapping */
1316 @REQ(create_mapping)
1317 unsigned int access; /* wanted access rights */
1318 unsigned int attributes; /* object attributes */
1319 file_pos_t size; /* mapping size */
1320 unsigned int protect; /* protection flags (see below) */
1321 obj_handle_t file_handle; /* file handle */
1322 VARARG(objattr,object_attributes); /* object attributes */
1324 obj_handle_t handle; /* handle to the mapping */
1326 /* per-page protection flags */
1327 #define VPROT_READ 0x01
1328 #define VPROT_WRITE 0x02
1329 #define VPROT_EXEC 0x04
1330 #define VPROT_WRITECOPY 0x08
1331 #define VPROT_GUARD 0x10
1332 #define VPROT_NOCACHE 0x20
1333 #define VPROT_COMMITTED 0x40
1334 #define VPROT_WRITEWATCH 0x80
1335 /* per-mapping protection flags */
1336 #define VPROT_IMAGE 0x0100 /* mapping for an exe image */
1337 #define VPROT_SYSTEM 0x0200 /* system view (underlying mmap not under our control) */
1338 #define VPROT_VALLOC 0x0400 /* allocated by VirtualAlloc */
1339 #define VPROT_NOEXEC 0x0800 /* don't force exec permission
*/
1342 /* Open a mapping
*/
1344 unsigned int access
; /* wanted access rights
*/
1345 unsigned int attributes
; /* object attributes
*/
1346 obj_handle_t rootdir
; /* root directory
*/
1347 VARARG(name
,unicode_str
); /* object name
*/
1349 obj_handle_t handle
; /* handle to the mapping
*/
1353 /* Get information about a file mapping
*/
1354 @
REQ(get_mapping_info
)
1355 obj_handle_t handle
; /* handle to the mapping
*/
1356 unsigned int access
; /* wanted access rights
*/
1358 file_pos_t size
; /* mapping size
*/
1359 int protect
; /* protection flags
*/
1360 int header_size
; /* header
size (for VPROT_IMAGE mapping
) */
1361 void
* base
; /* default base
addr (for VPROT_IMAGE mapping
) */
1362 obj_handle_t mapping
; /* duplicate mapping handle unless removable
*/
1363 obj_handle_t shared_file
; /* shared mapping file handle
*/
1367 /* Get a range of committed pages in a file mapping
*/
1368 @
REQ(get_mapping_committed_range
)
1369 obj_handle_t handle
; /* handle to the mapping
*/
1370 file_pos_t offset
; /* starting
offset (page
-aligned
, in bytes
) */
1372 file_pos_t size
; /* size of range starting at
offset (page
-aligned
, in bytes
) */
1373 int committed
; /* whether it is a committed range
*/
1377 /* Add a range to the committed pages in a file mapping
*/
1378 @
REQ(add_mapping_committed_range
)
1379 obj_handle_t handle
; /* handle to the mapping
*/
1380 file_pos_t offset
; /* starting
offset (page
-aligned
, in bytes
) */
1381 file_pos_t size
; /* size to
set (page
-aligned
, in bytes
) or
0 if only retrieving
*/
1385 #define SNAP_PROCESS
0x00000001
1386 #define SNAP_THREAD
0x00000002
1387 /* Create a snapshot
*/
1388 @
REQ(create_snapshot
)
1389 unsigned int attributes
; /* object attributes
*/
1390 unsigned int flags
; /* snapshot
flags (SNAP_*)
*/
1392 obj_handle_t handle
; /* handle to the snapshot
*/
1396 /* Get the next process from a snapshot
*/
1398 obj_handle_t handle
; /* handle to the snapshot
*/
1399 int reset
; /* reset snapshot position?
*/
1401 int count
; /* process usage count
*/
1402 process_id_t pid
; /* process id
*/
1403 process_id_t ppid
; /* parent process id
*/
1404 int threads
; /* number of threads
*/
1405 int priority
; /* process priority
*/
1406 int handles
; /* number of handles
*/
1407 VARARG(filename
,unicode_str
); /* file name of main exe
*/
1411 /* Get the next thread from a snapshot
*/
1413 obj_handle_t handle
; /* handle to the snapshot
*/
1414 int reset
; /* reset snapshot position?
*/
1416 int count
; /* thread usage count
*/
1417 process_id_t pid
; /* process id
*/
1418 thread_id_t tid
; /* thread id
*/
1419 int base_pri
; /* base priority
*/
1420 int delta_pri
; /* delta priority
*/
1424 /* Wait for a debug event
*/
1425 @
REQ(wait_debug_event
)
1426 int get_handle
; /* should we alloc a handle for waiting?
*/
1428 process_id_t pid
; /* process id
*/
1429 thread_id_t tid
; /* thread id
*/
1430 obj_handle_t wait
; /* wait handle if no event ready
*/
1431 VARARG(event
,debug_event
); /* debug event data
*/
1435 /* Queue an exception event
*/
1436 @
REQ(queue_exception_event
)
1437 int first
; /* first chance exception?
*/
1438 VARARG(record
,exc_event
); /* thread context followed by exception record
*/
1440 obj_handle_t handle
; /* handle to the queued event
*/
1444 /* Retrieve the status of an exception event
*/
1445 @
REQ(get_exception_status
)
1446 obj_handle_t handle
; /* handle to the queued event
*/
1448 VARARG(context
,context
); /* modified thread context
*/
1452 /* Send an output string to the debugger
*/
1453 @
REQ(output_debug_string
)
1454 void
* string
; /* string to
display (in debugged process address space
) */
1455 int unicode
; /* is it Unicode?
*/
1456 int length
; /* string length
*/
1460 /* Continue a debug event
*/
1461 @
REQ(continue_debug_event
)
1462 process_id_t pid
; /* process id to continue
*/
1463 thread_id_t tid
; /* thread id to continue
*/
1464 int status
; /* continuation status
*/
1468 /* Start
/stop debugging an existing process
*/
1470 process_id_t pid
; /* id of the process to debug
*/
1471 int attach
; /* 1=attaching
/ 0=detaching from the process
*/
1475 /* Simulate a breakpoint in a process
*/
1477 obj_handle_t handle
; /* process handle
*/
1479 int self
; /* was it the caller itself?
*/
1483 /* Set debugger kill on exit flag
*/
1484 @
REQ(set_debugger_kill_on_exit
)
1485 int kill_on_exit
; /* 0=detach
/1=kill debuggee when debugger dies
*/
1489 /* Read data from a process address space
*/
1490 @
REQ(read_process_memory
)
1491 obj_handle_t handle
; /* process handle
*/
1492 void
* addr
; /* addr to read from
*/
1494 VARARG(data
,bytes
); /* result data
*/
1498 /* Write data to a process address space
*/
1499 @
REQ(write_process_memory
)
1500 obj_handle_t handle
; /* process handle
*/
1501 void
* addr
; /* addr to write to
*/
1502 VARARG(data
,bytes
); /* data to write
*/
1506 /* Create a registry key
*/
1508 obj_handle_t parent
; /* handle to the parent key
*/
1509 unsigned int access
; /* desired access rights
*/
1510 unsigned int attributes
; /* object attributes
*/
1511 unsigned int options
; /* creation options
*/
1512 data_size_t namelen
; /* length of key name in bytes
*/
1513 VARARG(name
,unicode_str
,namelen
); /* key name
*/
1514 VARARG(class
,unicode_str
); /* class name
*/
1516 obj_handle_t hkey
; /* handle to the created key
*/
1517 int created
; /* has it been newly created?
*/
1520 /* Open a registry key
*/
1522 obj_handle_t parent
; /* handle to the parent key
*/
1523 unsigned int access
; /* desired access rights
*/
1524 unsigned int attributes
; /* object attributes
*/
1525 VARARG(name
,unicode_str
); /* key name
*/
1527 obj_handle_t hkey
; /* handle to the open key
*/
1531 /* Delete a registry key
*/
1533 obj_handle_t hkey
; /* handle to the key
*/
1537 /* Flush a registry key
*/
1539 obj_handle_t hkey
; /* handle to the key
*/
1543 /* Enumerate registry subkeys
*/
1545 obj_handle_t hkey
; /* handle to registry key
*/
1546 int index
; /* index of
subkey (or
-1 for current key
) */
1547 int info_class
; /* requested information class
*/
1549 int subkeys
; /* number of subkeys
*/
1550 int max_subkey
; /* longest subkey name
*/
1551 int max_class
; /* longest class name
*/
1552 int values
; /* number of values
*/
1553 int max_value
; /* longest value name
*/
1554 int max_data
; /* longest value data
*/
1555 timeout_t modif
; /* last modification time
*/
1556 data_size_t total
; /* total length needed for full name and class
*/
1557 data_size_t namelen
; /* length of key name in bytes
*/
1558 VARARG(name
,unicode_str
,namelen
); /* key name
*/
1559 VARARG(class
,unicode_str
); /* class name
*/
1563 /* Set a value of a registry key
*/
1565 obj_handle_t hkey
; /* handle to registry key
*/
1566 int type
; /* value type
*/
1567 data_size_t namelen
; /* length of value name in bytes
*/
1568 VARARG(name
,unicode_str
,namelen
); /* value name
*/
1569 VARARG(data
,bytes
); /* value data
*/
1573 /* Retrieve the value of a registry key
*/
1575 obj_handle_t hkey
; /* handle to registry key
*/
1576 VARARG(name
,unicode_str
); /* value name
*/
1578 int type
; /* value type
*/
1579 data_size_t total
; /* total length needed for data
*/
1580 VARARG(data
,bytes
); /* value data
*/
1584 /* Enumerate a value of a registry key
*/
1585 @
REQ(enum_key_value
)
1586 obj_handle_t hkey
; /* handle to registry key
*/
1587 int index
; /* value index
*/
1588 int info_class
; /* requested information class
*/
1590 int type
; /* value type
*/
1591 data_size_t total
; /* total length needed for full name and data
*/
1592 data_size_t namelen
; /* length of value name in bytes
*/
1593 VARARG(name
,unicode_str
,namelen
); /* value name
*/
1594 VARARG(data
,bytes
); /* value data
*/
1598 /* Delete a value of a registry key
*/
1599 @
REQ(delete_key_value
)
1600 obj_handle_t hkey
; /* handle to registry key
*/
1601 VARARG(name
,unicode_str
); /* value name
*/
1605 /* Load a registry branch from a file
*/
1607 obj_handle_t hkey
; /* root key to load to
*/
1608 obj_handle_t file
; /* file to load from
*/
1609 VARARG(name
,unicode_str
); /* subkey name
*/
1613 /* UnLoad a registry branch from a file
*/
1614 @
REQ(unload_registry
)
1615 obj_handle_t hkey
; /* root key to unload to
*/
1619 /* Save a registry branch to a file
*/
1621 obj_handle_t hkey
; /* key to save
*/
1622 obj_handle_t file
; /* file to save to
*/
1626 /* Add a registry key change notification
*/
1627 @
REQ(set_registry_notification
)
1628 obj_handle_t hkey
; /* key to watch for changes
*/
1629 obj_handle_t event
; /* event to set
*/
1630 int subtree
; /* should we watch the whole subtree?
*/
1631 unsigned int filter
; /* things to watch
*/
1635 /* Create a waitable timer
*/
1637 unsigned int access
; /* wanted access rights
*/
1638 unsigned int attributes
; /* object attributes
*/
1639 obj_handle_t rootdir
; /* root directory
*/
1640 int manual
; /* manual reset
*/
1641 VARARG(name
,unicode_str
); /* object name
*/
1643 obj_handle_t handle
; /* handle to the timer
*/
1647 /* Open a waitable timer
*/
1649 unsigned int access
; /* wanted access rights
*/
1650 unsigned int attributes
; /* object attributes
*/
1651 obj_handle_t rootdir
; /* root directory
*/
1652 VARARG(name
,unicode_str
); /* object name
*/
1654 obj_handle_t handle
; /* handle to the timer
*/
1657 /* Set a waitable timer
*/
1659 obj_handle_t handle
; /* handle to the timer
*/
1660 timeout_t expire
; /* next expiration absolute time
*/
1661 int period
; /* timer period in ms
*/
1662 void
* callback
; /* callback function
*/
1663 void
* arg
; /* callback argument
*/
1665 int signaled
; /* was the timer signaled before this call ?
*/
1668 /* Cancel a waitable timer
*/
1670 obj_handle_t handle
; /* handle to the timer
*/
1672 int signaled
; /* was the timer signaled before this calltime ?
*/
1675 /* Get information on a waitable timer
*/
1676 @
REQ(get_timer_info
)
1677 obj_handle_t handle
; /* handle to the timer
*/
1679 timeout_t when
; /* absolute time when the timer next expires
*/
1680 int signaled
; /* is the timer signaled?
*/
1684 /* Retrieve the current context of a thread
*/
1685 @
REQ(get_thread_context
)
1686 obj_handle_t handle
; /* thread handle
*/
1687 unsigned int flags
; /* context flags
*/
1688 int suspend
; /* if getting context during suspend
*/
1690 int self
; /* was it a handle to the current thread?
*/
1691 VARARG(context
,context
); /* thread context
*/
1695 /* Set the current context of a thread
*/
1696 @
REQ(set_thread_context
)
1697 obj_handle_t handle
; /* thread handle
*/
1698 unsigned int flags
; /* context flags
*/
1699 int suspend
; /* if setting context during suspend
*/
1700 VARARG(context
,context
); /* thread context
*/
1702 int self
; /* was it a handle to the current thread?
*/
1706 /* Fetch a selector entry for a thread
*/
1707 @
REQ(get_selector_entry
)
1708 obj_handle_t handle
; /* thread handle
*/
1709 int entry
; /* LDT entry
*/
1711 unsigned int base
; /* selector base
*/
1712 unsigned int limit
; /* selector limit
*/
1713 unsigned char flags
; /* selector flags
*/
1719 obj_handle_t table
; /* which table to add atom to
*/
1720 VARARG(name
,unicode_str
); /* atom name
*/
1722 atom_t atom
; /* resulting atom
*/
1726 /* Delete an atom
*/
1728 obj_handle_t table
; /* which table to delete atom from
*/
1729 atom_t atom
; /* atom handle
*/
1735 obj_handle_t table
; /* which table to find atom from
*/
1736 VARARG(name
,unicode_str
); /* atom name
*/
1738 atom_t atom
; /* atom handle
*/
1742 /* Get information about an atom
*/
1743 @
REQ(get_atom_information
)
1744 obj_handle_t table
; /* which table to find atom from
*/
1745 atom_t atom
; /* atom handle
*/
1747 int count
; /* atom lock count
*/
1748 int pinned
; /* whether the atom has been pinned
*/
1749 data_size_t total
; /* actual length of atom name
*/
1750 VARARG(name
,unicode_str
); /* atom name
*/
1754 /* Set information about an atom
*/
1755 @
REQ(set_atom_information
)
1756 obj_handle_t table
; /* which table to find atom from
*/
1757 atom_t atom
; /* atom handle
*/
1758 int pinned
; /* whether to bump atom information
*/
1762 /* Empty an atom table
*/
1763 @
REQ(empty_atom_table
)
1764 obj_handle_t table
; /* which table to find atom from
*/
1765 int if_pinned
; /* whether to delete pinned atoms
*/
1769 /* Init an atom table
*/
1770 @
REQ(init_atom_table
)
1771 int entries
; /* number of
entries (only for local
) */
1773 obj_handle_t table
; /* handle to the atom table
*/
1777 /* Get the message queue of the current thread
*/
1780 obj_handle_t handle
; /* handle to the queue
*/
1784 /* Set the file descriptor associated to the current thread queue
*/
1786 obj_handle_t handle
; /* handle to the file descriptor
*/
1790 /* Set the current message queue wakeup mask
*/
1791 @
REQ(set_queue_mask
)
1792 unsigned int wake_mask
; /* wakeup bits mask
*/
1793 unsigned int changed_mask
; /* changed bits mask
*/
1794 int skip_wait
; /* will we skip waiting if signaled?
*/
1796 unsigned int wake_bits
; /* current wake bits
*/
1797 unsigned int changed_bits
; /* current changed bits
*/
1801 /* Get the current message queue status
*/
1802 @
REQ(get_queue_status
)
1803 int clear
; /* should we clear the change bits?
*/
1805 unsigned int wake_bits
; /* wake bits
*/
1806 unsigned int changed_bits
; /* changed bits since last time
*/
1810 /* Retrieve the process idle event
*/
1811 @
REQ(get_process_idle_event
)
1812 obj_handle_t handle
; /* process handle
*/
1814 obj_handle_t event
; /* handle to idle event
*/
1818 /* Send a message to a thread queue
*/
1820 thread_id_t id
; /* thread id
*/
1821 int type
; /* message
type (see below
) */
1822 int flags
; /* message
flags (see below
) */
1823 user_handle_t win
; /* window handle
*/
1824 unsigned int msg
; /* message code
*/
1825 lparam_t wparam
; /* parameters
*/
1826 lparam_t lparam
; /* parameters
*/
1827 timeout_t timeout
; /* timeout for reply
*/
1828 VARARG(data
,message_data
); /* message data for sent messages
*/
1831 @
REQ(post_quit_message
)
1832 int exit_code
; /* exit code to return
*/
1837 MSG_ASCII
, /* Ascii
message (from SendMessageA
) */
1838 MSG_UNICODE
, /* Unicode
message (from SendMessageW
) */
1839 MSG_NOTIFY
, /* notify
message (from SendNotifyMessageW
), always Unicode
*/
1840 MSG_CALLBACK
, /* callback
message (from SendMessageCallbackW
), always Unicode
*/
1841 MSG_CALLBACK_RESULT
,/* result of a callback message
*/
1842 MSG_OTHER_PROCESS
, /* sent from other process
, may include vararg data
, always Unicode
*/
1843 MSG_POSTED
, /* posted
message (from PostMessageW
), always Unicode
*/
1844 MSG_HARDWARE
, /* hardware message
*/
1845 MSG_WINEVENT
/* winevent message
*/
1847 #define SEND_MSG_ABORT_IF_HUNG
0x01
1850 /* Send a hardware message to a thread queue
*/
1851 @
REQ(send_hardware_message
)
1852 thread_id_t id
; /* thread id
*/
1853 user_handle_t win
; /* window handle
*/
1854 unsigned int msg
; /* message code
*/
1855 unsigned int time
; /* message time
*/
1856 lparam_t wparam
; /* parameters
*/
1857 lparam_t lparam
; /* parameters
*/
1858 lparam_t info
; /* extra info
*/
1859 int x
; /* x position
*/
1860 int y
; /* y position
*/
1864 /* Get a message from the current queue
*/
1866 unsigned int flags
; /* PM_
* flags
*/
1867 user_handle_t get_win
; /* window handle to get
*/
1868 unsigned int get_first
; /* first message code to get
*/
1869 unsigned int get_last
; /* last message code to get
*/
1870 unsigned int hw_id
; /* id of the previous hardware
message (or
0) */
1871 unsigned int wake_mask
; /* wakeup bits mask
*/
1872 unsigned int changed_mask
; /* changed bits mask
*/
1874 user_handle_t win
; /* window handle
*/
1875 int type
; /* message type
*/
1876 unsigned int msg
; /* message code
*/
1877 lparam_t wparam
; /* parameters
*/
1878 lparam_t lparam
; /* parameters
*/
1879 lparam_t info
; /* extra info
*/
1880 int x
; /* x position
*/
1881 int y
; /* y position
*/
1882 unsigned int time
; /* message time
*/
1883 unsigned int hw_id
; /* id if hardware message
*/
1884 unsigned int active_hooks
; /* active hooks bitmap
*/
1885 data_size_t total
; /* total size of extra data
*/
1886 VARARG(data
,message_data
); /* message data for sent messages
*/
1890 /* Reply to a sent message
*/
1892 lparam_t result
; /* message result
*/
1893 int remove
; /* should we remove the message?
*/
1894 VARARG(data
,bytes
); /* message data for sent messages
*/
1898 /* Accept the current hardware message
*/
1899 @
REQ(accept_hardware_message
)
1900 unsigned int hw_id
; /* id of the hardware message
*/
1901 int remove
; /* should we remove the message?
*/
1902 user_handle_t new_win
; /* new destination window for current message
*/
1906 /* Retrieve the reply for the last message sent
*/
1907 @
REQ(get_message_reply
)
1908 int cancel
; /* cancel message if not ready?
*/
1910 lparam_t result
; /* message result
*/
1911 VARARG(data
,bytes
); /* message data for sent messages
*/
1915 /* Set a window timer
*/
1917 user_handle_t win
; /* window handle
*/
1918 unsigned int msg
; /* message to post
*/
1919 unsigned int rate
; /* timer rate in ms
*/
1920 lparam_t id
; /* timer id
*/
1921 lparam_t lparam
; /* message
lparam (callback proc
) */
1923 lparam_t id
; /* timer id
*/
1927 /* Kill a window timer
*/
1928 @
REQ(kill_win_timer
)
1929 user_handle_t win
; /* window handle
*/
1930 unsigned int msg
; /* message to post
*/
1931 lparam_t id
; /* timer id
*/
1935 /* check if the thread owning the window is hung
*/
1936 @
REQ(is_window_hung
)
1937 user_handle_t win
; /* window handle
*/
1943 /* Retrieve info about a serial port
*/
1944 @
REQ(get_serial_info
)
1945 obj_handle_t handle
; /* handle to comm port
*/
1947 unsigned int readinterval
;
1948 unsigned int readconst
;
1949 unsigned int readmult
;
1950 unsigned int writeconst
;
1951 unsigned int writemult
;
1952 unsigned int eventmask
;
1956 /* Set info about a serial port
*/
1957 @
REQ(set_serial_info
)
1958 obj_handle_t handle
; /* handle to comm port
*/
1959 int flags
; /* bitmask to set
values (see below
) */
1960 unsigned int readinterval
;
1961 unsigned int readconst
;
1962 unsigned int readmult
;
1963 unsigned int writeconst
;
1964 unsigned int writemult
;
1965 unsigned int eventmask
;
1967 #define SERIALINFO_SET_TIMEOUTS
0x01
1968 #define SERIALINFO_SET_MASK
0x02
1971 /* Create an async I
/O
*/
1972 @
REQ(register_async
)
1973 obj_handle_t handle
; /* handle to comm port
, socket or file
*/
1974 int type
; /* type of queue to look after
*/
1975 int count
; /* count
- usually # of bytes to be read
/written
*/
1976 async_data_t async
; /* async I
/O parameters
*/
1978 #define ASYNC_TYPE_READ
0x01
1979 #define ASYNC_TYPE_WRITE
0x02
1980 #define ASYNC_TYPE_WAIT
0x03
1983 /* Cancel all async op on a fd
*/
1985 obj_handle_t handle
; /* handle to comm port
, socket or file
*/
1989 /* Perform an ioctl on a file
*/
1991 obj_handle_t handle
; /* handle to the device
*/
1992 ioctl_code_t code
; /* ioctl code
*/
1993 async_data_t async
; /* async I
/O parameters
*/
1994 VARARG(in_data
,bytes
); /* ioctl input data
*/
1996 obj_handle_t wait
; /* handle to wait on for blocking ioctl
*/
1997 unsigned int options
; /* device open options
*/
1998 VARARG(out_data
,bytes
); /* ioctl output data
*/
2002 /* Retrieve results of an async ioctl
*/
2003 @
REQ(get_ioctl_result
)
2004 obj_handle_t handle
; /* handle to the device
*/
2005 void
* user_arg
; /* user arg used to identify the request
*/
2007 VARARG(out_data
,bytes
); /* ioctl output data
*/
2011 /* Create a named pipe
*/
2012 @
REQ(create_named_pipe
)
2013 unsigned int access
;
2014 unsigned int attributes
; /* object attributes
*/
2015 obj_handle_t rootdir
; /* root directory
*/
2016 unsigned int options
;
2018 unsigned int maxinstances
;
2019 unsigned int outsize
;
2020 unsigned int insize
;
2022 VARARG(name
,unicode_str
); /* pipe name
*/
2024 obj_handle_t handle
; /* handle to the pipe
*/
2027 /* flags in create_named_pipe and get_named_pipe_info
*/
2028 #define NAMED_PIPE_MESSAGE_STREAM_WRITE
0x0001
2029 #define NAMED_PIPE_MESSAGE_STREAM_READ
0x0002
2030 #define NAMED_PIPE_NONBLOCKING_MODE
0x0004
2031 #define NAMED_PIPE_SERVER_END
0x8000
2034 @
REQ(get_named_pipe_info
)
2035 obj_handle_t handle
;
2038 unsigned int maxinstances
;
2039 unsigned int instances
;
2040 unsigned int outsize
;
2041 unsigned int insize
;
2045 /* Create a window
*/
2047 user_handle_t parent
; /* parent window
*/
2048 user_handle_t owner
; /* owner window
*/
2049 atom_t atom
; /* class atom
*/
2050 void
* instance
; /* module instance
*/
2051 VARARG(class
,unicode_str
); /* class name
*/
2053 user_handle_t handle
; /* created window
*/
2054 user_handle_t parent
; /* full handle of parent
*/
2055 user_handle_t owner
; /* full handle of owner
*/
2056 int extra
; /* number of extra bytes
*/
2057 void
* class_ptr
; /* pointer to class in client address space
*/
2061 /* Destroy a window
*/
2062 @
REQ(destroy_window
)
2063 user_handle_t handle
; /* handle to the window
*/
2067 /* Retrieve the desktop window for the current thread
*/
2068 @
REQ(get_desktop_window
)
2069 int force
; /* force creation if it doesn
't exist */
2071 user_handle_t top_window; /* handle to the desktop window */
2072 user_handle_t msg_window; /* handle to the top-level HWND_MESSAGE parent */
2076 /* Set a window owner */
2077 @REQ(set_window_owner)
2078 user_handle_t handle; /* handle to the window */
2079 user_handle_t owner; /* new owner */
2081 user_handle_t full_owner; /* full handle of new owner */
2082 user_handle_t prev_owner; /* full handle of previous owner */
2086 /* Get information from a window handle */
2087 @REQ(get_window_info)
2088 user_handle_t handle; /* handle to the window */
2090 user_handle_t full_handle; /* full 32-bit handle */
2091 user_handle_t last_active; /* last active popup */
2092 process_id_t pid; /* process owning the window */
2093 thread_id_t tid; /* thread owning the window */
2094 atom_t atom; /* class atom */
2095 int is_unicode; /* ANSI or unicode */
2099 /* Set some information in a window */
2100 @REQ(set_window_info)
2101 unsigned int flags; /* flags for fields to set (see below) */
2102 user_handle_t handle; /* handle to the window */
2103 unsigned int style; /* window style */
2104 unsigned int ex_style; /* window extended style */
2105 unsigned int id; /* window id */
2106 int is_unicode; /* ANSI or unicode */
2107 void* instance; /* creator instance */
2108 lparam_t user_data; /* user-specific data */
2109 int extra_offset; /* offset to set in extra bytes */
2110 data_size_t extra_size; /* size to set in extra bytes */
2111 lparam_t extra_value; /* value to set in extra bytes */
2113 unsigned int old_style; /* old window style */
2114 unsigned int old_ex_style; /* old window extended style */
2115 unsigned int old_id; /* old window id */
2116 void* old_instance; /* old creator instance */
2117 lparam_t old_user_data; /* old user-specific data */
2118 lparam_t old_extra_value; /* old value in extra bytes */
2120 #define SET_WIN_STYLE 0x01
2121 #define SET_WIN_EXSTYLE 0x02
2122 #define SET_WIN_ID 0x04
2123 #define SET_WIN_INSTANCE 0x08
2124 #define SET_WIN_USERDATA 0x10
2125 #define SET_WIN_EXTRA 0x20
2126 #define SET_WIN_UNICODE 0x40
2129 /* Set the parent of a window */
2131 user_handle_t handle; /* handle to the window */
2132 user_handle_t parent; /* handle to the parent */
2134 user_handle_t old_parent; /* old parent window */
2135 user_handle_t full_parent; /* full handle of new parent */
2139 /* Get a list of the window parents, up to the root of the tree */
2140 @REQ(get_window_parents)
2141 user_handle_t handle; /* handle to the window */
2143 int count; /* total count of parents */
2144 VARARG(parents,user_handles); /* parent handles */
2148 /* Get a list of the window children */
2149 @REQ(get_window_children)
2150 obj_handle_t desktop; /* handle to desktop */
2151 user_handle_t parent; /* parent window */
2152 atom_t atom; /* class atom for the listed children */
2153 thread_id_t tid; /* thread owning the listed children */
2154 VARARG(class,unicode_str); /* class name */
2156 int count; /* total count of children */
2157 VARARG(children,user_handles); /* children handles */
2161 /* Get a list of the window children that contain a given point */
2162 @REQ(get_window_children_from_point)
2163 user_handle_t parent; /* parent window */
2164 int x; /* point in parent coordinates */
2167 int count; /* total count of children */
2168 VARARG(children,user_handles); /* children handles */
2172 /* Get window tree information from a window handle */
2173 @REQ(get_window_tree)
2174 user_handle_t handle; /* handle to the window */
2176 user_handle_t parent; /* parent window */
2177 user_handle_t owner; /* owner window */
2178 user_handle_t next_sibling; /* next sibling in Z-order */
2179 user_handle_t prev_sibling; /* prev sibling in Z-order */
2180 user_handle_t first_sibling; /* first sibling in Z-order */
2181 user_handle_t last_sibling; /* last sibling in Z-order */
2182 user_handle_t first_child; /* first child */
2183 user_handle_t last_child; /* last child */
2186 /* Set the position and Z order of a window */
2187 @REQ(set_window_pos)
2188 unsigned int flags; /* SWP_* flags */
2189 user_handle_t handle; /* handle to the window */
2190 user_handle_t previous; /* previous window in Z order */
2191 rectangle_t window; /* window rectangle */
2192 rectangle_t client; /* client rectangle */
2193 VARARG(valid,rectangles); /* valid rectangles from WM_NCCALCSIZE */
2195 unsigned int new_style; /* new window style */
2196 unsigned int new_ex_style; /* new window extended style */
2200 /* Get the window and client rectangles of a window */
2201 @REQ(get_window_rectangles)
2202 user_handle_t handle; /* handle to the window */
2204 rectangle_t window; /* window rectangle */
2205 rectangle_t visible; /* visible part of the window rectangle */
2206 rectangle_t client; /* client rectangle */
2210 /* Get the window text */
2211 @REQ(get_window_text)
2212 user_handle_t handle; /* handle to the window */
2214 VARARG(text,unicode_str); /* window text */
2218 /* Set the window text */
2219 @REQ(set_window_text)
2220 user_handle_t handle; /* handle to the window */
2221 VARARG(text,unicode_str); /* window text */
2225 /* Get the coordinates offset between two windows */
2226 @REQ(get_windows_offset)
2227 user_handle_t from; /* handle to the first window */
2228 user_handle_t to; /* handle to the second window */
2230 int x; /* x coordinate offset */
2231 int y; /* y coordinate offset */
2235 /* Get the visible region of a window */
2236 @REQ(get_visible_region)
2237 user_handle_t window; /* handle to the window */
2238 unsigned int flags; /* DCX flags */
2240 user_handle_t top_win; /* top window to clip against */
2241 rectangle_t top_rect; /* top window visible rect with screen coords */
2242 rectangle_t win_rect; /* window rect in screen coords */
2243 data_size_t total_size; /* total size of the resulting region */
2244 VARARG(region,rectangles); /* list of rectangles for the region (in screen coords) */
2248 /* Get the window region */
2249 @REQ(get_window_region)
2250 user_handle_t window; /* handle to the window */
2252 data_size_t total_size; /* total size of the resulting region */
2253 VARARG(region,rectangles); /* list of rectangles for the region */
2257 /* Set the window region */
2258 @REQ(set_window_region)
2259 user_handle_t window; /* handle to the window */
2260 int redraw; /* redraw the window? */
2261 VARARG(region,rectangles); /* list of rectangles for the region */
2265 /* Get the window update region */
2266 @REQ(get_update_region)
2267 user_handle_t window; /* handle to the window */
2268 user_handle_t from_child; /* child to start searching from */
2269 unsigned int flags; /* update flags (see below) */
2271 user_handle_t child; /* child to repaint (or window itself) */
2272 unsigned int flags; /* resulting update flags (see below) */
2273 data_size_t total_size; /* total size of the resulting region */
2274 VARARG(region,rectangles); /* list of rectangles for the region */
2276 #define UPDATE_NONCLIENT 0x01 /* get region for repainting non-client area */
2277 #define UPDATE_ERASE 0x02 /* get region for erasing client area */
2278 #define UPDATE_PAINT 0x04 /* get region for painting client area */
2279 #define UPDATE_INTERNALPAINT 0x08 /* get region if internal paint is pending */
2280 #define UPDATE_ALLCHILDREN 0x10 /* force repaint of all children */
2281 #define UPDATE_NOCHILDREN 0x20 /* don't try to repaint any children
*/
2282 #define UPDATE_NOREGION
0x40 /* don
't return a region, only the flags */
2283 #define UPDATE_DELAYED_ERASE 0x80 /* still needs erase after BeginPaint */
2286 /* Update the z order of a window so that a given rectangle is fully visible */
2287 @REQ(update_window_zorder)
2288 user_handle_t window; /* handle to the window */
2289 rectangle_t rect; /* rectangle that must be visible */
2293 /* Mark parts of a window as needing a redraw */
2295 user_handle_t window; /* handle to the window */
2296 unsigned int flags; /* RDW_* flags */
2297 VARARG(region,rectangles); /* list of rectangles for the region */
2301 /* Set a window property */
2302 @REQ(set_window_property)
2303 user_handle_t window; /* handle to the window */
2304 atom_t atom; /* property atom (if no name specified) */
2305 obj_handle_t handle; /* handle to store */
2306 VARARG(name,unicode_str); /* property name */
2310 /* Remove a window property */
2311 @REQ(remove_window_property)
2312 user_handle_t window; /* handle to the window */
2313 atom_t atom; /* property atom (if no name specified) */
2314 VARARG(name,unicode_str); /* property name */
2316 obj_handle_t handle; /* handle stored in property */
2320 /* Get a window property */
2321 @REQ(get_window_property)
2322 user_handle_t window; /* handle to the window */
2323 atom_t atom; /* property atom (if no name specified) */
2324 VARARG(name,unicode_str); /* property name */
2326 obj_handle_t handle; /* handle stored in property */
2330 /* Get the list of properties of a window */
2331 @REQ(get_window_properties)
2332 user_handle_t window; /* handle to the window */
2334 int total; /* total number of properties */
2335 VARARG(props,properties); /* list of properties */
2339 /* Create a window station */
2340 @REQ(create_winstation)
2341 unsigned int flags; /* window station flags */
2342 unsigned int access; /* wanted access rights */
2343 unsigned int attributes; /* object attributes */
2344 VARARG(name,unicode_str); /* object name */
2346 obj_handle_t handle; /* handle to the window station */
2350 /* Open a handle to a window station */
2351 @REQ(open_winstation)
2352 unsigned int access; /* wanted access rights */
2353 unsigned int attributes; /* object attributes */
2354 VARARG(name,unicode_str); /* object name */
2356 obj_handle_t handle; /* handle to the window station */
2360 /* Close a window station */
2361 @REQ(close_winstation)
2362 obj_handle_t handle; /* handle to the window station */
2366 /* Get the process current window station */
2367 @REQ(get_process_winstation)
2369 obj_handle_t handle; /* handle to the window station */
2373 /* Set the process current window station */
2374 @REQ(set_process_winstation)
2375 obj_handle_t handle; /* handle to the window station */
2379 /* Enumerate window stations */
2380 @REQ(enum_winstation)
2381 unsigned int index; /* current index */
2383 unsigned int next; /* next index */
2384 VARARG(name,unicode_str); /* window station name */
2388 /* Create a desktop */
2389 @REQ(create_desktop)
2390 unsigned int flags; /* desktop flags */
2391 unsigned int access; /* wanted access rights */
2392 unsigned int attributes; /* object attributes */
2393 VARARG(name,unicode_str); /* object name */
2395 obj_handle_t handle; /* handle to the desktop */
2399 /* Open a handle to a desktop */
2401 obj_handle_t winsta; /* window station to open (null allowed) */
2402 unsigned int flags; /* desktop flags */
2403 unsigned int access; /* wanted access rights */
2404 unsigned int attributes; /* object attributes */
2405 VARARG(name,unicode_str); /* object name */
2407 obj_handle_t handle; /* handle to the desktop */
2411 /* Close a desktop */
2413 obj_handle_t handle; /* handle to the desktop */
2417 /* Get the thread current desktop */
2418 @REQ(get_thread_desktop)
2419 thread_id_t tid; /* thread id */
2421 obj_handle_t handle; /* handle to the desktop */
2425 /* Set the thread current desktop */
2426 @REQ(set_thread_desktop)
2427 obj_handle_t handle; /* handle to the desktop */
2431 /* Enumerate desktops */
2433 obj_handle_t winstation; /* handle to the window station */
2434 unsigned int index; /* current index */
2436 unsigned int next; /* next index */
2437 VARARG(name,unicode_str); /* window station name */
2441 /* Get/set information about a user object (window station or desktop) */
2442 @REQ(set_user_object_info)
2443 obj_handle_t handle; /* handle to the object */
2444 unsigned int flags; /* information to set */
2445 unsigned int obj_flags; /* new object flags */
2447 int is_desktop; /* is object a desktop? */
2448 unsigned int old_obj_flags; /* old object flags */
2449 VARARG(name,unicode_str); /* object name */
2451 #define SET_USER_OBJECT_FLAGS 1
2454 /* Attach (or detach) thread inputs */
2455 @REQ(attach_thread_input)
2456 thread_id_t tid_from; /* thread to be attached */
2457 thread_id_t tid_to; /* thread to which tid_from should be attached */
2458 int attach; /* is it an attach? */
2462 /* Get input data for a given thread */
2463 @REQ(get_thread_input)
2464 thread_id_t tid; /* id of thread */
2466 user_handle_t focus; /* handle to the focus window */
2467 user_handle_t capture; /* handle to the capture window */
2468 user_handle_t active; /* handle to the active window */
2469 user_handle_t foreground; /* handle to the global foreground window */
2470 user_handle_t menu_owner; /* handle to the menu owner */
2471 user_handle_t move_size; /* handle to the moving/resizing window */
2472 user_handle_t caret; /* handle to the caret window */
2473 rectangle_t rect; /* caret rectangle */
2477 /* Get the time of the last input event */
2478 @REQ(get_last_input_time)
2484 /* Retrieve queue keyboard state for a given thread */
2486 thread_id_t tid; /* id of thread */
2487 int key; /* optional key code or -1 */
2489 unsigned char state; /* state of specified key */
2490 VARARG(keystate,bytes); /* state array for all the keys */
2493 /* Set queue keyboard state for a given thread */
2495 thread_id_t tid; /* id of thread */
2496 VARARG(keystate,bytes); /* state array for all the keys */
2499 /* Set the system foreground window */
2500 @REQ(set_foreground_window)
2501 user_handle_t handle; /* handle to the foreground window */
2503 user_handle_t previous; /* handle to the previous foreground window */
2504 int send_msg_old; /* whether we have to send a msg to the old window */
2505 int send_msg_new; /* whether we have to send a msg to the new window */
2508 /* Set the current thread focus window */
2509 @REQ(set_focus_window)
2510 user_handle_t handle; /* handle to the focus window */
2512 user_handle_t previous; /* handle to the previous focus window */
2515 /* Set the current thread active window */
2516 @REQ(set_active_window)
2517 user_handle_t handle; /* handle to the active window */
2519 user_handle_t previous; /* handle to the previous active window */
2522 /* Set the current thread capture window */
2523 @REQ(set_capture_window)
2524 user_handle_t handle; /* handle to the capture window */
2525 unsigned int flags; /* capture flags (see below) */
2527 user_handle_t previous; /* handle to the previous capture window */
2528 user_handle_t full_handle; /* full 32-bit handle of new capture window */
2530 #define CAPTURE_MENU 0x01 /* capture is for a menu */
2531 #define CAPTURE_MOVESIZE 0x02 /* capture is for moving/resizing */
2534 /* Set the current thread caret window */
2535 @REQ(set_caret_window)
2536 user_handle_t handle; /* handle to the caret window */
2537 int width; /* caret width */
2538 int height; /* caret height */
2540 user_handle_t previous; /* handle to the previous caret window */
2541 rectangle_t old_rect; /* previous caret rectangle */
2542 int old_hide; /* previous hide count */
2543 int old_state; /* previous caret state (1=on, 0=off) */
2547 /* Set the current thread caret information */
2548 @REQ(set_caret_info)
2549 unsigned int flags; /* caret flags (see below) */
2550 user_handle_t handle; /* handle to the caret window */
2551 int x; /* caret x position */
2552 int y; /* caret y position */
2553 int hide; /* increment for hide count (can be negative to show it) */
2554 int state; /* caret state (1=on, 0=off, -1=toggle current state) */
2556 user_handle_t full_handle; /* handle to the current caret window */
2557 rectangle_t old_rect; /* previous caret rectangle */
2558 int old_hide; /* previous hide count */
2559 int old_state; /* previous caret state (1=on, 0=off) */
2561 #define SET_CARET_POS 0x01 /* set the caret position from x,y */
2562 #define SET_CARET_HIDE 0x02 /* increment the caret hide count */
2563 #define SET_CARET_STATE 0x04 /* set the caret on/off state */
2566 /* Set a window hook */
2568 int id; /* id of the hook */
2569 process_id_t pid; /* id of process to set the hook into */
2570 thread_id_t tid; /* id of thread to set the hook into */
2574 void* proc; /* hook procedure */
2575 int unicode; /* is it a unicode hook? */
2576 VARARG(module,unicode_str); /* module name */
2578 user_handle_t handle; /* handle to the hook */
2579 unsigned int active_hooks; /* active hooks bitmap */
2583 /* Remove a window hook */
2585 user_handle_t handle; /* handle to the hook */
2586 int id; /* id of the hook if handle is 0 */
2587 void* proc; /* hook procedure if handle is 0 */
2589 unsigned int active_hooks; /* active hooks bitmap */
2593 /* Start calling a hook chain */
2594 @REQ(start_hook_chain)
2595 int id; /* id of the hook */
2596 int event; /* signalled event */
2597 user_handle_t window; /* handle to the event window */
2598 int object_id; /* object id for out of context winevent */
2599 int child_id; /* child id for out of context winevent */
2601 user_handle_t handle; /* handle to the next hook */
2602 process_id_t pid; /* process id for low-level keyboard/mouse hooks */
2603 thread_id_t tid; /* thread id for low-level keyboard/mouse hooks */
2604 void* proc; /* hook procedure */
2605 int unicode; /* is it a unicode hook? */
2606 unsigned int active_hooks; /* active hooks bitmap */
2607 VARARG(module,unicode_str); /* module name */
2611 /* Finished calling a hook chain */
2612 @REQ(finish_hook_chain)
2613 int id; /* id of the hook */
2617 /* Get the hook information */
2619 user_handle_t handle; /* handle to the current hook */
2620 int get_next; /* do we want info about current or next hook? */
2621 int event; /* signalled event */
2622 user_handle_t window; /* handle to the event window */
2623 int object_id; /* object id for out of context winevent */
2624 int child_id; /* child id for out of context winevent */
2626 user_handle_t handle; /* handle to the hook */
2627 int id; /* id of the hook */
2628 process_id_t pid; /* process id for low-level keyboard/mouse hooks */
2629 thread_id_t tid; /* thread id for low-level keyboard/mouse hooks */
2630 void* proc; /* hook procedure */
2631 int unicode; /* is it a unicode hook? */
2632 VARARG(module,unicode_str); /* module name */
2636 /* Create a window class */
2638 int local; /* is it a local class? */
2639 atom_t atom; /* class atom */
2640 unsigned int style; /* class style */
2641 void* instance; /* module instance */
2642 int extra; /* number of extra class bytes */
2643 int win_extra; /* number of window extra bytes */
2644 void* client_ptr; /* pointer to class in client address space */
2645 VARARG(name,unicode_str); /* class name */
2647 atom_t atom; /* resulting class atom */
2651 /* Destroy a window class */
2653 atom_t atom; /* class atom */
2654 void* instance; /* module instance */
2655 VARARG(name,unicode_str); /* class name */
2657 void* client_ptr; /* pointer to class in client address space */
2661 /* Set some information in a class */
2662 @REQ(set_class_info)
2663 user_handle_t window; /* handle to the window */
2664 unsigned int flags; /* flags for info to set (see below) */
2665 atom_t atom; /* class atom */
2666 unsigned int style; /* class style */
2667 int win_extra; /* number of window extra bytes */
2668 void* instance; /* module instance */
2669 int extra_offset; /* offset to set in extra bytes */
2670 data_size_t extra_size; /* size to set in extra bytes */
2671 lparam_t extra_value; /* value to set in extra bytes */
2673 atom_t old_atom; /* previous class atom */
2674 unsigned int old_style; /* previous class style */
2675 int old_extra; /* previous number of class extra bytes */
2676 int old_win_extra; /* previous number of window extra bytes */
2677 void* old_instance; /* previous module instance */
2678 lparam_t old_extra_value; /* old value in extra bytes */
2680 #define SET_CLASS_ATOM 0x0001
2681 #define SET_CLASS_STYLE 0x0002
2682 #define SET_CLASS_WINEXTRA 0x0004
2683 #define SET_CLASS_INSTANCE 0x0008
2684 #define SET_CLASS_EXTRA 0x0010
2687 /* Set/get clipboard information */
2688 @REQ(set_clipboard_info)
2689 unsigned int flags; /* flags for fields to set (see below) */
2690 user_handle_t clipboard; /* clipboard window */
2691 user_handle_t owner; /* clipboard owner */
2692 user_handle_t viewer; /* first clipboard viewer */
2693 unsigned int seqno; /* change sequence number */
2695 unsigned int flags; /* status flags (see below) */
2696 user_handle_t old_clipboard; /* old clipboard window */
2697 user_handle_t old_owner; /* old clipboard owner */
2698 user_handle_t old_viewer; /* old clipboard viewer */
2699 unsigned int seqno; /* current sequence number */
2702 #define SET_CB_OPEN 0x001
2703 #define SET_CB_OWNER 0x002
2704 #define SET_CB_VIEWER 0x004
2705 #define SET_CB_SEQNO 0x008
2706 #define SET_CB_RELOWNER 0x010
2707 #define SET_CB_CLOSE 0x020
2708 #define CB_OPEN 0x040
2709 #define CB_OWNER 0x080
2710 #define CB_PROCESS 0x100
2713 /* Open a security token */
2715 obj_handle_t handle; /* handle to the thread or process */
2716 unsigned int access; /* access rights to the new token */
2717 unsigned int attributes;/* object attributes */
2718 unsigned int flags; /* flags (see below) */
2720 obj_handle_t token; /* handle to the token */
2722 #define OPEN_TOKEN_THREAD 1
2723 #define OPEN_TOKEN_AS_SELF 2
2726 /* Set/get the global windows */
2727 @REQ(set_global_windows)
2728 unsigned int flags; /* flags for fields to set (see below) */
2729 user_handle_t shell_window; /* handle to the new shell window */
2730 user_handle_t shell_listview; /* handle to the new shell listview window */
2731 user_handle_t progman_window; /* handle to the new program manager window */
2732 user_handle_t taskman_window; /* handle to the new task manager window */
2734 user_handle_t old_shell_window; /* handle to the shell window */
2735 user_handle_t old_shell_listview; /* handle to the shell listview window */
2736 user_handle_t old_progman_window; /* handle to the new program manager window */
2737 user_handle_t old_taskman_window; /* handle to the new task manager window */
2739 #define SET_GLOBAL_SHELL_WINDOWS 0x01 /* set both main shell and listview windows */
2740 #define SET_GLOBAL_PROGMAN_WINDOW 0x02
2741 #define SET_GLOBAL_TASKMAN_WINDOW 0x04
2743 /* Adjust the privileges held by a token */
2744 @REQ(adjust_token_privileges)
2745 obj_handle_t handle; /* handle to the token */
2746 int disable_all; /* disable all privileges? */
2747 int get_modified_state; /* get modified privileges? */
2748 VARARG(privileges,LUID_AND_ATTRIBUTES); /* privileges to enable/disable/remove */
2750 unsigned int len; /* total length in bytes required to store token privileges */
2751 VARARG(privileges,LUID_AND_ATTRIBUTES); /* modified privileges */
2754 /* Retrieves the set of privileges held by or available to a token */
2755 @REQ(get_token_privileges)
2756 obj_handle_t handle; /* handle to the token */
2758 unsigned int len; /* total length in bytes required to store token privileges */
2759 VARARG(privileges,LUID_AND_ATTRIBUTES); /* privileges held by or available to a token */
2762 /* Check the token has the required privileges */
2763 @REQ(check_token_privileges)
2764 obj_handle_t handle; /* handle to the token */
2765 int all_required; /* are all the privileges required for the check to succeed? */
2766 VARARG(privileges,LUID_AND_ATTRIBUTES); /* privileges to check */
2768 int has_privileges; /* does the token have the required privileges? */
2769 VARARG(privileges,LUID_AND_ATTRIBUTES); /* privileges held by or available to a token */
2772 @REQ(duplicate_token)
2773 obj_handle_t handle; /* handle to the token to duplicate */
2774 unsigned int access; /* access rights to the new token */
2775 unsigned int attributes; /* object attributes */
2776 int primary; /* is the new token to be a primary one? */
2777 int impersonation_level; /* impersonation level of the new token */
2779 obj_handle_t new_handle; /* duplicated handle */
2783 obj_handle_t handle; /* handle to the token */
2784 unsigned int desired_access; /* desired access to the object */
2785 unsigned int mapping_read; /* mapping from generic read to specific rights */
2786 unsigned int mapping_write; /* mapping from generic write to specific rights */
2787 unsigned int mapping_execute; /* mapping from generic execute to specific rights */
2788 unsigned int mapping_all; /* mapping from generic all to specific rights */
2789 VARARG(sd,security_descriptor); /* security descriptor to check */
2791 unsigned int access_granted; /* access rights actually granted */
2792 unsigned int access_status; /* was access granted? */
2793 unsigned int privileges_len; /* length needed to store privileges */
2794 VARARG(privileges,LUID_AND_ATTRIBUTES); /* privileges used during access check */
2797 @REQ(get_token_user)
2798 obj_handle_t handle; /* handle to the token */
2800 data_size_t user_len; /* length needed to store user */
2801 VARARG(user,SID); /* sid of the user the token represents */
2804 @REQ(get_token_groups)
2805 obj_handle_t handle; /* handle to the token */
2807 data_size_t user_len; /* length needed to store user */
2808 VARARG(user,token_groups); /* groups the token's user belongs to
*/
2811 @
REQ(set_security_object
)
2812 obj_handle_t handle
; /* handle to the object
*/
2813 unsigned int security_info
; /* which parts of security descriptor to set
*/
2814 VARARG(sd
,security_descriptor
); /* security descriptor to set
*/
2817 @
REQ(get_security_object
)
2818 obj_handle_t handle
; /* handle to the object
*/
2819 unsigned int security_info
; /* which parts of security descriptor to get
*/
2821 unsigned int sd_len
; /* buffer size needed for sd
*/
2822 VARARG(sd
,security_descriptor
); /* retrieved security descriptor
*/
2825 /* Create a mailslot
*/
2826 @
REQ(create_mailslot
)
2827 unsigned int access
; /* wanted access rights
*/
2828 unsigned int attributes
; /* object attributes
*/
2829 obj_handle_t rootdir
; /* root directory
*/
2830 unsigned int max_msgsize
;
2831 timeout_t read_timeout
;
2832 VARARG(name
,unicode_str
); /* mailslot name
*/
2834 obj_handle_t handle
; /* handle to the mailslot
*/
2838 /* Set mailslot information
*/
2839 @
REQ(set_mailslot_info
)
2840 obj_handle_t handle
; /* handle to the mailslot
*/
2842 timeout_t read_timeout
;
2844 unsigned int max_msgsize
;
2845 timeout_t read_timeout
;
2847 #define MAILSLOT_SET_READ_TIMEOUT
1
2850 /* Create a directory object
*/
2851 @
REQ(create_directory
)
2852 unsigned int access
; /* access flags
*/
2853 unsigned int attributes
; /* object attributes
*/
2854 obj_handle_t rootdir
; /* root directory
*/
2855 VARARG(directory_name
,unicode_str
); /* Directory name
*/
2857 obj_handle_t handle
; /* handle to the directory
*/
2861 /* Open a directory object
*/
2862 @
REQ(open_directory
)
2863 unsigned int access
; /* access flags
*/
2864 unsigned int attributes
; /* object attributes
*/
2865 obj_handle_t rootdir
; /* root directory
*/
2866 VARARG(directory_name
,unicode_str
); /* Directory name
*/
2868 obj_handle_t handle
; /* handle to the directory
*/
2872 /* Get a directory entry by index
*/
2873 @
REQ(get_directory_entry
)
2874 obj_handle_t handle
; /* handle to the directory
*/
2875 unsigned int index
; /* entry index
*/
2877 data_size_t name_len
; /* length of the entry name in bytes
*/
2878 VARARG(name
,unicode_str
,name_len
); /* entry name
*/
2879 VARARG(type
,unicode_str
); /* entry type
*/
2883 /* Create a symbolic link object
*/
2884 @
REQ(create_symlink
)
2885 unsigned int access
; /* access flags
*/
2886 unsigned int attributes
; /* object attributes
*/
2887 obj_handle_t rootdir
; /* root directory
*/
2888 data_size_t name_len
; /* length of the symlink name in bytes
*/
2889 VARARG(name
,unicode_str
,name_len
); /* symlink name
*/
2890 VARARG(target_name
,unicode_str
); /* target name
*/
2892 obj_handle_t handle
; /* handle to the symlink
*/
2896 /* Open a symbolic link object
*/
2898 unsigned int access
; /* access flags
*/
2899 unsigned int attributes
; /* object attributes
*/
2900 obj_handle_t rootdir
; /* root directory
*/
2901 VARARG(name
,unicode_str
); /* symlink name
*/
2903 obj_handle_t handle
; /* handle to the symlink
*/
2907 /* Query a symbolic link object
*/
2909 obj_handle_t handle
; /* handle to the symlink
*/
2911 VARARG(target_name
,unicode_str
); /* target name
*/
2915 /* Query basic object information
*/
2916 @
REQ(get_object_info
)
2917 obj_handle_t handle
; /* handle to the object
*/
2919 unsigned int access
; /* granted access mask
*/
2920 unsigned int ref_count
; /* object ref count
*/
2924 /* Unlink a named object
*/
2926 obj_handle_t handle
; /* handle to the object
*/
2930 /* Query the impersonation level of an impersonation token
*/
2931 @
REQ(get_token_impersonation_level
)
2932 obj_handle_t handle
; /* handle to the object
*/
2934 int impersonation_level
; /* impersonation level of the impersonation token
*/
2937 /* Allocate a locally
-unique identifier
*/
2938 @
REQ(allocate_locally_unique_id
)
2944 /* Create a device manager
*/
2945 @
REQ(create_device_manager
)
2946 unsigned int access
; /* wanted access rights
*/
2947 unsigned int attributes
; /* object attributes
*/
2949 obj_handle_t handle
; /* handle to the device
*/
2953 /* Create a device
*/
2955 unsigned int access
; /* wanted access rights
*/
2956 unsigned int attributes
; /* object attributes
*/
2957 obj_handle_t rootdir
; /* root directory
*/
2958 obj_handle_t manager
; /* device manager
*/
2959 void
* user_ptr
; /* opaque ptr for use by client
*/
2960 VARARG(name
,unicode_str
); /* object name
*/
2962 obj_handle_t handle
; /* handle to the device
*/
2966 /* Delete a device
*/
2968 obj_handle_t handle
; /* handle to the device
*/
2972 /* Retrieve the next pending device ioctl request
*/
2973 @
REQ(get_next_device_request
)
2974 obj_handle_t manager
; /* handle to the device manager
*/
2975 obj_handle_t prev
; /* handle to the previous ioctl
*/
2976 unsigned int status
; /* status of the previous ioctl
*/
2977 VARARG(prev_data
,bytes
); /* output data of the previous ioctl
*/
2979 obj_handle_t next
; /* handle to the next ioctl
*/
2980 ioctl_code_t code
; /* ioctl code
*/
2981 void
* user_ptr
; /* opaque ptr for the device
*/
2982 data_size_t in_size
; /* total needed input size
*/
2983 data_size_t out_size
; /* needed output size
*/
2984 VARARG(next_data
,bytes
); /* input data of the next ioctl
*/
2988 /* Make the current process a system process
*/
2989 @
REQ(make_process_system
)
2991 obj_handle_t event
; /* event signaled when all user processes have exited
*/
2995 /* Get detailed fixed
-size information about a token
*/
2996 @
REQ(get_token_statistics
)
2997 obj_handle_t handle
; /* handle to the object
*/
2999 luid_t token_id
; /* locally
-unique identifier of the token
*/
3000 luid_t modified_id
; /* locally
-unique identifier of the modified version of the token
*/
3001 int primary
; /* is the token primary or impersonation?
*/
3002 int impersonation_level
; /* level of impersonation
*/
3003 int group_count
; /* the number of groups the token is a member of
*/
3004 int privilege_count
; /* the number of privileges the token has
*/
3008 /* Create I
/O completion port
*/
3009 @
REQ(create_completion
)
3010 unsigned int access
; /* desired access to a port
*/
3011 unsigned int attributes
; /* object attributes
*/
3012 unsigned int concurrent
; /* max number of concurrent active threads
*/
3013 obj_handle_t rootdir
; /* root directory
*/
3014 VARARG(filename
,string
); /* port name
*/
3016 obj_handle_t handle
; /* port handle
*/
3020 /* Open I
/O completion port
*/
3021 @
REQ(open_completion
)
3022 unsigned int access
; /* desired access to a port
*/
3023 unsigned int attributes
; /* object attributes
*/
3024 obj_handle_t rootdir
; /* root directory
*/
3025 VARARG(filename
,string
); /* port name
*/
3027 obj_handle_t handle
; /* port handle
*/
3031 /* add completion to completion port
*/
3032 @
REQ(add_completion
)
3033 obj_handle_t handle
; /* port handle
*/
3034 unsigned long ckey
; /* completion key
*/
3035 unsigned long cvalue
; /* completion value
*/
3036 unsigned long information
; /* IO_STATUS_BLOCK Information
*/
3037 unsigned int status
; /* completion result
*/
3041 /* get completion from completion port queue
*/
3042 @
REQ(remove_completion
)
3043 obj_handle_t handle
; /* port handle
*/
3045 unsigned long ckey
; /* completion key
*/
3046 unsigned long cvalue
; /* completion value
*/
3047 unsigned long information
; /* IO_STATUS_BLOCK Information
*/
3048 unsigned int status
; /* completion result
*/
3052 /* get completion queue depth
*/
3053 @
REQ(query_completion
)
3054 obj_handle_t handle
; /* port handle
*/
3056 unsigned int depth
; /* completion queue depth
*/
3060 /* associate object with completion port
*/
3061 @
REQ(set_completion_info
)
3062 obj_handle_t handle
; /* object handle
*/
3063 obj_handle_t chandle
; /* port handle
*/
3064 unsigned long ckey
; /* completion key
*/
3068 /* check for associated completion and push msg
*/
3069 @
REQ(add_fd_completion
)
3070 obj_handle_t handle
; /* async
' object */
3071 unsigned long cvalue; /* completion value */
3072 unsigned int status; /* completion status */
3073 unsigned long information; /* IO_STATUS_BLOCK Information */
3077 /* Retrieve layered info for a window */
3078 @REQ(get_window_layered_info)
3079 user_handle_t handle; /* handle to the window */
3081 unsigned int color_key; /* color key */
3082 unsigned int alpha; /* alpha (0..255) */
3083 unsigned int flags; /* LWA_* flags */
3087 /* Set layered info for a window */
3088 @REQ(set_window_layered_info)
3089 user_handle_t handle; /* handle to the window */
3090 unsigned int color_key; /* color key */
3091 unsigned int alpha; /* alpha (0..255) */
3092 unsigned int flags; /* LWA_* flags */