00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029 #include <odin.h>
00030 #include <odinwrap.h>
00031 #include <os2sel.h>
00032
00033 #include <os2win.h>
00034 #include <misc.h>
00035 #include <winuser32.h>
00036
00037 #include "user32.h"
00038 #include <winicon.h>
00039 #include "syscolor.h"
00040 #include "pmwindow.h"
00041 #include "oslibgdi.h"
00042 #include "oslibwin.h"
00043 #include "oslibprf.h"
00044
00045 #include <wchar.h>
00046 #include <stdlib.h>
00047 #include <string.h>
00048
00049 #include <win32wnd.h>
00050 #include <winuser.h>
00051 #include "initterm.h"
00052
00053 #define DBG_LOCALLOG DBG_user32
00054 #include "dbglocal.h"
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090 ODINDEBUGCHANNEL(USER32-USER32)
00091
00092
00093
00094
00095
00096
00097 BOOL WIN32API CopyRect( PRECT lprcDst, const RECT * lprcSrc)
00098 {
00099 dprintf2(("USER32: CopyRect\n"));
00100 if (!lprcDst || !lprcSrc) {
00101 SetLastError(ERROR_INVALID_PARAMETER);
00102 return FALSE;
00103 }
00104
00105 memcpy(lprcDst,lprcSrc,sizeof(RECT));
00106
00107 return TRUE;
00108 }
00109
00110
00111 BOOL WIN32API EqualRect( const RECT *lprc1, const RECT *lprc2)
00112 {
00113 dprintf2(("USER32: EqualRect\n"));
00114 if (!lprc1 || !lprc2)
00115 {
00116 SetLastError(ERROR_INVALID_PARAMETER);
00117 return FALSE;
00118 }
00119
00120 return (lprc1->left == lprc2->left &&
00121 lprc1->right == lprc2->right &&
00122 lprc1->top == lprc2->top &&
00123 lprc1->bottom == lprc2->bottom);
00124 }
00125
00126
00127 BOOL WIN32API InflateRect( PRECT lprc, int dx, int dy)
00128 {
00129 dprintf2(("USER32: InflateRect (%d,%d)(%d,%d) %d,%d", lprc->left, lprc->top, lprc->right, lprc->bottom, dx, dy));
00130 if (!lprc)
00131 {
00132 SetLastError(ERROR_INVALID_PARAMETER);
00133 return FALSE;
00134 }
00135
00136 lprc->left -= dx;
00137 lprc->right += dx;
00138 lprc->top -= dy;
00139 lprc->bottom += dy;
00140
00141 return TRUE;
00142 }
00143
00144
00145 BOOL WIN32API IntersectRect( PRECT lprcDst, const RECT * lprcSrc1, const RECT * lprcSrc2)
00146 {
00147 dprintf2(("USER32: IntersectRect (%d,%d)(%d,%d) (%d,%d)(%d,%d)", lprcSrc1->left, lprcSrc1->top, lprcSrc1->right, lprcSrc1->bottom, lprcSrc2->left, lprcSrc2->top, lprcSrc2->right, lprcSrc2->bottom));
00148 if (!lprcSrc1 || !lprcSrc2)
00149 {
00150 SetLastError(ERROR_INVALID_PARAMETER);
00151 return FALSE;
00152 }
00153
00154 if (IsRectEmpty(lprcSrc1) || IsRectEmpty(lprcSrc2) ||
00155 (lprcSrc1->left >= lprcSrc2->right) || (lprcSrc2->left >= lprcSrc1->right) ||
00156 (lprcSrc1->top >= lprcSrc2->bottom) || (lprcSrc2->top >= lprcSrc1->bottom))
00157 {
00158
00159
00160 if (lprcDst) SetRectEmpty(lprcDst);
00161 return FALSE;
00162 }
00163 if (lprcDst)
00164 {
00165 lprcDst->left = MAX(lprcSrc1->left,lprcSrc2->left);
00166 lprcDst->right = MIN(lprcSrc1->right,lprcSrc2->right);
00167 lprcDst->top = MAX(lprcSrc1->top,lprcSrc2->top);
00168 lprcDst->bottom = MIN(lprcSrc1->bottom,lprcSrc2->bottom);
00169 }
00170
00171 return TRUE;
00172 }
00173
00174
00175 BOOL WIN32API IsRectEmpty( const RECT * lprc)
00176 {
00177 if (!lprc)
00178 {
00179 SetLastError(ERROR_INVALID_PARAMETER);
00180 return FALSE;
00181 }
00182
00183 return (lprc->left == lprc->right || lprc->top == lprc->bottom);
00184 }
00185
00186
00187 BOOL WIN32API OffsetRect( PRECT lprc, int x, int y)
00188 {
00189 dprintf2(("USER32: OffsetRect (%d,%d)(%d,%d) %d %d", lprc->left, lprc->top, lprc->right, lprc->bottom, x, y));
00190 if (!lprc)
00191 {
00192 SetLastError(ERROR_INVALID_PARAMETER);
00193 return FALSE;
00194 }
00195
00196 lprc->left += x;
00197 lprc->right += x;
00198 lprc->top += y;
00199 lprc->bottom += y;
00200
00201 return TRUE;
00202 }
00203
00204
00205 BOOL WIN32API PtInRect( const RECT *lprc, POINT pt)
00206 {
00207 dprintf2(("USER32: PtInRect (%d,%d)(%d,%d) (%d,%d)", lprc->left, lprc->top, lprc->right, lprc->bottom, pt.x, pt.y));
00208 if (!lprc)
00209 {
00210 SetLastError(ERROR_INVALID_PARAMETER);
00211 return FALSE;
00212 }
00213
00214 return (pt.x >= lprc->left &&
00215 pt.x < lprc->right &&
00216 pt.y >= lprc->top &&
00217 pt.y < lprc->bottom);
00218 }
00219
00220
00221 BOOL WIN32API SetRect( PRECT lprc, int nLeft, int nTop, int nRight, int nBottom)
00222 {
00223 if (!lprc)
00224 {
00225 SetLastError(ERROR_INVALID_PARAMETER);
00226 return FALSE;
00227 }
00228
00229 lprc->left = nLeft;
00230 lprc->top = nTop;
00231 lprc->right = nRight;
00232 lprc->bottom = nBottom;
00233
00234 return TRUE;
00235 }
00236
00237
00238 BOOL WIN32API SetRectEmpty( PRECT lprc)
00239 {
00240 if (!lprc)
00241 {
00242 SetLastError(ERROR_INVALID_PARAMETER);
00243 return FALSE;
00244 }
00245
00246 lprc->left = lprc->right = lprc->top = lprc->bottom = 0;
00247
00248 return TRUE;
00249 }
00250
00251
00252 BOOL WIN32API SubtractRect( PRECT lprcDest, const RECT * lprcSrc1, const RECT * lprcSrc2)
00253 {
00254 dprintf2(("USER32: SubtractRect"));
00255 RECT tmp;
00256
00257 if (!lprcDest || !lprcSrc1 || !lprcSrc2)
00258 {
00259 SetLastError(ERROR_INVALID_PARAMETER);
00260 return FALSE;
00261 }
00262
00263 if (IsRectEmpty(lprcSrc1))
00264 {
00265 SetLastError(ERROR_INVALID_PARAMETER);
00266 SetRectEmpty(lprcDest);
00267 return FALSE;
00268 }
00269 *lprcDest = *lprcSrc1;
00270 if (IntersectRect(&tmp,lprcSrc1,lprcSrc2))
00271 {
00272 if (EqualRect(&tmp,lprcDest))
00273 {
00274 SetRectEmpty(lprcDest);
00275 return FALSE;
00276 }
00277 if ((tmp.top == lprcDest->top) && (tmp.bottom == lprcDest->bottom))
00278 {
00279 if (tmp.left == lprcDest->left) lprcDest->left = tmp.right;
00280 else if (tmp.right == lprcDest->right) lprcDest->right = tmp.left;
00281 }
00282 else if ((tmp.left == lprcDest->left) && (tmp.right == lprcDest->right))
00283 {
00284 if (tmp.top == lprcDest->top) lprcDest->top = tmp.bottom;
00285 else if (tmp.bottom == lprcDest->bottom) lprcDest->bottom = tmp.top;
00286 }
00287 }
00288
00289 return TRUE;
00290 }
00291
00292
00293 BOOL WIN32API UnionRect( PRECT lprcDst, const RECT *lprcSrc1, const RECT *lprcSrc2)
00294 {
00295 dprintf2(("USER32: UnionRect\n"));
00296 if (!lprcDst || !lprcSrc1 || !lprcSrc2)
00297 {
00298 SetLastError(ERROR_INVALID_PARAMETER);
00299 return FALSE;
00300 }
00301
00302 if (IsRectEmpty(lprcSrc1))
00303 {
00304 if (IsRectEmpty(lprcSrc2))
00305 {
00306 SetLastError(ERROR_INVALID_PARAMETER);
00307 SetRectEmpty(lprcDst);
00308 return FALSE;
00309 }
00310 else *lprcDst = *lprcSrc2;
00311 }
00312 else
00313 {
00314 if (IsRectEmpty(lprcSrc2)) *lprcDst = *lprcSrc1;
00315 else
00316 {
00317 lprcDst->left = MIN(lprcSrc1->left,lprcSrc2->left);
00318 lprcDst->right = MAX(lprcSrc1->right,lprcSrc2->right);
00319 lprcDst->top = MIN(lprcSrc1->top,lprcSrc2->top);
00320 lprcDst->bottom = MAX(lprcSrc1->bottom,lprcSrc2->bottom);
00321 }
00322 }
00323
00324 return TRUE;
00325 }
00326
00327
00328
00329
00330
00331
00332
00333
00334
00335
00336
00337
00338
00339
00340
00341
00342
00343
00344 ODINFUNCTION2(BOOL, ExitWindowsEx, UINT, uFlags,
00345 DWORD, dwReserved)
00346 {
00347 int rc = MessageBoxA(HWND_DESKTOP,
00348 "Are you sure you want to shutdown the OS/2 system?",
00349 "Shutdown ...",
00350 MB_YESNOCANCEL | MB_ICONQUESTION);
00351 switch (rc)
00352 {
00353 case IDCANCEL: return (FALSE);
00354 case IDYES: break;
00355 case IDNO:
00356 dprintf(("no shutdown!\n"));
00357 return TRUE;
00358 }
00359
00360 return O32_ExitWindowsEx(uFlags,dwReserved);
00361 }
00362
00363
00364
00365
00366 BOOL WIN32API MessageBeep( UINT uType)
00367 {
00368 INT flStyle;
00369
00370 dprintf(("USER32: MessageBeep\n"));
00371
00372 switch (uType)
00373 {
00374 case 0xFFFFFFFF:
00375 Beep(500,50);
00376 return TRUE;
00377 case MB_ICONASTERISK:
00378 flStyle = WAOS_NOTE;
00379 break;
00380 case MB_ICONEXCLAMATION:
00381 flStyle = WAOS_WARNING;
00382 break;
00383 case MB_ICONHAND:
00384 case MB_ICONQUESTION:
00385 case MB_OK:
00386 flStyle = WAOS_NOTE;
00387 break;
00388 default:
00389 flStyle = WAOS_ERROR;
00390 break;
00391 }
00392 return OSLibWinAlarm(OSLIB_HWND_DESKTOP,flStyle);
00393 }
00394
00395
00396
00397 VOID WIN32API SetLastErrorEx(DWORD dwErrCode, DWORD dwType)
00398 {
00399 dprintf(("USER32: SetLastErrorEx %x %x", dwErrCode, dwType));
00400 SetLastError(dwErrCode);
00401 }
00402
00403
00404
00405 int WIN32API GetSystemMetrics(int nIndex)
00406 {
00407 int rc = 0;
00408
00409 switch(nIndex) {
00410 case SM_CXSCREEN:
00411 rc = ScreenWidth;
00412 break;
00413
00414 case SM_CYSCREEN:
00415 rc = ScreenHeight;
00416 break;
00417
00418 case SM_CXVSCROLL:
00419 rc = OSLibWinQuerySysValue(SVOS_CXVSCROLL);
00420 break;
00421
00422 case SM_CYHSCROLL:
00423 rc = OSLibWinQuerySysValue(SVOS_CYHSCROLL);
00424 break;
00425
00426 case SM_CYCAPTION:
00427 if(fOS2Look) {
00428 rc = OSLibWinQuerySysValue(SVOS_CYTITLEBAR);
00429 }
00430 else rc = 19;
00431 break;
00432
00433 case SM_CXBORDER:
00434 case SM_CYBORDER:
00435 rc = 1;
00436 break;
00437
00438 case SM_CXDLGFRAME:
00439 case SM_CYDLGFRAME:
00440 rc = 3;
00441 break;
00442
00443 case SM_CYMENU:
00444 case SM_CXMENUSIZE:
00445 case SM_CYMENUSIZE:
00446 if(fOS2Look) {
00447 rc = OSLibWinQuerySysValue(SVOS_CYMENU);
00448 }
00449 else rc = 19;
00450 break;
00451
00452 case SM_CXSIZE:
00453 case SM_CYSIZE:
00454 rc = GetSystemMetrics(SM_CYCAPTION)-2;
00455 break;
00456
00457 case SM_CXFRAME:
00458 case SM_CYFRAME:
00459 rc = 4;
00460 break;
00461
00462 case SM_CXEDGE:
00463 case SM_CYEDGE:
00464 rc = 2;
00465 break;
00466
00467 case SM_CXMINSPACING:
00468 rc = 160;
00469 break;
00470
00471 case SM_CYMINSPACING:
00472 rc = 24;
00473 break;
00474
00475 case SM_CXSMICON:
00476 case SM_CYSMICON:
00477 rc = 16;
00478 break;
00479
00480 case SM_CYSMCAPTION:
00481 rc = 16;
00482 break;
00483
00484 case SM_CXSMSIZE:
00485 case SM_CYSMSIZE:
00486 rc = 15;
00487 break;
00488
00489
00490
00491 case SM_CXICONSPACING:
00492 rc = OSLibWinQuerySysValue(SVOS_CXICON);
00493
00494
00495 break;
00496 case SM_CYICONSPACING:
00497 rc = OSLibWinQuerySysValue(SVOS_CYICON);
00498
00499
00500 break;
00501 case SM_PENWINDOWS:
00502 rc = FALSE;
00503 break;
00504 case SM_DBCSENABLED:
00505 rc = FALSE;
00506 break;
00507 case SM_CXICON:
00508 case SM_CYICON:
00509 rc = 32;
00510
00511 break;
00512 case SM_ARRANGE:
00513 rc = ARW_BOTTOMLEFT | ARW_LEFT;
00514 break;
00515 case SM_CXMINIMIZED:
00516 break;
00517 case SM_CYMINIMIZED:
00518 break;
00519
00520 case SM_CXMINTRACK:
00521 case SM_CXMIN:
00522 rc = 112;
00523 break;
00524
00525 case SM_CYMINTRACK:
00526 case SM_CYMIN:
00527 rc = 27;
00528 break;
00529
00530 case SM_CXMAXTRACK:
00531 case SM_CXMAXIMIZED:
00532 rc = OSLibWinQuerySysValue(SVOS_CXSCREEN);
00533 break;
00534
00535 case SM_CYMAXTRACK:
00536 case SM_CYMAXIMIZED:
00537 rc = OSLibWinQuerySysValue(SVOS_CYSCREEN);
00538 break;
00539
00540 case SM_NETWORK:
00541 rc = 0x01;
00542 break;
00543 case SM_CLEANBOOT:
00544 rc = 0;
00545 break;
00546 case SM_CXDRAG:
00547 rc = 2;
00548 break;
00549 case SM_CYDRAG:
00550 rc = 2;
00551 break;
00552 case SM_SHOWSOUNDS:
00553 rc = FALSE;
00554 break;
00555 case SM_CXMENUCHECK:
00556 rc = 4;
00557 break;
00558 case SM_CYMENUCHECK:
00559 rc = OSLibWinQuerySysValue(SVOS_CYMENU);
00560 break;
00561 case SM_SLOWMACHINE:
00562 rc = FALSE;
00563 break;
00564 case SM_MIDEASTENABLED:
00565 rc = FALSE;
00566 break;
00567 case SM_MOUSEWHEELPRESENT:
00568 rc = FALSE;
00569 break;
00570 case SM_XVIRTUALSCREEN:
00571 rc = 0;
00572 break;
00573 case SM_YVIRTUALSCREEN:
00574 rc = 0;
00575 break;
00576
00577 case SM_CXVIRTUALSCREEN:
00578 rc = OSLibWinQuerySysValue(SVOS_CXSCREEN);
00579 break;
00580 case SM_CYVIRTUALSCREEN:
00581 rc = OSLibWinQuerySysValue(SVOS_CYSCREEN);
00582 break;
00583 case SM_CMONITORS:
00584 rc = 1;
00585 break;
00586 case SM_SAMEDISPLAYFORMAT:
00587 rc = TRUE;
00588 break;
00589 case SM_CMETRICS:
00590 rc = 81;
00591
00592 break;
00593 default:
00594
00595 rc = O32_GetSystemMetrics(nIndex);
00596 break;
00597 }
00598 dprintf2(("USER32: GetSystemMetrics %d returned %d\n", nIndex, rc));
00599 return(rc);
00600 }
00601
00602
00603
00604
00605
00606
00607
00608
00609
00610
00611
00612
00613
00614
00615
00616
00617
00618
00619
00620
00621
00622
00623
00624 BOOL WIN32API SystemParametersInfoA(UINT uiAction, UINT uiParam, PVOID pvParam, UINT fWinIni)
00625 {
00626 BOOL rc = TRUE;
00627
00628 dprintf(("USER32: SystemParametersInfoA uiAction: %d, uiParam: %d, pvParam: %d, fWinIni: %d\n",
00629 uiAction, uiParam, pvParam, fWinIni));
00630
00631 switch(uiAction) {
00632
00633 case SPI_GETBEEP:
00634 *(ULONG*)pvParam = OSLibWinQuerySysValue(SVOS_ALARM);
00635 break;
00636
00637 case SPI_GETKEYBOARDDELAY:
00638 *(PULONG)pvParam = OSLibPrfQueryProfileInt(OSLIB_HINI_USER, "PM_ControlPanel",
00639 "KeyRepeatDelay", 90);
00640 break;
00641
00642 case SPI_GETKEYBOARDSPEED:
00643 *(PULONG)pvParam = OSLibPrfQueryProfileInt(OSLIB_HINI_USER, "PM_ControlPanel",
00644 "KeyRepeatRate", 19);
00645 break;
00646
00647 #if 0
00648
00649 case SPI_GETMOUSE:
00650 {
00651 ULONG retCode;
00652 retCode = OSLibDosOpen(
00653 break;
00654 }
00655 #endif
00656
00657 case SPI_SETBEEP:
00658
00659 dprintf(("USER32: SPI_SETBEEP is ignored!\n"));
00660 break;
00661
00662 case SPI_SETBORDER:
00663
00664 dprintf(("USER32: SPI_SETBORDER is ignored, implement!\n"));
00665 break;
00666
00667 case SPI_SETDOUBLECLKHEIGHT:
00668
00669 dprintf(("USER32: SPI_SETDOUBLECLICKHEIGHT is ignored, implement!\n"));
00670 break;
00671
00672 case SPI_SETDOUBLECLKWIDTH:
00673
00674 dprintf(("USER32: SPI_SETDOUBLECLICKWIDTH is ignored, implement!\n"));
00675 break;
00676
00677 case SPI_SETDOUBLECLICKTIME:
00678
00679 dprintf(("USER32: SPI_SETDOUBLECLICKTIME is ignored, implement!\n"));
00680 break;
00681
00682 case SPI_SETKEYBOARDDELAY:
00683
00684 dprintf(("USER32: SPI_SETKEYBOARDDELAY is ignored, implement!\n"));
00685 break;
00686
00687 case SPI_SETKEYBOARDSPEED:
00688
00689 dprintf(("USER32: SPI_SETKEYBOARDSPEED is ignored, implement!\n"));
00690 break;
00691
00692 case SPI_SETMOUSE:
00693
00694 dprintf(("USER32: SPI_SETMOUSE is ignored, implement!\n"));
00695 break;
00696
00697 case SPI_SETMOUSEBUTTONSWAP:
00698
00699 dprintf(("USER32: SPI_SETMOUSEBUTTONSWAP is ignored, implement!\n"));
00700 break;
00701
00702 case SPI_SCREENSAVERRUNNING:
00703 *(BOOL *)pvParam = FALSE;
00704 break;
00705
00706 case SPI_GETDRAGFULLWINDOWS:
00707 *(BOOL *)pvParam = OSLibWinQuerySysValue(SVOS_DYNAMICDRAG);
00708 break;
00709
00710 case SPI_GETNONCLIENTMETRICS:
00711 {
00712 LPNONCLIENTMETRICSA lpnm = (LPNONCLIENTMETRICSA)pvParam;
00713
00714 if (lpnm->cbSize == sizeof(NONCLIENTMETRICSA))
00715 {
00716 memset(lpnm, 0, sizeof(NONCLIENTMETRICSA));
00717 lpnm->cbSize = sizeof(NONCLIENTMETRICSA);
00718
00719 SystemParametersInfoA(SPI_GETICONTITLELOGFONT, 0, (LPVOID)&(lpnm->lfCaptionFont),0);
00720 lpnm->lfCaptionFont.lfWeight = FW_BOLD;
00721 lpnm->iCaptionWidth = 32;
00722 lpnm->iCaptionHeight = 32;
00723
00724 SystemParametersInfoA(SPI_GETICONTITLELOGFONT, 0, (LPVOID)&(lpnm->lfSmCaptionFont),0);
00725 lpnm->iSmCaptionWidth = GetSystemMetrics(SM_CXSMSIZE);
00726 lpnm->iSmCaptionHeight = GetSystemMetrics(SM_CYSMSIZE);
00727
00728 LPLOGFONTA lpLogFont = &(lpnm->lfMenuFont);
00729 if(fOS2Look) {
00730 char fontname[128];
00731 char *pszFontName;
00732 BOOL fFound = TRUE;
00733
00734 if(OSLibPrfQueryProfileString(OSLIB_HINI_USER, "PM_SystemFonts", "Menus", "", fontname, sizeof(fontname)) == 1) {
00735 if(OSLibPrfQueryProfileString(OSLIB_HINI_USER, "PM_SystemFonts", "DefaultFont", "", fontname, sizeof(fontname)) == 1) {
00736 fFound = FALSE;
00737 }
00738 }
00739 if(fFound) {
00740 pszFontName = fontname;
00741 while(*pszFontName != '.' && *pszFontName != 0) pszFontName++;
00742 if(*pszFontName) {
00743 *pszFontName++ = 0;
00744
00745 strncpy(lpLogFont->lfFaceName, pszFontName, sizeof(lpLogFont->lfFaceName));
00746 lpLogFont->lfFaceName[sizeof(lpLogFont->lfFaceName)-1] = 0;
00747 lpLogFont->lfWeight = FW_NORMAL;
00748
00749
00750
00751
00752 lpLogFont->lfHeight = CapsCharHeight;
00753 }
00754 else fFound = FALSE;
00755 }
00756 if(!fFound) {
00757 GetProfileStringA("Desktop", "MenuFont", "WarpSans",
00758 lpLogFont->lfFaceName, LF_FACESIZE);
00759 lpLogFont->lfWeight = FW_BOLD;
00760
00761 lpLogFont->lfHeight = -GetProfileIntA("Desktop","MenuFontSize", CapsCharHeight);
00762 }
00763 lpLogFont->lfWidth = 0;
00764 lpLogFont->lfEscapement = lpLogFont->lfOrientation = 0;
00765 }
00766 else {
00767 GetProfileStringA("Desktop", "MenuFont", "MS Sans Serif",
00768 lpLogFont->lfFaceName, LF_FACESIZE);
00769 lpLogFont->lfWeight = FW_NORMAL;
00770 lpLogFont->lfHeight = -GetProfileIntA("Desktop","MenuFontSize", 13);
00771 lpLogFont->lfWidth = 0;
00772 lpLogFont->lfEscapement = lpLogFont->lfOrientation = 0;
00773 }
00774 lpLogFont->lfItalic = FALSE;
00775 lpLogFont->lfStrikeOut = FALSE;
00776 lpLogFont->lfUnderline = FALSE;
00777 lpLogFont->lfCharSet = ANSI_CHARSET;
00778 lpLogFont->lfOutPrecision = OUT_DEFAULT_PRECIS;
00779 lpLogFont->lfClipPrecision = CLIP_DEFAULT_PRECIS;
00780 lpLogFont->lfPitchAndFamily = DEFAULT_PITCH | FF_SWISS;
00781
00782 SystemParametersInfoA(SPI_GETICONTITLELOGFONT, 0,
00783 (LPVOID)&(lpnm->lfStatusFont),0);
00784 SystemParametersInfoA(SPI_GETICONTITLELOGFONT, 0,
00785 (LPVOID)&(lpnm->lfMessageFont),0);
00786
00787 lpnm->iBorderWidth = GetSystemMetrics(SM_CXBORDER);
00788 lpnm->iScrollWidth = GetSystemMetrics(SM_CXHSCROLL);
00789 lpnm->iScrollHeight = GetSystemMetrics(SM_CYHSCROLL);
00790 lpnm->iMenuHeight = GetSystemMetrics(SM_CYMENU);
00791 lpnm->iMenuWidth = lpnm->iMenuHeight;
00792 }
00793 else
00794 {
00795 dprintf(("SPI_GETNONCLIENTMETRICS: size mismatch !! (is %d; should be %d)\n", lpnm->cbSize, sizeof(NONCLIENTMETRICSA)));
00796
00797 rc = FALSE;
00798 }
00799 break;
00800 }
00801
00802 case SPI_GETICONMETRICS:
00803 {
00804 LPICONMETRICSA lpIcon = (LPICONMETRICSA)pvParam;
00805 if(lpIcon && lpIcon->cbSize == sizeof(*lpIcon))
00806 {
00807 SystemParametersInfoA( SPI_ICONHORIZONTALSPACING, 0,
00808 &lpIcon->iHorzSpacing, FALSE );
00809 SystemParametersInfoA( SPI_ICONVERTICALSPACING, 0,
00810 &lpIcon->iVertSpacing, FALSE );
00811 SystemParametersInfoA( SPI_GETICONTITLEWRAP, 0,
00812 &lpIcon->iTitleWrap, FALSE );
00813 SystemParametersInfoA( SPI_GETICONTITLELOGFONT, 0,
00814 &lpIcon->lfFont, FALSE );
00815 }
00816 else
00817 {
00818 dprintf(("SPI_GETICONMETRICS: size mismatch !! (is %d; should be %d)\n", lpIcon->cbSize, sizeof(ICONMETRICSA)));
00819
00820 rc = FALSE;
00821 }
00822 break;
00823 }
00824
00825 case SPI_GETICONTITLELOGFONT:
00826 {
00827 LPLOGFONTA lpLogFont = (LPLOGFONTA)pvParam;
00828
00829
00830 strcpy(lpLogFont->lfFaceName, "MS Sans Serif");
00831 lpLogFont->lfHeight = -GetProfileIntA("Desktop","IconTitleSize", 12);
00832 lpLogFont->lfWidth = 0;
00833 lpLogFont->lfEscapement = lpLogFont->lfOrientation = 0;
00834 lpLogFont->lfWeight = FW_NORMAL;
00835 lpLogFont->lfItalic = FALSE;
00836 lpLogFont->lfStrikeOut = FALSE;
00837 lpLogFont->lfUnderline = FALSE;
00838 lpLogFont->lfCharSet = ANSI_CHARSET;
00839 lpLogFont->lfOutPrecision = OUT_DEFAULT_PRECIS;
00840 lpLogFont->lfClipPrecision = CLIP_DEFAULT_PRECIS;
00841 lpLogFont->lfPitchAndFamily = DEFAULT_PITCH | FF_SWISS;
00842 break;
00843 }
00844 case SPI_GETBORDER:
00845 *(INT *)pvParam = GetSystemMetrics( SM_CXFRAME );
00846 break;
00847
00848 case SPI_GETWORKAREA:
00849 SetRect( (RECT *)pvParam, 0, 0,
00850 GetSystemMetrics( SM_CXSCREEN ),
00851 GetSystemMetrics( SM_CYSCREEN )
00852 );
00853 break;
00854
00855 case SPI_GETWHEELSCROLLLINES:
00856 rc = 16;
00857 break;
00858
00859 default:
00860 dprintf(("System parameter value is not supported!\n"));
00861 rc = FALSE;
00862
00863
00864 break;
00865 }
00866 dprintf(("USER32: SystemParametersInfoA %d, returned %d\n", uiAction, rc));
00867 return(rc);
00868 }
00869
00870
00871
00872 BOOL WIN32API SystemParametersInfoW(UINT uiAction, UINT uiParam, PVOID pvParam, UINT fWinIni)
00873 {
00874 BOOL rc = TRUE;
00875 NONCLIENTMETRICSW *clientMetricsW = (NONCLIENTMETRICSW *)pvParam;
00876 NONCLIENTMETRICSA clientMetricsA = {0};
00877 PVOID pvParamA;
00878 UINT uiParamA;
00879
00880 switch(uiAction) {
00881 case SPI_SETNONCLIENTMETRICS:
00882 clientMetricsA.cbSize = sizeof(NONCLIENTMETRICSA);
00883 clientMetricsA.iBorderWidth = clientMetricsW->iBorderWidth;
00884 clientMetricsA.iScrollWidth = clientMetricsW->iScrollWidth;
00885 clientMetricsA.iScrollHeight = clientMetricsW->iScrollHeight;
00886 clientMetricsA.iCaptionWidth = clientMetricsW->iCaptionWidth;
00887 clientMetricsA.iCaptionHeight = clientMetricsW->iCaptionHeight;
00888 ConvertFontWA(&clientMetricsW->lfCaptionFont, &clientMetricsA.lfCaptionFont);
00889 clientMetricsA.iSmCaptionWidth = clientMetricsW->iSmCaptionWidth;
00890 clientMetricsA.iSmCaptionHeight = clientMetricsW->iSmCaptionHeight;
00891 ConvertFontWA(&clientMetricsW->lfSmCaptionFont, &clientMetricsA.lfSmCaptionFont);
00892 clientMetricsA.iMenuWidth = clientMetricsW->iMenuWidth;
00893 clientMetricsA.iMenuHeight = clientMetricsW->iMenuHeight;
00894 ConvertFontWA(&clientMetricsW->lfMenuFont, &clientMetricsA.lfMenuFont);
00895 ConvertFontWA(&clientMetricsW->lfStatusFont, &clientMetricsA.lfStatusFont);
00896 ConvertFontWA(&clientMetricsW->lfMessageFont, &clientMetricsA.lfMessageFont);
00897
00898 case SPI_GETNONCLIENTMETRICS:
00899 uiParamA = sizeof(NONCLIENTMETRICSA);
00900 pvParamA = &clientMetricsA;
00901 break;
00902
00903 case SPI_GETICONMETRICS:
00904 {
00905 LPICONMETRICSW lpIcon = (LPICONMETRICSW)pvParam;
00906 if(lpIcon && lpIcon->cbSize == sizeof(*lpIcon))
00907 {
00908 SystemParametersInfoW( SPI_ICONHORIZONTALSPACING, 0,
00909 &lpIcon->iHorzSpacing, FALSE );
00910 SystemParametersInfoW( SPI_ICONVERTICALSPACING, 0,
00911 &lpIcon->iVertSpacing, FALSE );
00912 SystemParametersInfoW( SPI_GETICONTITLEWRAP, 0,
00913 &lpIcon->iTitleWrap, FALSE );
00914 SystemParametersInfoW( SPI_GETICONTITLELOGFONT, 0,
00915 &lpIcon->lfFont, FALSE );
00916 return TRUE;
00917 }
00918 else
00919 {
00920 dprintf(("SPI_GETICONMETRICS: size mismatch !! (is %d; should be %d)\n", lpIcon->cbSize, sizeof(ICONMETRICSA)));
00921
00922 return FALSE;
00923 }
00924 }
00925
00926 case SPI_GETICONTITLELOGFONT:
00927 {
00928 LPLOGFONTW lpLogFont = (LPLOGFONTW)pvParam;
00929
00930
00931 lstrcpyW(lpLogFont->lfFaceName, (LPCWSTR)L"MS Sans Serif");
00932 lpLogFont->lfHeight = -GetProfileIntA("Desktop","IconTitleSize", 12);
00933 lpLogFont->lfWidth = 0;
00934 lpLogFont->lfEscapement = lpLogFont->lfOrientation = 0;
00935 lpLogFont->lfWeight = FW_NORMAL;
00936 lpLogFont->lfItalic = FALSE;
00937 lpLogFont->lfStrikeOut = FALSE;
00938 lpLogFont->lfUnderline = FALSE;
00939 lpLogFont->lfCharSet = ANSI_CHARSET;
00940 lpLogFont->lfOutPrecision = OUT_DEFAULT_PRECIS;
00941 lpLogFont->lfClipPrecision = CLIP_DEFAULT_PRECIS;
00942 lpLogFont->lfPitchAndFamily = DEFAULT_PITCH | FF_SWISS;
00943 return TRUE;
00944 }
00945 default:
00946 pvParamA = pvParam;
00947 uiParamA = uiParam;
00948 break;
00949 }
00950 rc = SystemParametersInfoA(uiAction, uiParamA, pvParamA, fWinIni);
00951
00952 switch(uiAction) {
00953 case SPI_GETNONCLIENTMETRICS:
00954 clientMetricsW->cbSize = sizeof(*clientMetricsW);
00955 clientMetricsW->iBorderWidth = clientMetricsA.iBorderWidth;
00956 clientMetricsW->iScrollWidth = clientMetricsA.iScrollWidth;
00957 clientMetricsW->iScrollHeight = clientMetricsA.iScrollHeight;
00958 clientMetricsW->iCaptionWidth = clientMetricsA.iCaptionWidth;
00959 clientMetricsW->iCaptionHeight = clientMetricsA.iCaptionHeight;
00960 ConvertFontAW(&clientMetricsA.lfCaptionFont, &clientMetricsW->lfCaptionFont);
00961
00962 clientMetricsW->iSmCaptionWidth = clientMetricsA.iSmCaptionWidth;
00963 clientMetricsW->iSmCaptionHeight = clientMetricsA.iSmCaptionHeight;
00964 ConvertFontAW(&clientMetricsA.lfSmCaptionFont, &clientMetricsW->lfSmCaptionFont);
00965
00966 clientMetricsW->iMenuWidth = clientMetricsA.iMenuWidth;
00967 clientMetricsW->iMenuHeight = clientMetricsA.iMenuHeight;
00968 ConvertFontAW(&clientMetricsA.lfMenuFont, &clientMetricsW->lfMenuFont);
00969 ConvertFontAW(&clientMetricsA.lfStatusFont, &clientMetricsW->lfStatusFont);
00970 ConvertFontAW(&clientMetricsA.lfMessageFont, &clientMetricsW->lfMessageFont);
00971 break;
00972 }
00973 dprintf(("USER32: SystemParametersInfoW %d, returned %d\n", uiAction, rc));
00974 return(rc);
00975 }
00976
00977
00978
00979 BOOL WIN32API WinHelpA( HWND hwnd, LPCSTR lpszHelp, UINT uCommand, DWORD dwData)
00980 {
00981 static WORD WM_WINHELP = 0;
00982 HWND hDest;
00983 LPWINHELP lpwh;
00984 HINSTANCE winhelp;
00985 int size,dsize,nlen;
00986 BOOL ret;
00987
00988 dprintf(("USER32: WinHelpA %x %s %d %x", hwnd, lpszHelp, uCommand, dwData));
00989
00990 if(!WM_WINHELP)
00991 {
00992 WM_WINHELP=RegisterWindowMessageA("WM_WINHELP");
00993 if(!WM_WINHELP)
00994 return FALSE;
00995 }
00996
00997 hDest = FindWindowA( "MS_WINHELP", NULL );
00998 if(!hDest)
00999 {
01000 if(uCommand == HELP_QUIT)
01001 return TRUE;
01002 else
01003 winhelp = WinExec ( "winhlp32.exe -x", SW_SHOWNORMAL );
01004 if ( winhelp <= 32 ) return FALSE;
01005 if ( ! ( hDest = FindWindowA ( "MS_WINHELP", NULL ) )) return FALSE;
01006 }
01007
01008 switch(uCommand)
01009 {
01010 case HELP_CONTEXT:
01011 case HELP_SETCONTENTS:
01012 case HELP_CONTENTS:
01013 case HELP_CONTEXTPOPUP:
01014 case HELP_FORCEFILE:
01015 case HELP_HELPONHELP:
01016 case HELP_FINDER:
01017 case HELP_QUIT:
01018 dsize=0;
01019 break;
01020
01021 case HELP_KEY:
01022 case HELP_PARTIALKEY:
01023 case HELP_COMMAND:
01024 dsize = strlen( (LPSTR)dwData )+1;
01025 break;
01026
01027 case HELP_MULTIKEY:
01028 dsize = ((LPMULTIKEYHELP)dwData)->mkSize;
01029 break;
01030
01031 case HELP_SETWINPOS:
01032 dsize = ((LPHELPWININFO)dwData)->wStructSize;
01033 break;
01034
01035 default:
01036
01037 return FALSE;
01038 }
01039 if(lpszHelp)
01040 nlen = strlen(lpszHelp)+1;
01041 else
01042 nlen = 0;
01043 size = sizeof(WINHELP) + nlen + dsize;
01044
01045
01046 lpwh = (WINHELP*)_smalloc(size);
01047 lpwh->size = size;
01048 lpwh->command = uCommand;
01049 lpwh->data = dwData;
01050 if(nlen)
01051 {
01052 strcpy(((char*)lpwh) + sizeof(WINHELP),lpszHelp);
01053 lpwh->ofsFilename = sizeof(WINHELP);
01054 } else
01055 lpwh->ofsFilename = 0;
01056 if(dsize)
01057 {
01058 memcpy(((char*)lpwh)+sizeof(WINHELP)+nlen,(LPSTR)dwData,dsize);
01059 lpwh->ofsData = sizeof(WINHELP)+nlen;
01060 } else
01061 lpwh->ofsData = 0;
01062
01063 ret = SendMessageA(hDest,WM_WINHELP,hwnd,(LPARAM)lpwh);
01064 free(lpwh);
01065 return ret;
01066 }
01067
01068
01069 BOOL WIN32API WinHelpW( HWND hwnd, LPCWSTR lpszHelp, UINT uCommand, DWORD dwData)
01070 {
01071 char *astring = UnicodeToAsciiString((LPWSTR)lpszHelp);
01072 BOOL rc;
01073
01074 dprintf(("USER32: WinHelpW\n"));
01075
01076 rc = WinHelpA(hwnd,astring,uCommand,dwData);
01077 FreeAsciiString(astring);
01078
01079 return rc;
01080 }
01081
01082
01083
01084
01085
01086
01087
01088
01089
01090
01091
01092
01093
01094
01095
01096
01097
01098
01099 BOOL WIN32API PaintDesktop(HDC hdc)
01100 {
01101 dprintf(("USER32:PaintDesktop (%08x) not implemented.\n",
01102 hdc));
01103
01104 return (FALSE);
01105 }
01106
01107
01108
01109
01110 #define COLOR_MAX COLOR_GRADIENTINACTIVECAPTION
01111
01112 int WIN32API FillRect(HDC hDC, const RECT * lprc, HBRUSH hbr)
01113 {
01114
01115 if(hbr == 0) {
01116 hbr = GetCurrentObject(hDC, OBJ_BRUSH);
01117 }
01118 else
01119 if (hbr <= (HBRUSH) (COLOR_MAX + 1)) {
01120 hbr = GetSysColorBrush( (INT) hbr - 1 );
01121 }
01122 dprintf(("USER32: FillRect %x (%d,%d)(%d,%d) brush %X", hDC, lprc->left, lprc->top, lprc->right, lprc->bottom, hbr));
01123 return O32_FillRect(hDC,lprc,hbr);
01124 }
01125
01126
01127 int WIN32API FrameRect( HDC hDC, const RECT * lprc, HBRUSH hbr)
01128 {
01129 dprintf(("USER32: FrameRect %x (%d,%d)(%d,%d) brush %x", hDC, lprc->top, lprc->left, lprc->bottom, lprc->right, hbr));
01130 return O32_FrameRect(hDC,lprc,hbr);
01131 }
01132
01133
01134 BOOL WIN32API InvertRect( HDC hDC, const RECT * lprc)
01135 {
01136 if(lprc) {
01137 dprintf(("USER32: InvertRect %x (%d,%d)(%d,%d)", hDC, lprc->left, lprc->top, lprc->right, lprc->bottom));
01138 }
01139 else dprintf(("USER32: InvertRect %x NULL", hDC));
01140 return O32_InvertRect(hDC,lprc);
01141 }
01142
01143
01144
01145
01146
01147
01148
01149
01150
01151
01152
01153
01154
01155
01156
01157
01158
01159
01160 HDESK WIN32API GetThreadDesktop(DWORD dwThreadId)
01161 {
01162 dprintf(("USER32:GetThreadDesktop (%u) not implemented.\n",
01163 dwThreadId));
01164
01165 return (NULL);
01166 }
01167
01168
01169
01170
01171
01172
01173
01174
01175
01176
01177
01178
01179
01180
01181
01182
01183
01184 BOOL WIN32API CloseDesktop(HDESK hDesktop)
01185 {
01186 dprintf(("USER32:CloseDesktop(%08x) not implemented.\n",
01187 hDesktop));
01188
01189 return (FALSE);
01190 }
01191
01192
01193
01194
01195
01196
01197
01198
01199
01200
01201
01202
01203
01204 BOOL WIN32API CloseWindowStation(HWINSTA hWinSta)
01205 {
01206 dprintf(("USER32:CloseWindowStation(%08x) not implemented.\n",
01207 hWinSta));
01208
01209 return (FALSE);
01210 }
01211
01212
01213
01214
01215
01216
01217
01218
01219
01220
01221
01222
01223
01224
01225
01226
01227
01228
01229
01230
01231 HDESK WIN32API CreateDesktopA(LPCTSTR lpszDesktop,
01232 LPCTSTR lpszDevice,
01233 LPDEVMODEA pDevMode,
01234 DWORD dwFlags,
01235 DWORD dwDesiredAccess,
01236 LPSECURITY_ATTRIBUTES lpsa)
01237 {
01238 dprintf(("USER32:CreateDesktopA(%s,%s,%08xh,%08xh,%08xh,%08x) not implemented.\n",
01239 lpszDesktop,
01240 lpszDevice,
01241 pDevMode,
01242 dwFlags,
01243 dwDesiredAccess,
01244 lpsa));
01245
01246 return (NULL);
01247 }
01248
01249
01250
01251
01252
01253
01254
01255
01256
01257
01258
01259
01260
01261
01262
01263
01264
01265
01266
01267
01268 HDESK WIN32API CreateDesktopW(LPCTSTR lpszDesktop,
01269 LPCTSTR lpszDevice,
01270 LPDEVMODEW pDevMode,
01271 DWORD dwFlags,
01272 DWORD dwDesiredAccess,
01273 LPSECURITY_ATTRIBUTES lpsa)
01274 {
01275 dprintf(("USER32:CreateDesktopW(%s,%s,%08xh,%08xh,%08xh,%08x) not implemented.\n",
01276 lpszDesktop,
01277 lpszDevice,
01278 pDevMode,
01279 dwFlags,
01280 dwDesiredAccess,
01281 lpsa));
01282
01283 return (NULL);
01284 }
01285
01286
01287
01288
01289
01290
01291
01292
01293
01294
01295
01296
01297
01298
01299
01300
01301
01302
01303
01304
01305 HWINSTA WIN32API CreateWindowStationA(LPTSTR lpWinSta,
01306 DWORD dwReserved,
01307 DWORD dwDesiredAccess,
01308 LPSECURITY_ATTRIBUTES lpsa)
01309 {
01310 dprintf(("USER32:CreateWindowStationA(%s,%08xh,%08xh,%08x) not implemented.\n",
01311 lpWinSta,
01312 dwReserved,
01313 dwDesiredAccess,
01314 lpsa));
01315
01316 return (NULL);
01317 }
01318
01319
01320
01321
01322
01323
01324
01325
01326
01327
01328
01329
01330
01331
01332
01333
01334
01335
01336
01337
01338 HWINSTA WIN32API CreateWindowStationW(LPWSTR lpWinSta,
01339 DWORD dwReserved,
01340 DWORD dwDesiredAccess,
01341 LPSECURITY_ATTRIBUTES lpsa)
01342 {
01343 dprintf(("USER32:CreateWindowStationW(%s,%08xh,%08xh,%08x) not implemented.\n",
01344 lpWinSta,
01345 dwReserved,
01346 dwDesiredAccess,
01347 lpsa));
01348
01349 return (NULL);
01350 }
01351
01352
01353
01354
01355
01356
01357
01358
01359
01360
01361
01362
01363
01364
01365
01366
01367
01368 BOOL WIN32API EnumDesktopWindows(HDESK hDesktop,
01369 WNDENUMPROC lpfn,
01370 LPARAM lParam)
01371 {
01372 dprintf(("USER32:EnumDesktopWindows (%08xh,%08xh,%08x) not implemented.\n",
01373 hDesktop,
01374 lpfn,
01375 lParam));
01376
01377 return (FALSE);
01378 }
01379
01380
01381
01382
01383
01384
01385
01386
01387
01388
01389
01390
01391
01392
01393
01394
01395
01396
01397 BOOL WIN32API EnumDesktopsA(HWINSTA hWinSta,
01398 DESKTOPENUMPROCA lpEnumFunc,
01399 LPARAM lParam)
01400 {
01401 dprintf(("USER32:EnumDesktopsA (%08xh,%08xh,%08x) not implemented.\n",
01402 hWinSta,
01403 lpEnumFunc,
01404 lParam));
01405
01406 return (FALSE);
01407 }
01408
01409
01410
01411
01412
01413
01414
01415
01416
01417
01418
01419
01420
01421
01422
01423
01424
01425
01426 BOOL WIN32API EnumDesktopsW(HWINSTA hWinSta,
01427 DESKTOPENUMPROCW lpEnumFunc,
01428 LPARAM lParam)
01429 {
01430 dprintf(("USER32:EnumDesktopsW (%08xh,%08xh,%08x) not implemented.\n",
01431 hWinSta,
01432 lpEnumFunc,
01433 lParam));
01434
01435 return (FALSE);
01436 }
01437
01438
01439
01440
01441
01442
01443
01444
01445
01446
01447
01448
01449
01450
01451
01452
01453 BOOL WIN32API EnumWindowStationsA(WINSTAENUMPROCA lpEnumFunc,
01454 LPARAM lParam)
01455 {
01456 dprintf(("USER32:EnumWindowStationsA (%08xh,%08x) not implemented.\n",
01457 lpEnumFunc,
01458 lParam));
01459
01460 return (FALSE);
01461 }
01462
01463
01464
01465
01466
01467
01468
01469
01470
01471
01472
01473
01474
01475
01476
01477
01478 BOOL WIN32API EnumWindowStationsW(WINSTAENUMPROCW lpEnumFunc,
01479 LPARAM lParam)
01480 {
01481 dprintf(("USER32:EnumWindowStationsW (%08xh,%08x) not implemented.\n",
01482 lpEnumFunc,
01483 lParam));
01484
01485 return (FALSE);
01486 }
01487
01488
01489
01490
01491
01492
01493
01494
01495
01496
01497
01498
01499
01500
01501
01502
01503 HWINSTA WIN32API GetProcessWindowStation(VOID)
01504 {
01505 dprintf(("USER32:GetProcessWindowStation () not implemented.\n"));
01506
01507 return (NULL);
01508 }
01509
01510
01511
01512
01513
01514
01515
01516
01517
01518
01519
01520
01521
01522
01523
01524
01525
01526
01527 BOOL WIN32API GetUserObjectInformationA(HANDLE hObj,
01528 int nIndex,
01529 PVOID pvInfo,
01530 DWORD nLength,
01531 LPDWORD lpnLengthNeeded)
01532 {
01533 dprintf(("USER32:GetUserObjectInformationA (%08xh,%08xh,%08xh,%u,%08x) not implemented.\n",
01534 hObj,
01535 nIndex,
01536 pvInfo,
01537 nLength,
01538 lpnLengthNeeded));
01539
01540 return (FALSE);
01541 }
01542
01543
01544
01545
01546
01547
01548
01549
01550
01551
01552
01553
01554
01555
01556
01557
01558
01559
01560 BOOL WIN32API GetUserObjectInformationW(HANDLE hObj,
01561 int nIndex,
01562 PVOID pvInfo,
01563 DWORD nLength,
01564 LPDWORD lpnLengthNeeded)
01565 {
01566 dprintf(("USER32:GetUserObjectInformationW (%08xh,%08xh,%08xh,%u,%08x) not implemented.\n",
01567 hObj,
01568 nIndex,
01569 pvInfo,
01570 nLength,
01571 lpnLengthNeeded));
01572
01573 return (FALSE);
01574 }
01575
01576
01577
01578
01579
01580
01581
01582
01583
01584
01585
01586
01587
01588
01589
01590
01591
01592
01593 BOOL WIN32API GetUserObjectSecurity(HANDLE hObj,
01594 PSECURITY_INFORMATION pSIRequested,
01595 PSECURITY_DESCRIPTOR pSID,
01596 DWORD nLength,
01597 LPDWORD lpnLengthNeeded)
01598 {
01599 dprintf(("USER32:GetUserObjectSecurity (%08xh,%08xh,%08xh,%u,%08x) not implemented.\n",
01600 hObj,
01601 pSIRequested,
01602 pSID,
01603 nLength,
01604 lpnLengthNeeded));
01605
01606 return (FALSE);
01607 }
01608
01609
01610
01611
01612
01613
01614
01615
01616
01617
01618
01619
01620
01621
01622
01623
01624
01625
01626
01627
01628 HDESK WIN32API OpenDesktopA(LPCTSTR lpszDesktopName,
01629 DWORD dwFlags,
01630 BOOL fInherit,
01631 DWORD dwDesiredAccess)
01632 {
01633 dprintf(("USER32:OpenDesktopA (%s,%08xh,%08xh,%08x) not implemented.\n",
01634 lpszDesktopName,
01635 dwFlags,
01636 fInherit,
01637 dwDesiredAccess));
01638
01639 return (NULL);
01640 }
01641
01642
01643
01644
01645
01646
01647
01648
01649
01650
01651
01652
01653
01654
01655
01656
01657
01658
01659
01660
01661 HDESK WIN32API OpenDesktopW(LPCTSTR lpszDesktopName,
01662 DWORD dwFlags,
01663 BOOL fInherit,
01664 DWORD dwDesiredAccess)
01665 {
01666 dprintf(("USER32:OpenDesktopW (%s,%08xh,%08xh,%08x) not implemented.\n",
01667 lpszDesktopName,
01668 dwFlags,
01669 fInherit,
01670 dwDesiredAccess));
01671
01672 return (NULL);
01673 }
01674
01675
01676
01677
01678
01679
01680
01681
01682
01683
01684
01685
01686
01687
01688
01689
01690
01691
01692 HDESK WIN32API OpenInputDesktop(DWORD dwFlags,
01693 BOOL fInherit,
01694 DWORD dwDesiredAccess)
01695 {
01696 dprintf(("USER32:OpenInputDesktop (%08xh,%08xh,%08x) not implemented.\n",
01697 dwFlags,
01698 fInherit,
01699 dwDesiredAccess));
01700
01701 return (NULL);
01702 }
01703
01704
01705
01706
01707
01708
01709
01710
01711
01712
01713
01714
01715
01716
01717
01718
01719
01720 HWINSTA WIN32API OpenWindowStationA(LPCTSTR lpszWinStaName,
01721 BOOL fInherit,
01722 DWORD dwDesiredAccess)
01723 {
01724 dprintf(("USER32:OpenWindowStatieonA (%s,%08xh,%08x) not implemented.\n",
01725 lpszWinStaName,
01726 fInherit,
01727 dwDesiredAccess));
01728
01729 return (NULL);
01730 }
01731
01732
01733
01734
01735
01736
01737
01738
01739
01740
01741
01742
01743
01744
01745
01746
01747
01748
01749
01750 HWINSTA WIN32API OpenWindowStationW(LPCTSTR lpszWinStaName,
01751 BOOL fInherit,
01752 DWORD dwDesiredAccess)
01753 {
01754 dprintf(("USER32:OpenWindowStatieonW (%s,%08xh,%08x) not implemented.\n",
01755 lpszWinStaName,
01756 fInherit,
01757 dwDesiredAccess));
01758
01759 return (NULL);
01760 }
01761
01762
01763
01764
01765
01766
01767
01768
01769
01770
01771
01772
01773
01774
01775
01776
01777
01778 BOOL WIN32API SetProcessWindowStation(HWINSTA hWinSta)
01779 {
01780 dprintf(("USER32:SetProcessWindowStation (%08x) not implemented.\n",
01781 hWinSta));
01782
01783 return (FALSE);
01784 }
01785
01786
01787
01788
01789
01790
01791
01792
01793
01794
01795
01796
01797
01798
01799
01800 BOOL WIN32API SetThreadDesktop(HDESK hDesktop)
01801 {
01802 dprintf(("USER32:SetThreadDesktop (%08x) not implemented.\n",
01803 hDesktop));
01804
01805 return (FALSE);
01806 }
01807
01808
01809
01810
01811
01812
01813
01814
01815
01816
01817
01818
01819
01820
01821
01822
01823
01824 BOOL WIN32API SetUserObjectInformationA(HANDLE hObject,
01825 int nIndex,
01826 PVOID lpvInfo,
01827 DWORD cbInfo)
01828 {
01829 dprintf(("USER32:SetUserObjectInformationA (%08xh,%u,%08xh,%08x) not implemented.\n",
01830 hObject,
01831 nIndex,
01832 lpvInfo,
01833 cbInfo));
01834
01835 return (FALSE);
01836 }
01837
01838
01839
01840
01841
01842
01843
01844
01845
01846
01847
01848
01849
01850
01851
01852
01853
01854 BOOL WIN32API SetUserObjectInformationW(HANDLE hObject,
01855 int nIndex,
01856 PVOID lpvInfo,
01857 DWORD cbInfo)
01858 {
01859 dprintf(("USER32:SetUserObjectInformationW (%08xh,%u,%08xh,%08x) not implemented.\n",
01860 hObject,
01861 nIndex,
01862 lpvInfo,
01863 cbInfo));
01864
01865 return (FALSE);
01866 }
01867
01868
01869
01870
01871
01872
01873
01874
01875
01876
01877
01878
01879
01880
01881
01882
01883 BOOL WIN32API SetUserObjectSecurity(HANDLE hObject,
01884 PSECURITY_INFORMATION psi,
01885 PSECURITY_DESCRIPTOR psd)
01886 {
01887 dprintf(("USER32:SetUserObjectSecuroty (%08xh,%08xh,%08x) not implemented.\n",
01888 hObject,
01889 psi,
01890 psd));
01891
01892 return (FALSE);
01893 }
01894
01895
01896
01897
01898
01899
01900
01901
01902
01903
01904
01905
01906
01907
01908
01909
01910 BOOL WIN32API SwitchDesktop(HDESK hDesktop)
01911 {
01912 dprintf(("USER32:SwitchDesktop (%08x) not implemented.\n",
01913 hDesktop));
01914
01915 return (FALSE);
01916 }
01917
01918
01919
01920
01921
01922
01923
01924
01925
01926
01927
01928
01929
01930
01931
01932 VOID WIN32API SetDebugErrorLevel(DWORD dwLevel)
01933 {
01934 dprintf(("USER32:SetDebugErrorLevel (%08x) not implemented.\n",
01935 dwLevel));
01936 }
01937
01938
01939
01940
01941
01942
01943
01944
01945
01946
01947
01948
01949
01950
01951 DWORD WIN32API DragObject(HWND x1,HWND x2,UINT x3,DWORD x4,HCURSOR x5)
01952 {
01953 dprintf(("USER32: DragObject(%08x,%08xh,%08xh,%08xh,%08xh) not implemented.\n",
01954 x1,
01955 x2,
01956 x3,
01957 x4,
01958 x5));
01959
01960 return (FALSE);
01961 }
01962
01963
01964
01965
01966
01967
01968
01969
01970
01971
01972
01973
01974
01975
01976 BOOL WIN32API SetShellWindow(DWORD x1)
01977 {
01978 dprintf(("USER32: SetShellWindow(%08x) not implemented.\n",
01979 x1));
01980
01981 return (FALSE);
01982 }
01983
01984
01985
01986
01987
01988
01989
01990
01991
01992
01993
01994 BOOL WIN32API PlaySoundEvent(DWORD x1)
01995 {
01996 dprintf(("USER32: PlaySoundEvent(%08x) not implemented.\n",
01997 x1));
01998
01999 return (FALSE);
02000 }
02001
02002
02003
02004
02005
02006
02007
02008
02009
02010
02011
02012 BOOL WIN32API SetSysColorsTemp(void)
02013 {
02014 dprintf(("USER32: SetSysColorsTemp() not implemented.\n"));
02015
02016 return (FALSE);
02017 }
02018
02019
02020
02021
02022
02023
02024
02025
02026
02027
02028
02029 BOOL WIN32API RegisterNetworkCapabilities(DWORD x1,
02030 DWORD x2)
02031 {
02032 dprintf(("USER32: RegisterNetworkCapabilities(%08xh,%08xh) not implemented.\n",
02033 x1,
02034 x2));
02035
02036 return (FALSE);
02037 }
02038
02039
02040
02041
02042
02043
02044
02045
02046
02047
02048
02049 BOOL WIN32API EndTask(DWORD x1,
02050 DWORD x2,
02051 DWORD x3)
02052 {
02053 dprintf(("USER32: EndTask(%08xh,%08xh,%08xh) not implemented.\n",
02054 x1,
02055 x2,
02056 x3));
02057
02058 return (FALSE);
02059 }
02060
02061
02062
02063
02064
02065
02066
02067
02068
02069
02070
02071 BOOL WIN32API GetNextQueueWindow(DWORD x1,
02072 DWORD x2)
02073 {
02074 dprintf(("USER32: GetNextQueueWindow(%08xh,%08xh) not implemented.\n",
02075 x1,
02076 x2));
02077
02078 return (FALSE);
02079 }
02080
02081
02082
02083
02084
02085
02086
02087
02088
02089
02090
02091 BOOL WIN32API YieldTask(void)
02092 {
02093 dprintf(("USER32: YieldTask() not implemented.\n"));
02094
02095 return (FALSE);
02096 }
02097
02098
02099
02100
02101
02102
02103
02104
02105
02106
02107
02108 BOOL WIN32API WinOldAppHackoMatic(DWORD x1)
02109 {
02110 dprintf(("USER32: WinOldAppHackoMatic(%08x) not implemented.\n",
02111 x1));
02112
02113 return (FALSE);
02114 }
02115
02116
02117
02118
02119
02120
02121
02122
02123
02124
02125
02126 BOOL WIN32API RegisterSystemThread(DWORD x1,
02127 DWORD x2)
02128 {
02129 dprintf(("USER32: RegisterSystemThread(%08xh,%08xh) not implemented.\n",
02130 x1,
02131 x2));
02132
02133 return (FALSE);
02134 }
02135
02136
02137
02138
02139
02140
02141
02142
02143
02144
02145
02146 BOOL WIN32API IsHungThread(DWORD x1)
02147 {
02148 dprintf(("USER32: IsHungThread(%08xh) not implemented.\n",
02149 x1));
02150
02151 return (FALSE);
02152 }
02153
02154
02155
02156
02157
02158
02159
02160
02161
02162
02163
02164 BOOL WIN32API UserSignalProc(DWORD x1,
02165 DWORD x2,
02166 DWORD x3,
02167 DWORD x4)
02168 {
02169 dprintf(("USER32: SysErrorBox(%08xh,%08xh,%08xh,%08xh) not implemented.\n",
02170 x1,
02171 x2,
02172 x3,
02173 x4));
02174
02175 return (FALSE);
02176 }
02177
02178
02179
02180
02181
02182
02183
02184
02185
02186
02187
02188 HWND WIN32API GetShellWindow(void)
02189 {
02190 dprintf(("USER32: GetShellWindow() not implemented.\n"));
02191
02192 return (0);
02193 }
02194
02195
02196
02197 DWORD WIN32API RegisterTasklist (DWORD x)
02198 {
02199 dprintf(("USER32: RegisterTasklist(%08xh) not implemented.\n",
02200 x));
02201
02202 return TRUE;
02203 }
02204
02205
02206
02207 DWORD WIN32API SetLogonNotifyWindow(HWINSTA hwinsta,HWND hwnd)
02208 {
02209 dprintf(("USER32: SetLogonNotifyWindow - empty stub!"));
02210
02211 return 1;
02212 }
02213
02214
02215 DWORD WIN32API GetGUIThreadInfo(DWORD arg1, DWORD arg2)
02216 {
02217 dprintf(("USER32: GetGUIThreadInfo %x %x - empty stub!!", arg1, arg2));
02218
02219 return 0;
02220 }