summaryrefslogtreecommitdiffstats
path: root/bundles/org.eclipse.swt/Eclipse SWT AWT/gtk/library/swt_awt.c
diff options
context:
space:
mode:
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT AWT/gtk/library/swt_awt.c')
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT AWT/gtk/library/swt_awt.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT AWT/gtk/library/swt_awt.c b/bundles/org.eclipse.swt/Eclipse SWT AWT/gtk/library/swt_awt.c
index ff5c83e9a4..eac8751e57 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT AWT/gtk/library/swt_awt.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT AWT/gtk/library/swt_awt.c
@@ -9,19 +9,20 @@
* IBM Corporation - initial API and implementation
*******************************************************************************/
+#include "swt.h"
#include "jawt_md.h"
#define SWT_AWT_NATIVE(func) Java_org_eclipse_swt_awt_SWT_1AWT_##func
#ifndef NO_getAWTHandle
-JNIEXPORT jint JNICALL SWT_AWT_NATIVE(getAWTHandle)
+JNIEXPORT SWT_PTR JNICALL SWT_AWT_NATIVE(getAWTHandle)
(JNIEnv *env, jclass that, jobject canvas)
{
JAWT awt;
JAWT_DrawingSurface* ds;
JAWT_DrawingSurfaceInfo* dsi;
JAWT_X11DrawingSurfaceInfo* dsi_x11;
- jint result = 0;
+ SWT_PTR result = 0;
jint lock;
awt.version = JAWT_VERSION_1_3;
@@ -32,7 +33,7 @@ JNIEXPORT jint JNICALL SWT_AWT_NATIVE(getAWTHandle)
if ((lock & JAWT_LOCK_ERROR) == 0) {
dsi = ds->GetDrawingSurfaceInfo(ds);
dsi_x11 = (JAWT_X11DrawingSurfaceInfo*)dsi->platformInfo;
- result = (jint)dsi_x11->drawable;
+ result = (SWT_PTR)dsi_x11->drawable;
ds->FreeDrawingSurfaceInfo(dsi);
ds->Unlock(ds);
}