Revert "[GTK] Fix compilation warnings"

This reverts commit 68415d36c3caba2410b68a953439e3436f0970fc.

Change-Id: I2b74ae979ed2b8716bc697e3091d3c2d198dc3e4
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 32070a8..c2b3e5b 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
@@ -84,6 +84,18 @@
 }
 #endif
 
+#ifndef NO_GdkEventAny_1sizeof
+JNIEXPORT jint JNICALL GDK_NATIVE(GdkEventAny_1sizeof)
+	(JNIEnv *env, jclass that)
+{
+	jint rc = 0;
+	GDK_NATIVE_ENTER(env, that, GdkEventAny_1sizeof_FUNC);
+	rc = (jint)GdkEventAny_sizeof();
+	GDK_NATIVE_EXIT(env, that, GdkEventAny_1sizeof_FUNC);
+	return rc;
+}
+#endif
+
 #ifndef NO_GdkEventButton_1sizeof
 JNIEXPORT jint JNICALL GDK_NATIVE(GdkEventButton_1sizeof)
 	(JNIEnv *env, jclass that)
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.h b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.h
index 867aac7..611c5a1 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.h
@@ -176,6 +176,7 @@
 #define NO_GdkEventWindowState
 #define NO_GdkWindowAttr
 #define NO_GdkEvent
+#define NO_GdkEventAny
 #define NO_GdkEventButton
 #define NO_GdkEventCrossing
 #define NO_GdkEventFocus
@@ -190,6 +191,8 @@
 #define NO_memmove__LLorg_eclipse_swt_internal_gtk_GtkTargetEntry_2JJ
 #define NO_memmove__Iorg_eclipse_swt_internal_gtk_GdkEvent_2I
 #define NO_memmove__Jorg_eclipse_swt_internal_gtk_GdkEvent_2J
+#define NO_memmove__Iorg_eclipse_swt_internal_gtk_GdkEventAny_2I
+#define NO_memmove__Jorg_eclipse_swt_internal_gtk_GdkEventAny_2J
 #define NO_memmove__ILorg_eclipse_swt_internal_gtk_GdkEventButton_2I
 #define NO_memmove__JLorg_eclipse_swt_internal_gtk_GdkEventButton_2J
 #define NO_memmove__Lorg_eclipse_swt_internal_gtk_GdkEventButton_2II
@@ -367,7 +370,8 @@
 #define NO_gdk_1cursor_1new_1for_1display
 #define NO_gdk_1cursor_1new_1from_1pixbuf
 #define NO_gdk_1display_1supports_1cursor_1color
-#define NO_gdk_1cursor_1new_1from_1name__JLjava_lang_String_2
+#define NO_gdk_1cursor_1new_1from_1name__I_3B
+#define NO_gdk_1cursor_1new_1from_1name__J_3B
 
 #else
 
@@ -466,10 +470,6 @@
 #define NO_gdk_1event_1get_1string
 #define NO_gdk_1event_1get_1key_1group
 #define NO_gdk_1event_1get_1crossing_1mode
-
-// GdkCursor API changes
-#define NO_gdk_1cursor_1new_1from_1name__Ljava_lang_String_2J
-
 #endif
 
 #include "os_custom.h"
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.c b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.c
index a9fab99..56d5ab9 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.c
@@ -27,6 +27,7 @@
 	"GDK_1IS_1X11_1DISPLAY",
 	"GDK_1TYPE_1PIXBUF",
 	"GDK_1TYPE_1RGBA",
+	"GdkEventAny_1sizeof",
 	"GdkEventButton_1sizeof",
 	"GdkEventCrossing_1sizeof",
 	"GdkEventFocus_1sizeof",
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.h b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.h
index b09796a..430f29c 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.h
@@ -37,6 +37,7 @@
 	GDK_1IS_1X11_1DISPLAY_FUNC,
 	GDK_1TYPE_1PIXBUF_FUNC,
 	GDK_1TYPE_1RGBA_FUNC,
