thegeek
18-02-2010 00:57:56
Fails to compile due to use of deprecated constant: GWL_HINSTANCE
I refer to http://software.intel.com/en-us/article ... constants/
I refer to http://software.intel.com/en-us/article ... constants/
Replace the old constant with the new constant. Win64 uses the LLP64 (or P64) uniform data model, in which pointers and long long are 64 bits, but int and long are 32 bits. To support this data model and to provide compatibility with the existing Win32 code, new data types have been defined in Win64.
As an example using the Win32 API, the following code:
LONG iVal = GetWindowLong(hWnd, GWL_HINSTANCE);
should be changed to the following:
LONG_PTR iVal = GetWindowLongPtr(hWnd, GWLP_HINSTANCE);