1 | /* $Id: user32.cpp,v 1.46 1999-10-20 22:35:54 sandervl Exp $ */
|
---|
2 |
|
---|
3 | /*
|
---|
4 | * Win32 misc user32 API functions for OS/2
|
---|
5 | *
|
---|
6 | * Copyright 1998 Sander van Leeuwen
|
---|
7 | * Copyright 1998 Patrick Haller
|
---|
8 | * Copyright 1998 Peter Fitzsimmons
|
---|
9 | * Copyright 1999 Christoph Bratschi
|
---|
10 | * Copyright 1999 Daniela Engert (dani@ngrt.de)
|
---|
11 | *
|
---|
12 | *
|
---|
13 | * Project Odin Software License can be found in LICENSE.TXT
|
---|
14 | *
|
---|
15 | */
|
---|
16 | /*****************************************************************************
|
---|
17 | * Name : USER32.CPP
|
---|
18 | * Purpose : This module maps all Win32 functions contained in USER32.DLL
|
---|
19 | * to their OS/2-specific counterparts as far as possible.
|
---|
20 | *****************************************************************************/
|
---|
21 |
|
---|
22 | //Attention: many functions belong to other subsystems, move them to their
|
---|
23 | // right place!
|
---|
24 |
|
---|
25 | #include <odin.h>
|
---|
26 | #include <odinwrap.h>
|
---|
27 | #include <os2sel.h>
|
---|
28 |
|
---|
29 | #include <os2win.h>
|
---|
30 | #include "misc.h"
|
---|
31 |
|
---|
32 | #include "user32.h"
|
---|
33 | #include <winicon.h>
|
---|
34 | #include "syscolor.h"
|
---|
35 |
|
---|
36 | #include <wchar.h>
|
---|
37 | #include <stdlib.h>
|
---|
38 | #include <string.h>
|
---|
39 | #include <oslibwin.h>
|
---|
40 | #include <win32wnd.h>
|
---|
41 | #include <winuser.h>
|
---|
42 |
|
---|
43 | //undocumented stuff
|
---|
44 | // WIN32API CalcChildScroll
|
---|
45 | // WIN32API CascadeChildWindows
|
---|
46 | // WIN32API ClientThreadConnect
|
---|
47 | // WIN32API DragObject
|
---|
48 | // WIN32API DrawFrame
|
---|
49 | // WIN32API EditWndProc
|
---|
50 | // WIN32API EndTask
|
---|
51 | // WIN32API GetInputDesktop
|
---|
52 | // WIN32API GetNextQueueWindow
|
---|
53 | // WIN32API GetShellWindow
|
---|
54 | // WIN32API InitSharedTable
|
---|
55 | // WIN32API InitTask
|
---|
56 | // WIN32API IsHungThread
|
---|
57 | // WIN32API LockWindowStation
|
---|
58 | // WIN32API ModifyAccess
|
---|
59 | // WIN32API PlaySoundEvent
|
---|
60 | // WIN32API RegisterLogonProcess
|
---|
61 | // WIN32API RegisterNetworkCapabilities
|
---|
62 | // WIN32API RegisterSystemThread
|
---|
63 | // WIN32API SetDeskWallpaper
|
---|
64 | // WIN32API SetDesktopBitmap
|
---|
65 | // WIN32API SetInternalWindowPos
|
---|
66 | // WIN32API SetLogonNotifyWindow
|
---|
67 | // WIN32API SetShellWindow
|
---|
68 | // WIN32API SetSysColorsTemp
|
---|
69 | // WIN32API SetWindowFullScreenState
|
---|
70 | // WIN32API SwitchToThisWindow
|
---|
71 | // WIN32API SysErrorBox
|
---|
72 | // WIN32API TileChildWindows
|
---|
73 | // WIN32API UnlockWindowStation
|
---|
74 | // WIN32API UserClientDllInitialize
|
---|
75 | // WIN32API UserSignalProc
|
---|
76 | // WIN32API WinOldAppHackoMatic
|
---|
77 | // WIN32API WNDPROC_CALLBACK
|
---|
78 | // WIN32API YieldTask
|
---|
79 |
|
---|
80 | ODINDEBUGCHANNEL(USER32-USER32)
|
---|
81 |
|
---|
82 |
|
---|
83 | /* Coordinate Transformation */
|
---|
84 |
|
---|
85 | inline void OS2ToWin32ScreenPos(POINT *dest,POINT *source)
|
---|
86 | {
|
---|
87 | dest->x = source->x;
|
---|
88 | dest->y = OSLibWinQuerySysValue(OSLIB_HWND_DESKTOP,SVOS_CYSCREEN)-1-source->y;
|
---|
89 | }
|
---|
90 |
|
---|
91 | inline void Win32ToOS2ScreenPos(POINT *dest,POINT *source)
|
---|
92 | {
|
---|
93 | OS2ToWin32ScreenPos(dest,source); //transform back
|
---|
94 | }
|
---|
95 |
|
---|
96 | /* Rectangle Functions - parts from wine/windows/rect.c */
|
---|
97 |
|
---|
98 | BOOL WIN32API CopyRect( PRECT lprcDst, const RECT * lprcSrc)
|
---|
99 | {
|
---|
100 | // ddprintf(("USER32: CopyRect\n"));
|
---|
101 | if (!lprcDst || !lprcSrc) {
|
---|
102 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
103 | return FALSE;
|
---|
104 | }
|
---|
105 |
|
---|
106 | memcpy(lprcDst,lprcSrc,sizeof(RECT));
|
---|
107 |
|
---|
108 | return TRUE;
|
---|
109 | }
|
---|
110 | //******************************************************************************
|
---|
111 | //******************************************************************************
|
---|
112 | BOOL WIN32API EqualRect( const RECT *lprc1, const RECT *lprc2)
|
---|
113 | {
|
---|
114 | #ifdef DEBUG
|
---|
115 | WriteLog("USER32: EqualRect\n");
|
---|
116 | #endif
|
---|
117 | if (!lprc1 || !lprc2)
|
---|
118 | {
|
---|
119 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
120 | return FALSE;
|
---|
121 | }
|
---|
122 |
|
---|
123 | return (lprc1->left == lprc2->left &&
|
---|
124 | lprc1->right == lprc2->right &&
|
---|
125 | lprc1->top == lprc2->top &&
|
---|
126 | lprc1->bottom == lprc2->bottom);
|
---|
127 | }
|
---|
128 | //******************************************************************************
|
---|
129 | //******************************************************************************
|
---|
130 | BOOL WIN32API InflateRect( PRECT lprc, int dx, int dy)
|
---|
131 | {
|
---|
132 | #ifdef DEBUG
|
---|
133 | WriteLog("USER32: InflateRect\n");
|
---|
134 | #endif
|
---|
135 | if (!lprc)
|
---|
136 | {
|
---|
137 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
138 | return FALSE;
|
---|
139 | }
|
---|
140 |
|
---|
141 | lprc->left -= dx;
|
---|
142 | lprc->right += dx;
|
---|
143 | lprc->top -= dy;
|
---|
144 | lprc->bottom += dy;
|
---|
145 |
|
---|
146 | return TRUE;
|
---|
147 | }
|
---|
148 | //******************************************************************************
|
---|
149 | //******************************************************************************
|
---|
150 | BOOL WIN32API IntersectRect( PRECT lprcDst, const RECT * lprcSrc1, const RECT * lprcSrc2)
|
---|
151 | {
|
---|
152 | #ifdef DEBUG
|
---|
153 | //// WriteLog("USER32: IntersectRect\n");
|
---|
154 | #endif
|
---|
155 | if (!lprcDst || !lprcSrc1 || !lprcSrc2)
|
---|
156 | {
|
---|
157 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
158 | return FALSE;
|
---|
159 | }
|
---|
160 |
|
---|
161 | if (IsRectEmpty(lprcSrc1) || IsRectEmpty(lprcSrc2) ||
|
---|
162 | (lprcSrc1->left >= lprcSrc2->right) || (lprcSrc2->left >= lprcSrc1->right) ||
|
---|
163 | (lprcSrc1->top >= lprcSrc2->bottom) || (lprcSrc2->top >= lprcSrc1->bottom))
|
---|
164 | {
|
---|
165 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
166 | SetRectEmpty(lprcDst);
|
---|
167 | return FALSE;
|
---|
168 | }
|
---|
169 | lprcDst->left = MAX(lprcSrc1->left,lprcSrc2->left);
|
---|
170 | lprcDst->right = MIN(lprcSrc1->right,lprcSrc2->right);
|
---|
171 | lprcDst->top = MAX(lprcSrc1->top,lprcSrc2->top);
|
---|
172 | lprcDst->bottom = MIN(lprcSrc1->bottom,lprcSrc2->bottom);
|
---|
173 |
|
---|
174 | return TRUE;
|
---|
175 | }
|
---|
176 | //******************************************************************************
|
---|
177 | //******************************************************************************
|
---|
178 | BOOL WIN32API IsRectEmpty( const RECT * lprc)
|
---|
179 | {
|
---|
180 | if (!lprc)
|
---|
181 | {
|
---|
182 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
183 | return FALSE;
|
---|
184 | }
|
---|
185 |
|
---|
186 | return (lprc->left == lprc->right || lprc->top == lprc->bottom);
|
---|
187 | }
|
---|
188 | //******************************************************************************
|
---|
189 | //******************************************************************************
|
---|
190 | BOOL WIN32API OffsetRect( PRECT lprc, int x, int y)
|
---|
191 | {
|
---|
192 | #ifdef DEBUG
|
---|
193 | //// WriteLog("USER32: OffsetRect\n");
|
---|
194 | #endif
|
---|
195 | if (!lprc)
|
---|
196 | {
|
---|
197 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
198 | return FALSE;
|
---|
199 | }
|
---|
200 |
|
---|
201 | lprc->left += x;
|
---|
202 | lprc->right += x;
|
---|
203 | lprc->top += y;
|
---|
204 | lprc->bottom += y;
|
---|
205 |
|
---|
206 | return TRUE;
|
---|
207 | }
|
---|
208 | //******************************************************************************
|
---|
209 | //******************************************************************************
|
---|
210 | BOOL WIN32API PtInRect( const RECT *lprc, POINT pt)
|
---|
211 | {
|
---|
212 | #ifdef DEBUG1
|
---|
213 | WriteLog("USER32: PtInRect\n");
|
---|
214 | #endif
|
---|
215 | if (!lprc)
|
---|
216 | {
|
---|
217 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
218 | return FALSE;
|
---|
219 | }
|
---|
220 |
|
---|
221 | return (pt.x >= lprc->left &&
|
---|
222 | pt.x < lprc->right &&
|
---|
223 | pt.y >= lprc->top &&
|
---|
224 | pt.y < lprc->bottom);
|
---|
225 | }
|
---|
226 | //******************************************************************************
|
---|
227 | //******************************************************************************
|
---|
228 | BOOL WIN32API SetRect( PRECT lprc, int nLeft, int nTop, int nRight, int nBottom)
|
---|
229 | {
|
---|
230 | if (!lprc)
|
---|
231 | {
|
---|
232 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
233 | return FALSE;
|
---|
234 | }
|
---|
235 |
|
---|
236 | lprc->left = nLeft;
|
---|
237 | lprc->top = nTop;
|
---|
238 | lprc->right = nRight;
|
---|
239 | lprc->bottom = nBottom;
|
---|
240 |
|
---|
241 | return TRUE;
|
---|
242 | }
|
---|
243 | //******************************************************************************
|
---|
244 | //******************************************************************************
|
---|
245 | BOOL WIN32API SetRectEmpty( PRECT lprc)
|
---|
246 | {
|
---|
247 | if (!lprc)
|
---|
248 | {
|
---|
249 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
250 | return FALSE;
|
---|
251 | }
|
---|
252 |
|
---|
253 | lprc->left = lprc->right = lprc->top = lprc->bottom = 0;
|
---|
254 |
|
---|
255 | return TRUE;
|
---|
256 | }
|
---|
257 | //******************************************************************************
|
---|
258 | //******************************************************************************
|
---|
259 | BOOL WIN32API SubtractRect( PRECT lprcDest, const RECT * lprcSrc1, const RECT * lprcSrc2)
|
---|
260 | {
|
---|
261 | #ifdef DEBUG
|
---|
262 | WriteLog("USER32: SubtractRect");
|
---|
263 | #endif
|
---|
264 | RECT tmp;
|
---|
265 |
|
---|
266 | if (!lprcDest || !lprcSrc1 || !lprcSrc2)
|
---|
267 | {
|
---|
268 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
269 | return FALSE;
|
---|
270 | }
|
---|
271 |
|
---|
272 | if (IsRectEmpty(lprcSrc1))
|
---|
273 | {
|
---|
274 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
275 | SetRectEmpty(lprcDest);
|
---|
276 | return FALSE;
|
---|
277 | }
|
---|
278 | *lprcDest = *lprcSrc1;
|
---|
279 | if (IntersectRect(&tmp,lprcSrc1,lprcSrc2))
|
---|
280 | {
|
---|
281 | if (EqualRect(&tmp,lprcDest))
|
---|
282 | {
|
---|
283 | SetRectEmpty(lprcDest);
|
---|
284 | return FALSE;
|
---|
285 | }
|
---|
286 | if ((tmp.top == lprcDest->top) && (tmp.bottom == lprcDest->bottom))
|
---|
287 | {
|
---|
288 | if (tmp.left == lprcDest->left) lprcDest->left = tmp.right;
|
---|
289 | else if (tmp.right == lprcDest->right) lprcDest->right = tmp.left;
|
---|
290 | }
|
---|
291 | else if ((tmp.left == lprcDest->left) && (tmp.right == lprcDest->right))
|
---|
292 | {
|
---|
293 | if (tmp.top == lprcDest->top) lprcDest->top = tmp.bottom;
|
---|
294 | else if (tmp.bottom == lprcDest->bottom) lprcDest->bottom = tmp.top;
|
---|
295 | }
|
---|
296 | }
|
---|
297 |
|
---|
298 | return TRUE;
|
---|
299 | }
|
---|
300 | //******************************************************************************
|
---|
301 | //******************************************************************************
|
---|
302 | BOOL WIN32API UnionRect( PRECT lprcDst, const RECT *lprcSrc1, const RECT *lprcSrc2)
|
---|
303 | {
|
---|
304 | #ifdef DEBUG
|
---|
305 | WriteLog("USER32: UnionRect\n");
|
---|
306 | #endif
|
---|
307 | if (!lprcDst || !lprcSrc1 || !lprcSrc2)
|
---|
308 | {
|
---|
309 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
310 | return FALSE;
|
---|
311 | }
|
---|
312 |
|
---|
313 | if (IsRectEmpty(lprcSrc1))
|
---|
314 | {
|
---|
315 | if (IsRectEmpty(lprcSrc2))
|
---|
316 | {
|
---|
317 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
318 | SetRectEmpty(lprcDst);
|
---|
319 | return FALSE;
|
---|
320 | }
|
---|
321 | else *lprcDst = *lprcSrc2;
|
---|
322 | }
|
---|
323 | else
|
---|
324 | {
|
---|
325 | if (IsRectEmpty(lprcSrc2)) *lprcDst = *lprcSrc1;
|
---|
326 | else
|
---|
327 | {
|
---|
328 | lprcDst->left = MIN(lprcSrc1->left,lprcSrc2->left);
|
---|
329 | lprcDst->right = MAX(lprcSrc1->right,lprcSrc2->right);
|
---|
330 | lprcDst->top = MIN(lprcSrc1->top,lprcSrc2->top);
|
---|
331 | lprcDst->bottom = MAX(lprcSrc1->bottom,lprcSrc2->bottom);
|
---|
332 | }
|
---|
333 | }
|
---|
334 |
|
---|
335 | return TRUE;
|
---|
336 | }
|
---|
337 |
|
---|
338 | /* String Manipulation Functions */
|
---|
339 |
|
---|
340 | int __cdecl wsprintfA(char *lpOut, LPCSTR lpFmt, ...)
|
---|
341 | {
|
---|
342 | int rc;
|
---|
343 | va_list argptr;
|
---|
344 |
|
---|
345 | #ifdef DEBUG
|
---|
346 | WriteLog("USER32: wsprintfA\n");
|
---|
347 | WriteLog("USER32: %s\n", lpFmt);
|
---|
348 | #endif
|
---|
349 | va_start(argptr, lpFmt);
|
---|
350 | rc = O32_wvsprintf(lpOut, (char *)lpFmt, argptr);
|
---|
351 | va_end(argptr);
|
---|
352 | #ifdef DEBUG
|
---|
353 | WriteLog("USER32: %s\n", lpOut);
|
---|
354 | #endif
|
---|
355 | return(rc);
|
---|
356 | }
|
---|
357 | //******************************************************************************
|
---|
358 | //******************************************************************************
|
---|
359 | int __cdecl wsprintfW(LPWSTR lpOut, LPCWSTR lpFmt, ...)
|
---|
360 | {
|
---|
361 | int rc;
|
---|
362 | char *lpFmtA;
|
---|
363 | char szOut[512];
|
---|
364 | va_list argptr;
|
---|
365 |
|
---|
366 | dprintf(("USER32: wsprintfW(%08xh,%08xh).\n",
|
---|
367 | lpOut,
|
---|
368 | lpFmt));
|
---|
369 |
|
---|
370 | lpFmtA = UnicodeToAsciiString((LPWSTR)lpFmt);
|
---|
371 |
|
---|
372 | /* @@@PH 98/07/13 transform "%s" to "%ls" does the unicode magic */
|
---|
373 | {
|
---|
374 | PCHAR pszTemp;
|
---|
375 | PCHAR pszTemp1;
|
---|
376 | ULONG ulStrings;
|
---|
377 | ULONG ulIndex; /* temporary string counter */
|
---|
378 |
|
---|
379 | for (ulStrings = 0, /* determine number of placeholders */
|
---|
380 | pszTemp = lpFmtA;
|
---|
381 |
|
---|
382 | (pszTemp != NULL) &&
|
---|
383 | (*pszTemp != 0);
|
---|
384 |
|
---|
385 | ulStrings++)
|
---|
386 | {
|
---|
387 | pszTemp = strstr(pszTemp,
|
---|
388 | "%s");
|
---|
389 | if (pszTemp != NULL) /* skip 2 characters */
|
---|
390 | {
|
---|
391 | pszTemp++;
|
---|
392 | pszTemp++;
|
---|
393 | }
|
---|
394 | else
|
---|
395 | break; /* leave loop immediately */
|
---|
396 | }
|
---|
397 |
|
---|
398 | if (ulStrings != 0) /* transformation required ? */
|
---|
399 | {
|
---|
400 | /* now reallocate lpFmt */
|
---|
401 | ulStrings += strlen(lpFmtA); /* calculate total string length */
|
---|
402 | pszTemp = lpFmtA; /* save string pointer */
|
---|
403 | pszTemp1 = lpFmtA; /* save string pointer */
|
---|
404 |
|
---|
405 | /* @@@PH allocation has to be compatible to FreeAsciiString !!! */
|
---|
406 | lpFmtA = (char *)malloc(ulStrings + 1);
|
---|
407 | if (lpFmtA == NULL) /* check proper allocation */
|
---|
408 | return (0); /* raise error condition */
|
---|
409 |
|
---|
410 | for (ulIndex = 0;
|
---|
411 | ulIndex <= ulStrings;
|
---|
412 | ulIndex++,
|
---|
413 | pszTemp++)
|
---|
414 | {
|
---|
415 | if ((pszTemp[0] == '%') &&
|
---|
416 | (pszTemp[1] == 's') )
|
---|
417 | {
|
---|
418 | /* replace %s by %ls */
|
---|
419 | lpFmtA[ulIndex++] = '%';
|
---|
420 | lpFmtA[ulIndex ] = 'l';
|
---|
421 | lpFmtA[ulIndex+1] = 's';
|
---|
422 | }
|
---|
423 | else
|
---|
424 | lpFmtA[ulIndex] = *pszTemp; /* just copy over the character */
|
---|
425 | }
|
---|
426 |
|
---|
427 | lpFmtA[ulStrings] = 0; /* string termination */
|
---|
428 |
|
---|
429 | FreeAsciiString(pszTemp1); /* the original string is obsolete */
|
---|
430 | }
|
---|
431 | }
|
---|
432 |
|
---|
433 | dprintf(("USER32: wsprintfW (%s).\n",
|
---|
434 | lpFmt));
|
---|
435 |
|
---|
436 | va_start(argptr,
|
---|
437 | lpFmt);
|
---|
438 |
|
---|
439 | rc = O32_wvsprintf(szOut,
|
---|
440 | lpFmtA,
|
---|
441 | argptr);
|
---|
442 |
|
---|
443 | AsciiToUnicode(szOut,
|
---|
444 | lpOut);
|
---|
445 |
|
---|
446 | FreeAsciiString(lpFmtA);
|
---|
447 | return(rc);
|
---|
448 | }
|
---|
449 | //******************************************************************************
|
---|
450 | //******************************************************************************
|
---|
451 | int WIN32API wvsprintfA( LPSTR lpOutput, LPCSTR lpFormat, va_list arglist)
|
---|
452 | {
|
---|
453 | #ifdef DEBUG
|
---|
454 | WriteLog("USER32: wvsprintfA\n");
|
---|
455 | #endif
|
---|
456 | return O32_wvsprintf(lpOutput,lpFormat,(LPCVOID*)arglist);
|
---|
457 | }
|
---|
458 | //******************************************************************************
|
---|
459 | //******************************************************************************
|
---|
460 | int WIN32API wvsprintfW(LPWSTR lpOutput, LPCWSTR lpFormat, va_list arglist)
|
---|
461 | {
|
---|
462 | int rc;
|
---|
463 | char szOut[256];
|
---|
464 | char *lpFmtA;
|
---|
465 |
|
---|
466 | lpFmtA = UnicodeToAsciiString((LPWSTR)lpFormat);
|
---|
467 | #ifdef DEBUG
|
---|
468 | WriteLog("USER32: wvsprintfW, DOES NOT HANDLE UNICODE STRINGS!\n");
|
---|
469 | WriteLog("USER32: %s\n", lpFormat);
|
---|
470 | #endif
|
---|
471 | rc = O32_wvsprintf(szOut, lpFmtA, (LPCVOID)arglist);
|
---|
472 |
|
---|
473 | AsciiToUnicode(szOut, lpOutput);
|
---|
474 | #ifdef DEBUG
|
---|
475 | WriteLog("USER32: %s\n", lpOutput);
|
---|
476 | #endif
|
---|
477 | FreeAsciiString(lpFmtA);
|
---|
478 | return(rc);
|
---|
479 | }
|
---|
480 |
|
---|
481 | /* Cursor Functions */
|
---|
482 |
|
---|
483 | BOOL WIN32API ClipCursor(const RECT * lpRect)
|
---|
484 | {
|
---|
485 | #ifdef DEBUG
|
---|
486 | WriteLog("USER32: ClipCursor\n");
|
---|
487 | #endif
|
---|
488 | return O32_ClipCursor(lpRect);
|
---|
489 | }
|
---|
490 | //******************************************************************************
|
---|
491 | //******************************************************************************
|
---|
492 | HCURSOR WIN32API CreateCursor( HINSTANCE hInst, int xHotSpot, int yHotSpot, int nWidth, int nHeight, const VOID *pvANDPlane, const VOID *pvXORPlane)
|
---|
493 | {
|
---|
494 | #ifdef DEBUG
|
---|
495 | WriteLog("USER32: CreateCursor\n");
|
---|
496 | #endif
|
---|
497 | return O32_CreateCursor(hInst,xHotSpot,yHotSpot,nWidth,nHeight,pvANDPlane,pvXORPlane);
|
---|
498 | }
|
---|
499 | //******************************************************************************
|
---|
500 | //******************************************************************************
|
---|
501 | BOOL WIN32API DestroyCursor( HCURSOR hCursor)
|
---|
502 | {
|
---|
503 | #ifdef DEBUG
|
---|
504 | WriteLog("USER32: DestroyCursor\n");
|
---|
505 | #endif
|
---|
506 | return O32_DestroyCursor(hCursor);
|
---|
507 | }
|
---|
508 | //******************************************************************************
|
---|
509 | //******************************************************************************
|
---|
510 | BOOL WIN32API GetClipCursor( LPRECT lpRect)
|
---|
511 | {
|
---|
512 | #ifdef DEBUG
|
---|
513 | WriteLog("USER32: GetClipCursor\n");
|
---|
514 | #endif
|
---|
515 | return O32_GetClipCursor(lpRect);
|
---|
516 | }
|
---|
517 | //******************************************************************************
|
---|
518 | //******************************************************************************
|
---|
519 | HCURSOR WIN32API GetCursor(void)
|
---|
520 | {
|
---|
521 | #ifdef DEBUG
|
---|
522 | //// WriteLog("USER32: GetCursor\n");
|
---|
523 | #endif
|
---|
524 | return O32_GetCursor();
|
---|
525 | }
|
---|
526 | //******************************************************************************
|
---|
527 | //******************************************************************************
|
---|
528 | BOOL WIN32API GetCursorPos( PPOINT lpPoint)
|
---|
529 | {
|
---|
530 | BOOL rc;
|
---|
531 | POINT point;
|
---|
532 | #ifdef DEBUG
|
---|
533 | //// WriteLog("USER32: GetCursorPos\n");
|
---|
534 | #endif
|
---|
535 | if (!lpPoint) return FALSE;
|
---|
536 | if (OSLibWinQueryPointerPos(OSLIB_HWND_DESKTOP,&point)) //POINT == POINTL
|
---|
537 | {
|
---|
538 | OS2ToWin32ScreenPos(lpPoint,&point);
|
---|
539 | return TRUE;
|
---|
540 | } else return FALSE;
|
---|
541 | }
|
---|
542 | /*****************************************************************************
|
---|
543 | * Name : HCURSOR WIN32API LoadCursorFromFileA
|
---|
544 | * Purpose : The LoadCursorFromFile function creates a cursor based on data
|
---|
545 | * contained in a file. The file is specified by its name or by a
|
---|
546 | * system cursor identifier. The function returns a handle to the
|
---|
547 | * newly created cursor. Files containing cursor data may be in
|
---|
548 | * either cursor (.CUR) or animated cursor (.ANI) format.
|
---|
549 | * Parameters: LPCTSTR lpFileName pointer to cursor file, or system cursor id
|
---|
550 | * Variables :
|
---|
551 | * Result : If the function is successful, the return value is a handle to
|
---|
552 | * the new cursor.
|
---|
553 | * If the function fails, the return value is NULL. To get extended
|
---|
554 | * error information, call GetLastError. GetLastError may return
|
---|
555 | * the following
|
---|
556 | * Remark :
|
---|
557 | * Status : UNTESTED STUB
|
---|
558 | *
|
---|
559 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
560 | *****************************************************************************/
|
---|
561 | HCURSOR WIN32API LoadCursorFromFileA(LPCTSTR lpFileName)
|
---|
562 | {
|
---|
563 | if (!HIWORD(lpFileName))
|
---|
564 | {
|
---|
565 | return LoadCursorA(NULL,lpFileName);
|
---|
566 | } else
|
---|
567 | {
|
---|
568 | dprintf(("USER32:LoadCursorFromFileA (%s) not implemented.\n",
|
---|
569 | lpFileName));
|
---|
570 |
|
---|
571 | return (NULL);
|
---|
572 | }
|
---|
573 | }
|
---|
574 | /*****************************************************************************
|
---|
575 | * Name : HCURSOR WIN32API LoadCursorFromFileW
|
---|
576 | * Purpose : The LoadCursorFromFile function creates a cursor based on data
|
---|
577 | * contained in a file. The file is specified by its name or by a
|
---|
578 | * system cursor identifier. The function returns a handle to the
|
---|
579 | * newly created cursor. Files containing cursor data may be in
|
---|
580 | * either cursor (.CUR) or animated cursor (.ANI) format.
|
---|
581 | * Parameters: LPCTSTR lpFileName pointer to cursor file, or system cursor id
|
---|
582 | * Variables :
|
---|
583 | * Result : If the function is successful, the return value is a handle to
|
---|
584 | * the new cursor.
|
---|
585 | * If the function fails, the return value is NULL. To get extended
|
---|
586 | * error information, call GetLastError. GetLastError may return
|
---|
587 | * the following
|
---|
588 | * Remark :
|
---|
589 | * Status : UNTESTED STUB
|
---|
590 | *
|
---|
591 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
592 | *****************************************************************************/
|
---|
593 | HCURSOR WIN32API LoadCursorFromFileW(LPCWSTR lpFileName)
|
---|
594 | {
|
---|
595 | if (!HIWORD(lpFileName))
|
---|
596 | {
|
---|
597 | return LoadCursorW(NULL,lpFileName);
|
---|
598 | } else
|
---|
599 | {
|
---|
600 | dprintf(("USER32:LoadCursorFromFileW (%s) not implemented.\n",
|
---|
601 | lpFileName));
|
---|
602 |
|
---|
603 | return (NULL);
|
---|
604 | }
|
---|
605 | }
|
---|
606 | //******************************************************************************
|
---|
607 | //******************************************************************************
|
---|
608 | HCURSOR WIN32API SetCursor( HCURSOR hcur)
|
---|
609 | {
|
---|
610 | HCURSOR rc;
|
---|
611 |
|
---|
612 | rc = O32_SetCursor(hcur);
|
---|
613 | dprintf(("USER32: SetCursor %x (prev %x (%x))\n", hcur, rc, O32_GetCursor()));
|
---|
614 | return rc;
|
---|
615 | }
|
---|
616 | //******************************************************************************
|
---|
617 | //******************************************************************************
|
---|
618 | BOOL WIN32API SetCursorPos( int X, int Y)
|
---|
619 | {
|
---|
620 | #ifdef DEBUG
|
---|
621 | WriteLog("USER32: SetCursorPos\n");
|
---|
622 | #endif
|
---|
623 | return O32_SetCursorPos(X,Y);
|
---|
624 | }
|
---|
625 | /*****************************************************************************
|
---|
626 | * Name : BOOL WIN32API SetSystemCursor
|
---|
627 | * Purpose : The SetSystemCursor function replaces the contents of the system
|
---|
628 | * cursor specified by dwCursorId with the contents of the cursor
|
---|
629 | * specified by hCursor, and then destroys hCursor. This function
|
---|
630 | * lets an application customize the system cursors.
|
---|
631 | * Parameters: HCURSOR hCursor set specified system cursor to this cursor's
|
---|
632 | * contents, then destroy this
|
---|
633 | * DWORD dwCursorID system cursor specified by its identifier
|
---|
634 | * Variables :
|
---|
635 | * Result : If the function succeeds, the return value is TRUE.
|
---|
636 | * If the function fails, the return value is FALSE. To get extended
|
---|
637 | * error information, call GetLastError.
|
---|
638 | * Remark :
|
---|
639 | * Status : UNTESTED STUB
|
---|
640 | *
|
---|
641 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
642 | *****************************************************************************/
|
---|
643 | BOOL WIN32API SetSystemCursor(HCURSOR hCursor,
|
---|
644 | DWORD dwCursorId)
|
---|
645 | {
|
---|
646 | dprintf(("USER32:SetSystemCursor (%08xh,%08x) not supported.\n",
|
---|
647 | hCursor,
|
---|
648 | dwCursorId));
|
---|
649 |
|
---|
650 | return DestroyCursor(hCursor);
|
---|
651 | }
|
---|
652 | //******************************************************************************
|
---|
653 | //******************************************************************************
|
---|
654 | int WIN32API ShowCursor( BOOL bShow)
|
---|
655 | {
|
---|
656 | #ifdef DEBUG
|
---|
657 | WriteLog("USER32: ShowCursor\n");
|
---|
658 | #endif
|
---|
659 | return O32_ShowCursor(bShow);
|
---|
660 | }
|
---|
661 |
|
---|
662 | /* Mouse Input Functions */
|
---|
663 |
|
---|
664 | /*****************************************************************************
|
---|
665 | * Name : BOOL WIN32API DragDetect
|
---|
666 | * Purpose : The DragDetect function captures the mouse and tracks its movement
|
---|
667 | * Parameters: HWND hwnd
|
---|
668 | * POINT pt
|
---|
669 | * Variables :
|
---|
670 | * Result : If the user moved the mouse outside of the drag rectangle while
|
---|
671 | * holding the left button down, the return value is TRUE.
|
---|
672 | * If the user did not move the mouse outside of the drag rectangle
|
---|
673 | * while holding the left button down, the return value is FALSE.
|
---|
674 | * Remark :
|
---|
675 | * Status : UNTESTED STUB
|
---|
676 | *
|
---|
677 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
678 | *****************************************************************************/
|
---|
679 | BOOL WIN32API DragDetect(HWND hwnd,
|
---|
680 | POINT pt)
|
---|
681 | {
|
---|
682 | dprintf(("USER32:DragDetect(%08xh,...) not implemented.\n",
|
---|
683 | hwnd));
|
---|
684 |
|
---|
685 | return (FALSE);
|
---|
686 | }
|
---|
687 | //******************************************************************************
|
---|
688 | //******************************************************************************
|
---|
689 | UINT WIN32API GetDoubleClickTime(void)
|
---|
690 | {
|
---|
691 | #ifdef DEBUG
|
---|
692 | WriteLog("USER32: GetDoubleClickTime\n");
|
---|
693 | #endif
|
---|
694 | return O32_GetDoubleClickTime();
|
---|
695 | }
|
---|
696 | /*****************************************************************************
|
---|
697 | * Name : VOID WIN32API mouse_event
|
---|
698 | * Purpose : The mouse_event function synthesizes mouse motion and button clicks.
|
---|
699 | * Parameters: DWORD dwFlags flags specifying various motion/click variants
|
---|
700 | * DWORD dx horizontal mouse position or position change
|
---|
701 | * DWORD dy vertical mouse position or position change
|
---|
702 | * DWORD cButtons unused, reserved for future use, set to zero
|
---|
703 | * DWORD dwExtraInfo 32 bits of application-defined information
|
---|
704 | * Variables :
|
---|
705 | * Result :
|
---|
706 | * Remark :
|
---|
707 | * Status : UNTESTED STUB
|
---|
708 | *
|
---|
709 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
710 | *****************************************************************************/
|
---|
711 | VOID WIN32API mouse_event(DWORD dwFlags,
|
---|
712 | DWORD dx,
|
---|
713 | DWORD dy,
|
---|
714 | DWORD cButtons,
|
---|
715 | DWORD dwExtraInfo)
|
---|
716 | {
|
---|
717 | dprintf(("USER32:mouse_event (%08xh,%u,%u,%u,%08x) not implemented.\n",
|
---|
718 | dwFlags,
|
---|
719 | dx,
|
---|
720 | dy,
|
---|
721 | cButtons,
|
---|
722 | dwExtraInfo));
|
---|
723 | }
|
---|
724 | //******************************************************************************
|
---|
725 | //******************************************************************************
|
---|
726 | BOOL WIN32API ReleaseCapture(void)
|
---|
727 | {
|
---|
728 | dprintf(("USER32: ReleaseCapture"));
|
---|
729 | return O32_ReleaseCapture();
|
---|
730 | }
|
---|
731 | //******************************************************************************
|
---|
732 | //******************************************************************************
|
---|
733 | HWND WIN32API GetCapture(void)
|
---|
734 | {
|
---|
735 | HWND hwnd;
|
---|
736 |
|
---|
737 | hwnd = Win32Window::OS2ToWin32Handle(O32_GetCapture());
|
---|
738 | dprintf(("USER32: GetCapture returned %x", hwnd));
|
---|
739 | return hwnd;
|
---|
740 | }
|
---|
741 | //******************************************************************************
|
---|
742 | //******************************************************************************
|
---|
743 | HWND WIN32API SetCapture( HWND hwnd)
|
---|
744 | {
|
---|
745 | #ifdef DEBUG
|
---|
746 | WriteLog("USER32: SetCapture %x", hwnd);
|
---|
747 | #endif
|
---|
748 | hwnd = Win32Window::Win32ToOS2Handle(hwnd);
|
---|
749 | return Win32Window::OS2ToWin32Handle(O32_SetCapture(hwnd));
|
---|
750 | }
|
---|
751 | //******************************************************************************
|
---|
752 | //******************************************************************************
|
---|
753 | BOOL WIN32API SetDoubleClickTime( UINT uInterval)
|
---|
754 | {
|
---|
755 | #ifdef DEBUG
|
---|
756 | WriteLog("USER32: SetDoubleClickTime\n");
|
---|
757 | #endif
|
---|
758 | return O32_SetDoubleClickTime(uInterval);
|
---|
759 | }
|
---|
760 | //******************************************************************************
|
---|
761 | //******************************************************************************
|
---|
762 | BOOL WIN32API SwapMouseButton( BOOL fSwap)
|
---|
763 | {
|
---|
764 | #ifdef DEBUG
|
---|
765 | WriteLog("USER32: SwapMouseButton\n");
|
---|
766 | #endif
|
---|
767 | return O32_SwapMouseButton(fSwap);
|
---|
768 | }
|
---|
769 |
|
---|
770 | /* Error Functions */
|
---|
771 |
|
---|
772 | /*****************************************************************************
|
---|
773 | * Name : ExitWindowsEx
|
---|
774 | * Purpose : Shutdown System
|
---|
775 | * Parameters: UINT uFlags
|
---|
776 | * DWORD dwReserved
|
---|
777 | * Variables :
|
---|
778 | * Result : TRUE / FALSE
|
---|
779 | * Remark :
|
---|
780 | * Status :
|
---|
781 | *
|
---|
782 | * Author : Patrick Haller [Tue, 1999/10/20 21:24]
|
---|
783 | *****************************************************************************/
|
---|
784 |
|
---|
785 | ODINFUNCTION2(BOOL, ExitWindowsEx, UINT, uFlags,
|
---|
786 | DWORD, dwReserved)
|
---|
787 | {
|
---|
788 | int rc = MessageBoxA(HWND_DESKTOP,
|
---|
789 | "Are you sure you want to shutdown the system?",
|
---|
790 | "Shutdown ...",
|
---|
791 | MB_YESNOCANCEL | MB_ICONQUESTION);
|
---|
792 | switch (rc)
|
---|
793 | {
|
---|
794 | case IDCANCEL: return (FALSE);
|
---|
795 | case IDYES: break;
|
---|
796 | case IDNO:
|
---|
797 | dprintf(("no shutdown!\n"));
|
---|
798 | return TRUE;
|
---|
799 | }
|
---|
800 |
|
---|
801 | return O32_ExitWindowsEx(uFlags,dwReserved);
|
---|
802 | }
|
---|
803 |
|
---|
804 |
|
---|
805 | //******************************************************************************
|
---|
806 | //******************************************************************************
|
---|
807 | BOOL WIN32API MessageBeep( UINT uType)
|
---|
808 | {
|
---|
809 | INT flStyle;
|
---|
810 |
|
---|
811 | #ifdef DEBUG
|
---|
812 | WriteLog("USER32: MessageBeep\n");
|
---|
813 | #endif
|
---|
814 |
|
---|
815 | switch (uType)
|
---|
816 | {
|
---|
817 | case 0xFFFFFFFF:
|
---|
818 | OSLibDosBeep(500,50);
|
---|
819 | return TRUE;
|
---|
820 | case MB_ICONASTERISK:
|
---|
821 | flStyle = WAOS_NOTE;
|
---|
822 | break;
|
---|
823 | case MB_ICONEXCLAMATION:
|
---|
824 | flStyle = WAOS_WARNING;
|
---|
825 | break;
|
---|
826 | case MB_ICONHAND:
|
---|
827 | case MB_ICONQUESTION:
|
---|
828 | case MB_OK:
|
---|
829 | flStyle = WAOS_NOTE;
|
---|
830 | break;
|
---|
831 | default:
|
---|
832 | flStyle = WAOS_ERROR; //CB: should be right
|
---|
833 | break;
|
---|
834 | }
|
---|
835 | return OSLibWinAlarm(OSLIB_HWND_DESKTOP,flStyle);
|
---|
836 | }
|
---|
837 | //******************************************************************************
|
---|
838 | //2nd parameter not used according to SDK (yet?)
|
---|
839 | //******************************************************************************
|
---|
840 | VOID WIN32API SetLastErrorEx(DWORD dwErrCode, DWORD dwType)
|
---|
841 | {
|
---|
842 | #ifdef DEBUG
|
---|
843 | WriteLog("USER32: SetLastErrorEx\n");
|
---|
844 | #endif
|
---|
845 | SetLastError(dwErrCode);
|
---|
846 | }
|
---|
847 |
|
---|
848 | /* Accessibility Functions */
|
---|
849 |
|
---|
850 | int WIN32API GetSystemMetrics(int nIndex)
|
---|
851 | {
|
---|
852 | int rc = 0;
|
---|
853 |
|
---|
854 | switch(nIndex) {
|
---|
855 | case SM_CXICONSPACING: //TODO: size of grid cell for large icons
|
---|
856 | rc = OSLibWinQuerySysValue(OSLIB_HWND_DESKTOP,SVOS_CXICON);
|
---|
857 | //CB: return standard windows icon size?
|
---|
858 | //rc = 32;
|
---|
859 | break;
|
---|
860 | case SM_CYICONSPACING:
|
---|
861 | rc = OSLibWinQuerySysValue(OSLIB_HWND_DESKTOP,SVOS_CYICON);
|
---|
862 | //read SM_CXICONSPACING comment
|
---|
863 | //rc = 32;
|
---|
864 | break;
|
---|
865 | case SM_PENWINDOWS:
|
---|
866 | rc = FALSE;
|
---|
867 | break;
|
---|
868 | case SM_DBCSENABLED:
|
---|
869 | rc = FALSE;
|
---|
870 | break;
|
---|
871 | case SM_CXEDGE: //size of 3D window edge (not supported)
|
---|
872 | rc = 1;
|
---|
873 | break;
|
---|
874 | case SM_CYEDGE:
|
---|
875 | rc = 1;
|
---|
876 | break;
|
---|
877 | case SM_CXMINSPACING: //can be SM_CXMINIMIZED or larger
|
---|
878 | //CB: replace with const
|
---|
879 | rc = O32_GetSystemMetrics(SM_CXMINIMIZED);
|
---|
880 | break;
|
---|
881 | case SM_CYMINSPACING:
|
---|
882 | //CB: replace with const
|
---|
883 | rc = GetSystemMetrics(SM_CYMINIMIZED);
|
---|
884 | break;
|
---|
885 | case SM_CXICON:
|
---|
886 | case SM_CYICON:
|
---|
887 | rc = 32; //CB: Win32: only 32x32, OS/2 32x32/40x40
|
---|
888 | // we must implement 32x32 for all screen resolutions
|
---|
889 | break;
|
---|
890 | case SM_CXSMICON: //recommended size of small icons (TODO: adjust to screen res.)
|
---|
891 | rc = 16;
|
---|
892 | break;
|
---|
893 | case SM_CYSMICON:
|
---|
894 | rc = 16;
|
---|
895 | break;
|
---|
896 | case SM_CYSMCAPTION: //size in pixels of a small caption (TODO: ????)
|
---|
897 | rc = 8;
|
---|
898 | break;
|
---|
899 | case SM_CXSMSIZE: //size of small caption buttons (pixels) (TODO: implement properly)
|
---|
900 | rc = 16;
|
---|
901 | break;
|
---|
902 | case SM_CYSMSIZE:
|
---|
903 | rc = 16;
|
---|
904 | break;
|
---|
905 | case SM_CXMENUSIZE: //TODO: size of menu bar buttons (such as MDI window close)
|
---|
906 | rc = 16;
|
---|
907 | break;
|
---|
908 | case SM_CYMENUSIZE:
|
---|
909 | rc = 16;
|
---|
910 | break;
|
---|
911 | case SM_ARRANGE:
|
---|
912 | rc = ARW_BOTTOMLEFT | ARW_LEFT;
|
---|
913 | break;
|
---|
914 | case SM_CXMINIMIZED:
|
---|
915 | break;
|
---|
916 | case SM_CYMINIMIZED:
|
---|
917 | break;
|
---|
918 | case SM_CXMAXTRACK: //max window size
|
---|
919 | case SM_CXMAXIMIZED: //max toplevel window size
|
---|
920 | rc = OSLibWinQuerySysValue(OSLIB_HWND_DESKTOP,SVOS_CXSCREEN);
|
---|
921 | break;
|
---|
922 | case SM_CYMAXTRACK:
|
---|
923 | case SM_CYMAXIMIZED:
|
---|
924 | rc = OSLibWinQuerySysValue(OSLIB_HWND_DESKTOP,SVOS_CYSCREEN);
|
---|
925 | break;
|
---|
926 | case SM_NETWORK:
|
---|
927 | rc = 0x01; //TODO: default = yes
|
---|
928 | break;
|
---|
929 | case SM_CLEANBOOT:
|
---|
930 | rc = 0; //normal boot
|
---|
931 | break;
|
---|
932 | case SM_CXDRAG: //nr of pixels before drag becomes a real one
|
---|
933 | rc = 2;
|
---|
934 | break;
|
---|
935 | case SM_CYDRAG:
|
---|
936 | rc = 2;
|
---|
937 | break;
|
---|
938 | case SM_SHOWSOUNDS: //show instead of play sound
|
---|
939 | rc = FALSE;
|
---|
940 | break;
|
---|
941 | case SM_CXMENUCHECK:
|
---|
942 | rc = 4; //TODO
|
---|
943 | break;
|
---|
944 | case SM_CYMENUCHECK:
|
---|
945 | rc = OSLibWinQuerySysValue(OSLIB_HWND_DESKTOP,SVOS_CYMENU);
|
---|
946 | break;
|
---|
947 | case SM_SLOWMACHINE:
|
---|
948 | rc = FALSE; //even a slow machine is fast with OS/2 :)
|
---|
949 | break;
|
---|
950 | case SM_MIDEASTENABLED:
|
---|
951 | rc = FALSE;
|
---|
952 | break;
|
---|
953 | case SM_CMETRICS:
|
---|
954 | //CB: replace with const
|
---|
955 | rc = O32_GetSystemMetrics(44); //Open32 changed this one
|
---|
956 | break;
|
---|
957 | default:
|
---|
958 | //better than nothing
|
---|
959 | rc = O32_GetSystemMetrics(nIndex);
|
---|
960 | break;
|
---|
961 | }
|
---|
962 | #ifdef DEBUG
|
---|
963 | WriteLog("USER32: GetSystemMetrics %d returned %d\n", nIndex, rc);
|
---|
964 | #endif
|
---|
965 | return(rc);
|
---|
966 | }
|
---|
967 | //******************************************************************************
|
---|
968 | /* Not support by Open32 (not included are the new win9x parameters):
|
---|
969 | case SPI_GETFASTTASKSWITCH:
|
---|
970 | case SPI_GETGRIDGRANULARITY:
|
---|
971 | case SPI_GETICONTITLELOGFONT:
|
---|
972 | case SPI_GETICONTITLEWRAP:
|
---|
973 | case SPI_GETMENUDROPALIGNMENT:
|
---|
974 | case SPI_ICONHORIZONTALSPACING:
|
---|
975 | case SPI_ICONVERTICALSPACING:
|
---|
976 | case SPI_LANGDRIVER:
|
---|
977 | case SPI_SETFASTTASKSWITCH:
|
---|
978 | case SPI_SETGRIDGRANULARITY:
|
---|
979 | case SPI_SETICONTITLELOGFONT:
|
---|
980 | case SPI_SETICONTITLEWRAP:
|
---|
981 | case SPI_SETMENUDROPALIGNMENT:
|
---|
982 | case SPI_GETSCREENSAVEACTIVE:
|
---|
983 | case SPI_GETSCREENSAVETIMEOUT:
|
---|
984 | case SPI_SETDESKPATTERN:
|
---|
985 | case SPI_SETDESKWALLPAPER:
|
---|
986 | case SPI_SETSCREENSAVEACTIVE:
|
---|
987 | case SPI_SETSCREENSAVETIMEOUT:
|
---|
988 | */
|
---|
989 | //******************************************************************************
|
---|
990 | BOOL WIN32API SystemParametersInfoA(UINT uiAction, UINT uiParam, PVOID pvParam, UINT fWinIni)
|
---|
991 | {
|
---|
992 | BOOL rc = TRUE;
|
---|
993 | NONCLIENTMETRICSA *cmetric = (NONCLIENTMETRICSA *)pvParam;
|
---|
994 |
|
---|
995 | switch(uiAction) {
|
---|
996 | case SPI_SCREENSAVERRUNNING:
|
---|
997 | *(BOOL *)pvParam = FALSE;
|
---|
998 | break;
|
---|
999 | case SPI_GETDRAGFULLWINDOWS:
|
---|
1000 | *(BOOL *)pvParam = FALSE;
|
---|
1001 | break;
|
---|
1002 | case SPI_GETNONCLIENTMETRICS:
|
---|
1003 | memset(cmetric, 0, sizeof(NONCLIENTMETRICSA));
|
---|
1004 | cmetric->cbSize = sizeof(NONCLIENTMETRICSA);
|
---|
1005 |
|
---|
1006 | //CB: fonts not handled by Open32, set to WarpSans
|
---|
1007 | lstrcpyA(cmetric->lfCaptionFont.lfFaceName,"WarpSans");
|
---|
1008 | cmetric->lfCaptionFont.lfHeight = 9;
|
---|
1009 |
|
---|
1010 | lstrcpyA(cmetric->lfMenuFont.lfFaceName,"WarpSans");
|
---|
1011 | cmetric->lfMenuFont.lfHeight = 9;
|
---|
1012 |
|
---|
1013 | lstrcpyA(cmetric->lfStatusFont.lfFaceName,"WarpSans");
|
---|
1014 | cmetric->lfStatusFont.lfHeight = 9;
|
---|
1015 |
|
---|
1016 | lstrcpyA(cmetric->lfMessageFont.lfFaceName,"WarpSans");
|
---|
1017 | cmetric->lfMessageFont.lfHeight = 9;
|
---|
1018 |
|
---|
1019 | cmetric->iBorderWidth = GetSystemMetrics(SM_CXBORDER);
|
---|
1020 | cmetric->iScrollWidth = GetSystemMetrics(SM_CXHSCROLL);
|
---|
1021 | cmetric->iScrollHeight = GetSystemMetrics(SM_CYHSCROLL);
|
---|
1022 | cmetric->iCaptionWidth = 32; //TODO
|
---|
1023 | cmetric->iCaptionHeight = 16; //TODO
|
---|
1024 | cmetric->iSmCaptionWidth = GetSystemMetrics(SM_CXSMSIZE);
|
---|
1025 | cmetric->iSmCaptionHeight = GetSystemMetrics(SM_CYSMSIZE);
|
---|
1026 | cmetric->iMenuWidth = 32; //TODO
|
---|
1027 | cmetric->iMenuHeight = GetSystemMetrics(SM_CYMENU);
|
---|
1028 | break;
|
---|
1029 | case SPI_GETICONTITLELOGFONT:
|
---|
1030 | {
|
---|
1031 | LPLOGFONTA lpLogFont = (LPLOGFONTA)pvParam;
|
---|
1032 |
|
---|
1033 | /* from now on we always have an alias for MS Sans Serif */
|
---|
1034 | strcpy(lpLogFont->lfFaceName, "MS Sans Serif");
|
---|
1035 | lpLogFont->lfHeight = -GetProfileIntA("Desktop","IconTitleSize", 8);
|
---|
1036 | lpLogFont->lfWidth = 0;
|
---|
1037 | lpLogFont->lfEscapement = lpLogFont->lfOrientation = 0;
|
---|
1038 | lpLogFont->lfWeight = FW_NORMAL;
|
---|
1039 | lpLogFont->lfItalic = FALSE;
|
---|
1040 | lpLogFont->lfStrikeOut = FALSE;
|
---|
1041 | lpLogFont->lfUnderline = FALSE;
|
---|
1042 | lpLogFont->lfCharSet = ANSI_CHARSET;
|
---|
1043 | lpLogFont->lfOutPrecision = OUT_DEFAULT_PRECIS;
|
---|
1044 | lpLogFont->lfClipPrecision = CLIP_DEFAULT_PRECIS;
|
---|
1045 | lpLogFont->lfPitchAndFamily = DEFAULT_PITCH | FF_SWISS;
|
---|
1046 | break;
|
---|
1047 | }
|
---|
1048 | case SPI_GETBORDER:
|
---|
1049 | *(INT *)pvParam = GetSystemMetrics( SM_CXFRAME );
|
---|
1050 | break;
|
---|
1051 |
|
---|
1052 | case SPI_GETWORKAREA:
|
---|
1053 | SetRect( (RECT *)pvParam, 0, 0,
|
---|
1054 | GetSystemMetrics( SM_CXSCREEN ),
|
---|
1055 | GetSystemMetrics( SM_CYSCREEN )
|
---|
1056 | );
|
---|
1057 | break;
|
---|
1058 |
|
---|
1059 | case 104: //TODO: Undocumented
|
---|
1060 | rc = 16;
|
---|
1061 | break;
|
---|
1062 | default:
|
---|
1063 | rc = O32_SystemParametersInfo(uiAction, uiParam, pvParam, fWinIni);
|
---|
1064 | break;
|
---|
1065 | }
|
---|
1066 | #ifdef DEBUG
|
---|
1067 | WriteLog("USER32: SystemParametersInfoA %d, returned %d\n", uiAction, rc);
|
---|
1068 | #endif
|
---|
1069 | return(rc);
|
---|
1070 | }
|
---|
1071 | //******************************************************************************
|
---|
1072 | //TODO: Check for more options that have different structs for Unicode!!!!
|
---|
1073 | //******************************************************************************
|
---|
1074 | BOOL WIN32API SystemParametersInfoW(UINT uiAction, UINT uiParam, PVOID pvParam, UINT fWinIni)
|
---|
1075 | {
|
---|
1076 | BOOL rc;
|
---|
1077 | NONCLIENTMETRICSW *clientMetricsW = (NONCLIENTMETRICSW *)pvParam;
|
---|
1078 | NONCLIENTMETRICSA clientMetricsA = {0};
|
---|
1079 | PVOID pvParamA;
|
---|
1080 | UINT uiParamA;
|
---|
1081 |
|
---|
1082 | switch(uiAction) {
|
---|
1083 | case SPI_SETNONCLIENTMETRICS:
|
---|
1084 | clientMetricsA.cbSize = sizeof(NONCLIENTMETRICSA);
|
---|
1085 | clientMetricsA.iBorderWidth = clientMetricsW->iBorderWidth;
|
---|
1086 | clientMetricsA.iScrollWidth = clientMetricsW->iScrollWidth;
|
---|
1087 | clientMetricsA.iScrollHeight = clientMetricsW->iScrollHeight;
|
---|
1088 | clientMetricsA.iCaptionWidth = clientMetricsW->iCaptionWidth;
|
---|
1089 | clientMetricsA.iCaptionHeight = clientMetricsW->iCaptionHeight;
|
---|
1090 | ConvertFontWA(&clientMetricsW->lfCaptionFont, &clientMetricsA.lfCaptionFont);
|
---|
1091 | clientMetricsA.iSmCaptionWidth = clientMetricsW->iSmCaptionWidth;
|
---|
1092 | clientMetricsA.iSmCaptionHeight = clientMetricsW->iSmCaptionHeight;
|
---|
1093 | ConvertFontWA(&clientMetricsW->lfSmCaptionFont, &clientMetricsA.lfSmCaptionFont);
|
---|
1094 | clientMetricsA.iMenuWidth = clientMetricsW->iMenuWidth;
|
---|
1095 | clientMetricsA.iMenuHeight = clientMetricsW->iMenuHeight;
|
---|
1096 | ConvertFontWA(&clientMetricsW->lfMenuFont, &clientMetricsA.lfMenuFont);
|
---|
1097 | ConvertFontWA(&clientMetricsW->lfStatusFont, &clientMetricsA.lfStatusFont);
|
---|
1098 | ConvertFontWA(&clientMetricsW->lfMessageFont, &clientMetricsA.lfMessageFont);
|
---|
1099 | //no break
|
---|
1100 | case SPI_GETNONCLIENTMETRICS:
|
---|
1101 | uiParamA = sizeof(NONCLIENTMETRICSA);
|
---|
1102 | pvParamA = &clientMetricsA;
|
---|
1103 | break;
|
---|
1104 | case SPI_GETICONTITLELOGFONT:
|
---|
1105 | {
|
---|
1106 | LPLOGFONTW lpLogFont = (LPLOGFONTW)pvParam;
|
---|
1107 |
|
---|
1108 | /* from now on we always have an alias for MS Sans Serif */
|
---|
1109 | lstrcpyW(lpLogFont->lfFaceName, (LPCWSTR)L"MS Sans Serif");
|
---|
1110 | lpLogFont->lfHeight = -GetProfileIntA("Desktop","IconTitleSize", 8);
|
---|
1111 | lpLogFont->lfWidth = 0;
|
---|
1112 | lpLogFont->lfEscapement = lpLogFont->lfOrientation = 0;
|
---|
1113 | lpLogFont->lfWeight = FW_NORMAL;
|
---|
1114 | lpLogFont->lfItalic = FALSE;
|
---|
1115 | lpLogFont->lfStrikeOut = FALSE;
|
---|
1116 | lpLogFont->lfUnderline = FALSE;
|
---|
1117 | lpLogFont->lfCharSet = ANSI_CHARSET;
|
---|
1118 | lpLogFont->lfOutPrecision = OUT_DEFAULT_PRECIS;
|
---|
1119 | lpLogFont->lfClipPrecision = CLIP_DEFAULT_PRECIS;
|
---|
1120 | lpLogFont->lfPitchAndFamily = DEFAULT_PITCH | FF_SWISS;
|
---|
1121 | return TRUE;
|
---|
1122 | }
|
---|
1123 | default:
|
---|
1124 | pvParamA = pvParam;
|
---|
1125 | uiParamA = uiParam;
|
---|
1126 | break;
|
---|
1127 | }
|
---|
1128 | rc = SystemParametersInfoA(uiAction, uiParamA, pvParamA, fWinIni);
|
---|
1129 |
|
---|
1130 | switch(uiAction) {
|
---|
1131 | case SPI_GETNONCLIENTMETRICS:
|
---|
1132 | clientMetricsW->cbSize = sizeof(*clientMetricsW);
|
---|
1133 | clientMetricsW->iBorderWidth = clientMetricsA.iBorderWidth;
|
---|
1134 | clientMetricsW->iScrollWidth = clientMetricsA.iScrollWidth;
|
---|
1135 | clientMetricsW->iScrollHeight = clientMetricsA.iScrollHeight;
|
---|
1136 | clientMetricsW->iCaptionWidth = clientMetricsA.iCaptionWidth;
|
---|
1137 | clientMetricsW->iCaptionHeight = clientMetricsA.iCaptionHeight;
|
---|
1138 | ConvertFontAW(&clientMetricsA.lfCaptionFont, &clientMetricsW->lfCaptionFont);
|
---|
1139 |
|
---|
1140 | clientMetricsW->iSmCaptionWidth = clientMetricsA.iSmCaptionWidth;
|
---|
1141 | clientMetricsW->iSmCaptionHeight = clientMetricsA.iSmCaptionHeight;
|
---|
1142 | ConvertFontAW(&clientMetricsA.lfSmCaptionFont, &clientMetricsW->lfSmCaptionFont);
|
---|
1143 |
|
---|
1144 | clientMetricsW->iMenuWidth = clientMetricsA.iMenuWidth;
|
---|
1145 | clientMetricsW->iMenuHeight = clientMetricsA.iMenuHeight;
|
---|
1146 | ConvertFontAW(&clientMetricsA.lfMenuFont, &clientMetricsW->lfMenuFont);
|
---|
1147 | ConvertFontAW(&clientMetricsA.lfStatusFont, &clientMetricsW->lfStatusFont);
|
---|
1148 | ConvertFontAW(&clientMetricsA.lfMessageFont, &clientMetricsW->lfMessageFont);
|
---|
1149 | break;
|
---|
1150 | }
|
---|
1151 | #ifdef DEBUG
|
---|
1152 | WriteLog("USER32: SystemParametersInfoW %d, returned %d\n", uiAction, rc);
|
---|
1153 | #endif
|
---|
1154 | return(rc);
|
---|
1155 | }
|
---|
1156 |
|
---|
1157 | /* Timer Functions */
|
---|
1158 |
|
---|
1159 | #if 0
|
---|
1160 | BOOL WIN32API KillTimer(HWND hWnd, UINT uIDEvent)
|
---|
1161 | {
|
---|
1162 | #ifdef DEBUG
|
---|
1163 | WriteLog("USER32: KillTimer\n");
|
---|
1164 | #endif
|
---|
1165 | hWnd = Win32Window::Win32ToOS2Handle(hWnd);
|
---|
1166 | //WinStopTimer
|
---|
1167 | //CB: replace
|
---|
1168 | return O32_KillTimer(hWnd,uIDEvent);
|
---|
1169 | }
|
---|
1170 | //******************************************************************************
|
---|
1171 | //******************************************************************************
|
---|
1172 | UINT WIN32API SetTimer( HWND hwnd, UINT idTimer, UINT uTimeout, TIMERPROC tmprc)
|
---|
1173 | {
|
---|
1174 | #ifdef DEBUG
|
---|
1175 | WriteLog("USER32: SetTimer INCORRECT CALLING CONVENTION FOR HANDLER!!!!!\n");
|
---|
1176 | #endif
|
---|
1177 | hwnd = Win32Window::Win32ToOS2Handle(hwnd);
|
---|
1178 | //SvL: Write callback handler class for this one
|
---|
1179 | //CB: replace
|
---|
1180 | return O32_SetTimer(hwnd,idTimer,uTimeout,(TIMERPROC_O32)tmprc);
|
---|
1181 | }
|
---|
1182 | #endif
|
---|
1183 |
|
---|
1184 | /* Process and Thread Functions */
|
---|
1185 |
|
---|
1186 | //******************************************************************************
|
---|
1187 | //DWORD idAttach; /* thread to attach */
|
---|
1188 | //DWORD idAttachTo; /* thread to attach to */
|
---|
1189 | //BOOL fAttach; /* attach or detach */
|
---|
1190 | //******************************************************************************
|
---|
1191 | BOOL WIN32API AttachThreadInput(DWORD idAttach, DWORD idAttachTo, BOOL fAttach)
|
---|
1192 | {
|
---|
1193 | #ifdef DEBUG
|
---|
1194 | WriteLog("USER32: AttachThreadInput, not implemented\n");
|
---|
1195 | #endif
|
---|
1196 | return(TRUE);
|
---|
1197 | }
|
---|
1198 | //******************************************************************************
|
---|
1199 | //TODO:How can we emulate this one in OS/2???
|
---|
1200 | //******************************************************************************
|
---|
1201 | DWORD WIN32API WaitForInputIdle(HANDLE hProcess, DWORD dwTimeOut)
|
---|
1202 | {
|
---|
1203 | #ifdef DEBUG
|
---|
1204 | WriteLog("USER32: WaitForInputIdle (Not Implemented) %d\n", dwTimeOut);
|
---|
1205 | #endif
|
---|
1206 |
|
---|
1207 | if(dwTimeOut == INFINITE) return(0);
|
---|
1208 |
|
---|
1209 | // DosSleep(dwTimeOut/16);
|
---|
1210 | return(0);
|
---|
1211 | }
|
---|
1212 |
|
---|
1213 | /* Help Functions */
|
---|
1214 |
|
---|
1215 | DWORD WIN32API GetWindowContextHelpId(HWND hwnd)
|
---|
1216 | {
|
---|
1217 | #ifdef DEBUG
|
---|
1218 | WriteLog("USER32: GetWindowContextHelpId, not implemented\n");
|
---|
1219 | #endif
|
---|
1220 | hwnd = Win32Window::Win32ToOS2Handle(hwnd);
|
---|
1221 |
|
---|
1222 | return(0);
|
---|
1223 | }
|
---|
1224 | //******************************************************************************
|
---|
1225 | //******************************************************************************
|
---|
1226 | BOOL WIN32API SetWindowContextHelpId(HWND hwnd, DWORD dwContextHelpId)
|
---|
1227 | {
|
---|
1228 | #ifdef DEBUG
|
---|
1229 | WriteLog("USER32: SetWindowContextHelpId, not implemented\n");
|
---|
1230 | #endif
|
---|
1231 | hwnd = Win32Window::Win32ToOS2Handle(hwnd);
|
---|
1232 |
|
---|
1233 | return(TRUE);
|
---|
1234 | }
|
---|
1235 | //******************************************************************************
|
---|
1236 | //******************************************************************************
|
---|
1237 | BOOL WIN32API WinHelpA( HWND hwnd, LPCSTR lpszHelp, UINT uCommand, DWORD dwData)
|
---|
1238 | {
|
---|
1239 | #ifdef DEBUG
|
---|
1240 | WriteLog("USER32: WinHelp not implemented %s\n", lpszHelp);
|
---|
1241 | #endif
|
---|
1242 | // hwnd = Win32Window::Win32ToOS2Handle(hwnd);
|
---|
1243 | // return O32_WinHelp(arg1, arg2, arg3, arg4);
|
---|
1244 |
|
---|
1245 | return(TRUE);
|
---|
1246 | }
|
---|
1247 | //******************************************************************************
|
---|
1248 | //******************************************************************************
|
---|
1249 | BOOL WIN32API WinHelpW( HWND arg1, LPCWSTR arg2, UINT arg3, DWORD arg4)
|
---|
1250 | {
|
---|
1251 | char *astring = UnicodeToAsciiString((LPWSTR)arg2);
|
---|
1252 | BOOL rc;
|
---|
1253 |
|
---|
1254 | #ifdef DEBUG
|
---|
1255 | WriteLog("USER32: WinHelpW\n");
|
---|
1256 | #endif
|
---|
1257 | rc = WinHelpA(arg1, astring, arg3, arg4);
|
---|
1258 | FreeAsciiString(astring);
|
---|
1259 | return rc;
|
---|
1260 | }
|
---|
1261 |
|
---|
1262 | /* Keyboard and Input Functions */
|
---|
1263 |
|
---|
1264 | BOOL WIN32API ActivateKeyboardLayout(HKL hkl, UINT fuFlags)
|
---|
1265 | {
|
---|
1266 | #ifdef DEBUG
|
---|
1267 | WriteLog("USER32: ActivateKeyboardLayout, not implemented\n");
|
---|
1268 | #endif
|
---|
1269 | return(TRUE);
|
---|
1270 | }
|
---|
1271 | //******************************************************************************
|
---|
1272 | //SvL: 24-6-'97 - Added
|
---|
1273 | //TODO: Not implemented
|
---|
1274 | //******************************************************************************
|
---|
1275 | WORD WIN32API GetAsyncKeyState(INT nVirtKey)
|
---|
1276 | {
|
---|
1277 | #ifdef DEBUG
|
---|
1278 | //// WriteLog("USER32: GetAsyncKeyState Not implemented\n");
|
---|
1279 | #endif
|
---|
1280 | return 0;
|
---|
1281 | }
|
---|
1282 | /*****************************************************************************
|
---|
1283 | * Name : UINT WIN32API GetKBCodePage
|
---|
1284 | * Purpose : The GetKBCodePage function is provided for compatibility with
|
---|
1285 | * earlier versions of Windows. In the Win32 application programming
|
---|
1286 | * interface (API) it just calls the GetOEMCP function.
|
---|
1287 | * Parameters:
|
---|
1288 | * Variables :
|
---|
1289 | * Result : If the function succeeds, the return value is an OEM code-page
|
---|
1290 | * identifier, or it is the default identifier if the registry
|
---|
1291 | * value is not readable. For a list of OEM code-page identifiers,
|
---|
1292 | * see GetOEMCP.
|
---|
1293 | * Remark :
|
---|
1294 | * Status : UNTESTED
|
---|
1295 | *
|
---|
1296 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1297 | *****************************************************************************/
|
---|
1298 |
|
---|
1299 | UINT WIN32API GetKBCodePage(VOID)
|
---|
1300 | {
|
---|
1301 | return (GetOEMCP());
|
---|
1302 | }
|
---|
1303 | /*****************************************************************************
|
---|
1304 | * Name : BOOL WIN32API GetKeyboardLayoutNameA
|
---|
1305 | * Purpose : The GetKeyboardLayoutName function retrieves the name of the
|
---|
1306 | * active keyboard layout.
|
---|
1307 | * Parameters: LPTSTR pwszKLID address of buffer for layout name
|
---|
1308 | * Variables :
|
---|
1309 | * Result : If the function succeeds, the return value is TRUE.
|
---|
1310 | * If the function fails, the return value is FALSE. To get extended
|
---|
1311 | * error information, call GetLastError.
|
---|
1312 | * Remark :
|
---|
1313 | * Status : UNTESTED STUB
|
---|
1314 | *
|
---|
1315 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1316 | *****************************************************************************/
|
---|
1317 | // @@@PH Win32 BOOL's are casted to INTs
|
---|
1318 | INT WIN32API GetKeyboardLayoutNameA(LPTSTR pwszKLID)
|
---|
1319 | {
|
---|
1320 | dprintf(("USER32:GetKeyboardLayoutNameA (%08x) not implemented.",
|
---|
1321 | pwszKLID));
|
---|
1322 |
|
---|
1323 | return(FALSE);
|
---|
1324 | }
|
---|
1325 | //******************************************************************************
|
---|
1326 | //******************************************************************************
|
---|
1327 | int WIN32API GetKeyboardLayoutList(int nBuff, HKL *lpList)
|
---|
1328 | {
|
---|
1329 | #ifdef DEBUG
|
---|
1330 | WriteLog("USER32: GetKeyboardLayoutList, not implemented\n");
|
---|
1331 | #endif
|
---|
1332 | return(0);
|
---|
1333 | }
|
---|
1334 | //******************************************************************************
|
---|
1335 | //******************************************************************************
|
---|
1336 | HKL WIN32API GetKeyboardLayout(DWORD dwLayout)
|
---|
1337 | {
|
---|
1338 | #ifdef DEBUG
|
---|
1339 | WriteLog("USER32: GetKeyboardLayout, not implemented\n");
|
---|
1340 | #endif
|
---|
1341 | return(0);
|
---|
1342 | }
|
---|
1343 | /*****************************************************************************
|
---|
1344 | * Name : BOOL WIN32API GetKeyboardLayoutNameW
|
---|
1345 | * Purpose : The GetKeyboardLayoutName function retrieves the name of the
|
---|
1346 | * active keyboard layout.
|
---|
1347 | * Parameters: LPTSTR pwszKLID address of buffer for layout name
|
---|
1348 | * Variables :
|
---|
1349 | * Result : If the function succeeds, the return value is TRUE.
|
---|
1350 | * If the function fails, the return value is FALSE. To get extended
|
---|
1351 | * error information, call GetLastError.
|
---|
1352 | * Remark :
|
---|
1353 | * Status : UNTESTED STUB
|
---|
1354 | *
|
---|
1355 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1356 | *****************************************************************************/
|
---|
1357 | // @@@PH Win32 BOOL's are casted to INTs
|
---|
1358 | INT WIN32API GetKeyboardLayoutNameW(LPWSTR pwszKLID)
|
---|
1359 | {
|
---|
1360 | dprintf(("USER32:GetKeyboardLayoutNameW (%08x) not implemented.",
|
---|
1361 | pwszKLID));
|
---|
1362 |
|
---|
1363 | return(FALSE);
|
---|
1364 | }
|
---|
1365 | //******************************************************************************
|
---|
1366 | //******************************************************************************
|
---|
1367 | BOOL WIN32API GetKeyboardState(PBYTE lpKeyState)
|
---|
1368 | {
|
---|
1369 | #ifdef DEBUG
|
---|
1370 | WriteLog("USER32: GetKeyboardState, not properly implemented\n");
|
---|
1371 | #endif
|
---|
1372 | memset(lpKeyState, 0, 256);
|
---|
1373 | return(TRUE);
|
---|
1374 | }
|
---|
1375 | //******************************************************************************
|
---|
1376 | //******************************************************************************
|
---|
1377 | int WIN32API GetKeyNameTextA( LPARAM lParam, LPSTR lpString, int nSize)
|
---|
1378 | {
|
---|
1379 | #ifdef DEBUG
|
---|
1380 | WriteLog("USER32: GetKeyNameTextA\n");
|
---|
1381 | #endif
|
---|
1382 | return O32_GetKeyNameText(lParam,lpString,nSize);
|
---|
1383 | }
|
---|
1384 | //******************************************************************************
|
---|
1385 | //******************************************************************************
|
---|
1386 | int WIN32API GetKeyNameTextW( LPARAM lParam, LPWSTR lpString, int nSize)
|
---|
1387 | {
|
---|
1388 | #ifdef DEBUG
|
---|
1389 | WriteLog("USER32: GetKeyNameTextW DOES NOT WORK\n");
|
---|
1390 | #endif
|
---|
1391 | // NOTE: This will not work as is (needs UNICODE support)
|
---|
1392 | return 0;
|
---|
1393 | // return O32_GetKeyNameText(arg1, arg2, arg3);
|
---|
1394 | }
|
---|
1395 | //******************************************************************************
|
---|
1396 | //SvL: 24-6-'97 - Added
|
---|
1397 | //******************************************************************************
|
---|
1398 | SHORT WIN32API GetKeyState( int nVirtKey)
|
---|
1399 | {
|
---|
1400 | //SvL: Hehe. 32 MB logfile for Opera after a minute.
|
---|
1401 | #ifdef DEBUG
|
---|
1402 | // WriteLog("USER32: GetKeyState %d\n", nVirtKey);
|
---|
1403 | #endif
|
---|
1404 | return O32_GetKeyState(nVirtKey);
|
---|
1405 | }
|
---|
1406 | /*****************************************************************************
|
---|
1407 | * Name : VOID WIN32API keybd_event
|
---|
1408 | * Purpose : The keybd_event function synthesizes a keystroke. The system
|
---|
1409 | * can use such a synthesized keystroke to generate a WM_KEYUP or
|
---|
1410 | * WM_KEYDOWN message. The keyboard driver's interrupt handler calls
|
---|
1411 | * the keybd_event function.
|
---|
1412 | * Parameters: BYTE bVk virtual-key code
|
---|
1413 |
|
---|
1414 | * BYTE bScan hardware scan code
|
---|
1415 | * DWORD dwFlags flags specifying various function options
|
---|
1416 | * DWORD dwExtraInfo additional data associated with keystroke
|
---|
1417 | * Variables :
|
---|
1418 | * Result :
|
---|
1419 | * Remark :
|
---|
1420 | * Status : UNTESTED STUB
|
---|
1421 | *
|
---|
1422 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1423 | *****************************************************************************/
|
---|
1424 | VOID WIN32API keybd_event (BYTE bVk,
|
---|
1425 | BYTE bScan,
|
---|
1426 | DWORD dwFlags,
|
---|
1427 | DWORD dwExtraInfo)
|
---|
1428 | {
|
---|
1429 | dprintf(("USER32:keybd_event (%u,%u,%08xh,%08x) not implemented.\n",
|
---|
1430 | bVk,
|
---|
1431 | bScan,
|
---|
1432 | dwFlags,
|
---|
1433 | dwExtraInfo));
|
---|
1434 | }
|
---|
1435 | /*****************************************************************************
|
---|
1436 | * Name : HLK WIN32API LoadKeyboardLayoutA
|
---|
1437 | * Purpose : The LoadKeyboardLayout function loads a new keyboard layout into
|
---|
1438 | * the system. Several keyboard layouts can be loaded at a time, but
|
---|
1439 | * only one per process is active at a time. Loading multiple keyboard
|
---|
1440 | * layouts makes it possible to rapidly switch between layouts.
|
---|
1441 | * Parameters:
|
---|
1442 | * Variables :
|
---|
1443 | * Result : If the function succeeds, the return value is the handle of the
|
---|
1444 | * keyboard layout.
|
---|
1445 | * If the function fails, the return value is NULL. To get extended
|
---|
1446 | * error information, call GetLastError.
|
---|
1447 | * Remark :
|
---|
1448 | * Status : UNTESTED STUB
|
---|
1449 | *
|
---|
1450 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1451 | *****************************************************************************/
|
---|
1452 | HKL WIN32API LoadKeyboardLayoutA(LPCTSTR pwszKLID,
|
---|
1453 | UINT Flags)
|
---|
1454 | {
|
---|
1455 | dprintf(("USER32:LeadKeyboardLayoutA (%s,%u) not implemented.\n",
|
---|
1456 | pwszKLID,
|
---|
1457 | Flags));
|
---|
1458 |
|
---|
1459 | return (NULL);
|
---|
1460 | }
|
---|
1461 | /*****************************************************************************
|
---|
1462 | * Name : HLK WIN32API LoadKeyboardLayoutW
|
---|
1463 | * Purpose : The LoadKeyboardLayout function loads a new keyboard layout into
|
---|
1464 | * the system. Several keyboard layouts can be loaded at a time, but
|
---|
1465 | * only one per process is active at a time. Loading multiple keyboard
|
---|
1466 | * layouts makes it possible to rapidly switch between layouts.
|
---|
1467 | * Parameters:
|
---|
1468 | * Variables :
|
---|
1469 | * Result : If the function succeeds, the return value is the handle of the
|
---|
1470 | * keyboard layout.
|
---|
1471 | * If the function fails, the return value is NULL. To get extended
|
---|
1472 | * error information, call GetLastError.
|
---|
1473 | * Remark :
|
---|
1474 | * Status : UNTESTED STUB
|
---|
1475 | *
|
---|
1476 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1477 | *****************************************************************************/
|
---|
1478 | HKL WIN32API LoadKeyboardLayoutW(LPCWSTR pwszKLID,
|
---|
1479 | UINT Flags)
|
---|
1480 | {
|
---|
1481 | dprintf(("USER32:LeadKeyboardLayoutW (%s,%u) not implemented.\n",
|
---|
1482 | pwszKLID,
|
---|
1483 | Flags));
|
---|
1484 |
|
---|
1485 | return (NULL);
|
---|
1486 | }
|
---|
1487 | //******************************************************************************
|
---|
1488 | //******************************************************************************
|
---|
1489 | UINT WIN32API MapVirtualKeyA( UINT uCode, UINT uMapType)
|
---|
1490 | {
|
---|
1491 | #ifdef DEBUG
|
---|
1492 | WriteLog("USER32: MapVirtualKeyA\n");
|
---|
1493 | #endif
|
---|
1494 | return O32_MapVirtualKey(uCode,uMapType);
|
---|
1495 | }
|
---|
1496 | //******************************************************************************
|
---|
1497 | //******************************************************************************
|
---|
1498 | UINT WIN32API MapVirtualKeyW( UINT uCode, UINT uMapType)
|
---|
1499 | {
|
---|
1500 | #ifdef DEBUG
|
---|
1501 | WriteLog("USER32: MapVirtualKeyW\n");
|
---|
1502 | #endif
|
---|
1503 | // NOTE: This will not work as is (needs UNICODE support)
|
---|
1504 | return O32_MapVirtualKey(uCode,uMapType);
|
---|
1505 | }
|
---|
1506 | /*****************************************************************************
|
---|
1507 | * Name : UINT WIN32API MapVirtualKeyExA
|
---|
1508 | * Purpose : The MapVirtualKeyEx function translates (maps) a virtual-key
|
---|
1509 | * code into a scan code or character value, or translates a scan
|
---|
1510 | * code into a virtual-key code. The function translates the codes
|
---|
1511 | * using the input language and physical keyboard layout identified
|
---|
1512 | * by the given keyboard layout handle.
|
---|
1513 | * Parameters:
|
---|
1514 | * Variables :
|
---|
1515 | * Result : The return value is either a scan code, a virtual-key code, or
|
---|
1516 | * a character value, depending on the value of uCode and uMapType.
|
---|
1517 | * If there is no translation, the return value is zero.
|
---|
1518 | * Remark :
|
---|
1519 | * Status : UNTESTED STUB
|
---|
1520 | *
|
---|
1521 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1522 | *****************************************************************************/
|
---|
1523 | UINT WIN32API MapVirtualKeyExA(UINT uCode,
|
---|
1524 | UINT uMapType,
|
---|
1525 | HKL dwhkl)
|
---|
1526 | {
|
---|
1527 | dprintf(("USER32:MapVirtualKeyExA (%u,%u,%08x) not implemented.\n",
|
---|
1528 | uCode,
|
---|
1529 | uMapType,
|
---|
1530 | dwhkl));
|
---|
1531 |
|
---|
1532 | return (0);
|
---|
1533 | }
|
---|
1534 | /*****************************************************************************
|
---|
1535 | * Name : UINT WIN32API MapVirtualKeyExW
|
---|
1536 | * Purpose : The MapVirtualKeyEx function translates (maps) a virtual-key
|
---|
1537 | * code into a scan code or character value, or translates a scan
|
---|
1538 | * code into a virtual-key code. The function translates the codes
|
---|
1539 | * using the input language and physical keyboard layout identified
|
---|
1540 | * by the given keyboard layout handle.
|
---|
1541 | * Parameters:
|
---|
1542 | * Variables :
|
---|
1543 | * Result : The return value is either a scan code, a virtual-key code, or
|
---|
1544 | * a character value, depending on the value of uCode and uMapType.
|
---|
1545 | * If there is no translation, the return value is zero.
|
---|
1546 | * Remark :
|
---|
1547 | * Status : UNTESTED STUB
|
---|
1548 |
|
---|
1549 | *
|
---|
1550 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1551 | *****************************************************************************/
|
---|
1552 | UINT WIN32API MapVirtualKeyExW(UINT uCode,
|
---|
1553 | UINT uMapType,
|
---|
1554 | HKL dwhkl)
|
---|
1555 | {
|
---|
1556 | dprintf(("USER32:MapVirtualKeyExW (%u,%u,%08x) not implemented.\n",
|
---|
1557 | uCode,
|
---|
1558 | uMapType,
|
---|
1559 | dwhkl));
|
---|
1560 |
|
---|
1561 | return (0);
|
---|
1562 | }
|
---|
1563 | /*****************************************************************************
|
---|
1564 | * Name : DWORD WIN32API OemKeyScan
|
---|
1565 | * Purpose : The OemKeyScan function maps OEM ASCII codes 0 through 0x0FF
|
---|
1566 | * into the OEM scan codes and shift states. The function provides
|
---|
1567 | * information that allows a program to send OEM text to another
|
---|
1568 | * program by simulating keyboard input.
|
---|
1569 | * Parameters:
|
---|
1570 | * Variables :
|
---|
1571 | * Result :
|
---|
1572 | * Remark :
|
---|
1573 | * Status : UNTESTED STUB
|
---|
1574 | *
|
---|
1575 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1576 | *****************************************************************************/
|
---|
1577 | DWORD WIN32API OemKeyScan(WORD wOemChar)
|
---|
1578 | {
|
---|
1579 | dprintf(("USER32:OemKeyScan (%u) not implemented.\n",
|
---|
1580 | wOemChar));
|
---|
1581 |
|
---|
1582 | return (wOemChar);
|
---|
1583 | }
|
---|
1584 | //******************************************************************************
|
---|
1585 | //******************************************************************************
|
---|
1586 | BOOL WIN32API RegisterHotKey(HWND hwnd, int idHotKey, UINT fuModifiers, UINT uVirtKey)
|
---|
1587 | {
|
---|
1588 | #ifdef DEBUG
|
---|
1589 | WriteLog("USER32: RegisterHotKey, not implemented\n");
|
---|
1590 | #endif
|
---|
1591 | hwnd = Win32Window::Win32ToOS2Handle(hwnd);
|
---|
1592 | return(TRUE);
|
---|
1593 | }
|
---|
1594 | //******************************************************************************
|
---|
1595 | //******************************************************************************
|
---|
1596 | BOOL WIN32API SetKeyboardState(PBYTE lpKeyState)
|
---|
1597 | {
|
---|
1598 | #ifdef DEBUG
|
---|
1599 | WriteLog("USER32: SetKeyboardState, not implemented\n");
|
---|
1600 | #endif
|
---|
1601 | return(TRUE);
|
---|
1602 | }
|
---|
1603 | /*****************************************************************************
|
---|
1604 | * Name : int WIN32API ToAscii
|
---|
1605 | * Purpose : The ToAscii function translates the specified virtual-key code
|
---|
1606 | * and keyboard state to the corresponding Windows character or characters.
|
---|
1607 | * Parameters: UINT uVirtKey virtual-key code
|
---|
1608 | * UINT uScanCode scan code
|
---|
1609 | * PBYTE lpbKeyState address of key-state array
|
---|
1610 | * LPWORD lpwTransKey buffer for translated key
|
---|
1611 | * UINT fuState active-menu flag
|
---|
1612 | * Variables :
|
---|
1613 | * Result : 0 The specified virtual key has no translation for the current
|
---|
1614 | * state of the keyboard.
|
---|
1615 | * 1 One Windows character was copied to the buffer.
|
---|
1616 | * 2 Two characters were copied to the buffer. This usually happens
|
---|
1617 | * when a dead-key character (accent or diacritic) stored in the
|
---|
1618 | * keyboard layout cannot be composed with the specified virtual
|
---|
1619 | * key to form a single character.
|
---|
1620 | * Remark :
|
---|
1621 | * Status : UNTESTED STUB
|
---|
1622 | *
|
---|
1623 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1624 | *****************************************************************************/
|
---|
1625 | int WIN32API ToAscii(UINT uVirtKey,
|
---|
1626 | UINT uScanCode,
|
---|
1627 | PBYTE lpbKeyState,
|
---|
1628 | LPWORD lpwTransKey,
|
---|
1629 | UINT fuState)
|
---|
1630 | {
|
---|
1631 | dprintf(("USER32:ToAscii (%u,%u,%08xh,%08xh,%u) not implemented.\n",
|
---|
1632 | uVirtKey,
|
---|
1633 | uScanCode,
|
---|
1634 | lpbKeyState,
|
---|
1635 | lpwTransKey,
|
---|
1636 | fuState));
|
---|
1637 |
|
---|
1638 | return (0);
|
---|
1639 | }
|
---|
1640 | /*****************************************************************************
|
---|
1641 | * Name : int WIN32API ToAsciiEx
|
---|
1642 | * Purpose : The ToAscii function translates the specified virtual-key code
|
---|
1643 | * and keyboard state to the corresponding Windows character or characters.
|
---|
1644 | * Parameters: UINT uVirtKey virtual-key code
|
---|
1645 | * UINT uScanCode scan code
|
---|
1646 | * PBYTE lpbKeyState address of key-state array
|
---|
1647 | * LPWORD lpwTransKey buffer for translated key
|
---|
1648 | * UINT fuState active-menu flag
|
---|
1649 | * HLK hlk keyboard layout handle
|
---|
1650 | * Variables :
|
---|
1651 | * Result : 0 The specified virtual key has no translation for the current
|
---|
1652 | * state of the keyboard.
|
---|
1653 | * 1 One Windows character was copied to the buffer.
|
---|
1654 | * 2 Two characters were copied to the buffer. This usually happens
|
---|
1655 | * when a dead-key character (accent or diacritic) stored in the
|
---|
1656 | * keyboard layout cannot be composed with the specified virtual
|
---|
1657 | * key to form a single character.
|
---|
1658 | * Remark :
|
---|
1659 | * Status : UNTESTED STUB
|
---|
1660 | *
|
---|
1661 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1662 | *****************************************************************************/
|
---|
1663 | int WIN32API ToAsciiEx(UINT uVirtKey,
|
---|
1664 | UINT uScanCode,
|
---|
1665 | PBYTE lpbKeyState,
|
---|
1666 | LPWORD lpwTransKey,
|
---|
1667 | UINT fuState,
|
---|
1668 | HKL hkl)
|
---|
1669 | {
|
---|
1670 | dprintf(("USER32:ToAsciiEx (%u,%u,%08xh,%08xh,%u,%08x) not implemented.\n",
|
---|
1671 | uVirtKey,
|
---|
1672 | uScanCode,
|
---|
1673 | lpbKeyState,
|
---|
1674 | lpwTransKey,
|
---|
1675 | fuState,
|
---|
1676 | hkl));
|
---|
1677 |
|
---|
1678 | return (0);
|
---|
1679 | }
|
---|
1680 | /*****************************************************************************
|
---|
1681 | * Name : int WIN32API ToUnicode
|
---|
1682 | * Purpose : The ToUnicode function translates the specified virtual-key code
|
---|
1683 | * and keyboard state to the corresponding Unicode character or characters.
|
---|
1684 | * Parameters: UINT wVirtKey virtual-key code
|
---|
1685 | * UINT wScanCode scan code
|
---|
1686 | * PBYTE lpKeyState address of key-state array
|
---|
1687 | * LPWSTR pwszBuff buffer for translated key
|
---|
1688 | * int cchBuff size of translated key buffer
|
---|
1689 | * UINT wFlags set of function-conditioning flags
|
---|
1690 | * Variables :
|
---|
1691 | * Result : - 1 The specified virtual key is a dead-key character (accent or
|
---|
1692 | * diacritic). This value is returned regardless of the keyboard
|
---|
1693 | * layout, even if several characters have been typed and are
|
---|
1694 | * stored in the keyboard state. If possible, even with Unicode
|
---|
1695 | * keyboard layouts, the function has written a spacing version of
|
---|
1696 | * the dead-key character to the buffer specified by pwszBuffer.
|
---|
1697 | * For example, the function writes the character SPACING ACUTE
|
---|
1698 | * (0x00B4), rather than the character NON_SPACING ACUTE (0x0301).
|
---|
1699 | * 0 The specified virtual key has no translation for the current
|
---|
1700 | * state of the keyboard. Nothing was written to the buffer
|
---|
1701 | * specified by pwszBuffer.
|
---|
1702 | * 1 One character was written to the buffer specified by pwszBuffer.
|
---|
1703 | * 2 or more Two or more characters were written to the buffer specified by
|
---|
1704 | * pwszBuff. The most common cause for this is that a dead-key
|
---|
1705 | * character (accent or diacritic) stored in the keyboard layout
|
---|
1706 | * could not be combined with the specified virtual key to form a
|
---|
1707 | * single character.
|
---|
1708 | * Remark :
|
---|
1709 | * Status : UNTESTED STUB
|
---|
1710 | *
|
---|
1711 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1712 | *****************************************************************************/
|
---|
1713 | int WIN32API ToUnicode(UINT uVirtKey,
|
---|
1714 | UINT uScanCode,
|
---|
1715 | PBYTE lpKeyState,
|
---|
1716 | LPWSTR pwszBuff,
|
---|
1717 | int cchBuff,
|
---|
1718 | UINT wFlags)
|
---|
1719 | {
|
---|
1720 | dprintf(("USER32:ToUnicode (%u,%u,%08xh,%08xh,%u,%08x) not implemented.\n",
|
---|
1721 | uVirtKey,
|
---|
1722 | uScanCode,
|
---|
1723 | lpKeyState,
|
---|
1724 | pwszBuff,
|
---|
1725 | cchBuff,
|
---|
1726 | wFlags));
|
---|
1727 |
|
---|
1728 | return (0);
|
---|
1729 | }
|
---|
1730 | /*****************************************************************************
|
---|
1731 | * Name : BOOL WIN32API UnloadKeyboardLayout
|
---|
1732 | * Purpose : The UnloadKeyboardLayout function removes a keyboard layout.
|
---|
1733 | * Parameters: HKL hkl handle of keyboard layout
|
---|
1734 | * Variables :
|
---|
1735 | * Result : If the function succeeds, the return value is the handle of the
|
---|
1736 | * keyboard layout; otherwise, it is NULL. To get extended error
|
---|
1737 | * information, use the GetLastError function.
|
---|
1738 | * Remark :
|
---|
1739 | * Status : UNTESTED STUB
|
---|
1740 | *
|
---|
1741 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1742 | *****************************************************************************/
|
---|
1743 | BOOL WIN32API UnloadKeyboardLayout (HKL hkl)
|
---|
1744 | {
|
---|
1745 | dprintf(("USER32:UnloadKeyboardLayout (%08x) not implemented.\n",
|
---|
1746 | hkl));
|
---|
1747 |
|
---|
1748 | return (0);
|
---|
1749 | }
|
---|
1750 | //******************************************************************************
|
---|
1751 | //******************************************************************************
|
---|
1752 | BOOL WIN32API UnregisterHotKey(HWND hwnd, int idHotKey)
|
---|
1753 | {
|
---|
1754 | #ifdef DEBUG
|
---|
1755 | WriteLog("USER32: UnregisterHotKey, not implemented\n");
|
---|
1756 | #endif
|
---|
1757 | hwnd = Win32Window::Win32ToOS2Handle(hwnd);
|
---|
1758 |
|
---|
1759 | return(TRUE);
|
---|
1760 | }
|
---|
1761 | //******************************************************************************
|
---|
1762 | //SvL: 24-6-'97 - Added
|
---|
1763 | //******************************************************************************
|
---|
1764 | WORD WIN32API VkKeyScanA( char ch)
|
---|
1765 | {
|
---|
1766 | #ifdef DEBUG
|
---|
1767 | WriteLog("USER32: VkKeyScanA\n");
|
---|
1768 | #endif
|
---|
1769 | return O32_VkKeyScan(ch);
|
---|
1770 | }
|
---|
1771 | //******************************************************************************
|
---|
1772 | //******************************************************************************
|
---|
1773 | WORD WIN32API VkKeyScanW( WCHAR wch)
|
---|
1774 | {
|
---|
1775 | #ifdef DEBUG
|
---|
1776 | WriteLog("USER32: VkKeyScanW\n");
|
---|
1777 | #endif
|
---|
1778 | // NOTE: This will not work as is (needs UNICODE support)
|
---|
1779 | return O32_VkKeyScan((char)wch);
|
---|
1780 | }
|
---|
1781 | /*****************************************************************************
|
---|
1782 | * Name : SHORT WIN32API VkKeyScanExW
|
---|
1783 | * Purpose : The VkKeyScanEx function translates a character to the
|
---|
1784 | * corresponding virtual-key code and shift state. The function
|
---|
1785 | * translates the character using the input language and physical
|
---|
1786 | * keyboard layout identified by the given keyboard layout handle.
|
---|
1787 | * Parameters: UINT uChar character to translate
|
---|
1788 | * HKL hkl keyboard layout handle
|
---|
1789 | * Variables :
|
---|
1790 | * Result : see docs
|
---|
1791 | * Remark :
|
---|
1792 | * Status : UNTESTED STUB
|
---|
1793 | *
|
---|
1794 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1795 | *****************************************************************************/
|
---|
1796 | WORD WIN32API VkKeyScanExW(WCHAR uChar,
|
---|
1797 | HKL hkl)
|
---|
1798 | {
|
---|
1799 | dprintf(("USER32:VkKeyScanExW (%u,%08x) not implemented.\n",
|
---|
1800 | uChar,
|
---|
1801 | hkl));
|
---|
1802 |
|
---|
1803 | return (uChar);
|
---|
1804 | }
|
---|
1805 | /*****************************************************************************
|
---|
1806 | * Name : SHORT WIN32API VkKeyScanExA
|
---|
1807 | * Purpose : The VkKeyScanEx function translates a character to the
|
---|
1808 | * corresponding virtual-key code and shift state. The function
|
---|
1809 | * translates the character using the input language and physical
|
---|
1810 | * keyboard layout identified by the given keyboard layout handle.
|
---|
1811 | * Parameters: UINT uChar character to translate
|
---|
1812 | * HKL hkl keyboard layout handle
|
---|
1813 | * Variables :
|
---|
1814 | * Result : see docs
|
---|
1815 | * Remark :
|
---|
1816 | * Status : UNTESTED STUB
|
---|
1817 | *
|
---|
1818 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1819 | *****************************************************************************/
|
---|
1820 | WORD WIN32API VkKeyScanExA(CHAR uChar,
|
---|
1821 | HKL hkl)
|
---|
1822 | {
|
---|
1823 | dprintf(("USER32:VkKeyScanExA (%u,%08x) not implemented.\n",
|
---|
1824 | uChar,
|
---|
1825 | hkl));
|
---|
1826 |
|
---|
1827 | return (uChar);
|
---|
1828 | }
|
---|
1829 |
|
---|
1830 | /* Synchronization Functions */
|
---|
1831 | ODINFUNCTION5(DWORD,MsgWaitForMultipleObjects,DWORD, nCount,
|
---|
1832 | LPHANDLE, pHandles,
|
---|
1833 | BOOL, fWaitAll,
|
---|
1834 | DWORD, dwMilliseconds,
|
---|
1835 | DWORD, dwWakeMask)
|
---|
1836 | {
|
---|
1837 | // @@@PH that's a really difficult function to implement
|
---|
1838 |
|
---|
1839 | // @@@PH this is a temporary bugfix for WINFILE.EXE
|
---|
1840 | if (nCount == 0)
|
---|
1841 | {
|
---|
1842 | // only listens to incoming thread messages.
|
---|
1843 | return (WAIT_OBJECT_0);
|
---|
1844 | }
|
---|
1845 |
|
---|
1846 | return O32_MsgWaitForMultipleObjects(nCount,pHandles,fWaitAll,dwMilliseconds,dwWakeMask);
|
---|
1847 | }
|
---|
1848 |
|
---|
1849 | /* Button Functions */
|
---|
1850 |
|
---|
1851 | BOOL WIN32API CheckRadioButton( HWND hDlg, UINT nIDFirstButton, UINT nIDLastButton, UINT nIDCheckButton)
|
---|
1852 | {
|
---|
1853 | #ifdef DEBUG
|
---|
1854 | WriteLog("USER32: CheckRadioButton\n");
|
---|
1855 | #endif
|
---|
1856 | //CB: check radio buttons in interval
|
---|
1857 | if (nIDFirstButton > nIDLastButton)
|
---|
1858 | {
|
---|
1859 | SetLastError(ERROR_INVALID_PARAMETER);
|
---|
1860 | return (FALSE);
|
---|
1861 | }
|
---|
1862 |
|
---|
1863 | for (UINT x = nIDFirstButton;x <= nIDLastButton;x++)
|
---|
1864 | {
|
---|
1865 | SendDlgItemMessageA(hDlg,x,BM_SETCHECK,(x == nIDCheckButton) ? BST_CHECKED : BST_UNCHECKED,0);
|
---|
1866 | }
|
---|
1867 |
|
---|
1868 | return (TRUE);
|
---|
1869 | }
|
---|
1870 |
|
---|
1871 | /* Window Functions */
|
---|
1872 |
|
---|
1873 | /*****************************************************************************
|
---|
1874 | * Name : BOOL WIN32API AnyPopup
|
---|
1875 | * Purpose : The AnyPopup function indicates whether an owned, visible,
|
---|
1876 | * top-level pop-up, or overlapped window exists on the screen. The
|
---|
1877 | * function searches the entire Windows screen, not just the calling
|
---|
1878 | * application's client area.
|
---|
1879 | * Parameters: VOID
|
---|
1880 | * Variables :
|
---|
1881 | * Result : If a pop-up window exists, the return value is TRUE even if the
|
---|
1882 | * pop-up window is completely covered by other windows. Otherwise,
|
---|
1883 | * it is FALSE.
|
---|
1884 | * Remark : AnyPopup is a Windows version 1.x function and is retained for
|
---|
1885 | * compatibility purposes. It is generally not useful.
|
---|
1886 | * Status : UNTESTED STUB
|
---|
1887 | *
|
---|
1888 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1889 | *****************************************************************************/
|
---|
1890 | BOOL WIN32API AnyPopup(VOID)
|
---|
1891 | {
|
---|
1892 | dprintf(("USER32:AnyPopup() not implemented.\n"));
|
---|
1893 |
|
---|
1894 | return (FALSE);
|
---|
1895 | }
|
---|
1896 | //******************************************************************************
|
---|
1897 | //******************************************************************************
|
---|
1898 | HWND WIN32API GetForegroundWindow(void)
|
---|
1899 | {
|
---|
1900 | #ifdef DEBUG
|
---|
1901 | WriteLog("USER32: GetForegroundWindow\n");
|
---|
1902 | #endif
|
---|
1903 | return Win32Window::OS2ToWin32Handle(O32_GetForegroundWindow());
|
---|
1904 | }
|
---|
1905 | //******************************************************************************
|
---|
1906 | //******************************************************************************
|
---|
1907 | HWND WIN32API GetLastActivePopup( HWND hWnd)
|
---|
1908 | {
|
---|
1909 | #ifdef DEBUG
|
---|
1910 | WriteLog("USER32: GetLastActivePopup\n");
|
---|
1911 | #endif
|
---|
1912 | hWnd = Win32Window::Win32ToOS2Handle(hWnd);
|
---|
1913 |
|
---|
1914 | return Win32Window::OS2ToWin32Handle(O32_GetLastActivePopup(hWnd));
|
---|
1915 | }
|
---|
1916 | //******************************************************************************
|
---|
1917 | //******************************************************************************
|
---|
1918 | DWORD WIN32API GetWindowThreadProcessId(HWND hWnd, PDWORD lpdwProcessId)
|
---|
1919 | {
|
---|
1920 | #ifdef DEBUG
|
---|
1921 | WriteLog("USER32: GetWindowThreadProcessId\n");
|
---|
1922 | #endif
|
---|
1923 | hWnd = Win32Window::Win32ToOS2Handle(hWnd);
|
---|
1924 |
|
---|
1925 | return O32_GetWindowThreadProcessId(hWnd,lpdwProcessId);
|
---|
1926 | }
|
---|
1927 |
|
---|
1928 | /* Painting and Drawing Functions */
|
---|
1929 |
|
---|
1930 | INT WIN32API ExcludeUpdateRgn( HDC hDC, HWND hWnd)
|
---|
1931 | {
|
---|
1932 | #ifdef DEBUG
|
---|
1933 | WriteLog("USER32: ExcludeUpdateRgn\n");
|
---|
1934 | #endif
|
---|
1935 | hWnd = Win32Window::Win32ToOS2Handle(hWnd);
|
---|
1936 |
|
---|
1937 | return O32_ExcludeUpdateRgn(hDC,hWnd);
|
---|
1938 | }
|
---|
1939 | //******************************************************************************
|
---|
1940 | //******************************************************************************
|
---|
1941 | /*****************************************************************************
|
---|
1942 | * Name : int WIN32API GetWindowRgn
|
---|
1943 | * Purpose : The GetWindowRgn function obtains a copy of the window region of a window.
|
---|
1944 | * Parameters: HWND hWnd handle to window whose window region is to be obtained
|
---|
1945 | * HRGN hRgn handle to region that receives a copy of the window region
|
---|
1946 | * Variables :
|
---|
1947 | * Result : NULLREGION, SIMPLEREGION, COMPLEXREGION, ERROR
|
---|
1948 | * Remark :
|
---|
1949 | * Status : UNTESTED STUB
|
---|
1950 | *
|
---|
1951 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
1952 | *****************************************************************************/
|
---|
1953 |
|
---|
1954 | int WIN32API GetWindowRgn (HWND hWnd,
|
---|
1955 | HRGN hRgn)
|
---|
1956 | {
|
---|
1957 | dprintf(("USER32:GetWindowRgn (%08xh,%08x) not implemented.\n",
|
---|
1958 | hWnd,
|
---|
1959 | hRgn));
|
---|
1960 | //Attention: Win32 hwnd handle!
|
---|
1961 |
|
---|
1962 | return (NULLREGION);
|
---|
1963 | }
|
---|
1964 | //******************************************************************************
|
---|
1965 | //TODO: Not complete
|
---|
1966 | //******************************************************************************
|
---|
1967 | BOOL WIN32API GrayStringA(HDC hdc, HBRUSH hBrush, GRAYSTRINGPROC lpOutputFunc,
|
---|
1968 | LPARAM lpData, int nCount, int X, int Y, int nWidth,
|
---|
1969 | int nHeight)
|
---|
1970 | {
|
---|
1971 | BOOL rc;
|
---|
1972 | COLORREF curclr;
|
---|
1973 |
|
---|
1974 | #ifdef DEBUG
|
---|
1975 | WriteLog("USER32: GrayStringA, not completely implemented\n");
|
---|
1976 | #endif
|
---|
1977 | if(lpOutputFunc == NULL && lpData == NULL) {
|
---|
1978 | #ifdef DEBUG
|
---|
1979 | WriteLog("USER32: lpOutputFunc == NULL && lpData == NULL\n");
|
---|
1980 | #endif
|
---|
1981 | return(FALSE);
|
---|
1982 | }
|
---|
1983 | if(lpOutputFunc) {
|
---|
1984 | return(lpOutputFunc(hdc, lpData, nCount));
|
---|
1985 | }
|
---|
1986 | curclr = SetTextColor(hdc, GetSysColor(COLOR_GRAYTEXT));
|
---|
1987 | rc = TextOutA(hdc, X, Y, (char *)lpData, nCount);
|
---|
1988 | SetTextColor(hdc, curclr);
|
---|
1989 |
|
---|
1990 | return(rc);
|
---|
1991 | }
|
---|
1992 | //******************************************************************************
|
---|
1993 | //******************************************************************************
|
---|
1994 | BOOL WIN32API GrayStringW(HDC hdc, HBRUSH hBrush, GRAYSTRINGPROC lpOutputFunc,
|
---|
1995 | LPARAM lpData, int nCount, int X, int Y, int nWidth,
|
---|
1996 | int nHeight)
|
---|
1997 | {
|
---|
1998 | BOOL rc;
|
---|
1999 | char *astring;
|
---|
2000 | COLORREF curclr;
|
---|
2001 |
|
---|
2002 | #ifdef DEBUG
|
---|
2003 | WriteLog("USER32: GrayStringW, not completely implemented\n");
|
---|
2004 | #endif
|
---|
2005 |
|
---|
2006 | if(lpOutputFunc == NULL && lpData == NULL) {
|
---|
2007 | #ifdef DEBUG
|
---|
2008 | WriteLog("USER32: lpOutputFunc == NULL && lpData == NULL\n");
|
---|
2009 | #endif
|
---|
2010 | return(FALSE);
|
---|
2011 | }
|
---|
2012 | if(nCount == 0)
|
---|
2013 | nCount = UniStrlen((UniChar*)lpData);
|
---|
2014 |
|
---|
2015 | if(lpOutputFunc) {
|
---|
2016 | return(lpOutputFunc(hdc, lpData, nCount));
|
---|
2017 | }
|
---|
2018 | astring = UnicodeToAsciiString((LPWSTR)lpData);
|
---|
2019 |
|
---|
2020 | curclr = SetTextColor(hdc, GetSysColor(COLOR_GRAYTEXT));
|
---|
2021 | rc = TextOutA(hdc, X, Y, astring, nCount);
|
---|
2022 | SetTextColor(hdc, curclr);
|
---|
2023 |
|
---|
2024 | FreeAsciiString(astring);
|
---|
2025 | return(rc);
|
---|
2026 | }
|
---|
2027 | //******************************************************************************
|
---|
2028 | //******************************************************************************
|
---|
2029 | #if 0
|
---|
2030 | BOOL WIN32API InvalidateRgn( HWND hWnd, HRGN hRgn, BOOL bErase)
|
---|
2031 | {
|
---|
2032 | #ifdef DEBUG
|
---|
2033 | WriteLog("USER32: InvalidateRgn\n");
|
---|
2034 | #endif
|
---|
2035 | hWnd = Win32Window::Win32ToOS2Handle(hWnd);
|
---|
2036 |
|
---|
2037 | return O32_InvalidateRgn(hWnd,hRgn,bErase);
|
---|
2038 | }
|
---|
2039 | #endif
|
---|
2040 | /*****************************************************************************
|
---|
2041 | * Name : BOOL WIN32API PaintDesktop
|
---|
2042 | * Purpose : The PaintDesktop function fills the clipping region in the
|
---|
2043 | * specified device context with the desktop pattern or wallpaper.
|
---|
2044 | * The function is provided primarily for shell desktops.
|
---|
2045 | * Parameters:
|
---|
2046 | * Variables :
|
---|
2047 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2048 | * If the function fails, the return value is FALSE.
|
---|
2049 | * Remark :
|
---|
2050 | * Status : UNTESTED STUB
|
---|
2051 | *
|
---|
2052 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2053 | *****************************************************************************/
|
---|
2054 | BOOL WIN32API PaintDesktop(HDC hdc)
|
---|
2055 | {
|
---|
2056 | dprintf(("USER32:PaintDesktop (%08x) not implemented.\n",
|
---|
2057 | hdc));
|
---|
2058 |
|
---|
2059 | return (FALSE);
|
---|
2060 | }
|
---|
2061 | /*****************************************************************************
|
---|
2062 | * Name : int WIN32API SetWindowRgn
|
---|
2063 | * Purpose : The SetWindowRgn function sets the window region of a window. The
|
---|
2064 | * window region determines the area within the window where the
|
---|
2065 | * operating system permits drawing. The operating system does not
|
---|
2066 | * display any portion of a window that lies outside of the window region
|
---|
2067 | * Parameters: HWND hWnd handle to window whose window region is to be set
|
---|
2068 | * HRGN hRgn handle to region
|
---|
2069 | * BOOL bRedraw window redraw flag
|
---|
2070 | * Variables :
|
---|
2071 | * Result : If the function succeeds, the return value is non-zero.
|
---|
2072 | * If the function fails, the return value is zero.
|
---|
2073 | * Remark :
|
---|
2074 | * Status : UNTESTED STUB
|
---|
2075 | *
|
---|
2076 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2077 | *****************************************************************************/
|
---|
2078 |
|
---|
2079 | int WIN32API SetWindowRgn(HWND hWnd,
|
---|
2080 | HRGN hRgn,
|
---|
2081 | BOOL bRedraw)
|
---|
2082 | {
|
---|
2083 | dprintf(("USER32:SetWindowRgn (%08xh,%08xh,%u) not implemented.\n",
|
---|
2084 | hWnd,
|
---|
2085 | hRgn,
|
---|
2086 | bRedraw));
|
---|
2087 | //Attention: Win32 hwnd handle!
|
---|
2088 |
|
---|
2089 | return (0);
|
---|
2090 | }
|
---|
2091 | //******************************************************************************
|
---|
2092 | //******************************************************************************
|
---|
2093 | BOOL WIN32API ValidateRect( HWND hwnd, const RECT * lprc)
|
---|
2094 | {
|
---|
2095 | #ifdef DEBUG
|
---|
2096 | WriteLog("USER32: ValidateRect\n");
|
---|
2097 | #endif
|
---|
2098 | hwnd = Win32Window::Win32ToOS2Handle(hwnd);
|
---|
2099 |
|
---|
2100 | return O32_ValidateRect(hwnd,lprc);
|
---|
2101 | }
|
---|
2102 | //******************************************************************************
|
---|
2103 | //******************************************************************************
|
---|
2104 | BOOL WIN32API ValidateRgn( HWND hwnd, HRGN hrgn)
|
---|
2105 | {
|
---|
2106 | #ifdef DEBUG
|
---|
2107 | WriteLog("USER32: ValidateRgn\n");
|
---|
2108 | #endif
|
---|
2109 | hwnd = Win32Window::Win32ToOS2Handle(hwnd);
|
---|
2110 |
|
---|
2111 | return O32_ValidateRgn(hwnd,hrgn);
|
---|
2112 | }
|
---|
2113 |
|
---|
2114 | /* Filled Shape Functions */
|
---|
2115 |
|
---|
2116 |
|
---|
2117 | int WIN32API FillRect(HDC hDC, const RECT * lprc, HBRUSH hbr)
|
---|
2118 | {
|
---|
2119 | #ifdef DEBUG
|
---|
2120 | WriteLog("USER32: FillRect (%d,%d)(%d,%d) brush %X\n", lprc->left, lprc->top, lprc->right, lprc->bottom, hbr);
|
---|
2121 | #endif
|
---|
2122 | return O32_FillRect(hDC,lprc,hbr);
|
---|
2123 | }
|
---|
2124 | //******************************************************************************
|
---|
2125 | //******************************************************************************
|
---|
2126 | int WIN32API FrameRect( HDC hDC, const RECT * lprc, HBRUSH hbr)
|
---|
2127 | {
|
---|
2128 | #ifdef DEBUG
|
---|
2129 | WriteLog("USER32: FrameRect\n");
|
---|
2130 | #endif
|
---|
2131 | return O32_FrameRect(hDC,lprc,hbr);
|
---|
2132 | }
|
---|
2133 | //******************************************************************************
|
---|
2134 | //******************************************************************************
|
---|
2135 | BOOL WIN32API InvertRect( HDC hDC, const RECT * lprc)
|
---|
2136 | {
|
---|
2137 | #ifdef DEBUG
|
---|
2138 | WriteLog("USER32: InvertRect\n");
|
---|
2139 | #endif
|
---|
2140 | return O32_InvertRect(hDC,lprc);
|
---|
2141 | }
|
---|
2142 |
|
---|
2143 | /* System Information Functions */
|
---|
2144 |
|
---|
2145 | int WIN32API GetKeyboardType( int nTypeFlag)
|
---|
2146 | {
|
---|
2147 | #ifdef DEBUG
|
---|
2148 | WriteLog("USER32: GetKeyboardType\n");
|
---|
2149 | #endif
|
---|
2150 | return O32_GetKeyboardType(nTypeFlag);
|
---|
2151 | }
|
---|
2152 | /*****************************************************************************
|
---|
2153 | * Name : HDESK WIN32API GetThreadDesktop
|
---|
2154 | * Purpose : The GetThreadDesktop function returns a handle to the desktop
|
---|
2155 | * associated with a specified thread.
|
---|
2156 | * Parameters: DWORD dwThreadId thread identifier
|
---|
2157 | * Variables :
|
---|
2158 | * Result : If the function succeeds, the return value is the handle of the
|
---|
2159 | * desktop associated with the specified thread.
|
---|
2160 | * Remark :
|
---|
2161 | * Status : UNTESTED STUB
|
---|
2162 | *
|
---|
2163 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2164 | *****************************************************************************/
|
---|
2165 | HDESK WIN32API GetThreadDesktop(DWORD dwThreadId)
|
---|
2166 | {
|
---|
2167 | dprintf(("USER32:GetThreadDesktop (%u) not implemented.\n",
|
---|
2168 | dwThreadId));
|
---|
2169 |
|
---|
2170 | return (NULL);
|
---|
2171 | }
|
---|
2172 |
|
---|
2173 | /* Message and Message Queue Functions */
|
---|
2174 |
|
---|
2175 | /*****************************************************************************
|
---|
2176 | * Name : BOOL WIN32API GetInputState
|
---|
2177 | * Purpose : The GetInputState function determines whether there are
|
---|
2178 | * mouse-button or keyboard messages in the calling thread's message queue.
|
---|
2179 | * Parameters:
|
---|
2180 | * Variables :
|
---|
2181 | * Result : If the queue contains one or more new mouse-button or keyboard
|
---|
2182 | * messages, the return value is TRUE.
|
---|
2183 | * If the function fails, the return value is FALSE.
|
---|
2184 | * Remark :
|
---|
2185 | * Status : UNTESTED STUB
|
---|
2186 | *
|
---|
2187 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2188 | *****************************************************************************/
|
---|
2189 | BOOL WIN32API GetInputState(VOID)
|
---|
2190 | {
|
---|
2191 | dprintf(("USER32:GetInputState () not implemented.\n"));
|
---|
2192 |
|
---|
2193 | return (FALSE);
|
---|
2194 | }
|
---|
2195 | //******************************************************************************
|
---|
2196 | //******************************************************************************
|
---|
2197 | DWORD WIN32API GetQueueStatus( UINT flags)
|
---|
2198 | {
|
---|
2199 | #ifdef DEBUG
|
---|
2200 | WriteLog("USER32: GetQueueStatus\n");
|
---|
2201 | #endif
|
---|
2202 | return O32_GetQueueStatus(flags);
|
---|
2203 | }
|
---|
2204 |
|
---|
2205 | /* Font and Text Functions */
|
---|
2206 |
|
---|
2207 | DWORD WIN32API GetTabbedTextExtentA( HDC hDC, LPCSTR lpString, int nCount, int nTabPositions, LPINT lpnTabStopPositions)
|
---|
2208 | {
|
---|
2209 | #ifdef DEBUG
|
---|
2210 | WriteLog("USER32: GetTabbedTextExtentA\n");
|
---|
2211 | #endif
|
---|
2212 | return O32_GetTabbedTextExtent(hDC,lpString,nCount,nTabPositions,lpnTabStopPositions);
|
---|
2213 | }
|
---|
2214 | //******************************************************************************
|
---|
2215 | //******************************************************************************
|
---|
2216 | DWORD WIN32API GetTabbedTextExtentW( HDC hDC, LPCWSTR lpString, int nCount, int nTabPositions, LPINT lpnTabStopPositions)
|
---|
2217 | {
|
---|
2218 | char *astring = UnicodeToAsciiString((LPWSTR)lpString);
|
---|
2219 | DWORD rc;
|
---|
2220 |
|
---|
2221 | #ifdef DEBUG
|
---|
2222 | WriteLog("USER32: GetTabbedTextExtentW\n");
|
---|
2223 | #endif
|
---|
2224 | rc = O32_GetTabbedTextExtent(hDC,astring,nCount,nTabPositions,lpnTabStopPositions);
|
---|
2225 | FreeAsciiString(astring);
|
---|
2226 | return rc;
|
---|
2227 | }
|
---|
2228 | //******************************************************************************
|
---|
2229 | //******************************************************************************
|
---|
2230 | LONG WIN32API TabbedTextOutA( HDC hdc, int x, int y, LPCSTR lpString, int nCount, int nTabPositions, LPINT lpnTabStopPositions, int nTabOrigin)
|
---|
2231 | {
|
---|
2232 | #ifdef DEBUG
|
---|
2233 | WriteLog("USER32: TabbedTextOutA\n");
|
---|
2234 | #endif
|
---|
2235 | return O32_TabbedTextOut(hdc,x,y,lpString,nCount,nTabPositions,lpnTabStopPositions,nTabOrigin);
|
---|
2236 | }
|
---|
2237 | //******************************************************************************
|
---|
2238 | //******************************************************************************
|
---|
2239 | LONG WIN32API TabbedTextOutW( HDC hdc, int x, int y, LPCWSTR lpString, int nCount, int nTabPositions, LPINT lpnTabStopPositions, int nTabOrigin)
|
---|
2240 | {
|
---|
2241 | char *astring = UnicodeToAsciiString((LPWSTR)lpString);
|
---|
2242 | LONG rc;
|
---|
2243 |
|
---|
2244 | #ifdef DEBUG
|
---|
2245 | WriteLog("USER32: TabbedTextOutW\n");
|
---|
2246 | #endif
|
---|
2247 | rc = O32_TabbedTextOut(hdc,x,y,astring,nCount,nTabPositions,lpnTabStopPositions,nTabOrigin);
|
---|
2248 | FreeAsciiString(astring);
|
---|
2249 | return rc;
|
---|
2250 | }
|
---|
2251 |
|
---|
2252 | /* Dialog Box Functions */
|
---|
2253 |
|
---|
2254 | BOOL WIN32API MapDialogRect( HWND hDlg, PRECT lpRect)
|
---|
2255 | {
|
---|
2256 | #ifdef DEBUG
|
---|
2257 | WriteLog("USER32: MapDialogRect\n");
|
---|
2258 | #endif
|
---|
2259 | hDlg = Win32Window::Win32ToOS2Handle(hDlg);
|
---|
2260 |
|
---|
2261 | return O32_MapDialogRect(hDlg,lpRect);
|
---|
2262 | }
|
---|
2263 |
|
---|
2264 | /* Icon Functions */
|
---|
2265 | int WIN32API LookupIconIdFromDirectory(PBYTE presbits, BOOL fIcon)
|
---|
2266 | {
|
---|
2267 | #ifdef DEBUG
|
---|
2268 | WriteLog("USER32: LookupIconIdFromDirectory, not implemented\n");
|
---|
2269 | #endif
|
---|
2270 | return(0);
|
---|
2271 | }
|
---|
2272 | //******************************************************************************
|
---|
2273 | //******************************************************************************
|
---|
2274 | int WIN32API LookupIconIdFromDirectoryEx(PBYTE presbits, BOOL fIcon,
|
---|
2275 | int cxDesired, int cyDesired,
|
---|
2276 | UINT Flags)
|
---|
2277 | {
|
---|
2278 | #ifdef DEBUG
|
---|
2279 | WriteLog("USER32: LookupIconIdFromDirectoryEx, not implemented\n");
|
---|
2280 | #endif
|
---|
2281 | return(0);
|
---|
2282 | }
|
---|
2283 |
|
---|
2284 | /* Device Context Functions */
|
---|
2285 |
|
---|
2286 | BOOL WIN32API GetMonitorInfoA(HMONITOR,LPMONITORINFO)
|
---|
2287 | {
|
---|
2288 | #ifdef DEBUG
|
---|
2289 | WriteLog("USER32: GetMonitorInfoA not supported!!\n");
|
---|
2290 | #endif
|
---|
2291 | return(FALSE);
|
---|
2292 | }
|
---|
2293 | //******************************************************************************
|
---|
2294 | //******************************************************************************
|
---|
2295 | BOOL WIN32API GetMonitorInfoW(HMONITOR,LPMONITORINFO)
|
---|
2296 | {
|
---|
2297 | #ifdef DEBUG
|
---|
2298 | WriteLog("USER32: GetMonitorInfoW not supported!!\n");
|
---|
2299 | #endif
|
---|
2300 | return(FALSE);
|
---|
2301 | }
|
---|
2302 | //******************************************************************************
|
---|
2303 | //******************************************************************************
|
---|
2304 | HMONITOR WIN32API MonitorFromWindow(HWND hwnd, DWORD dwFlags)
|
---|
2305 | {
|
---|
2306 | #ifdef DEBUG
|
---|
2307 | WriteLog("USER32: MonitorFromWindow not correctly supported??\n");
|
---|
2308 | #endif
|
---|
2309 | //Attention: Win32 hwnd!
|
---|
2310 |
|
---|
2311 | return(0);
|
---|
2312 | }
|
---|
2313 | //******************************************************************************
|
---|
2314 | //******************************************************************************
|
---|
2315 | HMONITOR WIN32API MonitorFromRect(LPRECT rect, DWORD dwFlags)
|
---|
2316 | {
|
---|
2317 | #ifdef DEBUG
|
---|
2318 | WriteLog("USER32: MonitorFromRect not correctly supported??\n");
|
---|
2319 | #endif
|
---|
2320 | return(0);
|
---|
2321 | }
|
---|
2322 | //******************************************************************************
|
---|
2323 | //******************************************************************************
|
---|
2324 | HMONITOR WIN32API MonitorFromPoint(POINT point, DWORD dwflags)
|
---|
2325 | {
|
---|
2326 | #ifdef DEBUG
|
---|
2327 | WriteLog("USER32: MonitorFromPoint not correctly supported??\n");
|
---|
2328 | #endif
|
---|
2329 | return(0);
|
---|
2330 | }
|
---|
2331 | //******************************************************************************
|
---|
2332 | //******************************************************************************
|
---|
2333 | BOOL WIN32API EnumDisplayMonitors(HDC,LPRECT,MONITORENUMPROC,LPARAM)
|
---|
2334 | {
|
---|
2335 | #ifdef DEBUG
|
---|
2336 | WriteLog("USER32: EnumDisplayMonitors not supported??\n");
|
---|
2337 | #endif
|
---|
2338 | return(FALSE);
|
---|
2339 | }
|
---|
2340 | //******************************************************************************
|
---|
2341 | //******************************************************************************
|
---|
2342 | BOOL WIN32API EnumDisplaySettingsA(LPCSTR lpszDeviceName, DWORD iModeNum,
|
---|
2343 | LPDEVMODEA lpDevMode)
|
---|
2344 | {
|
---|
2345 | #ifdef DEBUG
|
---|
2346 | WriteLog("USER32: EnumDisplaySettingsA FAKED\n");
|
---|
2347 | #endif
|
---|
2348 | switch(iModeNum) {
|
---|
2349 | case 0:
|
---|
2350 | lpDevMode->dmBitsPerPel = 16;
|
---|
2351 | lpDevMode->dmPelsWidth = 768;
|
---|
2352 | lpDevMode->dmPelsHeight = 1024;
|
---|
2353 | lpDevMode->dmDisplayFlags = 0;
|
---|
2354 | lpDevMode->dmDisplayFrequency = 70;
|
---|
2355 | break;
|
---|
2356 | case 1:
|
---|
2357 | lpDevMode->dmBitsPerPel = 16;
|
---|
2358 | lpDevMode->dmPelsWidth = 640;
|
---|
2359 | lpDevMode->dmPelsHeight = 480;
|
---|
2360 | lpDevMode->dmDisplayFlags = 0;
|
---|
2361 | lpDevMode->dmDisplayFrequency = 70;
|
---|
2362 | break;
|
---|
2363 | default:
|
---|
2364 | return(FALSE);
|
---|
2365 | }
|
---|
2366 | return(TRUE);
|
---|
2367 | }
|
---|
2368 | /*****************************************************************************
|
---|
2369 | * Name : BOOL WIN32API EnumDisplaySettingsW
|
---|
2370 | * Purpose : The EnumDisplaySettings function obtains information about one
|
---|
2371 | * of a display device's graphics modes. You can obtain information
|
---|
2372 | * for all of a display device's graphics modes by making a series
|
---|
2373 | * of calls to this function.
|
---|
2374 | * Parameters: LPCTSTR lpszDeviceName specifies the display device
|
---|
2375 | * DWORD iModeNum specifies the graphics mode
|
---|
2376 | * LPDEVMODE lpDevMode points to structure to receive settings
|
---|
2377 | * Variables :
|
---|
2378 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2379 | * If the function fails, the return value is FALSE.
|
---|
2380 | * Remark :
|
---|
2381 | * Status : UNTESTED STUB
|
---|
2382 | *
|
---|
2383 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2384 | *****************************************************************************/
|
---|
2385 | BOOL WIN32API EnumDisplaySettingsW(LPCSTR lpszDeviceName,
|
---|
2386 | DWORD iModeNum,
|
---|
2387 | LPDEVMODEW lpDevMode)
|
---|
2388 | {
|
---|
2389 | dprintf(("USER32:EnumDisplaySettingsW (%s,%08xh,%08x) not implemented.\n",
|
---|
2390 | lpszDeviceName,
|
---|
2391 | iModeNum,
|
---|
2392 | lpDevMode));
|
---|
2393 |
|
---|
2394 | return (EnumDisplaySettingsA(lpszDeviceName,
|
---|
2395 | iModeNum,
|
---|
2396 | (LPDEVMODEA)lpDevMode));
|
---|
2397 | }
|
---|
2398 | //******************************************************************************
|
---|
2399 | //******************************************************************************
|
---|
2400 | LONG WIN32API ChangeDisplaySettingsA(LPDEVMODEA lpDevMode, DWORD dwFlags)
|
---|
2401 | {
|
---|
2402 | #ifdef DEBUG
|
---|
2403 | if(lpDevMode) {
|
---|
2404 | WriteLog("USER32: ChangeDisplaySettingsA FAKED %X\n", dwFlags);
|
---|
2405 | WriteLog("USER32: ChangeDisplaySettingsA lpDevMode->dmBitsPerPel %d\n", lpDevMode->dmBitsPerPel);
|
---|
2406 | WriteLog("USER32: ChangeDisplaySettingsA lpDevMode->dmPelsWidth %d\n", lpDevMode->dmPelsWidth);
|
---|
2407 | WriteLog("USER32: ChangeDisplaySettingsA lpDevMode->dmPelsHeight %d\n", lpDevMode->dmPelsHeight);
|
---|
2408 | }
|
---|
2409 | #endif
|
---|
2410 | return(DISP_CHANGE_SUCCESSFUL);
|
---|
2411 | }
|
---|
2412 | /*****************************************************************************
|
---|
2413 | * Name : LONG WIN32API ChangeDisplaySettingsW
|
---|
2414 | * Purpose : The ChangeDisplaySettings function changes the display settings
|
---|
2415 | * to the specified graphics mode.
|
---|
2416 | * Parameters: LPDEVMODEW lpDevModeW
|
---|
2417 | * DWORD dwFlags
|
---|
2418 | * Variables :
|
---|
2419 | * Result : DISP_CHANGE_SUCCESSFUL The settings change was successful.
|
---|
2420 | * DISP_CHANGE_RESTART The computer must be restarted in order for the graphics mode to work.
|
---|
2421 | * DISP_CHANGE_BADFLAGS An invalid set of flags was passed in.
|
---|
2422 | * DISP_CHANGE_FAILED The display driver failed the specified graphics mode.
|
---|
2423 | * DISP_CHANGE_BADMODE The graphics mode is not supported.
|
---|
2424 | * DISP_CHANGE_NOTUPDATED Unable to write settings to the registry.
|
---|
2425 | * Remark :
|
---|
2426 | * Status : UNTESTED STUB
|
---|
2427 | *
|
---|
2428 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2429 | *****************************************************************************/
|
---|
2430 | LONG WIN32API ChangeDisplaySettingsW(LPDEVMODEW lpDevMode,
|
---|
2431 | DWORD dwFlags)
|
---|
2432 | {
|
---|
2433 | dprintf(("USER32:ChangeDisplaySettingsW(%08xh,%08x) not implemented.\n",
|
---|
2434 | lpDevMode,
|
---|
2435 | dwFlags));
|
---|
2436 |
|
---|
2437 | return (ChangeDisplaySettingsA((LPDEVMODEA)lpDevMode,
|
---|
2438 | dwFlags));
|
---|
2439 | }
|
---|
2440 |
|
---|
2441 | /* Window Station and Desktop Functions */
|
---|
2442 |
|
---|
2443 | /*****************************************************************************
|
---|
2444 | * Name : BOOL WIN32API CloseDesktop
|
---|
2445 | * Purpose : The CloseDesktop function closes an open handle of a desktop
|
---|
2446 | * object. A desktop is a secure object contained within a window
|
---|
2447 | * station object. A desktop has a logical display surface and
|
---|
2448 | * contains windows, menus and hooks.
|
---|
2449 | * Parameters: HDESK hDesktop
|
---|
2450 | * Variables :
|
---|
2451 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2452 | * If the functions fails, the return value is FALSE. To get
|
---|
2453 | * extended error information, call GetLastError.
|
---|
2454 | * Remark :
|
---|
2455 | * Status : UNTESTED STUB
|
---|
2456 | *
|
---|
2457 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2458 | *****************************************************************************/
|
---|
2459 | BOOL WIN32API CloseDesktop(HDESK hDesktop)
|
---|
2460 | {
|
---|
2461 | dprintf(("USER32:CloseDesktop(%08x) not implemented.\n",
|
---|
2462 | hDesktop));
|
---|
2463 |
|
---|
2464 | return (FALSE);
|
---|
2465 | }
|
---|
2466 | /*****************************************************************************
|
---|
2467 | * Name : BOOL WIN32API CloseWindowStation
|
---|
2468 | * Purpose : The CloseWindowStation function closes an open window station handle.
|
---|
2469 | * Parameters: HWINSTA hWinSta
|
---|
2470 | * Variables :
|
---|
2471 | * Result :
|
---|
2472 | * Remark : If the function succeeds, the return value is TRUE.
|
---|
2473 | * If the functions fails, the return value is FALSE. To get
|
---|
2474 | * extended error information, call GetLastError.
|
---|
2475 | * Status : UNTESTED STUB
|
---|
2476 | *
|
---|
2477 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2478 | *****************************************************************************/
|
---|
2479 | BOOL WIN32API CloseWindowStation(HWINSTA hWinSta)
|
---|
2480 | {
|
---|
2481 | dprintf(("USER32:CloseWindowStation(%08x) not implemented.\n",
|
---|
2482 | hWinSta));
|
---|
2483 |
|
---|
2484 | return (FALSE);
|
---|
2485 | }
|
---|
2486 | /*****************************************************************************
|
---|
2487 | * Name : HDESK WIN32API CreateDesktopA
|
---|
2488 | * Purpose : The CreateDesktop function creates a new desktop on the window
|
---|
2489 | * station associated with the calling process.
|
---|
2490 | * Parameters: LPCTSTR lpszDesktop name of the new desktop
|
---|
2491 | * LPCTSTR lpszDevice name of display device to assign to the desktop
|
---|
2492 | * LPDEVMODE pDevMode reserved; must be NULL
|
---|
2493 | * DWORD dwFlags flags to control interaction with other applications
|
---|
2494 | * DWORD dwDesiredAccess specifies access of returned handle
|
---|
2495 | * LPSECURITY_ATTRIBUTES lpsa specifies security attributes of the desktop
|
---|
2496 | * Variables :
|
---|
2497 | * Result : If the function succeeds, the return value is a handle of the
|
---|
2498 | * newly created desktop.
|
---|
2499 | * If the function fails, the return value is NULL. To get extended
|
---|
2500 | * error information, call GetLastError.
|
---|
2501 | * Remark :
|
---|
2502 | * Status : UNTESTED STUB
|
---|
2503 | *
|
---|
2504 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2505 | *****************************************************************************/
|
---|
2506 | HDESK WIN32API CreateDesktopA(LPCTSTR lpszDesktop,
|
---|
2507 | LPCTSTR lpszDevice,
|
---|
2508 | LPDEVMODEA pDevMode,
|
---|
2509 | DWORD dwFlags,
|
---|
2510 | DWORD dwDesiredAccess,
|
---|
2511 | LPSECURITY_ATTRIBUTES lpsa)
|
---|
2512 | {
|
---|
2513 | dprintf(("USER32:CreateDesktopA(%s,%s,%08xh,%08xh,%08xh,%08x) not implemented.\n",
|
---|
2514 | lpszDesktop,
|
---|
2515 | lpszDevice,
|
---|
2516 | pDevMode,
|
---|
2517 | dwFlags,
|
---|
2518 | dwDesiredAccess,
|
---|
2519 | lpsa));
|
---|
2520 |
|
---|
2521 | return (NULL);
|
---|
2522 | }
|
---|
2523 | /*****************************************************************************
|
---|
2524 | * Name : HDESK WIN32API CreateDesktopW
|
---|
2525 | * Purpose : The CreateDesktop function creates a new desktop on the window
|
---|
2526 | * station associated with the calling process.
|
---|
2527 | * Parameters: LPCTSTR lpszDesktop name of the new desktop
|
---|
2528 | * LPCTSTR lpszDevice name of display device to assign to the desktop
|
---|
2529 | * LPDEVMODE pDevMode reserved; must be NULL
|
---|
2530 | * DWORD dwFlags flags to control interaction with other applications
|
---|
2531 | * DWORD dwDesiredAccess specifies access of returned handle
|
---|
2532 | * LPSECURITY_ATTRIBUTES lpsa specifies security attributes of the desktop
|
---|
2533 | * Variables :
|
---|
2534 | * Result : If the function succeeds, the return value is a handle of the
|
---|
2535 | * newly created desktop.
|
---|
2536 | * If the function fails, the return value is NULL. To get extended
|
---|
2537 | * error information, call GetLastError.
|
---|
2538 | * Remark :
|
---|
2539 | * Status : UNTESTED STUB
|
---|
2540 | *
|
---|
2541 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2542 | *****************************************************************************/
|
---|
2543 | HDESK WIN32API CreateDesktopW(LPCTSTR lpszDesktop,
|
---|
2544 | LPCTSTR lpszDevice,
|
---|
2545 | LPDEVMODEW pDevMode,
|
---|
2546 | DWORD dwFlags,
|
---|
2547 | DWORD dwDesiredAccess,
|
---|
2548 | LPSECURITY_ATTRIBUTES lpsa)
|
---|
2549 | {
|
---|
2550 | dprintf(("USER32:CreateDesktopW(%s,%s,%08xh,%08xh,%08xh,%08x) not implemented.\n",
|
---|
2551 | lpszDesktop,
|
---|
2552 | lpszDevice,
|
---|
2553 | pDevMode,
|
---|
2554 | dwFlags,
|
---|
2555 | dwDesiredAccess,
|
---|
2556 | lpsa));
|
---|
2557 |
|
---|
2558 | return (NULL);
|
---|
2559 | }
|
---|
2560 | /*****************************************************************************
|
---|
2561 | * Name : HWINSTA WIN32API CreateWindowStationA
|
---|
2562 | * Purpose : The CreateWindowStation function creates a window station object.
|
---|
2563 | * It returns a handle that can be used to access the window station.
|
---|
2564 | * A window station is a secure object that contains a set of global
|
---|
2565 | * atoms, a clipboard, and a set of desktop objects.
|
---|
2566 | * Parameters: LPTSTR lpwinsta name of the new window station
|
---|
2567 | * DWORD dwReserved reserved; must be NULL
|
---|
2568 | * DWORD dwDesiredAccess specifies access of returned handle
|
---|
2569 | * LPSECURITY_ATTRIBUTES lpsa specifies security attributes of the window station
|
---|
2570 | * Variables :
|
---|
2571 | * Result : If the function succeeds, the return value is the handle to the
|
---|
2572 | * newly created window station.
|
---|
2573 | * If the function fails, the return value is NULL. To get extended
|
---|
2574 | * error information, call GetLastError.
|
---|
2575 | * Remark :
|
---|
2576 | * Status : UNTESTED STUB
|
---|
2577 | *
|
---|
2578 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2579 | *****************************************************************************/
|
---|
2580 | HWINSTA WIN32API CreateWindowStationA(LPTSTR lpWinSta,
|
---|
2581 | DWORD dwReserved,
|
---|
2582 | DWORD dwDesiredAccess,
|
---|
2583 | LPSECURITY_ATTRIBUTES lpsa)
|
---|
2584 | {
|
---|
2585 | dprintf(("USER32:CreateWindowStationA(%s,%08xh,%08xh,%08x) not implemented.\n",
|
---|
2586 | lpWinSta,
|
---|
2587 | dwReserved,
|
---|
2588 | dwDesiredAccess,
|
---|
2589 | lpsa));
|
---|
2590 |
|
---|
2591 | return (NULL);
|
---|
2592 | }
|
---|
2593 | /*****************************************************************************
|
---|
2594 | * Name : HWINSTA WIN32API CreateWindowStationW
|
---|
2595 | * Purpose : The CreateWindowStation function creates a window station object.
|
---|
2596 | * It returns a handle that can be used to access the window station.
|
---|
2597 | * A window station is a secure object that contains a set of global
|
---|
2598 | * atoms, a clipboard, and a set of desktop objects.
|
---|
2599 | * Parameters: LPTSTR lpwinsta name of the new window station
|
---|
2600 | * DWORD dwReserved reserved; must be NULL
|
---|
2601 | * DWORD dwDesiredAccess specifies access of returned handle
|
---|
2602 | * LPSECURITY_ATTRIBUTES lpsa specifies security attributes of the window station
|
---|
2603 | * Variables :
|
---|
2604 | * Result : If the function succeeds, the return value is the handle to the
|
---|
2605 | * newly created window station.
|
---|
2606 | * If the function fails, the return value is NULL. To get extended
|
---|
2607 | * error information, call GetLastError.
|
---|
2608 | * Remark :
|
---|
2609 | * Status : UNTESTED STUB
|
---|
2610 | *
|
---|
2611 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2612 | *****************************************************************************/
|
---|
2613 | HWINSTA WIN32API CreateWindowStationW(LPWSTR lpWinSta,
|
---|
2614 | DWORD dwReserved,
|
---|
2615 | DWORD dwDesiredAccess,
|
---|
2616 | LPSECURITY_ATTRIBUTES lpsa)
|
---|
2617 | {
|
---|
2618 | dprintf(("USER32:CreateWindowStationW(%s,%08xh,%08xh,%08x) not implemented.\n",
|
---|
2619 | lpWinSta,
|
---|
2620 | dwReserved,
|
---|
2621 | dwDesiredAccess,
|
---|
2622 | lpsa));
|
---|
2623 |
|
---|
2624 | return (NULL);
|
---|
2625 | }
|
---|
2626 | /*****************************************************************************
|
---|
2627 | * Name : BOOL WIN32API EnumDesktopWindows
|
---|
2628 | * Purpose : The EnumDesktopWindows function enumerates all windows in a
|
---|
2629 | * desktop by passing the handle of each window, in turn, to an
|
---|
2630 | * application-defined callback function.
|
---|
2631 | * Parameters: HDESK hDesktop handle of desktop to enumerate
|
---|
2632 | * WNDENUMPROC lpfn points to application's callback function
|
---|
2633 | * LPARAM lParam 32-bit value to pass to the callback function
|
---|
2634 | * Variables :
|
---|
2635 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2636 | * If the function fails, the return value is FALSE. To get
|
---|
2637 | * extended error information, call GetLastError.
|
---|
2638 | * Remark :
|
---|
2639 | * Status : UNTESTED STUB
|
---|
2640 | *
|
---|
2641 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2642 | *****************************************************************************/
|
---|
2643 | BOOL WIN32API EnumDesktopWindows(HDESK hDesktop,
|
---|
2644 | WNDENUMPROC lpfn,
|
---|
2645 | LPARAM lParam)
|
---|
2646 | {
|
---|
2647 | dprintf(("USER32:EnumDesktopWindows (%08xh,%08xh,%08x) not implemented.\n",
|
---|
2648 | hDesktop,
|
---|
2649 | lpfn,
|
---|
2650 | lParam));
|
---|
2651 |
|
---|
2652 | return (FALSE);
|
---|
2653 | }
|
---|
2654 | /*****************************************************************************
|
---|
2655 | * Name : BOOL WIN32API EnumDesktopsA
|
---|
2656 | * Purpose : The EnumDesktops function enumerates all desktops in the window
|
---|
2657 | * station assigned to the calling process. The function does so by
|
---|
2658 | * passing the name of each desktop, in turn, to an application-
|
---|
2659 | * defined callback function.
|
---|
2660 | * Parameters: HWINSTA hwinsta handle of window station to enumerate
|
---|
2661 | * DESKTOPENUMPROC lpEnumFunc points to application's callback function
|
---|
2662 | * LPARAM lParam 32-bit value to pass to the callback function
|
---|
2663 | * Variables :
|
---|
2664 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2665 | * If the function fails, the return value is FALSE. To get extended
|
---|
2666 | * error information, call GetLastError.
|
---|
2667 | * Remark :
|
---|
2668 | * Status : UNTESTED STUB
|
---|
2669 | *
|
---|
2670 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2671 | *****************************************************************************/
|
---|
2672 | BOOL WIN32API EnumDesktopsA(HWINSTA hWinSta,
|
---|
2673 | DESKTOPENUMPROCA lpEnumFunc,
|
---|
2674 | LPARAM lParam)
|
---|
2675 | {
|
---|
2676 | dprintf(("USER32:EnumDesktopsA (%08xh,%08xh,%08x) not implemented.\n",
|
---|
2677 | hWinSta,
|
---|
2678 | lpEnumFunc,
|
---|
2679 | lParam));
|
---|
2680 |
|
---|
2681 | return (FALSE);
|
---|
2682 | }
|
---|
2683 | /*****************************************************************************
|
---|
2684 | * Name : BOOL WIN32API EnumDesktopsW
|
---|
2685 | * Purpose : The EnumDesktops function enumerates all desktops in the window
|
---|
2686 | * station assigned to the calling process. The function does so by
|
---|
2687 | * passing the name of each desktop, in turn, to an application-
|
---|
2688 | * defined callback function.
|
---|
2689 | * Parameters: HWINSTA hwinsta handle of window station to enumerate
|
---|
2690 | * DESKTOPENUMPROC lpEnumFunc points to application's callback function
|
---|
2691 | * LPARAM lParam 32-bit value to pass to the callback function
|
---|
2692 | * Variables :
|
---|
2693 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2694 | * If the function fails, the return value is FALSE. To get extended
|
---|
2695 | * error information, call GetLastError.
|
---|
2696 | * Remark :
|
---|
2697 | * Status : UNTESTED STUB
|
---|
2698 | *
|
---|
2699 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2700 | *****************************************************************************/
|
---|
2701 | BOOL WIN32API EnumDesktopsW(HWINSTA hWinSta,
|
---|
2702 | DESKTOPENUMPROCW lpEnumFunc,
|
---|
2703 | LPARAM lParam)
|
---|
2704 | {
|
---|
2705 | dprintf(("USER32:EnumDesktopsW (%08xh,%08xh,%08x) not implemented.\n",
|
---|
2706 | hWinSta,
|
---|
2707 | lpEnumFunc,
|
---|
2708 | lParam));
|
---|
2709 |
|
---|
2710 | return (FALSE);
|
---|
2711 | }
|
---|
2712 | /*****************************************************************************
|
---|
2713 | * Name : BOOL WIN32API EnumWindowStationsA
|
---|
2714 | * Purpose : The EnumWindowStations function enumerates all windowstations
|
---|
2715 | * in the system by passing the name of each window station, in
|
---|
2716 | * turn, to an application-defined callback function.
|
---|
2717 | * Parameters:
|
---|
2718 | * Variables : WINSTAENUMPROC lpEnumFunc points to application's callback function
|
---|
2719 | * LPARAM lParam 32-bit value to pass to the callback function
|
---|
2720 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2721 | * If the function fails the return value is FALSE. To get extended
|
---|
2722 | * error information, call GetLastError.
|
---|
2723 | * Remark :
|
---|
2724 | * Status : UNTESTED STUB
|
---|
2725 | *
|
---|
2726 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2727 | *****************************************************************************/
|
---|
2728 | BOOL WIN32API EnumWindowStationsA(WINSTAENUMPROCA lpEnumFunc,
|
---|
2729 | LPARAM lParam)
|
---|
2730 | {
|
---|
2731 | dprintf(("USER32:EnumWindowStationsA (%08xh,%08x) not implemented.\n",
|
---|
2732 | lpEnumFunc,
|
---|
2733 | lParam));
|
---|
2734 |
|
---|
2735 | return (FALSE);
|
---|
2736 | }
|
---|
2737 | /*****************************************************************************
|
---|
2738 | * Name : BOOL WIN32API EnumWindowStationsW
|
---|
2739 | * Purpose : The EnumWindowStations function enumerates all windowstations
|
---|
2740 | * in the system by passing the name of each window station, in
|
---|
2741 | * turn, to an application-defined callback function.
|
---|
2742 | * Parameters:
|
---|
2743 | * Variables : WINSTAENUMPROC lpEnumFunc points to application's callback function
|
---|
2744 | * LPARAM lParam 32-bit value to pass to the callback function
|
---|
2745 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2746 | * If the function fails the return value is FALSE. To get extended
|
---|
2747 | * error information, call GetLastError.
|
---|
2748 | * Remark :
|
---|
2749 | * Status : UNTESTED STUB
|
---|
2750 | *
|
---|
2751 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2752 | *****************************************************************************/
|
---|
2753 | BOOL WIN32API EnumWindowStationsW(WINSTAENUMPROCW lpEnumFunc,
|
---|
2754 | LPARAM lParam)
|
---|
2755 | {
|
---|
2756 | dprintf(("USER32:EnumWindowStationsW (%08xh,%08x) not implemented.\n",
|
---|
2757 | lpEnumFunc,
|
---|
2758 | lParam));
|
---|
2759 |
|
---|
2760 | return (FALSE);
|
---|
2761 | }
|
---|
2762 | /*****************************************************************************
|
---|
2763 | * Name : HWINSTA WIN32API GetProcessWindowStation
|
---|
2764 | * Purpose : The GetProcessWindowStation function returns a handle of the
|
---|
2765 | * window station associated with the calling process.
|
---|
2766 | * Parameters:
|
---|
2767 | * Variables :
|
---|
2768 | * Result : If the function succeeds, the return value is a handle of the
|
---|
2769 | * window station associated with the calling process.
|
---|
2770 | * If the function fails, the return value is NULL. This can occur
|
---|
2771 | * if the calling process is not an application written for Windows
|
---|
2772 | * NT. To get extended error information, call GetLastError.
|
---|
2773 | * Remark :
|
---|
2774 | * Status : UNTESTED STUB
|
---|
2775 | *
|
---|
2776 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2777 | *****************************************************************************/
|
---|
2778 | HWINSTA WIN32API GetProcessWindowStation(VOID)
|
---|
2779 | {
|
---|
2780 | dprintf(("USER32:GetProcessWindowStation () not implemented.\n"));
|
---|
2781 |
|
---|
2782 | return (NULL);
|
---|
2783 | }
|
---|
2784 | /*****************************************************************************
|
---|
2785 | * Name : BOOL WIN32API GetUserObjectInformationA
|
---|
2786 | * Purpose : The GetUserObjectInformation function returns information about
|
---|
2787 | * a window station or desktop object.
|
---|
2788 | * Parameters: HANDLE hObj handle of object to get information for
|
---|
2789 | * int nIndex type of information to get
|
---|
2790 | * PVOID pvInfo points to buffer that receives the information
|
---|
2791 | * DWORD nLength size, in bytes, of pvInfo buffer
|
---|
2792 | * LPDWORD lpnLengthNeeded receives required size, in bytes, of pvInfo buffer
|
---|
2793 | * Variables :
|
---|
2794 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2795 | * If the function fails, the return value is FALSE. To get extended
|
---|
2796 | * error information, call GetLastError.
|
---|
2797 | * Remark :
|
---|
2798 | * Status : UNTESTED STUB
|
---|
2799 | *
|
---|
2800 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2801 | *****************************************************************************/
|
---|
2802 | BOOL WIN32API GetUserObjectInformationA(HANDLE hObj,
|
---|
2803 | int nIndex,
|
---|
2804 | PVOID pvInfo,
|
---|
2805 | DWORD nLength,
|
---|
2806 | LPDWORD lpnLengthNeeded)
|
---|
2807 | {
|
---|
2808 | dprintf(("USER32:GetUserObjectInformationA (%08xh,%08xh,%08xh,%u,%08x) not implemented.\n",
|
---|
2809 | hObj,
|
---|
2810 | nIndex,
|
---|
2811 | pvInfo,
|
---|
2812 | nLength,
|
---|
2813 | lpnLengthNeeded));
|
---|
2814 |
|
---|
2815 | return (FALSE);
|
---|
2816 | }
|
---|
2817 | /*****************************************************************************
|
---|
2818 | * Name : BOOL WIN32API GetUserObjectInformationW
|
---|
2819 | * Purpose : The GetUserObjectInformation function returns information about
|
---|
2820 | * a window station or desktop object.
|
---|
2821 | * Parameters: HANDLE hObj handle of object to get information for
|
---|
2822 | * int nIndex type of information to get
|
---|
2823 | * PVOID pvInfo points to buffer that receives the information
|
---|
2824 | * DWORD nLength size, in bytes, of pvInfo buffer
|
---|
2825 | * LPDWORD lpnLengthNeeded receives required size, in bytes, of pvInfo buffer
|
---|
2826 | * Variables :
|
---|
2827 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2828 | * If the function fails, the return value is FALSE. To get extended
|
---|
2829 | * error information, call GetLastError.
|
---|
2830 | * Remark :
|
---|
2831 | * Status : UNTESTED STUB
|
---|
2832 | *
|
---|
2833 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2834 | *****************************************************************************/
|
---|
2835 | BOOL WIN32API GetUserObjectInformationW(HANDLE hObj,
|
---|
2836 | int nIndex,
|
---|
2837 | PVOID pvInfo,
|
---|
2838 | DWORD nLength,
|
---|
2839 | LPDWORD lpnLengthNeeded)
|
---|
2840 | {
|
---|
2841 | dprintf(("USER32:GetUserObjectInformationW (%08xh,%08xh,%08xh,%u,%08x) not implemented.\n",
|
---|
2842 | hObj,
|
---|
2843 | nIndex,
|
---|
2844 | pvInfo,
|
---|
2845 | nLength,
|
---|
2846 | lpnLengthNeeded));
|
---|
2847 |
|
---|
2848 | return (FALSE);
|
---|
2849 | }
|
---|
2850 | /*****************************************************************************
|
---|
2851 | * Name : BOOL WIN32API GetUserObjectSecurity
|
---|
2852 | * Purpose : The GetUserObjectSecurity function retrieves security information
|
---|
2853 | * for the specified user object.
|
---|
2854 | * Parameters: HANDLE hObj handle of user object
|
---|
2855 | * SECURITY_INFORMATION * pSIRequested address of requested security information
|
---|
2856 | * LPSECURITY_DESCRIPTOR pSID address of security descriptor
|
---|
2857 | * DWORD nLength size of buffer for security descriptor
|
---|
2858 | * LPDWORD lpnLengthNeeded address of required size of buffer
|
---|
2859 | * Variables :
|
---|
2860 | * Result : If the function succeeds, the return value is TRUE.
|
---|
2861 | * If the function fails, the return value is FALSE. To get extended
|
---|
2862 | * error information, call GetLastError.
|
---|
2863 | * Remark :
|
---|
2864 | * Status : UNTESTED STUB
|
---|
2865 | *
|
---|
2866 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2867 | *****************************************************************************/
|
---|
2868 | BOOL WIN32API GetUserObjectSecurity(HANDLE hObj,
|
---|
2869 | SECURITY_INFORMATION * pSIRequested,
|
---|
2870 | LPSECURITY_DESCRIPTOR pSID,
|
---|
2871 | DWORD nLength,
|
---|
2872 | LPDWORD lpnLengthNeeded)
|
---|
2873 | {
|
---|
2874 | dprintf(("USER32:GetUserObjectSecurity (%08xh,%08xh,%08xh,%u,%08x) not implemented.\n",
|
---|
2875 | hObj,
|
---|
2876 | pSIRequested,
|
---|
2877 | pSID,
|
---|
2878 | nLength,
|
---|
2879 | lpnLengthNeeded));
|
---|
2880 |
|
---|
2881 | return (FALSE);
|
---|
2882 | }
|
---|
2883 | /*****************************************************************************
|
---|
2884 | * Name : HDESK WIN32API OpenDesktopA
|
---|
2885 | * Purpose : The OpenDesktop function returns a handle to an existing desktop.
|
---|
2886 | * A desktop is a secure object contained within a window station
|
---|
2887 | * object. A desktop has a logical display surface and contains
|
---|
2888 | * windows, menus and hooks.
|
---|
2889 | * Parameters: LPCTSTR lpszDesktopName name of the desktop to open
|
---|
2890 | * DWORD dwFlags flags to control interaction with other applications
|
---|
2891 | * BOOL fInherit specifies whether returned handle is inheritable
|
---|
2892 | * DWORD dwDesiredAccess specifies access of returned handle
|
---|
2893 | * Variables :
|
---|
2894 | * Result : If the function succeeds, the return value is the handle to the
|
---|
2895 | * opened desktop.
|
---|
2896 | * If the function fails, the return value is NULL. To get extended
|
---|
2897 | * error information, call GetLastError.
|
---|
2898 | * Remark :
|
---|
2899 | * Status : UNTESTED STUB
|
---|
2900 | *
|
---|
2901 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2902 | *****************************************************************************/
|
---|
2903 | HDESK WIN32API OpenDesktopA(LPCTSTR lpszDesktopName,
|
---|
2904 | DWORD dwFlags,
|
---|
2905 | BOOL fInherit,
|
---|
2906 | DWORD dwDesiredAccess)
|
---|
2907 | {
|
---|
2908 | dprintf(("USER32:OpenDesktopA (%s,%08xh,%08xh,%08x) not implemented.\n",
|
---|
2909 | lpszDesktopName,
|
---|
2910 | dwFlags,
|
---|
2911 | fInherit,
|
---|
2912 | dwDesiredAccess));
|
---|
2913 |
|
---|
2914 | return (NULL);
|
---|
2915 | }
|
---|
2916 | /*****************************************************************************
|
---|
2917 | * Name : HDESK WIN32API OpenDesktopW
|
---|
2918 | * Purpose : The OpenDesktop function returns a handle to an existing desktop.
|
---|
2919 | * A desktop is a secure object contained within a window station
|
---|
2920 | * object. A desktop has a logical display surface and contains
|
---|
2921 | * windows, menus and hooks.
|
---|
2922 | * Parameters: LPCTSTR lpszDesktopName name of the desktop to open
|
---|
2923 | * DWORD dwFlags flags to control interaction with other applications
|
---|
2924 | * BOOL fInherit specifies whether returned handle is inheritable
|
---|
2925 | * DWORD dwDesiredAccess specifies access of returned handle
|
---|
2926 | * Variables :
|
---|
2927 | * Result : If the function succeeds, the return value is the handle to the
|
---|
2928 | * opened desktop.
|
---|
2929 | * If the function fails, the return value is NULL. To get extended
|
---|
2930 | * error information, call GetLastError.
|
---|
2931 | * Remark :
|
---|
2932 | * Status : UNTESTED STUB
|
---|
2933 | *
|
---|
2934 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2935 | *****************************************************************************/
|
---|
2936 | HDESK WIN32API OpenDesktopW(LPCTSTR lpszDesktopName,
|
---|
2937 | DWORD dwFlags,
|
---|
2938 | BOOL fInherit,
|
---|
2939 | DWORD dwDesiredAccess)
|
---|
2940 | {
|
---|
2941 | dprintf(("USER32:OpenDesktopW (%s,%08xh,%08xh,%08x) not implemented.\n",
|
---|
2942 | lpszDesktopName,
|
---|
2943 | dwFlags,
|
---|
2944 | fInherit,
|
---|
2945 | dwDesiredAccess));
|
---|
2946 |
|
---|
2947 | return (NULL);
|
---|
2948 | }
|
---|
2949 | /*****************************************************************************
|
---|
2950 | * Name : HDESK WIN32API OpenInputDesktop
|
---|
2951 | * Purpose : The OpenInputDesktop function returns a handle to the desktop
|
---|
2952 | * that receives user input. The input desktop is a desktop on the
|
---|
2953 | * window station associated with the logged-on user.
|
---|
2954 | * Parameters: DWORD dwFlags flags to control interaction with other applications
|
---|
2955 | * BOOL fInherit specifies whether returned handle is inheritable
|
---|
2956 | * DWORD dwDesiredAccess specifies access of returned handle
|
---|
2957 | * Variables :
|
---|
2958 | * Result : If the function succeeds, the return value is a handle of the
|
---|
2959 | * desktop that receives user input.
|
---|
2960 | * If the function fails, the return value is NULL. To get extended
|
---|
2961 | * error information, call GetLastError.
|
---|
2962 | * Remark :
|
---|
2963 | * Status : UNTESTED STUB
|
---|
2964 | *
|
---|
2965 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2966 | *****************************************************************************/
|
---|
2967 | HDESK WIN32API OpenInputDesktop(DWORD dwFlags,
|
---|
2968 | BOOL fInherit,
|
---|
2969 | DWORD dwDesiredAccess)
|
---|
2970 | {
|
---|
2971 | dprintf(("USER32:OpenInputDesktop (%08xh,%08xh,%08x) not implemented.\n",
|
---|
2972 | dwFlags,
|
---|
2973 | fInherit,
|
---|
2974 | dwDesiredAccess));
|
---|
2975 |
|
---|
2976 | return (NULL);
|
---|
2977 | }
|
---|
2978 | /*****************************************************************************
|
---|
2979 | * Name : HWINSTA WIN32API OpenWindowStationA
|
---|
2980 | * Purpose : The OpenWindowStation function returns a handle to an existing
|
---|
2981 | * window station.
|
---|
2982 | * Parameters: LPCTSTR lpszWinStaName name of the window station to open
|
---|
2983 | * BOOL fInherit specifies whether returned handle is inheritable
|
---|
2984 | * DWORD dwDesiredAccess specifies access of returned handle
|
---|
2985 | * Variables :
|
---|
2986 | * Result : If the function succeeds, the return value is the handle to the
|
---|
2987 | * specified window station.
|
---|
2988 | * If the function fails, the return value is NULL. To get extended
|
---|
2989 | * error information, call GetLastError.
|
---|
2990 | * Remark :
|
---|
2991 | * Status : UNTESTED STUB
|
---|
2992 | *
|
---|
2993 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
2994 | *****************************************************************************/
|
---|
2995 | HWINSTA WIN32API OpenWindowStationA(LPCTSTR lpszWinStaName,
|
---|
2996 | BOOL fInherit,
|
---|
2997 | DWORD dwDesiredAccess)
|
---|
2998 | {
|
---|
2999 | dprintf(("USER32:OpenWindowStatieonA (%s,%08xh,%08x) not implemented.\n",
|
---|
3000 | lpszWinStaName,
|
---|
3001 | fInherit,
|
---|
3002 | dwDesiredAccess));
|
---|
3003 |
|
---|
3004 | return (NULL);
|
---|
3005 | }
|
---|
3006 | /*****************************************************************************
|
---|
3007 | * Name : HWINSTA WIN32API OpenWindowStationW
|
---|
3008 | * Purpose : The OpenWindowStation function returns a handle to an existing
|
---|
3009 | * window station.
|
---|
3010 | * Parameters: LPCTSTR lpszWinStaName name of the window station to open
|
---|
3011 | * BOOL fInherit specifies whether returned handle is inheritable
|
---|
3012 | * DWORD dwDesiredAccess specifies access of returned handle
|
---|
3013 | * Variables :
|
---|
3014 | * Result : If the function succeeds, the return value is the handle to the
|
---|
3015 | * specified window station.
|
---|
3016 | * If the function fails, the return value is NULL. To get extended
|
---|
3017 | * error information, call GetLastError.
|
---|
3018 |
|
---|
3019 |
|
---|
3020 | * Remark :
|
---|
3021 | * Status : UNTESTED STUB
|
---|
3022 | *
|
---|
3023 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3024 | *****************************************************************************/
|
---|
3025 | HWINSTA WIN32API OpenWindowStationW(LPCTSTR lpszWinStaName,
|
---|
3026 | BOOL fInherit,
|
---|
3027 | DWORD dwDesiredAccess)
|
---|
3028 | {
|
---|
3029 | dprintf(("USER32:OpenWindowStatieonW (%s,%08xh,%08x) not implemented.\n",
|
---|
3030 | lpszWinStaName,
|
---|
3031 | fInherit,
|
---|
3032 | dwDesiredAccess));
|
---|
3033 |
|
---|
3034 | return (NULL);
|
---|
3035 | }
|
---|
3036 | /*****************************************************************************
|
---|
3037 | * Name : BOOL WIN32API SetProcessWindowStation
|
---|
3038 | * Purpose : The SetProcessWindowStation function assigns a window station
|
---|
3039 | * to the calling process. This enables the process to access
|
---|
3040 | * objects in the window station such as desktops, the clipboard,
|
---|
3041 | * and global atoms. All subsequent operations on the window station
|
---|
3042 | * use the access rights granted to hWinSta.
|
---|
3043 | * Parameters:
|
---|
3044 | * Variables :
|
---|
3045 | * Result : If the function succeeds, the return value is TRUE.
|
---|
3046 | * If the function fails, the return value is FALSE. To get extended
|
---|
3047 | * error information, call GetLastError.
|
---|
3048 | * Remark :
|
---|
3049 | * Status : UNTESTED STUB
|
---|
3050 | *
|
---|
3051 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3052 | *****************************************************************************/
|
---|
3053 | BOOL WIN32API SetProcessWindowStation(HWINSTA hWinSta)
|
---|
3054 | {
|
---|
3055 | dprintf(("USER32:SetProcessWindowStation (%08x) not implemented.\n",
|
---|
3056 | hWinSta));
|
---|
3057 |
|
---|
3058 | return (FALSE);
|
---|
3059 | }
|
---|
3060 | /*****************************************************************************
|
---|
3061 | * Name : BOOL WIN32API SetThreadDesktop
|
---|
3062 | * Purpose : The SetThreadDesktop function assigns a desktop to the calling
|
---|
3063 | * thread. All subsequent operations on the desktop use the access
|
---|
3064 | * rights granted to hDesk.
|
---|
3065 | * Parameters: HDESK hDesk handle of the desktop to assign to this thread
|
---|
3066 | * Variables :
|
---|
3067 | * Result : If the function succeeds, the return value is TRUE.
|
---|
3068 | * If the function fails, the return value is FALSE. To get extended
|
---|
3069 | * error information, call GetLastError.
|
---|
3070 | * Remark :
|
---|
3071 | * Status : UNTESTED STUB
|
---|
3072 | *
|
---|
3073 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3074 | *****************************************************************************/
|
---|
3075 | BOOL WIN32API SetThreadDesktop(HDESK hDesktop)
|
---|
3076 | {
|
---|
3077 | dprintf(("USER32:SetThreadDesktop (%08x) not implemented.\n",
|
---|
3078 | hDesktop));
|
---|
3079 |
|
---|
3080 | return (FALSE);
|
---|
3081 | }
|
---|
3082 | /*****************************************************************************
|
---|
3083 | * Name : BOOL WIN32API SetUserObjectInformationA
|
---|
3084 | * Purpose : The SetUserObjectInformation function sets information about a
|
---|
3085 | * window station or desktop object.
|
---|
3086 | * Parameters: HANDLE hObject handle of the object for which to set information
|
---|
3087 | * int nIndex type of information to set
|
---|
3088 | * PVOID lpvInfo points to a buffer that contains the information
|
---|
3089 | * DWORD cbInfo size, in bytes, of lpvInfo buffer
|
---|
3090 | * Variables :
|
---|
3091 | * Result : If the function succeeds, the return value is TRUE.
|
---|
3092 | * If the function fails the return value is FALSE. To get extended
|
---|
3093 | * error information, call GetLastError.
|
---|
3094 | * Remark :
|
---|
3095 | * Status : UNTESTED STUB
|
---|
3096 | *
|
---|
3097 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3098 | *****************************************************************************/
|
---|
3099 | BOOL WIN32API SetUserObjectInformationA(HANDLE hObject,
|
---|
3100 | int nIndex,
|
---|
3101 | PVOID lpvInfo,
|
---|
3102 | DWORD cbInfo)
|
---|
3103 | {
|
---|
3104 | dprintf(("USER32:SetUserObjectInformationA (%08xh,%u,%08xh,%08x) not implemented.\n",
|
---|
3105 | hObject,
|
---|
3106 | nIndex,
|
---|
3107 | lpvInfo,
|
---|
3108 | cbInfo));
|
---|
3109 |
|
---|
3110 | return (FALSE);
|
---|
3111 | }
|
---|
3112 | /*****************************************************************************
|
---|
3113 | * Name : BOOL WIN32API SetUserObjectInformationW
|
---|
3114 | * Purpose : The SetUserObjectInformation function sets information about a
|
---|
3115 | * window station or desktop object.
|
---|
3116 | * Parameters: HANDLE hObject handle of the object for which to set information
|
---|
3117 | * int nIndex type of information to set
|
---|
3118 | * PVOID lpvInfo points to a buffer that contains the information
|
---|
3119 | * DWORD cbInfo size, in bytes, of lpvInfo buffer
|
---|
3120 | * Variables :
|
---|
3121 | * Result : If the function succeeds, the return value is TRUE.
|
---|
3122 | * If the function fails the return value is FALSE. To get extended
|
---|
3123 | * error information, call GetLastError.
|
---|
3124 | * Remark :
|
---|
3125 | * Status : UNTESTED STUB
|
---|
3126 | *
|
---|
3127 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3128 | *****************************************************************************/
|
---|
3129 | BOOL WIN32API SetUserObjectInformationW(HANDLE hObject,
|
---|
3130 | int nIndex,
|
---|
3131 | PVOID lpvInfo,
|
---|
3132 | DWORD cbInfo)
|
---|
3133 | {
|
---|
3134 | dprintf(("USER32:SetUserObjectInformationW (%08xh,%u,%08xh,%08x) not implemented.\n",
|
---|
3135 | hObject,
|
---|
3136 | nIndex,
|
---|
3137 | lpvInfo,
|
---|
3138 | cbInfo));
|
---|
3139 |
|
---|
3140 | return (FALSE);
|
---|
3141 | }
|
---|
3142 | /*****************************************************************************
|
---|
3143 | * Name : BOOL WIN32API SetUserObjectSecurity
|
---|
3144 | * Purpose : The SetUserObjectSecurity function sets the security of a user
|
---|
3145 | * object. This can be, for example, a window or a DDE conversation
|
---|
3146 | * Parameters: HANDLE hObject handle of user object
|
---|
3147 | * SECURITY_INFORMATION * psi address of security information
|
---|
3148 | * LPSECURITY_DESCRIPTOR psd address of security descriptor
|
---|
3149 | * Variables :
|
---|
3150 | * Result : If the function succeeds, the return value is TRUE.
|
---|
3151 | * If the function fails, the return value is FALSE. To get extended
|
---|
3152 | * error information, call GetLastError.
|
---|
3153 | * Remark :
|
---|
3154 | * Status : UNTESTED STUB
|
---|
3155 | *
|
---|
3156 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3157 | *****************************************************************************/
|
---|
3158 | BOOL WIN32API SetUserObjectSecurity(HANDLE hObject,
|
---|
3159 | SECURITY_INFORMATION * psi,
|
---|
3160 | LPSECURITY_DESCRIPTOR psd)
|
---|
3161 | {
|
---|
3162 | dprintf(("USER32:SetUserObjectSecuroty (%08xh,%08xh,%08x) not implemented.\n",
|
---|
3163 | hObject,
|
---|
3164 | psi,
|
---|
3165 | psd));
|
---|
3166 |
|
---|
3167 | return (FALSE);
|
---|
3168 | }
|
---|
3169 | /*****************************************************************************
|
---|
3170 | * Name : BOOL WIN32API SwitchDesktop
|
---|
3171 | * Purpose : The SwitchDesktop function makes a desktop visible and activates
|
---|
3172 | * it. This enables the desktop to receive input from the user. The
|
---|
3173 | * calling process must have DESKTOP_SWITCHDESKTOP access to the
|
---|
3174 | * desktop for the SwitchDesktop function to succeed.
|
---|
3175 | * Parameters:
|
---|
3176 | * Variables :
|
---|
3177 | * Result : If the function succeeds, the return value is TRUE.
|
---|
3178 | * If the function fails, the return value is FALSE. To get extended
|
---|
3179 | * error information, call GetLastError.
|
---|
3180 | * Remark :
|
---|
3181 | * Status : UNTESTED STUB
|
---|
3182 | *
|
---|
3183 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3184 | *****************************************************************************/
|
---|
3185 | BOOL WIN32API SwitchDesktop(HDESK hDesktop)
|
---|
3186 | {
|
---|
3187 | dprintf(("USER32:SwitchDesktop (%08x) not implemented.\n",
|
---|
3188 | hDesktop));
|
---|
3189 |
|
---|
3190 | return (FALSE);
|
---|
3191 | }
|
---|
3192 |
|
---|
3193 | /* Debugging Functions */
|
---|
3194 |
|
---|
3195 | /*****************************************************************************
|
---|
3196 | * Name : VOID WIN32API SetDebugErrorLevel
|
---|
3197 | * Purpose : The SetDebugErrorLevel function sets the minimum error level at
|
---|
3198 | * which Windows will generate debugging events and pass them to a debugger.
|
---|
3199 | * Parameters: DWORD dwLevel debugging error level
|
---|
3200 | * Variables :
|
---|
3201 | * Result :
|
---|
3202 | * Remark :
|
---|
3203 | * Status : UNTESTED STUB
|
---|
3204 | *
|
---|
3205 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3206 | *****************************************************************************/
|
---|
3207 | VOID WIN32API SetDebugErrorLevel(DWORD dwLevel)
|
---|
3208 | {
|
---|
3209 | dprintf(("USER32:SetDebugErrorLevel (%08x) not implemented.\n",
|
---|
3210 | dwLevel));
|
---|
3211 | }
|
---|
3212 |
|
---|
3213 | /* Hook Functions */
|
---|
3214 |
|
---|
3215 | /*****************************************************************************
|
---|
3216 | * Name : BOOL WIN32API SetWindowsHookW
|
---|
3217 | * Purpose : The SetWindowsHook function is not implemented in the Win32 API.
|
---|
3218 | * Win32-based applications should use the SetWindowsHookEx function.
|
---|
3219 | * Parameters:
|
---|
3220 | * Variables :
|
---|
3221 | * Result :
|
---|
3222 | * Remark : ARGH ! MICROSOFT !
|
---|
3223 | * Status : UNTESTED STUB
|
---|
3224 | *
|
---|
3225 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3226 | *****************************************************************************/
|
---|
3227 | HHOOK WIN32API SetWindowsHookW(int nFilterType, HOOKPROC pfnFilterProc)
|
---|
3228 |
|
---|
3229 | {
|
---|
3230 | return (FALSE);
|
---|
3231 | }
|
---|
3232 |
|
---|
3233 | /* CB: move to ShowWindow() */
|
---|
3234 |
|
---|
3235 | /*****************************************************************************
|
---|
3236 | * Name : BOOL WIN32API ShowWindowAsync
|
---|
3237 | * Purpose : The ShowWindowAsync function sets the show state of a window
|
---|
3238 | * created by a different thread.
|
---|
3239 | * Parameters: HWND hwnd handle of window
|
---|
3240 | * int nCmdShow show state of window
|
---|
3241 | * Variables :
|
---|
3242 | * Result : If the window was previously visible, the return value is TRUE.
|
---|
3243 | * If the window was previously hidden, the return value is FALSE.
|
---|
3244 | * Remark :
|
---|
3245 | * Status : UNTESTED STUB
|
---|
3246 | *
|
---|
3247 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3248 | *****************************************************************************/
|
---|
3249 | BOOL WIN32API ShowWindowAsync (HWND hWnd,
|
---|
3250 | int nCmdShow)
|
---|
3251 | {
|
---|
3252 | dprintf(("USER32:ShowWindowAsync (%08xh,%08x) not implemented.\n",
|
---|
3253 | hWnd,
|
---|
3254 | nCmdShow));
|
---|
3255 |
|
---|
3256 | return (FALSE);
|
---|
3257 | }
|
---|
3258 |
|
---|
3259 | /* CB: move to MDI */
|
---|
3260 |
|
---|
3261 | /*****************************************************************************
|
---|
3262 | * Name : WORD WIN32API TileWindows
|
---|
3263 | * Purpose : The TileWindows function tiles the specified windows, or the child
|
---|
3264 | * windows of the specified parent window.
|
---|
3265 | * Parameters: HWND hwndParent handle of parent window
|
---|
3266 | * WORD wFlags types of windows not to arrange
|
---|
3267 | * LPCRECT lpRect rectangle to arrange windows in
|
---|
3268 | * WORD cChildrenb number of windows to arrange
|
---|
3269 | * const HWND *ahwndChildren array of window handles
|
---|
3270 | * Variables :
|
---|
3271 | * Result : If the function succeeds, the return value is the number of
|
---|
3272 | * windows arranged.
|
---|
3273 | * If the function fails, the return value is zero.
|
---|
3274 | * Remark :
|
---|
3275 | * Status : UNTESTED STUB
|
---|
3276 | *
|
---|
3277 | * Author : Patrick Haller [Thu, 1998/02/26 11:55]
|
---|
3278 | *****************************************************************************/
|
---|
3279 | WORD WIN32API TileWindows(HWND hwndParent,
|
---|
3280 | UINT wFlags,
|
---|
3281 | const LPRECT lpRect,
|
---|
3282 | UINT cChildrenb,
|
---|
3283 | const HWND *ahwndChildren)
|
---|
3284 | {
|
---|
3285 | dprintf(("USER32:TileWindows (%08xh,%08xh,%08xh,%08xh,%08x) not implemented.\n",
|
---|
3286 | hwndParent,
|
---|
3287 | wFlags,
|
---|
3288 | lpRect,
|
---|
3289 | cChildrenb,
|
---|
3290 | ahwndChildren));
|
---|
3291 |
|
---|
3292 | return (0);
|
---|
3293 | }
|
---|
3294 | /*****************************************************************************
|
---|
3295 | * Name : BOOL WIN32API TileChildWindows
|
---|
3296 | * Purpose : Unknown
|
---|
3297 | * Parameters: Unknown
|
---|
3298 | * Variables :
|
---|
3299 | * Result :
|
---|
3300 | * Remark :
|
---|
3301 | * Status : UNTESTED UNKNOWN STUB
|
---|
3302 | *
|
---|
3303 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3304 | *****************************************************************************/
|
---|
3305 | BOOL WIN32API TileChildWindows(DWORD x1,
|
---|
3306 | DWORD x2)
|
---|
3307 | {
|
---|
3308 | dprintf(("USER32: TileChildWindows(%08xh,%08xh) not implemented.\n",
|
---|
3309 | x1,
|
---|
3310 | x2));
|
---|
3311 |
|
---|
3312 | return (FALSE); /* default */
|
---|
3313 | }
|
---|
3314 | /*****************************************************************************
|
---|
3315 | * Name : BOOL WIN32API CascadeChildWindows
|
---|
3316 | * Purpose : Unknown
|
---|
3317 | * Parameters: Unknown
|
---|
3318 | * Variables :
|
---|
3319 | * Result :
|
---|
3320 | * Remark :
|
---|
3321 | * Status : UNTESTED UNKNOWN STUB
|
---|
3322 | *
|
---|
3323 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3324 | *****************************************************************************/
|
---|
3325 | BOOL WIN32API CascadeChildWindows(DWORD x1,
|
---|
3326 | DWORD x2)
|
---|
3327 | {
|
---|
3328 | dprintf(("USER32: CascadeChildWindows(%08xh,%08xh) not implemented.\n",
|
---|
3329 | x1,
|
---|
3330 | x2));
|
---|
3331 |
|
---|
3332 | return (FALSE); /* default */
|
---|
3333 | }
|
---|
3334 |
|
---|
3335 | /* Drag'n'drop */
|
---|
3336 |
|
---|
3337 | /*****************************************************************************
|
---|
3338 | * Name : BOOL WIN32API DragObject
|
---|
3339 | * Purpose : Unknown
|
---|
3340 | * Parameters: Unknown
|
---|
3341 | * Variables :
|
---|
3342 | * Result :
|
---|
3343 | * Remark :
|
---|
3344 | * Status : UNTESTED UNKNOWN STUB
|
---|
3345 | *
|
---|
3346 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3347 | *****************************************************************************/
|
---|
3348 | DWORD WIN32API DragObject(HWND x1,HWND x2,UINT x3,DWORD x4,HCURSOR x5)
|
---|
3349 | {
|
---|
3350 | dprintf(("USER32: DragObject(%08x,%08xh,%08xh,%08xh,%08xh) not implemented.\n",
|
---|
3351 | x1,
|
---|
3352 | x2,
|
---|
3353 | x3,
|
---|
3354 | x4,
|
---|
3355 | x5));
|
---|
3356 |
|
---|
3357 | return (FALSE); /* default */
|
---|
3358 | }
|
---|
3359 |
|
---|
3360 | /* Unknown */
|
---|
3361 |
|
---|
3362 | /*****************************************************************************
|
---|
3363 | * Name : BOOL WIN32API SetShellWindow
|
---|
3364 | * Purpose : Unknown
|
---|
3365 | * Parameters: Unknown
|
---|
3366 | * Variables :
|
---|
3367 | * Result :
|
---|
3368 | * Remark :
|
---|
3369 | * Status : UNTESTED UNKNOWN STUB
|
---|
3370 | *
|
---|
3371 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3372 | *****************************************************************************/
|
---|
3373 | BOOL WIN32API SetShellWindow(DWORD x1)
|
---|
3374 | {
|
---|
3375 | dprintf(("USER32: SetShellWindow(%08x) not implemented.\n",
|
---|
3376 | x1));
|
---|
3377 |
|
---|
3378 | return (FALSE); /* default */
|
---|
3379 | }
|
---|
3380 | /*****************************************************************************
|
---|
3381 | * Name : BOOL WIN32API PlaySoundEvent
|
---|
3382 | * Purpose : Unknown
|
---|
3383 | * Parameters: Unknown
|
---|
3384 | * Variables :
|
---|
3385 | * Result :
|
---|
3386 | * Remark :
|
---|
3387 | * Status : UNTESTED UNKNOWN STUB
|
---|
3388 | *
|
---|
3389 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3390 | *****************************************************************************/
|
---|
3391 | BOOL WIN32API PlaySoundEvent(DWORD x1)
|
---|
3392 | {
|
---|
3393 | dprintf(("USER32: PlaySoundEvent(%08x) not implemented.\n",
|
---|
3394 | x1));
|
---|
3395 |
|
---|
3396 | return (FALSE); /* default */
|
---|
3397 | }
|
---|
3398 | /*****************************************************************************
|
---|
3399 | * Name : BOOL WIN32API SetSysColorsTemp
|
---|
3400 | * Purpose : Unknown
|
---|
3401 | * Parameters: Unknown
|
---|
3402 | * Variables :
|
---|
3403 | * Result :
|
---|
3404 | * Remark :
|
---|
3405 | * Status : UNTESTED UNKNOWN STUB
|
---|
3406 | *
|
---|
3407 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3408 | *****************************************************************************/
|
---|
3409 | BOOL WIN32API SetSysColorsTemp(void)
|
---|
3410 | {
|
---|
3411 | dprintf(("USER32: SetSysColorsTemp() not implemented.\n"));
|
---|
3412 |
|
---|
3413 | return (FALSE); /* default */
|
---|
3414 | }
|
---|
3415 | /*****************************************************************************
|
---|
3416 | * Name : BOOL WIN32API RegisterNetworkCapabilities
|
---|
3417 | * Purpose : Unknown
|
---|
3418 | * Parameters: Unknown
|
---|
3419 | * Variables :
|
---|
3420 | * Result :
|
---|
3421 | * Remark :
|
---|
3422 | * Status : UNTESTED UNKNOWN STUB
|
---|
3423 | *
|
---|
3424 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3425 | *****************************************************************************/
|
---|
3426 | BOOL WIN32API RegisterNetworkCapabilities(DWORD x1,
|
---|
3427 | DWORD x2)
|
---|
3428 | {
|
---|
3429 | dprintf(("USER32: RegisterNetworkCapabilities(%08xh,%08xh) not implemented.\n",
|
---|
3430 | x1,
|
---|
3431 | x2));
|
---|
3432 |
|
---|
3433 | return (FALSE); /* default */
|
---|
3434 | }
|
---|
3435 | /*****************************************************************************
|
---|
3436 | * Name : BOOL WIN32API EndTask
|
---|
3437 | * Purpose : Unknown
|
---|
3438 | * Parameters: Unknown
|
---|
3439 | * Variables :
|
---|
3440 | * Result :
|
---|
3441 | * Remark :
|
---|
3442 | * Status : UNTESTED UNKNOWN STUB
|
---|
3443 | *
|
---|
3444 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3445 | *****************************************************************************/
|
---|
3446 | BOOL WIN32API EndTask(DWORD x1,
|
---|
3447 | DWORD x2,
|
---|
3448 | DWORD x3)
|
---|
3449 | {
|
---|
3450 | dprintf(("USER32: EndTask(%08xh,%08xh,%08xh) not implemented.\n",
|
---|
3451 | x1,
|
---|
3452 | x2,
|
---|
3453 | x3));
|
---|
3454 |
|
---|
3455 | return (FALSE); /* default */
|
---|
3456 | }
|
---|
3457 | /*****************************************************************************
|
---|
3458 | * Name : BOOL WIN32API GetNextQueueWindow
|
---|
3459 | * Purpose : Unknown
|
---|
3460 | * Parameters: Unknown
|
---|
3461 | * Variables :
|
---|
3462 | * Result :
|
---|
3463 | * Remark :
|
---|
3464 | * Status : UNTESTED UNKNOWN STUB
|
---|
3465 | *
|
---|
3466 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3467 | *****************************************************************************/
|
---|
3468 | BOOL WIN32API GetNextQueueWindow(DWORD x1,
|
---|
3469 | DWORD x2)
|
---|
3470 | {
|
---|
3471 | dprintf(("USER32: GetNextQueueWindow(%08xh,%08xh) not implemented.\n",
|
---|
3472 | x1,
|
---|
3473 | x2));
|
---|
3474 |
|
---|
3475 | return (FALSE); /* default */
|
---|
3476 | }
|
---|
3477 | /*****************************************************************************
|
---|
3478 | * Name : BOOL WIN32API YieldTask
|
---|
3479 | * Purpose : Unknown
|
---|
3480 | * Parameters: Unknown
|
---|
3481 | * Variables :
|
---|
3482 | * Result :
|
---|
3483 | * Remark :
|
---|
3484 | * Status : UNTESTED UNKNOWN STUB
|
---|
3485 | *
|
---|
3486 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3487 | *****************************************************************************/
|
---|
3488 | BOOL WIN32API YieldTask(void)
|
---|
3489 | {
|
---|
3490 | dprintf(("USER32: YieldTask() not implemented.\n"));
|
---|
3491 |
|
---|
3492 | return (FALSE); /* default */
|
---|
3493 | }
|
---|
3494 | /*****************************************************************************
|
---|
3495 | * Name : BOOL WIN32API WinOldAppHackoMatic
|
---|
3496 | * Purpose : Unknown
|
---|
3497 | * Parameters: Unknown
|
---|
3498 | * Variables :
|
---|
3499 | * Result :
|
---|
3500 | * Remark :
|
---|
3501 | * Status : UNTESTED UNKNOWN STUB
|
---|
3502 | *
|
---|
3503 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3504 | *****************************************************************************/
|
---|
3505 | BOOL WIN32API WinOldAppHackoMatic(DWORD x1)
|
---|
3506 | {
|
---|
3507 | dprintf(("USER32: WinOldAppHackoMatic(%08x) not implemented.\n",
|
---|
3508 | x1));
|
---|
3509 |
|
---|
3510 | return (FALSE); /* default */
|
---|
3511 | }
|
---|
3512 | /*****************************************************************************
|
---|
3513 | * Name : BOOL WIN32API RegisterSystemThread
|
---|
3514 | * Purpose : Unknown
|
---|
3515 | * Parameters: Unknown
|
---|
3516 | * Variables :
|
---|
3517 | * Result :
|
---|
3518 | * Remark :
|
---|
3519 | * Status : UNTESTED UNKNOWN STUB
|
---|
3520 | *
|
---|
3521 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3522 | *****************************************************************************/
|
---|
3523 | BOOL WIN32API RegisterSystemThread(DWORD x1,
|
---|
3524 | DWORD x2)
|
---|
3525 | {
|
---|
3526 | dprintf(("USER32: RegisterSystemThread(%08xh,%08xh) not implemented.\n",
|
---|
3527 | x1,
|
---|
3528 | x2));
|
---|
3529 |
|
---|
3530 | return (FALSE); /* default */
|
---|
3531 | }
|
---|
3532 | /*****************************************************************************
|
---|
3533 | * Name : BOOL WIN32API IsHungThread
|
---|
3534 | * Purpose : Unknown
|
---|
3535 | * Parameters: Unknown
|
---|
3536 | * Variables :
|
---|
3537 | * Result :
|
---|
3538 | * Remark :
|
---|
3539 | * Status : UNTESTED UNKNOWN STUB
|
---|
3540 | *
|
---|
3541 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3542 | *****************************************************************************/
|
---|
3543 | BOOL WIN32API IsHungThread(DWORD x1)
|
---|
3544 | {
|
---|
3545 | dprintf(("USER32: IsHungThread(%08xh) not implemented.\n",
|
---|
3546 | x1));
|
---|
3547 |
|
---|
3548 | return (FALSE); /* default */
|
---|
3549 | }
|
---|
3550 | /*****************************************************************************
|
---|
3551 | * Name : BOOL WIN32API UserSignalProc
|
---|
3552 | * Purpose : Unknown
|
---|
3553 | * Parameters: Unknown
|
---|
3554 | * Variables :
|
---|
3555 | * Result :
|
---|
3556 | * Remark :
|
---|
3557 | * Status : UNTESTED UNKNOWN STUB
|
---|
3558 | *
|
---|
3559 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3560 | *****************************************************************************/
|
---|
3561 | BOOL WIN32API UserSignalProc(DWORD x1,
|
---|
3562 | DWORD x2,
|
---|
3563 | DWORD x3,
|
---|
3564 | DWORD x4)
|
---|
3565 | {
|
---|
3566 | dprintf(("USER32: SysErrorBox(%08xh,%08xh,%08xh,%08xh) not implemented.\n",
|
---|
3567 | x1,
|
---|
3568 | x2,
|
---|
3569 | x3,
|
---|
3570 | x4));
|
---|
3571 |
|
---|
3572 | return (FALSE); /* default */
|
---|
3573 | }
|
---|
3574 | /*****************************************************************************
|
---|
3575 | * Name : BOOL WIN32API GetShellWindow
|
---|
3576 | * Purpose : Unknown
|
---|
3577 | * Parameters: Unknown
|
---|
3578 | * Variables :
|
---|
3579 | * Result :
|
---|
3580 | * Remark :
|
---|
3581 | * Status : UNTESTED UNKNOWN STUB
|
---|
3582 | *
|
---|
3583 | * Author : Patrick Haller [Wed, 1998/06/16 11:55]
|
---|
3584 | *****************************************************************************/
|
---|
3585 | HWND WIN32API GetShellWindow(void)
|
---|
3586 | {
|
---|
3587 | dprintf(("USER32: GetShellWindow() not implemented.\n"));
|
---|
3588 |
|
---|
3589 | return (0); /* default */
|
---|
3590 | }
|
---|
3591 | /***********************************************************************
|
---|
3592 | * RegisterTasklist32 [USER32.436]
|
---|
3593 | */
|
---|
3594 | DWORD WIN32API RegisterTasklist (DWORD x)
|
---|
3595 | {
|
---|
3596 | dprintf(("USER32: RegisterTasklist(%08xh) not implemented.\n",
|
---|
3597 | x));
|
---|
3598 |
|
---|
3599 | return TRUE;
|
---|
3600 | }
|
---|
3601 |
|
---|
3602 |
|
---|