summaryrefslogtreecommitdiffstatsabout
diff options
context:
space:
mode:
authorAlexander Kurtakov2012-03-15 17:53:54 (EDT)
committer Silenio Quarti2012-03-19 11:18:26 (EDT)
commit7f0e92a474848114999c959f30c9cf5832b6e8f4 (patch)
treeeb146c59772c08f0d51565ae3d15a699953dabd6
parentd8c49d477cf9fc567bbfb4474cead56e9b9cfb0a (diff)
downloadeclipse.platform.swt-7f0e92a474848114999c959f30c9cf5832b6e8f4.zip
eclipse.platform.swt-7f0e92a474848114999c959f30c9cf5832b6e8f4.tar.gz
eclipse.platform.swt-7f0e92a474848114999c959f30c9cf5832b6e8f4.tar.bz2
Make gdk_gc_set_background dynamic.
Single usage, cairo alternative is implemented.
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c10
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_custom.h1
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/OS.java2
3 files changed, 11 insertions, 2 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 8482339..38d416a 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
@@ -5718,7 +5718,15 @@ JNIEXPORT void JNICALL OS_NATIVE(_1gdk_1gc_1set_1background)
GdkColor _arg1, *lparg1=NULL;
OS_NATIVE_ENTER(env, that, _1gdk_1gc_1set_1background_FUNC);
if (arg1) if ((lparg1 = getGdkColorFields(env, arg1, &_arg1)) == NULL) goto fail;
- gdk_gc_set_background((GdkGC *)arg0, (GdkColor *)lparg1);
+/*
+ gdk_gc_set_background(arg0, (GdkColor *)lparg1);
+*/
+ {
+ OS_LOAD_FUNCTION(fp, gdk_gc_set_background)
+ if (fp) {
+ ((void (CALLING_CONVENTION*)(jintLong, GdkColor *))fp)(arg0, (GdkColor *)lparg1);
+ }
+ }
fail:
OS_NATIVE_EXIT(env, that, _1gdk_1gc_1set_1background_FUNC);
}
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 2622392..45f6c4c 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
@@ -153,6 +153,7 @@
#define gdk_draw_lines_LIB LIB_GDK
#define gdk_draw_pixbuf_LIB LIB_GDK
#define gdk_draw_point_LIB LIB_GDK
+#define gdk_gc_set_background_LIB LIB_GDK
#define gdk_gc_set_clip_mask_LIB LIB_GDK
#define gdk_gc_set_clip_origin_LIB LIB_GDK
#define gdk_gc_set_dashes_LIB LIB_GDK
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/OS.java b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/OS.java
index e22eda6..647a42e 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/OS.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/OS.java
@@ -4279,7 +4279,7 @@ public static final int /*long*/ gdk_gc_new(int /*long*/ window) {
}
}
/**
- * @param gc cast=(GdkGC *)
+ * @method flags=dynamic
* @param color cast=(GdkColor *),flags=no_out
*/
public static final native void _gdk_gc_set_background(int /*long*/ gc, GdkColor color);