summaryrefslogtreecommitdiff
path: root/indra/llwindow/lldragdropwin32.cpp
diff options
context:
space:
mode:
authorNicky <sl.nicky.ml@googlemail.com>2016-04-22 14:55:19 +0200
committerNicky <sl.nicky.ml@googlemail.com>2016-04-22 14:55:19 +0200
commit30dcad4b95d355e07f0807360f2e5f65b0460fe3 (patch)
tree892655c2846cc7e218f9fc487aa053c5cbdc393f /indra/llwindow/lldragdropwin32.cpp
parenta116f96a2fce19fa7e5dc56316044332c13d97d5 (diff)
Windows: 1. GWL_USERDATA must be GWLP_USERDATA to be compatible with x86 and x64. (GWL_USERDATA is deprecated anyway). 3. Replace Get/SetWindowLong with Get/SetWindoeLongPtr or placing this into GWLP_USERDATA will truncate the pointer.
(transplanted from 5f50745bff03700d3862a6bb1eb5936be0fdc6cd)
Diffstat (limited to 'indra/llwindow/lldragdropwin32.cpp')
-rw-r--r--indra/llwindow/lldragdropwin32.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/indra/llwindow/lldragdropwin32.cpp b/indra/llwindow/lldragdropwin32.cpp
index d00d9ab47e..0d1a47408b 100644
--- a/indra/llwindow/lldragdropwin32.cpp
+++ b/indra/llwindow/lldragdropwin32.cpp
@@ -113,7 +113,7 @@ class LLDragDropWin32Target:
PVOID data = GlobalLock( stgmed.hGlobal );
mDropUrl = std::string( (char*)data );
// XXX MAJOR MAJOR HACK!
- LLWindowWin32 *window_imp = (LLWindowWin32 *)GetWindowLong(mAppWindowHandle, GWL_USERDATA);
+ LLWindowWin32 *window_imp = (LLWindowWin32 *)GetWindowLongPtr( mAppWindowHandle, GWLP_USERDATA );
if (NULL != window_imp)
{
LLCoordGL gl_coord( 0, 0 );
@@ -168,7 +168,7 @@ class LLDragDropWin32Target:
if ( mAllowDrop )
{
// XXX MAJOR MAJOR HACK!
- LLWindowWin32 *window_imp = (LLWindowWin32 *)GetWindowLong(mAppWindowHandle, GWL_USERDATA);
+ LLWindowWin32 *window_imp = (LLWindowWin32 *)GetWindowLongPtr( mAppWindowHandle, GWLP_USERDATA );
if (NULL != window_imp)
{
LLCoordGL gl_coord( 0, 0 );
@@ -215,7 +215,7 @@ class LLDragDropWin32Target:
HRESULT __stdcall DragLeave( void )
{
// XXX MAJOR MAJOR HACK!
- LLWindowWin32 *window_imp = (LLWindowWin32 *)GetWindowLong(mAppWindowHandle, GWL_USERDATA);
+ LLWindowWin32 *window_imp = (LLWindowWin32 *)GetWindowLongPtr( mAppWindowHandle, GWLP_USERDATA );
if (NULL != window_imp)
{
LLCoordGL gl_coord( 0, 0 );
@@ -232,7 +232,7 @@ class LLDragDropWin32Target:
if ( mAllowDrop )
{
// window impl stored in Window data (neat!)
- LLWindowWin32 *window_imp = (LLWindowWin32 *)GetWindowLong( mAppWindowHandle, GWL_USERDATA );
+ LLWindowWin32 *window_imp = (LLWindowWin32 *)GetWindowLongPtr( mAppWindowHandle, GWLP_USERDATA );
if ( NULL != window_imp )
{
POINT pt_client;