From 1405f98b6e0fc43d41c3b8f16923589eccd08495 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Mon, 20 Sep 2021 10:08:02 +0200 Subject: Adapt SetWindowLong call to 64-bit build This failed with GWL_WNDPROC being undefined in 64-bit builds. See the note at : "To write code that is compatible with both 32-bit and 64-bit versions of Windows, use SetWindowLongPtr." Change-Id: I7abcc681b4daf459eb0c0481266949c75ecf4dda Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122341 Tested-by: Jenkins Reviewed-by: Stephan Bergmann --- .../OfficeDev/DesktopEnvironment/nativelib/windows/nativeview.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/nativelib/windows/nativeview.c b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/nativelib/windows/nativeview.c index f7bef492022c..2de998c69475 100644 --- a/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/nativelib/windows/nativeview.c +++ b/odk/examples/DevelopersGuide/OfficeDev/DesktopEnvironment/nativelib/windows/nativeview.c @@ -122,7 +122,7 @@ JNIEXPORT jlong JNICALL Java_NativeView_getNativeWindow */ if (GetProp( hWnd, OLD_PROC_KEY )==0) { - hFuncPtr = SetWindowLong( hWnd, GWL_WNDPROC, (DWORD)NativeViewWndProc ); + hFuncPtr = SetWindowLongPtr( hWnd, GWLP_WNDPROC, (LONG_PTR)NativeViewWndProc ); SetProp( hWnd, OLD_PROC_KEY, (HANDLE)hFuncPtr ); } -- cgit