771
|
1 /* Automatically-generated Unicode-encapsulation file,
|
|
2 using the command
|
|
3
|
|
4 ../lib-src/make-mswin-unicode.pl --c-output intl-auto-encap-win32.c --h-output intl-auto-encap-win32.h intl-encap-win32.c
|
|
5
|
|
6 Do not edit. See `make-mswin-unicode.pl'.
|
|
7 */
|
|
8
|
|
9 #include <config.h>
|
|
10 #include "lisp.h"
|
|
11
|
|
12 #include "syswindows.h"
|
|
13
|
|
14
|
|
15 /*----------------------------------------------------------------------*/
|
798
|
16 /* Processing file WINNLS.H */
|
|
17 /*----------------------------------------------------------------------*/
|
|
18
|
|
19 /* Error if GetCPInfoEx used: not used, not examined yet */
|
|
20
|
|
21 /* Error if CompareString used: not used, not examined yet */
|
|
22
|
|
23 /* Error if LCMapString used: not used, not examined yet */
|
|
24
|
|
25 int
|
|
26 qxeGetLocaleInfo (LCID Locale, LCTYPE LCType, Extbyte * lpLCData, int cchData)
|
|
27 {
|
|
28 if (XEUNICODE_P)
|
|
29 return GetLocaleInfoW (Locale, LCType, (LPWSTR) lpLCData, cchData);
|
|
30 else
|
|
31 return GetLocaleInfoA (Locale, LCType, (LPSTR) lpLCData, cchData);
|
|
32 }
|
|
33
|
|
34 BOOL
|
|
35 qxeSetLocaleInfo (LCID Locale, LCTYPE LCType, const Extbyte * lpLCData)
|
|
36 {
|
|
37 if (XEUNICODE_P)
|
|
38 return SetLocaleInfoW (Locale, LCType, (LPCWSTR) lpLCData);
|
|
39 else
|
|
40 return SetLocaleInfoA (Locale, LCType, (LPCSTR) lpLCData);
|
|
41 }
|
|
42
|
|
43 /* Error if GetTimeFormat used: not used, not examined yet */
|
|
44
|
|
45 /* Error if GetDateFormat used: not used, not examined yet */
|
|
46
|
|
47 /* Error if GetNumberFormat used: not used, not examined yet */
|
|
48
|
|
49 /* Error if GetCurrencyFormat used: not used, not examined yet */
|
|
50
|
|
51 /* Error if EnumCalendarInfo used: not used, not examined yet */
|
|
52
|
|
53 /* Error if EnumCalendarInfoEx used: not used, not examined yet */
|
|
54
|
|
55 /* Error if EnumTimeFormats used: not used, not examined yet */
|
|
56
|
|
57 /* Error if EnumDateFormats used: not used, not examined yet */
|
|
58
|
|
59 /* Error if EnumDateFormatsEx used: not used, not examined yet */
|
|
60
|
|
61 /* Error if GetStringTypeEx used: not used, not examined yet */
|
|
62
|
|
63 /* Error if FoldString used: not used, not examined yet */
|
|
64
|
|
65 /* Error if EnumSystemLocales used: not used, not examined yet */
|
|
66
|
|
67 /* Error if EnumSystemCodePages used: not used, not examined yet */
|
|
68
|
|
69
|
|
70 /*----------------------------------------------------------------------*/
|
771
|
71 /* Processing file WINSPOOL.H */
|
|
72 /*----------------------------------------------------------------------*/
|
|
73
|
|
74 #if defined (HAVE_MS_WINDOWS)
|
|
75
|
|
76 /* NOTE: #### problems with DEVMODE pointer in PRINTER_INFO_2 */
|
|
77 BOOL
|
|
78 qxeEnumPrinters (DWORD Flags, Extbyte * Name, DWORD Level, LPBYTE pPrinterEnum, DWORD cbBuf, LPDWORD pcbNeeded, LPDWORD pcReturned)
|
|
79 {
|
|
80 if (XEUNICODE_P)
|
|
81 return EnumPrintersW (Flags, (LPWSTR) Name, Level, pPrinterEnum, cbBuf, pcbNeeded, pcReturned);
|
|
82 else
|
|
83 return EnumPrintersA (Flags, (LPSTR) Name, Level, pPrinterEnum, cbBuf, pcbNeeded, pcReturned);
|
|
84 }
|
|
85
|
|
86 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
87
|
|
88 #if defined (HAVE_MS_WINDOWS)
|
|
89
|
|
90 /* Skipping OpenPrinter because split-sized DEVMODE pointer in split PRINTER_DEFAULTS */
|
|
91
|
|
92 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
93
|
|
94 #if defined (HAVE_MS_WINDOWS)
|
|
95
|
|
96 /* Error if ResetPrinter used: split-sized DEVMODE pointer in split PRINTER_DEFAULTS */
|
|
97
|
|
98 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
99
|
|
100 #if defined (HAVE_MS_WINDOWS)
|
|
101
|
|
102 /* Error if SetJob used: split-sized DEVMODE pointer in split JOB_INFO_2 */
|
|
103
|
|
104 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
105
|
|
106 #if defined (HAVE_MS_WINDOWS)
|
|
107
|
|
108 /* Error if GetJob used: split-sized DEVMODE pointer in split JOB_INFO_2 */
|
|
109
|
|
110 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
111
|
|
112 #if defined (HAVE_MS_WINDOWS)
|
|
113
|
|
114 /* Error if EnumJobs used: split-sized DEVMODE pointer in split JOB_INFO_2 */
|
|
115
|
|
116 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
117
|
|
118 #if defined (HAVE_MS_WINDOWS)
|
|
119
|
|
120 /* Error if AddPrinter used: split-sized DEVMODE pointer in split PRINTER_INFO_2 */
|
|
121
|
|
122 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
123
|
|
124 #if defined (HAVE_MS_WINDOWS)
|
|
125
|
|
126 /* Error if SetPrinter used: split-sized DEVMODE pointer in split PRINTER_INFO_2 */
|
|
127
|
|
128 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
129
|
|
130 #if defined (HAVE_MS_WINDOWS)
|
|
131
|
|
132 /* Error if GetPrinter used: split-sized DEVMODE pointer in split PRINTER_INFO_2 */
|
|
133
|
|
134 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
135
|
|
136 #if defined (HAVE_MS_WINDOWS)
|
|
137
|
|
138 /* Error if AddPrinterDriver used: not used, complicated interface with split structures */
|
|
139
|
|
140 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
141
|
|
142 #if defined (HAVE_MS_WINDOWS)
|
|
143
|
|
144 /* Error if AddPrinterDriverEx used: not used, complicated interface with split structures */
|
|
145
|
|
146 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
147
|
|
148 #if defined (HAVE_MS_WINDOWS)
|
|
149
|
|
150 /* Error if EnumPrinterDrivers used: not used, complicated interface with split structures */
|
|
151
|
|
152 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
153
|
|
154 #if defined (HAVE_MS_WINDOWS)
|
|
155
|
|
156 /* Error if GetPrinterDriver used: not used, complicated interface with split structures */
|
|
157
|
|
158 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
159
|
|
160 #if defined (HAVE_MS_WINDOWS)
|
|
161
|
|
162 /* Error if GetPrinterDriverDirectory used: not used, complicated interface with split structures */
|
|
163
|
|
164 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
165
|
|
166 #if defined (HAVE_MS_WINDOWS)
|
|
167
|
|
168 /* Error if DeletePrinterDriver used: not used, complicated interface with split structures */
|
|
169
|
|
170 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
171
|
|
172 #if defined (HAVE_MS_WINDOWS)
|
|
173
|
|
174 /* Error if DeletePrinterDriverEx used: not used, complicated interface with split structures */
|
|
175
|
|
176 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
177
|
|
178 #if defined (HAVE_MS_WINDOWS)
|
|
179
|
|
180 /* Error if AddPerMachineConnection used: not used, complicated interface with split structures */
|
|
181
|
|
182 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
183
|
|
184 #if defined (HAVE_MS_WINDOWS)
|
|
185
|
|
186 /* Error if DeletePerMachineConnection used: not used, complicated interface with split structures */
|
|
187
|
|
188 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
189
|
|
190 #if defined (HAVE_MS_WINDOWS)
|
|
191
|
|
192 /* Error if EnumPerMachineConnections used: not used, complicated interface with split structures */
|
|
193
|
|
194 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
195
|
|
196 #if defined (HAVE_MS_WINDOWS)
|
|
197
|
|
198 /* Error if AddPrintProcessor used: not used, complicated interface with split structures */
|
|
199
|
|
200 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
201
|
|
202 #if defined (HAVE_MS_WINDOWS)
|
|
203
|
|
204 /* Error if EnumPrintProcessors used: not used, complicated interface with split structures */
|
|
205
|
|
206 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
207
|
|
208 #if defined (HAVE_MS_WINDOWS)
|
|
209
|
|
210 /* Error if GetPrintProcessorDirectory used: not used, complicated interface with split structures */
|
|
211
|
|
212 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
213
|
|
214 #if defined (HAVE_MS_WINDOWS)
|
|
215
|
|
216 /* Error if EnumPrintProcessorDatatypes used: not used, complicated interface with split structures */
|
|
217
|
|
218 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
219
|
|
220 #if defined (HAVE_MS_WINDOWS)
|
|
221
|
|
222 /* Error if DeletePrintProcessor used: not used, complicated interface with split structures */
|
|
223
|
|
224 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
225
|
|
226 #if defined (HAVE_MS_WINDOWS)
|
|
227
|
|
228 /* Error if StartDocPrinter used: not used, complicated interface with split structures */
|
|
229
|
|
230 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
231
|
|
232 #if defined (HAVE_MS_WINDOWS)
|
|
233
|
|
234 /* Error if AddJob used: not used, complicated interface with split structures */
|
|
235
|
|
236 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
237
|
|
238 #if defined (HAVE_MS_WINDOWS)
|
|
239
|
|
240 /* Skipping DocumentProperties because split-sized DEVMODE, error in Cygwin prototype */
|
|
241
|
|
242 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
243
|
|
244 #if defined (HAVE_MS_WINDOWS)
|
|
245
|
|
246 /* Error if AdvancedDocumentProperties used: not used, complicated interface with split structures */
|
|
247
|
|
248 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
249
|
|
250 #if defined (HAVE_MS_WINDOWS)
|
|
251
|
|
252 /* Error if GetPrinterData used: not used, complicated interface with split structures */
|
|
253
|
|
254 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
255
|
|
256 #if defined (HAVE_MS_WINDOWS)
|
|
257
|
|
258 /* Error if GetPrinterDataEx used: not used, complicated interface with split structures */
|
|
259
|
|
260 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
261
|
|
262 #if defined (HAVE_MS_WINDOWS)
|
|
263
|
|
264 /* Error if EnumPrinterData used: not used, complicated interface with split structures */
|
|
265
|
|
266 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
267
|
|
268 #if defined (HAVE_MS_WINDOWS)
|
|
269
|
|
270 /* Error if EnumPrinterDataEx used: not used, complicated interface with split structures */
|
|
271
|
|
272 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
273
|
|
274 #if defined (HAVE_MS_WINDOWS)
|
|
275
|
|
276 /* Error if EnumPrinterKey used: not used, complicated interface with split structures */
|
|
277
|
|
278 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
279
|
|
280 #if defined (HAVE_MS_WINDOWS)
|
|
281
|
|
282 /* Error if SetPrinterData used: not used, complicated interface with split structures */
|
|
283
|
|
284 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
285
|
|
286 #if defined (HAVE_MS_WINDOWS)
|
|
287
|
|
288 /* Error if SetPrinterDataEx used: not used, complicated interface with split structures */
|
|
289
|
|
290 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
291
|
|
292 #if defined (HAVE_MS_WINDOWS)
|
|
293
|
|
294 /* Error if DeletePrinterData used: not used, complicated interface with split structures */
|
|
295
|
|
296 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
297
|
|
298 #if defined (HAVE_MS_WINDOWS)
|
|
299
|
|
300 /* Error if DeletePrinterDataEx used: not used, complicated interface with split structures */
|
|
301
|
|
302 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
303
|
|
304 #if defined (HAVE_MS_WINDOWS)
|
|
305
|
|
306 /* Error if DeletePrinterKey used: not used, complicated interface with split structures */
|
|
307
|
|
308 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
309
|
|
310 #if defined (HAVE_MS_WINDOWS)
|
|
311
|
|
312 /* Error if PrinterMessageBox used: not used, complicated interface with split structures */
|
|
313
|
|
314 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
315
|
|
316 #if defined (HAVE_MS_WINDOWS)
|
|
317
|
|
318 /* Error if AddForm used: not used, complicated interface with split structures */
|
|
319
|
|
320 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
321
|
|
322 #if defined (HAVE_MS_WINDOWS)
|
|
323
|
|
324 /* Error if DeleteForm used: not used, complicated interface with split structures */
|
|
325
|
|
326 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
327
|
|
328 #if defined (HAVE_MS_WINDOWS)
|
|
329
|
|
330 /* Error if GetForm used: not used, complicated interface with split structures */
|
|
331
|
|
332 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
333
|
|
334 #if defined (HAVE_MS_WINDOWS)
|
|
335
|
|
336 /* Error if SetForm used: not used, complicated interface with split structures */
|
|
337
|
|
338 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
339
|
|
340 #if defined (HAVE_MS_WINDOWS)
|
|
341
|
|
342 /* Error if EnumForms used: not used, complicated interface with split structures */
|
|
343
|
|
344 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
345
|
|
346 #if defined (HAVE_MS_WINDOWS)
|
|
347
|
|
348 /* Error if EnumMonitors used: not used, complicated interface with split structures */
|
|
349
|
|
350 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
351
|
|
352 #if defined (HAVE_MS_WINDOWS)
|
|
353
|
|
354 /* Error if AddMonitor used: not used, complicated interface with split structures */
|
|
355
|
|
356 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
357
|
|
358 #if defined (HAVE_MS_WINDOWS)
|
|
359
|
|
360 /* Error if DeleteMonitor used: not used, complicated interface with split structures */
|
|
361
|
|
362 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
363
|
|
364 #if defined (HAVE_MS_WINDOWS)
|
|
365
|
|
366 /* Error if EnumPorts used: not used, complicated interface with split structures */
|
|
367
|
|
368 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
369
|
|
370 #if defined (HAVE_MS_WINDOWS)
|
|
371
|
|
372 /* Error if AddPort used: not used, complicated interface with split structures */
|
|
373
|
|
374 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
375
|
|
376 #if defined (HAVE_MS_WINDOWS)
|
|
377
|
|
378 /* Error if ConfigurePort used: not used, complicated interface with split structures */
|
|
379
|
|
380 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
381
|
|
382 #if defined (HAVE_MS_WINDOWS)
|
|
383
|
|
384 /* Error if DeletePort used: not used, complicated interface with split structures */
|
|
385
|
|
386 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
387
|
|
388 #if defined (HAVE_MS_WINDOWS)
|
|
389
|
|
390 /* Error if XcvData used: not used, complicated interface with split structures */
|
|
391
|
|
392 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
393
|
|
394 #if defined (HAVE_MS_WINDOWS)
|
|
395
|
|
396 /* Error if SetPort used: not used, complicated interface with split structures */
|
|
397
|
|
398 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
399
|
|
400 #if defined (HAVE_MS_WINDOWS)
|
|
401
|
|
402 /* Error if AddPrinterConnection used: not used, complicated interface with split structures */
|
|
403
|
|
404 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
405
|
|
406 #if defined (HAVE_MS_WINDOWS)
|
|
407
|
|
408 /* Error if DeletePrinterConnection used: not used, complicated interface with split structures */
|
|
409
|
|
410 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
411
|
|
412 #if defined (HAVE_MS_WINDOWS)
|
|
413
|
|
414 /* Error if AddPrintProvidor used: not used, complicated interface with split structures */
|
|
415
|
|
416 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
417
|
|
418 #if defined (HAVE_MS_WINDOWS)
|
|
419
|
|
420 /* Error if DeletePrintProvidor used: not used, complicated interface with split structures */
|
|
421
|
|
422 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
423
|
|
424 #if defined (HAVE_MS_WINDOWS)
|
|
425
|
|
426 /* Error if SetPrinterHTMLView used: not used, complicated interface with split structures */
|
|
427
|
|
428 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
429
|
|
430 #if defined (HAVE_MS_WINDOWS)
|
|
431
|
|
432 /* Error if GetPrinterHTMLView used: not used, complicated interface with split structures */
|
|
433
|
|
434 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
435
|
|
436
|
|
437 /*----------------------------------------------------------------------*/
|
|
438 /* Processing file WINNETWK.H */
|
|
439 /*----------------------------------------------------------------------*/
|
|
440
|
|
441 #if defined (HAVE_MS_WINDOWS)
|
|
442
|
|
443 DWORD
|
|
444 qxeWNetAddConnection (const Extbyte * lpRemoteName, const Extbyte * lpPassword, const Extbyte * lpLocalName)
|
|
445 {
|
|
446 if (XEUNICODE_P)
|
|
447 return WNetAddConnectionW ((LPCWSTR) lpRemoteName, (LPCWSTR) lpPassword, (LPCWSTR) lpLocalName);
|
|
448 else
|
|
449 return WNetAddConnectionA ((LPCSTR) lpRemoteName, (LPCSTR) lpPassword, (LPCSTR) lpLocalName);
|
|
450 }
|
|
451
|
|
452 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
453
|
|
454 #if defined (HAVE_MS_WINDOWS)
|
|
455
|
|
456 DWORD
|
|
457 qxeWNetAddConnection2 (LPNETRESOURCEW lpNetResource, const Extbyte * lpPassword, const Extbyte * lpUserName, DWORD dwFlags)
|
|
458 {
|
|
459 if (XEUNICODE_P)
|
|
460 return WNetAddConnection2W (lpNetResource, (LPCWSTR) lpPassword, (LPCWSTR) lpUserName, dwFlags);
|
|
461 else
|
|
462 return WNetAddConnection2A ((LPNETRESOURCEA) lpNetResource, (LPCSTR) lpPassword, (LPCSTR) lpUserName, dwFlags);
|
|
463 }
|
|
464
|
|
465 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
466
|
|
467 #if defined (HAVE_MS_WINDOWS)
|
|
468
|
|
469 DWORD
|
|
470 qxeWNetAddConnection3 (HWND hwndOwner, LPNETRESOURCEW lpNetResource, const Extbyte * lpPassword, const Extbyte * lpUserName, DWORD dwFlags)
|
|
471 {
|
|
472 if (XEUNICODE_P)
|
|
473 return WNetAddConnection3W (hwndOwner, lpNetResource, (LPCWSTR) lpPassword, (LPCWSTR) lpUserName, dwFlags);
|
|
474 else
|
|
475 return WNetAddConnection3A (hwndOwner, (LPNETRESOURCEA) lpNetResource, (LPCSTR) lpPassword, (LPCSTR) lpUserName, dwFlags);
|
|
476 }
|
|
477
|
|
478 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
479
|
|
480 #if defined (HAVE_MS_WINDOWS)
|
|
481
|
|
482 DWORD
|
|
483 qxeWNetCancelConnection (const Extbyte * lpName, BOOL fForce)
|
|
484 {
|
|
485 if (XEUNICODE_P)
|
|
486 return WNetCancelConnectionW ((LPCWSTR) lpName, fForce);
|
|
487 else
|
|
488 return WNetCancelConnectionA ((LPCSTR) lpName, fForce);
|
|
489 }
|
|
490
|
|
491 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
492
|
|
493 #if defined (HAVE_MS_WINDOWS)
|
|
494
|
|
495 DWORD
|
|
496 qxeWNetCancelConnection2 (const Extbyte * lpName, DWORD dwFlags, BOOL fForce)
|
|
497 {
|
|
498 if (XEUNICODE_P)
|
|
499 return WNetCancelConnection2W ((LPCWSTR) lpName, dwFlags, fForce);
|
|
500 else
|
|
501 return WNetCancelConnection2A ((LPCSTR) lpName, dwFlags, fForce);
|
|
502 }
|
|
503
|
|
504 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
505
|
|
506 #if defined (HAVE_MS_WINDOWS)
|
|
507
|
|
508 DWORD
|
|
509 qxeWNetGetConnection (const Extbyte * lpLocalName, Extbyte * lpRemoteName, LPDWORD lpnLength)
|
|
510 {
|
|
511 if (XEUNICODE_P)
|
|
512 return WNetGetConnectionW ((LPCWSTR) lpLocalName, (LPWSTR) lpRemoteName, lpnLength);
|
|
513 else
|
|
514 return WNetGetConnectionA ((LPCSTR) lpLocalName, (LPSTR) lpRemoteName, lpnLength);
|
|
515 }
|
|
516
|
|
517 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
518
|
|
519 #if defined (HAVE_MS_WINDOWS)
|
|
520
|
|
521 DWORD
|
|
522 qxeWNetUseConnection (HWND hwndOwner, LPNETRESOURCEW lpNetResource, const Extbyte * lpUserID, const Extbyte * lpPassword, DWORD dwFlags, Extbyte * lpAccessName, LPDWORD lpBufferSize, LPDWORD lpResult)
|
|
523 {
|
|
524 if (XEUNICODE_P)
|
|
525 return WNetUseConnectionW (hwndOwner, lpNetResource, (LPCWSTR) lpUserID, (LPCWSTR) lpPassword, dwFlags, (LPWSTR) lpAccessName, lpBufferSize, lpResult);
|
|
526 else
|
|
527 return WNetUseConnectionA (hwndOwner, (LPNETRESOURCEA) lpNetResource, (LPCSTR) lpUserID, (LPCSTR) lpPassword, dwFlags, (LPSTR) lpAccessName, lpBufferSize, lpResult);
|
|
528 }
|
|
529
|
|
530 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
531
|
|
532 #if defined (HAVE_MS_WINDOWS)
|
|
533
|
|
534 /* NOTE: contains split-simple LPNETRESOURCE */
|
|
535 DWORD
|
|
536 qxeWNetConnectionDialog1 (LPCONNECTDLGSTRUCTW lpConnDlgStruct)
|
|
537 {
|
|
538 if (XEUNICODE_P)
|
|
539 return WNetConnectionDialog1W (lpConnDlgStruct);
|
|
540 else
|
|
541 return WNetConnectionDialog1A ((LPCONNECTDLGSTRUCTA) lpConnDlgStruct);
|
|
542 }
|
|
543
|
|
544 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
545
|
|
546 #if defined (HAVE_MS_WINDOWS)
|
|
547
|
|
548 DWORD
|
|
549 qxeWNetDisconnectDialog1 (LPDISCDLGSTRUCTW lpConnDlgStruct)
|
|
550 {
|
|
551 if (XEUNICODE_P)
|
|
552 return WNetDisconnectDialog1W (lpConnDlgStruct);
|
|
553 else
|
|
554 return WNetDisconnectDialog1A ((LPDISCDLGSTRUCTA) lpConnDlgStruct);
|
|
555 }
|
|
556
|
|
557 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
558
|
|
559 #if defined (HAVE_MS_WINDOWS)
|
|
560
|
|
561 DWORD
|
|
562 qxeWNetOpenEnum (DWORD dwScope, DWORD dwType, DWORD dwUsage, LPNETRESOURCEW lpNetResource, LPHANDLE lphEnum)
|
|
563 {
|
|
564 if (XEUNICODE_P)
|
|
565 return WNetOpenEnumW (dwScope, dwType, dwUsage, lpNetResource, lphEnum);
|
|
566 else
|
|
567 return WNetOpenEnumA (dwScope, dwType, dwUsage, (LPNETRESOURCEA) lpNetResource, lphEnum);
|
|
568 }
|
|
569
|
|
570 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
571
|
|
572 #if defined (HAVE_MS_WINDOWS)
|
|
573
|
|
574 DWORD
|
|
575 qxeWNetEnumResource (HANDLE hEnum, LPDWORD lpcCount, LPVOID lpBuffer, LPDWORD lpBufferSize)
|
|
576 {
|
|
577 if (XEUNICODE_P)
|
|
578 return WNetEnumResourceW (hEnum, lpcCount, lpBuffer, lpBufferSize);
|
|
579 else
|
|
580 return WNetEnumResourceA (hEnum, lpcCount, lpBuffer, lpBufferSize);
|
|
581 }
|
|
582
|
|
583 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
584
|
|
585 #if defined (HAVE_MS_WINDOWS)
|
|
586
|
|
587 DWORD
|
|
588 qxeWNetGetUniversalName (const Extbyte * lpLocalPath, DWORD dwInfoLevel, LPVOID lpBuffer, LPDWORD lpBufferSize)
|
|
589 {
|
|
590 if (XEUNICODE_P)
|
|
591 return WNetGetUniversalNameW ((LPCWSTR) lpLocalPath, dwInfoLevel, lpBuffer, lpBufferSize);
|
|
592 else
|
|
593 return WNetGetUniversalNameA ((LPCSTR) lpLocalPath, dwInfoLevel, lpBuffer, lpBufferSize);
|
|
594 }
|
|
595
|
|
596 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
597
|
|
598 #if defined (HAVE_MS_WINDOWS)
|
|
599
|
|
600 DWORD
|
|
601 qxeWNetGetUser (const Extbyte * lpName, Extbyte * lpUserName, LPDWORD lpnLength)
|
|
602 {
|
|
603 if (XEUNICODE_P)
|
|
604 return WNetGetUserW ((LPCWSTR) lpName, (LPWSTR) lpUserName, lpnLength);
|
|
605 else
|
|
606 return WNetGetUserA ((LPCSTR) lpName, (LPSTR) lpUserName, lpnLength);
|
|
607 }
|
|
608
|
|
609 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
610
|
|
611 #if defined (HAVE_MS_WINDOWS)
|
|
612
|
|
613 DWORD
|
|
614 qxeWNetGetProviderName (DWORD dwNetType, Extbyte * lpProviderName, LPDWORD lpBufferSize)
|
|
615 {
|
|
616 if (XEUNICODE_P)
|
|
617 return WNetGetProviderNameW (dwNetType, (LPWSTR) lpProviderName, lpBufferSize);
|
|
618 else
|
|
619 return WNetGetProviderNameA (dwNetType, (LPSTR) lpProviderName, lpBufferSize);
|
|
620 }
|
|
621
|
|
622 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
623
|
|
624 #if defined (HAVE_MS_WINDOWS)
|
|
625
|
|
626 DWORD
|
|
627 qxeWNetGetNetworkInformation (const Extbyte * lpProvider, LPNETINFOSTRUCT lpNetInfoStruct)
|
|
628 {
|
|
629 if (XEUNICODE_P)
|
|
630 return WNetGetNetworkInformationW ((LPCWSTR) lpProvider, lpNetInfoStruct);
|
|
631 else
|
|
632 return WNetGetNetworkInformationA ((LPCSTR) lpProvider, lpNetInfoStruct);
|
|
633 }
|
|
634
|
|
635 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
636
|
|
637 #if defined (HAVE_MS_WINDOWS)
|
|
638
|
|
639 DWORD
|
|
640 qxeWNetGetLastError (LPDWORD lpError, Extbyte * lpErrorBuf, DWORD nErrorBufSize, Extbyte * lpNameBuf, DWORD nNameBufSize)
|
|
641 {
|
|
642 if (XEUNICODE_P)
|
|
643 return WNetGetLastErrorW (lpError, (LPWSTR) lpErrorBuf, nErrorBufSize, (LPWSTR) lpNameBuf, nNameBufSize);
|
|
644 else
|
|
645 return WNetGetLastErrorA (lpError, (LPSTR) lpErrorBuf, nErrorBufSize, (LPSTR) lpNameBuf, nNameBufSize);
|
|
646 }
|
|
647
|
|
648 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
649
|
|
650 #if defined (HAVE_MS_WINDOWS)
|
|
651
|
|
652 DWORD
|
|
653 qxeMultinetGetConnectionPerformance (LPNETRESOURCEW lpNetResource, LPNETCONNECTINFOSTRUCT lpNetConnectInfoStruct)
|
|
654 {
|
|
655 if (XEUNICODE_P)
|
|
656 return MultinetGetConnectionPerformanceW (lpNetResource, lpNetConnectInfoStruct);
|
|
657 else
|
|
658 return MultinetGetConnectionPerformanceA ((LPNETRESOURCEA) lpNetResource, lpNetConnectInfoStruct);
|
|
659 }
|
|
660
|
|
661 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
662
|
|
663
|
|
664 /*----------------------------------------------------------------------*/
|
|
665 /* Processing file WINREG.H */
|
|
666 /*----------------------------------------------------------------------*/
|
|
667
|
|
668 /* Skipping RegConnectRegistry because error in Cygwin prototype */
|
|
669
|
|
670 LONG
|
|
671
|
|
672 qxeRegCreateKey (HKEY hKey, const Extbyte * lpSubKey, PHKEY phkResult)
|
|
673 {
|
|
674 if (XEUNICODE_P)
|
|
675 return RegCreateKeyW (hKey, (LPCWSTR) lpSubKey, phkResult);
|
|
676 else
|
|
677 return RegCreateKeyA (hKey, (LPCSTR) lpSubKey, phkResult);
|
|
678 }
|
|
679
|
|
680 LONG
|
|
681
|
|
682 qxeRegCreateKeyEx (HKEY hKey, const Extbyte * lpSubKey, DWORD Reserved, Extbyte * lpClass, DWORD dwOptions, REGSAM samDesired, LPSECURITY_ATTRIBUTES lpSecurityAttributes, PHKEY phkResult, LPDWORD lpdwDisposition)
|
|
683 {
|
|
684 if (XEUNICODE_P)
|
|
685 return RegCreateKeyExW (hKey, (LPCWSTR) lpSubKey, Reserved, (LPWSTR) lpClass, dwOptions, samDesired, lpSecurityAttributes, phkResult, lpdwDisposition);
|
|
686 else
|
|
687 return RegCreateKeyExA (hKey, (LPCSTR) lpSubKey, Reserved, (LPSTR) lpClass, dwOptions, samDesired, lpSecurityAttributes, phkResult, lpdwDisposition);
|
|
688 }
|
|
689
|
|
690 LONG
|
|
691
|
|
692 qxeRegDeleteKey (HKEY hKey, const Extbyte * lpSubKey)
|
|
693 {
|
|
694 if (XEUNICODE_P)
|
|
695 return RegDeleteKeyW (hKey, (LPCWSTR) lpSubKey);
|
|
696 else
|
|
697 return RegDeleteKeyA (hKey, (LPCSTR) lpSubKey);
|
|
698 }
|
|
699
|
|
700 LONG
|
|
701
|
|
702 qxeRegDeleteValue (HKEY hKey, const Extbyte * lpValueName)
|
|
703 {
|
|
704 if (XEUNICODE_P)
|
|
705 return RegDeleteValueW (hKey, (LPCWSTR) lpValueName);
|
|
706 else
|
|
707 return RegDeleteValueA (hKey, (LPCSTR) lpValueName);
|
|
708 }
|
|
709
|
|
710 LONG
|
|
711
|
|
712 qxeRegEnumKey (HKEY hKey, DWORD dwIndex, Extbyte * lpName, DWORD cbName)
|
|
713 {
|
|
714 if (XEUNICODE_P)
|
|
715 return RegEnumKeyW (hKey, dwIndex, (LPWSTR) lpName, cbName);
|
|
716 else
|
|
717 return RegEnumKeyA (hKey, dwIndex, (LPSTR) lpName, cbName);
|
|
718 }
|
|
719
|
|
720 LONG
|
|
721
|
|
722 qxeRegEnumKeyEx (HKEY hKey, DWORD dwIndex, Extbyte * lpName, LPDWORD lpcbName, LPDWORD lpReserved, Extbyte * lpClass, LPDWORD lpcbClass, PFILETIME lpftLastWriteTime)
|
|
723 {
|
|
724 if (XEUNICODE_P)
|
|
725 return RegEnumKeyExW (hKey, dwIndex, (LPWSTR) lpName, lpcbName, lpReserved, (LPWSTR) lpClass, lpcbClass, lpftLastWriteTime);
|
|
726 else
|
|
727 return RegEnumKeyExA (hKey, dwIndex, (LPSTR) lpName, lpcbName, lpReserved, (LPSTR) lpClass, lpcbClass, lpftLastWriteTime);
|
|
728 }
|
|
729
|
|
730 LONG
|
|
731
|
|
732 qxeRegEnumValue (HKEY hKey, DWORD dwIndex, Extbyte * lpValueName, LPDWORD lpcbValueName, LPDWORD lpReserved, LPDWORD lpType, LPBYTE lpData, LPDWORD lpcbData)
|
|
733 {
|
|
734 if (XEUNICODE_P)
|
|
735 return RegEnumValueW (hKey, dwIndex, (LPWSTR) lpValueName, lpcbValueName, lpReserved, lpType, lpData, lpcbData);
|
|
736 else
|
|
737 return RegEnumValueA (hKey, dwIndex, (LPSTR) lpValueName, lpcbValueName, lpReserved, lpType, lpData, lpcbData);
|
|
738 }
|
|
739
|
|
740 LONG
|
|
741
|
|
742 qxeRegLoadKey (HKEY hKey, const Extbyte * lpSubKey, const Extbyte * lpFile)
|
|
743 {
|
|
744 if (XEUNICODE_P)
|
|
745 return RegLoadKeyW (hKey, (LPCWSTR) lpSubKey, (LPCWSTR) lpFile);
|
|
746 else
|
|
747 return RegLoadKeyA (hKey, (LPCSTR) lpSubKey, (LPCSTR) lpFile);
|
|
748 }
|
|
749
|
|
750 LONG
|
|
751
|
|
752 qxeRegOpenKey (HKEY hKey, const Extbyte * lpSubKey, PHKEY phkResult)
|
|
753 {
|
|
754 if (XEUNICODE_P)
|
|
755 return RegOpenKeyW (hKey, (LPCWSTR) lpSubKey, phkResult);
|
|
756 else
|
|
757 return RegOpenKeyA (hKey, (LPCSTR) lpSubKey, phkResult);
|
|
758 }
|
|
759
|
|
760 LONG
|
|
761
|
|
762 qxeRegOpenKeyEx (HKEY hKey, const Extbyte * lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult)
|
|
763 {
|
|
764 if (XEUNICODE_P)
|
|
765 return RegOpenKeyExW (hKey, (LPCWSTR) lpSubKey, ulOptions, samDesired, phkResult);
|
|
766 else
|
|
767 return RegOpenKeyExA (hKey, (LPCSTR) lpSubKey, ulOptions, samDesired, phkResult);
|
|
768 }
|
|
769
|
|
770 LONG
|
|
771
|
|
772 qxeRegQueryInfoKey (HKEY hKey, Extbyte * lpClass, LPDWORD lpcbClass, LPDWORD lpReserved, LPDWORD lpcSubKeys, LPDWORD lpcbMaxSubKeyLen, LPDWORD lpcbMaxClassLen, LPDWORD lpcValues, LPDWORD lpcbMaxValueNameLen, LPDWORD lpcbMaxValueLen, LPDWORD lpcbSecurityDescriptor, PFILETIME lpftLastWriteTime)
|
|
773 {
|
|
774 if (XEUNICODE_P)
|
|
775 return RegQueryInfoKeyW (hKey, (LPWSTR) lpClass, lpcbClass, lpReserved, lpcSubKeys, lpcbMaxSubKeyLen, lpcbMaxClassLen, lpcValues, lpcbMaxValueNameLen, lpcbMaxValueLen, lpcbSecurityDescriptor, lpftLastWriteTime);
|
|
776 else
|
|
777 return RegQueryInfoKeyA (hKey, (LPSTR) lpClass, lpcbClass, lpReserved, lpcSubKeys, lpcbMaxSubKeyLen, lpcbMaxClassLen, lpcValues, lpcbMaxValueNameLen, lpcbMaxValueLen, lpcbSecurityDescriptor, lpftLastWriteTime);
|
|
778 }
|
|
779
|
|
780 LONG
|
|
781
|
|
782 qxeRegQueryValue (HKEY hKey, const Extbyte * lpSubKey, Extbyte * lpValue, PLONG lpcbValue)
|
|
783 {
|
|
784 if (XEUNICODE_P)
|
|
785 return RegQueryValueW (hKey, (LPCWSTR) lpSubKey, (LPWSTR) lpValue, lpcbValue);
|
|
786 else
|
|
787 return RegQueryValueA (hKey, (LPCSTR) lpSubKey, (LPSTR) lpValue, lpcbValue);
|
|
788 }
|
|
789
|
|
790 LONG
|
|
791
|
|
792 qxeRegQueryMultipleValues (HKEY hKey, PVALENTW val_list, DWORD num_vals, Extbyte * lpValueBuf, LPDWORD ldwTotsize)
|
|
793 {
|
|
794 if (XEUNICODE_P)
|
|
795 return RegQueryMultipleValuesW (hKey, val_list, num_vals, (LPWSTR) lpValueBuf, ldwTotsize);
|
|
796 else
|
|
797 return RegQueryMultipleValuesA (hKey, (PVALENTA) val_list, num_vals, (LPSTR) lpValueBuf, ldwTotsize);
|
|
798 }
|
|
799
|
|
800 LONG
|
|
801
|
|
802 qxeRegQueryValueEx (HKEY hKey, const Extbyte * lpValueName, LPDWORD lpReserved, LPDWORD lpType, LPBYTE lpData, LPDWORD lpcbData)
|
|
803 {
|
|
804 if (XEUNICODE_P)
|
|
805 return RegQueryValueExW (hKey, (LPCWSTR) lpValueName, lpReserved, lpType, lpData, lpcbData);
|
|
806 else
|
|
807 return RegQueryValueExA (hKey, (LPCSTR) lpValueName, lpReserved, lpType, lpData, lpcbData);
|
|
808 }
|
|
809
|
|
810 LONG
|
|
811
|
|
812 qxeRegReplaceKey (HKEY hKey, const Extbyte * lpSubKey, const Extbyte * lpNewFile, const Extbyte * lpOldFile)
|
|
813 {
|
|
814 if (XEUNICODE_P)
|
|
815 return RegReplaceKeyW (hKey, (LPCWSTR) lpSubKey, (LPCWSTR) lpNewFile, (LPCWSTR) lpOldFile);
|
|
816 else
|
|
817 return RegReplaceKeyA (hKey, (LPCSTR) lpSubKey, (LPCSTR) lpNewFile, (LPCSTR) lpOldFile);
|
|
818 }
|
|
819
|
|
820 LONG
|
|
821
|
|
822 qxeRegRestoreKey (HKEY hKey, const Extbyte * lpFile, DWORD dwFlags)
|
|
823 {
|
|
824 if (XEUNICODE_P)
|
|
825 return RegRestoreKeyW (hKey, (LPCWSTR) lpFile, dwFlags);
|
|
826 else
|
|
827 return RegRestoreKeyA (hKey, (LPCSTR) lpFile, dwFlags);
|
|
828 }
|
|
829
|
|
830 LONG
|
|
831
|
|
832 qxeRegSaveKey (HKEY hKey, const Extbyte * lpFile, LPSECURITY_ATTRIBUTES lpSecurityAttributes)
|
|
833 {
|
|
834 if (XEUNICODE_P)
|
|
835 return RegSaveKeyW (hKey, (LPCWSTR) lpFile, lpSecurityAttributes);
|
|
836 else
|
|
837 return RegSaveKeyA (hKey, (LPCSTR) lpFile, lpSecurityAttributes);
|
|
838 }
|
|
839
|
|
840 LONG
|
|
841
|
|
842 qxeRegSetValue (HKEY hKey, const Extbyte * lpSubKey, DWORD dwType, const Extbyte * lpData, DWORD cbData)
|
|
843 {
|
|
844 if (XEUNICODE_P)
|
|
845 return RegSetValueW (hKey, (LPCWSTR) lpSubKey, dwType, (LPCWSTR) lpData, cbData);
|
|
846 else
|
|
847 return RegSetValueA (hKey, (LPCSTR) lpSubKey, dwType, (LPCSTR) lpData, cbData);
|
|
848 }
|
|
849
|
|
850 LONG
|
|
851
|
|
852 qxeRegSetValueEx (HKEY hKey, const Extbyte * lpValueName, DWORD Reserved, DWORD dwType, CONST BYTE* lpData, DWORD cbData)
|
|
853 {
|
|
854 if (XEUNICODE_P)
|
|
855 return RegSetValueExW (hKey, (LPCWSTR) lpValueName, Reserved, dwType, lpData, cbData);
|
|
856 else
|
|
857 return RegSetValueExA (hKey, (LPCSTR) lpValueName, Reserved, dwType, lpData, cbData);
|
|
858 }
|
|
859
|
|
860 LONG
|
|
861
|
|
862 qxeRegUnLoadKey (HKEY hKey, const Extbyte * lpSubKey)
|
|
863 {
|
|
864 if (XEUNICODE_P)
|
|
865 return RegUnLoadKeyW (hKey, (LPCWSTR) lpSubKey);
|
|
866 else
|
|
867 return RegUnLoadKeyA (hKey, (LPCSTR) lpSubKey);
|
|
868 }
|
|
869
|
|
870 BOOL
|
|
871
|
|
872 qxeInitiateSystemShutdown (Extbyte * lpMachineName, Extbyte * lpMessage, DWORD dwTimeout, BOOL bForceAppsClosed, BOOL bRebootAfterShutdown)
|
|
873 {
|
|
874 if (XEUNICODE_P)
|
|
875 return InitiateSystemShutdownW ((LPWSTR) lpMachineName, (LPWSTR) lpMessage, dwTimeout, bForceAppsClosed, bRebootAfterShutdown);
|
|
876 else
|
|
877 return InitiateSystemShutdownA ((LPSTR) lpMachineName, (LPSTR) lpMessage, dwTimeout, bForceAppsClosed, bRebootAfterShutdown);
|
|
878 }
|
|
879
|
|
880 BOOL
|
|
881
|
|
882 qxeAbortSystemShutdown (Extbyte * lpMachineName)
|
|
883 {
|
|
884 if (XEUNICODE_P)
|
|
885 return AbortSystemShutdownW ((LPWSTR) lpMachineName);
|
|
886 else
|
|
887 return AbortSystemShutdownA ((LPSTR) lpMachineName);
|
|
888 }
|
|
889
|
|
890
|
|
891 /*----------------------------------------------------------------------*/
|
|
892 /* Processing file SHELLAPI.H */
|
|
893 /*----------------------------------------------------------------------*/
|
|
894
|
|
895 UINT
|
|
896 qxeDragQueryFile (HDROP arg1, UINT arg2, Extbyte * arg3, UINT arg4)
|
|
897 {
|
|
898 if (XEUNICODE_P)
|
|
899 return DragQueryFileW (arg1, arg2, (LPWSTR) arg3, arg4);
|
|
900 else
|
|
901 return DragQueryFileA (arg1, arg2, (LPSTR) arg3, arg4);
|
|
902 }
|
|
903
|
|
904 HINSTANCE
|
|
905 qxeShellExecute (HWND hwnd, const Extbyte * lpOperation, const Extbyte * lpFile, const Extbyte * lpParameters, const Extbyte * lpDirectory, INT nShowCmd)
|
|
906 {
|
|
907 if (XEUNICODE_P)
|
|
908 return ShellExecuteW (hwnd, (LPCWSTR) lpOperation, (LPCWSTR) lpFile, (LPCWSTR) lpParameters, (LPCWSTR) lpDirectory, nShowCmd);
|
|
909 else
|
|
910 return ShellExecuteA (hwnd, (LPCSTR) lpOperation, (LPCSTR) lpFile, (LPCSTR) lpParameters, (LPCSTR) lpDirectory, nShowCmd);
|
|
911 }
|
|
912
|
|
913 HINSTANCE
|
|
914 qxeFindExecutable (const Extbyte * lpFile, const Extbyte * lpDirectory, Extbyte * lpResult)
|
|
915 {
|
|
916 if (XEUNICODE_P)
|
|
917 return FindExecutableW ((LPCWSTR) lpFile, (LPCWSTR) lpDirectory, (LPWSTR) lpResult);
|
|
918 else
|
|
919 return FindExecutableA ((LPCSTR) lpFile, (LPCSTR) lpDirectory, (LPSTR) lpResult);
|
|
920 }
|
|
921
|
|
922 /* Error if CommandLineToArgv used: Unicode-only */
|
|
923
|
|
924 INT
|
|
925 qxeShellAbout (HWND hWnd, const Extbyte * szApp, const Extbyte * szOtherStuff, HICON hIcon)
|
|
926 {
|
|
927 if (XEUNICODE_P)
|
|
928 return ShellAboutW (hWnd, (LPCWSTR) szApp, (LPCWSTR) szOtherStuff, hIcon);
|
|
929 else
|
|
930 return ShellAboutA (hWnd, (LPCSTR) szApp, (LPCSTR) szOtherStuff, hIcon);
|
|
931 }
|
|
932
|
|
933 HICON
|
|
934 qxeExtractAssociatedIcon (HINSTANCE hInst, Extbyte * lpIconPath, LPWORD lpiIcon)
|
|
935 {
|
|
936 if (XEUNICODE_P)
|
|
937 return ExtractAssociatedIconW (hInst, (LPWSTR) lpIconPath, lpiIcon);
|
|
938 else
|
|
939 return ExtractAssociatedIconA (hInst, (LPSTR) lpIconPath, lpiIcon);
|
|
940 }
|
|
941
|
|
942 HICON
|
|
943 qxeExtractIcon (HINSTANCE hInst, const Extbyte * lpszExeFileName, UINT nIconIndex)
|
|
944 {
|
|
945 if (XEUNICODE_P)
|
|
946 return ExtractIconW (hInst, (LPCWSTR) lpszExeFileName, nIconIndex);
|
|
947 else
|
|
948 return ExtractIconA (hInst, (LPCSTR) lpszExeFileName, nIconIndex);
|
|
949 }
|
|
950
|
|
951 #if !defined (CYGWIN_HEADERS)
|
|
952
|
|
953 /* NOTE: NT 4.0+ only */
|
|
954 DWORD
|
|
955 qxeDoEnvironmentSubst (Extbyte * szString, UINT cbString)
|
|
956 {
|
|
957 if (XEUNICODE_P)
|
|
958 return DoEnvironmentSubstW ((LPWSTR) szString, cbString);
|
|
959 else
|
|
960 return DoEnvironmentSubstA ((LPSTR) szString, cbString);
|
|
961 }
|
|
962
|
|
963 #endif /* !defined (CYGWIN_HEADERS) */
|
|
964
|
|
965 /* Error if FindEnvironmentString used: causes link error; NT 4.0+ only */
|
|
966
|
|
967 /* Skipping ExtractIconEx because NT 4.0+ only, error in Cygwin prototype */
|
|
968
|
|
969 /* NOTE: NT 4.0+ only */
|
|
970 int
|
|
971 qxeSHFileOperation (LPSHFILEOPSTRUCTW lpFileOp)
|
|
972 {
|
|
973 if (XEUNICODE_P)
|
|
974 return SHFileOperationW (lpFileOp);
|
|
975 else
|
|
976 return SHFileOperationA ((LPSHFILEOPSTRUCTA) lpFileOp);
|
|
977 }
|
|
978
|
|
979 /* NOTE: NT 4.0+ only */
|
|
980 BOOL
|
|
981 qxeShellExecuteEx (LPSHELLEXECUTEINFOW lpExecInfo)
|
|
982 {
|
|
983 if (XEUNICODE_P)
|
|
984 return ShellExecuteExW (lpExecInfo);
|
|
985 else
|
|
986 return ShellExecuteExA ((LPSHELLEXECUTEINFOA) lpExecInfo);
|
|
987 }
|
|
988
|
|
989 /* Error if WinExecError used: causes link error; NT 4.0+ only */
|
|
990
|
|
991 #if !defined (CYGWIN_HEADERS)
|
|
992
|
|
993 /* NOTE: NT 4.0+ only */
|
|
994 HRESULT
|
|
995 qxeSHQueryRecycleBin (const Extbyte * pszRootPath, LPSHQUERYRBINFO pSHQueryRBInfo)
|
|
996 {
|
|
997 if (XEUNICODE_P)
|
|
998 return SHQueryRecycleBinW ((LPCWSTR) pszRootPath, pSHQueryRBInfo);
|
|
999 else
|
|
1000 return SHQueryRecycleBinA ((LPCSTR) pszRootPath, pSHQueryRBInfo);
|
|
1001 }
|
|
1002
|
|
1003 #endif /* !defined (CYGWIN_HEADERS) */
|
|
1004
|
|
1005 #if !defined (CYGWIN_HEADERS)
|
|
1006
|
|
1007 /* NOTE: NT 4.0+ only */
|
|
1008 HRESULT
|
|
1009 qxeSHEmptyRecycleBin (HWND hwnd, const Extbyte * pszRootPath, DWORD dwFlags)
|
|
1010 {
|
|
1011 if (XEUNICODE_P)
|
|
1012 return SHEmptyRecycleBinW (hwnd, (LPCWSTR) pszRootPath, dwFlags);
|
|
1013 else
|
|
1014 return SHEmptyRecycleBinA (hwnd, (LPCSTR) pszRootPath, dwFlags);
|
|
1015 }
|
|
1016
|
|
1017 #endif /* !defined (CYGWIN_HEADERS) */
|
|
1018
|
|
1019 /* Error if Shell_NotifyIcon used: split-sized NOTIFYICONDATA, NT 4.0+ only */
|
|
1020
|
|
1021 /* Skipping SHGetFileInfo because split-sized SHFILEINFO, NT 4.0+ only */
|
|
1022
|
|
1023 /* Error if SHGetDiskFreeSpace used: causes link error; NT 4.0+ only */
|
|
1024
|
|
1025 #if !defined (CYGWIN_HEADERS)
|
|
1026
|
|
1027 /* NOTE: NT 4.0+ only */
|
|
1028 BOOL
|
|
1029 qxeSHGetNewLinkInfo (const Extbyte * pszLinkTo, const Extbyte * pszDir, Extbyte * pszName, BOOL * pfMustCopy, UINT uFlags)
|
|
1030 {
|
|
1031 if (XEUNICODE_P)
|
|
1032 return SHGetNewLinkInfoW ((LPCWSTR) pszLinkTo, (LPCWSTR) pszDir, (LPWSTR) pszName, pfMustCopy, uFlags);
|
|
1033 else
|
|
1034 return SHGetNewLinkInfoA ((LPCSTR) pszLinkTo, (LPCSTR) pszDir, (LPSTR) pszName, pfMustCopy, uFlags);
|
|
1035 }
|
|
1036
|
|
1037 #endif /* !defined (CYGWIN_HEADERS) */
|
|
1038
|
|
1039 #if !defined (CYGWIN_HEADERS)
|
|
1040
|
|
1041 /* NOTE: NT 4.0+ only */
|
|
1042 BOOL
|
|
1043 qxeSHInvokePrinterCommand (HWND hwnd, UINT uAction, const Extbyte * lpBuf1, const Extbyte * lpBuf2, BOOL fModal)
|
|
1044 {
|
|
1045 if (XEUNICODE_P)
|
|
1046 return SHInvokePrinterCommandW (hwnd, uAction, (LPCWSTR) lpBuf1, (LPCWSTR) lpBuf2, fModal);
|
|
1047 else
|
|
1048 return SHInvokePrinterCommandA (hwnd, uAction, (LPCSTR) lpBuf1, (LPCSTR) lpBuf2, fModal);
|
|
1049 }
|
|
1050
|
|
1051 #endif /* !defined (CYGWIN_HEADERS) */
|
|
1052
|
|
1053
|
|
1054 /*----------------------------------------------------------------------*/
|
|
1055 /* Processing file WINCON.H */
|
|
1056 /*----------------------------------------------------------------------*/
|
|
1057
|
|
1058 BOOL
|
|
1059 qxePeekConsoleInput (HANDLE hConsoleInput, PINPUT_RECORD lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsRead)
|
|
1060 {
|
|
1061 if (XEUNICODE_P)
|
|
1062 return PeekConsoleInputW (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
|
|
1063 else
|
|
1064 return PeekConsoleInputA (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
|
|
1065 }
|
|
1066
|
|
1067 BOOL
|
|
1068 qxeReadConsoleInput (HANDLE hConsoleInput, PINPUT_RECORD lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsRead)
|
|
1069 {
|
|
1070 if (XEUNICODE_P)
|
|
1071 return ReadConsoleInputW (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
|
|
1072 else
|
|
1073 return ReadConsoleInputA (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsRead);
|
|
1074 }
|
|
1075
|
|
1076 BOOL
|
|
1077 qxeWriteConsoleInput (HANDLE hConsoleInput, CONST INPUT_RECORD * lpBuffer, DWORD nLength, LPDWORD lpNumberOfEventsWritten)
|
|
1078 {
|
|
1079 if (XEUNICODE_P)
|
|
1080 return WriteConsoleInputW (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsWritten);
|
|
1081 else
|
|
1082 return WriteConsoleInputA (hConsoleInput, lpBuffer, nLength, lpNumberOfEventsWritten);
|
|
1083 }
|
|
1084
|
|
1085 BOOL
|
|
1086 qxeReadConsoleOutput (HANDLE hConsoleOutput, PCHAR_INFO lpBuffer, COORD dwBufferSize, COORD dwBufferCoord, PSMALL_RECT lpReadRegion)
|
|
1087 {
|
|
1088 if (XEUNICODE_P)
|
|
1089 return ReadConsoleOutputW (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpReadRegion);
|
|
1090 else
|
|
1091 return ReadConsoleOutputA (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpReadRegion);
|
|
1092 }
|
|
1093
|
|
1094 BOOL
|
|
1095 qxeWriteConsoleOutput (HANDLE hConsoleOutput, CONST CHAR_INFO * lpBuffer, COORD dwBufferSize, COORD dwBufferCoord, PSMALL_RECT lpWriteRegion)
|
|
1096 {
|
|
1097 if (XEUNICODE_P)
|
|
1098 return WriteConsoleOutputW (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpWriteRegion);
|
|
1099 else
|
|
1100 return WriteConsoleOutputA (hConsoleOutput, lpBuffer, dwBufferSize, dwBufferCoord, lpWriteRegion);
|
|
1101 }
|
|
1102
|
|
1103 BOOL
|
|
1104 qxeReadConsoleOutputCharacter (HANDLE hConsoleOutput, Extbyte * lpCharacter, DWORD nLength, COORD dwReadCoord, LPDWORD lpNumberOfCharsRead)
|
|
1105 {
|
|
1106 if (XEUNICODE_P)
|
|
1107 return ReadConsoleOutputCharacterW (hConsoleOutput, (LPWSTR) lpCharacter, nLength, dwReadCoord, lpNumberOfCharsRead);
|
|
1108 else
|
|
1109 return ReadConsoleOutputCharacterA (hConsoleOutput, (LPSTR) lpCharacter, nLength, dwReadCoord, lpNumberOfCharsRead);
|
|
1110 }
|
|
1111
|
|
1112 BOOL
|
|
1113 qxeWriteConsoleOutputCharacter (HANDLE hConsoleOutput, const Extbyte * lpCharacter, DWORD nLength, COORD dwWriteCoord, LPDWORD lpNumberOfCharsWritten)
|
|
1114 {
|
|
1115 if (XEUNICODE_P)
|
|
1116 return WriteConsoleOutputCharacterW (hConsoleOutput, (LPCWSTR) lpCharacter, nLength, dwWriteCoord, lpNumberOfCharsWritten);
|
|
1117 else
|
|
1118 return WriteConsoleOutputCharacterA (hConsoleOutput, (LPCSTR) lpCharacter, nLength, dwWriteCoord, lpNumberOfCharsWritten);
|
|
1119 }
|
|
1120
|
|
1121 /* Error if FillConsoleOutputCharacter used: split CHAR */
|
|
1122
|
|
1123 BOOL
|
|
1124 qxeScrollConsoleScreenBuffer (HANDLE hConsoleOutput, CONST SMALL_RECT * lpScrollRectangle, CONST SMALL_RECT * lpClipRectangle, COORD dwDestinationOrigin, CONST CHAR_INFO * lpFill)
|
|
1125 {
|
|
1126 if (XEUNICODE_P)
|
|
1127 return ScrollConsoleScreenBufferW (hConsoleOutput, lpScrollRectangle, lpClipRectangle, dwDestinationOrigin, lpFill);
|
|
1128 else
|
|
1129 return ScrollConsoleScreenBufferA (hConsoleOutput, lpScrollRectangle, lpClipRectangle, dwDestinationOrigin, lpFill);
|
|
1130 }
|
|
1131
|
|
1132 DWORD
|
|
1133 qxeGetConsoleTitle (Extbyte * lpConsoleTitle, DWORD nSize)
|
|
1134 {
|
|
1135 if (XEUNICODE_P)
|
|
1136 return GetConsoleTitleW ((LPWSTR) lpConsoleTitle, nSize);
|
|
1137 else
|
|
1138 return GetConsoleTitleA ((LPSTR) lpConsoleTitle, nSize);
|
|
1139 }
|
|
1140
|
|
1141 BOOL
|
|
1142 qxeSetConsoleTitle (const Extbyte * lpConsoleTitle)
|
|
1143 {
|
|
1144 if (XEUNICODE_P)
|
|
1145 return SetConsoleTitleW ((LPCWSTR) lpConsoleTitle);
|
|
1146 else
|
|
1147 return SetConsoleTitleA ((LPCSTR) lpConsoleTitle);
|
|
1148 }
|
|
1149
|
|
1150 BOOL
|
|
1151 qxeReadConsole (HANDLE hConsoleInput, LPVOID lpBuffer, DWORD nNumberOfCharsToRead, LPDWORD lpNumberOfCharsRead, LPVOID lpReserved)
|
|
1152 {
|
|
1153 if (XEUNICODE_P)
|
|
1154 return ReadConsoleW (hConsoleInput, lpBuffer, nNumberOfCharsToRead, lpNumberOfCharsRead, lpReserved);
|
|
1155 else
|
|
1156 return ReadConsoleA (hConsoleInput, lpBuffer, nNumberOfCharsToRead, lpNumberOfCharsRead, lpReserved);
|
|
1157 }
|
|
1158
|
|
1159 BOOL
|
|
1160 qxeWriteConsole (HANDLE hConsoleOutput, CONST VOID * lpBuffer, DWORD nNumberOfCharsToWrite, LPDWORD lpNumberOfCharsWritten, LPVOID lpReserved)
|
|
1161 {
|
|
1162 if (XEUNICODE_P)
|
|
1163 return WriteConsoleW (hConsoleOutput, lpBuffer, nNumberOfCharsToWrite, lpNumberOfCharsWritten, lpReserved);
|
|
1164 else
|
|
1165 return WriteConsoleA (hConsoleOutput, lpBuffer, nNumberOfCharsToWrite, lpNumberOfCharsWritten, lpReserved);
|
|
1166 }
|
|
1167
|
|
1168
|
|
1169 /*----------------------------------------------------------------------*/
|
|
1170 /* Processing file IMM.H */
|
|
1171 /*----------------------------------------------------------------------*/
|
|
1172
|
|
1173 #if defined (HAVE_MS_WINDOWS)
|
|
1174
|
|
1175 HKL
|
|
1176 qxeImmInstallIME (const Extbyte * lpszIMEFileName, const Extbyte * lpszLayoutText)
|
|
1177 {
|
|
1178 if (XEUNICODE_P)
|
|
1179 return ImmInstallIMEW ((LPCWSTR) lpszIMEFileName, (LPCWSTR) lpszLayoutText);
|
|
1180 else
|
|
1181 return ImmInstallIMEA ((LPCSTR) lpszIMEFileName, (LPCSTR) lpszLayoutText);
|
|
1182 }
|
|
1183
|
|
1184 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1185
|
|
1186 #if defined (HAVE_MS_WINDOWS)
|
|
1187
|
|
1188 UINT
|
|
1189 qxeImmGetDescription (HKL arg1, Extbyte * arg2, UINT uBufLen)
|
|
1190 {
|
|
1191 if (XEUNICODE_P)
|
|
1192 return ImmGetDescriptionW (arg1, (LPWSTR) arg2, uBufLen);
|
|
1193 else
|
|
1194 return ImmGetDescriptionA (arg1, (LPSTR) arg2, uBufLen);
|
|
1195 }
|
|
1196
|
|
1197 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1198
|
|
1199 #if defined (HAVE_MS_WINDOWS)
|
|
1200
|
|
1201 UINT
|
|
1202 qxeImmGetIMEFileName (HKL arg1, Extbyte * arg2, UINT uBufLen)
|
|
1203 {
|
|
1204 if (XEUNICODE_P)
|
|
1205 return ImmGetIMEFileNameW (arg1, (LPWSTR) arg2, uBufLen);
|
|
1206 else
|
|
1207 return ImmGetIMEFileNameA (arg1, (LPSTR) arg2, uBufLen);
|
|
1208 }
|
|
1209
|
|
1210 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1211
|
|
1212 #if defined (HAVE_MS_WINDOWS)
|
|
1213
|
|
1214 LONG
|
|
1215 qxeImmGetCompositionString (HIMC arg1, DWORD arg2, LPVOID arg3, DWORD arg4)
|
|
1216 {
|
|
1217 if (XEUNICODE_P)
|
|
1218 return ImmGetCompositionStringW (arg1, arg2, arg3, arg4);
|
|
1219 else
|
|
1220 return ImmGetCompositionStringA (arg1, arg2, arg3, arg4);
|
|
1221 }
|
|
1222
|
|
1223 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1224
|
|
1225 #if defined (HAVE_MS_WINDOWS)
|
|
1226
|
|
1227 BOOL
|
|
1228 qxeImmSetCompositionString (HIMC arg1, DWORD dwIndex, LPCVOID lpComp, DWORD arg4, LPCVOID lpRead, DWORD arg6)
|
|
1229 {
|
|
1230 if (XEUNICODE_P)
|
|
1231 return ImmSetCompositionStringW (arg1, dwIndex, lpComp, arg4, lpRead, arg6);
|
|
1232 else
|
|
1233 return ImmSetCompositionStringA (arg1, dwIndex, lpComp, arg4, lpRead, arg6);
|
|
1234 }
|
|
1235
|
|
1236 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1237
|
|
1238 #if defined (HAVE_MS_WINDOWS)
|
|
1239
|
|
1240 DWORD
|
|
1241 qxeImmGetCandidateListCount (HIMC arg1, LPDWORD lpdwListCount)
|
|
1242 {
|
|
1243 if (XEUNICODE_P)
|
|
1244 return ImmGetCandidateListCountW (arg1, lpdwListCount);
|
|
1245 else
|
|
1246 return ImmGetCandidateListCountA (arg1, lpdwListCount);
|
|
1247 }
|
|
1248
|
|
1249 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1250
|
|
1251 #if defined (HAVE_MS_WINDOWS)
|
|
1252
|
|
1253 DWORD
|
|
1254 qxeImmGetCandidateList (HIMC arg1, DWORD deIndex, LPCANDIDATELIST arg3, DWORD dwBufLen)
|
|
1255 {
|
|
1256 if (XEUNICODE_P)
|
|
1257 return ImmGetCandidateListW (arg1, deIndex, arg3, dwBufLen);
|
|
1258 else
|
|
1259 return ImmGetCandidateListA (arg1, deIndex, arg3, dwBufLen);
|
|
1260 }
|
|
1261
|
|
1262 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1263
|
|
1264 #if defined (HAVE_MS_WINDOWS)
|
|
1265
|
|
1266 DWORD
|
|
1267 qxeImmGetGuideLine (HIMC arg1, DWORD dwIndex, Extbyte * arg3, DWORD dwBufLen)
|
|
1268 {
|
|
1269 if (XEUNICODE_P)
|
|
1270 return ImmGetGuideLineW (arg1, dwIndex, (LPWSTR) arg3, dwBufLen);
|
|
1271 else
|
|
1272 return ImmGetGuideLineA (arg1, dwIndex, (LPSTR) arg3, dwBufLen);
|
|
1273 }
|
|
1274
|
|
1275 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1276
|
|
1277 #if defined (HAVE_MS_WINDOWS)
|
|
1278
|
|
1279 /* Skipping ImmGetCompositionFont because split-sized LOGFONT */
|
|
1280
|
|
1281 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1282
|
|
1283 #if defined (HAVE_MS_WINDOWS)
|
|
1284
|
|
1285 /* Skipping ImmSetCompositionFont because split-sized LOGFONT */
|
|
1286
|
|
1287 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1288
|
|
1289 #if defined (HAVE_MS_WINDOWS)
|
|
1290
|
|
1291 /* NOTE: // split-simple REGISTERWORD */
|
|
1292 BOOL
|
|
1293 qxeImmConfigureIME (HKL arg1, HWND arg2, DWORD arg3, LPVOID arg4)
|
|
1294 {
|
|
1295 if (XEUNICODE_P)
|
|
1296 return ImmConfigureIMEW (arg1, arg2, arg3, arg4);
|
|
1297 else
|
|
1298 return ImmConfigureIMEA (arg1, arg2, arg3, arg4);
|
|
1299 }
|
|
1300
|
|
1301 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1302
|
|
1303 #if defined (HAVE_MS_WINDOWS)
|
|
1304
|
|
1305 /* NOTE: // strings of various sorts */
|
|
1306 LRESULT
|
|
1307 qxeImmEscape (HKL arg1, HIMC arg2, UINT arg3, LPVOID arg4)
|
|
1308 {
|
|
1309 if (XEUNICODE_P)
|
|
1310 return ImmEscapeW (arg1, arg2, arg3, arg4);
|
|
1311 else
|
|
1312 return ImmEscapeA (arg1, arg2, arg3, arg4);
|
|
1313 }
|
|
1314
|
|
1315 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1316
|
|
1317 #if defined (HAVE_MS_WINDOWS)
|
|
1318
|
|
1319 DWORD
|
|
1320 qxeImmGetConversionList (HKL arg1, HIMC arg2, const Extbyte * arg3, LPCANDIDATELIST arg4, DWORD dwBufLen, UINT uFlag)
|
|
1321 {
|
|
1322 if (XEUNICODE_P)
|
|
1323 return ImmGetConversionListW (arg1, arg2, (LPCWSTR) arg3, arg4, dwBufLen, uFlag);
|
|
1324 else
|
|
1325 return ImmGetConversionListA (arg1, arg2, (LPCSTR) arg3, arg4, dwBufLen, uFlag);
|
|
1326 }
|
|
1327
|
|
1328 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1329
|
|
1330 #if defined (HAVE_MS_WINDOWS)
|
|
1331
|
|
1332 BOOL
|
|
1333 qxeImmIsUIMessage (HWND arg1, UINT arg2, WPARAM arg3, LPARAM arg4)
|
|
1334 {
|
|
1335 if (XEUNICODE_P)
|
|
1336 return ImmIsUIMessageW (arg1, arg2, arg3, arg4);
|
|
1337 else
|
|
1338 return ImmIsUIMessageA (arg1, arg2, arg3, arg4);
|
|
1339 }
|
|
1340
|
|
1341 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1342
|
|
1343 #if defined (HAVE_MS_WINDOWS)
|
|
1344
|
|
1345 BOOL
|
|
1346 qxeImmRegisterWord (HKL arg1, const Extbyte * lpszReading, DWORD arg3, const Extbyte * lpszRegister)
|
|
1347 {
|
|
1348 if (XEUNICODE_P)
|
|
1349 return ImmRegisterWordW (arg1, (LPCWSTR) lpszReading, arg3, (LPCWSTR) lpszRegister);
|
|
1350 else
|
|
1351 return ImmRegisterWordA (arg1, (LPCSTR) lpszReading, arg3, (LPCSTR) lpszRegister);
|
|
1352 }
|
|
1353
|
|
1354 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1355
|
|
1356 #if defined (HAVE_MS_WINDOWS)
|
|
1357
|
|
1358 BOOL
|
|
1359 qxeImmUnregisterWord (HKL arg1, const Extbyte * lpszReading, DWORD arg3, const Extbyte * lpszUnregister)
|
|
1360 {
|
|
1361 if (XEUNICODE_P)
|
|
1362 return ImmUnregisterWordW (arg1, (LPCWSTR) lpszReading, arg3, (LPCWSTR) lpszUnregister);
|
|
1363 else
|
|
1364 return ImmUnregisterWordA (arg1, (LPCSTR) lpszReading, arg3, (LPCSTR) lpszUnregister);
|
|
1365 }
|
|
1366
|
|
1367 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1368
|
|
1369 #if defined (HAVE_MS_WINDOWS)
|
|
1370
|
|
1371 /* Error if ImmGetRegisterWordStyle used: split-sized STYLEBUF */
|
|
1372
|
|
1373 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1374
|
|
1375 #if defined (HAVE_MS_WINDOWS)
|
|
1376
|
|
1377 UINT
|
|
1378 qxeImmEnumRegisterWord (HKL arg1, REGISTERWORDENUMPROCW arg2, const Extbyte * lpszReading, DWORD arg4, const Extbyte * lpszRegister, LPVOID arg6)
|
|
1379 {
|
|
1380 if (XEUNICODE_P)
|
|
1381 return ImmEnumRegisterWordW (arg1, arg2, (LPCWSTR) lpszReading, arg4, (LPCWSTR) lpszRegister, arg6);
|
|
1382 else
|
|
1383 return ImmEnumRegisterWordA (arg1, (REGISTERWORDENUMPROCA) arg2, (LPCSTR) lpszReading, arg4, (LPCSTR) lpszRegister, arg6);
|
|
1384 }
|
|
1385
|
|
1386 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1387
|
|
1388 #if defined (HAVE_MS_WINDOWS)
|
|
1389
|
|
1390 /* Error if ImmGetImeMenuItems used: split-sized IMEMENUITEMINFO */
|
|
1391
|
|
1392 #endif /* defined (HAVE_MS_WINDOWS) */
|
|
1393
|
|
1394
|
|
1395 /*----------------------------------------------------------------------*/
|
|
1396 /* Processing file DDEML.H */
|
|
1397 /*----------------------------------------------------------------------*/
|
|
1398
|
|
1399 UINT
|
|
1400 qxeDdeInitialize (LPDWORD pidInst, PFNCALLBACK pfnCallback, DWORD afCmd, DWORD ulRes)
|
|
1401 {
|
|
1402 if (XEUNICODE_P)
|
|
1403 return DdeInitializeW (pidInst, pfnCallback, afCmd, ulRes);
|
|
1404 else
|
|
1405 return DdeInitializeA (pidInst, pfnCallback, afCmd, ulRes);
|
|
1406 }
|
|
1407
|
|
1408 HSZ
|
|
1409 qxeDdeCreateStringHandle (DWORD idInst, const Extbyte * psz, int iCodePage)
|
|
1410 {
|
|
1411 if (XEUNICODE_P)
|
|
1412 return DdeCreateStringHandleW (idInst, (LPCWSTR) psz, iCodePage);
|
|
1413 else
|
|
1414 return DdeCreateStringHandleA (idInst, (LPCSTR) psz, iCodePage);
|
|
1415 }
|
|
1416
|
|
1417 DWORD
|
|
1418 qxeDdeQueryString (DWORD idInst, HSZ hsz, Extbyte * psz, DWORD cchMax, int iCodePage)
|
|
1419 {
|
|
1420 if (XEUNICODE_P)
|
|
1421 return DdeQueryStringW (idInst, hsz, (LPWSTR) psz, cchMax, iCodePage);
|
|
1422 else
|
|
1423 return DdeQueryStringA (idInst, hsz, (LPSTR) psz, cchMax, iCodePage);
|
|
1424 }
|
|
1425
|
|
1426
|
|
1427 /*----------------------------------------------------------------------*/
|
|
1428 /* Processing file WINUSER.H */
|
|
1429 /*----------------------------------------------------------------------*/
|
|
1430
|
|
1431 int
|
|
1432 qxewvsprintf (Extbyte * arg1, const Extbyte * arg2, va_list arglist)
|
|
1433 {
|
|
1434 if (XEUNICODE_P)
|
|
1435 return wvsprintfW ((LPWSTR) arg1, (LPCWSTR) arg2, arglist);
|
|
1436 else
|
|
1437 return wvsprintfA ((LPSTR) arg1, (LPCSTR) arg2, arglist);
|
|
1438 }
|
|
1439
|
|
1440 HKL
|
|
1441 qxeLoadKeyboardLayout (const Extbyte * pwszKLID, UINT Flags)
|
|
1442 {
|
|
1443 if (XEUNICODE_P)
|
|
1444 return LoadKeyboardLayoutW ((LPCWSTR) pwszKLID, Flags);
|
|
1445 else
|
|
1446 return LoadKeyboardLayoutA ((LPCSTR) pwszKLID, Flags);
|
|
1447 }
|
|
1448
|
|
1449 BOOL
|
|
1450 qxeGetKeyboardLayoutName (Extbyte * pwszKLID)
|
|
1451 {
|
|
1452 if (XEUNICODE_P)
|
|
1453 return GetKeyboardLayoutNameW ((LPWSTR) pwszKLID);
|
|
1454 else
|
|
1455 return GetKeyboardLayoutNameA ((LPSTR) pwszKLID);
|
|
1456 }
|
|
1457
|
|
1458 /* Error if CreateDesktop used: split-sized LPDEVMODE */
|
|
1459
|
|
1460 HDESK
|
|
1461 qxeOpenDesktop (Extbyte * lpszDesktop, DWORD dwFlags, BOOL fInherit, ACCESS_MASK dwDesiredAccess)
|
|
1462 {
|
|
1463 if (XEUNICODE_P)
|
|
1464 return OpenDesktopW ((LPWSTR) lpszDesktop, dwFlags, fInherit, dwDesiredAccess);
|
|
1465 else
|
|
1466 return OpenDesktopA ((LPSTR) lpszDesktop, dwFlags, fInherit, dwDesiredAccess);
|
|
1467 }
|
|
1468
|
|
1469 /* NOTE: // callback fun differs only in string pointer type */
|
|
1470 BOOL
|
|
1471 qxeEnumDesktops (HWINSTA hwinsta, DESKTOPENUMPROCW lpEnumFunc, LPARAM lParam)
|
|
1472 {
|
|
1473 if (XEUNICODE_P)
|
|
1474 return EnumDesktopsW (hwinsta, lpEnumFunc, lParam);
|
|
1475 else
|
|
1476 return EnumDesktopsA (hwinsta, (DESKTOPENUMPROCA) lpEnumFunc, lParam);
|
|
1477 }
|
|
1478
|
|
1479 HWINSTA
|
|
1480 qxeCreateWindowStation (Extbyte * lpwinsta, DWORD dwReserved, ACCESS_MASK dwDesiredAccess, LPSECURITY_ATTRIBUTES lpsa)
|
|
1481 {
|
|
1482 if (XEUNICODE_P)
|
|
1483 return CreateWindowStationW ((LPWSTR) lpwinsta, dwReserved, dwDesiredAccess, lpsa);
|
|
1484 else
|
|
1485 return CreateWindowStationA ((LPSTR) lpwinsta, dwReserved, dwDesiredAccess, lpsa);
|
|
1486 }
|
|
1487
|
|
1488 HWINSTA
|
|
1489 qxeOpenWindowStation (Extbyte * lpszWinSta, BOOL fInherit, ACCESS_MASK dwDesiredAccess)
|
|
1490 {
|
|
1491 if (XEUNICODE_P)
|
|
1492 return OpenWindowStationW ((LPWSTR) lpszWinSta, fInherit, dwDesiredAccess);
|
|
1493 else
|
|
1494 return OpenWindowStationA ((LPSTR) lpszWinSta, fInherit, dwDesiredAccess);
|
|
1495 }
|
|
1496
|
|
1497 /* NOTE: // callback fun differs only in string pointer type */
|
|
1498 BOOL
|
|
1499 qxeEnumWindowStations (WINSTAENUMPROCW lpEnumFunc, LPARAM lParam)
|
|
1500 {
|
|
1501 if (XEUNICODE_P)
|
|
1502 return EnumWindowStationsW (lpEnumFunc, lParam);
|
|
1503 else
|
|
1504 return EnumWindowStationsA ((WINSTAENUMPROCA) lpEnumFunc, lParam);
|
|
1505 }
|
|
1506
|
|
1507 BOOL
|
|
1508 qxeGetUserObjectInformation (HANDLE hObj, int nIndex, PVOID pvInfo, DWORD nLength, LPDWORD lpnLengthNeeded)
|
|
1509 {
|
|
1510 if (XEUNICODE_P)
|
|
1511 return GetUserObjectInformationW (hObj, nIndex, pvInfo, nLength, lpnLengthNeeded);
|
|
1512 else
|
|
1513 return GetUserObjectInformationA (hObj, nIndex, pvInfo, nLength, lpnLengthNeeded);
|
|
1514 }
|
|
1515
|
|
1516 BOOL
|
|
1517 qxeSetUserObjectInformation (HANDLE hObj, int nIndex, PVOID pvInfo, DWORD nLength)
|
|
1518 {
|
|
1519 if (XEUNICODE_P)
|
|
1520 return SetUserObjectInformationW (hObj, nIndex, pvInfo, nLength);
|
|
1521 else
|
|
1522 return SetUserObjectInformationA (hObj, nIndex, pvInfo, nLength);
|
|
1523 }
|
|
1524
|
|
1525 UINT
|
|
1526 qxeRegisterWindowMessage (const Extbyte * lpString)
|
|
1527 {
|
|
1528 if (XEUNICODE_P)
|
|
1529 return RegisterWindowMessageW ((LPCWSTR) lpString);
|
|
1530 else
|
|
1531 return RegisterWindowMessageA ((LPCSTR) lpString);
|
|
1532 }
|
|
1533
|
|
1534 BOOL
|
|
1535 qxeGetMessage (LPMSG lpMsg, HWND hWnd, UINT wMsgFilterMin, UINT wMsgFilterMax)
|
|
1536 {
|
|
1537 if (XEUNICODE_P)
|
|
1538 return GetMessageW (lpMsg, hWnd, wMsgFilterMin, wMsgFilterMax);
|
|
1539 else
|
|
1540 return GetMessageA (lpMsg, hWnd, wMsgFilterMin, wMsgFilterMax);
|
|
1541 }
|
|
1542
|
|
1543 LONG
|
|
1544 qxeDispatchMessage (CONST MSG * lpMsg)
|
|
1545 {
|
|
1546 if (XEUNICODE_P)
|
|
1547 return DispatchMessageW (lpMsg);
|
|
1548 else
|
|
1549 return DispatchMessageA (lpMsg);
|
|
1550 }
|
|
1551
|
|
1552 BOOL
|
|
1553 qxePeekMessage (LPMSG lpMsg, HWND hWnd, UINT wMsgFilterMin, UINT wMsgFilterMax, UINT wRemoveMsg)
|
|
1554 {
|
|
1555 if (XEUNICODE_P)
|
|
1556 return PeekMessageW (lpMsg, hWnd, wMsgFilterMin, wMsgFilterMax, wRemoveMsg);
|
|
1557 else
|
|
1558 return PeekMessageA (lpMsg, hWnd, wMsgFilterMin, wMsgFilterMax, wRemoveMsg);
|
|
1559 }
|
|
1560
|
|
1561 /* Skipping SendMessage because split messages and structures */
|
|
1562
|
|
1563 LRESULT
|
|
1564 qxeSendMessageTimeout (HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam, UINT fuFlags, UINT uTimeout, LPDWORD lpdwResult)
|
|
1565 {
|
|
1566 if (XEUNICODE_P)
|
|
1567 return SendMessageTimeoutW (hWnd, Msg, wParam, lParam, fuFlags, uTimeout, lpdwResult);
|
|
1568 else
|
|
1569 return SendMessageTimeoutA (hWnd, Msg, wParam, lParam, fuFlags, uTimeout, lpdwResult);
|
|
1570 }
|
|
1571
|
|
1572 BOOL
|
|
1573 qxeSendNotifyMessage (HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam)
|
|
1574 {
|
|
1575 if (XEUNICODE_P)
|
|
1576 return SendNotifyMessageW (hWnd, Msg, wParam, lParam);
|
|
1577 else
|
|
1578 return SendNotifyMessageA (hWnd, Msg, wParam, lParam);
|
|
1579 }
|
|
1580
|
|
1581 BOOL
|
|
1582 qxeSendMessageCallback (HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam, SENDASYNCPROC lpResultCallBack, DWORD dwData)
|
|
1583 {
|
|
1584 if (XEUNICODE_P)
|
|
1585 return SendMessageCallbackW (hWnd, Msg, wParam, lParam, lpResultCallBack, dwData);
|
|
1586 else
|
|
1587 return SendMessageCallbackA (hWnd, Msg, wParam, lParam, lpResultCallBack, dwData);
|
|
1588 }
|
|
1589
|
|
1590 /* Error if BroadcastSystemMessage used: win95 version not split; NT 4.0+ only */
|
|
1591
|
|
1592 /* Error if RegisterDeviceNotification used: NT 5.0+ only */
|
|
1593
|
|
1594 BOOL
|
|
1595 qxePostMessage (HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam)
|
|
1596 {
|
|
1597 if (XEUNICODE_P)
|
|
1598 return PostMessageW (hWnd, Msg, wParam, lParam);
|
|
1599 else
|
|
1600 return PostMessageA (hWnd, Msg, wParam, lParam);
|
|
1601 }
|
|
1602
|
|
1603 BOOL
|
|
1604 qxePostThreadMessage (DWORD idThread, UINT Msg, WPARAM wParam, LPARAM lParam)
|
|
1605 {
|
|
1606 if (XEUNICODE_P)
|
|
1607 return PostThreadMessageW (idThread, Msg, wParam, lParam);
|
|
1608 else
|
|
1609 return PostThreadMessageA (idThread, Msg, wParam, lParam);
|
|
1610 }
|
|
1611
|
|
1612 /* Skipping DefWindowProc because return value is conditionalized on _MAC, messes up parser */
|
|
1613
|
|
1614 /* Error if CallWindowProc used: two versions, STRICT and non-STRICT */
|
|
1615
|
|
1616 /* Error if CallWindowProc used: two versions, STRICT and non-STRICT */
|
|
1617
|
|
1618 /* Skipping RegisterClass because need to intercept so we can provide our own window procedure and handle split notify messages; split-simple WNDCLASS */
|
|
1619
|
|
1620 /* Skipping UnregisterClass because need to intercept for reasons related to RegisterClass */
|
|
1621
|
|
1622 BOOL
|
|
1623 qxeGetClassInfo (HINSTANCE hInstance, const Extbyte * lpClassName, LPWNDCLASSW lpWndClass)
|
|
1624 {
|
|
1625 if (XEUNICODE_P)
|
|
1626 return GetClassInfoW (hInstance, (LPCWSTR) lpClassName, lpWndClass);
|
|
1627 else
|
|
1628 return GetClassInfoA (hInstance, (LPCSTR) lpClassName, (LPWNDCLASSA) lpWndClass);
|
|
1629 }
|
|
1630
|
|
1631 /* Skipping RegisterClassEx because need to intercept so we can provide our own window procedure and handle split notify messages; split-simple WNDCLASSEX; NT 4.0+ only */
|
|
1632
|
|
1633 /* NOTE: NT 4.0+ only */
|
|
1634 BOOL
|
|
1635 qxeGetClassInfoEx (HINSTANCE arg1, const Extbyte * arg2, LPWNDCLASSEXW arg3)
|
|
1636 {
|
|
1637 if (XEUNICODE_P)
|
|
1638 return GetClassInfoExW (arg1, (LPCWSTR) arg2, arg3);
|
|
1639 else
|
|
1640 return GetClassInfoExA (arg1, (LPCSTR) arg2, (LPWNDCLASSEXA) arg3);
|
|
1641 }
|
|
1642
|
|
1643 HWND
|
|
1644 qxeCreateWindowEx (DWORD dwExStyle, const Extbyte * lpClassName, const Extbyte * lpWindowName, DWORD dwStyle, int X, int Y, int nWidth, int nHeight, HWND hWndParent, HMENU hMenu, HINSTANCE hInstance, LPVOID lpParam)
|
|
1645 {
|
|
1646 if (XEUNICODE_P)
|
|
1647 return CreateWindowExW (dwExStyle, (LPCWSTR) lpClassName, (LPCWSTR) lpWindowName, dwStyle, X, Y, nWidth, nHeight, hWndParent, hMenu, hInstance, lpParam);
|
|
1648 else
|
|
1649 return CreateWindowExA (dwExStyle, (LPCSTR) lpClassName, (LPCSTR) lpWindowName, dwStyle, X, Y, nWidth, nHeight, hWndParent, hMenu, hInstance, lpParam);
|
|
1650 }
|
|
1651
|
|
1652 HWND
|
|
1653 qxeCreateDialogParam (HINSTANCE hInstance, const Extbyte * lpTemplateName, HWND hWndParent, DLGPROC lpDialogFunc, LPARAM dwInitParam)
|
|
1654 {
|
|
1655 if (XEUNICODE_P)
|
|
1656 return CreateDialogParamW (hInstance, (LPCWSTR) lpTemplateName, hWndParent, lpDialogFunc, dwInitParam);
|
|
1657 else
|
|
1658 return CreateDialogParamA (hInstance, (LPCSTR) lpTemplateName, hWndParent, lpDialogFunc, dwInitParam);
|
|
1659 }
|
|
1660
|
|
1661 /* NOTE: error in Cygwin prototype (no split) but fixable with typedef */
|
|
1662 HWND
|
|
1663 qxeCreateDialogIndirectParam (HINSTANCE hInstance, LPCDLGTEMPLATEW lpTemplate, HWND hWndParent, DLGPROC lpDialogFunc, LPARAM dwInitParam)
|
|
1664 {
|
|
1665 if (XEUNICODE_P)
|
|
1666 return CreateDialogIndirectParamW (hInstance, lpTemplate, hWndParent, lpDialogFunc, dwInitParam);
|
|
1667 else
|
|
1668 return CreateDialogIndirectParamA (hInstance, (LPCDLGTEMPLATEA) lpTemplate, hWndParent, lpDialogFunc, dwInitParam);
|
|
1669 }
|
|
1670
|
|
1671 int
|
|
1672 qxeDialogBoxParam (HINSTANCE hInstance, const Extbyte * lpTemplateName, HWND hWndParent, DLGPROC lpDialogFunc, LPARAM dwInitParam)
|
|
1673 {
|
|
1674 if (XEUNICODE_P)
|
|
1675 return DialogBoxParamW (hInstance, (LPCWSTR) lpTemplateName, hWndParent, lpDialogFunc, dwInitParam);
|
|
1676 else
|
|
1677 return DialogBoxParamA (hInstance, (LPCSTR) lpTemplateName, hWndParent, lpDialogFunc, dwInitParam);
|
|
1678 }
|
|
1679
|
|
1680 /* NOTE: error in Cygwin prototype (no split) but fixable with typedef */
|
|
1681 int
|
|
1682 qxeDialogBoxIndirectParam (HINSTANCE hInstance, LPCDLGTEMPLATEW hDialogTemplate, HWND hWndParent, DLGPROC lpDialogFunc, LPARAM dwInitParam)
|
|
1683 {
|
|
1684 if (XEUNICODE_P)
|
|
1685 return DialogBoxIndirectParamW (hInstance, hDialogTemplate, hWndParent, lpDialogFunc, dwInitParam);
|
|
1686 else
|
|
1687 return DialogBoxIndirectParamA (hInstance, (LPCDLGTEMPLATEA) hDialogTemplate, hWndParent, lpDialogFunc, dwInitParam);
|
|
1688 }
|
|
1689
|
|
1690 BOOL
|
|
1691 qxeSetDlgItemText (HWND hDlg, int nIDDlgItem, const Extbyte * lpString)
|
|
1692 {
|
|
1693 if (XEUNICODE_P)
|
|
1694 return SetDlgItemTextW (hDlg, nIDDlgItem, (LPCWSTR) lpString);
|
|
1695 else
|
|
1696 return SetDlgItemTextA (hDlg, nIDDlgItem, (LPCSTR) lpString);
|
|
1697 }
|
|
1698
|
|
1699 UINT
|
|
1700 qxeGetDlgItemText (HWND hDlg, int nIDDlgItem, Extbyte * lpString, int nMaxCount)
|
|
1701 {
|
|
1702 if (XEUNICODE_P)
|
|
1703 return GetDlgItemTextW (hDlg, nIDDlgItem, (LPWSTR) lpString, nMaxCount);
|
|
1704 else
|
|
1705 return GetDlgItemTextA (hDlg, nIDDlgItem, (LPSTR) lpString, nMaxCount);
|
|
1706 }
|
|
1707
|
|
1708 LONG
|
|
1709 qxeSendDlgItemMessage (HWND hDlg, int nIDDlgItem, UINT Msg, WPARAM wParam, LPARAM lParam)
|
|
1710 {
|
|
1711 if (XEUNICODE_P)
|
|
1712 return SendDlgItemMessageW (hDlg, nIDDlgItem, Msg, wParam, lParam);
|
|
1713 else
|
|
1714 return SendDlgItemMessageA (hDlg, nIDDlgItem, Msg, wParam, lParam);
|
|
1715 }
|
|
1716
|
|
1717 /* Error if DefDlgProc used: return value is conditionalized on _MAC, messes up parser */
|
|
1718
|
|
1719 #if !defined (CYGWIN_HEADERS)
|
|
1720
|
|
1721 BOOL
|
|
1722 qxeCallMsgFilter (LPMSG lpMsg, int nCode)
|
|
1723 {
|
|
1724 if (XEUNICODE_P)
|
|
1725 return CallMsgFilterW (lpMsg, nCode);
|
|
1726 else
|
|
1727 return CallMsgFilterA (lpMsg, nCode);
|
|
1728 }
|
|
1729
|
|
1730 #endif /* !defined (CYGWIN_HEADERS) */
|
|
1731
|
|
1732 UINT
|
|
1733 qxeRegisterClipboardFormat (const Extbyte * lpszFormat)
|
|
1734 {
|
|
1735 if (XEUNICODE_P)
|
|
1736 return RegisterClipboardFormatW ((LPCWSTR) lpszFormat);
|
|
1737 else
|
|
1738 return RegisterClipboardFormatA ((LPCSTR) lpszFormat);
|
|
1739 }
|
|
1740
|
|
1741 int
|
|
1742 qxeGetClipboardFormatName (UINT format, Extbyte * lpszFormatName, int cchMaxCount)
|
|
1743 {
|
|
1744 if (XEUNICODE_P)
|
|
1745 return GetClipboardFormatNameW (format, (LPWSTR) lpszFormatName, cchMaxCount);
|
|
1746 else
|
|
1747 return GetClipboardFormatNameA (format, (LPSTR) lpszFormatName, cchMaxCount);
|
|
1748 }
|
|
1749
|
|
1750 BOOL
|
|
1751 qxeCharToOem (const Extbyte * lpszSrc, LPSTR lpszDst)
|
|
1752 {
|
|
1753 if (XEUNICODE_P)
|
|
1754 return CharToOemW ((LPCWSTR) lpszSrc, lpszDst);
|
|
1755 else
|
|
1756 return CharToOemA ((LPCSTR) lpszSrc, lpszDst);
|
|
1757 }
|
|
1758
|
|
1759 BOOL
|
|
1760 qxeOemToChar (LPCSTR lpszSrc, Extbyte * lpszDst)
|
|
1761 {
|
|
1762 if (XEUNICODE_P)
|
|
1763 return OemToCharW (lpszSrc, (LPWSTR) lpszDst);
|
|
1764 else
|
|
1765 return OemToCharA (lpszSrc, (LPSTR) lpszDst);
|
|
1766 }
|
|
1767
|
|
1768 BOOL
|
|
1769 qxeCharToOemBuff (const Extbyte * lpszSrc, LPSTR lpszDst, DWORD cchDstLength)
|
|
1770 {
|
|
1771 if (XEUNICODE_P)
|
|
1772 return CharToOemBuffW ((LPCWSTR) lpszSrc, lpszDst, cchDstLength);
|
|
1773 else
|
|
1774 return CharToOemBuffA ((LPCSTR) lpszSrc, lpszDst, cchDstLength);
|
|
1775 }
|
|
1776
|
|
1777 BOOL
|
|
1778 qxeOemToCharBuff (LPCSTR lpszSrc, Extbyte * lpszDst, DWORD cchDstLength)
|
|
1779 {
|
|
1780 if (XEUNICODE_P)
|
|
1781 return OemToCharBuffW (lpszSrc, (LPWSTR) lpszDst, cchDstLength);
|
|
1782 else
|
|
1783 return OemToCharBuffA (lpszSrc, (LPSTR) lpszDst, cchDstLength);
|
|
1784 }
|
|
1785
|
|
1786 Extbyte *
|
|
1787 qxeCharUpper (Extbyte * lpsz)
|
|
1788 {
|
|
1789 if (XEUNICODE_P)
|
|
1790 return (Extbyte *) CharUpperW ((LPWSTR) lpsz);
|
|
1791 else
|
|
1792 return (Extbyte *) CharUpperA ((LPSTR) lpsz);
|
|
1793 }
|
|
1794
|
|
1795 DWORD
|
|
1796 qxeCharUpperBuff (Extbyte * lpsz, DWORD cchLength)
|
|
1797 {
|
|
1798 if (XEUNICODE_P)
|
|
1799 return CharUpperBuffW ((LPWSTR) lpsz, cchLength);
|
|
1800 else
|
|
1801 return CharUpperBuffA ((LPSTR) lpsz, cchLength);
|
|
1802 }
|
|
1803
|
|
1804 Extbyte *
|
|
1805 qxeCharLower (Extbyte * lpsz)
|
|
1806 {
|
|
1807 if (XEUNICODE_P)
|
|
1808 return (Extbyte *) CharLowerW ((LPWSTR) lpsz);
|
|
1809 else
|
|
1810 return (Extbyte *) CharLowerA ((LPSTR) lpsz);
|
|
1811 }
|
|
1812
|
|
1813 DWORD
|
|
1814 qxeCharLowerBuff (Extbyte * lpsz, DWORD cchLength)
|
|
1815 {
|
|
1816 if (XEUNICODE_P)
|
|
1817 return CharLowerBuffW ((LPWSTR) lpsz, cchLength);
|
|
1818 else
|
|
1819 return CharLowerBuffA ((LPSTR) lpsz, cchLength);
|
|
1820 }
|
|
1821
|
|
1822 Extbyte *
|
|
1823 qxeCharNext (const Extbyte * lpsz)
|
|
1824 {
|
|
1825 if (XEUNICODE_P)
|
|
1826 return (Extbyte *) CharNextW ((LPCWSTR) lpsz);
|
|
1827 else
|
|
1828 return (Extbyte *) CharNextA ((LPCSTR) lpsz);
|
|
1829 }
|
|
1830
|
|
1831 Extbyte *
|
|
1832 qxeCharPrev (const Extbyte * lpszStart, const Extbyte * lpszCurrent)
|
|
1833 {
|
|
1834 if (XEUNICODE_P)
|
|
1835 return (Extbyte *) CharPrevW ((LPCWSTR) lpszStart, (LPCWSTR) lpszCurrent);
|
|
1836 else
|
|
1837 return (Extbyte *) CharPrevA ((LPCSTR) lpszStart, (LPCSTR) lpszCurrent);
|
|
1838 }
|
|
1839
|
|
1840 /* Error if IsCharAlpha used: split CHAR */
|
|
1841
|
|
1842 /* Error if IsCharAlphaNumeric used: split CHAR */
|
|
1843
|
|
1844 /* Error if IsCharUpper used: split CHAR */
|
|
1845
|
|
1846 /* Error if IsCharLower used: split CHAR */
|
|
1847
|
|
1848 int
|
|
1849 qxeGetKeyNameText (LONG lParam, Extbyte * lpString, int nSize)
|
|
1850 {
|
|
1851 if (XEUNICODE_P)
|
|
1852 return GetKeyNameTextW (lParam, (LPWSTR) lpString, nSize);
|
|
1853 else
|
|
1854 return GetKeyNameTextA (lParam, (LPSTR) lpString, nSize);
|
|
1855 }
|
|
1856
|
|
1857 /* Skipping VkKeyScan because split CHAR */
|
|
1858
|
|
1859 /* Error if VkKeyScanEx used: split CHAR; NT 4.0+ only */
|
|
1860
|
|
1861 UINT
|
|
1862 qxeMapVirtualKey (UINT uCode, UINT uMapType)
|
|
1863 {
|
|
1864 if (XEUNICODE_P)
|
|
1865 return MapVirtualKeyW (uCode, uMapType);
|
|
1866 else
|
|
1867 return MapVirtualKeyA (uCode, uMapType);
|
|
1868 }
|
|
1869
|
|
1870 /* NOTE: NT 4.0+ only */
|
|
1871 UINT
|
|
1872 qxeMapVirtualKeyEx (UINT uCode, UINT uMapType, HKL dwhkl)
|
|
1873 {
|
|
1874 if (XEUNICODE_P)
|
|
1875 return MapVirtualKeyExW (uCode, uMapType, dwhkl);
|
|
1876 else
|
|
1877 return MapVirtualKeyExA (uCode, uMapType, dwhkl);
|
|
1878 }
|
|
1879
|
|
1880 HACCEL
|
|
1881 qxeLoadAccelerators (HINSTANCE hInstance, const Extbyte * lpTableName)
|
|
1882 {
|
|
1883 if (XEUNICODE_P)
|
|
1884 return LoadAcceleratorsW (hInstance, (LPCWSTR) lpTableName);
|
|
1885 else
|
|
1886 return LoadAcceleratorsA (hInstance, (LPCSTR) lpTableName);
|
|
1887 }
|
|
1888
|
|
1889 HACCEL
|
|
1890 qxeCreateAcceleratorTable (LPACCEL arg1, int arg2)
|
|
1891 {
|
|
1892 if (XEUNICODE_P)
|
|
1893 return CreateAcceleratorTableW (arg1, arg2);
|
|
1894 else
|
|
1895 return CreateAcceleratorTableA (arg1, arg2);
|
|
1896 }
|
|
1897
|
|
1898 int
|
|
1899 qxeCopyAcceleratorTable (HACCEL hAccelSrc, LPACCEL lpAccelDst, int cAccelEntries)
|
|
1900 {
|
|
1901 if (XEUNICODE_P)
|
|
1902 return CopyAcceleratorTableW (hAccelSrc, lpAccelDst, cAccelEntries);
|
|
1903 else
|
|
1904 return CopyAcceleratorTableA (hAccelSrc, lpAccelDst, cAccelEntries);
|
|
1905 }
|
|
1906
|
|
1907 int
|
|
1908 qxeTranslateAccelerator (HWND hWnd, HACCEL hAccTable, LPMSG lpMsg)
|
|
1909 {
|
|
1910 if (XEUNICODE_P)
|
|
1911 return TranslateAcceleratorW (hWnd, hAccTable, lpMsg);
|
|
1912 else
|
|
1913 return TranslateAcceleratorA (hWnd, hAccTable, lpMsg);
|
|
1914 }
|
|
1915
|
|
1916 HMENU
|
|
1917 qxeLoadMenu (HINSTANCE hInstance, const Extbyte * lpMenuName)
|
|
1918 {
|
|
1919 if (XEUNICODE_P)
|
|
1920 return LoadMenuW (hInstance, (LPCWSTR) lpMenuName);
|
|
1921 else
|
|
1922 return LoadMenuA (hInstance, (LPCSTR) lpMenuName);
|
|
1923 }
|
|
1924
|
|
1925 HMENU
|
|
1926 qxeLoadMenuIndirect (CONST MENUTEMPLATEW * lpMenuTemplate)
|
|
1927 {
|
|
1928 if (XEUNICODE_P)
|
|
1929 return LoadMenuIndirectW (lpMenuTemplate);
|
|
1930 else
|
|
1931 return LoadMenuIndirectA ((CONST MENUTEMPLATEA *) lpMenuTemplate);
|
|
1932 }
|
|
1933
|
|
1934 BOOL
|
|
1935 qxeChangeMenu (HMENU hMenu, UINT cmd, const Extbyte * lpszNewItem, UINT cmdInsert, UINT flags)
|
|
1936 {
|
|
1937 if (XEUNICODE_P)
|
|
1938 return ChangeMenuW (hMenu, cmd, (LPCWSTR) lpszNewItem, cmdInsert, flags);
|
|
1939 else
|
|
1940 return ChangeMenuA (hMenu, cmd, (LPCSTR) lpszNewItem, cmdInsert, flags);
|
|
1941 }
|
|
1942
|
|
1943 int
|
|
1944 qxeGetMenuString (HMENU hMenu, UINT uIDItem, Extbyte * lpString, int nMaxCount, UINT uFlag)
|
|
1945 {
|
|
1946 if (XEUNICODE_P)
|
|
1947 return GetMenuStringW (hMenu, uIDItem, (LPWSTR) lpString, nMaxCount, uFlag);
|
|
1948 else
|
|
1949 return GetMenuStringA (hMenu, uIDItem, (LPSTR) lpString, nMaxCount, uFlag);
|
|
1950 }
|
|
1951
|
|
1952 BOOL
|
|
1953 qxeInsertMenu (HMENU hMenu, UINT uPosition, UINT uFlags, UINT uIDNewItem, const Extbyte * lpNewItem)
|
|
1954 {
|
|
1955 if (XEUNICODE_P)
|
|
1956 return InsertMenuW (hMenu, uPosition, uFlags, uIDNewItem, (LPCWSTR) lpNewItem);
|
|
1957 else
|
|
1958 return InsertMenuA (hMenu, uPosition, uFlags, uIDNewItem, (LPCSTR) lpNewItem);
|
|
1959 }
|
|
1960
|
|
1961 BOOL
|
|
1962 qxeAppendMenu (HMENU hMenu, UINT uFlags, UINT uIDNewItem, const Extbyte * lpNewItem)
|
|
1963 {
|
|
1964 if (XEUNICODE_P)
|
|
1965 return AppendMenuW (hMenu, uFlags, uIDNewItem, (LPCWSTR) lpNewItem);
|
|
1966 else
|
|
1967 return AppendMenuA (hMenu, uFlags, uIDNewItem, (LPCSTR) lpNewItem);
|
|
1968 }
|
|
1969
|
|
1970 BOOL
|
|
1971 qxeModifyMenu (HMENU hMnu, UINT uPosition, UINT uFlags, UINT uIDNewItem, const Extbyte * lpNewItem)
|
|
1972 {
|
|
1973 if (XEUNICODE_P)
|
|
1974 return ModifyMenuW (hMnu, uPosition, uFlags, uIDNewItem, (LPCWSTR) lpNewItem);
|
|
1975 else
|
|
1976 return ModifyMenuA (hMnu, uPosition, uFlags, uIDNewItem, (LPCSTR) lpNewItem);
|
|
1977 }
|
|
1978
|
|
1979 /* NOTE: NT 4.0+ only */
|
|
1980 BOOL
|
|
1981 qxeInsertMenuItem (HMENU arg1, UINT arg2, BOOL arg3, LPCMENUITEMINFOW arg4)
|
|
1982 {
|
|
1983 if (XEUNICODE_P)
|
|
1984 return InsertMenuItemW (arg1, arg2, arg3, arg4);
|
|
1985 else
|
|
1986 return InsertMenuItemA (arg1, arg2, arg3, (LPCMENUITEMINFOA) arg4);
|
|
1987 }
|
|
1988
|
|
1989 /* NOTE: NT 4.0+ only */
|
|
1990 BOOL
|
|
1991 qxeGetMenuItemInfo (HMENU arg1, UINT arg2, BOOL arg3, LPMENUITEMINFOW arg4)
|
|
1992 {
|
|
1993 if (XEUNICODE_P)
|
|
1994 return GetMenuItemInfoW (arg1, arg2, arg3, arg4);
|
|
1995 else
|
|
1996 return GetMenuItemInfoA (arg1, arg2, arg3, (LPMENUITEMINFOA) arg4);
|
|
1997 }
|
|
1998
|
|
1999 /* NOTE: NT 4.0+ only */
|
|
2000 BOOL
|
|
2001 qxeSetMenuItemInfo (HMENU arg1, UINT arg2, BOOL arg3, LPCMENUITEMINFOW arg4)
|
|
2002 {
|
|
2003 if (XEUNICODE_P)
|
|
2004 return SetMenuItemInfoW (arg1, arg2, arg3, arg4);
|
|
2005 else
|
|
2006 return SetMenuItemInfoA (arg1, arg2, arg3, (LPCMENUITEMINFOA) arg4);
|
|
2007 }
|
|
2008
|
|
2009 int
|
|
2010 qxeDrawText (HDC hDC, const Extbyte * lpString, int nCount, LPRECT lpRect, UINT uFormat)
|
|
2011 {
|
|
2012 if (XEUNICODE_P)
|
|
2013 return DrawTextW (hDC, (LPCWSTR) lpString, nCount, lpRect, uFormat);
|
|
2014 else
|
|
2015 return DrawTextA (hDC, (LPCSTR) lpString, nCount, lpRect, uFormat);
|
|
2016 }
|
|
2017
|
|
2018 /* NOTE: NT 4.0+ only */
|
|
2019 int
|
|
2020 qxeDrawTextEx (HDC arg1, Extbyte * arg2, int arg3, LPRECT arg4, UINT arg5, LPDRAWTEXTPARAMS arg6)
|
|
2021 {
|
|
2022 if (XEUNICODE_P)
|
|
2023 return DrawTextExW (arg1, (LPWSTR) arg2, arg3, arg4, arg5, arg6);
|
|
2024 else
|
|
2025 return DrawTextExA (arg1, (LPSTR) arg2, arg3, arg4, arg5, arg6);
|
|
2026 }
|
|
2027
|
|
2028 BOOL
|
|
2029 qxeGrayString (HDC hDC, HBRUSH hBrush, GRAYSTRINGPROC lpOutputFunc, LPARAM lpData, int nCount, int X, int Y, int nWidth, int nHeight)
|
|
2030 {
|
|
2031 if (XEUNICODE_P)
|
|
2032 return GrayStringW (hDC, hBrush, lpOutputFunc, lpData, nCount, X, Y, nWidth, nHeight);
|
|
2033 else
|
|
2034 return GrayStringA (hDC, hBrush, lpOutputFunc, lpData, nCount, X, Y, nWidth, nHeight);
|
|
2035 }
|
|
2036
|
|
2037 /* NOTE: NT 4.0+ only */
|
|
2038 BOOL
|
|
2039 qxeDrawState (HDC arg1, HBRUSH arg2, DRAWSTATEPROC arg3, LPARAM arg4, WPARAM arg5, int arg6, int arg7, int arg8, int arg9, UINT arg10)
|
|
2040 {
|
|
2041 if (XEUNICODE_P)
|
|
2042 return DrawStateW (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10);
|
|
2043 else
|
|
2044 return DrawStateA (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10);
|
|
2045 }
|
|
2046
|
|
2047 LONG
|
|
2048 qxeTabbedTextOut (HDC hDC, int X, int Y, const Extbyte * lpString, int nCount, int nTabPositions, LPINT lpnTabStopPositions, int nTabOrigin)
|
|
2049 {
|
|
2050 if (XEUNICODE_P)
|
|
2051 return TabbedTextOutW (hDC, X, Y, (LPCWSTR) lpString, nCount, nTabPositions, lpnTabStopPositions, nTabOrigin);
|
|
2052 else
|
|
2053 return TabbedTextOutA (hDC, X, Y, (LPCSTR) lpString, nCount, nTabPositions, lpnTabStopPositions, nTabOrigin);
|
|
2054 }
|
|
2055
|
|
2056 DWORD
|
|
2057 qxeGetTabbedTextExtent (HDC hDC, const Extbyte * lpString, int nCount, int nTabPositions, LPINT lpnTabStopPositions)
|
|
2058 {
|
|
2059 if (XEUNICODE_P)
|
|
2060 return GetTabbedTextExtentW (hDC, (LPCWSTR) lpString, nCount, nTabPositions, lpnTabStopPositions);
|
|
2061 else
|
|
2062 return GetTabbedTextExtentA (hDC, (LPCSTR) lpString, nCount, nTabPositions, lpnTabStopPositions);
|
|
2063 }
|
|
2064
|
|
2065 BOOL
|
|
2066 qxeSetProp (HWND hWnd, const Extbyte * lpString, HANDLE hData)
|
|
2067 {
|
|
2068 if (XEUNICODE_P)
|
|
2069 return SetPropW (hWnd, (LPCWSTR) lpString, hData);
|
|
2070 else
|
|
2071 return SetPropA (hWnd, (LPCSTR) lpString, hData);
|
|
2072 }
|
|
2073
|
|
2074 HANDLE
|
|
2075 qxeGetProp (HWND hWnd, const Extbyte * lpString)
|
|
2076 {
|
|
2077 if (XEUNICODE_P)
|
|
2078 return GetPropW (hWnd, (LPCWSTR) lpString);
|
|
2079 else
|
|
2080 return GetPropA (hWnd, (LPCSTR) lpString);
|
|
2081 }
|
|
2082
|
|
2083 HANDLE
|
|
2084 qxeRemoveProp (HWND hWnd, const Extbyte * lpString)
|
|
2085 {
|
|
2086 if (XEUNICODE_P)
|
|
2087 return RemovePropW (hWnd, (LPCWSTR) lpString);
|
|
2088 else
|
|
2089 return RemovePropA (hWnd, (LPCSTR) lpString);
|
|
2090 }
|
|
2091
|
|
2092 /* NOTE: // callback fun differs only in string pointer type */
|
|
2093 int
|
|
2094 qxeEnumPropsEx (HWND hWnd, PROPENUMPROCEXW lpEnumFunc, LPARAM lParam)
|
|
2095 {
|
|
2096 if (XEUNICODE_P)
|
|
2097 return EnumPropsExW (hWnd, lpEnumFunc, lParam);
|
|
2098 else
|
|
2099 return EnumPropsExA (hWnd, (PROPENUMPROCEXA) lpEnumFunc, lParam);
|
|
2100 }
|
|
2101
|
|
2102 /* NOTE: // callback fun differs only in string pointer type */
|
|
2103 int
|
|
2104 qxeEnumProps (HWND hWnd, PROPENUMPROCW lpEnumFunc)
|
|
2105 {
|
|
2106 if (XEUNICODE_P)
|
|
2107 return EnumPropsW (hWnd, lpEnumFunc);
|
|
2108 else
|
|
2109 return EnumPropsA (hWnd, (PROPENUMPROCA) lpEnumFunc);
|
|
2110 }
|
|
2111
|
|
2112 BOOL
|
|
2113 qxeSetWindowText (HWND hWnd, const Extbyte * lpString)
|
|
2114 {
|
|
2115 if (XEUNICODE_P)
|
|
2116 return SetWindowTextW (hWnd, (LPCWSTR) lpString);
|
|
2117 else
|
|
2118 return SetWindowTextA (hWnd, (LPCSTR) lpString);
|
|
2119 }
|
|
2120
|
|
2121 int
|
|
2122 qxeGetWindowText (HWND hWnd, Extbyte * lpString, int nMaxCount)
|
|
2123 {
|
|
2124 if (XEUNICODE_P)
|
|
2125 return GetWindowTextW (hWnd, (LPWSTR) lpString, nMaxCount);
|
|
2126 else
|
|
2127 return GetWindowTextA (hWnd, (LPSTR) lpString, nMaxCount);
|
|
2128 }
|
|
2129
|
|
2130 int
|
|
2131 qxeGetWindowTextLength (HWND hWnd)
|
|
2132 {
|
|
2133 if (XEUNICODE_P)
|
|
2134 return GetWindowTextLengthW (hWnd);
|
|
2135 else
|
|
2136 return GetWindowTextLengthA (hWnd);
|
|
2137 }
|
|
2138
|
|
2139 int
|
|
2140 qxeMessageBox (HWND hWnd, const Extbyte * lpText, const Extbyte * lpCaption, UINT uType)
|
|
2141 {
|
|
2142 if (XEUNICODE_P)
|
|
2143 return MessageBoxW (hWnd, (LPCWSTR) lpText, (LPCWSTR) lpCaption, uType);
|
|
2144 else
|
|
2145 return MessageBoxA (hWnd, (LPCSTR) lpText, (LPCSTR) lpCaption, uType);
|
|
2146 }
|
|
2147
|
|
2148 int
|
|
2149 qxeMessageBoxEx (HWND hWnd, const Extbyte * lpText, const Extbyte * lpCaption, UINT uType, WORD wLanguageId)
|
|
2150 {
|
|
2151 if (XEUNICODE_P)
|
|
2152 return MessageBoxExW (hWnd, (LPCWSTR) lpText, (LPCWSTR) lpCaption, uType, wLanguageId);
|
|
2153 else
|
|
2154 return MessageBoxExA (hWnd, (LPCSTR) lpText, (LPCSTR) lpCaption, uType, wLanguageId);
|
|
2155 }
|
|
2156
|
|
2157 /* NOTE: NT 4.0+ only */
|
|
2158 int
|
|
2159 qxeMessageBoxIndirect (LPMSGBOXPARAMSW arg1)
|
|
2160 {
|
|
2161 if (XEUNICODE_P)
|
|
2162 return MessageBoxIndirectW (arg1);
|
|
2163 else
|
|
2164 return MessageBoxIndirectA ((LPMSGBOXPARAMSA) arg1);
|
|
2165 }
|
|
2166
|
|
2167 LONG
|
|
2168 qxeGetWindowLong (HWND hWnd, int nIndex)
|
|
2169 {
|
|
2170 if (XEUNICODE_P)
|
|
2171 return GetWindowLongW (hWnd, nIndex);
|
|
2172 else
|
|
2173 return GetWindowLongA (hWnd, nIndex);
|
|
2174 }
|
|
2175
|
|
2176 LONG
|
|
2177 qxeSetWindowLong (HWND hWnd, int nIndex, LONG dwNewLong)
|
|
2178 {
|
|
2179 if (XEUNICODE_P)
|
|
2180 return SetWindowLongW (hWnd, nIndex, dwNewLong);
|
|
2181 else
|
|
2182 return SetWindowLongA (hWnd, nIndex, dwNewLong);
|
|
2183 }
|
|
2184
|
|
2185 DWORD
|
|
2186 qxeGetClassLong (HWND hWnd, int nIndex)
|
|
2187 {
|
|
2188 if (XEUNICODE_P)
|
|
2189 return GetClassLongW (hWnd, nIndex);
|
|
2190 else
|
|
2191 return GetClassLongA (hWnd, nIndex);
|
|
2192 }
|
|
2193
|
|
2194 DWORD
|
|
2195 qxeSetClassLong (HWND hWnd, int nIndex, LONG dwNewLong)
|
|
2196 {
|
|
2197 if (XEUNICODE_P)
|
|
2198 return SetClassLongW (hWnd, nIndex, dwNewLong);
|
|
2199 else
|
|
2200 return SetClassLongA (hWnd, nIndex, dwNewLong);
|
|
2201 }
|
|
2202
|
|
2203 HWND
|
|
2204 qxeFindWindow (const Extbyte * lpClassName, const Extbyte * lpWindowName)
|
|
2205 {
|
|
2206 if (XEUNICODE_P)
|
|
2207 return FindWindowW ((LPCWSTR) lpClassName, (LPCWSTR) lpWindowName);
|
|
2208 else
|
|
2209 return FindWindowA ((LPCSTR) lpClassName, (LPCSTR) lpWindowName);
|
|
2210 }
|
|
2211
|
|
2212 /* NOTE: NT 4.0+ only */
|
|
2213 HWND
|
|
2214 qxeFindWindowEx (HWND arg1, HWND arg2, const Extbyte * arg3, const Extbyte * arg4)
|
|
2215 {
|
|
2216 if (XEUNICODE_P)
|
|
2217 return FindWindowExW (arg1, arg2, (LPCWSTR) arg3, (LPCWSTR) arg4);
|
|
2218 else
|
|
2219 return FindWindowExA (arg1, arg2, (LPCSTR) arg3, (LPCSTR) arg4);
|
|
2220 }
|
|
2221
|
|
2222 int
|
|
2223 qxeGetClassName (HWND hWnd, Extbyte * lpClassName, int nMaxCount)
|
|
2224 {
|
|
2225 if (XEUNICODE_P)
|
|
2226 return GetClassNameW (hWnd, (LPWSTR) lpClassName, nMaxCount);
|
|
2227 else
|
|
2228 return GetClassNameA (hWnd, (LPSTR) lpClassName, nMaxCount);
|
|
2229 }
|
|
2230
|
|
2231 /* Error if SetWindowsHook used: obsolete; two versions, STRICT and non-STRICT */
|
|
2232
|
|
2233 /* Error if SetWindowsHook used: obsolete; two versions, STRICT and non-STRICT */
|
|
2234
|
|
2235 HHOOK
|
|
2236 qxeSetWindowsHookEx (int idHook, HOOKPROC lpfn, HINSTANCE hmod, DWORD dwThreadId)
|
|
2237 {
|
|
2238 if (XEUNICODE_P)
|
|
2239 return SetWindowsHookExW (idHook, lpfn, hmod, dwThreadId);
|
|
2240 else
|
|
2241 return SetWindowsHookExA (idHook, lpfn, hmod, dwThreadId);
|
|
2242 }
|
|
2243
|
|
2244 HBITMAP
|
|
2245 qxeLoadBitmap (HINSTANCE hInstance, const Extbyte * lpBitmapName)
|
|
2246 {
|
|
2247 if (XEUNICODE_P)
|
|
2248 return LoadBitmapW (hInstance, (LPCWSTR) lpBitmapName);
|
|
2249 else
|
|
2250 return LoadBitmapA (hInstance, (LPCSTR) lpBitmapName);
|
|
2251 }
|
|
2252
|
|
2253 HCURSOR
|
|
2254 qxeLoadCursor (HINSTANCE hInstance, const Extbyte * lpCursorName)
|
|
2255 {
|
|
2256 if (XEUNICODE_P)
|
|
2257 return LoadCursorW (hInstance, (LPCWSTR) lpCursorName);
|
|
2258 else
|
|
2259 return LoadCursorA (hInstance, (LPCSTR) lpCursorName);
|
|
2260 }
|
|
2261
|
|
2262 HCURSOR
|
|
2263 qxeLoadCursorFromFile (const Extbyte * lpFileName)
|
|
2264 {
|
|
2265 if (XEUNICODE_P)
|
|
2266 return LoadCursorFromFileW ((LPCWSTR) lpFileName);
|
|
2267 else
|
|
2268 return LoadCursorFromFileA ((LPCSTR) lpFileName);
|
|
2269 }
|
|
2270
|
|
2271 HICON
|
|
2272 qxeLoadIcon (HINSTANCE hInstance, const Extbyte * lpIconName)
|
|
2273 {
|
|
2274 if (XEUNICODE_P)
|
|
2275 return LoadIconW (hInstance, (LPCWSTR) lpIconName);
|
|
2276 else
|
|
2277 return LoadIconA (hInstance, (LPCSTR) lpIconName);
|
|
2278 }
|
|
2279
|
|
2280 /* NOTE: NT 4.0+ only */
|
|
2281 HANDLE
|
|
2282 qxeLoadImage (HINSTANCE arg1, const Extbyte * arg2, UINT arg3, int arg4, int arg5, UINT arg6)
|
|
2283 {
|
|
2284 if (XEUNICODE_P)
|
|
2285 return LoadImageW (arg1, (LPCWSTR) arg2, arg3, arg4, arg5, arg6);
|
|
2286 else
|
|
2287 return LoadImageA (arg1, (LPCSTR) arg2, arg3, arg4, arg5, arg6);
|
|
2288 }
|
|
2289
|
|
2290 int
|
|
2291 qxeLoadString (HINSTANCE hInstance, UINT uID, Extbyte * lpBuffer, int nBufferMax)
|
|
2292 {
|
|
2293 if (XEUNICODE_P)
|
|
2294 return LoadStringW (hInstance, uID, (LPWSTR) lpBuffer, nBufferMax);
|
|
2295 else
|
|
2296 return LoadStringA (hInstance, uID, (LPSTR) lpBuffer, nBufferMax);
|
|
2297 }
|
|
2298
|
|
2299 BOOL
|
|
2300 qxeIsDialogMessage (HWND hDlg, LPMSG lpMsg)
|
|
2301 {
|
|
2302 if (XEUNICODE_P)
|
|
2303 return IsDialogMessageW (hDlg, lpMsg);
|
|
2304 else
|
|
2305 return IsDialogMessageA (hDlg, lpMsg);
|
|
2306 }
|
|
2307
|
|
2308 int
|
|
2309 qxeDlgDirList (HWND hDlg, Extbyte * lpPathSpec, int nIDListBox, int nIDStaticPath, UINT uFileType)
|
|
2310 {
|
|
2311 if (XEUNICODE_P)
|
|
2312 return DlgDirListW (hDlg, (LPWSTR) lpPathSpec, nIDListBox, nIDStaticPath, uFileType);
|
|
2313 else
|
|
2314 return DlgDirListA (hDlg, (LPSTR) lpPathSpec, nIDListBox, nIDStaticPath, uFileType);
|
|
2315 }
|
|
2316
|
|
2317 BOOL
|
|
2318 qxeDlgDirSelectEx (HWND hDlg, Extbyte * lpString, int nCount, int nIDListBox)
|
|
2319 {
|
|
2320 if (XEUNICODE_P)
|
|
2321 return DlgDirSelectExW (hDlg, (LPWSTR) lpString, nCount, nIDListBox);
|
|
2322 else
|
|
2323 return DlgDirSelectExA (hDlg, (LPSTR) lpString, nCount, nIDListBox);
|
|
2324 }
|
|
2325
|
|
2326 int
|
|
2327 qxeDlgDirListComboBox (HWND hDlg, Extbyte * lpPathSpec, int nIDComboBox, int nIDStaticPath, UINT uFiletype)
|
|
2328 {
|
|
2329 if (XEUNICODE_P)
|
|
2330 return DlgDirListComboBoxW (hDlg, (LPWSTR) lpPathSpec, nIDComboBox, nIDStaticPath, uFiletype);
|
|
2331 else
|
|
2332 return DlgDirListComboBoxA (hDlg, (LPSTR) lpPathSpec, nIDComboBox, nIDStaticPath, uFiletype);
|
|
2333 }
|
|
2334
|
|
2335 BOOL
|
|
2336 qxeDlgDirSelectComboBoxEx (HWND hDlg, Extbyte * lpString, int nCount, int nIDComboBox)
|
|
2337 {
|
|
2338 if (XEUNICODE_P)
|
|
2339 return DlgDirSelectComboBoxExW (hDlg, (LPWSTR) lpString, nCount, nIDComboBox);
|
|
2340 else
|
|
2341 return DlgDirSelectComboBoxExA (hDlg, (LPSTR) lpString, nCount, nIDComboBox);
|
|
2342 }
|
|
2343
|
|
2344 LRESULT
|
|
2345 qxeDefFrameProc (HWND hWnd, HWND hWndMDIClient, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
|
2346 {
|
|
2347 if (XEUNICODE_P)
|
|
2348 return DefFrameProcW (hWnd, hWndMDIClient, uMsg, wParam, lParam);
|
|
2349 else
|
|
2350 return DefFrameProcA (hWnd, hWndMDIClient, uMsg, wParam, lParam);
|
|
2351 }
|
|
2352
|
|
2353 /* Error if DefMDIChildProc used: return value is conditionalized on _MAC, messes up parser */
|
|
2354
|
|
2355 HWND
|
|
2356 qxeCreateMDIWindow (Extbyte * lpClassName, Extbyte * lpWindowName, DWORD dwStyle, int X, int Y, int nWidth, int nHeight, HWND hWndParent, HINSTANCE hInstance, LPARAM lParam)
|
|
2357 {
|
|
2358 if (XEUNICODE_P)
|
|
2359 return CreateMDIWindowW ((LPWSTR) lpClassName, (LPWSTR) lpWindowName, dwStyle, X, Y, nWidth, nHeight, hWndParent, hInstance, lParam);
|
|
2360 else
|
|
2361 return CreateMDIWindowA ((LPSTR) lpClassName, (LPSTR) lpWindowName, dwStyle, X, Y, nWidth, nHeight, hWndParent, hInstance, lParam);
|
|
2362 }
|
|
2363
|
|
2364 BOOL
|
|
2365 qxeWinHelp (HWND hWndMain, const Extbyte * lpszHelp, UINT uCommand, DWORD dwData)
|
|
2366 {
|
|
2367 if (XEUNICODE_P)
|
|
2368 return WinHelpW (hWndMain, (LPCWSTR) lpszHelp, uCommand, dwData);
|
|
2369 else
|
|
2370 return WinHelpA (hWndMain, (LPCSTR) lpszHelp, uCommand, dwData);
|
|
2371 }
|
|
2372
|
|
2373 /* Error if ChangeDisplaySettings used: split-sized LPDEVMODE */
|
|
2374
|
|
2375 /* Error if ChangeDisplaySettingsEx used: split-sized LPDEVMODE; NT 5.0/Win98+ only */
|
|
2376
|
|
2377 /* Error if EnumDisplaySettings used: split-sized LPDEVMODE */
|
|
2378
|
|
2379 /* Error if EnumDisplayDevices used: split-sized PDISPLAY_DEVICE; NT 5.0+ only, no Win98 */
|
|
2380
|
|
2381 /* NOTE: probs w/ICONMETRICS, NONCLIENTMETRICS */
|
|
2382 BOOL
|
|
2383 qxeSystemParametersInfo (UINT uiAction, UINT uiParam, PVOID pvParam, UINT fWinIni)
|
|
2384 {
|
|
2385 if (XEUNICODE_P)
|
|
2386 return SystemParametersInfoW (uiAction, uiParam, pvParam, fWinIni);
|
|
2387 else
|
|
2388 return SystemParametersInfoA (uiAction, uiParam, pvParam, fWinIni);
|
|
2389 }
|
|
2390
|
|
2391 /* Error if GetMonitorInfo used: NT 5.0/Win98+ only */
|
|
2392
|
|
2393 /* Error if GetWindowModuleFileName used: NT 5.0+ only */
|
|
2394
|
|
2395 /* Error if RealGetWindowClass used: NT 5.0+ only */
|
|
2396
|
|
2397 /* Error if GetAltTabInfo used: NT 5.0+ only */
|
|
2398
|
|
2399
|
|
2400 /*----------------------------------------------------------------------*/
|
|
2401 /* Processing file MMSYSTEM.H */
|
|
2402 /*----------------------------------------------------------------------*/
|
|
2403
|
|
2404 BOOL
|
|
2405 qxesndPlaySound (const Extbyte * pszSound, UINT fuSound)
|
|
2406 {
|
|
2407 if (XEUNICODE_P)
|
|
2408 return sndPlaySoundW ((LPCWSTR) pszSound, fuSound);
|
|
2409 else
|
|
2410 return sndPlaySoundA ((LPCSTR) pszSound, fuSound);
|
|
2411 }
|
|
2412
|
|
2413 BOOL
|
|
2414 qxePlaySound (const Extbyte * pszSound, HMODULE hmod, DWORD fdwSound)
|
|
2415 {
|
|
2416 if (XEUNICODE_P)
|
|
2417 return PlaySoundW ((LPCWSTR) pszSound, hmod, fdwSound);
|
|
2418 else
|
|
2419 return PlaySoundA ((LPCSTR) pszSound, hmod, fdwSound);
|
|
2420 }
|
|
2421
|
|
2422 /* Error if waveOutGetDevCaps used: split-sized LPWAVEOUTCAPS */
|
|
2423
|
|
2424 MMRESULT
|
|
2425 qxewaveOutGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
|
|
2426 {
|
|
2427 if (XEUNICODE_P)
|
|
2428 return waveOutGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
|
|
2429 else
|
|
2430 return waveOutGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
|
|
2431 }
|
|
2432
|
|
2433 /* Error if waveInGetDevCaps used: split-sized LPWAVEINCAPS */
|
|
2434
|
|
2435 MMRESULT
|
|
2436 qxewaveInGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
|
|
2437 {
|
|
2438 if (XEUNICODE_P)
|
|
2439 return waveInGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
|
|
2440 else
|
|
2441 return waveInGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
|
|
2442 }
|
|
2443
|
|
2444 /* Error if midiOutGetDevCaps used: split-sized LPMIDIOUTCAPS */
|
|
2445
|
|
2446 MMRESULT
|
|
2447 qxemidiOutGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
|
|
2448 {
|
|
2449 if (XEUNICODE_P)
|
|
2450 return midiOutGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
|
|
2451 else
|
|
2452 return midiOutGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
|
|
2453 }
|
|
2454
|
|
2455 /* Error if midiInGetDevCaps used: split-sized LPMIDIOUTCAPS */
|
|
2456
|
|
2457 MMRESULT
|
|
2458 qxemidiInGetErrorText (MMRESULT mmrError, Extbyte * pszText, UINT cchText)
|
|
2459 {
|
|
2460 if (XEUNICODE_P)
|
|
2461 return midiInGetErrorTextW (mmrError, (LPWSTR) pszText, cchText);
|
|
2462 else
|
|
2463 return midiInGetErrorTextA (mmrError, (LPSTR) pszText, cchText);
|
|
2464 }
|
|
2465
|
|
2466 /* Error if auxGetDevCaps used: split-sized LPAUXCAPS */
|
|
2467
|
|
2468 /* Error if mixerGetDevCaps used: split-sized LPMIXERCAPS */
|
|
2469
|
|
2470 /* Error if mixerGetLineInfo used: split-sized LPMIXERLINE */
|
|
2471
|
|
2472 /* Error if mixerGetLineControls used: split-sized LPMIXERCONTROL */
|
|
2473
|
|
2474 /* Error if mixerGetControlDetails used: split-sized LPMIXERCONTROL in LPMIXERLINECONTROLS in LPMIXERCONTROLDETAILS */
|
|
2475
|
|
2476 /* Error if joyGetDevCaps used: split-sized LPJOYCAPS */
|
|
2477
|
|
2478 FOURCC
|
|
2479 qxemmioStringToFOURCC (const Extbyte * sz, UINT uFlags)
|
|
2480 {
|
|
2481 if (XEUNICODE_P)
|
|
2482 return mmioStringToFOURCCW ((LPCWSTR) sz, uFlags);
|
|
2483 else
|
|
2484 return mmioStringToFOURCCA ((LPCSTR) sz, uFlags);
|
|
2485 }
|
|
2486
|
|
2487 LPMMIOPROC
|
|
2488 qxemmioInstallIOProc (FOURCC fccIOProc, LPMMIOPROC pIOProc, DWORD dwFlags)
|
|
2489 {
|
|
2490 if (XEUNICODE_P)
|
|
2491 return mmioInstallIOProcW (fccIOProc, pIOProc, dwFlags);
|
|
2492 else
|
|
2493 return mmioInstallIOProcA (fccIOProc, pIOProc, dwFlags);
|
|
2494 }
|
|
2495
|
|
2496 HMMIO
|
|
2497 qxemmioOpen (Extbyte * pszFileName, LPMMIOINFO pmmioinfo, DWORD fdwOpen)
|
|
2498 {
|
|
2499 if (XEUNICODE_P)
|
|
2500 return mmioOpenW ((LPWSTR) pszFileName, pmmioinfo, fdwOpen);
|
|
2501 else
|
|
2502 return mmioOpenA ((LPSTR) pszFileName, pmmioinfo, fdwOpen);
|
|
2503 }
|
|
2504
|
|
2505 MMRESULT
|
|
2506 qxemmioRename (const Extbyte * pszFileName, const Extbyte * pszNewFileName, LPCMMIOINFO pmmioinfo, DWORD fdwRename)
|
|
2507 {
|
|
2508 if (XEUNICODE_P)
|
|
2509 return mmioRenameW ((LPCWSTR) pszFileName, (LPCWSTR) pszNewFileName, pmmioinfo, fdwRename);
|
|
2510 else
|
|
2511 return mmioRenameA ((LPCSTR) pszFileName, (LPCSTR) pszNewFileName, pmmioinfo, fdwRename);
|
|
2512 }
|
|
2513
|
|
2514 MCIERROR
|
|
2515 qxemciSendCommand (MCIDEVICEID mciId, UINT uMsg, DWORD dwParam1, DWORD dwParam2)
|
|
2516 {
|
|
2517 if (XEUNICODE_P)
|
|
2518 return mciSendCommandW (mciId, uMsg, dwParam1, dwParam2);
|
|
2519 else
|
|
2520 return mciSendCommandA (mciId, uMsg, dwParam1, dwParam2);
|
|
2521 }
|
|
2522
|
|
2523 MCIERROR
|
|
2524 qxemciSendString (const Extbyte * lpstrCommand, Extbyte * lpstrReturnString, UINT uReturnLength, HWND hwndCallback)
|
|
2525 {
|
|
2526 if (XEUNICODE_P)
|
|
2527 return mciSendStringW ((LPCWSTR) lpstrCommand, (LPWSTR) lpstrReturnString, uReturnLength, hwndCallback);
|
|
2528 else
|
|
2529 return mciSendStringA ((LPCSTR) lpstrCommand, (LPSTR) lpstrReturnString, uReturnLength, hwndCallback);
|
|
2530 }
|
|
2531
|
|
2532 MCIDEVICEID
|
|
2533 qxemciGetDeviceID (const Extbyte * pszDevice)
|
|
2534 {
|
|
2535 if (XEUNICODE_P)
|
|
2536 return mciGetDeviceIDW ((LPCWSTR) pszDevice);
|
|
2537 else
|
|
2538 return mciGetDeviceIDA ((LPCSTR) pszDevice);
|
|
2539 }
|
|
2540
|
|
2541 #if !defined (MINGW)
|
|
2542
|
778
|
2543 /* Error if mciGetDeviceIDFromElementID used: missing from Win98se version of ADVAPI32.dll */
|
771
|
2544
|
|
2545 #endif /* !defined (MINGW) */
|
|
2546
|
|
2547 BOOL
|
|
2548 qxemciGetErrorString (MCIERROR mcierr, Extbyte * pszText, UINT cchText)
|
|
2549 {
|
|
2550 if (XEUNICODE_P)
|
|
2551 return mciGetErrorStringW (mcierr, (LPWSTR) pszText, cchText);
|
|
2552 else
|
|
2553 return mciGetErrorStringA (mcierr, (LPSTR) pszText, cchText);
|
|
2554 }
|
|
2555
|
|
2556
|
|
2557 /*----------------------------------------------------------------------*/
|
|
2558 /* Processing file WINBASE.H */
|
|
2559 /*----------------------------------------------------------------------*/
|
|
2560
|
|
2561 BOOL
|
|
2562 qxeGetBinaryType (const Extbyte * lpApplicationName, LPDWORD lpBinaryType)
|
|
2563 {
|
|
2564 if (XEUNICODE_P)
|
|
2565 return GetBinaryTypeW ((LPCWSTR) lpApplicationName, lpBinaryType);
|
|
2566 else
|
|
2567 return GetBinaryTypeA ((LPCSTR) lpApplicationName, lpBinaryType);
|
|
2568 }
|
|
2569
|
|
2570 DWORD
|
|
2571 qxeGetShortPathName (const Extbyte * lpszLongPath, Extbyte * lpszShortPath, DWORD cchBuffer)
|
|
2572 {
|
|
2573 if (XEUNICODE_P)
|
|
2574 return GetShortPathNameW ((LPCWSTR) lpszLongPath, (LPWSTR) lpszShortPath, cchBuffer);
|
|
2575 else
|
|
2576 return GetShortPathNameA ((LPCSTR) lpszLongPath, (LPSTR) lpszShortPath, cchBuffer);
|
|
2577 }
|
|
2578
|
|
2579 DWORD
|
|
2580 qxeGetLongPathName (const Extbyte * lpszShortPath, Extbyte * lpszLongPath, DWORD cchBuffer)
|
|
2581 {
|
|
2582 if (XEUNICODE_P)
|
|
2583 return GetLongPathNameW ((LPCWSTR) lpszShortPath, (LPWSTR) lpszLongPath, cchBuffer);
|
|
2584 else
|
|
2585 return GetLongPathNameA ((LPCSTR) lpszShortPath, (LPSTR) lpszLongPath, cchBuffer);
|
|
2586 }
|
|
2587
|
|
2588 Extbyte *
|
|
2589 qxeGetEnvironmentStrings (void)
|
|
2590 {
|
|
2591 if (XEUNICODE_P)
|
|
2592 return (Extbyte *) GetEnvironmentStringsW ();
|
|
2593 else
|
|
2594 return (Extbyte *) GetEnvironmentStringsA ();
|
|
2595 }
|
|
2596
|
|
2597 BOOL
|
|
2598 qxeFreeEnvironmentStrings (Extbyte * arg1)
|
|
2599 {
|
|
2600 if (XEUNICODE_P)
|
|
2601 return FreeEnvironmentStringsW ((LPWSTR) arg1);
|
|
2602 else
|
|
2603 return FreeEnvironmentStringsA ((LPSTR) arg1);
|
|
2604 }
|
|
2605
|
|
2606 DWORD
|
|
2607 qxeFormatMessage (DWORD dwFlags, LPCVOID lpSource, DWORD dwMessageId, DWORD dwLanguageId, Extbyte * lpBuffer, DWORD nSize, va_list * Arguments)
|
|
2608 {
|
|
2609 if (XEUNICODE_P)
|
|
2610 return FormatMessageW (dwFlags, lpSource, dwMessageId, dwLanguageId, (LPWSTR) lpBuffer, nSize, Arguments);
|
|
2611 else
|
|
2612 return FormatMessageA (dwFlags, lpSource, dwMessageId, dwLanguageId, (LPSTR) lpBuffer, nSize, Arguments);
|
|
2613 }
|
|
2614
|
|
2615 HANDLE
|
|
2616 qxeCreateMailslot (const Extbyte * lpName, DWORD nMaxMessageSize, DWORD lReadTimeout, LPSECURITY_ATTRIBUTES lpSecurityAttributes)
|
|
2617 {
|
|
2618 if (XEUNICODE_P)
|
|
2619 return CreateMailslotW ((LPCWSTR) lpName, nMaxMessageSize, lReadTimeout, lpSecurityAttributes);
|
|
2620 else
|
|
2621 return CreateMailslotA ((LPCSTR) lpName, nMaxMessageSize, lReadTimeout, lpSecurityAttributes);
|
|
2622 }
|
|
2623
|
|
2624 #if !defined (CYGWIN_HEADERS)
|
|
2625
|
778
|
2626 /* Error if EncryptFile used: Win2K+ only */
|
771
|
2627
|
|
2628 #endif /* !defined (CYGWIN_HEADERS) */
|
|
2629
|
|
2630 #if !defined (CYGWIN_HEADERS)
|
|
2631
|
778
|
2632 /* Error if DecryptFile used: Win2K+ only */
|
771
|
2633
|
|
2634 #endif /* !defined (CYGWIN_HEADERS) */
|
|
2635
|
|
2636 /* Error if OpenRaw used: error "The procedure entry point OpenRawW could not be located in the dynamic link library ADVAPI32.dll." */
|
|
2637
|
|
2638 /* Error if QueryRecoveryAgents used: split-sized LPRECOVERY_AGENT_INFORMATION */
|
|
2639
|
|
2640 int
|
|
2641 qxelstrcmp (const Extbyte * lpString1, const Extbyte * lpString2)
|
|
2642 {
|
|
2643 if (XEUNICODE_P)
|
|
2644 return lstrcmpW ((LPCWSTR) lpString1, (LPCWSTR) lpString2);
|
|
2645 else
|
|
2646 return lstrcmpA ((LPCSTR) lpString1, (LPCSTR) lpString2);
|
|
2647 }
|
|
2648
|
|
2649 int
|
|
2650 qxelstrcmpi (const Extbyte * lpString1, const Extbyte * lpString2)
|
|
2651 {
|
|
2652 if (XEUNICODE_P)
|
|
2653 return lstrcmpiW ((LPCWSTR) lpString1, (LPCWSTR) lpString2);
|
|
2654 else
|
|
2655 return lstrcmpiA ((LPCSTR) lpString1, (LPCSTR) lpString2);
|
|
2656 }
|
|
2657
|
|
2658 Extbyte *
|
|
2659 qxelstrcpyn (Extbyte * lpString1, const Extbyte * lpString2, int iMaxLength)
|
|
2660 {
|
|
2661 if (XEUNICODE_P)
|
|
2662 return (Extbyte *) lstrcpynW ((LPWSTR) lpString1, (LPCWSTR) lpString2, iMaxLength);
|
|
2663 else
|
|
2664 return (Extbyte *) lstrcpynA ((LPSTR) lpString1, (LPCSTR) lpString2, iMaxLength);
|
|
2665 }
|
|
2666
|
|
2667 Extbyte *
|
|
2668 qxelstrcpy (Extbyte * lpString1, const Extbyte * lpString2)
|
|
2669 {
|
|
2670 if (XEUNICODE_P)
|
|
2671 return (Extbyte *) lstrcpyW ((LPWSTR) lpString1, (LPCWSTR) lpString2);
|
|
2672 else
|
|
2673 return (Extbyte *) lstrcpyA ((LPSTR) lpString1, (LPCSTR) lpString2);
|
|
2674 }
|
|
2675
|
|
2676 Extbyte *
|
|
2677 qxelstrcat (Extbyte * lpString1, const Extbyte * lpString2)
|
|
2678 {
|
|
2679 if (XEUNICODE_P)
|
|
2680 return (Extbyte *) lstrcatW ((LPWSTR) lpString1, (LPCWSTR) lpString2);
|
|
2681 else
|
|
2682 return (Extbyte *) lstrcatA ((LPSTR) lpString1, (LPCSTR) lpString2);
|
|
2683 }
|
|
2684
|
|
2685 int
|
|
2686 qxelstrlen (const Extbyte * lpString)
|
|
2687 {
|
|
2688 if (XEUNICODE_P)
|
|
2689 return lstrlenW ((LPCWSTR) lpString);
|
|
2690 else
|
|
2691 return lstrlenA ((LPCSTR) lpString);
|
|
2692 }
|
|
2693
|
|
2694 HANDLE
|
|
2695 qxeCreateMutex (LPSECURITY_ATTRIBUTES lpMutexAttributes, BOOL bInitialOwner, const Extbyte * lpName)
|
|
2696 {
|
|
2697 if (XEUNICODE_P)
|
|
2698 return CreateMutexW (lpMutexAttributes, bInitialOwner, (LPCWSTR) lpName);
|
|
2699 else
|
|
2700 return CreateMutexA (lpMutexAttributes, bInitialOwner, (LPCSTR) lpName);
|
|
2701 }
|
|
2702
|
|
2703 HANDLE
|
|
2704 qxeOpenMutex (DWORD dwDesiredAccess, BOOL bInheritHandle, const Extbyte * lpName)
|
|
2705 {
|
|
2706 if (XEUNICODE_P)
|
|
2707 return OpenMutexW (dwDesiredAccess, bInheritHandle, (LPCWSTR) lpName);
|
|
2708 else
|
|
2709 return OpenMutexA (dwDesiredAccess, bInheritHandle, (LPCSTR) lpName);
|
|
2710 }
|
|
2711
|
|
2712 HANDLE
|
|
2713 qxeCreateEvent (LPSECURITY_ATTRIBUTES lpEventAttributes, BOOL bManualReset, BOOL bInitialState, const Extbyte * lpName)
|
|
2714 {
|
|
2715 if (XEUNICODE_P)
|
|
2716 return CreateEventW (lpEventAttributes, bManualReset, bInitialState, (LPCWSTR) lpName);
|
|
2717 else
|
|
2718 return CreateEventA (lpEventAttributes, bManualReset, bInitialState, (LPCSTR) lpName);
|
|
2719 }
|
|
2720
|
|
2721 HANDLE
|
|
2722 qxeOpenEvent (DWORD dwDesiredAccess, BOOL bInheritHandle, const Extbyte * lpName)
|
|
2723 {
|
|
2724 if (XEUNICODE_P)
|
|
2725 return OpenEventW (dwDesiredAccess, bInheritHandle, (LPCWSTR) lpName);
|
|
2726 else
|
|
2727 return OpenEventA (dwDesiredAccess, bInheritHandle, (LPCSTR) lpName);
|
|
2728 }
|
|
2729
|
|
2730 HANDLE
|
|
2731 qxeCreateSemaphore (LPSECURITY_ATTRIBUTES lpSemaphoreAttributes, LONG lInitialCount, LONG lMaximumCount, const Extbyte * lpName)
|
|
2732 {
|
|
2733 if (XEUNICODE_P)
|
|
2734 return CreateSemaphoreW (lpSemaphoreAttributes, lInitialCount, lMaximumCount, (LPCWSTR) lpName);
|
|
2735 else
|
|
2736 return CreateSemaphoreA (lpSemaphoreAttributes, lInitialCount, lMaximumCount, (LPCSTR) lpName);
|
|
2737 }
|
|
2738
|
|
2739 HANDLE
|
|
2740 qxeOpenSemaphore (DWORD dwDesiredAccess, BOOL bInheritHandle, const Extbyte * lpName)
|
|
2741 {
|
|
2742 if (XEUNICODE_P)
|
|
2743 return OpenSemaphoreW (dwDesiredAccess, bInheritHandle, (LPCWSTR) lpName);
|
|
2744 else
|
|
2745 return OpenSemaphoreA (dwDesiredAccess, bInheritHandle, (LPCSTR) lpName);
|
|
2746 }
|
|
2747
|
|
2748 HANDLE
|
|
2749 qxeCreateWaitableTimer (LPSECURITY_ATTRIBUTES lpTimerAttributes, BOOL bManualReset, const Extbyte * lpTimerName)
|
|
2750 {
|
|
2751 if (XEUNICODE_P)
|
|
2752 return CreateWaitableTimerW (lpTimerAttributes, bManualReset, (LPCWSTR) lpTimerName);
|
|
2753 else
|
|
2754 return CreateWaitableTimerA (lpTimerAttributes, bManualReset, (LPCSTR) lpTimerName);
|
|
2755 }
|
|
2756
|
|
2757 HANDLE
|
|
2758 qxeOpenWaitableTimer (DWORD dwDesiredAccess, BOOL bInheritHandle, const Extbyte * lpTimerName)
|
|
2759 {
|
|
2760 if (XEUNICODE_P)
|
|
2761 return OpenWaitableTimerW (dwDesiredAccess, bInheritHandle, (LPCWSTR) lpTimerName);
|
|
2762 else
|
|
2763 return OpenWaitableTimerA (dwDesiredAccess, bInheritHandle, (LPCSTR) lpTimerName);
|
|
2764 }
|
|
2765
|
|
2766 HANDLE
|
|
2767 qxeCreateFileMapping (HANDLE hFile, LPSECURITY_ATTRIBUTES lpFileMappingAttributes, DWORD flProtect, DWORD dwMaximumSizeHigh, DWORD dwMaximumSizeLow, const Extbyte * lpName)
|
|
2768 {
|
|
2769 if (XEUNICODE_P)
|
|
2770 return CreateFileMappingW (hFile, lpFileMappingAttributes, flProtect, dwMaximumSizeHigh, dwMaximumSizeLow, (LPCWSTR) lpName);
|
|
2771 else
|
|
2772 return CreateFileMappingA (hFile, lpFileMappingAttributes, flProtect, dwMaximumSizeHigh, dwMaximumSizeLow, (LPCSTR) lpName);
|
|
2773 }
|
|
2774
|
|
2775 HANDLE
|
|
2776 qxeOpenFileMapping (DWORD dwDesiredAccess, BOOL bInheritHandle, const Extbyte * lpName)
|
|
2777 {
|
|
2778 if (XEUNICODE_P)
|
|
2779 return OpenFileMappingW (dwDesiredAccess, bInheritHandle, (LPCWSTR) lpName);
|
|
2780 else
|
|
2781 return OpenFileMappingA (dwDesiredAccess, bInheritHandle, (LPCSTR) lpName);
|
|
2782 }
|
|
2783
|
|
2784 DWORD
|
|
2785 qxeGetLogicalDriveStrings (DWORD nBufferLength, Extbyte * lpBuffer)
|
|
2786 {
|
|
2787 if (XEUNICODE_P)
|
|
2788 return GetLogicalDriveStringsW (nBufferLength, (LPWSTR) lpBuffer);
|
|
2789 else
|
|
2790 return GetLogicalDriveStringsA (nBufferLength, (LPSTR) lpBuffer);
|
|
2791 }
|
|
2792
|
|
2793 HMODULE
|
|
2794 qxeLoadLibrary (const Extbyte * lpLibFileName)
|
|
2795 {
|
|
2796 if (XEUNICODE_P)
|
|
2797 return LoadLibraryW ((LPCWSTR) lpLibFileName);
|
|
2798 else
|
|
2799 return LoadLibraryA ((LPCSTR) lpLibFileName);
|
|
2800 }
|
|
2801
|
|
2802 HMODULE
|
|
2803 qxeLoadLibraryEx (const Extbyte * lpLibFileName, HANDLE hFile, DWORD dwFlags)
|
|
2804 {
|
|
2805 if (XEUNICODE_P)
|
|
2806 return LoadLibraryExW ((LPCWSTR) lpLibFileName, hFile, dwFlags);
|
|
2807 else
|
|
2808 return LoadLibraryExA ((LPCSTR) lpLibFileName, hFile, dwFlags);
|
|
2809 }
|
|
2810
|
|
2811 DWORD
|
|
2812 qxeGetModuleFileName (HMODULE hModule, Extbyte * lpFilename, DWORD nSize)
|
|
2813 {
|
|
2814 if (XEUNICODE_P)
|
|
2815 return GetModuleFileNameW (hModule, (LPWSTR) lpFilename, nSize);
|
|
2816 else
|
|
2817 return GetModuleFileNameA (hModule, (LPSTR) lpFilename, nSize);
|
|
2818 }
|
|
2819
|
|
2820 HMODULE
|
|
2821 qxeGetModuleHandle (const Extbyte * lpModuleName)
|
|
2822 {
|
|
2823 if (XEUNICODE_P)
|
|
2824 return GetModuleHandleW ((LPCWSTR) lpModuleName);
|
|
2825 else
|
|
2826 return GetModuleHandleA ((LPCSTR) lpModuleName);
|
|
2827 }
|
|
2828
|
|
2829 BOOL
|
|
2830 qxeCreateProcess (const Extbyte * lpApplicationName, Extbyte * lpCommandLine, LPSECURITY_ATTRIBUTES lpProcessAttributes, LPSECURITY_ATTRIBUTES lpThreadAttributes, BOOL bInheritHandles, DWORD dwCreationFlags, LPVOID lpEnvironment, const Extbyte * lpCurrentDirectory, LPSTARTUPINFOW lpStartupInfo, LPPROCESS_INFORMATION lpProcessInformation)
|
|
2831 {
|
|
2832 if (XEUNICODE_P)
|
|
2833 return CreateProcessW ((LPCWSTR) lpApplicationName, (LPWSTR) lpCommandLine, lpProcessAttributes, lpThreadAttributes, bInheritHandles, dwCreationFlags, lpEnvironment, (LPCWSTR) lpCurrentDirectory, lpStartupInfo, lpProcessInformation);
|
|
2834 else
|
|
2835 return CreateProcessA ((LPCSTR) lpApplicationName, (LPSTR) lpCommandLine, lpProcessAttributes, lpThreadAttributes, bInheritHandles, dwCreationFlags, lpEnvironment, (LPCSTR) lpCurrentDirectory, (LPSTARTUPINFOA) lpStartupInfo, lpProcessInformation);
|
|
2836 }
|
|
2837
|
|
2838 VOID
|
|
2839 qxeFatalAppExit (UINT uAction, const Extbyte * lpMessageText)
|
|
2840 {
|
|
2841 if (XEUNICODE_P)
|
|
2842 FatalAppExitW (uAction, (LPCWSTR) lpMessageText);
|
|
2843 else
|
|
2844 FatalAppExitA (uAction, (LPCSTR) lpMessageText);
|
|
2845 }
|
|
2846
|
|
2847 VOID
|
|
2848 qxeGetStartupInfo (LPSTARTUPINFOW lpStartupInfo)
|
|
2849 {
|
|
2850 if (XEUNICODE_P)
|
|
2851 GetStartupInfoW (lpStartupInfo);
|
|
2852 else
|
|
2853 GetStartupInfoA ((LPSTARTUPINFOA) lpStartupInfo);
|
|
2854 }
|
|
2855
|
|
2856 Extbyte *
|
|
2857 qxeGetCommandLine (void)
|
|
2858 {
|
|
2859 if (XEUNICODE_P)
|
|
2860 return (Extbyte *) GetCommandLineW ();
|
|
2861 else
|
|
2862 return (Extbyte *) GetCommandLineA ();
|
|
2863 }
|
|
2864
|
|
2865 DWORD
|
|
2866 qxeGetEnvironmentVariable (const Extbyte * lpName, Extbyte * lpBuffer, DWORD nSize)
|
|
2867 {
|
|
2868 if (XEUNICODE_P)
|
|
2869 return GetEnvironmentVariableW ((LPCWSTR) lpName, (LPWSTR) lpBuffer, nSize);
|
|
2870 else
|
|
2871 return GetEnvironmentVariableA ((LPCSTR) lpName, (LPSTR) lpBuffer, nSize);
|
|
2872 }
|
|
2873
|
|
2874 BOOL
|
|
2875 qxeSetEnvironmentVariable (const Extbyte * lpName, const Extbyte * lpValue)
|
|
2876 {
|
|
2877 if (XEUNICODE_P)
|
|
2878 return SetEnvironmentVariableW ((LPCWSTR) lpName, (LPCWSTR) lpValue);
|
|
2879 else
|
|
2880 return SetEnvironmentVariableA ((LPCSTR) lpName, (LPCSTR) lpValue);
|
|
2881 }
|
|
2882
|
|
2883 DWORD
|
|
2884 qxeExpandEnvironmentStrings (const Extbyte * lpSrc, Extbyte * lpDst, DWORD nSize)
|
|
2885 {
|
|
2886 if (XEUNICODE_P)
|
|
2887 return ExpandEnvironmentStringsW ((LPCWSTR) lpSrc, (LPWSTR) lpDst, nSize);
|
|
2888 else
|
|
2889 return ExpandEnvironmentStringsA ((LPCSTR) lpSrc, (LPSTR) lpDst, nSize);
|
|
2890 }
|
|
2891
|
|
2892 VOID
|
|
2893 qxeOutputDebugString (const Extbyte * lpOutputString)
|
|
2894 {
|
|
2895 if (XEUNICODE_P)
|
|
2896 OutputDebugStringW ((LPCWSTR) lpOutputString);
|
|
2897 else
|
|
2898 OutputDebugStringA ((LPCSTR) lpOutputString);
|
|
2899 }
|
|
2900
|
|
2901 HRSRC
|
|
2902 qxeFindResource (HMODULE hModule, const Extbyte * lpName, const Extbyte * lpType)
|
|
2903 {
|
|
2904 if (XEUNICODE_P)
|
|
2905 return FindResourceW (hModule, (LPCWSTR) lpName, (LPCWSTR) lpType);
|
|
2906 else
|
|
2907 return FindResourceA (hModule, (LPCSTR) lpName, (LPCSTR) lpType);
|
|
2908 }
|
|
2909
|
|
2910 HRSRC
|
|
2911 qxeFindResourceEx (HMODULE hModule, const Extbyte * lpType, const Extbyte * lpName, WORD wLanguage)
|
|
2912 {
|
|
2913 if (XEUNICODE_P)
|
|
2914 return FindResourceExW (hModule, (LPCWSTR) lpType, (LPCWSTR) lpName, wLanguage);
|
|
2915 else
|
|
2916 return FindResourceExA (hModule, (LPCSTR) lpType, (LPCSTR) lpName, wLanguage);
|
|
2917 }
|
|
2918
|
|
2919 BOOL
|
|
2920 qxeEnumResourceTypes (HMODULE hModule, ENUMRESTYPEPROC lpEnumFunc, LONG lParam)
|
|
2921 {
|
|
2922 if (XEUNICODE_P)
|
|
2923 return EnumResourceTypesW (hModule, lpEnumFunc, lParam);
|
|
2924 else
|
|
2925 return EnumResourceTypesA (hModule, lpEnumFunc, lParam);
|
|
2926 }
|
|
2927
|
|
2928 BOOL
|
|
2929 qxeEnumResourceNames (HMODULE hModule, const Extbyte * lpType, ENUMRESNAMEPROC lpEnumFunc, LONG lParam)
|
|
2930 {
|
|
2931 if (XEUNICODE_P)
|
|
2932 return EnumResourceNamesW (hModule, (LPCWSTR) lpType, lpEnumFunc, lParam);
|
|
2933 else
|
|
2934 return EnumResourceNamesA (hModule, (LPCSTR) lpType, lpEnumFunc, lParam);
|
|
2935 }
|
|
2936
|
|
2937 BOOL
|
|
2938 qxeEnumResourceLanguages (HMODULE hModule, const Extbyte * lpType, const Extbyte * lpName, ENUMRESLANGPROC lpEnumFunc, LONG lParam)
|
|
2939 {
|
|
2940 if (XEUNICODE_P)
|
|
2941 return EnumResourceLanguagesW (hModule, (LPCWSTR) lpType, (LPCWSTR) lpName, lpEnumFunc, lParam);
|
|
2942 else
|
|
2943 return EnumResourceLanguagesA (hModule, (LPCSTR) lpType, (LPCSTR) lpName, lpEnumFunc, lParam);
|
|
2944 }
|
|
2945
|
|
2946 HANDLE
|
|
2947 qxeBeginUpdateResource (const Extbyte * pFileName, BOOL bDeleteExistingResources)
|
|
2948 {
|
|
2949 if (XEUNICODE_P)
|
|
2950 return BeginUpdateResourceW ((LPCWSTR) pFileName, bDeleteExistingResources);
|
|
2951 else
|
|
2952 return BeginUpdateResourceA ((LPCSTR) pFileName, bDeleteExistingResources);
|
|
2953 }
|
|
2954
|
|
2955 BOOL
|
|
2956 qxeUpdateResource (HANDLE hUpdate, const Extbyte * lpType, const Extbyte * lpName, WORD wLanguage, LPVOID lpData, DWORD cbData)
|
|
2957 {
|
|
2958 if (XEUNICODE_P)
|
|
2959 return UpdateResourceW (hUpdate, (LPCWSTR) lpType, (LPCWSTR) lpName, wLanguage, lpData, cbData);
|
|
2960 else
|
|
2961 return UpdateResourceA (hUpdate, (LPCSTR) lpType, (LPCSTR) lpName, wLanguage, lpData, cbData);
|
|
2962 }
|
|
2963
|
|
2964 BOOL
|
|
2965 qxeEndUpdateResource (HANDLE hUpdate, BOOL fDiscard)
|
|
2966 {
|
|
2967 if (XEUNICODE_P)
|
|
2968 return EndUpdateResourceW (hUpdate, fDiscard);
|
|
2969 else
|
|
2970 return EndUpdateResourceA (hUpdate, fDiscard);
|
|
2971 }
|
|
2972
|
|
2973 ATOM
|
|
2974 qxeGlobalAddAtom (const Extbyte * lpString)
|
|
2975 {
|
|
2976 if (XEUNICODE_P)
|
|
2977 return GlobalAddAtomW ((LPCWSTR) lpString);
|
|
2978 else
|
|
2979 return GlobalAddAtomA ((LPCSTR) lpString);
|
|
2980 }
|
|
2981
|
|
2982 ATOM
|
|
2983 qxeGlobalFindAtom (const Extbyte * lpString)
|
|
2984 {
|
|
2985 if (XEUNICODE_P)
|
|
2986 return GlobalFindAtomW ((LPCWSTR) lpString);
|
|
2987 else
|
|
2988 return GlobalFindAtomA ((LPCSTR) lpString);
|
|
2989 }
|
|
2990
|
|
2991 UINT
|
|
2992 qxeGlobalGetAtomName (ATOM nAtom, Extbyte * lpBuffer, int nSize)
|
|
2993 {
|
|
2994 if (XEUNICODE_P)
|
|
2995 return GlobalGetAtomNameW (nAtom, (LPWSTR) lpBuffer, nSize);
|
|
2996 else
|
|
2997 return GlobalGetAtomNameA (nAtom, (LPSTR) lpBuffer, nSize);
|
|
2998 }
|
|
2999
|
|
3000 ATOM
|
|
3001 qxeAddAtom (const Extbyte * lpString)
|
|
3002 {
|
|
3003 if (XEUNICODE_P)
|
|
3004 return AddAtomW ((LPCWSTR) lpString);
|
|
3005 else
|
|
3006 return AddAtomA ((LPCSTR) lpString);
|
|
3007 }
|
|
3008
|
|
3009 ATOM
|
|
3010 qxeFindAtom (const Extbyte * lpString)
|
|
3011 {
|
|
3012 if (XEUNICODE_P)
|
|
3013 return FindAtomW ((LPCWSTR) lpString);
|
|
3014 else
|
|
3015 return FindAtomA ((LPCSTR) lpString);
|
|
3016 }
|
|
3017
|
|
3018 UINT
|
|
3019 qxeGetAtomName (ATOM nAtom, Extbyte * lpBuffer, int nSize)
|
|
3020 {
|
|
3021 if (XEUNICODE_P)
|
|
3022 return GetAtomNameW (nAtom, (LPWSTR) lpBuffer, nSize);
|
|
3023 else
|
|
3024 return GetAtomNameA (nAtom, (LPSTR) lpBuffer, nSize);
|
|
3025 }
|
|
3026
|
|
3027 UINT
|
|
3028 qxeGetProfileInt (const Extbyte * lpAppName, const Extbyte * lpKeyName, INT nDefault)
|
|
3029 {
|
|
3030 if (XEUNICODE_P)
|
|
3031 return GetProfileIntW ((LPCWSTR) lpAppName, (LPCWSTR) lpKeyName, nDefault);
|
|
3032 else
|
|
3033 return GetProfileIntA ((LPCSTR) lpAppName, (LPCSTR) lpKeyName, nDefault);
|
|
3034 }
|
|
3035
|
|
3036 DWORD
|
|
3037 qxeGetProfileString (const Extbyte * lpAppName, const Extbyte * lpKeyName, const Extbyte * lpDefault, Extbyte * lpReturnedString, DWORD nSize)
|
|
3038 {
|
|
3039 if (XEUNICODE_P)
|
|
3040 return GetProfileStringW ((LPCWSTR) lpAppName, (LPCWSTR) lpKeyName, (LPCWSTR) lpDefault, (LPWSTR) lpReturnedString, nSize);
|
|
3041 else
|
|
3042 return GetProfileStringA ((LPCSTR) lpAppName, (LPCSTR) lpKeyName, (LPCSTR) lpDefault, (LPSTR) lpReturnedString, nSize);
|
|
3043 }
|
|
3044
|
|
3045 BOOL
|
|
3046 qxeWriteProfileString (const Extbyte * lpAppName, const Extbyte * lpKeyName, const Extbyte * lpString)
|
|
3047 {
|
|
3048 if (XEUNICODE_P)
|
|
3049 return WriteProfileStringW ((LPCWSTR) lpAppName, (LPCWSTR) lpKeyName, (LPCWSTR) lpString);
|
|
3050 else
|
|
3051 return WriteProfileStringA ((LPCSTR) lpAppName, (LPCSTR) lpKeyName, (LPCSTR) lpString);
|
|
3052 }
|
|
3053
|
|
3054 DWORD
|
|
3055 qxeGetProfileSection (const Extbyte * lpAppName, Extbyte * lpReturnedString, DWORD nSize)
|
|
3056 {
|
|
3057 if (XEUNICODE_P)
|
|
3058 return GetProfileSectionW ((LPCWSTR) lpAppName, (LPWSTR) lpReturnedString, nSize);
|
|
3059 else
|
|
3060 return GetProfileSectionA ((LPCSTR) lpAppName, (LPSTR) lpReturnedString, nSize);
|
|
3061 }
|
|
3062
|
|
3063 BOOL
|
|
3064 qxeWriteProfileSection (const Extbyte * lpAppName, const Extbyte * lpString)
|
|
3065 {
|
|
3066 if (XEUNICODE_P)
|
|
3067 return WriteProfileSectionW ((LPCWSTR) lpAppName, (LPCWSTR) lpString);
|
|
3068 else
|
|
3069 return WriteProfileSectionA ((LPCSTR) lpAppName, (LPCSTR) lpString);
|
|
3070 }
|
|
3071
|
|
3072 UINT
|
|
3073 qxeGetPrivateProfileInt (const Extbyte * lpAppName, const Extbyte * lpKeyName, INT nDefault, const Extbyte * lpFileName)
|
|
3074 {
|
|
3075 if (XEUNICODE_P)
|
|
3076 return GetPrivateProfileIntW ((LPCWSTR) lpAppName, (LPCWSTR) lpKeyName, nDefault, (LPCWSTR) lpFileName);
|
|
3077 else
|
|
3078 return GetPrivateProfileIntA ((LPCSTR) lpAppName, (LPCSTR) lpKeyName, nDefault, (LPCSTR) lpFileName);
|
|
3079 }
|
|
3080
|
|
3081 DWORD
|
|
3082 qxeGetPrivateProfileString (const Extbyte * lpAppName, const Extbyte * lpKeyName, const Extbyte * lpDefault, Extbyte * lpReturnedString, DWORD nSize, const Extbyte * lpFileName)
|
|
3083 {
|
|
3084 if (XEUNICODE_P)
|
|
3085 return GetPrivateProfileStringW ((LPCWSTR) lpAppName, (LPCWSTR) lpKeyName, (LPCWSTR) lpDefault, (LPWSTR) lpReturnedString, nSize, (LPCWSTR) lpFileName);
|
|
3086 else
|
|
3087 return GetPrivateProfileStringA ((LPCSTR) lpAppName, (LPCSTR) lpKeyName, (LPCSTR) lpDefault, (LPSTR) lpReturnedString, nSize, (LPCSTR) lpFileName);
|
|
3088 }
|
|
3089
|
|
3090 BOOL
|
|
3091 qxeWritePrivateProfileString (const Extbyte * lpAppName, const Extbyte * lpKeyName, const Extbyte * lpString, const Extbyte * lpFileName)
|
|
3092 {
|
|
3093 if (XEUNICODE_P)
|
|
3094 return WritePrivateProfileStringW ((LPCWSTR) lpAppName, (LPCWSTR) lpKeyName, (LPCWSTR) lpString, (LPCWSTR) lpFileName);
|
|
3095 else
|
|
3096 return WritePrivateProfileStringA ((LPCSTR) lpAppName, (LPCSTR) lpKeyName, (LPCSTR) lpString, (LPCSTR) lpFileName);
|
|
3097 }
|
|
3098
|
|
3099 DWORD
|
|
3100 qxeGetPrivateProfileSection (const Extbyte * lpAppName, Extbyte * lpReturnedString, DWORD nSize, const Extbyte * lpFileName)
|
|
3101 {
|
|
3102 if (XEUNICODE_P)
|
|
3103 return GetPrivateProfileSectionW ((LPCWSTR) lpAppName, (LPWSTR) lpReturnedString, nSize, (LPCWSTR) lpFileName);
|
|
3104 else
|
|
3105 return GetPrivateProfileSectionA ((LPCSTR) lpAppName, (LPSTR) lpReturnedString, nSize, (LPCSTR) lpFileName);
|
|
3106 }
|
|
3107
|
|
3108 BOOL
|
|
3109 qxeWritePrivateProfileSection (const Extbyte * lpAppName, const Extbyte * lpString, const Extbyte * lpFileName)
|
|
3110 {
|
|
3111 if (XEUNICODE_P)
|
|
3112 return WritePrivateProfileSectionW ((LPCWSTR) lpAppName, (LPCWSTR) lpString, (LPCWSTR) lpFileName);
|
|
3113 else
|
|
3114 return WritePrivateProfileSectionA ((LPCSTR) lpAppName, (LPCSTR) lpString, (LPCSTR) lpFileName);
|
|
3115 }
|
|
3116
|
|
3117 DWORD
|
|
3118 qxeGetPrivateProfileSectionNames (Extbyte * lpszReturnBuffer, DWORD nSize, const Extbyte * lpFileName)
|
|
3119 {
|
|
3120 if (XEUNICODE_P)
|
|
3121 return GetPrivateProfileSectionNamesW ((LPWSTR) lpszReturnBuffer, nSize, (LPCWSTR) lpFileName);
|
|
3122 else
|
|
3123 return GetPrivateProfileSectionNamesA ((LPSTR) lpszReturnBuffer, nSize, (LPCSTR) lpFileName);
|
|
3124 }
|
|
3125
|
|
3126 BOOL
|
|
3127 qxeGetPrivateProfileStruct (const Extbyte * lpszSection, const Extbyte * lpszKey, LPVOID lpStruct, UINT uSizeStruct, const Extbyte * szFile)
|
|
3128 {
|
|
3129 if (XEUNICODE_P)
|
|
3130 return GetPrivateProfileStructW ((LPCWSTR) lpszSection, (LPCWSTR) lpszKey, lpStruct, uSizeStruct, (LPCWSTR) szFile);
|
|
3131 else
|
|
3132 return GetPrivateProfileStructA ((LPCSTR) lpszSection, (LPCSTR) lpszKey, lpStruct, uSizeStruct, (LPCSTR) szFile);
|
|
3133 }
|
|
3134
|
|
3135 BOOL
|
|
3136 qxeWritePrivateProfileStruct (const Extbyte * lpszSection, const Extbyte * lpszKey, LPVOID lpStruct, UINT uSizeStruct, const Extbyte * szFile)
|
|
3137 {
|
|
3138 if (XEUNICODE_P)
|
|
3139 return WritePrivateProfileStructW ((LPCWSTR) lpszSection, (LPCWSTR) lpszKey, lpStruct, uSizeStruct, (LPCWSTR) szFile);
|
|
3140 else
|
|
3141 return WritePrivateProfileStructA ((LPCSTR) lpszSection, (LPCSTR) lpszKey, lpStruct, uSizeStruct, (LPCSTR) szFile);
|
|
3142 }
|
|
3143
|
|
3144 UINT
|
|
3145 qxeGetDriveType (const Extbyte * lpRootPathName)
|
|
3146 {
|
|
3147 if (XEUNICODE_P)
|
|
3148 return GetDriveTypeW ((LPCWSTR) lpRootPathName);
|
|
3149 else
|
|
3150 return GetDriveTypeA ((LPCSTR) lpRootPathName);
|
|
3151 }
|
|
3152
|
|
3153 UINT
|
|
3154 qxeGetSystemDirectory (Extbyte * lpBuffer, UINT uSize)
|
|
3155 {
|
|
3156 if (XEUNICODE_P)
|
|
3157 return GetSystemDirectoryW ((LPWSTR) lpBuffer, uSize);
|
|
3158 else
|
|
3159 return GetSystemDirectoryA ((LPSTR) lpBuffer, uSize);
|
|
3160 }
|
|
3161
|
|
3162 DWORD
|
|
3163 qxeGetTempPath (DWORD nBufferLength, Extbyte * lpBuffer)
|
|
3164 {
|
|
3165 if (XEUNICODE_P)
|
|
3166 return GetTempPathW (nBufferLength, (LPWSTR) lpBuffer);
|
|
3167 else
|
|
3168 return GetTempPathA (nBufferLength, (LPSTR) lpBuffer);
|
|
3169 }
|
|
3170
|
|
3171 UINT
|
|
3172 qxeGetTempFileName (const Extbyte * lpPathName, const Extbyte * lpPrefixString, UINT uUnique, Extbyte * lpTempFileName)
|
|
3173 {
|
|
3174 if (XEUNICODE_P)
|
|
3175 return GetTempFileNameW ((LPCWSTR) lpPathName, (LPCWSTR) lpPrefixString, uUnique, (LPWSTR) lpTempFileName);
|
|
3176 else
|
|
3177 return GetTempFileNameA ((LPCSTR) lpPathName, (LPCSTR) lpPrefixString, uUnique, (LPSTR) lpTempFileName);
|
|
3178 }
|
|
3179
|
|
3180 UINT
|
|
3181 qxeGetWindowsDirectory (Extbyte * lpBuffer, UINT uSize)
|
|
3182 {
|
|
3183 if (XEUNICODE_P)
|
|
3184 return GetWindowsDirectoryW ((LPWSTR) lpBuffer, uSize);
|
|
3185 else
|
|
3186 return GetWindowsDirectoryA ((LPSTR) lpBuffer, uSize);
|
|
3187 }
|
|
3188
|
|
3189 BOOL
|
|
3190 qxeSetCurrentDirectory (const Extbyte * lpPathName)
|
|
3191 {
|
|
3192 if (XEUNICODE_P)
|
|
3193 return SetCurrentDirectoryW ((LPCWSTR) lpPathName);
|
|
3194 else
|
|
3195 return SetCurrentDirectoryA ((LPCSTR) lpPathName);
|
|
3196 }
|
|
3197
|
|
3198 DWORD
|
|
3199 qxeGetCurrentDirectory (DWORD nBufferLength, Extbyte * lpBuffer)
|
|
3200 {
|
|
3201 if (XEUNICODE_P)
|
|
3202 return GetCurrentDirectoryW (nBufferLength, (LPWSTR) lpBuffer);
|
|
3203 else
|
|
3204 return GetCurrentDirectoryA (nBufferLength, (LPSTR) lpBuffer);
|
|
3205 }
|
|
3206
|
|
3207 BOOL
|
|
3208 qxeGetDiskFreeSpace (const Extbyte * lpRootPathName, LPDWORD lpSectorsPerCluster, LPDWORD lpBytesPerSector, LPDWORD lpNumberOfFreeClusters, LPDWORD lpTotalNumberOfClusters)
|
|
3209 {
|
|
3210 if (XEUNICODE_P)
|
|
3211 return GetDiskFreeSpaceW ((LPCWSTR) lpRootPathName, lpSectorsPerCluster, lpBytesPerSector, lpNumberOfFreeClusters, lpTotalNumberOfClusters);
|
|
3212 else
|
|
3213 return GetDiskFreeSpaceA ((LPCSTR) lpRootPathName, lpSectorsPerCluster, lpBytesPerSector, lpNumberOfFreeClusters, lpTotalNumberOfClusters);
|
|
3214 }
|
|
3215
|
|
3216 BOOL
|
|
3217 qxeGetDiskFreeSpaceEx (const Extbyte * lpDirectoryName, PULARGE_INTEGER lpFreeBytesAvailableToCaller, PULARGE_INTEGER lpTotalNumberOfBytes, PULARGE_INTEGER lpTotalNumberOfFreeBytes)
|
|
3218 {
|
|
3219 if (XEUNICODE_P)
|
|
3220 return GetDiskFreeSpaceExW ((LPCWSTR) lpDirectoryName, lpFreeBytesAvailableToCaller, lpTotalNumberOfBytes, lpTotalNumberOfFreeBytes);
|
|
3221 else
|
|
3222 return GetDiskFreeSpaceExA ((LPCSTR) lpDirectoryName, lpFreeBytesAvailableToCaller, lpTotalNumberOfBytes, lpTotalNumberOfFreeBytes);
|
|
3223 }
|
|
3224
|
|
3225 BOOL
|
|
3226 qxeCreateDirectory (const Extbyte * lpPathName, LPSECURITY_ATTRIBUTES lpSecurityAttributes)
|
|
3227 {
|
|
3228 if (XEUNICODE_P)
|
|
3229 return CreateDirectoryW ((LPCWSTR) lpPathName, lpSecurityAttributes);
|
|
3230 else
|
|
3231 return CreateDirectoryA ((LPCSTR) lpPathName, lpSecurityAttributes);
|
|
3232 }
|
|
3233
|
|
3234 BOOL
|
|
3235 qxeCreateDirectoryEx (const Extbyte * lpTemplateDirectory, const Extbyte * lpNewDirectory, LPSECURITY_ATTRIBUTES lpSecurityAttributes)
|
|
3236 {
|
|
3237 if (XEUNICODE_P)
|
|
3238 return CreateDirectoryExW ((LPCWSTR) lpTemplateDirectory, (LPCWSTR) lpNewDirectory, lpSecurityAttributes);
|
|
3239 else
|
|
3240 return CreateDirectoryExA ((LPCSTR) lpTemplateDirectory, (LPCSTR) lpNewDirectory, lpSecurityAttributes);
|
|
3241 }
|
|
3242
|
|
3243 BOOL
|
|
3244 qxeRemoveDirectory (const Extbyte * lpPathName)
|
|
3245 {
|
|
3246 if (XEUNICODE_P)
|
|
3247 return RemoveDirectoryW ((LPCWSTR) lpPathName);
|
|
3248 else
|
|
3249 return RemoveDirectoryA ((LPCSTR) lpPathName);
|
|
3250 }
|
|
3251
|
|
3252 DWORD
|
|
3253 qxeGetFullPathName (const Extbyte * lpFileName, DWORD nBufferLength, Extbyte * lpBuffer, Extbyte * * lpFilePart)
|
|
3254 {
|
|
3255 if (XEUNICODE_P)
|
|
3256 return GetFullPathNameW ((LPCWSTR) lpFileName, nBufferLength, (LPWSTR) lpBuffer, (LPWSTR *) lpFilePart);
|
|
3257 else
|
|
3258 return GetFullPathNameA ((LPCSTR) lpFileName, nBufferLength, (LPSTR) lpBuffer, (LPSTR *) lpFilePart);
|
|
3259 }
|
|
3260
|
|
3261 BOOL
|
|
3262 qxeDefineDosDevice (DWORD dwFlags, const Extbyte * lpDeviceName, const Extbyte * lpTargetPath)
|
|
3263 {
|
|
3264 if (XEUNICODE_P)
|
|
3265 return DefineDosDeviceW (dwFlags, (LPCWSTR) lpDeviceName, (LPCWSTR) lpTargetPath);
|
|
3266 else
|
|
3267 return DefineDosDeviceA (dwFlags, (LPCSTR) lpDeviceName, (LPCSTR) lpTargetPath);
|
|
3268 }
|
|
3269
|
|
3270 DWORD
|
|
3271 qxeQueryDosDevice (const Extbyte * lpDeviceName, Extbyte * lpTargetPath, DWORD ucchMax)
|
|
3272 {
|
|
3273 if (XEUNICODE_P)
|
|
3274 return QueryDosDeviceW ((LPCWSTR) lpDeviceName, (LPWSTR) lpTargetPath, ucchMax);
|
|
3275 else
|
|
3276 return QueryDosDeviceA ((LPCSTR) lpDeviceName, (LPSTR) lpTargetPath, ucchMax);
|
|
3277 }
|
|
3278
|
|
3279 HANDLE
|
|
3280 qxeCreateFile (const Extbyte * lpFileName, DWORD dwDesiredAccess, DWORD dwShareMode, LPSECURITY_ATTRIBUTES lpSecurityAttributes, DWORD dwCreationDisposition, DWORD dwFlagsAndAttributes, HANDLE hTemplateFile)
|
|
3281 {
|
|
3282 if (XEUNICODE_P)
|
|
3283 return CreateFileW ((LPCWSTR) lpFileName, dwDesiredAccess, dwShareMode, lpSecurityAttributes, dwCreationDisposition, dwFlagsAndAttributes, hTemplateFile);
|
|
3284 else
|
|
3285 return CreateFileA ((LPCSTR) lpFileName, dwDesiredAccess, dwShareMode, lpSecurityAttributes, dwCreationDisposition, dwFlagsAndAttributes, hTemplateFile);
|
|
3286 }
|
|
3287
|
|
3288 BOOL
|
|
3289 qxeSetFileAttributes (const Extbyte * lpFileName, DWORD dwFileAttributes)
|
|
3290 {
|
|
3291 if (XEUNICODE_P)
|
|
3292 return SetFileAttributesW ((LPCWSTR) lpFileName, dwFileAttributes);
|
|
3293 else
|
|
3294 return SetFileAttributesA ((LPCSTR) lpFileName, dwFileAttributes);
|
|
3295 }
|
|
3296
|
|
3297 DWORD
|
|
3298 qxeGetFileAttributes (const Extbyte * lpFileName)
|
|
3299 {
|
|
3300 if (XEUNICODE_P)
|
|
3301 return GetFileAttributesW ((LPCWSTR) lpFileName);
|
|
3302 else
|
|
3303 return GetFileAttributesA ((LPCSTR) lpFileName);
|
|
3304 }
|
|
3305
|
|
3306 BOOL
|
|
3307 qxeGetFileAttributesEx (const Extbyte * lpFileName, GET_FILEEX_INFO_LEVELS fInfoLevelId, LPVOID lpFileInformation)
|
|
3308 {
|
|
3309 if (XEUNICODE_P)
|
|
3310 return GetFileAttributesExW ((LPCWSTR) lpFileName, fInfoLevelId, lpFileInformation);
|
|
3311 else
|
|
3312 return GetFileAttributesExA ((LPCSTR) lpFileName, fInfoLevelId, lpFileInformation);
|
|
3313 }
|
|
3314
|
|
3315 DWORD
|
|
3316 qxeGetCompressedFileSize (const Extbyte * lpFileName, LPDWORD lpFileSizeHigh)
|
|
3317 {
|
|
3318 if (XEUNICODE_P)
|
|
3319 return GetCompressedFileSizeW ((LPCWSTR) lpFileName, lpFileSizeHigh);
|
|
3320 else
|
|
3321 return GetCompressedFileSizeA ((LPCSTR) lpFileName, lpFileSizeHigh);
|
|
3322 }
|
|
3323
|
|
3324 BOOL
|
|
3325 qxeDeleteFile (const Extbyte * lpFileName)
|
|
3326 {
|
|
3327 if (XEUNICODE_P)
|
|
3328 return DeleteFileW ((LPCWSTR) lpFileName);
|
|
3329 else
|
|
3330 return DeleteFileA ((LPCSTR) lpFileName);
|
|
3331 }
|
|
3332
|
|
3333 /* Error if FindFirstFileEx used: split-sized LPWIN32_FIND_DATA; not used, NT 4.0+ only */
|
|
3334
|
|
3335 /* Skipping FindFirstFile because split-sized LPWIN32_FIND_DATA */
|
|
3336
|
|
3337 /* Skipping FindNextFile because split-sized LPWIN32_FIND_DATA */
|
|
3338
|
|
3339 DWORD
|
|
3340 qxeSearchPath (const Extbyte * lpPath, const Extbyte * lpFileName, const Extbyte * lpExtension, DWORD nBufferLength, Extbyte * lpBuffer, Extbyte * * lpFilePart)
|
|
3341 {
|
|
3342 if (XEUNICODE_P)
|
|
3343 return SearchPathW ((LPCWSTR) lpPath, (LPCWSTR) lpFileName, (LPCWSTR) lpExtension, nBufferLength, (LPWSTR) lpBuffer, (LPWSTR *) lpFilePart);
|
|
3344 else
|
|
3345 return SearchPathA ((LPCSTR) lpPath, (LPCSTR) lpFileName, (LPCSTR) lpExtension, nBufferLength, (LPSTR) lpBuffer, (LPSTR *) lpFilePart);
|
|
3346 }
|
|
3347
|
|
3348 BOOL
|
|
3349 qxeCopyFile (const Extbyte * lpExistingFileName, const Extbyte * lpNewFileName, BOOL bFailIfExists)
|
|
3350 {
|
|
3351 if (XEUNICODE_P)
|
|
3352 return CopyFileW ((LPCWSTR) lpExistingFileName, (LPCWSTR) lpNewFileName, bFailIfExists);
|
|
3353 else
|
|
3354 return CopyFileA ((LPCSTR) lpExistingFileName, (LPCSTR) lpNewFileName, bFailIfExists);
|
|
3355 }
|
|
3356
|
|
3357 /* NOTE: NT 4.0+ only */
|
|
3358 BOOL
|
|
3359 qxeCopyFileEx (const Extbyte * lpExistingFileName, const Extbyte * lpNewFileName, LPPROGRESS_ROUTINE lpProgressRoutine, LPVOID lpData, LPBOOL pbCancel, DWORD dwCopyFlags)
|
|
3360 {
|
|
3361 if (XEUNICODE_P)
|
|
3362 return CopyFileExW ((LPCWSTR) lpExistingFileName, (LPCWSTR) lpNewFileName, lpProgressRoutine, lpData, pbCancel, dwCopyFlags);
|
|
3363 else
|
|
3364 return CopyFileExA ((LPCSTR) lpExistingFileName, (LPCSTR) lpNewFileName, lpProgressRoutine, lpData, pbCancel, dwCopyFlags);
|
|
3365 }
|
|
3366
|
|
3367 BOOL
|
|
3368 qxeMoveFile (const Extbyte * lpExistingFileName, const Extbyte * lpNewFileName)
|
|
3369 {
|
|
3370 if (XEUNICODE_P)
|
|
3371 return MoveFileW ((LPCWSTR) lpExistingFileName, (LPCWSTR) lpNewFileName);
|
|
3372 else
|
|
3373 return MoveFileA ((LPCSTR) lpExistingFileName, (LPCSTR) lpNewFileName);
|
|
3374 }
|
|
3375
|
|
3376 BOOL
|
|
3377 qxeMoveFileEx (const Extbyte * lpExistingFileName, const Extbyte * lpNewFileName, DWORD dwFlags)
|
|
3378 {
|
|
3379 if (XEUNICODE_P)
|
|
3380 return MoveFileExW ((LPCWSTR) lpExistingFileName, (LPCWSTR) lpNewFileName, dwFlags);
|
|
3381 else
|
|
3382 return MoveFileExA ((LPCSTR) lpExistingFileName, (LPCSTR) lpNewFileName, dwFlags);
|
|
3383 }
|
|
3384
|
|
3385 /* Error if MoveFileWithProgress used: NT 5.0+ only */
|
|
3386
|
|
3387 /* Error if CreateHardLink used: NT 5.0+ only */
|
|
3388
|
|
3389 HANDLE
|
|
3390 qxeCreateNamedPipe (const Extbyte * lpName, DWORD dwOpenMode, DWORD dwPipeMode, DWORD nMaxInstances, DWORD nOutBufferSize, DWORD nInBufferSize, DWORD nDefaultTimeOut, LPSECURITY_ATTRIBUTES lpSecurityAttributes)
|
|
3391 {
|
|
3392 if (XEUNICODE_P)
|
|
3393 return CreateNamedPipeW ((LPCWSTR) lpName, dwOpenMode, dwPipeMode, nMaxInstances, nOutBufferSize, nInBufferSize, nDefaultTimeOut, lpSecurityAttributes);
|
|
3394 else
|
|
3395 return CreateNamedPipeA ((LPCSTR) lpName, dwOpenMode, dwPipeMode, nMaxInstances, nOutBufferSize, nInBufferSize, nDefaultTimeOut, lpSecurityAttributes);
|
|
3396 }
|
|
3397
|
|
3398 BOOL
|
|
3399 qxeGetNamedPipeHandleState (HANDLE hNamedPipe, LPDWORD lpState, LPDWORD lpCurInstances, LPDWORD lpMaxCollectionCount, LPDWORD lpCollectDataTimeout, Extbyte * lpUserName, DWORD nMaxUserNameSize)
|
|
3400 {
|
|
3401 if (XEUNICODE_P)
|
|
3402 return GetNamedPipeHandleStateW (hNamedPipe, lpState, lpCurInstances, lpMaxCollectionCount, lpCollectDataTimeout, (LPWSTR) lpUserName, nMaxUserNameSize);
|
|
3403 else
|
|
3404 return GetNamedPipeHandleStateA (hNamedPipe, lpState, lpCurInstances, lpMaxCollectionCount, lpCollectDataTimeout, (LPSTR) lpUserName, nMaxUserNameSize);
|
|
3405 }
|
|
3406
|
|
3407 BOOL
|
|
3408 qxeCallNamedPipe (const Extbyte * lpNamedPipeName, LPVOID lpInBuffer, DWORD nInBufferSize, LPVOID lpOutBuffer, DWORD nOutBufferSize, LPDWORD lpBytesRead, DWORD nTimeOut)
|
|
3409 {
|
|
3410 if (XEUNICODE_P)
|
|
3411 return CallNamedPipeW ((LPCWSTR) lpNamedPipeName, lpInBuffer, nInBufferSize, lpOutBuffer, nOutBufferSize, lpBytesRead, nTimeOut);
|
|
3412 else
|
|
3413 return CallNamedPipeA ((LPCSTR) lpNamedPipeName, lpInBuffer, nInBufferSize, lpOutBuffer, nOutBufferSize, lpBytesRead, nTimeOut);
|
|
3414 }
|
|
3415
|
|
3416 BOOL
|
|
3417 qxeWaitNamedPipe (const Extbyte * lpNamedPipeName, DWORD nTimeOut)
|
|
3418 {
|
|
3419 if (XEUNICODE_P)
|
|
3420 return WaitNamedPipeW ((LPCWSTR) lpNamedPipeName, nTimeOut);
|
|
3421 else
|
|
3422 return WaitNamedPipeA ((LPCSTR) lpNamedPipeName, nTimeOut);
|
|
3423 }
|
|
3424
|
|
3425 BOOL
|
|
3426 qxeSetVolumeLabel (const Extbyte * lpRootPathName, const Extbyte * lpVolumeName)
|
|
3427 {
|
|
3428 if (XEUNICODE_P)
|
|
3429 return SetVolumeLabelW ((LPCWSTR) lpRootPathName, (LPCWSTR) lpVolumeName);
|
|
3430 else
|
|
3431 return SetVolumeLabelA ((LPCSTR) lpRootPathName, (LPCSTR) lpVolumeName);
|
|
3432 }
|
|
3433
|
|
3434 BOOL
|
|
3435 qxeGetVolumeInformation (const Extbyte * lpRootPathName, Extbyte * lpVolumeNameBuffer, DWORD nVolumeNameSize, LPDWORD lpVolumeSerialNumber, LPDWORD lpMaximumComponentLength, LPDWORD lpFileSystemFlags, Extbyte * lpFileSystemNameBuffer, DWORD nFileSystemNameSize)
|
|
3436 {
|
|
3437 if (XEUNICODE_P)
|
|
3438 return GetVolumeInformationW ((LPCWSTR) lpRootPathName, (LPWSTR) lpVolumeNameBuffer, nVolumeNameSize, lpVolumeSerialNumber, lpMaximumComponentLength, lpFileSystemFlags, (LPWSTR) lpFileSystemNameBuffer, nFileSystemNameSize);
|
|
3439 else
|
|
3440 return GetVolumeInformationA ((LPCSTR) lpRootPathName, (LPSTR) lpVolumeNameBuffer, nVolumeNameSize, lpVolumeSerialNumber, lpMaximumComponentLength, lpFileSystemFlags, (LPSTR) lpFileSystemNameBuffer, nFileSystemNameSize);
|
|
3441 }
|
|
3442
|
|
3443 BOOL
|
|
3444 qxeClearEventLog (HANDLE hEventLog, const Extbyte * lpBackupFileName)
|
|
3445 {
|
|
3446 if (XEUNICODE_P)
|
|
3447 return ClearEventLogW (hEventLog, (LPCWSTR) lpBackupFileName);
|
|
3448 else
|
|
3449 return ClearEventLogA (hEventLog, (LPCSTR) lpBackupFileName);
|
|
3450 }
|
|
3451
|
|
3452 BOOL
|
|
3453 qxeBackupEventLog (HANDLE hEventLog, const Extbyte * lpBackupFileName)
|
|
3454 {
|
|
3455 if (XEUNICODE_P)
|
|
3456 return BackupEventLogW (hEventLog, (LPCWSTR) lpBackupFileName);
|
|
3457 else
|
|
3458 return BackupEventLogA (hEventLog, (LPCSTR) lpBackupFileName);
|
|
3459 }
|
|
3460
|
|
3461 HANDLE
|
|
3462 qxeOpenEventLog (const Extbyte * lpUNCServerName, const Extbyte * lpSourceName)
|
|
3463 {
|
|
3464 if (XEUNICODE_P)
|
|
3465 return OpenEventLogW ((LPCWSTR) lpUNCServerName, (LPCWSTR) lpSourceName);
|
|
3466 else
|
|
3467 return OpenEventLogA ((LPCSTR) lpUNCServerName, (LPCSTR) lpSourceName);
|
|
3468 }
|
|
3469
|
|
3470 HANDLE
|
|
3471 qxeRegisterEventSource (const Extbyte * lpUNCServerName, const Extbyte * lpSourceName)
|
|
3472 {
|
|
3473 if (XEUNICODE_P)
|
|
3474 return RegisterEventSourceW ((LPCWSTR) lpUNCServerName, (LPCWSTR) lpSourceName);
|
|
3475 else
|
|
3476 return RegisterEventSourceA ((LPCSTR) lpUNCServerName, (LPCSTR) lpSourceName);
|
|
3477 }
|
|
3478
|
|
3479 HANDLE
|
|
3480 qxeOpenBackupEventLog (const Extbyte * lpUNCServerName, const Extbyte * lpFileName)
|
|
3481 {
|
|
3482 if (XEUNICODE_P)
|
|
3483 return OpenBackupEventLogW ((LPCWSTR) lpUNCServerName, (LPCWSTR) lpFileName);
|
|
3484 else
|
|
3485 return OpenBackupEventLogA ((LPCSTR) lpUNCServerName, (LPCSTR) lpFileName);
|
|
3486 }
|
|
3487
|
|
3488 BOOL
|
|
3489 qxeReadEventLog (HANDLE hEventLog, DWORD dwReadFlags, DWORD dwRecordOffset, LPVOID lpBuffer, DWORD nNumberOfBytesToRead, DWORD * pnBytesRead, DWORD * pnMinNumberOfBytesNeeded)
|
|
3490 {
|
|
3491 if (XEUNICODE_P)
|
|
3492 return ReadEventLogW (hEventLog, dwReadFlags, dwRecordOffset, lpBuffer, nNumberOfBytesToRead, pnBytesRead, pnMinNumberOfBytesNeeded);
|
|
3493 else
|
|
3494 return ReadEventLogA (hEventLog, dwReadFlags, dwRecordOffset, lpBuffer, nNumberOfBytesToRead, pnBytesRead, pnMinNumberOfBytesNeeded);
|
|
3495 }
|
|
3496
|
|
3497 BOOL
|
|
3498 qxeReportEvent (HANDLE hEventLog, WORD wType, WORD wCategory, DWORD dwEventID, PSID lpUserSid, WORD wNumStrings, DWORD dwDataSize, const Extbyte * * lpStrings, LPVOID lpRawData)
|
|
3499 {
|
|
3500 if (XEUNICODE_P)
|
|
3501 return ReportEventW (hEventLog, wType, wCategory, dwEventID, lpUserSid, wNumStrings, dwDataSize, (LPCWSTR *) lpStrings, lpRawData);
|
|
3502 else
|
|
3503 return ReportEventA (hEventLog, wType, wCategory, dwEventID, lpUserSid, wNumStrings, dwDataSize, (LPCSTR *) lpStrings, lpRawData);
|
|
3504 }
|
|
3505
|
|
3506 BOOL
|
|
3507 qxeAccessCheckAndAuditAlarm (const Extbyte * SubsystemName, LPVOID HandleId, Extbyte * ObjectTypeName, Extbyte * ObjectName, PSECURITY_DESCRIPTOR SecurityDescriptor, DWORD DesiredAccess, PGENERIC_MAPPING GenericMapping, BOOL ObjectCreation, LPDWORD GrantedAccess, LPBOOL AccessStatus, LPBOOL pfGenerateOnClose)
|
|
3508 {
|
|
3509 if (XEUNICODE_P)
|
|
3510 return AccessCheckAndAuditAlarmW ((LPCWSTR) SubsystemName, HandleId, (LPWSTR) ObjectTypeName, (LPWSTR) ObjectName, SecurityDescriptor, DesiredAccess, GenericMapping, ObjectCreation, GrantedAccess, AccessStatus, pfGenerateOnClose);
|
|
3511 else
|
|
3512 return AccessCheckAndAuditAlarmA ((LPCSTR) SubsystemName, HandleId, (LPSTR) ObjectTypeName, (LPSTR) ObjectName, SecurityDescriptor, DesiredAccess, GenericMapping, ObjectCreation, GrantedAccess, AccessStatus, pfGenerateOnClose);
|
|
3513 }
|
|
3514
|
|
3515 /* Error if AccessCheckByTypeAndAuditAlarm used: NT 5.0+ only */
|
|
3516
|
|
3517 /* Error if AccessCheckByTypeResultListAndAuditAlarm used: NT 5.0+ only */
|
|
3518
|
|
3519 BOOL
|
|
3520 qxeObjectOpenAuditAlarm (const Extbyte * SubsystemName, LPVOID HandleId, Extbyte * ObjectTypeName, Extbyte * ObjectName, PSECURITY_DESCRIPTOR pSecurityDescriptor, HANDLE ClientToken, DWORD DesiredAccess, DWORD GrantedAccess, PPRIVILEGE_SET Privileges, BOOL ObjectCreation, BOOL AccessGranted, LPBOOL GenerateOnClose)
|
|
3521 {
|
|
3522 if (XEUNICODE_P)
|
|
3523 return ObjectOpenAuditAlarmW ((LPCWSTR) SubsystemName, HandleId, (LPWSTR) ObjectTypeName, (LPWSTR) ObjectName, pSecurityDescriptor, ClientToken, DesiredAccess, GrantedAccess, Privileges, ObjectCreation, AccessGranted, GenerateOnClose);
|
|
3524 else
|
|
3525 return ObjectOpenAuditAlarmA ((LPCSTR) SubsystemName, HandleId, (LPSTR) ObjectTypeName, (LPSTR) ObjectName, pSecurityDescriptor, ClientToken, DesiredAccess, GrantedAccess, Privileges, ObjectCreation, AccessGranted, GenerateOnClose);
|
|
3526 }
|
|
3527
|
|
3528 BOOL
|
|
3529 qxeObjectPrivilegeAuditAlarm (const Extbyte * SubsystemName, LPVOID HandleId, HANDLE ClientToken, DWORD DesiredAccess, PPRIVILEGE_SET Privileges, BOOL AccessGranted)
|
|
3530 {
|
|
3531 if (XEUNICODE_P)
|
|
3532 return ObjectPrivilegeAuditAlarmW ((LPCWSTR) SubsystemName, HandleId, ClientToken, DesiredAccess, Privileges, AccessGranted);
|
|
3533 else
|
|
3534 return ObjectPrivilegeAuditAlarmA ((LPCSTR) SubsystemName, HandleId, ClientToken, DesiredAccess, Privileges, AccessGranted);
|
|
3535 }
|
|
3536
|
|
3537 BOOL
|
|
3538 qxeObjectCloseAuditAlarm (const Extbyte * SubsystemName, LPVOID HandleId, BOOL GenerateOnClose)
|
|
3539 {
|
|
3540 if (XEUNICODE_P)
|
|
3541 return ObjectCloseAuditAlarmW ((LPCWSTR) SubsystemName, HandleId, GenerateOnClose);
|
|
3542 else
|
|
3543 return ObjectCloseAuditAlarmA ((LPCSTR) SubsystemName, HandleId, GenerateOnClose);
|
|
3544 }
|
|
3545
|
|
3546 BOOL
|
|
3547 qxeObjectDeleteAuditAlarm (const Extbyte * SubsystemName, LPVOID HandleId, BOOL GenerateOnClose)
|
|
3548 {
|
|
3549 if (XEUNICODE_P)
|
|
3550 return ObjectDeleteAuditAlarmW ((LPCWSTR) SubsystemName, HandleId, GenerateOnClose);
|
|
3551 else
|
|
3552 return ObjectDeleteAuditAlarmA ((LPCSTR) SubsystemName, HandleId, GenerateOnClose);
|
|
3553 }
|
|
3554
|
|
3555 BOOL
|
|
3556 qxePrivilegedServiceAuditAlarm (const Extbyte * SubsystemName, const Extbyte * ServiceName, HANDLE ClientToken, PPRIVILEGE_SET Privileges, BOOL AccessGranted)
|
|
3557 {
|
|
3558 if (XEUNICODE_P)
|
|
3559 return PrivilegedServiceAuditAlarmW ((LPCWSTR) SubsystemName, (LPCWSTR) ServiceName, ClientToken, Privileges, AccessGranted);
|
|
3560 else
|
|
3561 return PrivilegedServiceAuditAlarmA ((LPCSTR) SubsystemName, (LPCSTR) ServiceName, ClientToken, Privileges, AccessGranted);
|
|
3562 }
|
|
3563
|
|
3564 BOOL
|
|
3565 qxeSetFileSecurity (const Extbyte * lpFileName, SECURITY_INFORMATION SecurityInformation, PSECURITY_DESCRIPTOR pSecurityDescriptor)
|
|
3566 {
|
|
3567 if (XEUNICODE_P)
|
|
3568 return SetFileSecurityW ((LPCWSTR) lpFileName, SecurityInformation, pSecurityDescriptor);
|
|
3569 else
|
|
3570 return SetFileSecurityA ((LPCSTR) lpFileName, SecurityInformation, pSecurityDescriptor);
|
|
3571 }
|
|
3572
|
|
3573 BOOL
|
|
3574 qxeGetFileSecurity (const Extbyte * lpFileName, SECURITY_INFORMATION RequestedInformation, PSECURITY_DESCRIPTOR pSecurityDescriptor, DWORD nLength, LPDWORD lpnLengthNeeded)
|
|
3575 {
|
|
3576 if (XEUNICODE_P)
|
|
3577 return GetFileSecurityW ((LPCWSTR) lpFileName, RequestedInformation, pSecurityDescriptor, nLength, lpnLengthNeeded);
|
|
3578 else
|
|
3579 return GetFileSecurityA ((LPCSTR) lpFileName, RequestedInformation, pSecurityDescriptor, nLength, lpnLengthNeeded);
|
|
3580 }
|
|
3581
|
|
3582 HANDLE
|
|
3583 qxeFindFirstChangeNotification (const Extbyte * lpPathName, BOOL bWatchSubtree, DWORD dwNotifyFilter)
|
|
3584 {
|
|
3585 if (XEUNICODE_P)
|
|
3586 return FindFirstChangeNotificationW ((LPCWSTR) lpPathName, bWatchSubtree, dwNotifyFilter);
|
|
3587 else
|
|
3588 return FindFirstChangeNotificationA ((LPCSTR) lpPathName, bWatchSubtree, dwNotifyFilter);
|
|
3589 }
|
|
3590
|
|
3591 /* Error if ReadDirectoryChanges used: Unicode-only */
|
|
3592
|
|
3593 BOOL
|
|
3594 qxeIsBadStringPtr (const Extbyte * lpsz, UINT ucchMax)
|
|
3595 {
|
|
3596 if (XEUNICODE_P)
|
|
3597 return IsBadStringPtrW ((LPCWSTR) lpsz, ucchMax);
|
|
3598 else
|
|
3599 return IsBadStringPtrA ((LPCSTR) lpsz, ucchMax);
|
|
3600 }
|
|
3601
|
|
3602 BOOL
|
|
3603 qxeLookupAccountSid (const Extbyte * lpSystemName, PSID Sid, Extbyte * Name, LPDWORD cbName, Extbyte * ReferencedDomainName, LPDWORD cbReferencedDomainName, PSID_NAME_USE peUse)
|
|
3604 {
|
|
3605 if (XEUNICODE_P)
|
|
3606 return LookupAccountSidW ((LPCWSTR) lpSystemName, Sid, (LPWSTR) Name, cbName, (LPWSTR) ReferencedDomainName, cbReferencedDomainName, peUse);
|
|
3607 else
|
|
3608 return LookupAccountSidA ((LPCSTR) lpSystemName, Sid, (LPSTR) Name, cbName, (LPSTR) ReferencedDomainName, cbReferencedDomainName, peUse);
|
|
3609 }
|
|
3610
|
|
3611 BOOL
|
|
3612 qxeLookupAccountName (const Extbyte * lpSystemName, const Extbyte * lpAccountName, PSID Sid, LPDWORD cbSid, Extbyte * ReferencedDomainName, LPDWORD cbReferencedDomainName, PSID_NAME_USE peUse)
|
|
3613 {
|
|
3614 if (XEUNICODE_P)
|
|
3615 return LookupAccountNameW ((LPCWSTR) lpSystemName, (LPCWSTR) lpAccountName, Sid, cbSid, (LPWSTR) ReferencedDomainName, cbReferencedDomainName, peUse);
|
|
3616 else
|
|
3617 return LookupAccountNameA ((LPCSTR) lpSystemName, (LPCSTR) lpAccountName, Sid, cbSid, (LPSTR) ReferencedDomainName, cbReferencedDomainName, peUse);
|
|
3618 }
|
|
3619
|
|
3620 BOOL
|
|
3621 qxeLookupPrivilegeValue (const Extbyte * lpSystemName, const Extbyte * lpName, PLUID lpLuid)
|
|
3622 {
|
|
3623 if (XEUNICODE_P)
|
|
3624 return LookupPrivilegeValueW ((LPCWSTR) lpSystemName, (LPCWSTR) lpName, lpLuid);
|
|
3625 else
|
|
3626 return LookupPrivilegeValueA ((LPCSTR) lpSystemName, (LPCSTR) lpName, lpLuid);
|
|
3627 }
|
|
3628
|
|
3629 BOOL
|
|
3630 qxeLookupPrivilegeName (const Extbyte * lpSystemName, PLUID lpLuid, Extbyte * lpName, LPDWORD cbName)
|
|
3631 {
|
|
3632 if (XEUNICODE_P)
|
|
3633 return LookupPrivilegeNameW ((LPCWSTR) lpSystemName, lpLuid, (LPWSTR) lpName, cbName);
|
|
3634 else
|
|
3635 return LookupPrivilegeNameA ((LPCSTR) lpSystemName, lpLuid, (LPSTR) lpName, cbName);
|
|
3636 }
|
|
3637
|
|
3638 BOOL
|
|
3639 qxeLookupPrivilegeDisplayName (const Extbyte * lpSystemName, const Extbyte * lpName, Extbyte * lpDisplayName, LPDWORD cbDisplayName, LPDWORD lpLanguageId)
|
|
3640 {
|
|
3641 if (XEUNICODE_P)
|
|
3642 return LookupPrivilegeDisplayNameW ((LPCWSTR) lpSystemName, (LPCWSTR) lpName, (LPWSTR) lpDisplayName, cbDisplayName, lpLanguageId);
|
|
3643 else
|
|
3644 return LookupPrivilegeDisplayNameA ((LPCSTR) lpSystemName, (LPCSTR) lpName, (LPSTR) lpDisplayName, cbDisplayName, lpLanguageId);
|
|
3645 }
|
|
3646
|
|
3647 BOOL
|
|
3648 qxeBuildCommDCB (const Extbyte * lpDef, LPDCB lpDCB)
|
|
3649 {
|
|
3650 if (XEUNICODE_P)
|
|
3651 return BuildCommDCBW ((LPCWSTR) lpDef, lpDCB);
|
|
3652 else
|
|
3653 return BuildCommDCBA ((LPCSTR) lpDef, lpDCB);
|
|
3654 }
|
|
3655
|
|
3656 BOOL
|
|
3657 qxeBuildCommDCBAndTimeouts (const Extbyte * lpDef, LPDCB lpDCB, LPCOMMTIMEOUTS lpCommTimeouts)
|
|
3658 {
|
|
3659 if (XEUNICODE_P)
|
|
3660 return BuildCommDCBAndTimeoutsW ((LPCWSTR) lpDef, lpDCB, lpCommTimeouts);
|
|
3661 else
|
|
3662 return BuildCommDCBAndTimeoutsA ((LPCSTR) lpDef, lpDCB, lpCommTimeouts);
|
|
3663 }
|
|
3664
|
|
3665 BOOL
|
|
3666 qxeCommConfigDialog (const Extbyte * lpszName, HWND hWnd, LPCOMMCONFIG lpCC)
|
|
3667 {
|
|
3668 if (XEUNICODE_P)
|
|
3669 return CommConfigDialogW ((LPCWSTR) lpszName, hWnd, lpCC);
|
|
3670 else
|
|
3671 return CommConfigDialogA ((LPCSTR) lpszName, hWnd, lpCC);
|
|
3672 }
|
|
3673
|
|
3674 BOOL
|
|
3675 qxeGetDefaultCommConfig (const Extbyte * lpszName, LPCOMMCONFIG lpCC, LPDWORD lpdwSize)
|
|
3676 {
|
|
3677 if (XEUNICODE_P)
|
|
3678 return GetDefaultCommConfigW ((LPCWSTR) lpszName, lpCC, lpdwSize);
|
|
3679 else
|
|
3680 return GetDefaultCommConfigA ((LPCSTR) lpszName, lpCC, lpdwSize);
|
|
3681 }
|
|
3682
|
|
3683 BOOL
|
|
3684 qxeSetDefaultCommConfig (const Extbyte * lpszName, LPCOMMCONFIG lpCC, DWORD dwSize)
|
|
3685 {
|
|
3686 if (XEUNICODE_P)
|
|
3687 return SetDefaultCommConfigW ((LPCWSTR) lpszName, lpCC, dwSize);
|
|
3688 else
|
|
3689 return SetDefaultCommConfigA ((LPCSTR) lpszName, lpCC, dwSize);
|
|
3690 }
|
|
3691
|
|
3692 BOOL
|
|
3693 qxeGetComputerName (Extbyte * lpBuffer, LPDWORD nSize)
|
|
3694 {
|
|
3695 if (XEUNICODE_P)
|
|
3696 return GetComputerNameW ((LPWSTR) lpBuffer, nSize);
|
|
3697 else
|
|
3698 return GetComputerNameA ((LPSTR) lpBuffer, nSize);
|
|
3699 }
|
|
3700
|
|
3701 BOOL
|
|
3702 qxeSetComputerName (const Extbyte * lpComputerName)
|
|
3703 {
|
|
3704 if (XEUNICODE_P)
|
|
3705 return SetComputerNameW ((LPCWSTR) lpComputerName);
|
|
3706 else
|
|
3707 return SetComputerNameA ((LPCSTR) lpComputerName);
|
|
3708 }
|
|
3709
|
|
3710 BOOL
|
|
3711 qxeGetUserName (Extbyte * lpBuffer, LPDWORD nSize)
|
|
3712 {
|
|
3713 if (XEUNICODE_P)
|
|
3714 return GetUserNameW ((LPWSTR) lpBuffer, nSize);
|
|
3715 else
|
|
3716 return GetUserNameA ((LPSTR) lpBuffer, nSize);
|
|
3717 }
|
|
3718
|
|
3719 BOOL
|
|
3720 qxeLogonUser (Extbyte * lpszUsername, Extbyte * lpszDomain, Extbyte * lpszPassword, DWORD dwLogonType, DWORD dwLogonProvider, PHANDLE phToken)
|
|
3721 {
|
|
3722 if (XEUNICODE_P)
|
|
3723 return LogonUserW ((LPWSTR) lpszUsername, (LPWSTR) lpszDomain, (LPWSTR) lpszPassword, dwLogonType, dwLogonProvider, phToken);
|
|
3724 else
|
|
3725 return LogonUserA ((LPSTR) lpszUsername, (LPSTR) lpszDomain, (LPSTR) lpszPassword, dwLogonType, dwLogonProvider, phToken);
|
|
3726 }
|
|
3727
|
|
3728 BOOL
|
|
3729 qxeCreateProcessAsUser (HANDLE hToken, const Extbyte * lpApplicationName, Extbyte * lpCommandLine, LPSECURITY_ATTRIBUTES lpProcessAttributes, LPSECURITY_ATTRIBUTES lpThreadAttributes, BOOL bInheritHandles, DWORD dwCreationFlags, LPVOID lpEnvironment, const Extbyte * lpCurrentDirectory, LPSTARTUPINFOW lpStartupInfo, LPPROCESS_INFORMATION lpProcessInformation)
|
|
3730 {
|
|
3731 if (XEUNICODE_P)
|
|
3732 return CreateProcessAsUserW (hToken, (LPCWSTR) lpApplicationName, (LPWSTR) lpCommandLine, lpProcessAttributes, lpThreadAttributes, bInheritHandles, dwCreationFlags, lpEnvironment, (LPCWSTR) lpCurrentDirectory, lpStartupInfo, lpProcessInformation);
|
|
3733 else
|
|
3734 return CreateProcessAsUserA (hToken, (LPCSTR) lpApplicationName, (LPSTR) lpCommandLine, lpProcessAttributes, lpThreadAttributes, bInheritHandles, dwCreationFlags, lpEnvironment, (LPCSTR) lpCurrentDirectory, (LPSTARTUPINFOA) lpStartupInfo, lpProcessInformation);
|
|
3735 }
|
|
3736
|
|
3737 /* Error if GetCurrentHwProfile used: split-sized LPHW_PROFILE_INFO; NT 4.0+ only */
|
|
3738
|
|
3739 /* Error if GetVersionEx used: split-sized LPOSVERSIONINFO */
|
|
3740
|
|
3741 /* Error if CreateJobObject used: NT 5.0+ only */
|
|
3742
|
|
3743 /* Error if OpenJobObject used: NT 5.0+ only */
|
|
3744
|
|
3745
|
|
3746 /*----------------------------------------------------------------------*/
|
|
3747 /* Processing file COMMDLG.H */
|
|
3748 /*----------------------------------------------------------------------*/
|
|
3749
|
|
3750 BOOL
|
|
3751 qxeGetOpenFileName (LPOPENFILENAMEW arg1)
|
|
3752 {
|
|
3753 if (XEUNICODE_P)
|
|
3754 return GetOpenFileNameW (arg1);
|
|
3755 else
|
|
3756 return GetOpenFileNameA ((LPOPENFILENAMEA) arg1);
|
|
3757 }
|
|
3758
|
|
3759 BOOL
|
|
3760 qxeGetSaveFileName (LPOPENFILENAMEW arg1)
|
|
3761 {
|
|
3762 if (XEUNICODE_P)
|
|
3763 return GetSaveFileNameW (arg1);
|
|
3764 else
|
|
3765 return GetSaveFileNameA ((LPOPENFILENAMEA) arg1);
|
|
3766 }
|
|
3767
|
|
3768 short
|
|
3769 qxeGetFileTitle (const Extbyte * arg1, Extbyte * arg2, WORD arg3)
|
|
3770 {
|
|
3771 if (XEUNICODE_P)
|
|
3772 return GetFileTitleW ((LPCWSTR) arg1, (LPWSTR) arg2, arg3);
|
|
3773 else
|
|
3774 return GetFileTitleA ((LPCSTR) arg1, (LPSTR) arg2, arg3);
|
|
3775 }
|
|
3776
|
|
3777 BOOL
|
|
3778 qxeChooseColor (LPCHOOSECOLORW arg1)
|
|
3779 {
|
|
3780 if (XEUNICODE_P)
|
|
3781 return ChooseColorW (arg1);
|
|
3782 else
|
|
3783 return ChooseColorA ((LPCHOOSECOLORA) arg1);
|
|
3784 }
|
|
3785
|
|
3786 HWND
|
|
3787 qxeFindText (LPFINDREPLACEW arg1)
|
|
3788 {
|
|
3789 if (XEUNICODE_P)
|
|
3790 return FindTextW (arg1);
|
|
3791 else
|
|
3792 return FindTextA ((LPFINDREPLACEA) arg1);
|
|
3793 }
|
|
3794
|
|
3795 HWND
|
|
3796 qxeReplaceText (LPFINDREPLACEW arg1)
|
|
3797 {
|
|
3798 if (XEUNICODE_P)
|
|
3799 return ReplaceTextW (arg1);
|
|
3800 else
|
|
3801 return ReplaceTextA ((LPFINDREPLACEA) arg1);
|
|
3802 }
|
|
3803
|
|
3804 /* Error if AfxReplaceText used: mac only */
|
|
3805
|
|
3806 /* Error if ChooseFont used: split-sized LPLOGFONT in LPCHOOSEFONT */
|
|
3807
|
|
3808 /* Skipping PrintDlg because LPPRINTDLG with split-sized DEVMODE handle */
|
|
3809
|
|
3810 /* Skipping PageSetupDlg because LPPAGESETUPDLG with split-sized DEVMODE handle */
|
|
3811
|
|
3812
|
|
3813 /*----------------------------------------------------------------------*/
|
|
3814 /* Processing file SHLOBJ.H */
|
|
3815 /*----------------------------------------------------------------------*/
|
|
3816
|
|
3817 BOOL
|
|
3818 qxeSHGetPathFromIDList (LPCITEMIDLIST pidl, Extbyte * pszPath)
|
|
3819 {
|
|
3820 if (XEUNICODE_P)
|
|
3821 return SHGetPathFromIDListW (pidl, (LPWSTR) pszPath);
|
|
3822 else
|
|
3823 return SHGetPathFromIDListA (pidl, (LPSTR) pszPath);
|
|
3824 }
|
|
3825
|
778
|
3826 /* Skipping SHGetSpecialFolderPath because error in Cygwin prototype, missing from Cygwin libraries */
|
771
|
3827
|
|
3828 /* Skipping SHBrowseForFolder because need to intercept callback for SendMessage */
|
|
3829
|
778
|
3830 /* Skipping SHGetDataFromIDList because split-sized WIN32_FIND_DATA or split-simple NETRESOURCE, missing from Cygwin libraries */
|
771
|
3831
|
|
3832
|
|
3833 /*----------------------------------------------------------------------*/
|
|
3834 /* Processing file IME.H */
|
|
3835 /*----------------------------------------------------------------------*/
|
|
3836
|
|
3837 /* Error if SendIMEMessageEx used: obsolete, no docs available */
|
|
3838
|
|
3839
|
|
3840 /*----------------------------------------------------------------------*/
|
|
3841 /* Processing file WINGDI.H */
|
|
3842 /*----------------------------------------------------------------------*/
|
|
3843
|
|
3844 int
|
|
3845 qxeAddFontResource (const Extbyte * arg1)
|
|
3846 {
|
|
3847 if (XEUNICODE_P)
|
|
3848 return AddFontResourceW ((LPCWSTR) arg1);
|
|
3849 else
|
|
3850 return AddFontResourceA ((LPCSTR) arg1);
|
|
3851 }
|
|
3852
|
|
3853 HMETAFILE
|
|
3854 qxeCopyMetaFile (HMETAFILE arg1, const Extbyte * arg2)
|
|
3855 {
|
|
3856 if (XEUNICODE_P)
|
|
3857 return CopyMetaFileW (arg1, (LPCWSTR) arg2);
|
|
3858 else
|
|
3859 return CopyMetaFileA (arg1, (LPCSTR) arg2);
|
|
3860 }
|
|
3861
|
|
3862 /* Skipping CreateDC because split-sized DEVMODE */
|
|
3863
|
|
3864 /* Skipping CreateFontIndirect because split-sized LOGFONT */
|
|
3865
|
|
3866 HFONT
|
|
3867 qxeCreateFont (int arg1, int arg2, int arg3, int arg4, int arg5, DWORD arg6, DWORD arg7, DWORD arg8, DWORD arg9, DWORD arg10, DWORD arg11, DWORD arg12, DWORD arg13, const Extbyte * arg14)
|
|
3868 {
|
|
3869 if (XEUNICODE_P)
|
|
3870 return CreateFontW (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, (LPCWSTR) arg14);
|
|
3871 else
|
|
3872 return CreateFontA (arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12, arg13, (LPCSTR) arg14);
|
|
3873 }
|
|
3874
|
|
3875 /* Skipping CreateIC because split-sized DEVMODE */
|
|
3876
|
|
3877 HDC
|
|
3878 qxeCreateMetaFile (const Extbyte * arg1)
|
|
3879 {
|
|
3880 if (XEUNICODE_P)
|
|
3881 return CreateMetaFileW ((LPCWSTR) arg1);
|
|
3882 else
|
|
3883 return CreateMetaFileA ((LPCSTR) arg1);
|
|
3884 }
|
|
3885
|
|
3886 BOOL
|
|
3887 qxeCreateScalableFontResource (DWORD arg1, const Extbyte * arg2, const Extbyte * arg3, const Extbyte * arg4)
|
|
3888 {
|
|
3889 if (XEUNICODE_P)
|
|
3890 return CreateScalableFontResourceW (arg1, (LPCWSTR) arg2, (LPCWSTR) arg3, (LPCWSTR) arg4);
|
|
3891 else
|
|
3892 return CreateScalableFontResourceA (arg1, (LPCSTR) arg2, (LPCSTR) arg3, (LPCSTR) arg4);
|
|
3893 }
|
|
3894
|
|
3895 /* Skipping DeviceCapabilities because split-sized DEVMODE */
|
|
3896
|
|
3897 /* Skipping EnumFontFamiliesEx because split-complex FONTENUMPROC; NT 4.0+ only */
|
|
3898
|
|
3899 /* Error if EnumFontFamilies used: split-complex FONTENUMPROC */
|
|
3900
|
|
3901 /* Error if EnumFonts used: split-complex FONTENUMPROC */
|
|
3902
|
|
3903 BOOL
|
|
3904 qxeGetCharWidth (HDC arg1, UINT arg2, UINT arg3, LPINT arg4)
|
|
3905 {
|
|
3906 if (XEUNICODE_P)
|
|
3907 return GetCharWidthW (arg1, arg2, arg3, arg4);
|
|
3908 else
|
|
3909 return GetCharWidthA (arg1, arg2, arg3, arg4);
|
|
3910 }
|
|
3911
|
|
3912 BOOL
|
|
3913 qxeGetCharWidth32 (HDC arg1, UINT arg2, UINT arg3, LPINT arg4)
|
|
3914 {
|
|
3915 if (XEUNICODE_P)
|
|
3916 return GetCharWidth32W (arg1, arg2, arg3, arg4);
|
|
3917 else
|
|
3918 return GetCharWidth32A (arg1, arg2, arg3, arg4);
|
|
3919 }
|
|
3920
|
|
3921 BOOL
|
|
3922 qxeGetCharWidthFloat (HDC arg1, UINT arg2, UINT arg3, PFLOAT arg4)
|
|
3923 {
|
|
3924 if (XEUNICODE_P)
|
|
3925 return GetCharWidthFloatW (arg1, arg2, arg3, arg4);
|
|
3926 else
|
|
3927 return GetCharWidthFloatA (arg1, arg2, arg3, arg4);
|
|
3928 }
|
|
3929
|
|
3930 BOOL
|
|
3931 qxeGetCharABCWidths (HDC arg1, UINT arg2, UINT arg3, LPABC arg4)
|
|
3932 {
|
|
3933 if (XEUNICODE_P)
|
|
3934 return GetCharABCWidthsW (arg1, arg2, arg3, arg4);
|
|
3935 else
|
|
3936 return GetCharABCWidthsA (arg1, arg2, arg3, arg4);
|
|
3937 }
|
|
3938
|
|
3939 BOOL
|
|
3940 qxeGetCharABCWidthsFloat (HDC arg1, UINT arg2, UINT arg3, LPABCFLOAT arg4)
|
|
3941 {
|
|
3942 if (XEUNICODE_P)
|
|
3943 return GetCharABCWidthsFloatW (arg1, arg2, arg3, arg4);
|
|
3944 else
|
|
3945 return GetCharABCWidthsFloatA (arg1, arg2, arg3, arg4);
|
|
3946 }
|
|
3947
|
|
3948 DWORD
|
|
3949 qxeGetGlyphOutline (HDC arg1, UINT arg2, UINT arg3, LPGLYPHMETRICS arg4, DWORD arg5, LPVOID arg6, CONST MAT2 * arg7)
|
|
3950 {
|
|
3951 if (XEUNICODE_P)
|
|
3952 return GetGlyphOutlineW (arg1, arg2, arg3, arg4, arg5, arg6, arg7);
|
|
3953 else
|
|
3954 return GetGlyphOutlineA (arg1, arg2, arg3, arg4, arg5, arg6, arg7);
|
|
3955 }
|
|
3956
|
|
3957 HMETAFILE
|
|
3958 qxeGetMetaFile (const Extbyte * arg1)
|
|
3959 {
|
|
3960 if (XEUNICODE_P)
|
|
3961 return GetMetaFileW ((LPCWSTR) arg1);
|
|
3962 else
|
|
3963 return GetMetaFileA ((LPCSTR) arg1);
|
|
3964 }
|
|
3965
|
|
3966 /* Error if GetOutlineTextMetrics used: split-sized LPOUTLINETEXTMETRIC */
|
|
3967
|
|
3968 BOOL
|
|
3969 qxeGetTextExtentPoint (HDC arg1, const Extbyte * arg2, int arg3, LPSIZE arg4)
|
|
3970 {
|
|
3971 if (XEUNICODE_P)
|
|
3972 return GetTextExtentPointW (arg1, (LPCWSTR) arg2, arg3, arg4);
|
|
3973 else
|
|
3974 return GetTextExtentPointA (arg1, (LPCSTR) arg2, arg3, arg4);
|
|
3975 }
|
|
3976
|
|
3977 BOOL
|
|
3978 qxeGetTextExtentPoint32 (HDC arg1, const Extbyte * arg2, int arg3, LPSIZE arg4)
|
|
3979 {
|
|
3980 if (XEUNICODE_P)
|
|
3981 return GetTextExtentPoint32W (arg1, (LPCWSTR) arg2, arg3, arg4);
|
|
3982 else
|
|
3983 return GetTextExtentPoint32A (arg1, (LPCSTR) arg2, arg3, arg4);
|
|
3984 }
|
|
3985
|
|
3986 BOOL
|
|
3987 qxeGetTextExtentExPoint (HDC arg1, const Extbyte * arg2, int arg3, int arg4, LPINT arg5, LPINT arg6, LPSIZE arg7)
|
|
3988 {
|
|
3989 if (XEUNICODE_P)
|
|
3990 return GetTextExtentExPointW (arg1, (LPCWSTR) arg2, arg3, arg4, arg5, arg6, arg7);
|
|
3991 else
|
|
3992 return GetTextExtentExPointA (arg1, (LPCSTR) arg2, arg3, arg4, arg5, arg6, arg7);
|
|
3993 }
|
|
3994
|
|
3995 /* NOTE: NT 4.0+ only */
|
|
3996 DWORD
|
|
3997 qxeGetCharacterPlacement (HDC arg1, const Extbyte * arg2, int arg3, int arg4, LPGCP_RESULTSW arg5, DWORD arg6)
|
|
3998 {
|
|
3999 if (XEUNICODE_P)
|
|
4000 return GetCharacterPlacementW (arg1, (LPCWSTR) arg2, arg3, arg4, arg5, arg6);
|
|
4001 else
|
|
4002 return GetCharacterPlacementA (arg1, (LPCSTR) arg2, arg3, arg4, (LPGCP_RESULTSA) arg5, arg6);
|
|
4003 }
|
|
4004
|
|
4005 /* Error if GetGlyphIndices used: NT 5.0+ only */
|
|
4006
|
|
4007 /* Error if AddFontResourceEx used: NT 5.0+ only */
|
|
4008
|
|
4009 /* Error if RemoveFontResourceEx used: NT 5.0+ only */
|
|
4010
|
|
4011 /* Error if CreateFontIndirectEx used: split-sized ENUMLOGFONTEXDV; NT 5.0+ only */
|
|
4012
|
|
4013 /* Skipping ResetDC because split-sized DEVMODE */
|
|
4014
|
|
4015 BOOL
|
|
4016 qxeRemoveFontResource (const Extbyte * arg1)
|
|
4017 {
|
|
4018 if (XEUNICODE_P)
|
|
4019 return RemoveFontResourceW ((LPCWSTR) arg1);
|
|
4020 else
|
|
4021 return RemoveFontResourceA ((LPCSTR) arg1);
|
|
4022 }
|
|
4023
|
|
4024 HENHMETAFILE
|
|
4025 qxeCopyEnhMetaFile (HENHMETAFILE arg1, const Extbyte * arg2)
|
|
4026 {
|
|
4027 if (XEUNICODE_P)
|
|
4028 return CopyEnhMetaFileW (arg1, (LPCWSTR) arg2);
|
|
4029 else
|
|
4030 return CopyEnhMetaFileA (arg1, (LPCSTR) arg2);
|
|
4031 }
|
|
4032
|
|
4033 HDC
|
|
4034 qxeCreateEnhMetaFile (HDC arg1, const Extbyte * arg2, CONST RECT * arg3, const Extbyte * arg4)
|
|
4035 {
|
|
4036 if (XEUNICODE_P)
|
|
4037 return CreateEnhMetaFileW (arg1, (LPCWSTR) arg2, arg3, (LPCWSTR) arg4);
|
|
4038 else
|
|
4039 return CreateEnhMetaFileA (arg1, (LPCSTR) arg2, arg3, (LPCSTR) arg4);
|
|
4040 }
|
|
4041
|
|
4042 HENHMETAFILE
|
|
4043 qxeGetEnhMetaFile (const Extbyte * arg1)
|
|
4044 {
|
|
4045 if (XEUNICODE_P)
|
|
4046 return GetEnhMetaFileW ((LPCWSTR) arg1);
|
|
4047 else
|
|
4048 return GetEnhMetaFileA ((LPCSTR) arg1);
|
|
4049 }
|
|
4050
|
|
4051 UINT
|
|
4052 qxeGetEnhMetaFileDescription (HENHMETAFILE arg1, UINT arg2, Extbyte * arg3)
|
|
4053 {
|
|
4054 if (XEUNICODE_P)
|
|
4055 return GetEnhMetaFileDescriptionW (arg1, arg2, (LPWSTR) arg3);
|
|
4056 else
|
|
4057 return GetEnhMetaFileDescriptionA (arg1, arg2, (LPSTR) arg3);
|
|
4058 }
|
|
4059
|
|
4060 /* Skipping GetTextMetrics because split-sized LPTEXTMETRIC */
|
|
4061
|
|
4062 int
|
|
4063 qxeStartDoc (HDC arg1, CONST DOCINFOW * arg2)
|
|
4064 {
|
|
4065 if (XEUNICODE_P)
|
|
4066 return StartDocW (arg1, arg2);
|
|
4067 else
|
|
4068 return StartDocA (arg1, (CONST DOCINFOA *) arg2);
|
|
4069 }
|
|
4070
|
|
4071 /* Skipping GetObject because split-sized LOGFONT */
|
|
4072
|
|
4073 BOOL
|
|
4074 qxeTextOut (HDC arg1, int arg2, int arg3, const Extbyte * arg4, int arg5)
|
|
4075 {
|
|
4076 if (XEUNICODE_P)
|
|
4077 return TextOutW (arg1, arg2, arg3, (LPCWSTR) arg4, arg5);
|
|
4078 else
|
|
4079 return TextOutA (arg1, arg2, arg3, (LPCSTR) arg4, arg5);
|
|
4080 }
|
|
4081
|
|
4082 BOOL
|
|
4083 qxeExtTextOut (HDC arg1, int arg2, int arg3, UINT arg4, CONST RECT * arg5, const Extbyte * arg6, UINT arg7, CONST INT * arg8)
|
|
4084 {
|
|
4085 if (XEUNICODE_P)
|
|
4086 return ExtTextOutW (arg1, arg2, arg3, arg4, arg5, (LPCWSTR) arg6, arg7, arg8);
|
|
4087 else
|
|
4088 return ExtTextOutA (arg1, arg2, arg3, arg4, arg5, (LPCSTR) arg6, arg7, arg8);
|
|
4089 }
|
|
4090
|
|
4091 BOOL
|
|
4092 qxePolyTextOut (HDC arg1, CONST POLYTEXTW * arg2, int arg3)
|
|
4093 {
|
|
4094 if (XEUNICODE_P)
|
|
4095 return PolyTextOutW (arg1, arg2, arg3);
|
|
4096 else
|
|
4097 return PolyTextOutA (arg1, (CONST POLYTEXTA *) arg2, arg3);
|
|
4098 }
|
|
4099
|
|
4100 int
|
|
4101 qxeGetTextFace (HDC arg1, int arg2, Extbyte * arg3)
|
|
4102 {
|
|
4103 if (XEUNICODE_P)
|
|
4104 return GetTextFaceW (arg1, arg2, (LPWSTR) arg3);
|
|
4105 else
|
|
4106 return GetTextFaceA (arg1, arg2, (LPSTR) arg3);
|
|
4107 }
|
|
4108
|
|
4109 DWORD
|
|
4110 qxeGetKerningPairs (HDC arg1, DWORD arg2, LPKERNINGPAIR arg3)
|
|
4111 {
|
|
4112 if (XEUNICODE_P)
|
|
4113 return GetKerningPairsW (arg1, arg2, arg3);
|
|
4114 else
|
|
4115 return GetKerningPairsA (arg1, arg2, arg3);
|
|
4116 }
|
|
4117
|
|
4118 /* Error if GetLogColorSpace used: split-sized LPLOGCOLORSPACE; NT 4.0+ only */
|
|
4119
|
|
4120 /* Error if CreateColorSpace used: split-sized LPLOGCOLORSPACE; NT 4.0+ only */
|
|
4121
|
|
4122 /* Skipping GetICMProfile because NT 4.0+ only, error in Cygwin prototype */
|
|
4123
|
|
4124 /* NOTE: NT 4.0+ only */
|
|
4125 BOOL
|
|
4126 qxeSetICMProfile (HDC arg1, Extbyte * arg2)
|
|
4127 {
|
|
4128 if (XEUNICODE_P)
|
|
4129 return SetICMProfileW (arg1, (LPWSTR) arg2);
|
|
4130 else
|
|
4131 return SetICMProfileA (arg1, (LPSTR) arg2);
|
|
4132 }
|
|
4133
|
|
4134 /* NOTE: NT 4.0+ only */
|
|
4135 int
|
|
4136 qxeEnumICMProfiles (HDC arg1, ICMENUMPROCW arg2, LPARAM arg3)
|
|
4137 {
|
|
4138 if (XEUNICODE_P)
|
|
4139 return EnumICMProfilesW (arg1, arg2, arg3);
|
|
4140 else
|
|
4141 return EnumICMProfilesA (arg1, (ICMENUMPROCA) arg2, arg3);
|
|
4142 }
|
|
4143
|
|
4144 /* Skipping UpdateICMRegKey because NT 4.0+ only, error in Cygwin prototype */
|
|
4145
|
|
4146 /* Error if wglUseFontBitmaps used: causes link error */
|
|
4147
|
|
4148 /* Error if wglUseFontOutlines used: causes link error */
|
|
4149
|