summaryrefslogtreecommitdiffstats
path: root/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library
diff options
context:
space:
mode:
authorSilenio Quarti <silenio_quarti@ca.ibm.com>2012-08-03 19:20:00 -0400
committerSilenio Quarti <silenio_quarti@ca.ibm.com>2012-08-03 19:20:00 -0400
commit88dc3a4dc3c68bb6669db018f4d6d63689ecddba (patch)
tree119485c479d9c77f1a0ae56857dc5a405c3cd896 /bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library
parent9ef4324d53b9a731c1016f0319ea780ff7e16145 (diff)
downloadeclipse.platform.swt-88dc3a4dc3c68bb6669db018f4d6d63689ecddba.tar.gz
eclipse.platform.swt-88dc3a4dc3c68bb6669db018f4d6d63689ecddba.tar.xz
eclipse.platform.swt-88dc3a4dc3c68bb6669db018f4d6d63689ecddba.zip
Bug 385939 - Omit use of deprecated GTK_TOOLTIPS_TIP_WINDOW and gtk_tooltips_new
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library')
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c52
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_custom.h9
2 files changed, 34 insertions, 27 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c
index 8098b20651..1bf69d95c6 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c
@@ -13973,7 +13973,15 @@ JNIEXPORT jintLong JNICALL OS_NATIVE(_1gtk_1tooltips_1new)
{
jintLong rc = 0;
OS_NATIVE_ENTER(env, that, _1gtk_1tooltips_1new_FUNC);
+/*
rc = (jintLong)gtk_tooltips_new();
+*/
+ {
+ OS_LOAD_FUNCTION(fp, gtk_tooltips_new)
+ if (fp) {
+ rc = (jintLong)((jintLong (CALLING_CONVENTION*)())fp)();
+ }
+ }
OS_NATIVE_EXIT(env, that, _1gtk_1tooltips_1new_FUNC);
return rc;
}
@@ -15502,6 +15510,28 @@ JNIEXPORT jintLong JNICALL OS_NATIVE(_1gtk_1widget_1get_1accessible)
}
#endif
+#ifndef NO__1gtk_1widget_1get_1allocation
+JNIEXPORT void JNICALL OS_NATIVE(_1gtk_1widget_1get_1allocation)
+ (JNIEnv *env, jclass that, jintLong arg0, jobject arg1)
+{
+ GtkAllocation _arg1, *lparg1=NULL;
+ OS_NATIVE_ENTER(env, that, _1gtk_1widget_1get_1allocation_FUNC);
+ if (arg1) if ((lparg1 = &_arg1) == NULL) goto fail;
+/*
+ gtk_widget_get_allocation((GtkWidget *)arg0, (GtkAllocation *)lparg1);
+*/
+ {
+ OS_LOAD_FUNCTION(fp, gtk_widget_get_allocation)
+ if (fp) {
+ ((void (CALLING_CONVENTION*)(GtkWidget *, GtkAllocation *))fp)((GtkWidget *)arg0, (GtkAllocation *)lparg1);
+ }
+ }
+fail:
+ if (arg1 && lparg1) setGtkAllocationFields(env, arg1, lparg1);
+ OS_NATIVE_EXIT(env, that, _1gtk_1widget_1get_1allocation_FUNC);
+}
+#endif
+
#ifndef NO__1gtk_1widget_1get_1can_1default
JNIEXPORT jboolean JNICALL OS_NATIVE(_1gtk_1widget_1get_1can_1default)
(JNIEnv *env, jclass that, jintLong arg0)
@@ -18308,28 +18338,6 @@ JNIEXPORT void JNICALL OS_NATIVE(gdk_1threads_1set_1lock_1functions)
}
#endif
-#ifndef NO_gtk_1widget_1get_1allocation
-JNIEXPORT void JNICALL OS_NATIVE(gtk_1widget_1get_1allocation)
- (JNIEnv *env, jclass that, jintLong arg0, jobject arg1)
-{
- GtkAllocation _arg1, *lparg1=NULL;
- OS_NATIVE_ENTER(env, that, gtk_1widget_1get_1allocation_FUNC);
- if (arg1) if ((lparg1 = &_arg1) == NULL) goto fail;
-/*
- gtk_widget_get_allocation(arg0, (GtkAllocation *)lparg1);
-*/
- {
- OS_LOAD_FUNCTION(fp, gtk_widget_get_allocation)
- if (fp) {
- ((void (CALLING_CONVENTION*)(jintLong, GtkAllocation *))fp)(arg0, (GtkAllocation *)lparg1);
- }
- }
-fail:
- if (arg1 && lparg1) setGtkAllocationFields(env, arg1, lparg1);
- OS_NATIVE_EXIT(env, that, gtk_1widget_1get_1allocation_FUNC);
-}
-#endif
-
#ifndef NO_localeconv_1decimal_1point
JNIEXPORT jintLong JNICALL OS_NATIVE(localeconv_1decimal_1point)
(JNIEnv *env, jclass that)
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_custom.h b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_custom.h
index 12e59d11e7..271d03c36e 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_custom.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_custom.h
@@ -152,6 +152,7 @@
#define gtk_entry_set_alignment_LIB LIB_GTK
#define gtk_entry_set_icon_from_stock_LIB LIB_GTK
#define gtk_entry_set_icon_sensitive_LIB LIB_GTK
+#define gtk_tooltips_new_LIB LIB_GTK
#define gdk_cursor_new_from_pixbuf_LIB LIB_GDK
#define gdk_display_get_default_LIB LIB_GDK
#define gdk_display_supports_cursor_color_LIB LIB_GDK
@@ -407,15 +408,13 @@
#define GTK_WIDGET_SET_X(arg0, arg1) (arg0)->allocation.x = arg1
#define GTK_ENTRY_IM_CONTEXT(arg0) (arg0)->im_context
#define GTK_TEXTVIEW_IM_CONTEXT(arg0) (arg0)->im_context
-#define GTK_TOOLTIPS_TIP_WINDOW(arg0) (arg0)->tip_window
#if GTK_CHECK_VERSION(2,12,0)
+#define GTK_TOOLTIPS_TIP_WINDOW(arg0) 0
#define GTK_TOOLTIPS_SET_ACTIVE(arg0, arg1)
-#else
-#define GTK_TOOLTIPS_SET_ACTIVE(arg0, arg1) (arg0)->active_tips_data = arg1
-#endif
-#if GTK_CHECK_VERSION(2,12,0)
#define GTK_TOOLTIPS_GET_TIP_TEXT(arg0) 0
#else
+#define GTK_TOOLTIPS_TIP_WINDOW(arg0) (arg0)->tip_window
+#define GTK_TOOLTIPS_SET_ACTIVE(arg0, arg1) (arg0)->active_tips_data = arg1
#define GTK_TOOLTIPS_GET_TIP_TEXT(arg0) (arg0)->tip_text
#endif
#if GTK_CHECK_VERSION(2,18,0)