Changeset 331 for trunk/src/user32/new/window.cpp
- Timestamp:
- Jul 18, 1999, 7:12:52 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/new/window.cpp
r325 r331 1 /* $Id: window.cpp,v 1. 5 1999-07-18 10:39:52sandervl Exp $ */1 /* $Id: window.cpp,v 1.6 1999-07-18 17:12:03 sandervl Exp $ */ 2 2 /* 3 3 * Win32 window apis for OS/2 … … 19 19 #include <misc.h> 20 20 #include <win32wnd.h> 21 #include <oslibwin.h> 22 #include "user32.h" 23 #include "icon.h" 24 #include "usrcall.h" 21 25 22 26 //****************************************************************************** … … 378 382 //****************************************************************************** 379 383 //****************************************************************************** 384 BOOL WIN32API SetWindowPlacement( HWND arg1, const WINDOWPLACEMENT * arg2) 385 { 386 dprintf(("USER32: SetWindowPlacement\n")); 387 return O32_SetWindowPlacement(arg1, arg2); 388 } 389 //****************************************************************************** 390 //****************************************************************************** 380 391 BOOL WIN32API IsWindow( HWND hwnd) 381 392 { … … 418 429 return window->IsWindowVisible(); 419 430 } 431 //****************************************************************************** 432 //****************************************************************************** 433 HWND WIN32API SetFocus( HWND hwnd) 434 { 435 HWND lastFocus; 436 437 dprintf(("USER32: SetFocus\n")); 438 439 lastFocus = GetFocus(); 440 hwnd = Win32Window::Win32ToOS2Handle(hwnd); 441 return (OSLibWinSetFocus(OSLIB_HWND_DESKTOP,hwnd)) ? lastFocus:0; 442 } 443 //****************************************************************************** 444 //****************************************************************************** 445 HWND WIN32API GetFocus(void) 446 { 447 HWND hwnd; 448 // dprintf(("USER32: GetFocus\n")); 449 450 hwnd = OSLibWinQueryFocus(OSLIB_HWND_DESKTOP); 451 return Win32Window::OS2ToWin32Handle(hwnd); 452 } 453 //****************************************************************************** 454 //****************************************************************************** 420 455 /*********************************************************************** 421 456 * GetInternalWindowPos (USER32.245) … … 434 469 if (O32_GetWindowPlacement( hwnd, &wndpl )) 435 470 { 436 if (rectWnd) *rectWnd = wndpl.rcNormalPosition;437 if (ptIcon) *ptIcon = wndpl.ptMinPosition;438 return wndpl.showCmd;471 if (rectWnd) *rectWnd = wndpl.rcNormalPosition; 472 if (ptIcon) *ptIcon = wndpl.ptMinPosition; 473 return wndpl.showCmd; 439 474 } 440 475 return 0; … … 541 576 return(rc); 542 577 } 578 /******************************************************************* 579 * InternalGetWindowText (USER32.326) 580 */ 581 int WIN32API InternalGetWindowText(HWND hwnd, 582 LPWSTR lpString, 583 INT nMaxCount ) 584 { 585 dprintf(("USER32: InternalGetWindowText(%08xh,%08xh,%08xh) not properly implemented.\n", 586 hwnd, 587 lpString, 588 nMaxCount)); 589 590 return GetWindowTextW(hwnd,lpString,nMaxCount); 591 } 543 592 //****************************************************************************** 544 593 //****************************************************************************** … … 562 611 //****************************************************************************** 563 612 //****************************************************************************** 613 HWND WIN32API GetDesktopWindow(void) 614 { 615 dprintf(("USER32: GetDesktopWindow\n")); 616 return OSLIB_HWND_DESKTOP; 617 } 618 //****************************************************************************** 619 //****************************************************************************** 564 620 HWND WIN32API FindWindowA(LPCSTR arg1, LPCSTR arg2) 565 621 { … … 580 636 //****************************************************************************** 581 637 //****************************************************************************** 582 BOOL WIN32API FlashWindow( HWND arg1, BOOL arg2) 583 { 584 #ifdef DEBUG 585 WriteLog("USER32: FlashWindow\n"); 586 #endif 587 return O32_FlashWindow(arg1, arg2); 638 BOOL WIN32API FlashWindow(HWND hwnd, BOOL fFlash) 639 { 640 dprintf(("FlashWindow %x %d\n", hwnd, fFlash)); 641 return OSLibWinFlashWindow(Win32Window::Win32ToOS2Handle(hwnd), fFlash); 588 642 } 589 643 //****************************************************************************** … … 786 840 //****************************************************************************** 787 841 //****************************************************************************** 842 BOOL WIN32API EnumThreadWindows(DWORD dwThreadId, WNDENUMPROC lpfn, LPARAM lParam) 843 { 844 BOOL rc; 845 EnumWindowCallback *callback = new EnumWindowCallback(lpfn, lParam); 846 847 dprintf(("USER32: EnumThreadWindows\n")); 848 //CB: replace 849 rc = O32_EnumThreadWindows(dwThreadId, callback->GetOS2Callback(), (LPARAM)callback); 850 if(callback) 851 delete callback; 852 return(rc); 853 } 854 //****************************************************************************** 855 //****************************************************************************** 856 BOOL WIN32API GetUpdateRect( HWND hwnd, PRECT lpRect, BOOL bErase) 857 { 858 dprintf(("GetUpdateRect %x %d\n", hwnd, bErase)); 859 if (!lpRect) return FALSE; 860 861 return OSLibWinQueryUpdateRect(Win32Window::Win32ToOS2Handle(hwnd), (PVOID)&lpRect); 862 } 863 //****************************************************************************** 864 //****************************************************************************** 865 BOOL WIN32API EnableScrollBar( HWND arg1, INT arg2, UINT arg3) 866 { 867 #ifdef DEBUG 868 WriteLog("USER32: EnableScrollBar\n"); 869 #endif 870 //CB: implement in window class 871 return O32_EnableScrollBar(arg1, arg2, arg3); 872 } 873 //****************************************************************************** 874 //****************************************************************************** 875 UINT WIN32API ArrangeIconicWindows( HWND arg1) 876 { 877 #ifdef DEBUG 878 WriteLog("USER32: ArrangeIconicWindows\n"); 879 #endif 880 return O32_ArrangeIconicWindows(arg1); 881 } 882 //****************************************************************************** 883 //restores iconized window to previous size/position 884 //****************************************************************************** 885 BOOL WIN32API OpenIcon(HWND hwnd) 886 { 887 #ifdef DEBUG 888 WriteLog("USER32: OpenIcon\n"); 889 #endif 890 if(!IsIconic(hwnd)) 891 return FALSE; 892 ShowWindow(hwnd, SW_SHOWNORMAL); 893 return TRUE; 894 } 895 //****************************************************************************** 896 //****************************************************************************** 897 BOOL WIN32API ShowOwnedPopups( HWND arg1, BOOL arg2) 898 { 899 dprintf(("USER32: ShowOwnedPopups\n")); 900 return O32_ShowOwnedPopups(arg1, arg2); 901 } 902 //****************************************************************************** 903 //******************************************************************************
Note:
See TracChangeset
for help on using the changeset viewer.