The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: cozofdeath on November 19, 2011, 07:51:00 PM

Title: New Libraries?
Post by: cozofdeath on November 19, 2011, 07:51:00 PM
Although I have the newest version of masm (I think) I don't seem to have updated libraries for at least user32. I was trying to access SetClassLongPtr (SetClassLongPtrA) and it winasm/masm only seems to recognize the older SetClassLongPtr. Is there newer .libs out there that will help or do I need to somehow compile these my self? Thanks again for any help guys :U
Title: Re: New Libraries?
Post by: jj2007 on November 19, 2011, 08:03:08 PM
MSDN: "When compiling for 32-bit Windows, SetClassLongPtr is defined as a call to the SetClassLong function"

The only difference is the last arg, which is LONG for the old and LONG_PTR for the new version - and they are both DWORDs in 32-bit windows.
Title: Re: New Libraries?
Post by: dedndave on November 19, 2011, 08:08:47 PM
i see that GCLP_ HBRBACKGROUND is also not defined - oops   :P
IFNDEF GCLP_ HBRBACKGROUND
GCLP_ HBRBACKGROUND EQU -10
ENDIF

IFNDEF SetClassLongPtrA
SetClassLongPtrA PROTO :DWORD,:DWORD,:DWORD
ENDIF

IFNDEF SetClassLongPtr
SetClassLongPtr equ <SetClassLongPtrA>
ENDIF

IFNDEF SetClassLongPtrW
SetClassLongPtrW PROTO :DWORD,:DWORD,:DWORD
ENDIF
Title: Re: New Libraries?
Post by: cozofdeath on November 19, 2011, 08:35:10 PM
OK, thanks for the quick info guys. :U