+	GdkEventAny_1sizeof_FUNC,
 	GdkEventButton_1sizeof_FUNC,
 	GdkEventCrossing_1sizeof_FUNC,
 	GdkEventFocus_1sizeof_FUNC,
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/GDK.java b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/GDK.java
index f7b5284..307fb42 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/GDK.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/GDK.java
@@ -239,6 +239,7 @@
 	public static final native int GdkKeymapKey_sizeof();
 	public static final native int GdkRGBA_sizeof();
 	public static final native int GdkEvent_sizeof();
+	public static final native int GdkEventAny_sizeof();
 	public static final native int GdkEventButton_sizeof();
 	public static final native int GdkEventCrossing_sizeof();
 	public static final native int GdkEventFocus_sizeof();
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/library/webkitgtk_extension.c b/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/library/webkitgtk_extension.c
index 5db8a18..e459576 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/library/webkitgtk_extension.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/library/webkitgtk_extension.c
@@ -199,10 +199,11 @@
 	}
 
 	if (g_variant_is_of_type(value, G_VARIANT_TYPE_TUPLE)) {
-		gsize length = g_variant_n_children(value);
+		gsize length = (int) g_variant_n_children(value);
 		JSValueRef *children = g_new(JSValueRef, length);
 
-		for (gsize i = 0; i < length; i++) {
+		int i = 0;
+		for (i = 0; i < length; i++) {
 			children[i] = convert_gvariant_to_js(context, g_variant_get_child_value(value, i));
 		}
 		JSValueRef result = JSObjectMakeArray(context, length, children, NULL);
@@ -363,7 +364,7 @@
 	    	continue;
 	    }
 	    guint64 page = g_variant_get_uint64(g_variant_get_child_value(child, 0));
-	    if (page == -1UL) {
+	    if (page == -1) {
 	    	// Empty or malformed BrowserFunction, skip this one
 	    	continue;
 	    } else {
@@ -410,7 +411,7 @@
      */
     if (function_list != NULL) {
     	guint64 page_id = webkit_web_page_get_id (web_page);
-    	if (page_id != -1UL) {
+    	if (page_id != -1) {
     		g_slist_foreach(function_list, (GFunc)execute_browser_functions, GUINT_TO_POINTER(page_id));
     	} else {
     		g_warning("There was an error fetching the page ID in the object_cleared callback.\n");
@@ -433,7 +434,7 @@
 	// Check method names
 	if (g_strcmp0(method_name, "webkitgtk_extension_register_function") == 0) {
 		g_variant_get(parameters, "(t&s&s)", &page_id, &script, &url);
-		if (page_id != -1UL) {
+		if (page_id != -1) {
 			result = TRUE;
 			// Return before processing the linked list, to prevent DBus from hanging
 			g_dbus_method_invocation_return_value(invocation, g_variant_new("(b)", result));
@@ -445,7 +446,7 @@
 	}
 	if (g_strcmp0(method_name, "webkitgtk_extension_deregister_function") == 0) {
 		g_variant_get(parameters, "(t&s&s)", &page_id, &script, &url);
-		if (page_id != -1UL) {
+		if (page_id != -1) {
 			result = TRUE;
 			// Return before processing the linked list, to prevent DBus from hanging
 			g_dbus_method_invocation_return_value(invocation, g_variant_new("(b)", result));
@@ -458,7 +459,7 @@
 	g_error ("Unknown method %s\n", method_name);
 }
 
-static const GDBusInterfaceVTable interface_vtable = {.method_call = webkitgtk_extension_handle_method_call};
+static const GDBusInterfaceVTable interface_vtable = {webkitgtk_extension_handle_method_call, NULL, NULL};
 
 static void connection_closed_cb (GDBusConnection *connection, gboolean remote_peer_vanished, GError *error,
 		gpointer user_data) {