From 36ef425c19b48aa111df6fd464808e4b3b1fe39c Mon Sep 17 00:00:00 2001 From: Dimitri Papadopoulos Date: Mon, 13 Oct 2003 06:02:06 +0000 Subject: [PATCH] * include/windows.h (CopyCursor): Although MSDN pretends this is a function to be imported from user32.lib, it's actually a macro. From the Delphi FAQ: Question: Where is the Windows API function CopyCursor defined in 32-Bit versions of Delphi and C++ Builder? Answer: While the call is documented in the Win32 help file, the function is simply mapped to the Windows API function CopyIcon(). Note that the 32 bit version of CopyIcon does not take a hInstance parameter. --- winsup/w32api/ChangeLog | 14 ++++++++++++++ winsup/w32api/include/winuser.h | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/winsup/w32api/ChangeLog b/winsup/w32api/ChangeLog index 0bfeb685c..d6b912509 100644 --- a/winsup/w32api/ChangeLog +++ b/winsup/w32api/ChangeLog @@ -1,3 +1,17 @@ +2003-10-13 Andre Auzi + + * include/windows.h (CopyCursor): Although MSDN pretends this is + a function to be imported from user32.lib, it's actually a macro. + From the Delphi FAQ: + Question: + Where is the Windows API function CopyCursor defined in + 32-Bit versions of Delphi and C++ Builder? + Answer: + While the call is documented in the Win32 help file, the + function is simply mapped to the Windows API function + CopyIcon(). Note that the 32 bit version of CopyIcon + does not take a hInstance parameter. + 2003-10-13 Steven Edwards * include/winnt.h (CONTAINING_RECORD): Add macro. diff --git a/winsup/w32api/include/winuser.h b/winsup/w32api/include/winuser.h index 1c1284183..abe43f3ca 100644 --- a/winsup/w32api/include/winuser.h +++ b/winsup/w32api/include/winuser.h @@ -3161,7 +3161,7 @@ BOOL WINAPI CloseWindow(HWND); BOOL WINAPI CloseWindowStation(HWINSTA); int WINAPI CopyAcceleratorTableA(HACCEL,LPACCEL,int); int WINAPI CopyAcceleratorTableW(HACCEL,LPACCEL,int); -HCURSOR WINAPI CopyCursor(HCURSOR); +#define CopyCursor(c) ((HCURSOR)CopyIcon((HICON)(c))) HICON WINAPI CopyIcon(HICON); HANDLE WINAPI CopyImage(HANDLE,UINT,int,int,UINT); BOOL WINAPI CopyRect(LPRECT,LPCRECT);