2 rdesktop: A Remote Desktop Protocol client.
4 Copyright (C) Matthew Chapman 1999-2005
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
28 typedef unsigned char uint8
;
29 typedef signed char sint8
;
30 typedef unsigned short uint16
;
31 typedef signed short sint16
;
32 typedef unsigned int uint32
;
33 typedef signed int sint32
;
35 typedef void *RD_HBITMAP
;
36 typedef void *RD_HGLYPH
;
37 typedef void *RD_HCOLOURMAP
;
38 typedef void *RD_HCURSOR
;
40 typedef struct _RD_POINT
46 typedef struct _COLOURENTRY
55 typedef struct _COLOURMAP
63 typedef struct _BOUNDS
92 typedef struct _FONTGLYPH
103 typedef struct _DATABLOB
111 typedef struct _key_translation
113 /* For normal scancode translations */
116 /* For sequences. If keysym is nonzero, the fields above are not used. */
117 uint32 seq_keysym
; /* Really KeySym */
118 struct _key_translation
*next
;
122 typedef struct _VCHANNEL
128 void (*process
) (STREAM
);
133 typedef uint8 HASH_KEY
[8];
135 /* Header for an entry in the persistent bitmap cache file */
136 typedef struct _PSTCACHE_CELLHEADER
145 #define MAX_CBSIZE 256
152 uint32 nSamplesPerSec
;
153 uint32 nAvgBytesPerSec
;
155 uint16 wBitsPerSample
;
157 uint8 cb
[MAX_CBSIZE
];
160 typedef struct _RDPCOMP
163 uint8 hist
[RDP_MPPC_DICT_SIZE
];
169 typedef uint32 RD_NTSTATUS
;
170 typedef uint32 RD_NTHANDLE
;
172 typedef struct _DEVICE_FNS
174 RD_NTSTATUS(*create
) (uint32 device
, uint32 desired_access
, uint32 share_mode
,
175 uint32 create_disposition
, uint32 flags_and_attributes
, char *filename
,
176 RD_NTHANDLE
* handle
);
177 RD_NTSTATUS(*close
) (RD_NTHANDLE handle
);
178 RD_NTSTATUS(*read
) (RD_NTHANDLE handle
, uint8
* data
, uint32 length
, uint32 offset
,
180 RD_NTSTATUS(*write
) (RD_NTHANDLE handle
, uint8
* data
, uint32 length
, uint32 offset
,
182 RD_NTSTATUS(*device_control
) (RD_NTHANDLE handle
, uint32 request
, STREAM in
, STREAM out
);
187 typedef struct rdpdr_device_info
197 typedef struct rdpdr_serial_device_info
201 uint32 control
, xonoff
, onlimit
, offlimit
;
206 read_interval_timeout
,
207 read_total_timeout_multiplier
,
208 read_total_timeout_constant
,
209 write_total_timeout_multiplier
, write_total_timeout_constant
, posix_wait_mask
;
210 uint8 stop_bits
, parity
, word_length
;
212 struct termios
*ptermios
, *pold_termios
;
213 int event_txempty
, event_cts
, event_dsr
, event_rlsd
, event_pending
;
217 typedef struct rdpdr_parallel_device_info
219 char *driver
, *printer
;
220 uint32 queue_in_size
,
223 read_interval_timeout
,
224 read_total_timeout_multiplier
,
225 read_total_timeout_constant
,
226 write_total_timeout_multiplier
,
227 write_total_timeout_constant
, posix_wait_mask
, bloblen
;
232 typedef struct rdpdr_printer_info
235 char *driver
, *printer
;
238 BOOL default_printer
;
242 typedef struct notify_data
247 unsigned int num_entries
;
256 typedef struct fileinfo
258 uint32 device_id
, flags_and_attributes
, accessmask
;
261 struct dirent
*pdirent
;
262 char pattern
[PATH_MAX
];
263 BOOL delete_on_close
;
270 typedef BOOL(*str_handle_lines_t
) (const char *line
, void *data
);