Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGrant Gayed2013-02-13 16:15:10 +0000
committerGrant Gayed2013-02-21 21:51:48 +0000
commit6ca3b735300fb6059e388a16f4cb841cc88ec92a (patch)
tree72c298474062f7c54889e6055cc1653618a20cd3
parent22fa45ac6dbb2092d2c5466d2ba94e8543ea83dd (diff)
downloadeclipse.platform.swt-6ca3b735300fb6059e388a16f4cb841cc88ec92a.tar.gz
eclipse.platform.swt-6ca3b735300fb6059e388a16f4cb841cc88ec92a.tar.xz
eclipse.platform.swt-6ca3b735300fb6059e388a16f4cb841cc88ec92a.zip
initial CEF work
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/Browser.java1
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT Browser/win32/org/eclipse/swt/browser/BrowserFactory.java2
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3.c613
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3.h40
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_custom.c15
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_custom.h10
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_stats.c126
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_stats.h111
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_structs.c1142
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_structs.h229
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_subprocess.c25
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/swt_cef3.rc45
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEF.java2453
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFApp.java95
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFBrowserProcessHandler.java76
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFClient.java116
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/CEF3.java159
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/CEF3Object.java50
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_app_t.java51
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_base_t.java19
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_browser_process_handler_t.java37
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_browser_settings_t.java230
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_client_t.java62
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_command_line_t.java132
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_context_menu_handler_t.java28
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_display_handler_t.java36
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_focus_handler_t.java22
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_life_span_handler_t.java41
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_load_handler_t.java50
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_main_args_t.java6
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_proxy_handler_t.java11
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_request_handler_t.java78
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_resource_bundle_handler_t.java25
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_settings_t.java143
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_string_t.java12
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_window_info_t.java31
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/XPCOMObject.java1021
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/common/org/eclipse/swt/internal/OSObject.java1016
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/make_win32.mak48
-rw-r--r--bundles/org.eclipse.swt/buildSWT.xml2
40 files changed, 7405 insertions, 1004 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/Browser.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/Browser.java
index 09889544de..d56821b001 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/Browser.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/common/org/eclipse/swt/browser/Browser.java
@@ -125,6 +125,7 @@ static Composite checkParent (Composite parent) {
}
static int checkStyle(int style) {
+ style |= SWT.EMBEDDED; // TODO
String platform = SWT.getPlatform ();
if (DefaultType == SWT.DEFAULT) {
/*
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Browser/win32/org/eclipse/swt/browser/BrowserFactory.java b/bundles/org.eclipse.swt/Eclipse SWT Browser/win32/org/eclipse/swt/browser/BrowserFactory.java
index 7f67d30eb7..288504175e 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Browser/win32/org/eclipse/swt/browser/BrowserFactory.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Browser/win32/org/eclipse/swt/browser/BrowserFactory.java
@@ -23,7 +23,7 @@ WebBrowser createWebBrowser (int style) {
return new Mozilla ();
}
if ((style & SWT.WEBKIT) != 0) {
- return new WebKit ();
+ return new CEF (); // TODO
}
return new IE ();
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3.c b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3.c
new file mode 100644
index 0000000000..8b41ce412d
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3.c
@@ -0,0 +1,613 @@
+/*******************************************************************************
+ * Copyright (c) 2000, 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+
+#include "swt.h"
+#include "cef3_structs.h"
+#include "cef3_stats.h"
+
+#ifndef CEF3_NATIVE
+#define CEF3_NATIVE(func) Java_org_eclipse_swt_internal_cef3_CEF3_##func
+#endif
+
+#ifndef NO_cef_1app_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1app_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1app_1t_1sizeof_FUNC);
+ rc = (jint)cef_app_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1app_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1browser_1host_1create_1browser
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1browser_1host_1create_1browser)
+ (JNIEnv *env, jclass that, jobject arg0, jintLong arg1, jintLong arg2, jobject arg3)
+{
+ cef_window_info_t _arg0, *lparg0=NULL;
+ cef_browser_settings_t _arg3, *lparg3=NULL;
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1browser_1host_1create_1browser_FUNC);
+ if (arg0) if ((lparg0 = getcef_window_info_tFields(env, arg0, &_arg0)) == NULL) goto fail;
+ if (arg3) if ((lparg3 = getcef_browser_settings_tFields(env, arg3, &_arg3)) == NULL) goto fail;
+ rc = (jint)cef_browser_host_create_browser((const cef_window_info_t*)lparg0, (struct _cef_client_t*)arg1, (const cef_string_t*)arg2, (const struct _cef_browser_settings_t*)lparg3);
+fail:
+ if (arg3 && lparg3) setcef_browser_settings_tFields(env, arg3, lparg3);
+ if (arg0 && lparg0) setcef_window_info_tFields(env, arg0, lparg0);
+ CEF3_NATIVE_EXIT(env, that, cef_1browser_1host_1create_1browser_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1browser_1host_1create_1browser_1sync
+JNIEXPORT jintLong JNICALL CEF3_NATIVE(cef_1browser_1host_1create_1browser_1sync)
+ (JNIEnv *env, jclass that, jobject arg0, jobject arg1, jobject arg2, jintLong arg3)
+{
+ cef_window_info_t _arg0, *lparg0=NULL;
+ cef_client_t _arg1, *lparg1=NULL;
+ cef_string_t _arg2, *lparg2=NULL;
+ jintLong rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1browser_1host_1create_1browser_1sync_FUNC);
+ if (arg0) if ((lparg0 = getcef_window_info_tFields(env, arg0, &_arg0)) == NULL) goto fail;
+ if (arg1) if ((lparg1 = getcef_client_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ if (arg2) if ((lparg2 = getcef_string_tFields(env, arg2, &_arg2)) == NULL) goto fail;
+ rc = (jintLong)cef_browser_host_create_browser_sync((const cef_window_info_t*)lparg0, (struct _cef_client_t*)lparg1, (const cef_string_t*)lparg2, (const struct _cef_browser_settings_t*)arg3);
+fail:
+ if (arg2 && lparg2) setcef_string_tFields(env, arg2, lparg2);
+ if (arg1 && lparg1) setcef_client_tFields(env, arg1, lparg1);
+ if (arg0 && lparg0) setcef_window_info_tFields(env, arg0, lparg0);
+ CEF3_NATIVE_EXIT(env, that, cef_1browser_1host_1create_1browser_1sync_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1browser_1process_1handler_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1browser_1process_1handler_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1browser_1process_1handler_1t_1sizeof_FUNC);
+ rc = (jint)cef_browser_process_handler_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1browser_1process_1handler_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1browser_1settings_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1browser_1settings_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1browser_1settings_1t_1sizeof_FUNC);
+ rc = (jint)cef_browser_settings_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1browser_1settings_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1client_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1client_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1client_1t_1sizeof_FUNC);
+ rc = (jint)cef_client_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1client_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1command_1line_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1command_1line_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1command_1line_1t_1sizeof_FUNC);
+ rc = (jint)cef_command_line_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1command_1line_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1context_1menu_1handler_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1context_1menu_1handler_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1context_1menu_1handler_1t_1sizeof_FUNC);
+ rc = (jint)cef_context_menu_handler_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1context_1menu_1handler_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1display_1handler_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1display_1handler_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1display_1handler_1t_1sizeof_FUNC);
+ rc = (jint)cef_display_handler_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1display_1handler_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1execute_1process
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1execute_1process)
+ (JNIEnv *env, jclass that, jobject arg0, jintLong arg1)
+{
+ cef_main_args_t _arg0, *lparg0=NULL;
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1execute_1process_FUNC);
+ if (arg0) if ((lparg0 = getcef_main_args_tFields(env, arg0, &_arg0)) == NULL) goto fail;
+ rc = (jint)cef_execute_process((const struct _cef_main_args_t*)lparg0, (struct _cef_app_t*)arg1);
+fail:
+ if (arg0 && lparg0) setcef_main_args_tFields(env, arg0, lparg0);
+ CEF3_NATIVE_EXIT(env, that, cef_1execute_1process_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1focus_1handler_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1focus_1handler_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1focus_1handler_1t_1sizeof_FUNC);
+ rc = (jint)cef_focus_handler_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1focus_1handler_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1initialize
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1initialize)
+ (JNIEnv *env, jclass that, jobject arg0, jobject arg1, jintLong arg2)
+{
+ cef_main_args_t _arg0, *lparg0=NULL;
+ cef_settings_t _arg1, *lparg1=NULL;
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1initialize_FUNC);
+ if (arg0) if ((lparg0 = getcef_main_args_tFields(env, arg0, &_arg0)) == NULL) goto fail;
+ if (arg1) if ((lparg1 = getcef_settings_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ rc = (jint)cef_initialize((const struct _cef_main_args_t*)lparg0, (const struct _cef_settings_t*)lparg1, (struct _cef_app_t*)arg2);
+fail:
+ if (arg1 && lparg1) setcef_settings_tFields(env, arg1, lparg1);
+ if (arg0 && lparg0) setcef_main_args_tFields(env, arg0, lparg0);
+ CEF3_NATIVE_EXIT(env, that, cef_1initialize_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1life_1span_1handler_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1life_1span_1handler_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1life_1span_1handler_1t_1sizeof_FUNC);
+ rc = (jint)cef_life_span_handler_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1life_1span_1handler_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1load_1handler_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1load_1handler_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1load_1handler_1t_1sizeof_FUNC);
+ rc = (jint)cef_load_handler_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1load_1handler_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1proxy_1handler_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1proxy_1handler_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1proxy_1handler_1t_1sizeof_FUNC);
+ rc = (jint)cef_proxy_handler_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1proxy_1handler_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1request_1handler_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1request_1handler_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1request_1handler_1t_1sizeof_FUNC);
+ rc = (jint)cef_request_handler_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1request_1handler_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1resource_1bundle_1handler_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1resource_1bundle_1handler_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1resource_1bundle_1handler_1t_1sizeof_FUNC);
+ rc = (jint)cef_resource_bundle_handler_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1resource_1bundle_1handler_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1settings_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1settings_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1settings_1t_1sizeof_FUNC);
+ rc = (jint)cef_settings_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1settings_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1string_1clear
+JNIEXPORT void JNICALL CEF3_NATIVE(cef_1string_1clear)
+ (JNIEnv *env, jclass that, jintLong arg0)
+{
+ CEF3_NATIVE_ENTER(env, that, cef_1string_1clear_FUNC);
+ cef_string_clear((cef_string_t*)arg0);
+ CEF3_NATIVE_EXIT(env, that, cef_1string_1clear_FUNC);
+}
+#endif
+
+#ifndef NO_cef_1string_1set
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1string_1set)
+ (JNIEnv *env, jclass that, jcharArray arg0, jintLong arg1, jintLong arg2, jint arg3)
+{
+ jchar *lparg0=NULL;
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1string_1set_FUNC);
+ if (arg0) if ((lparg0 = (*env)->GetCharArrayElements(env, arg0, NULL)) == NULL) goto fail;
+ rc = (jint)cef_string_set((void*)lparg0, (size_t)arg1, (cef_string_t*)arg2, arg3);
+fail:
+ if (arg0 && lparg0) (*env)->ReleaseCharArrayElements(env, arg0, lparg0, 0);
+ CEF3_NATIVE_EXIT(env, that, cef_1string_1set_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1string_1t_1sizeof
+JNIEXPORT jint JNICALL CEF3_NATIVE(cef_1string_1t_1sizeof)
+ (JNIEnv *env, jclass that)
+{
+ jint rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1string_1t_1sizeof_FUNC);
+ rc = (jint)cef_string_t_sizeof();
+ CEF3_NATIVE_EXIT(env, that, cef_1string_1t_1sizeof_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1string_1userfree_1alloc
+JNIEXPORT jintLong JNICALL CEF3_NATIVE(cef_1string_1userfree_1alloc)
+ (JNIEnv *env, jclass that)
+{
+ jintLong rc = 0;
+ CEF3_NATIVE_ENTER(env, that, cef_1string_1userfree_1alloc_FUNC);
+ rc = (jintLong)cef_string_userfree_alloc();
+ CEF3_NATIVE_EXIT(env, that, cef_1string_1userfree_1alloc_FUNC);
+ return rc;
+}
+#endif
+
+#ifndef NO_cef_1string_1userfree_1free
+JNIEXPORT void JNICALL CEF3_NATIVE(cef_1string_1userfree_1free)
+ (JNIEnv *env, jclass that, jintLong arg0)
+{
+ CEF3_NATIVE_ENTER(env, that, cef_1string_1userfree_1free_FUNC);
+ cef_string_userfree_free((cef_string_userfree_t)arg0);
+ CEF3_NATIVE_EXIT(env, that, cef_1string_1userfree_1free_FUNC);
+}
+#endif
+
+#if (!defined(NO_memmove__ILorg_eclipse_swt_internal_cef3_cef_1app_1t_2I) && !defined(JNI64)) || (!defined(NO_memmove__JLorg_eclipse_swt_internal_cef3_cef_1app_1t_2J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__ILorg_eclipse_swt_internal_cef3_cef_1app_1t_2I)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__JLorg_eclipse_swt_internal_cef3_cef_1app_1t_2J)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#endif
+{
+ cef_app_t _arg1, *lparg1=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1app_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1app_1t_2J_FUNC);
+#endif
+ if (arg1) if ((lparg1 = getcef_app_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ memmove((void *)arg0, (const void *)lparg1, (size_t)arg2);
+fail:
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1app_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1app_1t_2J_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__ILorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2I) && !defined(JNI64)) || (!defined(NO_memmove__JLorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__ILorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2I)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__JLorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2J)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#endif
+{
+ cef_browser_process_handler_t _arg1, *lparg1=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2J_FUNC);
+#endif
+ if (arg1) if ((lparg1 = getcef_browser_process_handler_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ memmove((void *)arg0, (const void *)lparg1, (size_t)arg2);
+fail:
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2J_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__ILorg_eclipse_swt_internal_cef3_cef_1client_1t_2I) && !defined(JNI64)) || (!defined(NO_memmove__JLorg_eclipse_swt_internal_cef3_cef_1client_1t_2J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__ILorg_eclipse_swt_internal_cef3_cef_1client_1t_2I)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__JLorg_eclipse_swt_internal_cef3_cef_1client_1t_2J)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#endif
+{
+ cef_client_t _arg1, *lparg1=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1client_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1client_1t_2J_FUNC);
+#endif
+ if (arg1) if ((lparg1 = getcef_client_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ memmove((void *)arg0, (const void *)lparg1, (size_t)arg2);
+fail:
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1client_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1client_1t_2J_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__ILorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2I) && !defined(JNI64)) || (!defined(NO_memmove__JLorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__ILorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2I)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__JLorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2J)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#endif
+{
+ cef_display_handler_t _arg1, *lparg1=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2J_FUNC);
+#endif
+ if (arg1) if ((lparg1 = getcef_display_handler_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ memmove((void *)arg0, (const void *)lparg1, (size_t)arg2);
+fail:
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2J_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__ILorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2I) && !defined(JNI64)) || (!defined(NO_memmove__JLorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__ILorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2I)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__JLorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2J)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#endif
+{
+ cef_focus_handler_t _arg1, *lparg1=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2J_FUNC);
+#endif
+ if (arg1) if ((lparg1 = getcef_focus_handler_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ memmove((void *)arg0, (const void *)lparg1, (size_t)arg2);
+fail:
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2J_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__ILorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2I) && !defined(JNI64)) || (!defined(NO_memmove__JLorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__ILorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2I)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__JLorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2J)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#endif
+{
+ cef_life_span_handler_t _arg1, *lparg1=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2J_FUNC);
+#endif
+ if (arg1) if ((lparg1 = getcef_life_span_handler_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ memmove((void *)arg0, (const void *)lparg1, (size_t)arg2);
+fail:
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2J_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__ILorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2I) && !defined(JNI64)) || (!defined(NO_memmove__JLorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__ILorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2I)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__JLorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2J)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#endif
+{
+ cef_load_handler_t _arg1, *lparg1=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2J_FUNC);
+#endif
+ if (arg1) if ((lparg1 = getcef_load_handler_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ memmove((void *)arg0, (const void *)lparg1, (size_t)arg2);
+fail:
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2J_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__ILorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2I) && !defined(JNI64)) || (!defined(NO_memmove__JLorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__ILorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2I)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__JLorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2J)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#endif
+{
+ cef_proxy_handler_t _arg1, *lparg1=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2J_FUNC);
+#endif
+ if (arg1) if ((lparg1 = getcef_proxy_handler_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ memmove((void *)arg0, (const void *)lparg1, (size_t)arg2);
+fail:
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2J_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__ILorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2I) && !defined(JNI64)) || (!defined(NO_memmove__JLorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__ILorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2I)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__JLorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2J)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#endif
+{
+ cef_request_handler_t _arg1, *lparg1=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2J_FUNC);
+#endif
+ if (arg1) if ((lparg1 = getcef_request_handler_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ memmove((void *)arg0, (const void *)lparg1, (size_t)arg2);
+fail:
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2J_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__ILorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2I) && !defined(JNI64)) || (!defined(NO_memmove__JLorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__ILorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2I)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__JLorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2J)(JNIEnv *env, jclass that, jintLong arg0, jobject arg1, jintLong arg2)
+#endif
+{
+ cef_resource_bundle_handler_t _arg1, *lparg1=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2J_FUNC);
+#endif
+ if (arg1) if ((lparg1 = getcef_resource_bundle_handler_tFields(env, arg1, &_arg1)) == NULL) goto fail;
+ memmove((void *)arg0, (const void *)lparg1, (size_t)arg2);
+fail:
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__ILorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2I_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__JLorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2J_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2II) && !defined(JNI64)) || (!defined(NO_memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2JJ) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2II)(JNIEnv *env, jclass that, jobject arg0, jintLong arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2JJ)(JNIEnv *env, jclass that, jobject arg0, jintLong arg1, jintLong arg2)
+#endif
+{
+ cef_command_line_t _arg0, *lparg0=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2II_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2JJ_FUNC);
+#endif
+ if (arg0) if ((lparg0 = &_arg0) == NULL) goto fail;
+ memmove((void *)lparg0, (const void *)arg1, (size_t)arg2);
+fail:
+ if (arg0 && lparg0) setcef_command_line_tFields(env, arg0, lparg0);
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2II_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2JJ_FUNC);
+#endif
+}
+#endif
+
+#if (!defined(NO_memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2II) && !defined(JNI64)) || (!defined(NO_memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2JJ) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2II)(JNIEnv *env, jclass that, jobject arg0, jintLong arg1, jintLong arg2)
+#else
+JNIEXPORT void JNICALL CEF3_NATIVE(memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2JJ)(JNIEnv *env, jclass that, jobject arg0, jintLong arg1, jintLong arg2)
+#endif
+{
+ cef_string_t _arg0, *lparg0=NULL;
+#ifndef JNI64
+ CEF3_NATIVE_ENTER(env, that, memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2II_FUNC);
+#else
+ CEF3_NATIVE_ENTER(env, that, memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2JJ_FUNC);
+#endif
+ if (arg0) if ((lparg0 = &_arg0) == NULL) goto fail;
+ memmove((void *)lparg0, (const void *)arg1, (size_t)arg2);
+fail:
+ if (arg0 && lparg0) setcef_string_tFields(env, arg0, lparg0);
+#ifndef JNI64
+ CEF3_NATIVE_EXIT(env, that, memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2II_FUNC);
+#else
+ CEF3_NATIVE_EXIT(env, that, memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2JJ_FUNC);
+#endif
+}
+#endif
+
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3.h b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3.h
new file mode 100644
index 0000000000..74ebf92378
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3.h
@@ -0,0 +1,40 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+
+#ifndef INC_cef3_H
+#define INC_cef3_H
+
+#define bool int
+//#define cef_log_severity_t int
+
+// !!!!! REMEMBER: 3 HACKS IN cef_types.h !!!!!
+
+#include <cef_export.h>
+#include <cef_types.h>
+#include <cef_app_capi.h>
+#include <cef_browser_capi.h>
+#include <cef_browser_process_handler_capi.h>
+#include <cef_client_capi.h>
+#include <cef_command_line_capi.h>
+#include <cef_context_menu_handler_capi.h>
+#include <cef_display_handler_capi.h>
+#include <cef_download_handler_capi.h>
+#include <cef_focus_handler_capi.h>
+#include <cef_jsdialog_handler_capi.h>
+#include <cef_keyboard_handler_capi.h>
+#include <cef_life_span_handler_capi.h>
+#include <cef_load_handler_capi.h>
+#include <cef_proxy_handler_capi.h>
+#include <cef_request_handler_capi.h>
+#include <cef_resource_bundle_handler_capi.h>
+
+#endif /* INC_cef3_H */
+
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_custom.c b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_custom.c
new file mode 100644
index 0000000000..3e8fa2ad6a
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_custom.c
@@ -0,0 +1,15 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+
+#include "swt.h"
+
+#include "cef3.h"
+#include "cef3_stats.h"
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_custom.h b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_custom.h
new file mode 100644
index 0000000000..f92b953748
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_custom.h
@@ -0,0 +1,10 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_stats.c b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_stats.c
new file mode 100644
index 0000000000..97b23a8148
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_stats.c
@@ -0,0 +1,126 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+
+#include "swt.h"
+#include "cef3_stats.h"
+
+#ifdef NATIVE_STATS
+
+char * CEF3_nativeFunctionNames[] = {
+ "cef_1app_1t_1sizeof",
+ "cef_1browser_1host_1create_1browser",
+ "cef_1browser_1host_1create_1browser_1sync",
+ "cef_1browser_1process_1handler_1t_1sizeof",
+ "cef_1browser_1settings_1t_1sizeof",
+ "cef_1client_1t_1sizeof",
+ "cef_1command_1line_1t_1sizeof",
+ "cef_1context_1menu_1handler_1t_1sizeof",
+ "cef_1display_1handler_1t_1sizeof",
+ "cef_1execute_1process",
+ "cef_1focus_1handler_1t_1sizeof",
+ "cef_1initialize",
+ "cef_1life_1span_1handler_1t_1sizeof",
+ "cef_1load_1handler_1t_1sizeof",
+ "cef_1proxy_1handler_1t_1sizeof",
+ "cef_1request_1handler_1t_1sizeof",
+ "cef_1resource_1bundle_1handler_1t_1sizeof",
+ "cef_1settings_1t_1sizeof",
+ "cef_1string_1clear",
+ "cef_1string_1set",
+ "cef_1string_1t_1sizeof",
+ "cef_1string_1userfree_1alloc",
+ "cef_1string_1userfree_1free",
+#ifndef JNI64
+ "memmove__ILorg_eclipse_swt_internal_cef3_cef_1app_1t_2I",
+#else
+ "memmove__JLorg_eclipse_swt_internal_cef3_cef_1app_1t_2J",
+#endif
+#ifndef JNI64
+ "memmove__ILorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2I",
+#else
+ "memmove__JLorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2J",
+#endif
+#ifndef JNI64
+ "memmove__ILorg_eclipse_swt_internal_cef3_cef_1client_1t_2I",
+#else
+ "memmove__JLorg_eclipse_swt_internal_cef3_cef_1client_1t_2J",
+#endif
+#ifndef JNI64
+ "memmove__ILorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2I",
+#else
+ "memmove__JLorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2J",
+#endif
+#ifndef JNI64
+ "memmove__ILorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2I",
+#else
+ "memmove__JLorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2J",
+#endif
+#ifndef JNI64
+ "memmove__ILorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2I",
+#else
+ "memmove__JLorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2J",
+#endif
+#ifndef JNI64
+ "memmove__ILorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2I",
+#else
+ "memmove__JLorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2J",
+#endif
+#ifndef JNI64
+ "memmove__ILorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2I",
+#else
+ "memmove__JLorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2J",
+#endif
+#ifndef JNI64
+ "memmove__ILorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2I",
+#else
+ "memmove__JLorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2J",
+#endif
+#ifndef JNI64
+ "memmove__ILorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2I",
+#else
+ "memmove__JLorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2J",
+#endif
+#ifndef JNI64
+ "memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2II",
+#else
+ "memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2JJ",
+#endif
+#ifndef JNI64
+ "memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2II",
+#else
+ "memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2JJ",
+#endif
+};
+#define NATIVE_FUNCTION_COUNT sizeof(CEF3_nativeFunctionNames) / sizeof(char*)
+int CEF3_nativeFunctionCount = NATIVE_FUNCTION_COUNT;
+int CEF3_nativeFunctionCallCount[NATIVE_FUNCTION_COUNT];
+
+#define STATS_NATIVE(func) Java_org_eclipse_swt_tools_internal_NativeStats_##func
+
+JNIEXPORT jint JNICALL STATS_NATIVE(CEF3_1GetFunctionCount)
+ (JNIEnv *env, jclass that)
+{
+ return CEF3_nativeFunctionCount;
+}
+
+JNIEXPORT jstring JNICALL STATS_NATIVE(CEF3_1GetFunctionName)
+ (JNIEnv *env, jclass that, jint index)
+{
+ return (*env)->NewStringUTF(env, CEF3_nativeFunctionNames[index]);
+}
+
+JNIEXPORT jint JNICALL STATS_NATIVE(CEF3_1GetFunctionCallCount)
+ (JNIEnv *env, jclass that, jint index)
+{
+ return CEF3_nativeFunctionCallCount[index];
+}
+
+#endif
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_stats.h b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_stats.h
new file mode 100644
index 0000000000..ce13e2febd
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_stats.h
@@ -0,0 +1,111 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+
+#ifdef NATIVE_STATS
+extern int CEF3_nativeFunctionCount;
+extern int CEF3_nativeFunctionCallCount[];
+extern char* CEF3_nativeFunctionNames[];
+#define CEF3_NATIVE_ENTER(env, that, func) CEF3_nativeFunctionCallCount[func]++;
+#define CEF3_NATIVE_EXIT(env, that, func)
+#else
+#ifndef CEF3_NATIVE_ENTER
+#define CEF3_NATIVE_ENTER(env, that, func)
+#endif
+#ifndef CEF3_NATIVE_EXIT
+#define CEF3_NATIVE_EXIT(env, that, func)
+#endif
+#endif
+
+typedef enum {
+ cef_1app_1t_1sizeof_FUNC,
+ cef_1browser_1host_1create_1browser_FUNC,
+ cef_1browser_1host_1create_1browser_1sync_FUNC,
+ cef_1browser_1process_1handler_1t_1sizeof_FUNC,
+ cef_1browser_1settings_1t_1sizeof_FUNC,
+ cef_1client_1t_1sizeof_FUNC,
+ cef_1command_1line_1t_1sizeof_FUNC,
+ cef_1context_1menu_1handler_1t_1sizeof_FUNC,
+ cef_1display_1handler_1t_1sizeof_FUNC,
+ cef_1execute_1process_FUNC,
+ cef_1focus_1handler_1t_1sizeof_FUNC,
+ cef_1initialize_FUNC,
+ cef_1life_1span_1handler_1t_1sizeof_FUNC,
+ cef_1load_1handler_1t_1sizeof_FUNC,
+ cef_1proxy_1handler_1t_1sizeof_FUNC,
+ cef_1request_1handler_1t_1sizeof_FUNC,
+ cef_1resource_1bundle_1handler_1t_1sizeof_FUNC,
+ cef_1settings_1t_1sizeof_FUNC,
+ cef_1string_1clear_FUNC,
+ cef_1string_1set_FUNC,
+ cef_1string_1t_1sizeof_FUNC,
+ cef_1string_1userfree_1alloc_FUNC,
+ cef_1string_1userfree_1free_FUNC,
+#ifndef JNI64
+ memmove__ILorg_eclipse_swt_internal_cef3_cef_1app_1t_2I_FUNC,
+#else
+ memmove__JLorg_eclipse_swt_internal_cef3_cef_1app_1t_2J_FUNC,
+#endif
+#ifndef JNI64
+ memmove__ILorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2I_FUNC,
+#else
+ memmove__JLorg_eclipse_swt_internal_cef3_cef_1browser_1process_1handler_1t_2J_FUNC,
+#endif
+#ifndef JNI64
+ memmove__ILorg_eclipse_swt_internal_cef3_cef_1client_1t_2I_FUNC,
+#else
+ memmove__JLorg_eclipse_swt_internal_cef3_cef_1client_1t_2J_FUNC,
+#endif
+#ifndef JNI64
+ memmove__ILorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2I_FUNC,
+#else
+ memmove__JLorg_eclipse_swt_internal_cef3_cef_1display_1handler_1t_2J_FUNC,
+#endif
+#ifndef JNI64
+ memmove__ILorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2I_FUNC,
+#else
+ memmove__JLorg_eclipse_swt_internal_cef3_cef_1focus_1handler_1t_2J_FUNC,
+#endif
+#ifndef JNI64
+ memmove__ILorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2I_FUNC,
+#else
+ memmove__JLorg_eclipse_swt_internal_cef3_cef_1life_1span_1handler_1t_2J_FUNC,
+#endif
+#ifndef JNI64
+ memmove__ILorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2I_FUNC,
+#else
+ memmove__JLorg_eclipse_swt_internal_cef3_cef_1load_1handler_1t_2J_FUNC,
+#endif
+#ifndef JNI64
+ memmove__ILorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2I_FUNC,
+#else
+ memmove__JLorg_eclipse_swt_internal_cef3_cef_1proxy_1handler_1t_2J_FUNC,
+#endif
+#ifndef JNI64
+ memmove__ILorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2I_FUNC,
+#else
+ memmove__JLorg_eclipse_swt_internal_cef3_cef_1request_1handler_1t_2J_FUNC,
+#endif
+#ifndef JNI64
+ memmove__ILorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2I_FUNC,
+#else
+ memmove__JLorg_eclipse_swt_internal_cef3_cef_1resource_1bundle_1handler_1t_2J_FUNC,
+#endif
+#ifndef JNI64
+ memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2II_FUNC,
+#else
+ memmove__Lorg_eclipse_swt_internal_cef3_cef_1command_1line_1t_2JJ_FUNC,
+#endif
+#ifndef JNI64
+ memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2II_FUNC,
+#else
+ memmove__Lorg_eclipse_swt_internal_cef3_cef_1string_1t_2JJ_FUNC,
+#endif
+} CEF3_FUNCS;
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_structs.c b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_structs.c
new file mode 100644
index 0000000000..df3076515c
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_structs.c
@@ -0,0 +1,1142 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+
+#include "swt.h"
+#include "cef3_structs.h"
+
+#ifndef NO_cef_app_t
+typedef struct cef_app_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID on_before_command_line_processing, on_register_custom_schemes, get_resource_bundle_handler, get_browser_process_handler, get_render_process_handler;
+} cef_app_t_FID_CACHE;
+
+cef_app_t_FID_CACHE cef_app_tFc;
+
+void cachecef_app_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_app_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_app_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_app_tFc.on_before_command_line_processing = (*env)->GetFieldID(env, cef_app_tFc.clazz, "on_before_command_line_processing", I_J);
+ cef_app_tFc.on_register_custom_schemes = (*env)->GetFieldID(env, cef_app_tFc.clazz, "on_register_custom_schemes", I_J);
+ cef_app_tFc.get_resource_bundle_handler = (*env)->GetFieldID(env, cef_app_tFc.clazz, "get_resource_bundle_handler", I_J);
+ cef_app_tFc.get_browser_process_handler = (*env)->GetFieldID(env, cef_app_tFc.clazz, "get_browser_process_handler", I_J);
+ cef_app_tFc.get_render_process_handler = (*env)->GetFieldID(env, cef_app_tFc.clazz, "get_render_process_handler", I_J);
+ cef_app_tFc.cached = 1;
+}
+
+cef_app_t *getcef_app_tFields(JNIEnv *env, jobject lpObject, cef_app_t *lpStruct)
+{
+ if (!cef_app_tFc.cached) cachecef_app_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->on_before_command_line_processing = (*env)->GetIntLongField(env, lpObject, cef_app_tFc.on_before_command_line_processing);
+ lpStruct->on_register_custom_schemes = (*env)->GetIntLongField(env, lpObject, cef_app_tFc.on_register_custom_schemes);
+ lpStruct->get_resource_bundle_handler = (*env)->GetIntLongField(env, lpObject, cef_app_tFc.get_resource_bundle_handler);
+ lpStruct->get_browser_process_handler = (*env)->GetIntLongField(env, lpObject, cef_app_tFc.get_browser_process_handler);
+ lpStruct->get_render_process_handler = (*env)->GetIntLongField(env, lpObject, cef_app_tFc.get_render_process_handler);
+ return lpStruct;
+}
+
+void setcef_app_tFields(JNIEnv *env, jobject lpObject, cef_app_t *lpStruct)
+{
+ if (!cef_app_tFc.cached) cachecef_app_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_app_tFc.on_before_command_line_processing, (jintLong)lpStruct->on_before_command_line_processing);
+ (*env)->SetIntLongField(env, lpObject, cef_app_tFc.on_register_custom_schemes, (jintLong)lpStruct->on_register_custom_schemes);
+ (*env)->SetIntLongField(env, lpObject, cef_app_tFc.get_resource_bundle_handler, (jintLong)lpStruct->get_resource_bundle_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_app_tFc.get_browser_process_handler, (jintLong)lpStruct->get_browser_process_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_app_tFc.get_render_process_handler, (jintLong)lpStruct->get_render_process_handler);
+}
+#endif
+
+#ifndef NO_cef_base_t
+typedef struct cef_base_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID size, add_ref, release, get_refct;
+} cef_base_t_FID_CACHE;
+
+cef_base_t_FID_CACHE cef_base_tFc;
+
+void cachecef_base_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_base_tFc.cached) return;
+ cef_base_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_base_tFc.size = (*env)->GetFieldID(env, cef_base_tFc.clazz, "size", I_J);
+ cef_base_tFc.add_ref = (*env)->GetFieldID(env, cef_base_tFc.clazz, "add_ref", I_J);
+ cef_base_tFc.release = (*env)->GetFieldID(env, cef_base_tFc.clazz, "release", I_J);
+ cef_base_tFc.get_refct = (*env)->GetFieldID(env, cef_base_tFc.clazz, "get_refct", I_J);
+ cef_base_tFc.cached = 1;
+}
+
+cef_base_t *getcef_base_tFields(JNIEnv *env, jobject lpObject, cef_base_t *lpStruct)
+{
+ if (!cef_base_tFc.cached) cachecef_base_tFields(env, lpObject);
+ lpStruct->size = (size_t)(*env)->GetIntLongField(env, lpObject, cef_base_tFc.size);
+ lpStruct->add_ref = (*env)->GetIntLongField(env, lpObject, cef_base_tFc.add_ref);
+ lpStruct->release = (*env)->GetIntLongField(env, lpObject, cef_base_tFc.release);
+ lpStruct->get_refct = (*env)->GetIntLongField(env, lpObject, cef_base_tFc.get_refct);
+ return lpStruct;
+}
+
+void setcef_base_tFields(JNIEnv *env, jobject lpObject, cef_base_t *lpStruct)
+{
+ if (!cef_base_tFc.cached) cachecef_base_tFields(env, lpObject);
+ (*env)->SetIntLongField(env, lpObject, cef_base_tFc.size, (jintLong)lpStruct->size);
+ (*env)->SetIntLongField(env, lpObject, cef_base_tFc.add_ref, (jintLong)lpStruct->add_ref);
+ (*env)->SetIntLongField(env, lpObject, cef_base_tFc.release, (jintLong)lpStruct->release);
+ (*env)->SetIntLongField(env, lpObject, cef_base_tFc.get_refct, (jintLong)lpStruct->get_refct);
+}
+#endif
+
+#ifndef NO_cef_browser_process_handler_t
+typedef struct cef_browser_process_handler_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID get_proxy_handler, on_context_initialized, on_before_child_process_launch, on_render_process_thread_created;
+} cef_browser_process_handler_t_FID_CACHE;
+
+cef_browser_process_handler_t_FID_CACHE cef_browser_process_handler_tFc;
+
+void cachecef_browser_process_handler_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_browser_process_handler_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_browser_process_handler_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_browser_process_handler_tFc.get_proxy_handler = (*env)->GetFieldID(env, cef_browser_process_handler_tFc.clazz, "get_proxy_handler", I_J);
+ cef_browser_process_handler_tFc.on_context_initialized = (*env)->GetFieldID(env, cef_browser_process_handler_tFc.clazz, "on_context_initialized", I_J);
+ cef_browser_process_handler_tFc.on_before_child_process_launch = (*env)->GetFieldID(env, cef_browser_process_handler_tFc.clazz, "on_before_child_process_launch", I_J);
+ cef_browser_process_handler_tFc.on_render_process_thread_created = (*env)->GetFieldID(env, cef_browser_process_handler_tFc.clazz, "on_render_process_thread_created", I_J);
+ cef_browser_process_handler_tFc.cached = 1;
+}
+
+cef_browser_process_handler_t *getcef_browser_process_handler_tFields(JNIEnv *env, jobject lpObject, cef_browser_process_handler_t *lpStruct)
+{
+ if (!cef_browser_process_handler_tFc.cached) cachecef_browser_process_handler_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->get_proxy_handler = (*env)->GetIntLongField(env, lpObject, cef_browser_process_handler_tFc.get_proxy_handler);
+ lpStruct->on_context_initialized = (*env)->GetIntLongField(env, lpObject, cef_browser_process_handler_tFc.on_context_initialized);
+ lpStruct->on_before_child_process_launch = (*env)->GetIntLongField(env, lpObject, cef_browser_process_handler_tFc.on_before_child_process_launch);
+ lpStruct->on_render_process_thread_created = (*env)->GetIntLongField(env, lpObject, cef_browser_process_handler_tFc.on_render_process_thread_created);
+ return lpStruct;
+}
+
+void setcef_browser_process_handler_tFields(JNIEnv *env, jobject lpObject, cef_browser_process_handler_t *lpStruct)
+{
+ if (!cef_browser_process_handler_tFc.cached) cachecef_browser_process_handler_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_browser_process_handler_tFc.get_proxy_handler, (jintLong)lpStruct->get_proxy_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_browser_process_handler_tFc.on_context_initialized, (jintLong)lpStruct->on_context_initialized);
+ (*env)->SetIntLongField(env, lpObject, cef_browser_process_handler_tFc.on_before_child_process_launch, (jintLong)lpStruct->on_before_child_process_launch);
+ (*env)->SetIntLongField(env, lpObject, cef_browser_process_handler_tFc.on_render_process_thread_created, (jintLong)lpStruct->on_render_process_thread_created);
+}
+#endif
+
+#ifndef NO_cef_browser_settings_t
+typedef struct cef_browser_settings_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID size, standard_font_family, fixed_font_family, serif_font_family, sans_serif_font_family, cursive_font_family, fantasy_font_family, default_font_size, default_fixed_font_size, minimum_font_size, minimum_logical_font_size, remote_fonts_disabled, default_encoding, encoding_detector_enabled, javascript_disabled, javascript_open_windows_disallowed, javascript_close_windows_disallowed, javascript_access_clipboard_disallowed, dom_paste_disabled, caret_browsing_enabled, java_disabled, plugins_disabled, universal_access_from_file_urls_allowed, file_access_from_file_urls_allowed, web_security_disabled, xss_auditor_enabled, image_load_disabled, shrink_standalone_images_to_fit, site_specific_quirks_disabled, text_area_resize_disabled, page_cache_disabled, tab_to_links_disabled, hyperlink_auditing_disabled, user_style_sheet_enabled, user_style_sheet_location, author_and_user_styles_disabled, local_storage_disabled, databases_disabled, application_cache_disabled, webgl_disabled, accelerated_compositing_disabled, accelerated_layers_disabled, accelerated_video_disabled, accelerated_2d_canvas_disabled, accelerated_painting_enabled, accelerated_filters_enabled, accelerated_plugins_disabled, developer_tools_disabled, fullscreen_enabled;
+} cef_browser_settings_t_FID_CACHE;
+
+cef_browser_settings_t_FID_CACHE cef_browser_settings_tFc;
+
+void cachecef_browser_settings_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_browser_settings_tFc.cached) return;
+ cef_browser_settings_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_browser_settings_tFc.size = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "size", I_J);
+ cef_browser_settings_tFc.standard_font_family = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "standard_font_family", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_browser_settings_tFc.fixed_font_family = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "fixed_font_family", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_browser_settings_tFc.serif_font_family = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "serif_font_family", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_browser_settings_tFc.sans_serif_font_family = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "sans_serif_font_family", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_browser_settings_tFc.cursive_font_family = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "cursive_font_family", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_browser_settings_tFc.fantasy_font_family = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "fantasy_font_family", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_browser_settings_tFc.default_font_size = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "default_font_size", "I");
+ cef_browser_settings_tFc.default_fixed_font_size = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "default_fixed_font_size", "I");
+ cef_browser_settings_tFc.minimum_font_size = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "minimum_font_size", "I");
+ cef_browser_settings_tFc.minimum_logical_font_size = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "minimum_logical_font_size", "I");
+ cef_browser_settings_tFc.remote_fonts_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "remote_fonts_disabled", "I");
+ cef_browser_settings_tFc.default_encoding = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "default_encoding", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_browser_settings_tFc.encoding_detector_enabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "encoding_detector_enabled", "I");
+ cef_browser_settings_tFc.javascript_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "javascript_disabled", "I");
+ cef_browser_settings_tFc.javascript_open_windows_disallowed = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "javascript_open_windows_disallowed", "I");
+ cef_browser_settings_tFc.javascript_close_windows_disallowed = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "javascript_close_windows_disallowed", "I");
+ cef_browser_settings_tFc.javascript_access_clipboard_disallowed = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "javascript_access_clipboard_disallowed", "I");
+ cef_browser_settings_tFc.dom_paste_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "dom_paste_disabled", "I");
+ cef_browser_settings_tFc.caret_browsing_enabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "caret_browsing_enabled", "I");
+ cef_browser_settings_tFc.java_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "java_disabled", "I");
+ cef_browser_settings_tFc.plugins_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "plugins_disabled", "I");
+ cef_browser_settings_tFc.universal_access_from_file_urls_allowed = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "universal_access_from_file_urls_allowed", "I");
+ cef_browser_settings_tFc.file_access_from_file_urls_allowed = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "file_access_from_file_urls_allowed", "I");
+ cef_browser_settings_tFc.web_security_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "web_security_disabled", "I");
+ cef_browser_settings_tFc.xss_auditor_enabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "xss_auditor_enabled", "I");
+ cef_browser_settings_tFc.image_load_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "image_load_disabled", "I");
+ cef_browser_settings_tFc.shrink_standalone_images_to_fit = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "shrink_standalone_images_to_fit", "I");
+ cef_browser_settings_tFc.site_specific_quirks_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "site_specific_quirks_disabled", "I");
+ cef_browser_settings_tFc.text_area_resize_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "text_area_resize_disabled", "I");
+ cef_browser_settings_tFc.page_cache_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "page_cache_disabled", "I");
+ cef_browser_settings_tFc.tab_to_links_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "tab_to_links_disabled", "I");
+ cef_browser_settings_tFc.hyperlink_auditing_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "hyperlink_auditing_disabled", "I");
+ cef_browser_settings_tFc.user_style_sheet_enabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "user_style_sheet_enabled", "I");
+ cef_browser_settings_tFc.user_style_sheet_location = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "user_style_sheet_location", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_browser_settings_tFc.author_and_user_styles_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "author_and_user_styles_disabled", "I");
+ cef_browser_settings_tFc.local_storage_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "local_storage_disabled", "I");
+ cef_browser_settings_tFc.databases_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "databases_disabled", "I");
+ cef_browser_settings_tFc.application_cache_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "application_cache_disabled", "I");
+ cef_browser_settings_tFc.webgl_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "webgl_disabled", "I");
+ cef_browser_settings_tFc.accelerated_compositing_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "accelerated_compositing_disabled", "I");
+ cef_browser_settings_tFc.accelerated_layers_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "accelerated_layers_disabled", "I");
+ cef_browser_settings_tFc.accelerated_video_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "accelerated_video_disabled", "I");
+ cef_browser_settings_tFc.accelerated_2d_canvas_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "accelerated_2d_canvas_disabled", "I");
+ cef_browser_settings_tFc.accelerated_painting_enabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "accelerated_painting_enabled", "I");
+ cef_browser_settings_tFc.accelerated_filters_enabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "accelerated_filters_enabled", "I");
+ cef_browser_settings_tFc.accelerated_plugins_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "accelerated_plugins_disabled", "I");
+ cef_browser_settings_tFc.developer_tools_disabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "developer_tools_disabled", "I");
+ cef_browser_settings_tFc.fullscreen_enabled = (*env)->GetFieldID(env, cef_browser_settings_tFc.clazz, "fullscreen_enabled", "I");
+ cef_browser_settings_tFc.cached = 1;
+}
+
+cef_browser_settings_t *getcef_browser_settings_tFields(JNIEnv *env, jobject lpObject, cef_browser_settings_t *lpStruct)
+{
+ if (!cef_browser_settings_tFc.cached) cachecef_browser_settings_tFields(env, lpObject);
+ lpStruct->size = (*env)->GetIntLongField(env, lpObject, cef_browser_settings_tFc.size);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.standard_font_family);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->standard_font_family);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.fixed_font_family);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->fixed_font_family);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.serif_font_family);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->serif_font_family);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.sans_serif_font_family);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->sans_serif_font_family);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.cursive_font_family);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->cursive_font_family);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.fantasy_font_family);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->fantasy_font_family);
+ }
+ lpStruct->default_font_size = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.default_font_size);
+ lpStruct->default_fixed_font_size = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.default_fixed_font_size);
+ lpStruct->minimum_font_size = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.minimum_font_size);
+ lpStruct->minimum_logical_font_size = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.minimum_logical_font_size);
+ lpStruct->remote_fonts_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.remote_fonts_disabled);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.default_encoding);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->default_encoding);
+ }
+ lpStruct->encoding_detector_enabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.encoding_detector_enabled);
+ lpStruct->javascript_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.javascript_disabled);
+ lpStruct->javascript_open_windows_disallowed = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.javascript_open_windows_disallowed);
+ lpStruct->javascript_close_windows_disallowed = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.javascript_close_windows_disallowed);
+ lpStruct->javascript_access_clipboard_disallowed = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.javascript_access_clipboard_disallowed);
+ lpStruct->dom_paste_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.dom_paste_disabled);
+ lpStruct->caret_browsing_enabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.caret_browsing_enabled);
+ lpStruct->java_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.java_disabled);
+ lpStruct->plugins_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.plugins_disabled);
+ lpStruct->universal_access_from_file_urls_allowed = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.universal_access_from_file_urls_allowed);
+ lpStruct->file_access_from_file_urls_allowed = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.file_access_from_file_urls_allowed);
+ lpStruct->web_security_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.web_security_disabled);
+ lpStruct->xss_auditor_enabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.xss_auditor_enabled);
+ lpStruct->image_load_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.image_load_disabled);
+ lpStruct->shrink_standalone_images_to_fit = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.shrink_standalone_images_to_fit);
+ lpStruct->site_specific_quirks_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.site_specific_quirks_disabled);
+ lpStruct->text_area_resize_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.text_area_resize_disabled);
+ lpStruct->page_cache_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.page_cache_disabled);
+ lpStruct->tab_to_links_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.tab_to_links_disabled);
+ lpStruct->hyperlink_auditing_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.hyperlink_auditing_disabled);
+ lpStruct->user_style_sheet_enabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.user_style_sheet_enabled);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.user_style_sheet_location);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->user_style_sheet_location);
+ }
+ lpStruct->author_and_user_styles_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.author_and_user_styles_disabled);
+ lpStruct->local_storage_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.local_storage_disabled);
+ lpStruct->databases_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.databases_disabled);
+ lpStruct->application_cache_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.application_cache_disabled);
+ lpStruct->webgl_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.webgl_disabled);
+ lpStruct->accelerated_compositing_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_compositing_disabled);
+ lpStruct->accelerated_layers_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_layers_disabled);
+ lpStruct->accelerated_video_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_video_disabled);
+ lpStruct->accelerated_2d_canvas_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_2d_canvas_disabled);
+ lpStruct->accelerated_painting_enabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_painting_enabled);
+ lpStruct->accelerated_filters_enabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_filters_enabled);
+ lpStruct->accelerated_plugins_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_plugins_disabled);
+ lpStruct->developer_tools_disabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.developer_tools_disabled);
+ lpStruct->fullscreen_enabled = (*env)->GetIntField(env, lpObject, cef_browser_settings_tFc.fullscreen_enabled);
+ return lpStruct;
+}
+
+void setcef_browser_settings_tFields(JNIEnv *env, jobject lpObject, cef_browser_settings_t *lpStruct)
+{
+ if (!cef_browser_settings_tFc.cached) cachecef_browser_settings_tFields(env, lpObject);
+ (*env)->SetIntLongField(env, lpObject, cef_browser_settings_tFc.size, (jintLong)lpStruct->size);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.standard_font_family);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->standard_font_family);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.fixed_font_family);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->fixed_font_family);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.serif_font_family);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->serif_font_family);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.sans_serif_font_family);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->sans_serif_font_family);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.cursive_font_family);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->cursive_font_family);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.fantasy_font_family);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->fantasy_font_family);
+ }
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.default_font_size, (jint)lpStruct->default_font_size);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.default_fixed_font_size, (jint)lpStruct->default_fixed_font_size);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.minimum_font_size, (jint)lpStruct->minimum_font_size);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.minimum_logical_font_size, (jint)lpStruct->minimum_logical_font_size);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.remote_fonts_disabled, (jint)lpStruct->remote_fonts_disabled);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.default_encoding);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->default_encoding);
+ }
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.encoding_detector_enabled, (jint)lpStruct->encoding_detector_enabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.javascript_disabled, (jint)lpStruct->javascript_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.javascript_open_windows_disallowed, (jint)lpStruct->javascript_open_windows_disallowed);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.javascript_close_windows_disallowed, (jint)lpStruct->javascript_close_windows_disallowed);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.javascript_access_clipboard_disallowed, (jint)lpStruct->javascript_access_clipboard_disallowed);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.dom_paste_disabled, (jint)lpStruct->dom_paste_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.caret_browsing_enabled, (jint)lpStruct->caret_browsing_enabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.java_disabled, (jint)lpStruct->java_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.plugins_disabled, (jint)lpStruct->plugins_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.universal_access_from_file_urls_allowed, (jint)lpStruct->universal_access_from_file_urls_allowed);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.file_access_from_file_urls_allowed, (jint)lpStruct->file_access_from_file_urls_allowed);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.web_security_disabled, (jint)lpStruct->web_security_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.xss_auditor_enabled, (jint)lpStruct->xss_auditor_enabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.image_load_disabled, (jint)lpStruct->image_load_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.shrink_standalone_images_to_fit, (jint)lpStruct->shrink_standalone_images_to_fit);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.site_specific_quirks_disabled, (jint)lpStruct->site_specific_quirks_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.text_area_resize_disabled, (jint)lpStruct->text_area_resize_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.page_cache_disabled, (jint)lpStruct->page_cache_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.tab_to_links_disabled, (jint)lpStruct->tab_to_links_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.hyperlink_auditing_disabled, (jint)lpStruct->hyperlink_auditing_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.user_style_sheet_enabled, (jint)lpStruct->user_style_sheet_enabled);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_browser_settings_tFc.user_style_sheet_location);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->user_style_sheet_location);
+ }
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.author_and_user_styles_disabled, (jint)lpStruct->author_and_user_styles_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.local_storage_disabled, (jint)lpStruct->local_storage_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.databases_disabled, (jint)lpStruct->databases_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.application_cache_disabled, (jint)lpStruct->application_cache_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.webgl_disabled, (jint)lpStruct->webgl_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_compositing_disabled, (jint)lpStruct->accelerated_compositing_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_layers_disabled, (jint)lpStruct->accelerated_layers_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_video_disabled, (jint)lpStruct->accelerated_video_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_2d_canvas_disabled, (jint)lpStruct->accelerated_2d_canvas_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_painting_enabled, (jint)lpStruct->accelerated_painting_enabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_filters_enabled, (jint)lpStruct->accelerated_filters_enabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.accelerated_plugins_disabled, (jint)lpStruct->accelerated_plugins_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.developer_tools_disabled, (jint)lpStruct->developer_tools_disabled);
+ (*env)->SetIntField(env, lpObject, cef_browser_settings_tFc.fullscreen_enabled, (jint)lpStruct->fullscreen_enabled);
+}
+#endif
+
+#ifndef NO_cef_client_t
+typedef struct cef_client_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID get_context_menu_handler, get_dialog_handler, get_display_handler, get_download_handler, get_focus_handler, get_geolocation_handler, get_jsdialog_handler, get_keyboard_handler, get_life_span_handler, get_load_handler, get_request_handler, on_process_message_received;
+} cef_client_t_FID_CACHE;
+
+cef_client_t_FID_CACHE cef_client_tFc;
+
+void cachecef_client_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_client_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_client_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_client_tFc.get_context_menu_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_context_menu_handler", I_J);
+ cef_client_tFc.get_dialog_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_dialog_handler", I_J);
+ cef_client_tFc.get_display_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_display_handler", I_J);
+ cef_client_tFc.get_download_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_download_handler", I_J);
+ cef_client_tFc.get_focus_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_focus_handler", I_J);
+ cef_client_tFc.get_geolocation_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_geolocation_handler", I_J);
+ cef_client_tFc.get_jsdialog_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_jsdialog_handler", I_J);
+ cef_client_tFc.get_keyboard_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_keyboard_handler", I_J);
+ cef_client_tFc.get_life_span_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_life_span_handler", I_J);
+ cef_client_tFc.get_load_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_load_handler", I_J);
+ cef_client_tFc.get_request_handler = (*env)->GetFieldID(env, cef_client_tFc.clazz, "get_request_handler", I_J);
+ cef_client_tFc.on_process_message_received = (*env)->GetFieldID(env, cef_client_tFc.clazz, "on_process_message_received", I_J);
+ cef_client_tFc.cached = 1;
+}
+
+cef_client_t *getcef_client_tFields(JNIEnv *env, jobject lpObject, cef_client_t *lpStruct)
+{
+ if (!cef_client_tFc.cached) cachecef_client_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->get_context_menu_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_context_menu_handler);
+ lpStruct->get_dialog_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_dialog_handler);
+ lpStruct->get_display_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_display_handler);
+ lpStruct->get_download_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_download_handler);
+ lpStruct->get_focus_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_focus_handler);
+ lpStruct->get_geolocation_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_geolocation_handler);
+ lpStruct->get_jsdialog_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_jsdialog_handler);
+ lpStruct->get_keyboard_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_keyboard_handler);
+ lpStruct->get_life_span_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_life_span_handler);
+ lpStruct->get_load_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_load_handler);
+ lpStruct->get_request_handler = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.get_request_handler);
+ lpStruct->on_process_message_received = (*env)->GetIntLongField(env, lpObject, cef_client_tFc.on_process_message_received);
+ return lpStruct;
+}
+
+void setcef_client_tFields(JNIEnv *env, jobject lpObject, cef_client_t *lpStruct)
+{
+ if (!cef_client_tFc.cached) cachecef_client_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_context_menu_handler, (jintLong)lpStruct->get_context_menu_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_dialog_handler, (jintLong)lpStruct->get_dialog_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_display_handler, (jintLong)lpStruct->get_display_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_download_handler, (jintLong)lpStruct->get_download_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_focus_handler, (jintLong)lpStruct->get_focus_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_geolocation_handler, (jintLong)lpStruct->get_geolocation_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_jsdialog_handler, (jintLong)lpStruct->get_jsdialog_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_keyboard_handler, (jintLong)lpStruct->get_keyboard_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_life_span_handler, (jintLong)lpStruct->get_life_span_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_load_handler, (jintLong)lpStruct->get_load_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.get_request_handler, (jintLong)lpStruct->get_request_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_client_tFc.on_process_message_received, (jintLong)lpStruct->on_process_message_received);
+}
+#endif
+
+#ifndef NO_cef_command_line_t
+typedef struct cef_command_line_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID is_valid, is_read_only, copy, init_from_argv, init_from_string, reset, get_command_line_string, get_program, set_program, has_switch, get_switch_value, get_switches, append_switch, append_switch_with_value, has_arguments, get_arguments, append_argument, prepend_wrapper;
+} cef_command_line_t_FID_CACHE;
+
+cef_command_line_t_FID_CACHE cef_command_line_tFc;
+
+void cachecef_command_line_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_command_line_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_command_line_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_command_line_tFc.is_valid = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "is_valid", I_J);
+ cef_command_line_tFc.is_read_only = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "is_read_only", I_J);
+ cef_command_line_tFc.copy = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "copy", I_J);
+ cef_command_line_tFc.init_from_argv = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "init_from_argv", I_J);
+ cef_command_line_tFc.init_from_string = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "init_from_string", I_J);
+ cef_command_line_tFc.reset = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "reset", I_J);
+ cef_command_line_tFc.get_command_line_string = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "get_command_line_string", I_J);
+ cef_command_line_tFc.get_program = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "get_program", I_J);
+ cef_command_line_tFc.set_program = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "set_program", I_J);
+ cef_command_line_tFc.has_switch = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "has_switch", I_J);
+ cef_command_line_tFc.get_switch_value = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "get_switch_value", I_J);
+ cef_command_line_tFc.get_switches = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "get_switches", I_J);
+ cef_command_line_tFc.append_switch = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "append_switch", I_J);
+ cef_command_line_tFc.append_switch_with_value = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "append_switch_with_value", I_J);
+ cef_command_line_tFc.has_arguments = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "has_arguments", I_J);
+ cef_command_line_tFc.get_arguments = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "get_arguments", I_J);
+ cef_command_line_tFc.append_argument = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "append_argument", I_J);
+ cef_command_line_tFc.prepend_wrapper = (*env)->GetFieldID(env, cef_command_line_tFc.clazz, "prepend_wrapper", I_J);
+ cef_command_line_tFc.cached = 1;
+}
+
+cef_command_line_t *getcef_command_line_tFields(JNIEnv *env, jobject lpObject, cef_command_line_t *lpStruct)
+{
+ if (!cef_command_line_tFc.cached) cachecef_command_line_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->is_valid = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.is_valid);
+ lpStruct->is_read_only = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.is_read_only);
+ lpStruct->copy = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.copy);
+ lpStruct->init_from_argv = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.init_from_argv);
+ lpStruct->init_from_string = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.init_from_string);
+ lpStruct->reset = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.reset);
+ lpStruct->get_command_line_string = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.get_command_line_string);
+ lpStruct->get_program = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.get_program);
+ lpStruct->set_program = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.set_program);
+ lpStruct->has_switch = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.has_switch);
+ lpStruct->get_switch_value = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.get_switch_value);
+ lpStruct->get_switches = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.get_switches);
+ lpStruct->append_switch = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.append_switch);
+ lpStruct->append_switch_with_value = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.append_switch_with_value);
+ lpStruct->has_arguments = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.has_arguments);
+ lpStruct->get_arguments = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.get_arguments);
+ lpStruct->append_argument = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.append_argument);
+ lpStruct->prepend_wrapper = (*env)->GetIntLongField(env, lpObject, cef_command_line_tFc.prepend_wrapper);
+ return lpStruct;
+}
+
+void setcef_command_line_tFields(JNIEnv *env, jobject lpObject, cef_command_line_t *lpStruct)
+{
+ if (!cef_command_line_tFc.cached) cachecef_command_line_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.is_valid, (jintLong)lpStruct->is_valid);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.is_read_only, (jintLong)lpStruct->is_read_only);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.copy, (jintLong)lpStruct->copy);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.init_from_argv, (jintLong)lpStruct->init_from_argv);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.init_from_string, (jintLong)lpStruct->init_from_string);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.reset, (jintLong)lpStruct->reset);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.get_command_line_string, (jintLong)lpStruct->get_command_line_string);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.get_program, (jintLong)lpStruct->get_program);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.set_program, (jintLong)lpStruct->set_program);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.has_switch, (jintLong)lpStruct->has_switch);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.get_switch_value, (jintLong)lpStruct->get_switch_value);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.get_switches, (jintLong)lpStruct->get_switches);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.append_switch, (jintLong)lpStruct->append_switch);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.append_switch_with_value, (jintLong)lpStruct->append_switch_with_value);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.has_arguments, (jintLong)lpStruct->has_arguments);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.get_arguments, (jintLong)lpStruct->get_arguments);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.append_argument, (jintLong)lpStruct->append_argument);
+ (*env)->SetIntLongField(env, lpObject, cef_command_line_tFc.prepend_wrapper, (jintLong)lpStruct->prepend_wrapper);
+}
+#endif
+
+#ifndef NO_cef_context_menu_handler_t
+typedef struct cef_context_menu_handler_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID on_before_context_menu, on_context_menu_command, on_context_menu_dismissed;
+} cef_context_menu_handler_t_FID_CACHE;
+
+cef_context_menu_handler_t_FID_CACHE cef_context_menu_handler_tFc;
+
+void cachecef_context_menu_handler_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_context_menu_handler_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_context_menu_handler_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_context_menu_handler_tFc.on_before_context_menu = (*env)->GetFieldID(env, cef_context_menu_handler_tFc.clazz, "on_before_context_menu", I_J);
+ cef_context_menu_handler_tFc.on_context_menu_command = (*env)->GetFieldID(env, cef_context_menu_handler_tFc.clazz, "on_context_menu_command", I_J);
+ cef_context_menu_handler_tFc.on_context_menu_dismissed = (*env)->GetFieldID(env, cef_context_menu_handler_tFc.clazz, "on_context_menu_dismissed", I_J);
+ cef_context_menu_handler_tFc.cached = 1;
+}
+
+cef_context_menu_handler_t *getcef_context_menu_handler_tFields(JNIEnv *env, jobject lpObject, cef_context_menu_handler_t *lpStruct)
+{
+ if (!cef_context_menu_handler_tFc.cached) cachecef_context_menu_handler_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->on_before_context_menu = (*env)->GetIntLongField(env, lpObject, cef_context_menu_handler_tFc.on_before_context_menu);
+ lpStruct->on_context_menu_command = (*env)->GetIntLongField(env, lpObject, cef_context_menu_handler_tFc.on_context_menu_command);
+ lpStruct->on_context_menu_dismissed = (*env)->GetIntLongField(env, lpObject, cef_context_menu_handler_tFc.on_context_menu_dismissed);
+ return lpStruct;
+}
+
+void setcef_context_menu_handler_tFields(JNIEnv *env, jobject lpObject, cef_context_menu_handler_t *lpStruct)
+{
+ if (!cef_context_menu_handler_tFc.cached) cachecef_context_menu_handler_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_context_menu_handler_tFc.on_before_context_menu, (jintLong)lpStruct->on_before_context_menu);
+ (*env)->SetIntLongField(env, lpObject, cef_context_menu_handler_tFc.on_context_menu_command, (jintLong)lpStruct->on_context_menu_command);
+ (*env)->SetIntLongField(env, lpObject, cef_context_menu_handler_tFc.on_context_menu_dismissed, (jintLong)lpStruct->on_context_menu_dismissed);
+}
+#endif
+
+#ifndef NO_cef_display_handler_t
+typedef struct cef_display_handler_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID on_loading_state_change, on_address_change, on_title_change, on_tooltip, on_status_message, on_console_message;
+} cef_display_handler_t_FID_CACHE;
+
+cef_display_handler_t_FID_CACHE cef_display_handler_tFc;
+
+void cachecef_display_handler_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_display_handler_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_display_handler_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_display_handler_tFc.on_loading_state_change = (*env)->GetFieldID(env, cef_display_handler_tFc.clazz, "on_loading_state_change", I_J);
+ cef_display_handler_tFc.on_address_change = (*env)->GetFieldID(env, cef_display_handler_tFc.clazz, "on_address_change", I_J);
+ cef_display_handler_tFc.on_title_change = (*env)->GetFieldID(env, cef_display_handler_tFc.clazz, "on_title_change", I_J);
+ cef_display_handler_tFc.on_tooltip = (*env)->GetFieldID(env, cef_display_handler_tFc.clazz, "on_tooltip", I_J);
+ cef_display_handler_tFc.on_status_message = (*env)->GetFieldID(env, cef_display_handler_tFc.clazz, "on_status_message", I_J);
+ cef_display_handler_tFc.on_console_message = (*env)->GetFieldID(env, cef_display_handler_tFc.clazz, "on_console_message", I_J);
+ cef_display_handler_tFc.cached = 1;
+}
+
+cef_display_handler_t *getcef_display_handler_tFields(JNIEnv *env, jobject lpObject, cef_display_handler_t *lpStruct)
+{
+ if (!cef_display_handler_tFc.cached) cachecef_display_handler_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->on_loading_state_change = (*env)->GetIntLongField(env, lpObject, cef_display_handler_tFc.on_loading_state_change);
+ lpStruct->on_address_change = (*env)->GetIntLongField(env, lpObject, cef_display_handler_tFc.on_address_change);
+ lpStruct->on_title_change = (*env)->GetIntLongField(env, lpObject, cef_display_handler_tFc.on_title_change);
+ lpStruct->on_tooltip = (*env)->GetIntLongField(env, lpObject, cef_display_handler_tFc.on_tooltip);
+ lpStruct->on_status_message = (*env)->GetIntLongField(env, lpObject, cef_display_handler_tFc.on_status_message);
+ lpStruct->on_console_message = (*env)->GetIntLongField(env, lpObject, cef_display_handler_tFc.on_console_message);
+ return lpStruct;
+}
+
+void setcef_display_handler_tFields(JNIEnv *env, jobject lpObject, cef_display_handler_t *lpStruct)
+{
+ if (!cef_display_handler_tFc.cached) cachecef_display_handler_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_display_handler_tFc.on_loading_state_change, (jintLong)lpStruct->on_loading_state_change);
+ (*env)->SetIntLongField(env, lpObject, cef_display_handler_tFc.on_address_change, (jintLong)lpStruct->on_address_change);
+ (*env)->SetIntLongField(env, lpObject, cef_display_handler_tFc.on_title_change, (jintLong)lpStruct->on_title_change);
+ (*env)->SetIntLongField(env, lpObject, cef_display_handler_tFc.on_tooltip, (jintLong)lpStruct->on_tooltip);
+ (*env)->SetIntLongField(env, lpObject, cef_display_handler_tFc.on_status_message, (jintLong)lpStruct->on_status_message);
+ (*env)->SetIntLongField(env, lpObject, cef_display_handler_tFc.on_console_message, (jintLong)lpStruct->on_console_message);
+}
+#endif
+
+#ifndef NO_cef_focus_handler_t
+typedef struct cef_focus_handler_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID on_take_focus, on_set_focus, on_got_focus;
+} cef_focus_handler_t_FID_CACHE;
+
+cef_focus_handler_t_FID_CACHE cef_focus_handler_tFc;
+
+void cachecef_focus_handler_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_focus_handler_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_focus_handler_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_focus_handler_tFc.on_take_focus = (*env)->GetFieldID(env, cef_focus_handler_tFc.clazz, "on_take_focus", I_J);
+ cef_focus_handler_tFc.on_set_focus = (*env)->GetFieldID(env, cef_focus_handler_tFc.clazz, "on_set_focus", I_J);
+ cef_focus_handler_tFc.on_got_focus = (*env)->GetFieldID(env, cef_focus_handler_tFc.clazz, "on_got_focus", I_J);
+ cef_focus_handler_tFc.cached = 1;
+}
+
+cef_focus_handler_t *getcef_focus_handler_tFields(JNIEnv *env, jobject lpObject, cef_focus_handler_t *lpStruct)
+{
+ if (!cef_focus_handler_tFc.cached) cachecef_focus_handler_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->on_take_focus = (*env)->GetIntLongField(env, lpObject, cef_focus_handler_tFc.on_take_focus);
+ lpStruct->on_set_focus = (*env)->GetIntLongField(env, lpObject, cef_focus_handler_tFc.on_set_focus);
+ lpStruct->on_got_focus = (*env)->GetIntLongField(env, lpObject, cef_focus_handler_tFc.on_got_focus);
+ return lpStruct;
+}
+
+void setcef_focus_handler_tFields(JNIEnv *env, jobject lpObject, cef_focus_handler_t *lpStruct)
+{
+ if (!cef_focus_handler_tFc.cached) cachecef_focus_handler_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_focus_handler_tFc.on_take_focus, (jintLong)lpStruct->on_take_focus);
+ (*env)->SetIntLongField(env, lpObject, cef_focus_handler_tFc.on_set_focus, (jintLong)lpStruct->on_set_focus);
+ (*env)->SetIntLongField(env, lpObject, cef_focus_handler_tFc.on_got_focus, (jintLong)lpStruct->on_got_focus);
+}
+#endif
+
+#ifndef NO_cef_life_span_handler_t
+typedef struct cef_life_span_handler_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID on_before_popup, on_after_created, run_modal, do_close, on_before_close;
+} cef_life_span_handler_t_FID_CACHE;
+
+cef_life_span_handler_t_FID_CACHE cef_life_span_handler_tFc;
+
+void cachecef_life_span_handler_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_life_span_handler_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_life_span_handler_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_life_span_handler_tFc.on_before_popup = (*env)->GetFieldID(env, cef_life_span_handler_tFc.clazz, "on_before_popup", I_J);
+ cef_life_span_handler_tFc.on_after_created = (*env)->GetFieldID(env, cef_life_span_handler_tFc.clazz, "on_after_created", I_J);
+ cef_life_span_handler_tFc.run_modal = (*env)->GetFieldID(env, cef_life_span_handler_tFc.clazz, "run_modal", I_J);
+ cef_life_span_handler_tFc.do_close = (*env)->GetFieldID(env, cef_life_span_handler_tFc.clazz, "do_close", I_J);
+ cef_life_span_handler_tFc.on_before_close = (*env)->GetFieldID(env, cef_life_span_handler_tFc.clazz, "on_before_close", I_J);
+ cef_life_span_handler_tFc.cached = 1;
+}
+
+cef_life_span_handler_t *getcef_life_span_handler_tFields(JNIEnv *env, jobject lpObject, cef_life_span_handler_t *lpStruct)
+{
+ if (!cef_life_span_handler_tFc.cached) cachecef_life_span_handler_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->on_before_popup = (*env)->GetIntLongField(env, lpObject, cef_life_span_handler_tFc.on_before_popup);
+ lpStruct->on_after_created = (*env)->GetIntLongField(env, lpObject, cef_life_span_handler_tFc.on_after_created);
+ lpStruct->run_modal = (*env)->GetIntLongField(env, lpObject, cef_life_span_handler_tFc.run_modal);
+ lpStruct->do_close = (*env)->GetIntLongField(env, lpObject, cef_life_span_handler_tFc.do_close);
+ lpStruct->on_before_close = (*env)->GetIntLongField(env, lpObject, cef_life_span_handler_tFc.on_before_close);
+ return lpStruct;
+}
+
+void setcef_life_span_handler_tFields(JNIEnv *env, jobject lpObject, cef_life_span_handler_t *lpStruct)
+{
+ if (!cef_life_span_handler_tFc.cached) cachecef_life_span_handler_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_life_span_handler_tFc.on_before_popup, (jintLong)lpStruct->on_before_popup);
+ (*env)->SetIntLongField(env, lpObject, cef_life_span_handler_tFc.on_after_created, (jintLong)lpStruct->on_after_created);
+ (*env)->SetIntLongField(env, lpObject, cef_life_span_handler_tFc.run_modal, (jintLong)lpStruct->run_modal);
+ (*env)->SetIntLongField(env, lpObject, cef_life_span_handler_tFc.do_close, (jintLong)lpStruct->do_close);
+ (*env)->SetIntLongField(env, lpObject, cef_life_span_handler_tFc.on_before_close, (jintLong)lpStruct->on_before_close);
+}
+#endif
+
+#ifndef NO_cef_load_handler_t
+typedef struct cef_load_handler_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID on_load_start, on_load_end, on_load_error, on_render_process_terminated, on_plugin_crashed;
+} cef_load_handler_t_FID_CACHE;
+
+cef_load_handler_t_FID_CACHE cef_load_handler_tFc;
+
+void cachecef_load_handler_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_load_handler_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_load_handler_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_load_handler_tFc.on_load_start = (*env)->GetFieldID(env, cef_load_handler_tFc.clazz, "on_load_start", I_J);
+ cef_load_handler_tFc.on_load_end = (*env)->GetFieldID(env, cef_load_handler_tFc.clazz, "on_load_end", I_J);
+ cef_load_handler_tFc.on_load_error = (*env)->GetFieldID(env, cef_load_handler_tFc.clazz, "on_load_error", I_J);
+ cef_load_handler_tFc.on_render_process_terminated = (*env)->GetFieldID(env, cef_load_handler_tFc.clazz, "on_render_process_terminated", I_J);
+ cef_load_handler_tFc.on_plugin_crashed = (*env)->GetFieldID(env, cef_load_handler_tFc.clazz, "on_plugin_crashed", I_J);
+ cef_load_handler_tFc.cached = 1;
+}
+
+cef_load_handler_t *getcef_load_handler_tFields(JNIEnv *env, jobject lpObject, cef_load_handler_t *lpStruct)
+{
+ if (!cef_load_handler_tFc.cached) cachecef_load_handler_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->on_load_start = (*env)->GetIntLongField(env, lpObject, cef_load_handler_tFc.on_load_start);
+ lpStruct->on_load_end = (*env)->GetIntLongField(env, lpObject, cef_load_handler_tFc.on_load_end);
+ lpStruct->on_load_error = (*env)->GetIntLongField(env, lpObject, cef_load_handler_tFc.on_load_error);
+ lpStruct->on_render_process_terminated = (*env)->GetIntLongField(env, lpObject, cef_load_handler_tFc.on_render_process_terminated);
+ lpStruct->on_plugin_crashed = (*env)->GetIntLongField(env, lpObject, cef_load_handler_tFc.on_plugin_crashed);
+ return lpStruct;
+}
+
+void setcef_load_handler_tFields(JNIEnv *env, jobject lpObject, cef_load_handler_t *lpStruct)
+{
+ if (!cef_load_handler_tFc.cached) cachecef_load_handler_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_load_handler_tFc.on_load_start, (jintLong)lpStruct->on_load_start);
+ (*env)->SetIntLongField(env, lpObject, cef_load_handler_tFc.on_load_end, (jintLong)lpStruct->on_load_end);
+ (*env)->SetIntLongField(env, lpObject, cef_load_handler_tFc.on_load_error, (jintLong)lpStruct->on_load_error);
+ (*env)->SetIntLongField(env, lpObject, cef_load_handler_tFc.on_render_process_terminated, (jintLong)lpStruct->on_render_process_terminated);
+ (*env)->SetIntLongField(env, lpObject, cef_load_handler_tFc.on_plugin_crashed, (jintLong)lpStruct->on_plugin_crashed);
+}
+#endif
+
+#ifndef NO_cef_main_args_t
+typedef struct cef_main_args_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID instance;
+} cef_main_args_t_FID_CACHE;
+
+cef_main_args_t_FID_CACHE cef_main_args_tFc;
+
+void cachecef_main_args_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_main_args_tFc.cached) return;
+ cef_main_args_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_main_args_tFc.instance = (*env)->GetFieldID(env, cef_main_args_tFc.clazz, "instance", I_J);
+ cef_main_args_tFc.cached = 1;
+}
+
+cef_main_args_t *getcef_main_args_tFields(JNIEnv *env, jobject lpObject, cef_main_args_t *lpStruct)
+{
+ if (!cef_main_args_tFc.cached) cachecef_main_args_tFields(env, lpObject);
+ lpStruct->instance = (HINSTANCE)(*env)->GetIntLongField(env, lpObject, cef_main_args_tFc.instance);
+ return lpStruct;
+}
+
+void setcef_main_args_tFields(JNIEnv *env, jobject lpObject, cef_main_args_t *lpStruct)
+{
+ if (!cef_main_args_tFc.cached) cachecef_main_args_tFields(env, lpObject);
+ (*env)->SetIntLongField(env, lpObject, cef_main_args_tFc.instance, (jintLong)lpStruct->instance);
+}
+#endif
+
+#ifndef NO_cef_proxy_handler_t
+typedef struct cef_proxy_handler_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID get_proxy_for_url;
+} cef_proxy_handler_t_FID_CACHE;
+
+cef_proxy_handler_t_FID_CACHE cef_proxy_handler_tFc;
+
+void cachecef_proxy_handler_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_proxy_handler_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_proxy_handler_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_proxy_handler_tFc.get_proxy_for_url = (*env)->GetFieldID(env, cef_proxy_handler_tFc.clazz, "get_proxy_for_url", I_J);
+ cef_proxy_handler_tFc.cached = 1;
+}
+
+cef_proxy_handler_t *getcef_proxy_handler_tFields(JNIEnv *env, jobject lpObject, cef_proxy_handler_t *lpStruct)
+{
+ if (!cef_proxy_handler_tFc.cached) cachecef_proxy_handler_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->get_proxy_for_url = (*env)->GetIntLongField(env, lpObject, cef_proxy_handler_tFc.get_proxy_for_url);
+ return lpStruct;
+}
+
+void setcef_proxy_handler_tFields(JNIEnv *env, jobject lpObject, cef_proxy_handler_t *lpStruct)
+{
+ if (!cef_proxy_handler_tFc.cached) cachecef_proxy_handler_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_proxy_handler_tFc.get_proxy_for_url, (jintLong)lpStruct->get_proxy_for_url);
+}
+#endif
+
+#ifndef NO_cef_request_handler_t
+typedef struct cef_request_handler_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID on_before_resource_load, get_resource_handler, on_resource_redirect, get_auth_credentials, on_quota_request, get_cookie_manager, on_protocol_execution, on_before_plugin_load;
+} cef_request_handler_t_FID_CACHE;
+
+cef_request_handler_t_FID_CACHE cef_request_handler_tFc;
+
+void cachecef_request_handler_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_request_handler_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_request_handler_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_request_handler_tFc.on_before_resource_load = (*env)->GetFieldID(env, cef_request_handler_tFc.clazz, "on_before_resource_load", I_J);
+ cef_request_handler_tFc.get_resource_handler = (*env)->GetFieldID(env, cef_request_handler_tFc.clazz, "get_resource_handler", I_J);
+ cef_request_handler_tFc.on_resource_redirect = (*env)->GetFieldID(env, cef_request_handler_tFc.clazz, "on_resource_redirect", I_J);
+ cef_request_handler_tFc.get_auth_credentials = (*env)->GetFieldID(env, cef_request_handler_tFc.clazz, "get_auth_credentials", I_J);
+ cef_request_handler_tFc.on_quota_request = (*env)->GetFieldID(env, cef_request_handler_tFc.clazz, "on_quota_request", I_J);
+ cef_request_handler_tFc.get_cookie_manager = (*env)->GetFieldID(env, cef_request_handler_tFc.clazz, "get_cookie_manager", I_J);
+ cef_request_handler_tFc.on_protocol_execution = (*env)->GetFieldID(env, cef_request_handler_tFc.clazz, "on_protocol_execution", I_J);
+ cef_request_handler_tFc.on_before_plugin_load = (*env)->GetFieldID(env, cef_request_handler_tFc.clazz, "on_before_plugin_load", I_J);
+ cef_request_handler_tFc.cached = 1;
+}
+
+cef_request_handler_t *getcef_request_handler_tFields(JNIEnv *env, jobject lpObject, cef_request_handler_t *lpStruct)
+{
+ if (!cef_request_handler_tFc.cached) cachecef_request_handler_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->on_before_resource_load = (*env)->GetIntLongField(env, lpObject, cef_request_handler_tFc.on_before_resource_load);
+ lpStruct->get_resource_handler = (*env)->GetIntLongField(env, lpObject, cef_request_handler_tFc.get_resource_handler);
+ lpStruct->on_resource_redirect = (*env)->GetIntLongField(env, lpObject, cef_request_handler_tFc.on_resource_redirect);
+ lpStruct->get_auth_credentials = (*env)->GetIntLongField(env, lpObject, cef_request_handler_tFc.get_auth_credentials);
+ lpStruct->on_quota_request = (*env)->GetIntLongField(env, lpObject, cef_request_handler_tFc.on_quota_request);
+ lpStruct->get_cookie_manager = (*env)->GetIntLongField(env, lpObject, cef_request_handler_tFc.get_cookie_manager);
+ lpStruct->on_protocol_execution = (*env)->GetIntLongField(env, lpObject, cef_request_handler_tFc.on_protocol_execution);
+ lpStruct->on_before_plugin_load = (*env)->GetIntLongField(env, lpObject, cef_request_handler_tFc.on_before_plugin_load);
+ return lpStruct;
+}
+
+void setcef_request_handler_tFields(JNIEnv *env, jobject lpObject, cef_request_handler_t *lpStruct)
+{
+ if (!cef_request_handler_tFc.cached) cachecef_request_handler_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_request_handler_tFc.on_before_resource_load, (jintLong)lpStruct->on_before_resource_load);
+ (*env)->SetIntLongField(env, lpObject, cef_request_handler_tFc.get_resource_handler, (jintLong)lpStruct->get_resource_handler);
+ (*env)->SetIntLongField(env, lpObject, cef_request_handler_tFc.on_resource_redirect, (jintLong)lpStruct->on_resource_redirect);
+ (*env)->SetIntLongField(env, lpObject, cef_request_handler_tFc.get_auth_credentials, (jintLong)lpStruct->get_auth_credentials);
+ (*env)->SetIntLongField(env, lpObject, cef_request_handler_tFc.on_quota_request, (jintLong)lpStruct->on_quota_request);
+ (*env)->SetIntLongField(env, lpObject, cef_request_handler_tFc.get_cookie_manager, (jintLong)lpStruct->get_cookie_manager);
+ (*env)->SetIntLongField(env, lpObject, cef_request_handler_tFc.on_protocol_execution, (jintLong)lpStruct->on_protocol_execution);
+ (*env)->SetIntLongField(env, lpObject, cef_request_handler_tFc.on_before_plugin_load, (jintLong)lpStruct->on_before_plugin_load);
+}
+#endif
+
+#ifndef NO_cef_resource_bundle_handler_t
+typedef struct cef_resource_bundle_handler_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID get_localized_string, get_data_resource;
+} cef_resource_bundle_handler_t_FID_CACHE;
+
+cef_resource_bundle_handler_t_FID_CACHE cef_resource_bundle_handler_tFc;
+
+void cachecef_resource_bundle_handler_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_resource_bundle_handler_tFc.cached) return;
+ cachecef_base_tFields(env, lpObject);
+ cef_resource_bundle_handler_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_resource_bundle_handler_tFc.get_localized_string = (*env)->GetFieldID(env, cef_resource_bundle_handler_tFc.clazz, "get_localized_string", I_J);
+ cef_resource_bundle_handler_tFc.get_data_resource = (*env)->GetFieldID(env, cef_resource_bundle_handler_tFc.clazz, "get_data_resource", I_J);
+ cef_resource_bundle_handler_tFc.cached = 1;
+}
+
+cef_resource_bundle_handler_t *getcef_resource_bundle_handler_tFields(JNIEnv *env, jobject lpObject, cef_resource_bundle_handler_t *lpStruct)
+{
+ if (!cef_resource_bundle_handler_tFc.cached) cachecef_resource_bundle_handler_tFields(env, lpObject);
+ getcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ lpStruct->get_localized_string = (*env)->GetIntLongField(env, lpObject, cef_resource_bundle_handler_tFc.get_localized_string);
+ lpStruct->get_data_resource = (*env)->GetIntLongField(env, lpObject, cef_resource_bundle_handler_tFc.get_data_resource);
+ return lpStruct;
+}
+
+void setcef_resource_bundle_handler_tFields(JNIEnv *env, jobject lpObject, cef_resource_bundle_handler_t *lpStruct)
+{
+ if (!cef_resource_bundle_handler_tFc.cached) cachecef_resource_bundle_handler_tFields(env, lpObject);
+ setcef_base_tFields(env, lpObject, (cef_base_t *)lpStruct);
+ (*env)->SetIntLongField(env, lpObject, cef_resource_bundle_handler_tFc.get_localized_string, (jintLong)lpStruct->get_localized_string);
+ (*env)->SetIntLongField(env, lpObject, cef_resource_bundle_handler_tFc.get_data_resource, (jintLong)lpStruct->get_data_resource);
+}
+#endif
+
+#ifndef NO_cef_settings_t
+typedef struct cef_settings_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID size, single_process, browser_subprocess_path, multi_threaded_message_loop, command_line_args_disabled, cache_path, user_agent, product_version, locale, log_file, log_severity, release_dcheck_enabled, javascript_flags, auto_detect_proxy_settings_enabled, resources_dir_path, locales_dir_path, pack_loading_disabled, remote_debugging_port, uncaught_exception_stack_size, context_safety_implementation;
+} cef_settings_t_FID_CACHE;
+
+cef_settings_t_FID_CACHE cef_settings_tFc;
+
+void cachecef_settings_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_settings_tFc.cached) return;
+ cef_settings_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_settings_tFc.size = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "size", I_J);
+ cef_settings_tFc.single_process = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "single_process", "I");
+ cef_settings_tFc.browser_subprocess_path = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "browser_subprocess_path", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_settings_tFc.multi_threaded_message_loop = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "multi_threaded_message_loop", "I");
+ cef_settings_tFc.command_line_args_disabled = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "command_line_args_disabled", "I");
+ cef_settings_tFc.cache_path = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "cache_path", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_settings_tFc.user_agent = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "user_agent", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_settings_tFc.product_version = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "product_version", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_settings_tFc.locale = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "locale", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_settings_tFc.log_file = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "log_file", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_settings_tFc.log_severity = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "log_severity", "I");
+ cef_settings_tFc.release_dcheck_enabled = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "release_dcheck_enabled", "I");
+ cef_settings_tFc.javascript_flags = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "javascript_flags", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_settings_tFc.auto_detect_proxy_settings_enabled = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "auto_detect_proxy_settings_enabled", "I");
+ cef_settings_tFc.resources_dir_path = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "resources_dir_path", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_settings_tFc.locales_dir_path = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "locales_dir_path", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_settings_tFc.pack_loading_disabled = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "pack_loading_disabled", "I");
+ cef_settings_tFc.remote_debugging_port = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "remote_debugging_port", "I");
+ cef_settings_tFc.uncaught_exception_stack_size = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "uncaught_exception_stack_size", "I");
+ cef_settings_tFc.context_safety_implementation = (*env)->GetFieldID(env, cef_settings_tFc.clazz, "context_safety_implementation", "I");
+ cef_settings_tFc.cached = 1;
+}
+
+cef_settings_t *getcef_settings_tFields(JNIEnv *env, jobject lpObject, cef_settings_t *lpStruct)
+{
+ if (!cef_settings_tFc.cached) cachecef_settings_tFields(env, lpObject);
+ lpStruct->size = (size_t)(*env)->GetIntLongField(env, lpObject, cef_settings_tFc.size);
+ lpStruct->single_process = (bool)(*env)->GetIntField(env, lpObject, cef_settings_tFc.single_process);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.browser_subprocess_path);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->browser_subprocess_path);
+ }
+ lpStruct->multi_threaded_message_loop = (bool)(*env)->GetIntField(env, lpObject, cef_settings_tFc.multi_threaded_message_loop);
+ lpStruct->command_line_args_disabled = (bool)(*env)->GetIntField(env, lpObject, cef_settings_tFc.command_line_args_disabled);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.cache_path);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->cache_path);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.user_agent);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->user_agent);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.product_version);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->product_version);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.locale);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->locale);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.log_file);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->log_file);
+ }
+ lpStruct->log_severity = (int)(*env)->GetIntField(env, lpObject, cef_settings_tFc.log_severity);
+ lpStruct->release_dcheck_enabled = (bool)(*env)->GetIntField(env, lpObject, cef_settings_tFc.release_dcheck_enabled);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.javascript_flags);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->javascript_flags);
+ }
+ lpStruct->auto_detect_proxy_settings_enabled = (bool)(*env)->GetIntField(env, lpObject, cef_settings_tFc.auto_detect_proxy_settings_enabled);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.resources_dir_path);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->resources_dir_path);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.locales_dir_path);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->locales_dir_path);
+ }
+ lpStruct->pack_loading_disabled = (bool)(*env)->GetIntField(env, lpObject, cef_settings_tFc.pack_loading_disabled);
+ lpStruct->remote_debugging_port = (int)(*env)->GetIntField(env, lpObject, cef_settings_tFc.remote_debugging_port);
+ lpStruct->uncaught_exception_stack_size = (*env)->GetIntField(env, lpObject, cef_settings_tFc.uncaught_exception_stack_size);
+ lpStruct->context_safety_implementation = (*env)->GetIntField(env, lpObject, cef_settings_tFc.context_safety_implementation);
+ return lpStruct;
+}
+
+void setcef_settings_tFields(JNIEnv *env, jobject lpObject, cef_settings_t *lpStruct)
+{
+ if (!cef_settings_tFc.cached) cachecef_settings_tFields(env, lpObject);
+ (*env)->SetIntLongField(env, lpObject, cef_settings_tFc.size, (jintLong)lpStruct->size);
+ (*env)->SetIntField(env, lpObject, cef_settings_tFc.single_process, (jint)lpStruct->single_process);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.browser_subprocess_path);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->browser_subprocess_path);
+ }
+ (*env)->SetIntField(env, lpObject, cef_settings_tFc.multi_threaded_message_loop, (jint)lpStruct->multi_threaded_message_loop);
+ (*env)->SetIntField(env, lpObject, cef_settings_tFc.command_line_args_disabled, (jint)lpStruct->command_line_args_disabled);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.cache_path);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->cache_path);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.user_agent);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->user_agent);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.product_version);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->product_version);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.locale);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->locale);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.log_file);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->log_file);
+ }
+ (*env)->SetIntField(env, lpObject, cef_settings_tFc.log_severity, (jint)lpStruct->log_severity);
+ (*env)->SetIntField(env, lpObject, cef_settings_tFc.release_dcheck_enabled, (jint)lpStruct->release_dcheck_enabled);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.javascript_flags);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->javascript_flags);
+ }
+ (*env)->SetIntField(env, lpObject, cef_settings_tFc.auto_detect_proxy_settings_enabled, (jint)lpStruct->auto_detect_proxy_settings_enabled);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.resources_dir_path);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->resources_dir_path);
+ }
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_settings_tFc.locales_dir_path);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->locales_dir_path);
+ }
+ (*env)->SetIntField(env, lpObject, cef_settings_tFc.pack_loading_disabled, (jint)lpStruct->pack_loading_disabled);
+ (*env)->SetIntField(env, lpObject, cef_settings_tFc.remote_debugging_port, (jint)lpStruct->remote_debugging_port);
+ (*env)->SetIntField(env, lpObject, cef_settings_tFc.uncaught_exception_stack_size, (jint)lpStruct->uncaught_exception_stack_size);
+ (*env)->SetIntField(env, lpObject, cef_settings_tFc.context_safety_implementation, (jint)lpStruct->context_safety_implementation);
+}
+#endif
+
+#ifndef NO_cef_string_t
+typedef struct cef_string_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID str, length, dtor;
+} cef_string_t_FID_CACHE;
+
+cef_string_t_FID_CACHE cef_string_tFc;
+
+void cachecef_string_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_string_tFc.cached) return;
+ cef_string_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_string_tFc.str = (*env)->GetFieldID(env, cef_string_tFc.clazz, "str", I_J);
+ cef_string_tFc.length = (*env)->GetFieldID(env, cef_string_tFc.clazz, "length", I_J);
+ cef_string_tFc.dtor = (*env)->GetFieldID(env, cef_string_tFc.clazz, "dtor", I_J);
+ cef_string_tFc.cached = 1;
+}
+
+cef_string_t *getcef_string_tFields(JNIEnv *env, jobject lpObject, cef_string_t *lpStruct)
+{
+ if (!cef_string_tFc.cached) cachecef_string_tFields(env, lpObject);
+ lpStruct->str = (void *)(*env)->GetIntLongField(env, lpObject, cef_string_tFc.str);
+ lpStruct->length = (size_t)(*env)->GetIntLongField(env, lpObject, cef_string_tFc.length);
+ lpStruct->dtor = (void (__cdecl *)(void *))(*env)->GetIntLongField(env, lpObject, cef_string_tFc.dtor);
+ return lpStruct;
+}
+
+void setcef_string_tFields(JNIEnv *env, jobject lpObject, cef_string_t *lpStruct)
+{
+ if (!cef_string_tFc.cached) cachecef_string_tFields(env, lpObject);
+ (*env)->SetIntLongField(env, lpObject, cef_string_tFc.str, (jintLong)lpStruct->str);
+ (*env)->SetIntLongField(env, lpObject, cef_string_tFc.length, (jintLong)lpStruct->length);
+ (*env)->SetIntLongField(env, lpObject, cef_string_tFc.dtor, (jintLong)lpStruct->dtor);
+}
+#endif
+
+#ifndef NO_cef_window_info_t
+typedef struct cef_window_info_t_FID_CACHE {
+ int cached;
+ jclass clazz;
+ jfieldID ex_style, window_name, style, x, y, width, height, parent_window, menu, transparent_painting, window;
+} cef_window_info_t_FID_CACHE;
+
+cef_window_info_t_FID_CACHE cef_window_info_tFc;
+
+void cachecef_window_info_tFields(JNIEnv *env, jobject lpObject)
+{
+ if (cef_window_info_tFc.cached) return;
+ cef_window_info_tFc.clazz = (*env)->GetObjectClass(env, lpObject);
+ cef_window_info_tFc.ex_style = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "ex_style", "I");
+ cef_window_info_tFc.window_name = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "window_name", "Lorg/eclipse/swt/internal/cef3/cef_string_t;");
+ cef_window_info_tFc.style = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "style", "I");
+ cef_window_info_tFc.x = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "x", "I");
+ cef_window_info_tFc.y = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "y", "I");
+ cef_window_info_tFc.width = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "width", "I");
+ cef_window_info_tFc.height = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "height", "I");
+ cef_window_info_tFc.parent_window = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "parent_window", I_J);
+ cef_window_info_tFc.menu = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "menu", I_J);
+ cef_window_info_tFc.transparent_painting = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "transparent_painting", "I");
+ cef_window_info_tFc.window = (*env)->GetFieldID(env, cef_window_info_tFc.clazz, "window", I_J);
+ cef_window_info_tFc.cached = 1;
+}
+
+cef_window_info_t *getcef_window_info_tFields(JNIEnv *env, jobject lpObject, cef_window_info_t *lpStruct)
+{
+ if (!cef_window_info_tFc.cached) cachecef_window_info_tFields(env, lpObject);
+ lpStruct->ex_style = (DWORD)(*env)->GetIntField(env, lpObject, cef_window_info_tFc.ex_style);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_window_info_tFc.window_name);
+ if (lpObject1 != NULL) getcef_string_tFields(env, lpObject1, &lpStruct->window_name);
+ }
+ lpStruct->style = (DWORD)(*env)->GetIntField(env, lpObject, cef_window_info_tFc.style);
+ lpStruct->x = (int)(*env)->GetIntField(env, lpObject, cef_window_info_tFc.x);
+ lpStruct->y = (int)(*env)->GetIntField(env, lpObject, cef_window_info_tFc.y);
+ lpStruct->width = (int)(*env)->GetIntField(env, lpObject, cef_window_info_tFc.width);
+ lpStruct->height = (int)(*env)->GetIntField(env, lpObject, cef_window_info_tFc.height);
+ lpStruct->parent_window = (cef_window_handle_t)(*env)->GetIntLongField(env, lpObject, cef_window_info_tFc.parent_window);
+ lpStruct->menu = (HMENU)(*env)->GetIntLongField(env, lpObject, cef_window_info_tFc.menu);
+ lpStruct->transparent_painting = (BOOL)(*env)->GetIntField(env, lpObject, cef_window_info_tFc.transparent_painting);
+ lpStruct->window = (cef_window_handle_t)(*env)->GetIntLongField(env, lpObject, cef_window_info_tFc.window);
+ return lpStruct;
+}
+
+void setcef_window_info_tFields(JNIEnv *env, jobject lpObject, cef_window_info_t *lpStruct)
+{
+ if (!cef_window_info_tFc.cached) cachecef_window_info_tFields(env, lpObject);
+ (*env)->SetIntField(env, lpObject, cef_window_info_tFc.ex_style, (jint)lpStruct->ex_style);
+ {
+ jobject lpObject1 = (*env)->GetObjectField(env, lpObject, cef_window_info_tFc.window_name);
+ if (lpObject1 != NULL) setcef_string_tFields(env, lpObject1, &lpStruct->window_name);
+ }
+ (*env)->SetIntField(env, lpObject, cef_window_info_tFc.style, (jint)lpStruct->style);
+ (*env)->SetIntField(env, lpObject, cef_window_info_tFc.x, (jint)lpStruct->x);
+ (*env)->SetIntField(env, lpObject, cef_window_info_tFc.y, (jint)lpStruct->y);
+ (*env)->SetIntField(env, lpObject, cef_window_info_tFc.width, (jint)lpStruct->width);
+ (*env)->SetIntField(env, lpObject, cef_window_info_tFc.height, (jint)lpStruct->height);
+ (*env)->SetIntLongField(env, lpObject, cef_window_info_tFc.parent_window, (jintLong)lpStruct->parent_window);
+ (*env)->SetIntLongField(env, lpObject, cef_window_info_tFc.menu, (jintLong)lpStruct->menu);
+ (*env)->SetIntField(env, lpObject, cef_window_info_tFc.transparent_painting, (jint)lpStruct->transparent_painting);
+ (*env)->SetIntLongField(env, lpObject, cef_window_info_tFc.window, (jintLong)lpStruct->window);
+}
+#endif
+
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_structs.h b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_structs.h
new file mode 100644
index 0000000000..7d17b78342
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_structs.h
@@ -0,0 +1,229 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+
+#include "cef3.h"
+
+#ifndef NO_cef_app_t
+void cachecef_app_tFields(JNIEnv *env, jobject lpObject);
+cef_app_t *getcef_app_tFields(JNIEnv *env, jobject lpObject, cef_app_t *lpStruct);
+void setcef_app_tFields(JNIEnv *env, jobject lpObject, cef_app_t *lpStruct);
+#define cef_app_t_sizeof() sizeof(cef_app_t)
+#else
+#define cachecef_app_tFields(a,b)
+#define getcef_app_tFields(a,b,c) NULL
+#define setcef_app_tFields(a,b,c)
+#define cef_app_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_base_t
+void cachecef_base_tFields(JNIEnv *env, jobject lpObject);
+cef_base_t *getcef_base_tFields(JNIEnv *env, jobject lpObject, cef_base_t *lpStruct);
+void setcef_base_tFields(JNIEnv *env, jobject lpObject, cef_base_t *lpStruct);
+#define cef_base_t_sizeof() sizeof(cef_base_t)
+#else
+#define cachecef_base_tFields(a,b)
+#define getcef_base_tFields(a,b,c) NULL
+#define setcef_base_tFields(a,b,c)
+#define cef_base_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_browser_process_handler_t
+void cachecef_browser_process_handler_tFields(JNIEnv *env, jobject lpObject);
+cef_browser_process_handler_t *getcef_browser_process_handler_tFields(JNIEnv *env, jobject lpObject, cef_browser_process_handler_t *lpStruct);
+void setcef_browser_process_handler_tFields(JNIEnv *env, jobject lpObject, cef_browser_process_handler_t *lpStruct);
+#define cef_browser_process_handler_t_sizeof() sizeof(cef_browser_process_handler_t)
+#else
+#define cachecef_browser_process_handler_tFields(a,b)
+#define getcef_browser_process_handler_tFields(a,b,c) NULL
+#define setcef_browser_process_handler_tFields(a,b,c)
+#define cef_browser_process_handler_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_browser_settings_t
+void cachecef_browser_settings_tFields(JNIEnv *env, jobject lpObject);
+cef_browser_settings_t *getcef_browser_settings_tFields(JNIEnv *env, jobject lpObject, cef_browser_settings_t *lpStruct);
+void setcef_browser_settings_tFields(JNIEnv *env, jobject lpObject, cef_browser_settings_t *lpStruct);
+#define cef_browser_settings_t_sizeof() sizeof(cef_browser_settings_t)
+#else
+#define cachecef_browser_settings_tFields(a,b)
+#define getcef_browser_settings_tFields(a,b,c) NULL
+#define setcef_browser_settings_tFields(a,b,c)
+#define cef_browser_settings_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_client_t
+void cachecef_client_tFields(JNIEnv *env, jobject lpObject);
+cef_client_t *getcef_client_tFields(JNIEnv *env, jobject lpObject, cef_client_t *lpStruct);
+void setcef_client_tFields(JNIEnv *env, jobject lpObject, cef_client_t *lpStruct);
+#define cef_client_t_sizeof() sizeof(cef_client_t)
+#else
+#define cachecef_client_tFields(a,b)
+#define getcef_client_tFields(a,b,c) NULL
+#define setcef_client_tFields(a,b,c)
+#define cef_client_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_command_line_t
+void cachecef_command_line_tFields(JNIEnv *env, jobject lpObject);
+cef_command_line_t *getcef_command_line_tFields(JNIEnv *env, jobject lpObject, cef_command_line_t *lpStruct);
+void setcef_command_line_tFields(JNIEnv *env, jobject lpObject, cef_command_line_t *lpStruct);
+#define cef_command_line_t_sizeof() sizeof(cef_command_line_t)
+#else
+#define cachecef_command_line_tFields(a,b)
+#define getcef_command_line_tFields(a,b,c) NULL
+#define setcef_command_line_tFields(a,b,c)
+#define cef_command_line_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_context_menu_handler_t
+void cachecef_context_menu_handler_tFields(JNIEnv *env, jobject lpObject);
+cef_context_menu_handler_t *getcef_context_menu_handler_tFields(JNIEnv *env, jobject lpObject, cef_context_menu_handler_t *lpStruct);
+void setcef_context_menu_handler_tFields(JNIEnv *env, jobject lpObject, cef_context_menu_handler_t *lpStruct);
+#define cef_context_menu_handler_t_sizeof() sizeof(cef_context_menu_handler_t)
+#else
+#define cachecef_context_menu_handler_tFields(a,b)
+#define getcef_context_menu_handler_tFields(a,b,c) NULL
+#define setcef_context_menu_handler_tFields(a,b,c)
+#define cef_context_menu_handler_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_display_handler_t
+void cachecef_display_handler_tFields(JNIEnv *env, jobject lpObject);
+cef_display_handler_t *getcef_display_handler_tFields(JNIEnv *env, jobject lpObject, cef_display_handler_t *lpStruct);
+void setcef_display_handler_tFields(JNIEnv *env, jobject lpObject, cef_display_handler_t *lpStruct);
+#define cef_display_handler_t_sizeof() sizeof(cef_display_handler_t)
+#else
+#define cachecef_display_handler_tFields(a,b)
+#define getcef_display_handler_tFields(a,b,c) NULL
+#define setcef_display_handler_tFields(a,b,c)
+#define cef_display_handler_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_focus_handler_t
+void cachecef_focus_handler_tFields(JNIEnv *env, jobject lpObject);
+cef_focus_handler_t *getcef_focus_handler_tFields(JNIEnv *env, jobject lpObject, cef_focus_handler_t *lpStruct);
+void setcef_focus_handler_tFields(JNIEnv *env, jobject lpObject, cef_focus_handler_t *lpStruct);
+#define cef_focus_handler_t_sizeof() sizeof(cef_focus_handler_t)
+#else
+#define cachecef_focus_handler_tFields(a,b)
+#define getcef_focus_handler_tFields(a,b,c) NULL
+#define setcef_focus_handler_tFields(a,b,c)
+#define cef_focus_handler_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_life_span_handler_t
+void cachecef_life_span_handler_tFields(JNIEnv *env, jobject lpObject);
+cef_life_span_handler_t *getcef_life_span_handler_tFields(JNIEnv *env, jobject lpObject, cef_life_span_handler_t *lpStruct);
+void setcef_life_span_handler_tFields(JNIEnv *env, jobject lpObject, cef_life_span_handler_t *lpStruct);
+#define cef_life_span_handler_t_sizeof() sizeof(cef_life_span_handler_t)
+#else
+#define cachecef_life_span_handler_tFields(a,b)
+#define getcef_life_span_handler_tFields(a,b,c) NULL
+#define setcef_life_span_handler_tFields(a,b,c)
+#define cef_life_span_handler_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_load_handler_t
+void cachecef_load_handler_tFields(JNIEnv *env, jobject lpObject);
+cef_load_handler_t *getcef_load_handler_tFields(JNIEnv *env, jobject lpObject, cef_load_handler_t *lpStruct);
+void setcef_load_handler_tFields(JNIEnv *env, jobject lpObject, cef_load_handler_t *lpStruct);
+#define cef_load_handler_t_sizeof() sizeof(cef_load_handler_t)
+#else
+#define cachecef_load_handler_tFields(a,b)
+#define getcef_load_handler_tFields(a,b,c) NULL
+#define setcef_load_handler_tFields(a,b,c)
+#define cef_load_handler_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_main_args_t
+void cachecef_main_args_tFields(JNIEnv *env, jobject lpObject);
+cef_main_args_t *getcef_main_args_tFields(JNIEnv *env, jobject lpObject, cef_main_args_t *lpStruct);
+void setcef_main_args_tFields(JNIEnv *env, jobject lpObject, cef_main_args_t *lpStruct);
+#define cef_main_args_t_sizeof() sizeof(cef_main_args_t)
+#else
+#define cachecef_main_args_tFields(a,b)
+#define getcef_main_args_tFields(a,b,c) NULL
+#define setcef_main_args_tFields(a,b,c)
+#define cef_main_args_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_proxy_handler_t
+void cachecef_proxy_handler_tFields(JNIEnv *env, jobject lpObject);
+cef_proxy_handler_t *getcef_proxy_handler_tFields(JNIEnv *env, jobject lpObject, cef_proxy_handler_t *lpStruct);
+void setcef_proxy_handler_tFields(JNIEnv *env, jobject lpObject, cef_proxy_handler_t *lpStruct);
+#define cef_proxy_handler_t_sizeof() sizeof(cef_proxy_handler_t)
+#else
+#define cachecef_proxy_handler_tFields(a,b)
+#define getcef_proxy_handler_tFields(a,b,c) NULL
+#define setcef_proxy_handler_tFields(a,b,c)
+#define cef_proxy_handler_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_request_handler_t
+void cachecef_request_handler_tFields(JNIEnv *env, jobject lpObject);
+cef_request_handler_t *getcef_request_handler_tFields(JNIEnv *env, jobject lpObject, cef_request_handler_t *lpStruct);
+void setcef_request_handler_tFields(JNIEnv *env, jobject lpObject, cef_request_handler_t *lpStruct);
+#define cef_request_handler_t_sizeof() sizeof(cef_request_handler_t)
+#else
+#define cachecef_request_handler_tFields(a,b)
+#define getcef_request_handler_tFields(a,b,c) NULL
+#define setcef_request_handler_tFields(a,b,c)
+#define cef_request_handler_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_resource_bundle_handler_t
+void cachecef_resource_bundle_handler_tFields(JNIEnv *env, jobject lpObject);
+cef_resource_bundle_handler_t *getcef_resource_bundle_handler_tFields(JNIEnv *env, jobject lpObject, cef_resource_bundle_handler_t *lpStruct);
+void setcef_resource_bundle_handler_tFields(JNIEnv *env, jobject lpObject, cef_resource_bundle_handler_t *lpStruct);
+#define cef_resource_bundle_handler_t_sizeof() sizeof(cef_resource_bundle_handler_t)
+#else
+#define cachecef_resource_bundle_handler_tFields(a,b)
+#define getcef_resource_bundle_handler_tFields(a,b,c) NULL
+#define setcef_resource_bundle_handler_tFields(a,b,c)
+#define cef_resource_bundle_handler_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_settings_t
+void cachecef_settings_tFields(JNIEnv *env, jobject lpObject);
+cef_settings_t *getcef_settings_tFields(JNIEnv *env, jobject lpObject, cef_settings_t *lpStruct);
+void setcef_settings_tFields(JNIEnv *env, jobject lpObject, cef_settings_t *lpStruct);
+#define cef_settings_t_sizeof() sizeof(cef_settings_t)
+#else
+#define cachecef_settings_tFields(a,b)
+#define getcef_settings_tFields(a,b,c) NULL
+#define setcef_settings_tFields(a,b,c)
+#define cef_settings_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_string_t
+void cachecef_string_tFields(JNIEnv *env, jobject lpObject);
+cef_string_t *getcef_string_tFields(JNIEnv *env, jobject lpObject, cef_string_t *lpStruct);
+void setcef_string_tFields(JNIEnv *env, jobject lpObject, cef_string_t *lpStruct);
+#define cef_string_t_sizeof() sizeof(cef_string_t)
+#else
+#define cachecef_string_tFields(a,b)
+#define getcef_string_tFields(a,b,c) NULL
+#define setcef_string_tFields(a,b,c)
+#define cef_string_t_sizeof() 0
+#endif
+
+#ifndef NO_cef_window_info_t
+void cachecef_window_info_tFields(JNIEnv *env, jobject lpObject);
+cef_window_info_t *getcef_window_info_tFields(JNIEnv *env, jobject lpObject, cef_window_info_t *lpStruct);
+void setcef_window_info_tFields(JNIEnv *env, jobject lpObject, cef_window_info_t *lpStruct);
+#define cef_window_info_t_sizeof() sizeof(cef_window_info_t)
+#else
+#define cachecef_window_info_tFields(a,b)
+#define getcef_window_info_tFields(a,b,c) NULL
+#define setcef_window_info_tFields(a,b,c)
+#define cef_window_info_t_sizeof() 0
+#endif
+
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_subprocess.c b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_subprocess.c
new file mode 100644
index 0000000000..d06c452c6e
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/cef3_subprocess.c
@@ -0,0 +1,25 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+
+ //#include <windows.h>
+//#include <stdio.h>
+#include "swt.h"
+#include "cef3_structs.h"
+#include "cef3_stats.h"
+#include <cef_app_capi.h>
+
+
+int main(int argc, char **argv, char **envp) {
+ cef_main_args_t args;
+ args.instance = GetModuleHandle("cef3_subprocess.exe");
+// MessageBox(0, "in main(void)", 0, MB_OK);
+ return cef_execute_process(&args, NULL);
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/swt_cef3.rc b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/swt_cef3.rc
new file mode 100644
index 0000000000..aa69968d31
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library/swt_cef3.rc
@@ -0,0 +1,45 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+
+#include "windows.h"
+
+VS_VERSION_INFO VERSIONINFO
+ FILEVERSION SWT_COMMA_VERSION
+ PRODUCTVERSION 0,0,0,0
+ FILEFLAGSMASK 0x3fL
+#ifdef _DEBUG
+ FILEFLAGS 0x1L
+#else
+ FILEFLAGS 0x0L
+#endif
+ FILEOS 0x40000L
+ FILETYPE 0x2L
+ FILESUBTYPE 0x0L
+BEGIN
+ BLOCK "StringFileInfo"
+ BEGIN
+ BLOCK "040904b0"
+ BEGIN
+ VALUE "CompanyName", "Eclipse Foundation\0"
+ VALUE "FileDescription", "SWT for Windows native library\0"
+ VALUE "FileVersion", SWT_FILE_VERSION
+ VALUE "InternalName", "SWT\0"
+ VALUE "LegalCopyright", "Copyright (c) 2013 IBM Corp. All Rights Reserved.\0"
+ VALUE "OriginalFilename", SWT_ORG_FILENAME
+ VALUE "ProductName", "Standard Widget Toolkit\0"
+ VALUE "ProductVersion", "0,0,0,0\0"
+ END
+ END
+ BLOCK "VarFileInfo"
+ BEGIN
+ VALUE "Translation", 0x409, 1200
+ END
+END
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEF.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEF.java
new file mode 100644
index 0000000000..b808ab2a98
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEF.java
@@ -0,0 +1,2453 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.swt.browser;
+
+
+import java.io.UnsupportedEncodingException;
+import java.net.*;
+import java.util.*;
+
+import org.eclipse.swt.*;
+import org.eclipse.swt.graphics.*;
+import org.eclipse.swt.internal.*;
+import org.eclipse.swt.internal.cef3.*;
+import org.eclipse.swt.internal.win32.OS;
+import org.eclipse.swt.layout.*;
+import org.eclipse.swt.widgets.*;
+
+public class CEF extends WebBrowser {
+ public static cef_string_t STRING_EMPTY;
+
+ long /*int*/ webView, webViewData, scrolledWindow;
+ int failureCount, lastKeyCode, lastCharCode;
+ String postData;
+ String[] headers;
+ boolean ignoreDispose, loadingText, untrustedText;
+ byte[] htmlBytes;
+ BrowserFunction eventFunction;
+
+ static int DisabledJSCount;
+ static long /*int*/ ExternalClass, PostString, WebViewType;
+ static boolean IsWebKit14orNewer, LibraryLoaded;
+ static Hashtable WindowMappings = new Hashtable ();
+
+ static final String ABOUT_BLANK = "about:blank"; //$NON-NLS-1$
+ static final String CHARSET_UTF8 = "UTF-8"; //$NON-NLS-1$
+ static final String CLASSNAME_EXTERNAL = "External"; //$NON-NLS-1$
+ static final String FUNCTIONNAME_CALLJAVA = "callJava"; //$NON-NLS-1$
+ static final String HEADER_CONTENTTYPE = "content-type"; //$NON-NLS-1$
+ static final String MIMETYPE_FORMURLENCODED = "application/x-www-form-urlencoded"; //$NON-NLS-1$
+ static final String OBJECTNAME_EXTERNAL = "external"; //$NON-NLS-1$
+ static final String PROPERTY_LENGTH = "length"; //$NON-NLS-1$
+ static final String PROPERTY_PROXYHOST = "network.proxy_host"; //$NON-NLS-1$
+ static final String PROPERTY_PROXYPORT = "network.proxy_port"; //$NON-NLS-1$
+ static final String PROTOCOL_FILE = "file://"; //$NON-NLS-1$
+ static final String PROTOCOL_HTTP = "http://"; //$NON-NLS-1$
+ static final String URI_FILEROOT = "file:///"; //$NON-NLS-1$
+ static final String USER_AGENT = "user-agent"; //$NON-NLS-1$
+ static final int MAX_PORT = 65535;
+ static final int MAX_PROGRESS = 100;
+ static final int[] MIN_VERSION = {1, 2, 0};
+ static final int SENTINEL_KEYPRESS = -1;
+ static final char SEPARATOR_FILE = System.getProperty ("file.separator").charAt (0); //$NON-NLS-1$
+ static final int STOP_PROPOGATE = 1;
+
+ static final String DOMEVENT_DRAGSTART = "dragstart"; //$NON-NLS-1$
+ static final String DOMEVENT_KEYDOWN = "keydown"; //$NON-NLS-1$
+ static final String DOMEVENT_KEYPRESS = "keypress"; //$NON-NLS-1$
+ static final String DOMEVENT_KEYUP = "keyup"; //$NON-NLS-1$
+ static final String DOMEVENT_MOUSEDOWN = "mousedown"; //$NON-NLS-1$
+ static final String DOMEVENT_MOUSEUP = "mouseup"; //$NON-NLS-1$
+ static final String DOMEVENT_MOUSEMOVE = "mousemove"; //$NON-NLS-1$
+ static final String DOMEVENT_MOUSEOUT = "mouseout"; //$NON-NLS-1$
+ static final String DOMEVENT_MOUSEOVER = "mouseover"; //$NON-NLS-1$
+ static final String DOMEVENT_MOUSEWHEEL = "mousewheel"; //$NON-NLS-1$
+
+ /* WebKit signal data */
+ static final int HOVERING_OVER_LINK = 1;
+ static final int NOTIFY_PROGRESS = 2;
+ static final int NAVIGATION_POLICY_DECISION_REQUESTED = 3;
+ static final int NOTIFY_TITLE = 4;
+ static final int POPULATE_POPUP = 5;
+ static final int STATUS_BAR_TEXT_CHANGED = 6;
+ static final int CREATE_WEB_VIEW = 7;
+ static final int WEB_VIEW_READY = 8;
+ static final int NOTIFY_LOAD_STATUS = 9;
+ static final int RESOURCE_REQUEST_STARTING = 10;
+ static final int DOWNLOAD_REQUESTED = 11;
+ static final int MIME_TYPE_POLICY_DECISION_REQUESTED = 12;
+ static final int CLOSE_WEB_VIEW = 13;
+ static final int WINDOW_OBJECT_CLEARED = 14;
+ static final int CONSOLE_MESSAGE = 15;
+
+ static final String KEY_CHECK_SUBWINDOW = "org.eclipse.swt.internal.control.checksubwindow"; //$NON-NLS-1$
+
+ /* the following Callbacks are never freed */
+ static Callback Proc2, Proc3, Proc4, Proc5, Proc6;
+ static Callback JSObjectHasPropertyProc, JSObjectGetPropertyProc, JSObjectCallAsFunctionProc;
+ static Callback JSDOMEventProc;
+
+ static {
+ try {
+// Library.loadLibrary ("libcef"); // $NON-NLS-1$
+ Library.loadLibrary ("swt-cef3"); // $NON-NLS-1$
+ LibraryLoaded = true;
+ long /*int*/ string = CEF3.cef_string_userfree_alloc();
+ CEF3.cef_string_clear(string);
+ STRING_EMPTY = new cef_string_t();
+ CEF3.memmove(STRING_EMPTY, string, cef_string_t.sizeof);
+ } catch (Throwable e) {
+ e.printStackTrace();
+ }
+
+ if (LibraryLoaded) {
+// WebViewType = WebKitGTK.webkit_web_view_get_type ();
+
+// Proc2 = new Callback (WebKit.class, "Proc", 2); //$NON-NLS-1$
+// if (Proc2.getAddress () == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
+// Proc3 = new Callback (WebKit.class, "Proc", 3); //$NON-NLS-1$
+// if (Proc3.getAddress () == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
+// Proc4 = new Callback (WebKit.class, "Proc", 4); //$NON-NLS-1$
+// if (Proc4.getAddress () == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
+// Proc5 = new Callback (WebKit.class, "Proc", 5); //$NON-NLS-1$
+// if (Proc5.getAddress () == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
+// Proc6 = new Callback (WebKit.class, "Proc", 6); //$NON-NLS-1$
+// if (Proc6.getAddress () == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
+// JSObjectHasPropertyProc = new Callback (WebKit.class, "JSObjectHasPropertyProc", 3); //$NON-NLS-1$
+// if (JSObjectHasPropertyProc.getAddress () == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
+// JSObjectGetPropertyProc = new Callback (WebKit.class, "JSObjectGetPropertyProc", 4); //$NON-NLS-1$
+// if (JSObjectGetPropertyProc.getAddress () == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
+// JSObjectCallAsFunctionProc = new Callback (WebKit.class, "JSObjectCallAsFunctionProc", 6); //$NON-NLS-1$
+// if (JSObjectCallAsFunctionProc.getAddress () == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
+// JSDOMEventProc = new Callback (WebKit.class, "JSDOMEventProc", 3); //$NON-NLS-1$
+// if (JSDOMEventProc.getAddress () == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
+
+ NativeClearSessions = new Runnable () {
+ public void run () {
+ if (!LibraryLoaded) return;
+// long /*int*/ session = WebKitGTK.webkit_get_default_session ();
+// long /*int*/ type = WebKitGTK.soup_cookie_jar_get_type ();
+// long /*int*/ jar = WebKitGTK.soup_session_get_feature (session, type);
+// if (jar == 0) return;
+// long /*int*/ cookies = WebKitGTK.soup_cookie_jar_all_cookies (jar);
+// int length = OS.g_slist_length (cookies);
+// long /*int*/ current = cookies;
+// for (int i = 0; i < length; i++) {
+// long /*int*/ cookie = OS.g_slist_data (current);
+// long /*int*/ expires = WebKitGTK.SoupCookie_expires (cookie);
+// if (expires == 0) {
+// /* indicates a session cookie */
+// WebKitGTK.soup_cookie_jar_delete_cookie (jar, cookie);
+// }
+// WebKitGTK.soup_cookie_free (cookie);
+// current = OS.g_slist_next (current);
+// }
+// OS.g_slist_free (cookies);
+ }
+ };
+
+ NativeGetCookie = new Runnable () {
+ public void run () {
+ if (!LibraryLoaded) return;
+// long /*int*/ session = WebKitGTK.webkit_get_default_session ();
+// long /*int*/ type = WebKitGTK.soup_cookie_jar_get_type ();
+// long /*int*/ jar = WebKitGTK.soup_session_get_feature (session, type);
+// if (jar == 0) return;
+// byte[] bytes = Converter.wcsToMbcs (null, CookieUrl, true);
+// long /*int*/ uri = WebKitGTK.soup_uri_new (bytes);
+// if (uri == 0) return;
+// long /*int*/ cookies = WebKitGTK.soup_cookie_jar_get_cookies (jar, uri, 0);
+// WebKitGTK.soup_uri_free (uri);
+// if (cookies == 0) return;
+// int length = OS.strlen (cookies);
+// bytes = new byte[length];
+// C.memmove (bytes, cookies, length);
+// OS.g_free (cookies);
+// String allCookies = new String (Converter.mbcsToWcs (null, bytes));
+// StringTokenizer tokenizer = new StringTokenizer (allCookies, ";"); //$NON-NLS-1$
+// while (tokenizer.hasMoreTokens ()) {
+// String cookie = tokenizer.nextToken ();
+// int index = cookie.indexOf ('=');
+// if (index != -1) {
+// String name = cookie.substring (0, index).trim ();
+// if (name.equals (CookieName)) {
+// CookieValue = cookie.substring (index + 1).trim ();
+// return;
+// }
+// }
+// }
+ }
+ };
+
+ NativeSetCookie = new Runnable () {
+ public void run () {
+ if (!LibraryLoaded) return;
+// long /*int*/ session = WebKitGTK.webkit_get_default_session ();
+// long /*int*/ type = WebKitGTK.soup_cookie_jar_get_type ();
+// long /*int*/ jar = WebKitGTK.soup_session_get_feature (session, type);
+// if (jar == 0) {
+// /* this happens if a navigation has not occurred yet */
+// WebKitGTK.soup_session_add_feature_by_type (session, type);
+// jar = WebKitGTK.soup_session_get_feature (session, type);
+// }
+// if (jar == 0) return;
+// byte[] bytes = Converter.wcsToMbcs (null, CookieUrl, true);
+// long /*int*/ uri = WebKitGTK.soup_uri_new (bytes);
+// if (uri == 0) return;
+// bytes = Converter.wcsToMbcs (null, CookieValue, true);
+// long /*int*/ cookie = WebKitGTK.soup_cookie_parse (bytes, uri);
+// if (cookie != 0) {
+// WebKitGTK.soup_cookie_jar_add_cookie (jar, cookie);
+// // the following line is intentionally commented
+// // WebKitGTK.soup_cookie_free (cookie);
+// CookieResult = true;
+// }
+// WebKitGTK.soup_uri_free (uri);
+ }
+ };
+
+ if (NativePendingCookies != null) {
+ SetPendingCookies (NativePendingCookies);
+ NativePendingCookies = null;
+ }
+ }
+ }
+
+static Browser FindBrowser (long /*int*/ webView) {
+ if (webView == 0) return null;
+// long /*int*/ parent = OS.gtk_widget_get_parent (webView);
+// parent = OS.gtk_widget_get_parent (parent);
+// return (Browser)Display.getCurrent ().findWidget (parent);
+ return null;
+}
+
+static boolean IsInstalled () {
+ if (!LibraryLoaded) return false;
+ // TODO webkit_check_version() should take care of the following, but for some
+ // reason this symbol is missing from the latest build. If it is present in
+ // Linux distro-provided builds then replace the following with this call.
+// int major = WebKitGTK.webkit_major_version ();
+// int minor = WebKitGTK.webkit_minor_version ();
+// int micro = WebKitGTK.webkit_micro_version ();
+// IsWebKit14orNewer = major > 1 ||
+// (major == 1 && minor > 4) ||
+// (major == 1 && minor == 4 && micro >= 0);
+// return major > MIN_VERSION[0] ||
+// (major == MIN_VERSION[0] && minor > MIN_VERSION[1]) ||
+// (major == MIN_VERSION[0] && minor == MIN_VERSION[1] && micro >= MIN_VERSION[2]);
+ return true;
+}
+
+//static long /*int*/ JSObjectCallAsFunctionProc (long /*int*/ ctx, long /*int*/ function, long /*int*/ thisObject, long /*int*/ argumentCount, long /*int*/ arguments, long /*int*/ exception) {
+// if (WebKitGTK.JSValueIsObjectOfClass (ctx, thisObject, ExternalClass) == 0) {
+// return WebKitGTK.JSValueMakeUndefined (ctx);
+// }
+// long /*int*/ ptr = WebKitGTK.JSObjectGetPrivate (thisObject);
+// long /*int*/[] handle = new long /*int*/[1];
+// C.memmove (handle, ptr, C.PTR_SIZEOF);
+// Browser browser = FindBrowser (handle[0]);
+// if (browser == null) return 0;
+// WebKit webkit = (WebKit)browser.webBrowser;
+// return webkit.callJava (ctx, function, thisObject, argumentCount, arguments, exception);
+//}
+
+//static long /*int*/ JSObjectGetPropertyProc (long /*int*/ ctx, long /*int*/ object, long /*int*/ propertyName, long /*int*/ exception) {
+// byte[] bytes = null;
+// try {
+// bytes = (FUNCTIONNAME_CALLJAVA + '\0').getBytes (CHARSET_UTF8); //$NON-NLS-1$
+// } catch (UnsupportedEncodingException e) {
+// bytes = Converter.wcsToMbcs (null, FUNCTIONNAME_CALLJAVA, true);
+// }
+// long /*int*/ name = WebKitGTK.JSStringCreateWithUTF8CString (bytes);
+// long /*int*/ function = WebKitGTK.JSObjectMakeFunctionWithCallback (ctx, name, JSObjectCallAsFunctionProc.getAddress ());
+// WebKitGTK.JSStringRelease (name);
+// return function;
+//}
+
+//static long /*int*/ JSObjectHasPropertyProc (long /*int*/ ctx, long /*int*/ object, long /*int*/ propertyName) {
+// byte[] bytes = null;
+// try {
+// bytes = (FUNCTIONNAME_CALLJAVA + '\0').getBytes (CHARSET_UTF8); //$NON-NLS-1$
+// } catch (UnsupportedEncodingException e) {
+// bytes = Converter.wcsToMbcs (null, FUNCTIONNAME_CALLJAVA, true);
+// }
+// return WebKitGTK.JSStringIsEqualToUTF8CString (propertyName, bytes);
+//}
+
+//static long /*int*/ JSDOMEventProc (long /*int*/ arg0, long /*int*/ event, long /*int*/ user_data) {
+// if (OS.GTK_IS_SCROLLED_WINDOW (arg0)) {
+// /*
+// * Stop the propagation of events that are not consumed by WebKit, before
+// * they reach the parent embedder. These events have already been received.
+// */
+// return user_data;
+// }
+//
+// if (OS.G_TYPE_CHECK_INSTANCE_TYPE (arg0, WebViewType)) {
+// /*
+// * Only consider using GDK events to create SWT events to send if JS is disabled
+// * in one or more WebKit instances (indicates that this instance may not be
+// * receiving events from the DOM). This check is done up-front for performance.
+// */
+// if (DisabledJSCount > 0) {
+// final Browser browser = FindBrowser (arg0);
+// if (browser != null && !browser.webBrowser.jsEnabled) {
+// /* this instance does need to use the GDK event to create an SWT event to send */
+// switch (OS.GDK_EVENT_TYPE (event)) {
+// case OS.GDK_KEY_PRESS: {
+// if (browser.isFocusControl ()) {
+// final GdkEventKey gdkEvent = new GdkEventKey ();
+// OS.memmove (gdkEvent, event, GdkEventKey.sizeof);
+// switch (gdkEvent.keyval) {
+// case OS.GDK_ISO_Left_Tab:
+// case OS.GDK_Tab: {
+// if ((gdkEvent.state & (OS.GDK_CONTROL_MASK | OS.GDK_MOD1_MASK)) == 0) {
+// browser.getDisplay ().asyncExec (new Runnable () {
+// public void run () {
+// if (browser.isDisposed ()) return;
+// if (browser.getDisplay ().getFocusControl () == null) {
+// int traversal = (gdkEvent.state & OS.GDK_SHIFT_MASK) != 0 ? SWT.TRAVERSE_TAB_PREVIOUS : SWT.TRAVERSE_TAB_NEXT;
+// browser.traverse (traversal);
+// }
+// }
+// });
+// }
+// break;
+// }
+// case OS.GDK_Escape: {
+// Event keyEvent = new Event ();
+// keyEvent.widget = browser;
+// keyEvent.type = SWT.KeyDown;
+// keyEvent.keyCode = keyEvent.character = SWT.ESC;
+// if ((gdkEvent.state & OS.GDK_MOD1_MASK) != 0) keyEvent.stateMask |= SWT.ALT;
+// if ((gdkEvent.state & OS.GDK_SHIFT_MASK) != 0) keyEvent.stateMask |= SWT.SHIFT;
+// if ((gdkEvent.state & OS.GDK_CONTROL_MASK) != 0) keyEvent.stateMask |= SWT.CONTROL;
+// browser.webBrowser.sendKeyEvent (keyEvent);
+// return 1;
+// }
+// }
+// }
+// break;
+// }
+// }
+// OS.gtk_widget_event (browser.handle, event);
+// }
+// }
+// return 0;
+// }
+//
+// LONG webViewHandle = (LONG)WindowMappings.get (new LONG (arg0));
+// if (webViewHandle == null) return 0;
+// Browser browser = FindBrowser (webViewHandle.value);
+// if (browser == null) return 0;
+// WebKit webkit = (WebKit)browser.webBrowser;
+// return webkit.handleDOMEvent (event, (int)user_data) ? 0 : STOP_PROPOGATE;
+//}
+
+//static long /*int*/ Proc (long /*int*/ handle, long /*int*/ user_data) {
+// Browser browser = FindBrowser (handle);
+// if (browser == null) return 0;
+// WebKit webkit = (WebKit)browser.webBrowser;
+// return webkit.webViewProc (handle, user_data);
+//}
+
+//static long /*int*/ Proc (long /*int*/ handle, long /*int*/ arg0, long /*int*/ user_data) {
+// long /*int*/ webView;
+// if (OS.G_TYPE_CHECK_INSTANCE_TYPE (handle, WebKitGTK.webkit_web_frame_get_type ())) {
+// webView = WebKitGTK.webkit_web_frame_get_web_view (handle);
+// } else {
+// webView = handle;
+// }
+// Browser browser = FindBrowser (webView);
+// if (browser == null) return 0;
+// WebKit webkit = (WebKit)browser.webBrowser;
+// if (webView == handle) {
+// return webkit.webViewProc (handle, arg0, user_data);
+// } else {
+// return webkit.webFrameProc (handle, arg0, user_data);
+// }
+//}
+
+//static long /*int*/ Proc (long /*int*/ handle, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ user_data) {
+// Browser browser = FindBrowser (handle);
+// if (browser == null) return 0;
+// WebKit webkit = (WebKit)browser.webBrowser;
+// return webkit.webViewProc (handle, arg0, arg1, user_data);
+//}
+
+//static long /*int*/ Proc (long /*int*/ handle, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ user_data) {
+// long /*int*/ webView;
+// if (OS.G_TYPE_CHECK_INSTANCE_TYPE (handle, WebKitGTK.soup_session_get_type ())) {
+// webView = user_data;
+// } else {
+// webView = handle;
+// }
+// Browser browser = FindBrowser (webView);
+// if (browser == null) return 0;
+// WebKit webkit = (WebKit)browser.webBrowser;
+// if (webView == handle) {
+// return webkit.webViewProc (handle, arg0, arg1, arg2, user_data);
+// } else {
+// return webkit.sessionProc (handle, arg0, arg1, arg2, user_data);
+// }
+//}
+
+//static long /*int*/ Proc (long /*int*/ handle, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3, long /*int*/ user_data) {
+// Browser browser = FindBrowser (handle);
+// if (browser == null) return 0;
+// WebKit webkit = (WebKit)browser.webBrowser;
+// return webkit.webViewProc (handle, arg0, arg1, arg2, arg3, user_data);
+//}
+
+//long /*int*/ sessionProc (long /*int*/ session, long /*int*/ msg, long /*int*/ auth, long /*int*/ retrying, long /*int*/ user_data) {
+// /* authentication challenges are currently the only notification received from the session */
+// if (retrying == 0) {
+// failureCount = 0;
+// } else {
+// if (++failureCount >= 3) return 0;
+// }
+//
+// long /*int*/ uri = WebKitGTK.soup_message_get_uri (msg);
+// long /*int*/ uriString = WebKitGTK.soup_uri_to_string (uri, 0);
+// int length = C.strlen (uriString);
+// byte[] bytes = new byte[length];
+// OS.memmove (bytes, uriString, length);
+// OS.g_free (uriString);
+// String location = new String (MozillaDelegate.mbcsToWcs (null, bytes));
+//
+// for (int i = 0; i < authenticationListeners.length; i++) {
+// AuthenticationEvent event = new AuthenticationEvent (browser);
+// event.location = location;
+// authenticationListeners[i].authenticate (event);
+// if (!event.doit) {
+// OS.g_signal_stop_emission_by_name (session, WebKitGTK.authenticate);
+// return 0;
+// }
+// if (event.user != null && event.password != null) {
+// byte[] userBytes = Converter.wcsToMbcs (null, event.user, true);
+// byte[] passwordBytes = Converter.wcsToMbcs (null, event.password, true);
+// WebKitGTK.soup_auth_authenticate (auth, userBytes, passwordBytes);
+// OS.g_signal_stop_emission_by_name (session, WebKitGTK.authenticate);
+// return 0;
+// }
+// }
+// return 0;
+//}
+
+//long /*int*/ webFrameProc (long /*int*/ handle, long /*int*/ arg0, long /*int*/ user_data) {
+// switch ((int)/*64*/user_data) {
+// case NOTIFY_LOAD_STATUS: return webframe_notify_load_status (handle, arg0);
+// default: return 0;
+// }
+//}
+
+//long /*int*/ webViewProc (long /*int*/ handle, long /*int*/ user_data) {
+// switch ((int)/*64*/user_data) {
+// case CLOSE_WEB_VIEW: return webkit_close_web_view (handle);
+// case WEB_VIEW_READY: return webkit_web_view_ready (handle);
+// default: return 0;
+// }
+//}
+
+//long /*int*/ webViewProc (long /*int*/ handle, long /*int*/ arg0, long /*int*/ user_data) {
+// switch ((int)/*64*/user_data) {
+// case CREATE_WEB_VIEW: return webkit_create_web_view (handle, arg0);
+// case DOWNLOAD_REQUESTED: return webkit_download_requested (handle, arg0);
+// case NOTIFY_LOAD_STATUS: return webkit_notify_load_status (handle, arg0);
+// case NOTIFY_PROGRESS: return webkit_notify_progress (handle, arg0);
+// case NOTIFY_TITLE: return webkit_notify_title (handle, arg0);
+// case POPULATE_POPUP: return webkit_populate_popup (handle, arg0);
+// case STATUS_BAR_TEXT_CHANGED: return webkit_status_bar_text_changed (handle, arg0);
+// default: return 0;
+// }
+//}
+
+//long /*int*/ webViewProc (long /*int*/ handle, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ user_data) {
+// switch ((int)/*64*/user_data) {
+// case HOVERING_OVER_LINK: return webkit_hovering_over_link (handle, arg0, arg1);
+// default: return 0;
+// }
+//}
+
+//long /*int*/ webViewProc (long /*int*/ handle, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ user_data) {
+// switch ((int)/*64*/user_data) {
+// case CONSOLE_MESSAGE: return webkit_console_message (handle, arg0, arg1, arg2);
+// case WINDOW_OBJECT_CLEARED: return webkit_window_object_cleared (handle, arg0, arg1, arg2);
+// default: return 0;
+// }
+//}
+
+//long /*int*/ webViewProc (long /*int*/ handle, long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3, long /*int*/ user_data) {
+// switch ((int)/*64*/user_data) {
+// case MIME_TYPE_POLICY_DECISION_REQUESTED: return webkit_mime_type_policy_decision_requested (handle, arg0, arg1, arg2, arg3);
+// case NAVIGATION_POLICY_DECISION_REQUESTED: return webkit_navigation_policy_decision_requested (handle, arg0, arg1, arg2, arg3);
+// case RESOURCE_REQUEST_STARTING: return webkit_resource_request_starting (handle, arg0, arg1, arg2, arg3);
+// default: return 0;
+// }
+//}
+
+public static Callback baseCB_add_ref = new Callback (CEF.class, "base_add_ref", 1); //$NON-NLS-1$
+public static Callback baseCB_get_refct = new Callback (CEF.class, "base_get_refct", 1); //$NON-NLS-1$
+public static Callback baseCB_release = new Callback (CEF.class, "base_release", 1); //$NON-NLS-1$
+public static Callback displayHandlerCB_on_loading_state_change = new Callback (CEF.class, "displayHandler_on_loading_state_change", 5); //$NON-NLS-1$
+public static Callback displayHandlerCB_on_address_change = new Callback (CEF.class, "displayHandler_on_address_change", 4); //$NON-NLS-1$
+public static Callback displayHandlerCB_on_title_change = new Callback (CEF.class, "displayHandler_on_title_change", 3); //$NON-NLS-1$
+public static Callback displayHandlerCB_on_tooltip = new Callback (CEF.class, "displayHandler_on_tooltip", 3); //$NON-NLS-1$
+public static Callback displayHandlerCB_on_status_message = new Callback (CEF.class, "displayHandler_on_status_message", 3); //$NON-NLS-1$
+public static Callback displayHandlerCB_on_console_message = new Callback (CEF.class, "displayHandler_on_console_message", 5); //$NON-NLS-1$
+public static Callback focusHandlerCB_on_take_focus = new Callback (CEF.class, "focusHandler_on_take_focus", 3); //$NON-NLS-1$
+public static Callback focusHandlerCB_on_set_focus = new Callback (CEF.class, "focusHandler_on_set_focus", 3); //$NON-NLS-1$
+public static Callback focusHandlerCB_on_got_focus = new Callback (CEF.class, "focusHandler_on_got_focus", 2); //$NON-NLS-1$
+public static Callback lifeSpanHandlerCB_on_before_popup = new Callback (CEF.class, "lifeSpanHandler_on_before_popup", 7); //$NON-NLS-1$
+public static Callback lifeSpanHandlerCB_on_after_created = new Callback (CEF.class, "lifeSpanHandler_on_after_created", 2); //$NON-NLS-1$
+public static Callback lifeSpanHandlerCB_run_modal = new Callback (CEF.class, "lifeSpanHandler_run_modal", 2); //$NON-NLS-1$
+public static Callback lifeSpanHandlerCB_do_close = new Callback (CEF.class, "lifeSpanHandler_do_close", 2); //$NON-NLS-1$
+public static Callback lifeSpanHandlerCB_on_before_close = new Callback (CEF.class, "lifeSpanHandler_on_before_close", 2); //$NON-NLS-1$
+public static Callback loadHandlerCB_on_load_start = new Callback (CEF.class, "loadHandler_on_load_start", 3); //$NON-NLS-1$
+public static Callback loadHandlerCB_on_load_end = new Callback (CEF.class, "loadHandler_on_load_end", 4); //$NON-NLS-1$
+public static Callback loadHandlerCB_on_load_error = new Callback (CEF.class, "loadHandler_on_load_error", 6); //$NON-NLS-1$
+public static Callback loadHandlerCB_on_render_process_terminated = new Callback (CEF.class, "loadHandler_on_render_process_terminated", 3); //$NON-NLS-1$
+public static Callback loadHandlerCB_on_plugin_crashed = new Callback (CEF.class, "loadHandler_on_plugin_crashed", 3); //$NON-NLS-1$
+public static Callback requestHandlerCB_on_before_resource_load = new Callback (CEF.class, "requestHandler_on_before_resource_load", 4); //$NON-NLS-1$
+public static Callback requestHandlerCB_get_resource_handler = new Callback (CEF.class, "requestHandler_get_resource_handler", 4); //$NON-NLS-1$
+public static Callback requestHandlerCB_on_resource_redirect = new Callback (CEF.class, "requestHandler_on_resource_redirect", 5); //$NON-NLS-1$
+public static Callback requestHandlerCB_get_auth_credentials = new Callback (CEF.class, "requestHandler_get_auth_credentials", 9); //$NON-NLS-1$
+public static Callback requestHandlerCB_on_quota_request = new Callback (CEF.class, "requestHandler_on_quota_request", 5); //$NON-NLS-1$
+public static Callback requestHandlerCB_get_cookie_manager = new Callback (CEF.class, "requestHandler_get_cookie_manager", 3); //$NON-NLS-1$
+public static Callback requestHandlerCB_on_protocol_execution = new Callback (CEF.class, "requestHandler_on_protocol_execution", 4); //$NON-NLS-1$
+public static Callback requestHandlerCB_on_before_plugin_load = new Callback (CEF.class, "requestHandler_on_before_plugin_load", 5); //$NON-NLS-1$
+public static Callback resourceBundleHandlerCB_get_data_resource = new Callback (CEF.class, "resourceBundleHandler_get_data_resource", 4); //$NON-NLS-1$
+public static Callback resourceBundleHandlerCB_get_localized_string = new Callback (CEF.class, "resourceBundleHandler_get_localized_string", 3); //$NON-NLS-1$
+
+
+static HashMap objects = new HashMap();
+static long /*int*/ base_add_ref(long /*int*/ arg0) {
+ Integer object = (Integer)objects.get(Long.valueOf(arg0));
+ if (object == null) {
+ object = new Integer(1);
+ }
+ int value = object.intValue();
+ value++;
+ objects.put(Long.valueOf(arg0), new Integer(value));
+ return value;
+}
+static long /*int*/ base_get_refct(long /*int*/ arg0) {
+ Integer object = (Integer)objects.get(Long.valueOf(arg0));
+ if (object == null) {
+ return 0;
+ }
+ return object.intValue();
+}
+static long /*int*/ base_release(long /*int*/ arg0) {
+ Integer object = (Integer)objects.get(Long.valueOf(arg0));
+ if (object == null) {
+ object = new Integer(1);
+ }
+ int value = object.intValue();
+ value--;
+ objects.put(Long.valueOf(arg0), new Integer(value));
+ if (value == 0) {
+ System.out.println("should release!");
+ }
+ return value;
+}
+
+static long /*int*/ displayHandler; /* leaked */
+static {
+ cef_display_handler_t handler = new cef_display_handler_t();
+ handler.size = cef_display_handler_t.sizeof;
+ handler.add_ref = baseCB_add_ref.getAddress();
+ handler.release = baseCB_release.getAddress();
+ handler.get_refct = baseCB_get_refct.getAddress();
+ handler.on_loading_state_change = displayHandlerCB_on_loading_state_change.getAddress();
+ handler.on_address_change = displayHandlerCB_on_address_change.getAddress();
+ handler.on_title_change = displayHandlerCB_on_title_change.getAddress();
+ handler.on_tooltip = displayHandlerCB_on_tooltip.getAddress();
+ handler.on_status_message = displayHandlerCB_on_status_message.getAddress();
+ handler.on_console_message = displayHandlerCB_on_console_message.getAddress();
+ displayHandler = C.malloc(handler.size);
+ CEF3.memmove(displayHandler, handler, handler.size);
+}
+
+static long /*int*/ focusHandler; /* leaked */
+static {
+ cef_focus_handler_t handler = new cef_focus_handler_t();
+ handler.size = cef_focus_handler_t.sizeof;
+ handler.add_ref = baseCB_add_ref.getAddress();
+ handler.release = baseCB_release.getAddress();
+ handler.get_refct = baseCB_get_refct.getAddress();
+ handler.on_take_focus = focusHandlerCB_on_take_focus.getAddress();
+ handler.on_set_focus = focusHandlerCB_on_set_focus.getAddress();
+ handler.on_got_focus = focusHandlerCB_on_got_focus.getAddress();
+ focusHandler = C.malloc(handler.size);
+ CEF3.memmove(focusHandler, handler, handler.size);
+}
+
+static long /*int*/ lifeSpanHandler; /* leaked */
+static {
+ cef_life_span_handler_t handler = new cef_life_span_handler_t();
+ handler.size = cef_life_span_handler_t.sizeof;
+ handler.add_ref = baseCB_add_ref.getAddress();
+ handler.release = baseCB_release.getAddress();
+ handler.get_refct = baseCB_get_refct.getAddress();
+ handler.on_before_popup = lifeSpanHandlerCB_on_before_popup.getAddress();
+ handler.on_after_created = lifeSpanHandlerCB_on_after_created.getAddress();
+ handler.run_modal = lifeSpanHandlerCB_run_modal.getAddress();
+ handler.do_close = lifeSpanHandlerCB_do_close.getAddress();
+ handler.on_before_close = lifeSpanHandlerCB_on_before_close.getAddress();
+ lifeSpanHandler = C.malloc(handler.size);
+ CEF3.memmove(lifeSpanHandler, handler, handler.size);
+}
+
+static long /*int*/ loadHandler; /* leaked */
+static {
+ cef_load_handler_t handler = new cef_load_handler_t();
+ handler.size = cef_load_handler_t.sizeof;
+ handler.add_ref = baseCB_add_ref.getAddress();
+ handler.release = baseCB_release.getAddress();
+ handler.get_refct = baseCB_get_refct.getAddress();
+ handler.on_load_start = loadHandlerCB_on_load_start.getAddress();
+ handler.on_load_end = loadHandlerCB_on_load_end.getAddress();
+ handler.on_load_error = loadHandlerCB_on_load_error.getAddress();
+ handler.on_render_process_terminated = loadHandlerCB_on_render_process_terminated.getAddress();
+ handler.on_plugin_crashed = loadHandlerCB_on_plugin_crashed.getAddress();
+ loadHandler = C.malloc(handler.size);
+ CEF3.memmove(loadHandler, handler, handler.size);
+}
+
+static long /*int*/ requestHandler; /* leaked */
+static {
+ cef_request_handler_t handler = new cef_request_handler_t();
+ handler.size = cef_request_handler_t.sizeof;
+ handler.add_ref = baseCB_add_ref.getAddress();
+ handler.release = baseCB_release.getAddress();
+ handler.get_refct = baseCB_get_refct.getAddress();
+ handler.on_before_resource_load = requestHandlerCB_on_before_resource_load.getAddress();
+ handler.get_resource_handler = requestHandlerCB_get_resource_handler.getAddress();
+ handler.on_resource_redirect = requestHandlerCB_on_resource_redirect.getAddress();
+ handler.get_auth_credentials = requestHandlerCB_get_auth_credentials.getAddress();
+ handler.on_quota_request = requestHandlerCB_on_quota_request.getAddress();
+ handler.get_cookie_manager = requestHandlerCB_get_cookie_manager.getAddress();
+ handler.on_protocol_execution = requestHandlerCB_on_protocol_execution.getAddress();
+ handler.on_before_plugin_load = requestHandlerCB_on_before_plugin_load.getAddress();
+ requestHandler = C.malloc(handler.size);
+ CEF3.memmove(requestHandler, handler, handler.size);
+}
+
+static long /*int*/ resourceBundleHandler; /* leaked */
+static {
+ cef_resource_bundle_handler_t handler = new cef_resource_bundle_handler_t();
+ handler.size = cef_resource_bundle_handler_t.sizeof;
+ handler.add_ref = baseCB_add_ref.getAddress();
+ handler.release = baseCB_release.getAddress();
+ handler.get_refct = baseCB_get_refct.getAddress();
+ handler.get_data_resource = resourceBundleHandlerCB_get_data_resource.getAddress();
+ handler.get_localized_string = resourceBundleHandlerCB_get_localized_string.getAddress();
+ resourceBundleHandler = C.malloc(handler.size);
+ CEF3.memmove(resourceBundleHandler, handler, handler.size);
+}
+
+static long /*int*/ displayHandler_on_loading_state_change(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3, long /*int*/ arg4) {
+ System.out.println("displayHandler_on_loading_state_change");
+ return 0;
+}
+static long /*int*/ displayHandler_on_address_change(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3) {
+ System.out.println("displayHandler_on_address_change");
+ return 0;
+}
+static long /*int*/ displayHandler_on_title_change(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ System.out.println("displayHandler_on_title_change");
+ return 0;
+}
+static long /*int*/ displayHandler_on_tooltip(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ System.out.println("displayHandler_on_tooltip");
+ return 0;
+}
+static long /*int*/ displayHandler_on_status_message(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ System.out.println("displayHandler_on_status_message");
+ return 0;
+}
+static long /*int*/ displayHandler_on_console_message(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3, long /*int*/ arg4) {
+ System.out.println("displayHandler_on_console_message");
+ return 0;
+}
+static long /*int*/ focusHandler_on_take_focus(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ System.out.println("focusHandler_on_take_focus");
+ return 0;
+}
+static long /*int*/ focusHandler_on_set_focus(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ System.out.println("focusHandler_on_set_focus");
+ return 0;
+}
+static long /*int*/ focusHandler_on_got_focus(long /*int*/ arg0, long /*int*/ arg1) {
+ System.out.println("focusHandler_on_got_focus");
+ return 0;
+}
+static long /*int*/ lifeSpanHandler_on_before_popup(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3, long /*int*/ arg4, long /*int*/ arg5, long /*int*/ arg6) {
+ System.out.println("lifeSpanHandler_on_before_popup");
+ return 0;
+}
+static long /*int*/ lifeSpanHandler_on_after_created(long /*int*/ arg0, long /*int*/ arg1) {
+ System.out.println("lifeSpanHandler_on_after_created");
+ return 0;
+}
+static long /*int*/ lifeSpanHandler_run_modal(long /*int*/ arg0, long /*int*/ arg1) {
+ System.out.println("lifeSpanHandler_run_modal");
+ return 0;
+}
+static long /*int*/ lifeSpanHandler_do_close(long /*int*/ arg0, long /*int*/ arg1) {
+ System.out.println("lifeSpanHandler_do_close");
+ return 0;
+}
+static long /*int*/ lifeSpanHandler_on_before_close(long /*int*/ arg0, long /*int*/ arg1) {
+ System.out.println("lifeSpanHandler_on_before_close");
+ return 0;
+}
+static long /*int*/ loadHandler_on_load_start(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ System.out.println("loadHandler_on_load_start");
+ return 0;
+}
+static long /*int*/ loadHandler_on_load_end(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3) {
+ System.out.println("loadHandler_on_load_end");
+ return 0;
+}
+static long /*int*/ loadHandler_on_load_error(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3, long /*int*/ arg4, long /*int*/ arg5) {
+ System.out.println("loadHandler_on_load_error");
+ return 0;
+}
+static long /*int*/ loadHandler_on_render_process_terminated(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ System.out.println("loadHandler_on_render_process_terminated");
+ return 0;
+}
+static long /*int*/ loadHandler_on_plugin_crashed(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ System.out.println("loadHandler_on_plugin_crashed");
+ return 0;
+}
+static long /*int*/ requestHandler_on_before_resource_load(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3) {
+ System.out.println("requestHandler_on_before_resource_load");
+ return 0;
+}
+static long /*int*/ requestHandler_get_resource_handler(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3) {
+ System.out.println("requestHandler_get_resource_handler");
+ return 0;
+}
+static long /*int*/ requestHandler_on_resource_redirect(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3, long /*int*/ arg4) {
+ System.out.println("requestHandler_on_resource_redirect");
+ return 0;
+}
+static long /*int*/ requestHandler_get_auth_credentials(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3, long /*int*/ arg4, long /*int*/ arg5, long /*int*/ arg6, long /*int*/ arg7, long /*int*/ arg8) {
+ System.out.println("requestHandler_get_auth_credentials");
+ return 0;
+}
+static long /*int*/ requestHandler_on_quota_request(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3, long /*int*/ arg4) {
+ System.out.println("requestHandler_on_quota_request");
+ return 0;
+}
+static long /*int*/ requestHandler_get_cookie_manager(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ System.out.println("requestHandler_get_cookie_manager");
+ return 0;
+}
+static long /*int*/ requestHandler_on_protocol_execution(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3) {
+ System.out.println("requestHandler_on_protocol_execution");
+ return 0;
+}
+static long /*int*/ requestHandler_on_before_plugin_load(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3, long /*int*/ arg4) {
+ System.out.println("requestHandler_on_before_plugin_load");
+ return 0;
+}
+static long /*int*/ resourceBundleHandler_get_data_resource(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2, long /*int*/ arg3) {
+ System.out.println("resourceBundleHandler_get_data_resource");
+ return 0;
+}
+static long /*int*/ resourceBundleHandler_get_localized_string(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ System.out.println("resourceBundleHandler_get_localized_string");
+ return 0;
+}
+
+static long /*int*/ createCEFString(String string) {
+ char[] chars = new char[string.length ()];
+ string.getChars (0, string.length (), chars, 0);
+ long /*int*/ result = CEF3.cef_string_userfree_alloc();
+ CEF3.cef_string_set(chars, chars.length, result, 1);
+ // TODO set its destructor function
+ return result;
+}
+
+public void create (Composite parent, int style) {
+ cef_main_args_t args = new cef_main_args_t();
+ args.instance = OS.GetModuleHandle(null);
+
+ CEFApp app = new CEFApp();
+ app.add_ref(); // TODO this should not be needed
+ int exitCode = CEF3.cef_execute_process(args, app.getAddress());
+ if (exitCode >= 0) {
+ return;
+ }
+
+ cef_settings_t settings = new cef_settings_t();
+ settings.size = cef_settings_t.sizeof;
+ settings.multi_threaded_message_loop = 1;
+ long /*int*/ subprocessPath = createCEFString("C:\\cef3-1180\\chromium\\src\\cef\\binary_distrib\\cef_binary_3.1180.None_windows\\Release\\cef3_subprocess.exe");
+ settings.browser_subprocess_path = new cef_string_t();
+ CEF3.memmove(settings.browser_subprocess_path, subprocessPath, cef_string_t.sizeof);
+
+ int rc = CEF3.cef_initialize(args, settings, app.getAddress());
+ if (rc == 0) {
+ return;
+ }
+
+ int extStyle = OS.WS_EX_NOINHERITLAYOUT;
+ if ((style & SWT.BORDER) != 0) extStyle |= OS.WS_EX_CLIENTEDGE;
+ if ((style & SWT.RIGHT_TO_LEFT) != 0) extStyle |= OS.WS_EX_LAYOUTRTL;
+ cef_window_info_t windowInfo = new cef_window_info_t();
+ windowInfo.ex_style = extStyle;
+ windowInfo.style = OS.WS_CHILD | OS.WS_VISIBLE | OS.WS_CLIPSIBLINGS;
+ windowInfo.x = OS.CW_USEDEFAULT;
+ windowInfo.width = OS.CW_USEDEFAULT;
+ windowInfo.ex_style = 0;
+ windowInfo.window_name = STRING_EMPTY;
+ windowInfo.parent_window = browser.handle;
+
+ cef_browser_settings_t browserSettings = new cef_browser_settings_t();
+ browserSettings.size = cef_browser_settings_t.sizeof;
+
+ long /*int*/ url = createCEFString("http://www.google.com/");
+ CEFClient client = new CEFClient();
+ client.add_ref();
+ rc = CEF3.cef_browser_host_create_browser(windowInfo, client.getAddress(), url, browserSettings);
+ if (rc == 0) {
+ return;
+ }
+
+
+
+
+
+ if (ExternalClass == 0) {
+ if (Device.DEBUG) {
+// int major = WebKitGTK.webkit_major_version ();
+// int minor = WebKitGTK.webkit_minor_version ();
+// int micro = WebKitGTK.webkit_micro_version ();
+// System.out.println("WebKit version " + major + "." + minor + "." + micro); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ }
+// JSClassDefinition jsClassDefinition = new JSClassDefinition ();
+// byte[] bytes = Converter.wcsToMbcs (null, CLASSNAME_EXTERNAL, true);
+// jsClassDefinition.className = C.malloc (bytes.length);
+// OS.memmove (jsClassDefinition.className, bytes, bytes.length);
+// jsClassDefinition.hasProperty = JSObjectHasPropertyProc.getAddress ();
+// jsClassDefinition.getProperty = JSObjectGetPropertyProc.getAddress ();
+// long /*int*/ classDefinitionPtr = C.malloc (JSClassDefinition.sizeof);
+// WebKitGTK.memmove (classDefinitionPtr, jsClassDefinition, JSClassDefinition.sizeof);
+// ExternalClass = WebKitGTK.JSClassCreate (classDefinitionPtr);
+//
+// bytes = Converter.wcsToMbcs (null, "POST", true); //$NON-NLS-1$
+// PostString = C.malloc (bytes.length);
+// C.memmove (PostString, bytes, bytes.length);
+ }
+
+// scrolledWindow = OS.gtk_scrolled_window_new (0, 0);
+// OS.gtk_scrolled_window_set_policy (scrolledWindow, OS.GTK_POLICY_AUTOMATIC, OS.GTK_POLICY_AUTOMATIC);
+// webView = WebKitGTK.webkit_web_view_new ();
+// webViewData = C.malloc (C.PTR_SIZEOF);
+// C.memmove (webViewData, new long /*int*/[] {webView}, C.PTR_SIZEOF);
+// OS.gtk_container_add (scrolledWindow, webView);
+// OS.gtk_container_add (browser.handle, scrolledWindow);
+// OS.gtk_widget_show (scrolledWindow);
+// OS.gtk_widget_show (webView);
+// OS.g_signal_connect (webView, WebKitGTK.close_web_view, Proc2.getAddress (), CLOSE_WEB_VIEW);
+// OS.g_signal_connect (webView, WebKitGTK.console_message, Proc5.getAddress (), CONSOLE_MESSAGE);
+// OS.g_signal_connect (webView, WebKitGTK.create_web_view, Proc3.getAddress (), CREATE_WEB_VIEW);
+// OS.g_signal_connect (webView, WebKitGTK.download_requested, Proc3.getAddress (), DOWNLOAD_REQUESTED);
+// OS.g_signal_connect (webView, WebKitGTK.hovering_over_link, Proc4.getAddress (), HOVERING_OVER_LINK);
+// OS.g_signal_connect (webView, WebKitGTK.mime_type_policy_decision_requested, Proc6.getAddress (), MIME_TYPE_POLICY_DECISION_REQUESTED);
+// OS.g_signal_connect (webView, WebKitGTK.navigation_policy_decision_requested, Proc6.getAddress (), NAVIGATION_POLICY_DECISION_REQUESTED);
+// OS.g_signal_connect (webView, WebKitGTK.notify_load_status, Proc3.getAddress (), NOTIFY_LOAD_STATUS);
+// OS.g_signal_connect (webView, WebKitGTK.notify_progress, Proc3.getAddress (), NOTIFY_PROGRESS);
+// OS.g_signal_connect (webView, WebKitGTK.notify_title, Proc3.getAddress (), NOTIFY_TITLE);
+// OS.g_signal_connect (webView, WebKitGTK.populate_popup, Proc3.getAddress (), POPULATE_POPUP);
+// OS.g_signal_connect (webView, WebKitGTK.resource_request_starting, Proc6.getAddress (), RESOURCE_REQUEST_STARTING);
+// OS.g_signal_connect (webView, WebKitGTK.status_bar_text_changed, Proc3.getAddress (), STATUS_BAR_TEXT_CHANGED);
+// OS.g_signal_connect (webView, WebKitGTK.web_view_ready, Proc2.getAddress (), WEB_VIEW_READY);
+// OS.g_signal_connect (webView, WebKitGTK.window_object_cleared, Proc5.getAddress (), WINDOW_OBJECT_CLEARED);
+
+ /* Callback to get events before WebKit receives and consumes them */
+// OS.g_signal_connect (webView, OS.button_press_event, JSDOMEventProc.getAddress (), 0);
+// OS.g_signal_connect (webView, OS.button_release_event, JSDOMEventProc.getAddress (), 0);
+// OS.g_signal_connect (webView, OS.key_press_event, JSDOMEventProc.getAddress (), 0);
+// OS.g_signal_connect (webView, OS.key_release_event, JSDOMEventProc.getAddress (), 0);
+// OS.g_signal_connect (webView, OS.scroll_event, JSDOMEventProc.getAddress (), 0);
+// OS.g_signal_connect (webView, OS.motion_notify_event, JSDOMEventProc.getAddress (), 0);
+
+ /*
+ * Callbacks to get the events not consumed by WebKit, and to block
+ * them so that they don't get propagated to the parent handle twice.
+ * This hook is set after WebKit and is therefore called after WebKit's
+ * handler because GTK dispatches events in their order of registration.
+ */
+// OS.g_signal_connect (scrolledWindow, OS.button_press_event, JSDOMEventProc.getAddress (), STOP_PROPOGATE);
+// OS.g_signal_connect (scrolledWindow, OS.button_release_event, JSDOMEventProc.getAddress (), STOP_PROPOGATE);
+// OS.g_signal_connect (scrolledWindow, OS.key_press_event, JSDOMEventProc.getAddress (), STOP_PROPOGATE);
+// OS.g_signal_connect (scrolledWindow, OS.key_release_event, JSDOMEventProc.getAddress (), STOP_PROPOGATE);
+// OS.g_signal_connect (scrolledWindow, OS.scroll_event, JSDOMEventProc.getAddress (), STOP_PROPOGATE);
+// OS.g_signal_connect (scrolledWindow, OS.motion_notify_event, JSDOMEventProc.getAddress (), STOP_PROPOGATE);
+
+// long /*int*/ settings = WebKitGTK.webkit_web_view_get_settings (webView);
+// OS.g_object_set (settings, WebKitGTK.javascript_can_open_windows_automatically, 1, 0);
+// OS.g_object_set (settings, WebKitGTK.enable_universal_access_from_file_uris, 1, 0);
+// byte[] bytes = Converter.wcsToMbcs (null, "UTF-8", true); // $NON-NLS-1$
+// OS.g_object_set (settings, WebKitGTK.default_encoding, bytes, 0);
+
+ Listener listener = new Listener () {
+ public void handleEvent (Event event) {
+ switch (event.type) {
+ case SWT.Dispose: {
+ /* make this handler run after other dispose listeners */
+ if (ignoreDispose) {
+ ignoreDispose = false;
+ break;
+ }
+ ignoreDispose = true;
+ browser.notifyListeners (event.type, event);
+ event.type = SWT.NONE;
+ onDispose (event);
+ break;
+ }
+ case SWT.FocusIn: {
+// OS.gtk_widget_grab_focus (webView);
+ break;
+ }
+ case SWT.Resize: {
+ onResize (event);
+ break;
+ }
+ }
+ }
+ };
+ browser.addListener (SWT.Dispose, listener);
+ browser.addListener (SWT.FocusIn, listener);
+ browser.addListener (SWT.KeyDown, listener);
+ browser.addListener (SWT.Resize, listener);
+
+ /*
+ * Ensure that our Authenticate listener is at the front of the signal
+ * queue by removing the default Authenticate listener, adding ours,
+ * and then re-adding the default listener.
+ */
+// long /*int*/ session = WebKitGTK.webkit_get_default_session ();
+// long /*int*/ originalAuth = WebKitGTK.soup_session_get_feature (session, WebKitGTK.webkit_soup_auth_dialog_get_type ());
+// WebKitGTK.soup_session_feature_detach (originalAuth, session);
+// OS.g_signal_connect (session, WebKitGTK.authenticate, Proc5.getAddress (), webView);
+// WebKitGTK.soup_session_feature_attach (originalAuth, session);
+
+ /*
+ * Check for proxy values set as documented java properties and update the
+ * session to use these values if needed.
+ */
+ String proxyHost = System.getProperty (PROPERTY_PROXYHOST);
+ String proxyPortString = System.getProperty (PROPERTY_PROXYPORT);
+ int port = -1;
+ if (proxyPortString != null) {
+ try {
+ int value = Integer.valueOf (proxyPortString).intValue ();
+ if (0 <= value && value <= MAX_PORT) port = value;
+ } catch (NumberFormatException e) {
+ /* do nothing, java property has non-integer value */
+ }
+ }
+ if (proxyHost != null || port != -1) {
+ if (!proxyHost.startsWith (PROTOCOL_HTTP)) {
+ proxyHost = PROTOCOL_HTTP + proxyHost;
+ }
+ proxyHost += ":" + port; //$NON-NLS-1$
+// bytes = Converter.wcsToMbcs (null, proxyHost, true);
+// long /*int*/ uri = WebKitGTK.soup_uri_new (bytes);
+// if (uri != 0) {
+// OS.g_object_set (session, WebKitGTK.SOUP_SESSION_PROXY_URI, uri, 0);
+// WebKitGTK.soup_uri_free (uri);
+// }
+ }
+
+ eventFunction = new BrowserFunction (browser, "HandleWebKitEvent") { //$NON-NLS-1$
+ public Object function(Object[] arguments) {
+ return handleEventFromFunction (arguments) ? Boolean.TRUE : Boolean.FALSE;
+ };
+ };
+
+ /*
+ * Bug in WebKitGTK. MouseOver/MouseLeave events are not consistently sent from
+ * the DOM when the mouse enters and exits the browser control, see
+ * https://bugs.webkit.org/show_bug.cgi?id=35246. As a workaround for sending
+ * MouseEnter/MouseExit events, swt's default mouse enter/exit mechanism is used,
+ * but in order to do this the Browser's default sub-window check behavior must
+ * be changed.
+ */
+ browser.setData (KEY_CHECK_SUBWINDOW, Boolean.FALSE);
+}
+
+void addEventHandlers (long /*int*/ web_view, boolean top) {
+ /*
+ * If JS is disabled (causes DOM events to not be delivered) then do not add event
+ * listeners here, DOM events will be inferred from received GDK events instead.
+ */
+ if (!jsEnabled) return;
+
+ if (top && IsWebKit14orNewer) {
+// long /*int*/ domDocument = WebKitGTK.webkit_web_view_get_dom_document (web_view);
+// if (domDocument != 0) {
+// WindowMappings.put (new LONG (domDocument), new LONG (web_view));
+// WebKitGTK.webkit_dom_event_target_add_event_listener (domDocument, WebKitGTK.dragstart, JSDOMEventProc.getAddress (), 0, SWT.DragDetect);
+// WebKitGTK.webkit_dom_event_target_add_event_listener (domDocument, WebKitGTK.keydown, JSDOMEventProc.getAddress (), 0, SWT.KeyDown);
+// WebKitGTK.webkit_dom_event_target_add_event_listener (domDocument, WebKitGTK.keypress, JSDOMEventProc.getAddress (), 0, SENTINEL_KEYPRESS);
+// WebKitGTK.webkit_dom_event_target_add_event_listener (domDocument, WebKitGTK.keyup, JSDOMEventProc.getAddress (), 0, SWT.KeyUp);
+// WebKitGTK.webkit_dom_event_target_add_event_listener (domDocument, WebKitGTK.mousedown, JSDOMEventProc.getAddress (), 0, SWT.MouseDown);
+// WebKitGTK.webkit_dom_event_target_add_event_listener (domDocument, WebKitGTK.mousemove, JSDOMEventProc.getAddress (), 0, SWT.MouseMove);
+// WebKitGTK.webkit_dom_event_target_add_event_listener (domDocument, WebKitGTK.mouseup, JSDOMEventProc.getAddress (), 0, SWT.MouseUp);
+// WebKitGTK.webkit_dom_event_target_add_event_listener (domDocument, WebKitGTK.mousewheel, JSDOMEventProc.getAddress (), 0, SWT.MouseWheel);
+//
+// /*
+// * The following two lines are intentionally commented because they cannot be used to
+// * consistently send MouseEnter/MouseExit events until https://bugs.webkit.org/show_bug.cgi?id=35246
+// * is fixed.
+// */
+// //WebKitGTK.webkit_dom_event_target_add_event_listener (domWindow, WebKitGTK.mouseover, JSDOMEventProc.getAddress (), 0, SWT.MouseEnter);
+// //WebKitGTK.webkit_dom_event_target_add_event_listener (domWindow, WebKitGTK.mouseout, JSDOMEventProc.getAddress (), 0, SWT.MouseExit);
+// }
+ return;
+ }
+
+ /* install the JS call-out to the registered BrowserFunction */
+ StringBuffer buffer = new StringBuffer ("window.SWTkeyhandler = function SWTkeyhandler(e) {"); //$NON-NLS-1$
+ buffer.append ("try {e.returnValue = HandleWebKitEvent(e.type, e.keyCode, e.charCode, e.altKey, e.ctrlKey, e.shiftKey, e.metaKey);} catch (e) {}};"); //$NON-NLS-1$
+ execute (buffer.toString ());
+ buffer = new StringBuffer ("window.SWTmousehandler = function SWTmousehandler(e) {"); //$NON-NLS-1$
+ buffer.append ("try {e.returnValue = HandleWebKitEvent(e.type, e.screenX, e.screenY, e.detail, e.button, e.altKey, e.ctrlKey, e.shiftKey, e.metaKey, e.relatedTarget != null);} catch (e) {}};"); //$NON-NLS-1$
+ execute (buffer.toString ());
+
+ if (top) {
+ /* DOM API is not available, so add listener to top-level document */
+ buffer = new StringBuffer ("document.addEventListener('keydown', SWTkeyhandler, true);"); //$NON-NLS-1$
+ buffer.append ("document.addEventListener('keypress', SWTkeyhandler, true);"); //$NON-NLS-1$
+ buffer.append ("document.addEventListener('keyup', SWTkeyhandler, true);"); //$NON-NLS-1$
+ buffer.append ("document.addEventListener('mousedown', SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ("document.addEventListener('mouseup', SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ("document.addEventListener('mousemove', SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ("document.addEventListener('mousewheel', SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ("document.addEventListener('dragstart', SWTmousehandler, true);"); //$NON-NLS-1$
+
+ /*
+ * The following two lines are intentionally commented because they cannot be used to
+ * consistently send MouseEnter/MouseExit events until https://bugs.webkit.org/show_bug.cgi?id=35246
+ * is fixed.
+ */
+ //buffer.append ("document.addEventListener('mouseover', SWTmousehandler, true);"); //$NON-NLS-1$
+ //buffer.append ("document.addEventListener('mouseout', SWTmousehandler, true);"); //$NON-NLS-1$
+
+ execute (buffer.toString ());
+ return;
+ }
+
+ /* add JS event listener in frames */
+ buffer = new StringBuffer ("for (var i = 0; i < frames.length; i++) {"); //$NON-NLS-1$
+ buffer.append ("frames[i].document.addEventListener('keydown', window.SWTkeyhandler, true);"); //$NON-NLS-1$
+ buffer.append ("frames[i].document.addEventListener('keypress', window.SWTkeyhandler, true);"); //$NON-NLS-1$
+ buffer.append ("frames[i].document.addEventListener('keyup', window.SWTkeyhandler, true);"); //$NON-NLS-1$
+ buffer.append ("frames[i].document.addEventListener('mousedown', window.SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ("frames[i].document.addEventListener('mouseup', window.SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ("frames[i].document.addEventListener('mousemove', window.SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ("frames[i].document.addEventListener('mouseover', window.SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ("frames[i].document.addEventListener('mouseout', window.SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ("frames[i].document.addEventListener('mousewheel', window.SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ("frames[i].document.addEventListener('dragstart', window.SWTmousehandler, true);"); //$NON-NLS-1$
+ buffer.append ('}');
+ execute (buffer.toString ());
+}
+
+public boolean back () {
+// if (WebKitGTK.webkit_web_view_can_go_back (webView) == 0) return false;
+// WebKitGTK.webkit_web_view_go_back (webView);
+ return true;
+}
+
+public boolean close () {
+ return close (true);
+}
+
+boolean close (boolean showPrompters) {
+ if (!jsEnabled) return true;
+
+ String message1 = Compatibility.getMessage("SWT_OnBeforeUnload_Message1"); // $NON-NLS-1$
+ String message2 = Compatibility.getMessage("SWT_OnBeforeUnload_Message2"); // $NON-NLS-1$
+ String functionName = EXECUTE_ID + "CLOSE"; // $NON-NLS-1$
+ StringBuffer buffer = new StringBuffer ("function "); // $NON-NLS-1$
+ buffer.append (functionName);
+ buffer.append ("(win) {\n"); // $NON-NLS-1$
+ buffer.append ("var fn = win.onbeforeunload; if (fn != null) {try {var str = fn(); "); // $NON-NLS-1$
+ if (showPrompters) {
+ buffer.append ("if (str != null) { "); // $NON-NLS-1$
+ buffer.append ("var result = confirm('"); // $NON-NLS-1$
+ buffer.append (message1);
+ buffer.append ("\\n\\n'+str+'\\n\\n"); // $NON-NLS-1$
+ buffer.append (message2);
+ buffer.append ("');"); // $NON-NLS-1$
+ buffer.append ("if (!result) return false;}"); // $NON-NLS-1$
+ }
+ buffer.append ("} catch (e) {}}"); // $NON-NLS-1$
+ buffer.append ("try {for (var i = 0; i < win.frames.length; i++) {var result = "); // $NON-NLS-1$
+ buffer.append (functionName);
+ buffer.append ("(win.frames[i]); if (!result) return false;}} catch (e) {} return true;"); // $NON-NLS-1$
+ buffer.append ("\n};"); // $NON-NLS-1$
+ execute (buffer.toString ());
+
+ Boolean result = (Boolean)evaluate ("return " + functionName +"(window);"); // $NON-NLS-1$ // $NON-NLS-2$
+ if (result == null) return false;
+ return result.booleanValue ();
+}
+
+public boolean execute (String script) {
+// long /*int*/ frame = WebKitGTK.webkit_web_view_get_main_frame (webView);
+// long /*int*/ context = WebKitGTK.webkit_web_frame_get_global_context (frame);
+//
+// byte[] bytes = null;
+// try {
+// bytes = (script + '\0').getBytes (CHARSET_UTF8); //$NON-NLS-1$
+// } catch (UnsupportedEncodingException e) {
+// bytes = Converter.wcsToMbcs (null, script, true);
+// }
+// long /*int*/ scriptString = WebKitGTK.JSStringCreateWithUTF8CString (bytes);
+//
+// try {
+// bytes = (getUrl () + '\0').getBytes (CHARSET_UTF8); //$NON-NLS-1$
+// } catch (UnsupportedEncodingException e) {
+// bytes = Converter.wcsToMbcs (null, getUrl (), true);
+// }
+// long /*int*/ urlString = WebKitGTK.JSStringCreateWithUTF8CString (bytes);
+//
+// long /*int*/ result = WebKitGTK.JSEvaluateScript (context, scriptString, 0, urlString, 0, null);
+// WebKitGTK.JSStringRelease (urlString);
+// WebKitGTK.JSStringRelease (scriptString);
+// return result != 0;
+ return false;
+}
+
+public boolean forward () {
+// if (WebKitGTK.webkit_web_view_can_go_forward (webView) == 0) return false;
+// WebKitGTK.webkit_web_view_go_forward (webView);
+ return true;
+}
+
+public String getBrowserType () {
+ return "webkit"; //$NON-NLS-1$
+}
+
+public String getText () {
+// long /*int*/ frame = WebKitGTK.webkit_web_view_get_main_frame (webView);
+// long /*int*/ source = WebKitGTK.webkit_web_frame_get_data_source (frame);
+// if (source == 0) return ""; //$NON-NLS-1$
+// long /*int*/ data = WebKitGTK.webkit_web_data_source_get_data (source);
+// if (data == 0) return ""; //$NON-NLS-1$
+//
+// long /*int*/ encoding = WebKitGTK.webkit_web_data_source_get_encoding (source);
+// int length = OS.strlen (encoding);
+// byte[] bytes = new byte [length];
+// OS.memmove (bytes, encoding, length);
+// String encodingString = new String (Converter.mbcsToWcs (null, bytes));
+//
+// length = OS.GString_len (data);
+// bytes = new byte[length];
+// long /*int*/ string = OS.GString_str (data);
+// C.memmove (bytes, string, length);
+//
+// try {
+// return new String (bytes, encodingString);
+// } catch (UnsupportedEncodingException e) {
+// }
+// return new String (Converter.mbcsToWcs (null, bytes));
+ return null;
+}
+
+public String getUrl () {
+// long /*int*/ uri = WebKitGTK.webkit_web_view_get_uri (webView);
+//
+// /* WebKit auto-navigates to about:blank at startup */
+// if (uri == 0) return ABOUT_BLANK;
+//
+// int length = OS.strlen (uri);
+// byte[] bytes = new byte[length];
+// OS.memmove (bytes, uri, length);
+//
+// String url = new String (Converter.mbcsToWcs (null, bytes));
+// /*
+// * If the URI indicates that the page is being rendered from memory
+// * (via setText()) then set it to about:blank to be consistent with IE.
+// */
+// if (url.equals (URI_FILEROOT)) {
+// url = ABOUT_BLANK;
+// } else {
+// length = URI_FILEROOT.length ();
+// if (url.startsWith (URI_FILEROOT) && url.charAt (length) == '#') {
+// url = ABOUT_BLANK + url.substring (length);
+// }
+// }
+// return url;
+ return null;
+}
+
+boolean handleDOMEvent (long /*int*/ event, int type) {
+ /*
+ * This method handles JS events that are received through the DOM
+ * listener API that was introduced in WebKitGTK 1.4.
+ */
+ String typeString = null;
+ boolean isMouseEvent = false;
+ switch (type) {
+ case SWT.DragDetect: {
+ typeString = "dragstart"; //$NON-NLS-1$
+ isMouseEvent = true;
+ break;
+ }
+ case SWT.MouseDown: {
+ typeString = "mousedown"; //$NON-NLS-1$
+ isMouseEvent = true;
+ break;
+ }
+ case SWT.MouseMove: {
+ typeString = "mousemove"; //$NON-NLS-1$
+ isMouseEvent = true;
+ break;
+ }
+ case SWT.MouseUp: {
+ typeString = "mouseup"; //$NON-NLS-1$
+ isMouseEvent = true;
+ break;
+ }
+ case SWT.MouseWheel: {
+ typeString = "mousewheel"; //$NON-NLS-1$
+ isMouseEvent = true;
+ break;
+ }
+ case SWT.KeyDown: {
+ typeString = "keydown"; //$NON-NLS-1$
+ break;
+ }
+ case SWT.KeyUp: {
+ typeString = "keyup"; //$NON-NLS-1$
+ break;
+ }
+ case SENTINEL_KEYPRESS: {
+ typeString = "keypress"; //$NON-NLS-1$
+ break;
+ }
+ }
+
+// if (isMouseEvent) {
+// int screenX = (int)WebKitGTK.webkit_dom_mouse_event_get_screen_x (event);
+// int screenY = (int)WebKitGTK.webkit_dom_mouse_event_get_screen_y (event);
+// int button = (int)WebKitGTK.webkit_dom_mouse_event_get_button (event) + 1;
+// boolean altKey = WebKitGTK.webkit_dom_mouse_event_get_alt_key (event) != 0;
+// boolean ctrlKey = WebKitGTK.webkit_dom_mouse_event_get_ctrl_key (event) != 0;
+// boolean shiftKey = WebKitGTK.webkit_dom_mouse_event_get_shift_key (event) != 0;
+// boolean metaKey = WebKitGTK.webkit_dom_mouse_event_get_meta_key (event) != 0;
+// int detail = (int)WebKitGTK.webkit_dom_ui_event_get_detail (event);
+// boolean hasRelatedTarget = false; //WebKitGTK.webkit_dom_mouse_event_get_related_target (event) != 0;
+// return handleMouseEvent(typeString, screenX, screenY, detail, button, altKey, ctrlKey, shiftKey, metaKey, hasRelatedTarget);
+// }
+
+ /* key event */
+// int keyCode = (int)WebKitGTK.webkit_dom_ui_event_get_key_code (event);
+// int charCode = (int)WebKitGTK.webkit_dom_ui_event_get_char_code (event);
+// boolean altKey = WebKitGTK.webkit_dom_mouse_event_get_alt_key (event) != 0;
+// boolean ctrlKey = WebKitGTK.webkit_dom_mouse_event_get_ctrl_key (event) != 0;
+// boolean shiftKey = WebKitGTK.webkit_dom_mouse_event_get_shift_key (event) != 0;
+// boolean metaKey = WebKitGTK.webkit_dom_mouse_event_get_meta_key (event) != 0;
+// return handleKeyEvent(typeString, keyCode, charCode, altKey, ctrlKey, shiftKey, metaKey);
+ return true;
+}
+
+boolean handleEventFromFunction (Object[] arguments) {
+ /*
+ * Prior to WebKitGTK 1.4 there was no API for hooking DOM listeners.
+ * As a workaround, eventFunction was introduced to capture JS events
+ * and report them back to the java side. This method handles these
+ * events by extracting their arguments and passing them to the
+ * handleKeyEvent()/handleMouseEvent() event handler methods.
+ */
+
+ /*
+ * The arguments for key events are:
+ * argument 0: type (String)
+ * argument 1: keyCode (Double)
+ * argument 2: charCode (Double)
+ * argument 3: altKey (Boolean)
+ * argument 4: ctrlKey (Boolean)
+ * argument 5: shiftKey (Boolean)
+ * argument 6: metaKey (Boolean)
+ * returns doit
+ *
+ * The arguments for mouse events are:
+ * argument 0: type (String)
+ * argument 1: screenX (Double)
+ * argument 2: screenY (Double)
+ * argument 3: detail (Double)
+ * argument 4: button (Double)
+ * argument 5: altKey (Boolean)
+ * argument 6: ctrlKey (Boolean)
+ * argument 7: shiftKey (Boolean)
+ * argument 8: metaKey (Boolean)
+ * argument 9: hasRelatedTarget (Boolean)
+ * returns doit
+ */
+
+ String type = (String)arguments[0];
+ if (type.equals (DOMEVENT_KEYDOWN) || type.equals (DOMEVENT_KEYPRESS) || type.equals (DOMEVENT_KEYUP)) {
+ return handleKeyEvent(
+ type,
+ ((Double)arguments[1]).intValue (),
+ ((Double)arguments[2]).intValue (),
+ ((Boolean)arguments[3]).booleanValue (),
+ ((Boolean)arguments[4]).booleanValue (),
+ ((Boolean)arguments[5]).booleanValue (),
+ ((Boolean)arguments[6]).booleanValue ());
+ }
+
+ return handleMouseEvent(
+ type,
+ ((Double)arguments[1]).intValue (),
+ ((Double)arguments[2]).intValue (),
+ ((Double)arguments[3]).intValue (),
+ ((Double)arguments[4]).intValue () + 1,
+ ((Boolean)arguments[5]).booleanValue (),
+ ((Boolean)arguments[6]).booleanValue (),
+ ((Boolean)arguments[7]).booleanValue (),
+ ((Boolean)arguments[8]).booleanValue (),
+ ((Boolean)arguments[9]).booleanValue ());
+}
+
+boolean handleKeyEvent (String type, int keyCode, int charCode, boolean altKey, boolean ctrlKey, boolean shiftKey, boolean metaKey) {
+ if (type.equals (DOMEVENT_KEYDOWN)) {
+ keyCode = translateKey (keyCode);
+ lastKeyCode = keyCode;
+ switch (keyCode) {
+ case SWT.SHIFT:
+ case SWT.CONTROL:
+ case SWT.ALT:
+ case SWT.CAPS_LOCK:
+ case SWT.NUM_LOCK:
+ case SWT.SCROLL_LOCK:
+ case SWT.COMMAND:
+ case SWT.ESC:
+ case SWT.TAB:
+ case SWT.PAUSE:
+ case SWT.BS:
+ case SWT.INSERT:
+ case SWT.DEL:
+ case SWT.HOME:
+ case SWT.END:
+ case SWT.PAGE_UP:
+ case SWT.PAGE_DOWN:
+ case SWT.ARROW_DOWN:
+ case SWT.ARROW_UP:
+ case SWT.ARROW_LEFT:
+ case SWT.ARROW_RIGHT:
+ case SWT.F1:
+ case SWT.F2:
+ case SWT.F3:
+ case SWT.F4:
+ case SWT.F5:
+ case SWT.F6:
+ case SWT.F7:
+ case SWT.F8:
+ case SWT.F9:
+ case SWT.F10:
+ case SWT.F11:
+ case SWT.F12: {
+ /* keypress events will not be received for these keys, so send KeyDowns for them now */
+
+ Event keyEvent = new Event ();
+ keyEvent.widget = browser;
+ keyEvent.type = type.equals (DOMEVENT_KEYDOWN) ? SWT.KeyDown : SWT.KeyUp;
+ keyEvent.keyCode = keyCode;
+ switch (keyCode) {
+ case SWT.BS: keyEvent.character = SWT.BS; break;
+ case SWT.DEL: keyEvent.character = SWT.DEL; break;
+ case SWT.ESC: keyEvent.character = SWT.ESC; break;
+ case SWT.TAB: keyEvent.character = SWT.TAB; break;
+ }
+ lastCharCode = keyEvent.character;
+ keyEvent.stateMask = (altKey ? SWT.ALT : 0) | (ctrlKey ? SWT.CTRL : 0) | (shiftKey ? SWT.SHIFT : 0) | (metaKey ? SWT.COMMAND : 0);
+ keyEvent.stateMask &= ~keyCode; /* remove current keydown if it's a state key */
+ final int stateMask = keyEvent.stateMask;
+ if (!sendKeyEvent (keyEvent) || browser.isDisposed ()) return false;
+
+ if (browser.isFocusControl ()) {
+ if (keyCode == SWT.TAB && (stateMask & (SWT.CTRL | SWT.ALT)) == 0) {
+ browser.getDisplay ().asyncExec (new Runnable () {
+ public void run () {
+ if (browser.isDisposed ()) return;
+ if (browser.getDisplay ().getFocusControl () == null) {
+ int traversal = (stateMask & SWT.SHIFT) != 0 ? SWT.TRAVERSE_TAB_PREVIOUS : SWT.TRAVERSE_TAB_NEXT;
+ browser.traverse (traversal);
+ }
+ }
+ });
+ }
+ }
+ break;
+ }
+ }
+ return true;
+ }
+
+ if (type.equals (DOMEVENT_KEYPRESS)) {
+ /*
+ * if keydown could not determine a keycode for this key then it's a
+ * key for which key events are not sent (eg.- the Windows key)
+ */
+ if (lastKeyCode == 0) return true;
+
+ lastCharCode = charCode;
+ if (ctrlKey && (0 <= lastCharCode && lastCharCode <= 0x7F)) {
+ if ('a' <= lastCharCode && lastCharCode <= 'z') lastCharCode -= 'a' - 'A';
+ if (64 <= lastCharCode && lastCharCode <= 95) lastCharCode -= 64;
+ }
+
+ Event keyEvent = new Event ();
+ keyEvent.widget = browser;
+ keyEvent.type = SWT.KeyDown;
+ keyEvent.keyCode = lastKeyCode;
+ keyEvent.character = (char)lastCharCode;
+ keyEvent.stateMask = (altKey ? SWT.ALT : 0) | (ctrlKey ? SWT.CTRL : 0) | (shiftKey ? SWT.SHIFT : 0) | (metaKey ? SWT.COMMAND : 0);
+ return sendKeyEvent (keyEvent) && !browser.isDisposed ();
+ }
+
+ /* keyup */
+
+ keyCode = translateKey (keyCode);
+ if (keyCode == 0) {
+ /* indicates a key for which key events are not sent */
+ return true;
+ }
+ if (keyCode != lastKeyCode) {
+ /* keyup does not correspond to the last keydown */
+ lastKeyCode = keyCode;
+ lastCharCode = 0;
+ }
+
+ Event keyEvent = new Event ();
+ keyEvent.widget = browser;
+ keyEvent.type = SWT.KeyUp;
+ keyEvent.keyCode = lastKeyCode;
+ keyEvent.character = (char)lastCharCode;
+ keyEvent.stateMask = (altKey ? SWT.ALT : 0) | (ctrlKey ? SWT.CTRL : 0) | (shiftKey ? SWT.SHIFT : 0) | (metaKey ? SWT.COMMAND : 0);
+ switch (lastKeyCode) {
+ case SWT.SHIFT:
+ case SWT.CONTROL:
+ case SWT.ALT:
+ case SWT.COMMAND: {
+ keyEvent.stateMask |= lastKeyCode;
+ }
+ }
+ browser.notifyListeners (keyEvent.type, keyEvent);
+ lastKeyCode = lastCharCode = 0;
+ return keyEvent.doit && !browser.isDisposed ();
+}
+
+boolean handleMouseEvent (String type, int screenX, int screenY, int detail, int button, boolean altKey, boolean ctrlKey, boolean shiftKey, boolean metaKey, boolean hasRelatedTarget) {
+ /*
+ * MouseOver and MouseOut events are fired any time the mouse enters or exits
+ * any element within the Browser. To ensure that SWT events are only
+ * fired for mouse movements into or out of the Browser, do not fire an
+ * event if there is a related target element.
+ */
+
+ /*
+ * The following is intentionally commented because MouseOver and MouseOut events
+ * are not being hooked until https://bugs.webkit.org/show_bug.cgi?id=35246 is fixed.
+ */
+ //if (type.equals (DOMEVENT_MOUSEOVER) || type.equals (DOMEVENT_MOUSEOUT)) {
+ // if (((Boolean)arguments[9]).booleanValue ()) return true;
+ //}
+
+ /*
+ * The position of mouse events is received in screen-relative coordinates
+ * in order to handle pages with frames, since frames express their event
+ * coordinates relative to themselves rather than relative to their top-
+ * level page. Convert screen-relative coordinates to be browser-relative.
+ */
+ Point position = new Point (screenX, screenY);
+ position = browser.getDisplay ().map (null, browser, position);
+
+ Event mouseEvent = new Event ();
+ mouseEvent.widget = browser;
+ mouseEvent.x = position.x;
+ mouseEvent.y = position.y;
+ int mask = (altKey ? SWT.ALT : 0) | (ctrlKey ? SWT.CTRL : 0) | (shiftKey ? SWT.SHIFT : 0) | (metaKey ? SWT.COMMAND : 0);
+ mouseEvent.stateMask = mask;
+
+ if (type.equals (DOMEVENT_MOUSEDOWN)) {
+ mouseEvent.type = SWT.MouseDown;
+ mouseEvent.count = detail;
+ mouseEvent.button = button;
+ browser.notifyListeners (mouseEvent.type, mouseEvent);
+ if (browser.isDisposed ()) return true;
+ if (detail == 2) {
+ mouseEvent = new Event ();
+ mouseEvent.type = SWT.MouseDoubleClick;
+ mouseEvent.widget = browser;
+ mouseEvent.x = position.x;
+ mouseEvent.y = position.y;
+ mouseEvent.stateMask = mask;
+ mouseEvent.count = detail;
+ mouseEvent.button = button;
+ browser.notifyListeners (mouseEvent.type, mouseEvent);
+ }
+ return true;
+ }
+
+ if (type.equals (DOMEVENT_MOUSEUP)) {
+ mouseEvent.type = SWT.MouseUp;
+ mouseEvent.count = detail;
+ mouseEvent.button = button;
+ } else if (type.equals (DOMEVENT_MOUSEMOVE)) {
+ mouseEvent.type = SWT.MouseMove;
+ } else if (type.equals (DOMEVENT_MOUSEWHEEL)) {
+ mouseEvent.type = SWT.MouseWheel;
+ mouseEvent.count = detail;
+
+ /*
+ * The following is intentionally commented because MouseOver and MouseOut events
+ * are not being hooked until https://bugs.webkit.org/show_bug.cgi?id=35246 is fixed.
+ */
+ //} else if (type.equals (DOMEVENT_MOUSEOVER)) {
+ // mouseEvent.type = SWT.MouseEnter;
+ //} else if (type.equals (DOMEVENT_MOUSEOUT)) {
+ // mouseEvent.type = SWT.MouseExit;
+
+ } else if (type.equals (DOMEVENT_DRAGSTART)) {
+ mouseEvent.type = SWT.DragDetect;
+ mouseEvent.button = button;
+ switch (mouseEvent.button) {
+ case 1: mouseEvent.stateMask |= SWT.BUTTON1; break;
+ case 2: mouseEvent.stateMask |= SWT.BUTTON2; break;
+ case 3: mouseEvent.stateMask |= SWT.BUTTON3; break;
+ case 4: mouseEvent.stateMask |= SWT.BUTTON4; break;
+ case 5: mouseEvent.stateMask |= SWT.BUTTON5; break;
+ }
+ /*
+ * Bug in WebKitGTK 1.2.x. Dragging an image quickly and repeatedly can
+ * cause WebKitGTK to take the mouse grab indefinitely and lock up the
+ * display, see https://bugs.webkit.org/show_bug.cgi?id=32840. The
+ * workaround is to veto all drag attempts if using WebKitGTK 1.2.x.
+ */
+ if (!IsWebKit14orNewer) {
+ browser.notifyListeners (mouseEvent.type, mouseEvent);
+ return false;
+ }
+ }
+
+ browser.notifyListeners (mouseEvent.type, mouseEvent);
+ return true;
+}
+
+long /*int*/ handleLoadCommitted (long /*int*/ uri, boolean top) {
+// int length = OS.strlen (uri);
+// byte[] bytes = new byte[length];
+// OS.memmove (bytes, uri, length);
+// String url = new String (Converter.mbcsToWcs (null, bytes));
+// /*
+// * If the URI indicates that the page is being rendered from memory
+// * (via setText()) then set it to about:blank to be consistent with IE.
+// */
+// if (url.equals (URI_FILEROOT)) {
+// url = ABOUT_BLANK;
+// } else {
+// length = URI_FILEROOT.length ();
+// if (url.startsWith (URI_FILEROOT) && url.charAt (length) == '#') {
+// url = ABOUT_BLANK + url.substring (length);
+// }
+// }
+
+ /*
+ * Each invocation of setText() causes webkit_notify_load_status to be invoked
+ * twice, once for the initial navigate to about:blank, and once for the auto-navigate
+ * to about:blank that WebKit does when webkit_web_view_load_string is invoked. If
+ * this is the first webkit_notify_load_status callback received for a setText()
+ * invocation then do not send any events or re-install registered BrowserFunctions.
+ */
+// if (top && url.startsWith(ABOUT_BLANK) && htmlBytes != null) return 0;
+
+// LocationEvent event = new LocationEvent (browser);
+// event.display = browser.getDisplay ();
+// event.widget = browser;
+// event.location = url;
+// event.top = top;
+// for (int i = 0; i < locationListeners.length; i++) {
+// locationListeners[i].changed (event);
+// }
+ return 0;
+}
+
+long /*int*/ handleLoadFinished (long /*int*/ uri, boolean top) {
+// int length = OS.strlen (uri);
+// byte[] bytes = new byte[length];
+// OS.memmove (bytes, uri, length);
+// String url = new String (Converter.mbcsToWcs (null, bytes));
+// /*
+// * If the URI indicates that the page is being rendered from memory
+// * (via setText()) then set it to about:blank to be consistent with IE.
+// */
+// if (url.equals (URI_FILEROOT)) {
+// url = ABOUT_BLANK;
+// } else {
+// length = URI_FILEROOT.length ();
+// if (url.startsWith (URI_FILEROOT) && url.charAt (length) == '#') {
+// url = ABOUT_BLANK + url.substring (length);
+// }
+// }
+
+ /*
+ * If htmlBytes is not null then there is html from a previous setText() call
+ * waiting to be set into the about:blank page once it has completed loading.
+ */
+// if (top && htmlBytes != null) {
+// if (url.startsWith(ABOUT_BLANK)) {
+// loadingText = true;
+// byte[] mimeType = Converter.wcsToMbcs (null, "text/html", true); //$NON-NLS-1$
+// byte[] encoding = Converter.wcsToMbcs (null, CHARSET_UTF8, true); //$NON-NLS-1$
+// byte[] uriBytes;
+// if (untrustedText) {
+// uriBytes = Converter.wcsToMbcs (null, ABOUT_BLANK, true);
+// } else {
+// uriBytes = Converter.wcsToMbcs (null, URI_FILEROOT, true);
+// }
+// WebKitGTK.webkit_web_view_load_string (webView, htmlBytes, mimeType, encoding, uriBytes);
+// htmlBytes = null;
+// }
+// }
+
+ /*
+ * The webkit_web_view_load_string() invocation above will trigger a second
+ * webkit_web_view_load_string callback when it is completed. Wait for this
+ * second callback to come before sending the title or completed events.
+ */
+// if (!loadingText) {
+// /*
+// * To be consistent with other platforms a title event should be fired
+// * when a top-level page has completed loading. A page with a <title>
+// * tag will do this automatically when the notify::title signal is received.
+// * However a page without a <title> tag will not do this by default, so fire
+// * the event here with the page's url as the title.
+// */
+// if (top) {
+// long /*int*/ frame = WebKitGTK.webkit_web_view_get_main_frame (webView);
+// long /*int*/ title = WebKitGTK.webkit_web_frame_get_title (frame);
+// if (title == 0) {
+// TitleEvent newEvent = new TitleEvent (browser);
+// newEvent.display = browser.getDisplay ();
+// newEvent.widget = browser;
+// newEvent.title = url;
+// for (int i = 0; i < titleListeners.length; i++) {
+// titleListeners[i].changed (newEvent);
+// }
+// if (browser.isDisposed ()) return 0;
+// }
+// }
+//
+// ProgressEvent progress = new ProgressEvent (browser);
+// progress.display = browser.getDisplay ();
+// progress.widget = browser;
+// progress.current = MAX_PROGRESS;
+// progress.total = MAX_PROGRESS;
+// for (int i = 0; i < progressListeners.length; i++) {
+// progressListeners[i].completed (progress);
+// }
+// }
+// loadingText = false;
+
+ return 0;
+}
+
+public boolean isBackEnabled () {
+ //return WebKitGTK.webkit_web_view_can_go_back (webView) != 0;
+ return false;
+}
+
+public boolean isForwardEnabled () {
+ //return WebKitGTK.webkit_web_view_can_go_forward (webView) != 0;
+ return false;
+}
+
+void onDispose (Event e) {
+ /* Browser could have been disposed by one of the Dispose listeners */
+ if (!browser.isDisposed()) {
+ /* invoke onbeforeunload handlers */
+ if (!browser.isClosing) {
+ close (false);
+ }
+ }
+
+ Enumeration elements = functions.elements ();
+ while (elements.hasMoreElements ()) {
+ ((BrowserFunction)elements.nextElement ()).dispose (false);
+ }
+ functions = null;
+
+ if (eventFunction != null) {
+ eventFunction.dispose (false);
+ eventFunction = null;
+ }
+
+ C.free (webViewData);
+ postData = null;
+ headers = null;
+ htmlBytes = null;
+}
+
+void onResize (Event e) {
+// Rectangle rect = browser.getClientArea ();
+// OS.gtk_widget_set_size_request (scrolledWindow, rect.width, rect.height);
+}
+
+void openDownloadWindow (final long /*int*/ webkitDownload) {
+ final Shell shell = new Shell ();
+ String msg = Compatibility.getMessage ("SWT_FileDownload"); //$NON-NLS-1$
+ shell.setText (msg);
+ GridLayout gridLayout = new GridLayout ();
+ gridLayout.marginHeight = 15;
+ gridLayout.marginWidth = 15;
+ gridLayout.verticalSpacing = 20;
+ shell.setLayout (gridLayout);
+
+// long /*int*/ name = WebKitGTK.webkit_download_get_suggested_filename (webkitDownload);
+// int length = OS.strlen (name);
+// byte[] bytes = new byte[length];
+// OS.memmove (bytes, name, length);
+// String nameString = new String (Converter.mbcsToWcs (null, bytes));
+// long /*int*/ url = WebKitGTK.webkit_download_get_uri (webkitDownload);
+// length = OS.strlen (url);
+// bytes = new byte[length];
+// OS.memmove (bytes, url, length);
+// String urlString = new String (Converter.mbcsToWcs (null, bytes));
+// msg = Compatibility.getMessage ("SWT_Download_Location", new Object[] {nameString, urlString}); //$NON-NLS-1$
+// Label nameLabel = new Label (shell, SWT.WRAP);
+// nameLabel.setText (msg);
+// GridData data = new GridData ();
+// Monitor monitor = browser.getMonitor ();
+// int maxWidth = monitor.getBounds ().width / 2;
+// int width = nameLabel.computeSize (SWT.DEFAULT, SWT.DEFAULT).x;
+// data.widthHint = Math.min (width, maxWidth);
+// data.horizontalAlignment = GridData.FILL;
+// data.grabExcessHorizontalSpace = true;
+// nameLabel.setLayoutData (data);
+
+// final Label statusLabel = new Label (shell, SWT.NONE);
+// statusLabel.setText (Compatibility.getMessage ("SWT_Download_Started")); //$NON-NLS-1$
+// data = new GridData (GridData.FILL_BOTH);
+// statusLabel.setLayoutData (data);
+
+// final Button cancel = new Button (shell, SWT.PUSH);
+// cancel.setText (Compatibility.getMessage ("SWT_Cancel")); //$NON-NLS-1$
+// data = new GridData ();
+// data.horizontalAlignment = GridData.CENTER;
+// cancel.setLayoutData (data);
+// final Listener cancelListener = new Listener () {
+// public void handleEvent (Event event) {
+// WebKitGTK.webkit_download_cancel (webkitDownload);
+// }
+// };
+// cancel.addListener (SWT.Selection, cancelListener);
+
+// OS.g_object_ref (webkitDownload);
+// final Display display = browser.getDisplay ();
+// final int INTERVAL = 500;
+// display.timerExec (INTERVAL, new Runnable () {
+// public void run () {
+// int status = WebKitGTK.webkit_download_get_status (webkitDownload);
+// if (shell.isDisposed () || status == WebKitGTK.WEBKIT_DOWNLOAD_STATUS_FINISHED || status == WebKitGTK.WEBKIT_DOWNLOAD_STATUS_CANCELLED) {
+// shell.dispose ();
+// display.timerExec (-1, this);
+// OS.g_object_unref (webkitDownload);
+// return;
+// }
+// if (status == WebKitGTK.WEBKIT_DOWNLOAD_STATUS_ERROR) {
+// statusLabel.setText (Compatibility.getMessage ("SWT_Download_Error")); //$NON-NLS-1$
+// display.timerExec (-1, this);
+// OS.g_object_unref (webkitDownload);
+// cancel.removeListener (SWT.Selection, cancelListener);
+// cancel.addListener (SWT.Selection, new Listener () {
+// public void handleEvent (Event event) {
+// shell.dispose ();
+// }
+// });
+// return;
+// }
+//
+// long current = WebKitGTK.webkit_download_get_current_size (webkitDownload) / 1024L;
+// long total = WebKitGTK.webkit_download_get_total_size (webkitDownload) / 1024L;
+// String message = Compatibility.getMessage ("SWT_Download_Status", new Object[] {new Long(current), new Long(total)}); //$NON-NLS-1$
+// statusLabel.setText (message);
+// display.timerExec (INTERVAL, this);
+// }
+// });
+//
+// shell.pack ();
+// shell.open ();
+}
+
+public void refresh () {
+// WebKitGTK.webkit_web_view_reload (webView);
+}
+
+public boolean setText (String html, boolean trusted) {
+ /* convert the String containing HTML to an array of bytes with UTF-8 data */
+// byte[] bytes = null;
+// try {
+// bytes = (html + '\0').getBytes (CHARSET_UTF8); //$NON-NLS-1$
+// } catch (UnsupportedEncodingException e) {
+// bytes = Converter.wcsToMbcs (null, html, true);
+// }
+//
+// /*
+// * If this.htmlBytes is not null then the about:blank page is already being loaded,
+// * so no navigate is required. Just set the html that is to be shown.
+// */
+// boolean blankLoading = htmlBytes != null;
+// htmlBytes = bytes;
+// untrustedText = !trusted;
+// if (blankLoading) return true;
+//
+// byte[] uriBytes = Converter.wcsToMbcs (null, ABOUT_BLANK, true);
+// WebKitGTK.webkit_web_view_load_uri (webView, uriBytes);
+ return true;
+}
+
+public boolean setUrl (String url, String postData, String[] headers) {
+// this.postData = postData;
+// this.headers = headers;
+
+ /*
+ * WebKitGTK attempts to open the exact url string that is passed to it and
+ * will not infer a protocol if it's not specified. Detect the case of an
+ * invalid URL string and try to fix it by prepending an appropriate protocol.
+ */
+// try {
+// new URL(url);
+// } catch (MalformedURLException e) {
+// String testUrl = null;
+// if (url.charAt (0) == SEPARATOR_FILE) {
+// /* appears to be a local file */
+// testUrl = PROTOCOL_FILE + url;
+// } else {
+// testUrl = PROTOCOL_HTTP + url;
+// }
+// try {
+// new URL (testUrl);
+// url = testUrl; /* adding the protocol made the url valid */
+// } catch (MalformedURLException e2) {
+// /* adding the protocol did not make the url valid, so do nothing */
+// }
+// }
+
+ /*
+ * Feature of WebKit. The user-agent header value cannot be overridden
+ * by changing it in the resource request. The workaround is to detect
+ * here whether the user-agent is being overridden, and if so, temporarily
+ * set the value on the WebView when initiating the load request and then
+ * remove it afterwards.
+ */
+// long /*int*/ settings = WebKitGTK.webkit_web_view_get_settings (webView);
+// if (headers != null) {
+// for (int i = 0; i < headers.length; i++) {
+// String current = headers[i];
+// if (current != null) {
+// int index = current.indexOf (':');
+// if (index != -1) {
+// String key = current.substring (0, index).trim ();
+// String value = current.substring (index + 1).trim ();
+// if (key.length () > 0 && value.length () > 0) {
+// if (key.equalsIgnoreCase (USER_AGENT)) {
+// byte[] bytes = Converter.wcsToMbcs (null, value, true);
+// OS.g_object_set (settings, WebKitGTK.user_agent, bytes, 0);
+// }
+// }
+// }
+// }
+// }
+// }
+// byte[] uriBytes = Converter.wcsToMbcs (null, url, true);
+// WebKitGTK.webkit_web_view_load_uri (webView, uriBytes);
+// OS.g_object_set (settings, WebKitGTK.user_agent, 0, 0);
+ return true;
+}
+
+public void stop () {
+// WebKitGTK.webkit_web_view_stop_loading (webView);
+}
+
+long /*int*/ webframe_notify_load_status (long /*int*/ web_frame, long /*int*/ pspec) {
+// int status = WebKitGTK.webkit_web_frame_get_load_status (web_frame);
+// switch (status) {
+// case WebKitGTK.WEBKIT_LOAD_COMMITTED: {
+// long /*int*/ uri = WebKitGTK.webkit_web_frame_get_uri (web_frame);
+// return handleLoadCommitted (uri, false);
+// }
+// case WebKitGTK.WEBKIT_LOAD_FINISHED: {
+// /*
+// * If this frame navigation was isolated to this frame (eg.- a link was
+// * clicked in the frame, as opposed to this frame being created in
+// * response to navigating to a main document containing frames) then
+// * treat this as a completed load.
+// */
+// long /*int*/ parentFrame = WebKitGTK.webkit_web_frame_get_parent (web_frame);
+// if (WebKitGTK.webkit_web_frame_get_load_status (parentFrame) == WebKitGTK.WEBKIT_LOAD_FINISHED) {
+// long /*int*/ uri = WebKitGTK.webkit_web_frame_get_uri (web_frame);
+// return handleLoadFinished (uri, false);
+// }
+// }
+// }
+ return 0;
+}
+
+long /*int*/ webkit_close_web_view (long /*int*/ web_view) {
+// WindowEvent newEvent = new WindowEvent (browser);
+// newEvent.display = browser.getDisplay ();
+// newEvent.widget = browser;
+// for (int i = 0; i < closeWindowListeners.length; i++) {
+// closeWindowListeners[i].close (newEvent);
+// }
+// browser.dispose ();
+ return 0;
+}
+
+long /*int*/ webkit_console_message (long /*int*/ web_view, long /*int*/ message, long /*int*/ line, long /*int*/ source_id) {
+ return 1; /* stop the message from being written to stderr */
+}
+
+long /*int*/ webkit_create_web_view (long /*int*/ web_view, long /*int*/ frame) {
+// WindowEvent newEvent = new WindowEvent (browser);
+// newEvent.display = browser.getDisplay ();
+// newEvent.widget = browser;
+// newEvent.required = true;
+// if (openWindowListeners != null) {
+// for (int i = 0; i < openWindowListeners.length; i++) {
+// openWindowListeners[i].open (newEvent);
+// }
+// }
+// Browser browser = null;
+// if (newEvent.browser != null && newEvent.browser.webBrowser instanceof WebKit) {
+// browser = newEvent.browser;
+// }
+// if (browser != null && !browser.isDisposed ()) {
+// return ((WebKit)browser.webBrowser).webView;
+// }
+ return 0;
+}
+
+long /*int*/ webkit_download_requested (long /*int*/ web_view, long /*int*/ download) {
+// long /*int*/ name = WebKitGTK.webkit_download_get_suggested_filename (download);
+// int length = OS.strlen (name);
+// byte[] bytes = new byte[length];
+// OS.memmove (bytes, name, length);
+// final String nameString = new String (Converter.mbcsToWcs (null, bytes));
+
+// final long /*int*/ request = WebKitGTK.webkit_download_get_network_request (download);
+// OS.g_object_ref (request);
+
+ /*
+ * As of WebKitGTK 1.8.x attempting to show a FileDialog in this callback causes
+ * a hang. The workaround is to open it asynchronously with a new download.
+ */
+// browser.getDisplay ().asyncExec (new Runnable () {
+// public void run () {
+// if (!browser.isDisposed ()) {
+// FileDialog dialog = new FileDialog (browser.getShell (), SWT.SAVE);
+// dialog.setFileName (nameString);
+// String title = Compatibility.getMessage ("SWT_FileDownload"); //$NON-NLS-1$
+// dialog.setText (title);
+// String path = dialog.open ();
+// if (path != null) {
+// path = URI_FILEROOT + path;
+// long /*int*/ newDownload = WebKitGTK.webkit_download_new (request);
+// byte[] uriBytes = Converter.wcsToMbcs (null, path, true);
+// WebKitGTK.webkit_download_set_destination_uri (newDownload, uriBytes);
+// openDownloadWindow (newDownload);
+// WebKitGTK.webkit_download_start (newDownload);
+// OS.g_object_unref (newDownload);
+// }
+// }
+// OS.g_object_unref (request);
+// }
+// });
+
+ return 1;
+}
+
+long /*int*/ webkit_hovering_over_link (long /*int*/ web_view, long /*int*/ title, long /*int*/ uri) {
+// if (uri != 0) {
+// int length = OS.strlen (uri);
+// byte[] bytes = new byte[length];
+// OS.memmove (bytes, uri, length);
+// String text = new String (Converter.mbcsToWcs (null, bytes));
+// StatusTextEvent event = new StatusTextEvent (browser);
+// event.display = browser.getDisplay ();
+// event.widget = browser;
+// event.text = text;
+// for (int i = 0; i < statusTextListeners.length; i++) {
+// statusTextListeners[i].changed (event);
+// }
+// }
+ return 0;
+}
+
+long /*int*/ webkit_mime_type_policy_decision_requested (long /*int*/ web_view, long /*int*/ frame, long /*int*/ request, long /*int*/ mimetype, long /*int*/ policy_decision) {
+// boolean canShow = WebKitGTK.webkit_web_view_can_show_mime_type (webView, mimetype) != 0;
+// if (!canShow) {
+// WebKitGTK.webkit_web_policy_decision_download (policy_decision);
+// return 1;
+// }
+ return 0;
+}
+
+long /*int*/ webkit_navigation_policy_decision_requested (long /*int*/ web_view, long /*int*/ frame, long /*int*/ request, long /*int*/ navigation_action, long /*int*/ policy_decision) {
+// if (loadingText) {
+// /*
+// * WebKit is auto-navigating to about:blank in response to a
+// * webkit_web_view_load_string() invocation. This navigate
+// * should always proceed without sending an event since it is
+// * preceded by an explicit navigate to about:blank in setText().
+// */
+// return 0;
+// }
+
+// long /*int*/ uri = WebKitGTK.webkit_network_request_get_uri (request);
+// int length = OS.strlen (uri);
+// byte[] bytes = new byte[length];
+// OS.memmove (bytes, uri, length);
+
+// String url = new String (Converter.mbcsToWcs (null, bytes));
+// /*
+// * If the URI indicates that the page is being rendered from memory
+// * (via setText()) then set it to about:blank to be consistent with IE.
+// */
+// if (url.equals (URI_FILEROOT)) {
+// url = ABOUT_BLANK;
+// } else {
+// length = URI_FILEROOT.length ();
+// if (url.startsWith (URI_FILEROOT) && url.charAt (length) == '#') {
+// url = ABOUT_BLANK + url.substring (length);
+// }
+// }
+
+// LocationEvent newEvent = new LocationEvent (browser);
+// newEvent.display = browser.getDisplay ();
+// newEvent.widget = browser;
+// newEvent.location = url;
+// newEvent.doit = true;
+// if (locationListeners != null) {
+// for (int i = 0; i < locationListeners.length; i++) {
+// locationListeners[i].changing (newEvent);
+// }
+// }
+// if (newEvent.doit && !browser.isDisposed ()) {
+// if (jsEnabled != jsEnabledOnNextPage) {
+// jsEnabled = jsEnabledOnNextPage;
+// DisabledJSCount += !jsEnabled ? 1 : -1;
+// long /*int*/ settings = WebKitGTK.webkit_web_view_get_settings (webView);
+// OS.g_object_set (settings, WebKitGTK.enable_scripts, jsEnabled ? 1 : 0, 0);
+// }
+//
+// /* hook status change signal if frame is a newly-created sub-frame */
+// long /*int*/ mainFrame = WebKitGTK.webkit_web_view_get_main_frame (webView);
+// if (frame != mainFrame) {
+// int id = OS.g_signal_handler_find (frame, OS.G_SIGNAL_MATCH_FUNC | OS.G_SIGNAL_MATCH_DATA, 0, 0, 0, Proc3.getAddress (), NOTIFY_LOAD_STATUS);
+// if (id == 0) {
+// OS.g_signal_connect (frame, WebKitGTK.notify_load_status, Proc3.getAddress (), NOTIFY_LOAD_STATUS);
+// }
+// }
+//
+// /*
+// * The following line is intentionally commented. For some reason, invoking
+// * webkit_web_policy_decision_use(policy_decision) causes the Flash plug-in
+// * to crash when navigating to a page with Flash. Since returning from this
+// * callback without invoking webkit_web_policy_decision_ignore(policy_decision)
+// * implies that the page should be loaded, it's fine to not invoke
+// * webkit_web_policy_decision_use(policy_decision) here.
+// */
+// //WebKitGTK.webkit_web_policy_decision_use (policy_decision);
+// } else {
+// WebKitGTK.webkit_web_policy_decision_ignore (policy_decision);
+// }
+ return 0;
+}
+
+long /*int*/ webkit_notify_load_status (long /*int*/ web_view, long /*int*/ pspec) {
+// int status = WebKitGTK.webkit_web_view_get_load_status (webView);
+// switch (status) {
+// case WebKitGTK.WEBKIT_LOAD_COMMITTED: {
+// long /*int*/ uri = WebKitGTK.webkit_web_view_get_uri (webView);
+// return handleLoadCommitted (uri, true);
+// }
+// case WebKitGTK.WEBKIT_LOAD_FINISHED: {
+// long /*int*/ uri = WebKitGTK.webkit_web_view_get_uri (webView);
+// return handleLoadFinished (uri, true);
+// }
+// }
+ return 0;
+}
+
+long /*int*/ webkit_notify_progress (long /*int*/ web_view, long /*int*/ pspec) {
+// ProgressEvent event = new ProgressEvent (browser);
+// event.display = browser.getDisplay ();
+// event.widget = browser;
+// event.current = (int)(WebKitGTK.webkit_web_view_get_progress (webView) * MAX_PROGRESS);
+// event.total = MAX_PROGRESS;
+// for (int i = 0; i < progressListeners.length; i++) {
+// progressListeners[i].changed (event);
+// }
+ return 0;
+}
+
+long /*int*/ webkit_notify_title (long /*int*/ web_view, long /*int*/ pspec) {
+// long /*int*/ title = WebKitGTK.webkit_web_view_get_title (webView);
+// String titleString;
+// if (title == 0) {
+// titleString = ""; //$NON-NLS-1$
+// } else {
+// int length = OS.strlen (title);
+// byte[] bytes = new byte[length];
+// OS.memmove (bytes, title, length);
+// titleString = new String (Converter.mbcsToWcs (null, bytes));
+// }
+// TitleEvent event = new TitleEvent (browser);
+// event.display = browser.getDisplay ();
+// event.widget = browser;
+// event.title = titleString;
+// for (int i = 0; i < titleListeners.length; i++) {
+// titleListeners[i].changed (event);
+// }
+ return 0;
+}
+
+long /*int*/ webkit_populate_popup (long /*int*/ web_view, long /*int*/ webkit_menu) {
+// Point pt = browser.getDisplay ().getCursorLocation ();
+// Event event = new Event ();
+// event.x = pt.x;
+// event.y = pt.y;
+// browser.notifyListeners (SWT.MenuDetect, event);
+// if (!event.doit) {
+// /* clear the menu */
+// long /*int*/ children = OS.gtk_container_get_children (webkit_menu);
+// long /*int*/ current = children;
+// while (current != 0) {
+// long /*int*/ item = OS.g_list_data (current);
+// OS.gtk_container_remove (webkit_menu, item);
+// current = OS.g_list_next (current);
+// }
+// OS.g_list_free (children);
+// return 0;
+// }
+// Menu menu = browser.getMenu ();
+// if (menu != null && !menu.isDisposed ()) {
+// if (pt.x != event.x || pt.y != event.y) {
+// menu.setLocation (event.x, event.y);
+// }
+// menu.setVisible (true);
+// /* clear the menu */
+// long /*int*/ children = OS.gtk_container_get_children (webkit_menu);
+// long /*int*/ current = children;
+// while (current != 0) {
+// long /*int*/ item = OS.g_list_data (current);
+// OS.gtk_container_remove (webkit_menu, item);
+// current = OS.g_list_next (current);
+// }
+// OS.g_list_free (children);
+// }
+ return 0;
+}
+
+long /*int*/ webkit_resource_request_starting (long /*int*/ web_view, long /*int*/ web_frame, long /*int*/ web_resource, long /*int*/ request, long /*int*/ response) {
+// if (postData != null || headers != null) {
+// long /*int*/ message = WebKitGTK.webkit_network_request_get_message (request);
+// if (message == 0) {
+// headers = null;
+// postData = null;
+// } else {
+// if (postData != null) {
+// WebKitGTK.SoupMessage_method (message, PostString);
+// long /*int*/ body = WebKitGTK.SoupMessage_request_body (message);
+// byte[] bytes = Converter.wcsToMbcs (null, postData, false);
+// long /*int*/ data = C.malloc (bytes.length);
+// C.memmove (data, bytes, bytes.length);
+// WebKitGTK.soup_message_body_append (body, WebKitGTK.SOUP_MEMORY_TAKE, data, bytes.length);
+// WebKitGTK.soup_message_body_flatten (body);
+//
+// if (headers == null) headers = new String[0];
+// boolean found = false;
+// for (int i = 0; i < headers.length; i++) {
+// int index = headers[i].indexOf (':');
+// if (index != -1) {
+// String name = headers[i].substring (0, index).trim ().toLowerCase ();
+// if (name.equals (HEADER_CONTENTTYPE)) {
+// found = true;
+// break;
+// }
+// }
+// }
+// if (!found) {
+// String[] temp = new String[headers.length + 1];
+// System.arraycopy (headers, 0, temp, 0, headers.length);
+// temp[headers.length] = HEADER_CONTENTTYPE + ':' + MIMETYPE_FORMURLENCODED;
+// headers = temp;
+// }
+// postData = null;
+// }
+//
+// /* headers */
+// long /*int*/ requestHeaders = WebKitGTK.SoupMessage_request_headers (message);
+// for (int i = 0; i < headers.length; i++) {
+// String current = headers[i];
+// if (current != null) {
+// int index = current.indexOf (':');
+// if (index != -1) {
+// String key = current.substring (0, index).trim ();
+// String value = current.substring (index + 1).trim ();
+// if (key.length () > 0 && value.length () > 0) {
+// byte[] nameBytes = Converter.wcsToMbcs (null, key, true);
+// byte[] valueBytes = Converter.wcsToMbcs (null, value, true);
+// WebKitGTK.soup_message_headers_append (requestHeaders, nameBytes, valueBytes);
+// }
+// }
+// }
+// }
+// headers = null;
+// }
+// }
+
+ return 0;
+}
+
+long /*int*/ webkit_status_bar_text_changed (long /*int*/ web_view, long /*int*/ text) {
+// int length = OS.strlen (text);
+// byte[] bytes = new byte[length];
+// OS.memmove (bytes, text, length);
+// StatusTextEvent statusText = new StatusTextEvent (browser);
+// statusText.display = browser.getDisplay ();
+// statusText.widget = browser;
+// statusText.text = new String (Converter.mbcsToWcs (null, bytes));
+// for (int i = 0; i < statusTextListeners.length; i++) {
+// statusTextListeners[i].changed (statusText);
+// }
+ return 0;
+}
+
+long /*int*/ webkit_web_view_ready (long /*int*/ web_view) {
+// WindowEvent newEvent = new WindowEvent (browser);
+// newEvent.display = browser.getDisplay ();
+// newEvent.widget = browser;
+//
+// long /*int*/ settings = WebKitGTK.webkit_web_view_get_window_features (webView);
+// int[] result = new int[1];
+// OS.g_object_get (settings, WebKitGTK.locationbar_visible, result, 0);
+// newEvent.addressBar = result[0] != 0;
+// result[0] = 0;
+// OS.g_object_get (settings, WebKitGTK.menubar_visible, result, 0);
+// newEvent.menuBar = result[0] != 0;
+// result[0] = 0;
+// OS.g_object_get (settings, WebKitGTK.statusbar_visible, result, 0);
+// newEvent.statusBar = result[0] != 0;
+// result[0] = 0;
+// OS.g_object_get (settings, WebKitGTK.toolbar_visible, result, 0);
+// newEvent.toolBar = result[0] != 0;
+// result[0] = 0;
+// OS.g_object_get (settings, WebKitGTK.x, result, 0);
+// int x = result[0];
+// result[0] = 0;
+// OS.g_object_get (settings, WebKitGTK.y, result, 0);
+// int y = result[0];
+// result[0] = 0;
+// OS.g_object_get (settings, WebKitGTK.width, result, 0);
+// int width = result[0];
+// result[0] = 0;
+// OS.g_object_get (settings, WebKitGTK.height, result, 0);
+// int height = result[0];
+// result[0] = 0;
+// if (x != -1 && y != -1) {
+// newEvent.location = new Point (x,y);
+// }
+// if (width != -1 && height != -1) {
+// newEvent.size = new Point (width,height);
+// }
+// for (int i = 0; i < visibilityWindowListeners.length; i++) {
+// visibilityWindowListeners[i].show (newEvent);
+// }
+ return 0;
+}
+
+long /*int*/ webkit_window_object_cleared (long /*int*/ web_view, long /*int*/ frame, long /*int*/ context, long /*int*/ window_object) {
+// long /*int*/ globalObject = WebKitGTK.JSContextGetGlobalObject (context);
+// long /*int*/ externalObject = WebKitGTK.JSObjectMake (context, ExternalClass, webViewData);
+// byte[] bytes = null;
+// try {
+// bytes = (OBJECTNAME_EXTERNAL + '\0').getBytes (CHARSET_UTF8);
+// } catch (UnsupportedEncodingException e) {
+// bytes = Converter.wcsToMbcs (null, OBJECTNAME_EXTERNAL, true);
+// }
+// long /*int*/ name = WebKitGTK.JSStringCreateWithUTF8CString (bytes);
+// WebKitGTK.JSObjectSetProperty (context, globalObject, name, externalObject, 0, null);
+// WebKitGTK.JSStringRelease (name);
+// Enumeration elements = functions.elements ();
+// while (elements.hasMoreElements ()) {
+// BrowserFunction current = (BrowserFunction)elements.nextElement ();
+// execute (current.functionString);
+// }
+// long /*int*/ mainFrame = WebKitGTK.webkit_web_view_get_main_frame (webView);
+// boolean top = mainFrame == frame;
+// addEventHandlers (web_view, top);
+ return 0;
+}
+
+long /*int*/ callJava (long /*int*/ ctx, long /*int*/ func, long /*int*/ thisObject, long /*int*/ argumentCount, long /*int*/ arguments, long /*int*/ exception) {
+// Object returnValue = null;
+// if (argumentCount == 3) {
+// long /*int*/[] result = new long /*int*/[1];
+// C.memmove (result, arguments, C.PTR_SIZEOF);
+// int type = WebKitGTK.JSValueGetType (ctx, result[0]);
+// if (type == WebKitGTK.kJSTypeNumber) {
+// int index = ((Double)convertToJava (ctx, result[0])).intValue ();
+// result[0] = 0;
+// Object key = new Integer (index);
+// C.memmove (result, arguments + C.PTR_SIZEOF, C.PTR_SIZEOF);
+// type = WebKitGTK.JSValueGetType (ctx, result[0]);
+// if (type == WebKitGTK.kJSTypeString) {
+// String token = (String)convertToJava (ctx, result[0]);
+// BrowserFunction function = (BrowserFunction)functions.get (key);
+// if (function != null && token.equals (function.token)) {
+// try {
+// C.memmove (result, arguments + 2 * C.PTR_SIZEOF, C.PTR_SIZEOF);
+// Object temp = convertToJava (ctx, result[0]);
+// if (temp instanceof Object[]) {
+// Object[] args = (Object[])temp;
+// try {
+// returnValue = function.function (args);
+// } catch (Exception e) {
+// /* exception during function invocation */
+// returnValue = WebBrowser.CreateErrorString (e.getLocalizedMessage ());
+// }
+// }
+// } catch (IllegalArgumentException e) {
+// /* invalid argument value type */
+// if (function.isEvaluate) {
+// /* notify the function so that a java exception can be thrown */
+// function.function (new String[] {WebBrowser.CreateErrorString (new SWTException (SWT.ERROR_INVALID_RETURN_VALUE).getLocalizedMessage ())});
+// }
+// returnValue = WebBrowser.CreateErrorString (e.getLocalizedMessage ());
+// }
+// }
+// }
+// }
+// }
+// return convertToJS (ctx, returnValue);
+ return 0;
+}
+
+long /*int*/ convertToJS (long /*int*/ ctx, Object value) {
+// if (value == null) {
+// return WebKitGTK.JSValueMakeUndefined (ctx);
+// }
+// if (value instanceof String) {
+// byte[] bytes = null;
+// try {
+// bytes = ((String)value + '\0').getBytes (CHARSET_UTF8); //$NON-NLS-1$
+// } catch (UnsupportedEncodingException e) {
+// bytes = Converter.wcsToMbcs (null, (String)value, true);
+// }
+// long /*int*/ stringRef = WebKitGTK.JSStringCreateWithUTF8CString (bytes);
+// long /*int*/ result = WebKitGTK.JSValueMakeString (ctx, stringRef);
+// WebKitGTK.JSStringRelease (stringRef);
+// return result;
+// }
+// if (value instanceof Boolean) {
+// return WebKitGTK.JSValueMakeBoolean (ctx, ((Boolean)value).booleanValue () ? 1 : 0);
+// }
+// if (value instanceof Number) {
+// return WebKitGTK.JSValueMakeNumber (ctx, ((Number)value).doubleValue ());
+// }
+// if (value instanceof Object[]) {
+// Object[] arrayValue = (Object[]) value;
+// int length = arrayValue.length;
+// long /*int*/[] arguments = new long /*int*/[length];
+// for (int i = 0; i < length; i++) {
+// Object javaObject = arrayValue[i];
+// long /*int*/ jsObject = convertToJS (ctx, javaObject);
+// arguments[i] = jsObject;
+// }
+// return WebKitGTK.JSObjectMakeArray (ctx, length, arguments, null);
+// }
+// SWT.error (SWT.ERROR_INVALID_RETURN_VALUE);
+ return 0;
+}
+
+Object convertToJava (long /*int*/ ctx, long /*int*/ value) {
+// int type = WebKitGTK.JSValueGetType (ctx, value);
+// switch (type) {
+// case WebKitGTK.kJSTypeBoolean: {
+// int result = (int)WebKitGTK.JSValueToNumber (ctx, value, null);
+// return new Boolean (result != 0);
+// }
+// case WebKitGTK.kJSTypeNumber: {
+// double result = WebKitGTK.JSValueToNumber (ctx, value, null);
+// return new Double(result);
+// }
+// case WebKitGTK.kJSTypeString: {
+// long /*int*/ string = WebKitGTK.JSValueToStringCopy (ctx, value, null);
+// if (string == 0) return ""; //$NON-NLS-1$
+// long /*int*/ length = WebKitGTK.JSStringGetMaximumUTF8CStringSize (string);
+// byte[] bytes = new byte[(int)/*64*/length];
+// length = WebKitGTK.JSStringGetUTF8CString (string, bytes, length);
+// WebKitGTK.JSStringRelease (string);
+// try {
+// /* length-1 is needed below to exclude the terminator character */
+// return new String (bytes, 0, (int)/*64*/length - 1, CHARSET_UTF8);
+// } catch (UnsupportedEncodingException e) {
+// return new String (Converter.mbcsToWcs (null, bytes));
+// }
+// }
+// case WebKitGTK.kJSTypeNull:
+// // FALL THROUGH
+// case WebKitGTK.kJSTypeUndefined: return null;
+// case WebKitGTK.kJSTypeObject: {
+// byte[] bytes = null;
+// try {
+// bytes = (PROPERTY_LENGTH + '\0').getBytes (CHARSET_UTF8); //$NON-NLS-1$
+// } catch (UnsupportedEncodingException e) {
+// bytes = Converter.wcsToMbcs (null, PROPERTY_LENGTH, true);
+// }
+// long /*int*/ propertyName = WebKitGTK.JSStringCreateWithUTF8CString (bytes);
+// long /*int*/ valuePtr = WebKitGTK.JSObjectGetProperty (ctx, value, propertyName, null);
+// WebKitGTK.JSStringRelease (propertyName);
+// type = WebKitGTK.JSValueGetType (ctx, valuePtr);
+// if (type == WebKitGTK.kJSTypeNumber) {
+// int length = (int)WebKitGTK.JSValueToNumber (ctx, valuePtr, null);
+// Object[] result = new Object[length];
+// for (int i = 0; i < length; i++) {
+// long /*int*/ current = WebKitGTK.JSObjectGetPropertyAtIndex (ctx, value, i, null);
+// if (current != 0) {
+// result[i] = convertToJava (ctx, current);
+// }
+// }
+// return result;
+// }
+// }
+// }
+// SWT.error (SWT.ERROR_INVALID_ARGUMENT);
+ return null;
+}
+
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFApp.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFApp.java
new file mode 100644
index 0000000000..b9ce9ad75b
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFApp.java
@@ -0,0 +1,95 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.swt.browser;
+
+import org.eclipse.swt.graphics.Device;
+import org.eclipse.swt.internal.C;
+import org.eclipse.swt.internal.Callback;
+import org.eclipse.swt.internal.cef3.CEF3;
+import org.eclipse.swt.internal.cef3.CEF3Object;
+import org.eclipse.swt.internal.cef3.cef_browser_process_handler_t;
+
+public class CEFApp {
+ CEF3Object object;
+ CEFBrowserProcessHandler browserProcessHandler;
+ int refCount = 1;
+
+public CEFApp() {
+ object = new CEF3Object (new int[] {0, 0, 0, 2, 1, 0, 0, 0}) {
+ public long /*int*/ method0(long /*int*/[] args) {return add_ref();}
+ public long /*int*/ method1(long /*int*/[] args) {return CEFApp.this.release();}
+ public long /*int*/ method2(long /*int*/[] args) {return get_refct();}
+ public long /*int*/ method3(long /*int*/[] args) {return on_before_command_line_processing(args[0], args[1]);}
+ public long /*int*/ method4(long /*int*/[] args) {return on_register_custom_schemes(args[0]);}
+ public long /*int*/ method5(long /*int*/[] args) {return get_resource_bundle_handler();}
+ public long /*int*/ method6(long /*int*/[] args) {return get_browser_process_handler();}
+ public long /*int*/ method7(long /*int*/[] args) {return get_render_process_handler();}
+ };
+}
+
+long /*int*/ getAddress () {
+ return object.getAddress ();
+}
+
+/* cef_base_t */
+
+int add_ref() {
+ refCount++;
+ return refCount;
+}
+
+int get_refct() {
+ return refCount;
+}
+
+int release() {
+ if (--refCount == 0) {
+ if (browserProcessHandler != null) {
+ browserProcessHandler.release();
+ browserProcessHandler = null;
+ }
+ if (object != null) {
+ object.dispose ();
+ }
+ object = null;
+ }
+ return refCount;
+}
+
+/* cef_app_t */
+
+long /*int*/ get_browser_process_handler() {
+ if (Device.DEBUG) System.out.println("get_browser_process_handler");
+ if (browserProcessHandler == null) {
+ browserProcessHandler = new CEFBrowserProcessHandler();
+ browserProcessHandler.add_ref();
+ }
+ return browserProcessHandler.getAddress();
+}
+long /*int*/ get_render_process_handler() {
+ if (Device.DEBUG) System.out.println("**get_render_process_handler");
+ return 0;
+}
+long /*int*/ get_resource_bundle_handler() {
+ if (Device.DEBUG) System.out.println("**get_resource_bundle_handler");
+ return 0;
+}
+long /*int*/ on_before_command_line_processing(long /*int*/ self, long /*int*/ arg1) {
+ /* opportunity to view/modify command line before it is used by subprocess */
+ if (Device.DEBUG) System.out.println("on_before_command_line_processing");
+ return 0;
+}
+long /*int*/ on_register_custom_schemes(long /*int*/ self) {
+ if (Device.DEBUG) System.out.println("on_register_custom_schemes");
+ return 0;
+}
+
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFBrowserProcessHandler.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFBrowserProcessHandler.java
new file mode 100644
index 0000000000..468ea6e330
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFBrowserProcessHandler.java
@@ -0,0 +1,76 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.swt.browser;
+
+import org.eclipse.swt.graphics.Device;
+import org.eclipse.swt.internal.cef3.CEF3Object;
+
+public class CEFBrowserProcessHandler {
+ CEF3Object object;
+ int refCount = 1;
+
+public CEFBrowserProcessHandler() {
+ object = new CEF3Object (new int[] {0, 0, 0, 0, 0, 1, 1}) {
+ public long /*int*/ method0(long /*int*/[] args) {return add_ref();}
+ public long /*int*/ method1(long /*int*/[] args) {return CEFBrowserProcessHandler.this.release();}
+ public long /*int*/ method2(long /*int*/[] args) {return get_refct();}
+ public long /*int*/ method3(long /*int*/[] args) {return get_proxy_handler();}
+ public long /*int*/ method4(long /*int*/[] args) {return on_context_initialized();}
+ public long /*int*/ method5(long /*int*/[] args) {return on_before_child_process_launch(args[0]);}
+ public long /*int*/ method6(long /*int*/[] args) {return on_render_process_thread_created(args[0]);}
+ };
+}
+
+long /*int*/ getAddress () {
+ return object.getAddress ();
+}
+
+/* cef_base_t */
+
+int add_ref() {
+ refCount++;
+ return refCount;
+}
+
+int get_refct() {
+ return refCount;
+}
+
+int release() {
+ if (--refCount == 0) {
+ if (object != null) {
+ object.dispose ();
+ }
+ object = null;
+ }
+ return refCount;
+}
+
+/* cef_browser_process_handler_t */
+
+static long /*int*/ get_proxy_handler() {
+ if (Device.DEBUG) System.out.println("get_proxy_handler");
+ return 0;
+}
+static long /*int*/ on_context_initialized() {
+ if (Device.DEBUG) System.out.println("on_context_initialized");
+ return 0;
+}
+static long /*int*/ on_before_child_process_launch(long /*int*/ arg0) {
+ if (Device.DEBUG) System.out.println("on_before_child_process_launch");
+ return 0;
+}
+static long /*int*/ on_render_process_thread_created(long /*int*/ arg0) {
+ if (Device.DEBUG) System.out.println("on_render_process_thread_created");
+ return 0;
+}
+
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFClient.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFClient.java
new file mode 100644
index 0000000000..8f799eaa8c
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/browser/CEFClient.java
@@ -0,0 +1,116 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.swt.browser;
+
+import org.eclipse.swt.graphics.Device;
+import org.eclipse.swt.internal.cef3.CEF3Object;
+
+public class CEFClient {
+ CEF3Object object;
+ int refCount = 1;
+
+public CEFClient() {
+ object = new CEF3Object (new int[] {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3}) {
+ public long /*int*/ method0(long /*int*/[] args) {return add_ref();}
+ public long /*int*/ method1(long /*int*/[] args) {return CEFClient.this.release();}
+ public long /*int*/ method2(long /*int*/[] args) {return get_refct();}
+ public long /*int*/ method3(long /*int*/[] args) {return get_context_menu_handler();}
+ public long /*int*/ method4(long /*int*/[] args) {return get_dialog_handler();}
+ public long /*int*/ method5(long /*int*/[] args) {return get_display_handler();}
+ public long /*int*/ method6(long /*int*/[] args) {return get_download_handler();}
+ public long /*int*/ method7(long /*int*/[] args) {return get_focus_handler();}
+ public long /*int*/ method8(long /*int*/[] args) {return get_geolocation_handler();}
+ public long /*int*/ method9(long /*int*/[] args) {return get_jsdialog_handler();}
+ public long /*int*/ method10(long /*int*/[] args) {return get_keyboard_handler();}
+ public long /*int*/ method11(long /*int*/[] args) {return get_life_span_handler();}
+ public long /*int*/ method12(long /*int*/[] args) {return get_load_handler();}
+ public long /*int*/ method13(long /*int*/[] args) {return get_request_handler();}
+ public long /*int*/ method14(long /*int*/[] args) {return on_process_message_received(args[0], args[1], args[2]);}
+ };
+}
+
+long /*int*/ getAddress () {
+ return object.getAddress ();
+}
+
+/* cef_base_t */
+
+int add_ref() {
+ refCount++;
+ return refCount;
+}
+
+int get_refct() {
+ return refCount;
+}
+
+int release() {
+ if (--refCount == 0) {
+ if (object != null) {
+ object.dispose ();
+ }
+ object = null;
+ }
+ return refCount;
+}
+
+/* cef_t */
+
+long /*int*/ get_context_menu_handler() {
+ if (Device.DEBUG) System.out.println("**get_context_menu_handler");
+ return 0;
+}
+long /*int*/ get_dialog_handler() {
+ if (Device.DEBUG) System.out.println("**get_dialog_handler");
+ return 0;
+}
+long /*int*/ get_display_handler() {
+ if (Device.DEBUG) System.out.println("get_display_handler");
+ return 0/*displayHandler*/;
+}
+long /*int*/ get_download_handler() {
+ if (Device.DEBUG) System.out.println("**get_download_handler");
+ return 0;
+}
+long /*int*/ get_focus_handler() {
+ if (Device.DEBUG) System.out.println("get_focus_handler");
+ return 0/*focusHandler*/;
+}
+long /*int*/ get_geolocation_handler() {
+ if (Device.DEBUG) System.out.println("**get_geolocation_handler");
+ return 0;
+}
+long /*int*/ get_jsdialog_handler() {
+ if (Device.DEBUG) System.out.println("**get_jsdialog_handler");
+ return 0;
+}
+long /*int*/ get_keyboard_handler() {
+ if (Device.DEBUG) System.out.println("**get_keyboard_handler");
+ return 0;
+}
+long /*int*/ get_life_span_handler() {
+ if (Device.DEBUG) System.out.println("get_life_span_handler");
+ return 0/*lifeSpanHandler*/;
+}
+long /*int*/ get_load_handler() {
+ if (Device.DEBUG) System.out.println("get_load_handler");
+ return 0/*loadHandler*/;
+}
+long /*int*/ get_request_handler() {
+ if (Device.DEBUG) System.out.println("get_request_handler");
+ return 0/*requestHandler*/;
+}
+long /*int*/ on_process_message_received(long /*int*/ arg0, long /*int*/ arg1, long /*int*/ arg2) {
+ if (Device.DEBUG) System.out.println("on_process_message_received");
+ return 0;
+}
+
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/CEF3.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/CEF3.java
new file mode 100644
index 0000000000..4d24b51828
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/CEF3.java
@@ -0,0 +1,159 @@
+package org.eclipse.swt.internal.cef3;
+
+import org.eclipse.swt.internal.C;
+
+public class CEF3 extends C {
+
+/**
+ * @param windowInfo cast=(const cef_window_info_t*)
+ * @param client cast=(struct _cef_client_t*)
+ * @param url cast=(const cef_string_t*)
+ * @param settings cast=(const struct _cef_browser_settings_t*)
+ */
+public static final native int cef_browser_host_create_browser(cef_window_info_t windowInfo, /*cef_client_t*/ long /*int*/ client, /*cef_string_t*/ long /*int*/ url, cef_browser_settings_t settings);
+
+/**
+ * @param windowInfo cast=(const cef_window_info_t*)
+ * @param client cast=(struct _cef_client_t*)
+ * @param url cast=(const cef_string_t*)
+ * @param settings cast=(const struct _cef_browser_settings_t*)
+ */
+public static final native long /*int*/ cef_browser_host_create_browser_sync(cef_window_info_t windowInfo, cef_client_t client, cef_string_t url, long /*int*/ settings);
+
+///
+// This function should be called from the application entry point function to
+// execute a secondary process. It can be used to run secondary processes from
+// the browser client executable (default behavior) or from a separate
+// executable specified by the CefSettings.browser_subprocess_path value. If
+// called for the browser process (identified by no "type" command-line value)
+// it will return immediately with a value of -1. If called for a recognized
+// secondary process it will block until the process should exit and then return
+// the process exit code. The |application| parameter may be NULL.
+///
+//CEF_EXPORT int cef_execute_process(const struct _cef_main_args_t* args,
+// struct _cef_app_t* application);
+/**
+ * @param args cast=(const struct _cef_main_args_t*)
+ * @param application cast=(struct _cef_app_t*)
+ */
+public static final native int cef_execute_process(cef_main_args_t args, long /*int*/ application);
+
+///
+// This function should be called on the main application thread to initialize
+// the CEF browser process. The |application| parameter may be NULL. A return
+// value of true (1) indicates that it succeeded and false (0) indicates that it
+// failed.
+///
+//CEF_EXPORT int cef_initialize(const struct _cef_main_args_t* args,
+// const struct _cef_settings_t* settings, struct _cef_app_t* application);
+/**
+ * @param args cast=(const struct _cef_main_args_t*)
+ * @param settings cast=(const struct _cef_settings_t*)
+ * @param application cast=(struct _cef_app_t*)
+ */
+public static final native int cef_initialize(cef_main_args_t args, cef_settings_t settings, /*cef_app_t*/ long /*int*/ application);
+
+/* strings */
+/** @param str cast=(cef_string_t*) */
+public static final native void cef_string_clear(long /*int*/ str);
+/**
+ * @param src cast=(void*)
+ * @param src_len cast=(size_t)
+ * @param output cast=(cef_string_t*)
+ */
+public static final native int cef_string_set(char[] src, long /*int*/ src_len, /*cef_string_t*/ long /*int*/ output, int copy);
+public static final native long /*int*/ cef_string_userfree_alloc();
+/** @param str cast=(cef_string_userfree_t) */
+public static final native void cef_string_userfree_free(long /*int*/ str);
+
+/**
+ * @param dest cast=(void *)
+ * @param src cast=(const void *),flags=no_out critical
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (long /*int*/ dest, cef_app_t src, long /*int*/ size);
+/**
+ * @param dest cast=(void *)
+ * @param src cast=(const void *),flags=no_out critical
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (long /*int*/ dest, cef_browser_process_handler_t src, long /*int*/ size);
+/**
+ * @param dest cast=(void *)
+ * @param src cast=(const void *),flags=no_out critical
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (long /*int*/ dest, cef_client_t src, long /*int*/ size);
+/**
+ * @param dest cast=(void *)
+ * @param src cast=(const void *),flags=no_out critical
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (long /*int*/ dest, cef_display_handler_t src, long /*int*/ size);
+/**
+ * @param dest cast=(void *)
+ * @param src cast=(const void *),flags=no_out critical
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (long /*int*/ dest, cef_focus_handler_t src, long /*int*/ size);
+/**
+ * @param dest cast=(void *)
+ * @param src cast=(const void *),flags=no_out critical
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (long /*int*/ dest, cef_life_span_handler_t src, long /*int*/ size);
+/**
+ * @param dest cast=(void *)
+ * @param src cast=(const void *),flags=no_out critical
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (long /*int*/ dest, cef_load_handler_t src, long /*int*/ size);
+/**
+ * @param dest cast=(void *)
+ * @param src cast=(const void *),flags=no_out critical
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (long /*int*/ dest, cef_proxy_handler_t src, long /*int*/ size);
+/**
+ * @param dest cast=(void *)
+ * @param src cast=(const void *),flags=no_out critical
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (long /*int*/ dest, cef_request_handler_t src, long /*int*/ size);
+/**
+ * @param dest cast=(void *)
+ * @param src cast=(const void *),flags=no_out critical
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (long /*int*/ dest, cef_resource_bundle_handler_t src, long /*int*/ size);
+
+/**
+ * @param dest cast=(void *),flags=no_in critical
+ * @param src cast=(const void *)
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (cef_command_line_t dest, long /*int*/ src, long /*int*/ size);
+/**
+ * @param dest cast=(void *),flags=no_in critical
+ * @param src cast=(const void *)
+ * @param size cast=(size_t)
+ */
+public static final native void memmove (cef_string_t dest, long /*int*/ src, long /*int*/ size);
+
+/* sizeof */
+public static final native int cef_app_t_sizeof();
+public static final native int cef_browser_process_handler_t_sizeof();
+public static final native int cef_browser_settings_t_sizeof();
+public static final native int cef_client_t_sizeof();
+public static final native int cef_command_line_t_sizeof();
+public static final native int cef_context_menu_handler_t_sizeof();
+public static final native int cef_display_handler_t_sizeof();
+public static final native int cef_focus_handler_t_sizeof();
+public static final native int cef_life_span_handler_t_sizeof();
+public static final native int cef_load_handler_t_sizeof();
+public static final native int cef_proxy_handler_t_sizeof();
+public static final native int cef_request_handler_t_sizeof();
+public static final native int cef_resource_bundle_handler_t_sizeof();
+public static final native int cef_settings_t_sizeof();
+public static final native int cef_string_t_sizeof();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/CEF3Object.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/CEF3Object.java
new file mode 100644
index 0000000000..b3dd0ed7fc
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/CEF3Object.java
@@ -0,0 +1,50 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.swt.internal.cef3;
+
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.internal.*;
+
+public class CEF3Object extends OSObject {
+ static {
+ FailCode = 0;
+ NotImplementedCode = 0;
+ }
+
+public CEF3Object (int[] argCounts) {
+ super (argCounts);
+}
+
+protected long /*int*/ create (int[] argCounts, int os_offset) {
+ /* a +1 offset is added to callbackAddresses references to account for the "size" field that must be at position 0 */
+ long /*int*/[] callbackAddresses = new long /*int*/[argCounts.length + os_offset + 1];
+ synchronized (Callbacks) {
+ for (int i = 0, length = argCounts.length; i < length; i++) {
+ if ((Callbacks[i + os_offset][argCounts[i]]) == null) {
+ Callbacks[i + os_offset][argCounts[i]] = new Callback(getClass(), "callback"+i, argCounts[i] + 1, true, FailCode); //$NON-NLS-1$
+ }
+ callbackAddresses[i + os_offset + 1] = Callbacks[i + os_offset][argCounts[i]].getAddress();
+ if (callbackAddresses[i + os_offset + 1] == 0) SWT.error(SWT.ERROR_NO_MORE_CALLBACKS);
+ }
+ }
+
+ int size = C.PTR_SIZEOF * (argCounts.length + os_offset + 1);
+ callbackAddresses[0] = size; /* set the "size" field value */
+ long /*int*/ result = C.malloc (size);
+ C.memmove (result, callbackAddresses, size);
+ return result;
+}
+
+protected void release (long /*int*/ handle) {
+ C.free (handle);
+}
+
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_app_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_app_t.java
new file mode 100644
index 0000000000..6d46f4250e
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_app_t.java
@@ -0,0 +1,51 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_app_t extends cef_base_t {
+ ///
+ // Provides an opportunity to view and/or modify command-line arguments before
+ // processing by CEF and Chromium. The |process_type| value will be NULL for
+ // the browser process. Do not keep a reference to the cef_command_line_t
+ // object passed to this function. The CefSettings.command_line_args_disabled
+ // value can be used to start with an NULL command-line object. Any values
+ // specified in CefSettings that equate to command-line arguments will be set
+ // before this function is called. Be cautious when using this function to
+ // modify command-line arguments for non-browser processes as this may result
+ // in undefined behavior including crashes.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_before_command_line_processing)(struct _cef_app_t* self, const cef_string_t* process_type, struct _cef_command_line_t* command_line)) */
+ public long /*int*/ on_before_command_line_processing;
+
+ ///
+ // Provides an opportunity to register custom schemes. Do not keep a reference
+ // to the |registrar| object. This function is called on the main thread for
+ // each process and the registered schemes should be the same across all
+ // processes.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_register_custom_schemes)(struct _cef_app_t* self, struct _cef_scheme_registrar_t* registrar)) */
+ public long /*int*/ on_register_custom_schemes;
+
+ ///
+ // Return the handler for resource bundle events. If
+ // CefSettings.pack_loading_disabled is true (1) a handler must be returned.
+ // If no handler is returned resources will be loaded from pack files. This
+ // function is called by the browser and render processes on multiple threads.
+ ///
+// /** @field cast=(struct _cef_resource_bundle_handler_t* (CEF_CALLBACK *get_resource_bundle_handler)(struct _cef_app_t* self)) */
+ public long /*int*/ get_resource_bundle_handler;
+
+ ///
+ // Return the handler for functionality specific to the browser process. This
+ // function is called on multiple threads in the browser process.
+ ///
+// /** @field cast=(struct _cef_browser_process_handler_t* (CEF_CALLBACK *get_browser_process_handler)(struct _cef_app_t* self)) */
+ public long /*int*/ get_browser_process_handler;
+
+ ///
+ // Return the handler for functionality specific to the render process. This
+ // function is called on the render process main thread.
+ ///
+// /** @field cast=(struct _cef_render_process_handler_t* (CEF_CALLBACK *get_render_process_handler)(struct _cef_app_t* self)) */
+ public long /*int*/ get_render_process_handler;
+
+ public static final int sizeof = CEF3.cef_app_t_sizeof();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_base_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_base_t.java
new file mode 100644
index 0000000000..3d1701a844
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_base_t.java
@@ -0,0 +1,19 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_base_t {
+ /** @field cast=(size_t) */
+ public long /*int*/ size;
+
+ // Increment the reference count.
+// /** @field cast=(int (CEF_CALLBACK *add_ref)(struct _cef_base_t* self)) */
+ public long /*int*/ add_ref;
+
+ // Decrement the reference count. Delete this object when no references
+ // remain.
+// /** @field cast=(int (CEF_CALLBACK *release)(struct _cef_base_t* self)) */
+ public long /*int*/ release;
+
+ // Returns the current number of references.
+// /** @field cast=(int (CEF_CALLBACK *get_refct)(struct _cef_base_t* self)) */
+ public long /*int*/ get_refct;
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_browser_process_handler_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_browser_process_handler_t.java
new file mode 100644
index 0000000000..bfa3c32687
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_browser_process_handler_t.java
@@ -0,0 +1,37 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_browser_process_handler_t extends cef_base_t {
+ ///
+ // Return the handler for proxy events. If no handler is returned the default
+ // system handler will be used. This function is called on the browser process
+ // IO thread.
+ ///
+// /** @field cast=(struct _cef_proxy_handler_t* (CEF_CALLBACK *get_proxy_handler)(struct _cef_browser_process_handler_t* self);
+ public long /*int*/ get_proxy_handler;
+
+ ///
+ // Called on the browser process UI thread immediately after the CEF context
+ // has been initialized.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_context_initialized)(struct _cef_browser_process_handler_t* self);
+ public long /*int*/ on_context_initialized;
+
+ ///
+ // Called on the browser process IO thread before a child process is launched.
+ // Provides an opportunity to modify the child process command line.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_before_child_process_launch)(struct _cef_browser_process_handler_t* self, struct _cef_command_line_t* command_line);
+ public long /*int*/ on_before_child_process_launch;
+
+ ///
+ // Called on the browser process IO thread after the main thread has been
+ // created for a new render process. Provides an opportunity to specify extra
+ // information that will be passed to
+ // cef_render_process_handler_t::on_render_thread_created() in the render
+ // process. Do not keep a reference to |extra_info| outside of this function.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_render_process_thread_created)(struct _cef_browser_process_handler_t* self, struct _cef_list_value_t* extra_info);
+ public long /*int*/ on_render_process_thread_created;
+
+ public static final int sizeof = CEF3.cef_browser_process_handler_t_sizeof();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_browser_settings_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_browser_settings_t.java
new file mode 100644
index 0000000000..d1bbba1cdb
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_browser_settings_t.java
@@ -0,0 +1,230 @@
+package org.eclipse.swt.internal.cef3;
+
+import org.eclipse.swt.browser.CEF;
+
+public class cef_browser_settings_t {
+ public long /*int*/ size;
+
+ /** @field cast=(cef_string_t) */
+ public cef_string_t standard_font_family = CEF.STRING_EMPTY;
+
+ /** @field cast=(cef_string_t) */
+ public cef_string_t fixed_font_family = CEF.STRING_EMPTY;
+
+ /** @field cast=(cef_string_t) */
+ public cef_string_t serif_font_family = CEF.STRING_EMPTY;
+
+ /** @field cast=(cef_string_t) */
+ public cef_string_t sans_serif_font_family = CEF.STRING_EMPTY;
+
+ /** @field cast=(cef_string_t) */
+ public cef_string_t cursive_font_family = CEF.STRING_EMPTY;
+
+ /** @field cast=(cef_string_t) */
+ public cef_string_t fantasy_font_family = CEF.STRING_EMPTY;
+
+ public int default_font_size;
+ public int default_fixed_font_size;
+ public int minimum_font_size;
+ public int minimum_logical_font_size;
+
+ ///
+ // Set to true (1) to disable loading of fonts from remote sources.
+ ///
+ public int remote_fonts_disabled;
+
+ ///
+ // Default encoding for Web content. If empty "ISO-8859-1" will be used.
+ ///
+ /** @field cast=(cef_string_t) */
+ public cef_string_t default_encoding = CEF.STRING_EMPTY;
+
+ ///
+ // Set to true (1) to attempt automatic detection of content encoding.
+ ///
+ public int encoding_detector_enabled;
+
+ ///
+ // Set to true (1) to disable JavaScript.
+ ///
+ public int javascript_disabled;
+
+ ///
+ // Set to true (1) to disallow JavaScript from opening windows.
+ ///
+ public int javascript_open_windows_disallowed;
+
+ ///
+ // Set to true (1) to disallow JavaScript from closing windows.
+ ///
+ public int javascript_close_windows_disallowed;
+
+ ///
+ // Set to true (1) to disallow JavaScript from accessing the clipboard.
+ ///
+ public int javascript_access_clipboard_disallowed;
+
+ ///
+ // Set to true (1) to disable DOM pasting in the editor. DOM pasting also
+ // depends on |javascript_cannot_access_clipboard| being false (0).
+ ///
+ public int dom_paste_disabled;
+
+ ///
+ // Set to true (1) to enable drawing of the caret position.
+ ///
+ public int caret_browsing_enabled;
+
+ ///
+ // Set to true (1) to disable Java.
+ ///
+ public int java_disabled;
+
+ ///
+ // Set to true (1) to disable plugins.
+ ///
+ public int plugins_disabled;
+
+ ///
+ // Set to true (1) to allow access to all URLs from file URLs.
+ ///
+ public int universal_access_from_file_urls_allowed;
+
+ ///
+ // Set to true (1) to allow access to file URLs from other file URLs.
+ ///
+ public int file_access_from_file_urls_allowed;
+
+ ///
+ // Set to true (1) to allow risky security behavior such as cross-site
+ // scripting (XSS). Use with extreme care.
+ ///
+ public int web_security_disabled;
+
+ ///
+ // Set to true (1) to enable console warnings about XSS attempts.
+ ///
+ public int xss_auditor_enabled;
+
+ ///
+ // Set to true (1) to suppress the network load of image URLs. A cached
+ // image will still be rendered if requested.
+ ///
+ public int image_load_disabled;
+
+ ///
+ // Set to true (1) to shrink standalone images to fit the page.
+ ///
+ public int shrink_standalone_images_to_fit;
+
+ ///
+ // Set to true (1) to disable browser backwards compatibility features.
+ ///
+ public int site_specific_quirks_disabled;
+
+ ///
+ // Set to true (1) to disable resize of text areas.
+ ///
+ public int text_area_resize_disabled;
+
+ ///
+ // Set to true (1) to disable use of the page cache.
+ ///
+ public int page_cache_disabled;
+
+ ///
+ // Set to true (1) to not have the tab key advance focus to links.
+ ///
+ public int tab_to_links_disabled;
+
+ ///
+ // Set to true (1) to disable hyperlink pings (<a ping> and window.sendPing).
+ ///
+ public int hyperlink_auditing_disabled;
+
+ ///
+ // Set to true (1) to enable the user style sheet for all pages.
+ ///
+ public int user_style_sheet_enabled;
+
+ ///
+ // Location of the user style sheet. This must be a data URL of the form
+ // "data:text/css;charset=utf-8;base64,csscontent" where "csscontent" is the
+ // base64 encoded contents of the CSS file.
+ ///
+ /** @field cast=(cef_string_t) */
+ public cef_string_t user_style_sheet_location = CEF.STRING_EMPTY;
+
+ ///
+ // Set to true (1) to disable style sheets.
+ ///
+ public int author_and_user_styles_disabled;
+
+ ///
+ // Set to true (1) to disable local storage.
+ ///
+ public int local_storage_disabled;
+
+ ///
+ // Set to true (1) to disable databases.
+ ///
+ public int databases_disabled;
+
+ ///
+ // Set to true (1) to disable application cache.
+ ///
+ public int application_cache_disabled;
+
+ ///
+ // Set to true (1) to disable WebGL.
+ ///
+ public int webgl_disabled;
+
+ ///
+ // Set to true (1) to disable accelerated compositing.
+ ///
+ public int accelerated_compositing_disabled;
+
+ ///
+ // Set to true (1) to disable accelerated layers. This affects features like
+ // 3D CSS transforms.
+ ///
+ public int accelerated_layers_disabled;
+
+ ///
+ // Set to true (1) to disable accelerated video.
+ ///
+ public int accelerated_video_disabled;
+
+ ///
+ // Set to true (1) to disable accelerated 2d canvas.
+ ///
+ public int accelerated_2d_canvas_disabled;
+
+ ///
+ // Set to true (1) to enable accelerated painting.
+ ///
+ public int accelerated_painting_enabled;
+
+ ///
+ // Set to true (1) to enable accelerated filters.
+ ///
+ public int accelerated_filters_enabled;
+
+ ///
+ // Set to true (1) to disable accelerated plugins.
+ ///
+ public int accelerated_plugins_disabled;
+
+ ///
+ // Set to true (1) to disable developer tools (WebKit inspector).
+ ///
+ public int developer_tools_disabled;
+
+ ///
+ // Set to true (1) to enable fullscreen mode.
+ ///
+ public int fullscreen_enabled;
+
+ public static final int sizeof = CEF3.cef_browser_settings_t_sizeof ();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_client_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_client_t.java
new file mode 100644
index 0000000000..693e083005
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_client_t.java
@@ -0,0 +1,62 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_client_t extends cef_base_t {
+ // Return the handler for context menus. If no handler is provided the default
+ // implementation will be used.
+// /** @field cast=(struct _cef_context_menu_handler_t* (CEF_CALLBACK *get_context_menu_handler)(struct _cef_client_t* self)) */
+ public long /*int*/ get_context_menu_handler;
+
+ ///
+ // Return the handler for dialogs. If no handler is provided the default
+ // implementation will be used.
+ ///
+// /** @field cast=(struct _cef_dialog_handler_t* (CEF_CALLBACK *get_dialog_handler)(struct _cef_client_t* self);
+ public long /*int*/ get_dialog_handler;
+
+ // Return the handler for browser display state events.
+// /** @field cast=(struct _cef_display_handler_t* (CEF_CALLBACK *get_display_handler)(struct _cef_client_t* self)) */
+ public long /*int*/ get_display_handler;
+
+ // Return the handler for download events. If no handler is returned downloads
+ // will not be allowed.
+// /** @field cast=(struct _cef_download_handler_t* (CEF_CALLBACK *get_download_handler)(struct _cef_client_t* self)) */
+ public long /*int*/ get_download_handler;
+
+ // Return the handler for focus events.
+// /** @field cast=(struct _cef_focus_handler_t* (CEF_CALLBACK *get_focus_handler)(struct _cef_client_t* self)) */
+ public long /*int*/ get_focus_handler;
+
+ // Return the handler for geolocation permissions requests. If no handler is
+ // provided geolocation access will be denied by default.
+// /** @field cast=(struct _cef_geolocation_handler_t* (CEF_CALLBACK *get_geolocation_handler)(struct _cef_client_t* self)) */
+ public long /*int*/ get_geolocation_handler;
+
+ // Return the handler for JavaScript dialogs. If no handler is provided the
+ // default implementation will be used.
+// /** @field cast=(struct _cef_jsdialog_handler_t* (CEF_CALLBACK *get_jsdialog_handler)(struct _cef_client_t* self)) */
+ public long /*int*/ get_jsdialog_handler;
+
+ // Return the handler for keyboard events.
+// /** @field cast=(struct _cef_keyboard_handler_t* (CEF_CALLBACK *get_keyboard_handler)(struct _cef_client_t* self)) */
+ public long /*int*/ get_keyboard_handler;
+
+ // Return the handler for browser life span events.
+// /** @field cast=(struct _cef_life_span_handler_t* (CEF_CALLBACK *get_life_span_handler)(struct _cef_client_t* self)) */
+ public long /*int*/ get_life_span_handler;
+
+ // Return the handler for browser load status events.
+// /** @field cast=(struct _cef_load_handler_t* (CEF_CALLBACK *get_load_handler)(struct _cef_client_t* self)) */
+ public long /*int*/ get_load_handler;
+
+ // Return the handler for browser request events.
+// /** @field cast=(struct _cef_request_handler_t* (CEF_CALLBACK *get_request_handler)(struct _cef_client_t* self)) */
+ public long /*int*/ get_request_handler;
+
+ // Called when a new message is received from a different process. Return true
+ // (1) if the message was handled or false (0) otherwise. Do not keep a
+ // reference to or attempt to access the message outside of this callback.
+// /** @field cast=(int (CEF_CALLBACK *on_process_message_received)(struct _cef_client_t* self, struct _cef_browser_t* browser, enum cef_process_id_t source_process, struct _cef_process_message_t* message)) */
+ public long /*int*/ on_process_message_received;
+
+ public static final int sizeof = CEF3.cef_client_t_sizeof ();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_command_line_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_command_line_t.java
new file mode 100644
index 0000000000..33dfbd762d
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_command_line_t.java
@@ -0,0 +1,132 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_command_line_t extends cef_base_t {
+ ///
+ // Returns true (1) if this object is valid. Do not call any other functions
+ // if this function returns false (0).
+ ///
+ //int (CEF_CALLBACK *is_valid)(struct _cef_command_line_t* self);
+ public long /*int*/ is_valid;
+
+ ///
+ // Returns true (1) if the values of this object are read-only. Some APIs may
+ // expose read-only objects.
+ ///
+ //int (CEF_CALLBACK *is_read_only)(struct _cef_command_line_t* self);
+ public long /*int*/ is_read_only;
+
+ ///
+ // Returns a writable copy of this object.
+ ///
+ //struct _cef_command_line_t* (CEF_CALLBACK *copy)(struct _cef_command_line_t* self);
+ public long /*int*/ copy;
+
+ ///
+ // Initialize the command line with the specified |argc| and |argv| values.
+ // The first argument must be the name of the program. This function is only
+ // supported on non-Windows platforms.
+ ///
+ //void (CEF_CALLBACK *init_from_argv)(struct _cef_command_line_t* self, int argc, const char* const* argv);
+ public long /*int*/ init_from_argv;
+
+ ///
+ // Initialize the command line with the string returned by calling
+ // GetCommandLineW(). This function is only supported on Windows.
+ ///
+ //void (CEF_CALLBACK *init_from_string)(struct _cef_command_line_t* self, const cef_string_t* command_line);
+ public long /*int*/ init_from_string;
+
+ ///
+ // Reset the command-line switches and arguments but leave the program
+ // component unchanged.
+ ///
+ //void (CEF_CALLBACK *reset)(struct _cef_command_line_t* self);
+ public long /*int*/ reset;
+
+ ///
+ // Constructs and returns the represented command line string. Use this
+ // function cautiously because quoting behavior is unclear.
+ ///
+ // The resulting string must be freed by calling cef_string_userfree_free().
+ //cef_string_userfree_t (CEF_CALLBACK *get_command_line_string)(struct _cef_command_line_t* self);
+ public long /*int*/ get_command_line_string;
+
+ ///
+ // Get the program part of the command line string (the first item).
+ ///
+ // The resulting string must be freed by calling cef_string_userfree_free().
+ //cef_string_userfree_t (CEF_CALLBACK *get_program)(struct _cef_command_line_t* self);
+ public long /*int*/ get_program;
+
+ ///
+ // Set the program part of the command line string (the first item).
+ ///
+ //void (CEF_CALLBACK *set_program)(struct _cef_command_line_t* self, const cef_string_t* program);
+ public long /*int*/ set_program;
+
+ ///
+ // Returns true (1) if the command line has switches.
+ ///
+ //int (CEF_CALLBACK *has_switches)(struct _cef_command_line_t* self);
+
+ ///
+ // Returns true (1) if the command line contains the given switch.
+ ///
+ //int (CEF_CALLBACK *has_switch)(struct _cef_command_line_t* self, const cef_string_t* name);
+ public long /*int*/ has_switch;
+
+ ///
+ // Returns the value associated with the given switch. If the switch has no
+ // value or isn't present this function returns the NULL string.
+ ///
+ // The resulting string must be freed by calling cef_string_userfree_free().
+ //cef_string_userfree_t (CEF_CALLBACK *get_switch_value)(struct _cef_command_line_t* self, const cef_string_t* name);
+ public long /*int*/ get_switch_value;
+
+ ///
+ // Returns the map of switch names and values. If a switch has no value an
+ // NULL string is returned.
+ ///
+ //void (CEF_CALLBACK *get_switches)(struct _cef_command_line_t* self, cef_string_map_t switches);
+ public long /*int*/ get_switches;
+
+ ///
+ // Add a switch to the end of the command line. If the switch has no value
+ // pass an NULL value string.
+ ///
+ //void (CEF_CALLBACK *append_switch)(struct _cef_command_line_t* self, const cef_string_t* name);
+ public long /*int*/ append_switch;
+
+ ///
+ // Add a switch with the specified value to the end of the command line.
+ ///
+ //void (CEF_CALLBACK *append_switch_with_value)(struct _cef_command_line_t* self, const cef_string_t* name, const cef_string_t* value);
+ public long /*int*/ append_switch_with_value;
+
+ ///
+ // True if there are remaining command line arguments.
+ ///
+ //int (CEF_CALLBACK *has_arguments)(struct _cef_command_line_t* self);
+ public long /*int*/ has_arguments;
+
+ ///
+ // Get the remaining command line arguments.
+ ///
+ //void (CEF_CALLBACK *get_arguments)(struct _cef_command_line_t* self, cef_string_list_t arguments);
+ public long /*int*/ get_arguments;
+
+ ///
+ // Add an argument to the end of the command line.
+ ///
+ //void (CEF_CALLBACK *append_argument)(struct _cef_command_line_t* self, const cef_string_t* argument);
+ public long /*int*/ append_argument;
+
+ ///
+ // Insert a command before the current command. Common for debuggers, like
+ // "valgrind" or "gdb --args".
+ ///
+ //void (CEF_CALLBACK *prepend_wrapper)(struct _cef_command_line_t* self, const cef_string_t* wrapper);
+ public long /*int*/ prepend_wrapper;
+
+ public static final int sizeof = CEF3.cef_command_line_t_sizeof();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_context_menu_handler_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_context_menu_handler_t.java
new file mode 100644
index 0000000000..ab6e1cd2c7
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_context_menu_handler_t.java
@@ -0,0 +1,28 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_context_menu_handler_t extends cef_base_t {
+ // Called before a context menu is displayed. |params| provides information
+ // about the context menu state. |model| initially contains the default
+ // context menu. The |model| can be cleared to show no context menu or
+ // modified to show a custom menu. Do not keep references to |params| or
+ // |model| outside of this callback.
+ // /** @field cast=(void (CEF_CALLBACK *on_before_context_menu) (struct _cef_context_menu_handler_t* self, struct _cef_browser_t* browser, struct _cef_frame_t* frame, struct _cef_context_menu_params_t* params, struct _cef_menu_model_t* model))
+ public long /*int*/ on_before_context_menu;
+
+ // Called to execute a command selected from the context menu. Return true (1)
+ // if the command was handled or false (0) for the default implementation. See
+ // cef_menu_id_t for the command ids that have default implementations. All
+ // user-defined command ids should be between MENU_ID_USER_FIRST and
+ // MENU_ID_USER_LAST. |params| will have the same values as what was passed to
+ // on_before_context_menu(). Do not keep a reference to |params| outside of
+ // this callback.
+ // /** @field cast=(int (CEF_CALLBACK *on_context_menu_command)(struct _cef_context_menu_handler_t* self, struct _cef_browser_t* browser, struct _cef_frame_t* frame, struct _cef_context_menu_params_t* params, int command_id, enum cef_event_flags_t event_flags))
+ public long /*int*/ on_context_menu_command;
+
+ // Called when the context menu is dismissed irregardless of whether the menu
+ // was NULL or a command was selected.
+ // /** @field cast=(void (CEF_CALLBACK *on_context_menu_dismissed)(struct _cef_context_menu_handler_t* self, struct _cef_browser_t* browser, struct _cef_frame_t* frame))
+ public long /*int*/ on_context_menu_dismissed;
+
+ public static final int sizeof = CEF3.cef_context_menu_handler_t_sizeof ();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_display_handler_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_display_handler_t.java
new file mode 100644
index 0000000000..4ad458dcd5
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_display_handler_t.java
@@ -0,0 +1,36 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_display_handler_t extends cef_base_t {
+ // Called when the loading state has changed.
+ // /** @field cast=(void (CEF_CALLBACK *on_loading_state_change)(struct _cef_display_handler_t* self, struct _cef_browser_t* browser, int isLoading, int canGoBack, int canGoForward))
+ public long /*int*/ on_loading_state_change;
+
+ // Called when a frame's address has changed.
+ // /** @field cast=(void (CEF_CALLBACK *on_address_change)(struct _cef_display_handler_t* self, struct _cef_browser_t* browser, struct _cef_frame_t* frame, const cef_string_t* url))
+ public long /*int*/ on_address_change;
+
+ // Called when the page title changes.
+ // /** @field cast=(void (CEF_CALLBACK *on_title_change)(struct _cef_display_handler_t* self, struct _cef_browser_t* browser, const cef_string_t* title))
+ public long /*int*/ on_title_change;
+
+ // Called when the browser is about to display a tooltip. |text| contains the
+ // text that will be displayed in the tooltip. To handle the display of the
+ // tooltip yourself return true (1). Otherwise, you can optionally modify
+ // |text| and then return false (0) to allow the browser to display the
+ // tooltip.
+ // /** @field cast=(int (CEF_CALLBACK *on_tooltip)(struct _cef_display_handler_t* self, struct _cef_browser_t* browser, cef_string_t* text))
+ public long /*int*/ on_tooltip;
+
+ // Called when the browser receives a status message. |text| contains the text
+ // that will be displayed in the status message and |type| indicates the
+ // status message type.
+ // /** @field cast=(void (CEF_CALLBACK *on_status_message)(struct _cef_display_handler_t* self, struct _cef_browser_t* browser, const cef_string_t* value))
+ public long /*int*/ on_status_message;
+
+ // Called to display a console message. Return true (1) to stop the message
+ // from being output to the console.
+ // /** @field cast=(int (CEF_CALLBACK *on_console_message)(struct _cef_display_handler_t* self, struct _cef_browser_t* browser, const cef_string_t* message, const cef_string_t* source, int line))
+ public long /*int*/ on_console_message;
+
+ public static final int sizeof = CEF3.cef_display_handler_t_sizeof ();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_focus_handler_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_focus_handler_t.java
new file mode 100644
index 0000000000..5bc2aee44a
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_focus_handler_t.java
@@ -0,0 +1,22 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_focus_handler_t extends cef_base_t {
+ // Called when the browser component is about to loose focus. For instance, if
+ // focus was on the last HTML element and the user pressed the TAB key. |next|
+ // will be true (1) if the browser is giving focus to the next component and
+ // false (0) if the browser is giving focus to the previous component.
+// /** @field cast=(void (CEF_CALLBACK *on_take_focus)(struct _cef_focus_handler_t* self, struct _cef_browser_t* browser, int next);
+ public long /*int*/ on_take_focus;
+
+ // Called when the browser component is requesting focus. |source| indicates
+ // where the focus request is originating from. Return false (0) to allow the
+ // focus to be set or true (1) to cancel setting the focus.
+// /** @field cast=(int (CEF_CALLBACK *on_set_focus)(struct _cef_focus_handler_t* self, struct _cef_browser_t* browser, enum cef_focus_source_t source);
+ public long /*int*/ on_set_focus;
+
+ // Called when the browser component has received focus.
+// /** @field cast=(void (CEF_CALLBACK *on_got_focus)(struct _cef_focus_handler_t* self, struct _cef_browser_t* browser);
+ public long /*int*/ on_got_focus;
+
+ public static final int sizeof = CEF3.cef_focus_handler_t_sizeof ();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_life_span_handler_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_life_span_handler_t.java
new file mode 100644
index 0000000000..7012ca3f31
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_life_span_handler_t.java
@@ -0,0 +1,41 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_life_span_handler_t extends cef_base_t {
+ // Called before a new popup window is created. The |parentBrowser| parameter
+ // will point to the parent browser window. The |popupFeatures| parameter will
+ // contain information about the style of popup window requested. Return false
+ // (0) to have the framework create the new popup window based on the
+ // parameters in |windowInfo|. Return true (1) to cancel creation of the popup
+ // window. By default, a newly created popup window will have the same client
+ // and settings as the parent window. To change the client for the new window
+ // modify the object that |client| points to. To change the settings for the
+ // new window modify the |settings| structure.
+// /** @field cast=(int (CEF_CALLBACK *on_before_popup)(struct _cef_life_span_handler_t* self, struct _cef_browser_t* parentBrowser, const struct _cef_popup_features_t* popupFeatures, struct _cef_window_info_t* windowInfo, const cef_string_t* url, struct _cef_client_t** client, struct _cef_browser_settings_t* settings);
+ public long /*int*/ on_before_popup;
+
+ // Called after a new window is created.
+// /** @field cast=(void (CEF_CALLBACK *on_after_created)(struct _cef_life_span_handler_t* self, struct _cef_browser_t* browser);
+ public long /*int*/ on_after_created;
+
+ // Called when a modal window is about to display and the modal loop should
+ // begin running. Return false (0) to use the default modal loop
+ // implementation or true (1) to use a custom implementation.
+// /** @field cast=(int (CEF_CALLBACK *run_modal)(struct _cef_life_span_handler_t* self, struct _cef_browser_t* browser);
+ public long /*int*/ run_modal;
+
+ // Called when a window has recieved a request to close. Return false (0) to
+ // proceed with the window close or true (1) to cancel the window close. If
+ // this is a modal window and a custom modal loop implementation was provided
+ // in run_modal() this callback should be used to restore the opener window to
+ // a usable state.
+// /** @field cast=(int (CEF_CALLBACK *do_close)(struct _cef_life_span_handler_t* self, struct _cef_browser_t* browser);
+ public long /*int*/ do_close;
+
+ // Called just before a window is closed. If this is a modal window and a
+ // custom modal loop implementation was provided in run_modal() this callback
+ // should be used to exit the custom modal loop.
+// /** @field cast=(void (CEF_CALLBACK *on_before_close)(struct _cef_life_span_handler_t* self, struct _cef_browser_t* browser);
+ public long /*int*/ on_before_close;
+
+ public static final int sizeof = CEF3.cef_life_span_handler_t_sizeof();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_load_handler_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_load_handler_t.java
new file mode 100644
index 0000000000..931aa311c1
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_load_handler_t.java
@@ -0,0 +1,50 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_load_handler_t extends cef_base_t {
+ ///
+ // Called when the browser begins loading a frame. The |frame| value will
+ // never be NULL -- call the is_main() function to check if this frame is the
+ // main frame. Multiple frames may be loading at the same time. Sub-frames may
+ // start or continue loading after the main frame load has ended. This
+ // function may not be called for a particular frame if the load request for
+ // that frame fails.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_load_start)(struct _cef_load_handler_t* self,struct _cef_browser_t* browser, struct _cef_frame_t* frame);
+ public long /*int*/ on_load_start;
+
+ ///
+ // Called when the browser is done loading a frame. The |frame| value will
+ // never be NULL -- call the is_main() function to check if this frame is the
+ // main frame. Multiple frames may be loading at the same time. Sub-frames may
+ // start or continue loading after the main frame load has ended. This
+ // function will always be called for all frames irrespective of whether the
+ // request completes successfully.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_load_end)(struct _cef_load_handler_t* self, struct _cef_browser_t* browser, struct _cef_frame_t* frame, int httpStatusCode);
+ public long /*int*/ on_load_end;
+
+ ///
+ // Called when the browser fails to load a resource. |errorCode| is the error
+ // code number, |errorText| is the error text and and |failedUrl| is the URL
+ // that failed to load. See net\base\net_error_list.h for complete
+ // descriptions of the error codes.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_load_error)(struct _cef_load_handler_t* self, struct _cef_browser_t* browser, struct _cef_frame_t* frame, enum cef_errorcode_t errorCode, const cef_string_t* errorText, const cef_string_t* failedUrl);
+ public long /*int*/ on_load_error;
+
+ ///
+ // Called when the render process terminates unexpectedly. |status| indicates
+ // how the process terminated.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_render_process_terminated)(struct _cef_load_handler_t* self, struct _cef_browser_t* browser, enum cef_termination_status_t status);
+ public long /*int*/ on_render_process_terminated;
+
+ ///
+ // Called when a plugin has crashed. |plugin_path| is the path of the plugin
+ // that crashed.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_plugin_crashed)(struct _cef_load_handler_t* self, struct _cef_browser_t* browser, const cef_string_t* plugin_path);
+ public long /*int*/ on_plugin_crashed;
+
+ public static final int sizeof = CEF3.cef_load_handler_t_sizeof();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_main_args_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_main_args_t.java
new file mode 100644
index 0000000000..81b14eaf2e
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_main_args_t.java
@@ -0,0 +1,6 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_main_args_t {
+ /** @field cast=(HINSTANCE) */
+ public long /*int*/ instance;
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_proxy_handler_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_proxy_handler_t.java
new file mode 100644
index 0000000000..b015474dad
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_proxy_handler_t.java
@@ -0,0 +1,11 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_proxy_handler_t extends cef_base_t {
+ ///
+ // Called to retrieve proxy information for the specified |url|.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *get_proxy_for_url)(struct _cef_proxy_handler_t* self,const cef_string_t* url, struct _cef_proxy_info_t* proxy_info);
+ public long /*int*/ get_proxy_for_url;
+
+ public static final int sizeof = CEF3.cef_proxy_handler_t_sizeof();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_request_handler_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_request_handler_t.java
new file mode 100644
index 0000000000..7ba07fbf89
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_request_handler_t.java
@@ -0,0 +1,78 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_request_handler_t extends cef_base_t {
+ ///
+ // Called on the IO thread before a resource request is loaded. The |request|
+ // object may be modified. To cancel the request return true (1) otherwise
+ // return false (0).
+ ///
+// /** @field cast=(int (CEF_CALLBACK *on_before_resource_load)(struct _cef_request_handler_t* self, struct _cef_browser_t* browser, struct _cef_frame_t* frame, struct _cef_request_t* request);
+ public long /*int*/ on_before_resource_load;
+
+ ///
+ // Called on the IO thread before a resource is loaded. To allow the resource
+ // to load normally return NULL. To specify a handler for the resource return
+ // a cef_resource_handler_t object. The |request| object should not be
+ // modified in this callback.
+ ///
+// /** @field cast=(struct _cef_resource_handler_t* (CEF_CALLBACK *get_resource_handler)(struct _cef_request_handler_t* self, struct _cef_browser_t* browser, struct _cef_frame_t* frame, struct _cef_request_t* request);
+ public long /*int*/ get_resource_handler;
+
+ ///
+ // Called on the IO thread when a resource load is redirected. The |old_url|
+ // parameter will contain the old URL. The |new_url| parameter will contain
+ // the new URL and can be changed if desired.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_resource_redirect)(struct _cef_request_handler_t* self, struct _cef_browser_t* browser, struct _cef_frame_t* frame, const cef_string_t* old_url, cef_string_t* new_url);
+ public long /*int*/ on_resource_redirect;
+
+ ///
+ // Called on the IO thread when the browser needs credentials from the user.
+ // |isProxy| indicates whether the host is a proxy server. |host| contains the
+ // hostname and |port| contains the port number. Return true (1) to continue
+ // the request and call cef_auth_callback_t::Complete() when the
+ // authentication information is available. Return false (0) to cancel the
+ // request.
+ ///
+// /** @field cast=(int (CEF_CALLBACK *get_auth_credentials)(struct _cef_request_handler_t* self, struct _cef_browser_t* browser, struct _cef_frame_t* frame, int isProxy, const cef_string_t* host, int port, const cef_string_t* realm, const cef_string_t* scheme, struct _cef_auth_callback_t* callback);
+ public long /*int*/ get_auth_credentials;
+
+ ///
+ // Called on the IO thread when JavaScript requests a specific storage quota
+ // size via the webkitStorageInfo.requestQuota function. |origin_url| is the
+ // origin of the page making the request. |new_size| is the requested quota
+ // size in bytes. Return true (1) and call cef_quota_callback_t::Complete()
+ // either in this function or at a later time to grant or deny the request.
+ // Return false (0) to cancel the request.
+ ///
+// /** @field cast=(int (CEF_CALLBACK *on_quota_request)(struct _cef_request_handler_t* self, struct _cef_browser_t* browser, const cef_string_t* origin_url, int64 new_size, struct _cef_quota_callback_t* callback);
+ public long /*int*/ on_quota_request;
+
+ ///
+ // Called on the IO thread to retrieve the cookie manager. |main_url| is the
+ // URL of the top-level frame. Cookies managers can be unique per browser or
+ // shared across multiple browsers. The global cookie manager will be used if
+ // this function returns NULL.
+ ///
+// /** @field cast=(struct _cef_cookie_manager_t* (CEF_CALLBACK *get_cookie_manager)(struct _cef_request_handler_t* self, struct _cef_browser_t* browser, const cef_string_t* main_url);
+ public long /*int*/ get_cookie_manager;
+
+ ///
+ // Called on the UI thread to handle requests for URLs with an unknown
+ // protocol component. Set |allow_os_execution| to true (1) to attempt
+ // execution via the registered OS protocol handler, if any. SECURITY WARNING:
+ // YOU SHOULD USE THIS METHOD TO ENFORCE RESTRICTIONS BASED ON SCHEME, HOST OR
+ // OTHER URL ANALYSIS BEFORE ALLOWING OS EXECUTION.
+ ///
+// /** @field cast=(void (CEF_CALLBACK *on_protocol_execution)(struct _cef_request_handler_t* self, struct _cef_browser_t* browser, const cef_string_t* url, int* allow_os_execution);
+ public long /*int*/ on_protocol_execution;
+
+ ///
+ // Called on the browser process IO thread before a plugin is loaded. Return
+ // true (1) to block loading of the plugin.
+ ///
+// /** @field cast=(int (CEF_CALLBACK *on_before_plugin_load)(struct _cef_request_handler_t* self, struct _cef_browser_t* browser, const cef_string_t* url, const cef_string_t* policy_url, struct _cef_web_plugin_info_t* info);
+ public long /*int*/ on_before_plugin_load;
+
+ public static final int sizeof = CEF3.cef_request_handler_t_sizeof();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_resource_bundle_handler_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_resource_bundle_handler_t.java
new file mode 100644
index 0000000000..33841995c5
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_resource_bundle_handler_t.java
@@ -0,0 +1,25 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_resource_bundle_handler_t extends cef_base_t {
+ ///
+ // Called to retrieve a localized translation for the string specified by
+ // |message_id|. To provide the translation set |string| to the translation
+ // string and return true (1). To use the default translation return false
+ // (0). Supported message IDs are listed in cef_pack_strings.h.
+ ///
+// /** @field cast=(int (CEF_CALLBACK *get_localized_string)(struct _cef_resource_bundle_handler_t* self, int message_id, cef_string_t* string)) */
+ public long /*int*/ get_localized_string;
+
+ ///
+ // Called to retrieve data for the resource specified by |resource_id|. To
+ // provide the resource data set |data| and |data_size| to the data pointer
+ // and size respectively and return true (1). To use the default resource data
+ // return false (0). The resource data will not be copied and must remain
+ // resident in memory. Supported resource IDs are listed in
+ // cef_pack_resources.h.
+ ///
+// /** @field cast=(int (CEF_CALLBACK *get_data_resource)(struct _cef_resource_bundle_handler_t* self, int resource_id, void** data, size_t* data_size))
+ public long /*int*/ get_data_resource;
+
+ public static final int sizeof = CEF3.cef_resource_bundle_handler_t_sizeof ();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_settings_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_settings_t.java
new file mode 100644
index 0000000000..722e941a3e
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_settings_t.java
@@ -0,0 +1,143 @@
+package org.eclipse.swt.internal.cef3;
+
+import org.eclipse.swt.browser.CEF;
+
+public class cef_settings_t {
+ // Size of this structure.
+ /** @field cast=(size_t) */
+ public long /*int*/ size;
+
+ // Set to true (1) to use a single process for the browser and renderer. This
+ // run mode is not officially supported by Chromium and is less stable than
+ // the multi-process default.
+ /** @field cast=(bool) */
+ public int single_process;
+
+ // The path to a separate executable that will be launched for sub-processes.
+ // By default the browser process executable is used. See the comments on
+ // CefExecuteProcess() for details.
+ /** @field cast=(cef_string_t) */
+ public cef_string_t browser_subprocess_path = CEF.STRING_EMPTY;
+
+ // Set to true (1) to have the browser process message loop run in a separate
+ // thread. If false (0) than the CefDoMessageLoopWork() function must be
+ // called from your application message loop.
+ /** @field cast=(bool) */
+ public int multi_threaded_message_loop;
+
+ // Set to true (1) to disable configuration of browser process features using
+ // standard CEF and Chromium command-line arguments. Configuration can still
+ // be specified using CEF data structures or via the
+ // CefApp::OnBeforeCommandLineProcessing() method.
+ /** @field cast=(bool) */
+ public int command_line_args_disabled;
+
+ // The location where cache data will be stored on disk. If empty an in-memory
+ // cache will be used. HTML5 databases such as localStorage will only persist
+ // across sessions if a cache path is specified.
+ /** @field cast=(cef_string_t) */
+ public cef_string_t cache_path = CEF.STRING_EMPTY;
+
+ // Value that will be returned as the User-Agent HTTP header. If empty the
+ // default User-Agent string will be used.
+ /** @field cast=(cef_string_t) */
+ public cef_string_t user_agent = CEF.STRING_EMPTY;
+
+ // Value that will be inserted as the product portion of the default
+ // User-Agent string. If empty the Chromium product version will be used. If
+ // |userAgent| is specified this value will be ignored.
+ /** @field cast=(cef_string_t) */
+ public cef_string_t product_version = CEF.STRING_EMPTY;
+
+ // The locale string that will be passed to WebKit. If empty the default
+ // locale of "en-US" will be used. This value is ignored on Linux where locale
+ // is determined using environment variable parsing with the precedence order:
+ // LANGUAGE, LC_ALL, LC_MESSAGES and LANG.
+ /** @field cast=(cef_string_t) */
+ public cef_string_t locale = CEF.STRING_EMPTY;
+
+ // The directory and file name to use for the debug log. If empty, the
+ // default name of "debug.log" will be used and the file will be written
+ // to the application directory.
+ /** @field cast=(cef_string_t) */
+ public cef_string_t log_file = CEF.STRING_EMPTY;
+
+ // The log severity. Only messages of this severity level or higher will be
+ // logged.
+ /** @field cast=(int) */ //GWG should be cef_log_severity_t
+ public int log_severity;
+
+ ///
+ // Enable DCHECK in release mode to ease debugging.
+ ///
+ /** @field cast=(bool) */
+ public int release_dcheck_enabled;
+
+ // Custom flags that will be used when initializing the V8 JavaScript engine.
+ // The consequences of using custom flags may not be well tested.
+ /** @field cast=(cef_string_t) */
+ public cef_string_t javascript_flags = CEF.STRING_EMPTY;
+
+ // Set to true (1) to use the system proxy resolver on Windows when
+ // "Automatically detect settings" is checked. This setting is disabled
+ // by default for performance reasons.
+ /** @field cast=(bool) */
+ public int auto_detect_proxy_settings_enabled;
+
+ // The fully qualified path for the resources directory. If this value is
+ // empty the cef.pak and/or devtools_resources.pak files must be located in
+ // the module directory on Windows/Linux or the app bundle Resources directory
+ // on Mac OS X.
+ /** @field cast=(cef_string_t) */
+ public cef_string_t resources_dir_path = CEF.STRING_EMPTY;
+
+ // The fully qualified path for the locales directory. If this value is empty
+ // the locales directory must be located in the module directory. This value
+ // is ignored on Mac OS X where pack files are always loaded from the app
+ // bundle Resources directory.
+ /** @field cast=(cef_string_t) */
+ public cef_string_t locales_dir_path = CEF.STRING_EMPTY;
+
+ // Set to true (1) to disable loading of pack files for resources and locales.
+ // A resource bundle handler must be provided for the browser and render
+ // processes via CefApp::GetResourceBundleHandler() if loading of pack files
+ // is disabled.
+ /** @field cast=(bool) */
+ public int pack_loading_disabled;
+
+ // Set to a value between 1024 and 65535 to enable remote debugging on the
+ // specified port. For example, if 8080 is specified the remote debugging URL
+ // will be http://localhost:8080. CEF can be remotely debugged from any CEF or
+ // Chrome browser window.
+ /** @field cast=(int) */
+ public int remote_debugging_port;
+
+ ///
+ // The number of stack trace frames to capture for uncaught exceptions.
+ // Specify a positive value to enable the CefV8ContextHandler::
+ // OnUncaughtException() callback. Specify 0 (default value) and
+ // OnUncaughtException() will not be called.
+ ///
+ public int uncaught_exception_stack_size;
+
+ ///
+ // By default CEF V8 references will be invalidated (the IsValid() method will
+ // return false) after the owning context has been released. This reduces the
+ // need for external record keeping and avoids crashes due to the use of V8
+ // references after the associated context has been released.
+ //
+ // CEF currently offers two context safety implementations with different
+ // performance characteristics. The default implementation (value of 0) uses a
+ // map of hash values and should provide better performance in situations with
+ // a small number contexts. The alternate implementation (value of 1) uses a
+ // hidden value attached to each context and should provide better performance
+ // in situations with a large number of contexts.
+ //
+ // If you need better performance in the creation of V8 references and you
+ // plan to manually track context lifespan you can disable context safety by
+ // specifying a value of -1.
+ ///
+ public int context_safety_implementation;
+
+ public static final int sizeof = CEF3.cef_settings_t_sizeof ();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_string_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_string_t.java
new file mode 100644
index 0000000000..1f78c1c874
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_string_t.java
@@ -0,0 +1,12 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_string_t {
+ /** @field cast=(void *) */
+ public long /*int*/ str;
+ /** @field cast=(size_t) */
+ public long /*int*/ length;
+ /** @field cast=(void (__cdecl *)(void *)) */
+ public long /*int*/ dtor;
+
+ public static final int sizeof = CEF3.cef_string_t_sizeof ();
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_window_info_t.java b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_window_info_t.java
new file mode 100644
index 0000000000..28560ed1a4
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT CEF/win32/org/eclipse/swt/internal/cef3/cef_window_info_t.java
@@ -0,0 +1,31 @@
+package org.eclipse.swt.internal.cef3;
+
+public class cef_window_info_t {
+ // Standard parameters required by CreateWindowEx()
+ /** @field cast=(DWORD) */
+ public int ex_style;
+ /** @field cast=(cef_string_t) */
+ public cef_string_t window_name;
+ /** @field cast=(DWORD) */
+ public int style;
+ /** @field cast=(int) */
+ public int x;
+ /** @field cast=(int) */
+ public int y;
+ /** @field cast=(int) */
+ public int width;
+ /** @field cast=(int) */
+ public int height;
+ /** @field cast=(cef_window_handle_t) */
+ public long /*int*/ parent_window;
+ /** @field cast=(HMENU) */
+ public long /*int*/ menu;
+
+ // Set to true to enable transparent painting.
+ /** @field cast=(BOOL) */
+ public int transparent_painting;
+
+ // Handle for the new browser window.
+ /** @field cast=(cef_window_handle_t) */ // on win32 it's an HWND
+ public long /*int*/ window;
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/XPCOMObject.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/XPCOMObject.java
index 9899a99c9c..61f2998844 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/XPCOMObject.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/XPCOMObject.java
@@ -10,1022 +10,39 @@
*******************************************************************************/
package org.eclipse.swt.internal.mozilla;
-import java.util.*;
-import org.eclipse.swt.*;
+import org.eclipse.swt.SWT;
import org.eclipse.swt.internal.*;
-public class XPCOMObject {
- static boolean IsSolaris;
- static {
- String osName = System.getProperty ("os.name").toLowerCase (); //$NON-NLS-1$
- IsSolaris = osName.startsWith ("sunos") || osName.startsWith("solaris"); //$NON-NLS-1$
- }
-
- private long /*int*/ ppVtable;
-
- static private final int MAX_ARG_COUNT = 12;
- static private final int MAX_VTABLE_LENGTH = 80;
- static final int OS_OFFSET = IsSolaris ? 2 : 0;
- static private Callback[][] Callbacks = new Callback[MAX_VTABLE_LENGTH + OS_OFFSET][MAX_ARG_COUNT];
- static private Hashtable ObjectMap = new Hashtable ();
-
+public class XPCOMObject extends OSObject {
public XPCOMObject (int[] argCounts) {
- long /*int*/[] callbackAddresses = new long /*int*/[argCounts.length + OS_OFFSET];
+ super (argCounts);
+}
+
+protected long /*int*/ create (int[] argCounts, int os_offset) {
+ long /*int*/[] callbackAddresses = new long /*int*/[argCounts.length + os_offset];
synchronized (Callbacks) {
for (int i = 0, length = argCounts.length; i < length; i++) {
- if ((Callbacks[i + OS_OFFSET][argCounts[i]]) == null) {
- Callbacks[i + OS_OFFSET][argCounts[i]] = new Callback (getClass (), "callback"+i, argCounts[i] + 1, true, XPCOM.NS_ERROR_FAILURE); //$NON-NLS-1$
+ if ((Callbacks[i + os_offset][argCounts[i]]) == null) {
+ Callbacks[i + os_offset][argCounts[i]] = new Callback (getClass (), "callback"+i, argCounts[i] + 1, true, XPCOM.NS_ERROR_FAILURE); //$NON-NLS-1$
}
- callbackAddresses[i + OS_OFFSET] = Callbacks[i + OS_OFFSET][argCounts[i]].getAddress ();
- if (callbackAddresses[i + OS_OFFSET] == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
+ callbackAddresses[i + os_offset] = Callbacks[i + os_offset][argCounts[i]].getAddress ();
+ if (callbackAddresses[i + os_offset] == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
}
}
- long /*int*/ pVtable = C.malloc (C.PTR_SIZEOF * (argCounts.length + OS_OFFSET));
- XPCOM.memmove (pVtable, callbackAddresses, C.PTR_SIZEOF * (argCounts.length + OS_OFFSET));
- ppVtable = C.malloc (C.PTR_SIZEOF);
- XPCOM.memmove (ppVtable, new long /*int*/[] {pVtable}, C.PTR_SIZEOF);
- ObjectMap.put (new LONG (ppVtable), this);
-}
-
-static long /*int*/ callback0 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method0 (args);
-}
-static long /*int*/ callback1 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method1 (args);
-}
-static long /*int*/ callback10 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method10 (args);
-}
-static long /*int*/ callback11 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method11 (args);
-}
-static long /*int*/ callback12 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method12 (args);
-}
-static long /*int*/ callback13 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method13 (args);
-}
-static long /*int*/ callback14 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method14 (args);
-}
-static long /*int*/ callback15 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method15 (args);
-}
-static long /*int*/ callback16 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method16 (args);
-}
-static long /*int*/ callback17 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method17 (args);
-}
-static long /*int*/ callback18 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method18 (args);
-}
-static long /*int*/ callback19 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method19 (args);
-}
-static long /*int*/ callback2 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method2 (args);
-}
-static long /*int*/ callback20 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method20 (args);
-}
-static long /*int*/ callback21 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method21 (args);
-}
-static long /*int*/ callback22 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method22 (args);
-}
-static long /*int*/ callback23 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method23 (args);
-}
-static long /*int*/ callback24 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method24 (args);
-}
-static long /*int*/ callback25 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method25 (args);
-}
-static long /*int*/ callback26 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method26 (args);
-}
-static long /*int*/ callback27 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method27 (args);
-}
-static long /*int*/ callback28 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method28 (args);
-}
-static long /*int*/ callback29 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method29 (args);
-}
-static long /*int*/ callback3 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method3 (args);
-}
-static long /*int*/ callback30 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method30 (args);
-}
-static long /*int*/ callback31 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method31 (args);
-}
-static long /*int*/ callback32 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method32 (args);
-}
-static long /*int*/ callback33 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method33 (args);
-}
-static long /*int*/ callback34 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method34 (args);
-}
-static long /*int*/ callback35 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method35 (args);
-}
-static long /*int*/ callback36 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method36 (args);
-}
-static long /*int*/ callback37 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method37 (args);
-}
-static long /*int*/ callback38 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method38 (args);
-}
-static long /*int*/ callback39 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method39 (args);
-}
-static long /*int*/ callback4 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method4 (args);
-}
-static long /*int*/ callback40 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method40 (args);
-}
-static long /*int*/ callback41 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method41 (args);
-}
-static long /*int*/ callback42 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method42 (args);
-}
-static long /*int*/ callback43 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method43 (args);
-}
-static long /*int*/ callback44 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method44 (args);
-}
-static long /*int*/ callback45 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method45 (args);
-}
-static long /*int*/ callback46 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method46 (args);
-}
-static long /*int*/ callback47 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method47 (args);
-}
-static long /*int*/ callback48 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method48 (args);
-}
-static long /*int*/ callback49 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method49 (args);
-}
-static long /*int*/ callback5 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method5 (args);
-}
-static long /*int*/ callback50 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method50 (args);
-}
-static long /*int*/ callback51 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method51 (args);
-}
-static long /*int*/ callback52 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method52 (args);
-}
-static long /*int*/ callback53 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method53 (args);
-}
-static long /*int*/ callback54 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method54 (args);
-}
-static long /*int*/ callback55 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method55 (args);
-}
-static long /*int*/ callback56 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method56 (args);
-}
-static long /*int*/ callback57 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method57 (args);
-}
-static long /*int*/ callback58 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method58 (args);
-}
-static long /*int*/ callback59 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method59 (args);
-}
-static long /*int*/ callback6 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method6 (args);
-}
-static long /*int*/ callback60 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method60 (args);
-}
-static long /*int*/ callback61 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method61 (args);
-}
-static long /*int*/ callback62 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method62 (args);
-}
-static long /*int*/ callback63 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method63 (args);
-}
-static long /*int*/ callback64 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method64 (args);
-}
-static long /*int*/ callback65 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method65 (args);
-}
-static long /*int*/ callback66 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method66 (args);
-}
-static long /*int*/ callback67 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method67 (args);
-}
-static long /*int*/ callback68 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method68 (args);
-}
-static long /*int*/ callback69 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method69 (args);
-}
-static long /*int*/ callback7 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method7 (args);
-}
-static long /*int*/ callback70 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method70 (args);
-}
-static long /*int*/ callback71 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method71 (args);
-}
-static long /*int*/ callback72 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method72 (args);
-}
-static long /*int*/ callback73 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method73 (args);
-}
-static long /*int*/ callback74 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method74 (args);
-}
-static long /*int*/ callback75 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method75 (args);
-}
-static long /*int*/ callback76 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method76 (args);
-}
-static long /*int*/ callback77 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method77 (args);
-}
-static long /*int*/ callback78 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method78 (args);
-}
-static long /*int*/ callback79 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method79 (args);
-}
-static long /*int*/ callback8 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method8 (args);
-}
-static long /*int*/ callback9 (long /*int*/[] callbackArgs) {
- // find the object on which this call was invoked
- long /*int*/ address = callbackArgs[0];
- Object object = ObjectMap.get (new LONG (address));
- if (object == null) return XPCOM.NS_ERROR_FAILURE;
- long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
- System.arraycopy (callbackArgs, 1, args, 0, args.length);
- return ((XPCOMObject) object).method9 (args);
+ long /*int*/ pVtable = C.malloc (C.PTR_SIZEOF * (argCounts.length + os_offset));
+ XPCOM.memmove (pVtable, callbackAddresses, C.PTR_SIZEOF * (argCounts.length + os_offset));
+ long /*int*/ result = C.malloc (C.PTR_SIZEOF);
+ XPCOM.memmove (result, new long /*int*/[] {pVtable}, C.PTR_SIZEOF);
+ return result;
}
-public void dispose() {
- // free the memory for this reference
+protected void release (long /*int*/ handle) {
long /*int*/[] pVtable = new long /*int*/[1];
- XPCOM.memmove (pVtable, ppVtable, C.PTR_SIZEOF);
+ XPCOM.memmove (pVtable, handle, C.PTR_SIZEOF);
C.free (pVtable[0]);
- C.free (ppVtable);
-
- // remove this ppVtable from the list
- ObjectMap.remove (new LONG (ppVtable));
-
- ppVtable = 0;
-}
-
-public long /*int*/ getAddress () {
- return ppVtable;
+ C.free (handle);
}
-public long /*int*/ method0 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method1 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method10 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method11 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method12 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method13 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method14 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method15 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method16 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method17 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method18 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method19 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method2 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method20 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method21 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method22 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method23 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method24 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method25 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method26 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method27 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method28 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method29 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method3 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method30 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method31 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method32 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method33 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method34 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method35 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method36 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method37 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method38 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method39 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method4 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method40 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method41 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method42 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method43 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
}
-public long /*int*/ method44 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method45 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method46 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method47 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method48 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method49 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method5 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method50 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method51 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method52 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method53 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method54 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method55 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method56 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method57 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method58 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method59 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method6 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method60 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method61 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method62 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method63 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method64 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method65 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method66 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method67 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method68 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method69 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method7 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method70 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method71 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method72 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method73 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method74 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method75 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method76 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method77 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method78 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method79 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method8 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-public long /*int*/ method9 (long /*int*/[] args) {
- return XPCOM.NS_ERROR_NOT_IMPLEMENTED;
-}
-}
-
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/common/org/eclipse/swt/internal/OSObject.java b/bundles/org.eclipse.swt/Eclipse SWT PI/common/org/eclipse/swt/internal/OSObject.java
new file mode 100644
index 0000000000..ccfb9e52fd
--- /dev/null
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/common/org/eclipse/swt/internal/OSObject.java
@@ -0,0 +1,1016 @@
+/*******************************************************************************
+ * Copyright (c) 2013 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.swt.internal;
+
+import java.util.*;
+
+public abstract class OSObject {
+ static boolean IsSolaris;
+ static {
+ String osName = System.getProperty ("os.name").toLowerCase (); //$NON-NLS-1$
+ IsSolaris = osName.startsWith ("sunos") || osName.startsWith("solaris"); //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
+ private long /*int*/ handle;
+
+ static protected int FailCode = -1;
+ static protected int NotImplementedCode = -1;
+
+ static private final int MAX_ARG_COUNT = 12;
+ static private final int MAX_VTABLE_LENGTH = 80;
+ static private final int OS_OFFSET = IsSolaris ? 2 : 0;
+ static protected Callback[][] Callbacks = new Callback[MAX_VTABLE_LENGTH + OS_OFFSET][MAX_ARG_COUNT];
+
+ static private final Hashtable ObjectMap = new Hashtable ();
+
+
+public OSObject (int[] argCounts) {
+ super ();
+ handle = create (argCounts, OS_OFFSET);
+ ObjectMap.put (new LONG (handle), this);
+}
+
+protected abstract long /*int*/ create (int[] argCounts, int os_offset);
+protected abstract void release (long /*int*/ handle);
+
+public void dispose () {
+ release (handle);
+ ObjectMap.remove (new LONG (handle));
+ handle = 0;
+}
+
+static long /*int*/ callback0 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method0 (args);
+}
+static long /*int*/ callback1 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method1 (args);
+}
+static long /*int*/ callback10 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method10 (args);
+}
+static long /*int*/ callback11 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method11 (args);
+}
+static long /*int*/ callback12 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method12 (args);
+}
+static long /*int*/ callback13 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method13 (args);
+}
+static long /*int*/ callback14 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method14 (args);
+}
+static long /*int*/ callback15 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method15 (args);
+}
+static long /*int*/ callback16 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method16 (args);
+}
+static long /*int*/ callback17 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method17 (args);
+}
+static long /*int*/ callback18 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method18 (args);
+}
+static long /*int*/ callback19 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method19 (args);
+}
+static long /*int*/ callback2 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method2 (args);
+}
+static long /*int*/ callback20 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method20 (args);
+}
+static long /*int*/ callback21 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method21 (args);
+}
+static long /*int*/ callback22 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method22 (args);
+}
+static long /*int*/ callback23 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method23 (args);
+}
+static long /*int*/ callback24 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method24 (args);
+}
+static long /*int*/ callback25 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method25 (args);
+}
+static long /*int*/ callback26 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method26 (args);
+}
+static long /*int*/ callback27 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method27 (args);
+}
+static long /*int*/ callback28 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method28 (args);
+}
+static long /*int*/ callback29 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method29 (args);
+}
+static long /*int*/ callback3 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method3 (args);
+}
+static long /*int*/ callback30 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method30 (args);
+}
+static long /*int*/ callback31 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method31 (args);
+}
+static long /*int*/ callback32 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method32 (args);
+}
+static long /*int*/ callback33 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method33 (args);
+}
+static long /*int*/ callback34 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method34 (args);
+}
+static long /*int*/ callback35 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method35 (args);
+}
+static long /*int*/ callback36 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method36 (args);
+}
+static long /*int*/ callback37 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method37 (args);
+}
+static long /*int*/ callback38 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method38 (args);
+}
+static long /*int*/ callback39 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method39 (args);
+}
+static long /*int*/ callback4 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method4 (args);
+}
+static long /*int*/ callback40 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method40 (args);
+}
+static long /*int*/ callback41 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method41 (args);
+}
+static long /*int*/ callback42 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method42 (args);
+}
+static long /*int*/ callback43 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method43 (args);
+}
+static long /*int*/ callback44 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method44 (args);
+}
+static long /*int*/ callback45 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method45 (args);
+}
+static long /*int*/ callback46 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method46 (args);
+}
+static long /*int*/ callback47 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method47 (args);
+}
+static long /*int*/ callback48 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method48 (args);
+}
+static long /*int*/ callback49 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method49 (args);
+}
+static long /*int*/ callback5 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method5 (args);
+}
+static long /*int*/ callback50 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method50 (args);
+}
+static long /*int*/ callback51 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method51 (args);
+}
+static long /*int*/ callback52 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method52 (args);
+}
+static long /*int*/ callback53 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method53 (args);
+}
+static long /*int*/ callback54 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method54 (args);
+}
+static long /*int*/ callback55 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method55 (args);
+}
+static long /*int*/ callback56 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method56 (args);
+}
+static long /*int*/ callback57 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method57 (args);
+}
+static long /*int*/ callback58 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method58 (args);
+}
+static long /*int*/ callback59 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method59 (args);
+}
+static long /*int*/ callback6 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method6 (args);
+}
+static long /*int*/ callback60 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method60 (args);
+}
+static long /*int*/ callback61 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method61 (args);
+}
+static long /*int*/ callback62 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method62 (args);
+}
+static long /*int*/ callback63 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method63 (args);
+}
+static long /*int*/ callback64 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method64 (args);
+}
+static long /*int*/ callback65 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method65 (args);
+}
+static long /*int*/ callback66 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method66 (args);
+}
+static long /*int*/ callback67 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method67 (args);
+}
+static long /*int*/ callback68 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method68 (args);
+}
+static long /*int*/ callback69 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method69 (args);
+}
+static long /*int*/ callback7 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method7 (args);
+}
+static long /*int*/ callback70 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method70 (args);
+}
+static long /*int*/ callback71 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method71 (args);
+}
+static long /*int*/ callback72 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method72 (args);
+}
+static long /*int*/ callback73 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method73 (args);
+}
+static long /*int*/ callback74 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method74 (args);
+}
+static long /*int*/ callback75 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method75 (args);
+}
+static long /*int*/ callback76 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method76 (args);
+}
+static long /*int*/ callback77 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method77 (args);
+}
+static long /*int*/ callback78 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method78 (args);
+}
+static long /*int*/ callback79 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method79 (args);
+}
+static long /*int*/ callback8 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method8 (args);
+}
+static long /*int*/ callback9 (long /*int*/[] callbackArgs) {
+ // find the object on which this call was invoked
+ long /*int*/ address = callbackArgs[0];
+ Object object = ObjectMap.get (new LONG (address));
+ if (object == null) return FailCode;
+ long /*int*/[] args = new long /*int*/[callbackArgs.length - 1];
+ System.arraycopy (callbackArgs, 1, args, 0, args.length);
+ return ((OSObject) object).method9 (args);
+}
+
+public long /*int*/ getAddress () {
+ return handle;
+}
+
+public long /*int*/ method0 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method1 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method10 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method11 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method12 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method13 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method14 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method15 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method16 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method17 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method18 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method19 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method2 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method20 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method21 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method22 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method23 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method24 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method25 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method26 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method27 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method28 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method29 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method3 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method30 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method31 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method32 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method33 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method34 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method35 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method36 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method37 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method38 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method39 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method4 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method40 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method41 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method42 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method43 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method44 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method45 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method46 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method47 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method48 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method49 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method5 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method50 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method51 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method52 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method53 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method54 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method55 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method56 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method57 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method58 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method59 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method6 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method60 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method61 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method62 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method63 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method64 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method65 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method66 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method67 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method68 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method69 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method7 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method70 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method71 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method72 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method73 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method74 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method75 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method76 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method77 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method78 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method79 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method8 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+public long /*int*/ method9 (long /*int*/[] args) {
+ return NotImplementedCode;
+}
+}
+
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/make_win32.mak b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/make_win32.mak
index 57be563a6e..80170ef0c0 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/make_win32.mak
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/make_win32.mak
@@ -44,6 +44,14 @@ WEBKIT_LIB = $(WEBKIT_PREFIX)-$(WS_PREFIX)-$(SWT_VERSION).dll
WEBKIT_LIBS = $(WEBKIT_DIR)\lib\webkit.lib $(WEBKIT_SUPPORT_DIR)\win\lib\CFNetwork.lib $(WEBKIT_SUPPORT_DIR)\win\lib\CoreFoundation.lib
WEBKIT_OBJS = webkit_win32.obj webkit_win32_stats.obj webkit_win32_custom.obj webkit_win32_structs.obj
+# CEF3_DIR = S:\swt-builddir\cef_3.1180.823_windows
+CEF3_DIR = C:\cef3-1180\chromium\src\cef
+CEF3_PREFIX = swt-cef3
+CEF3_LIB = $(CEF3_PREFIX)-$(WS_PREFIX)-$(SWT_VERSION).dll
+# CEF3_LIBS = $(CEF3_DIR)\lib\Release\libcef.lib
+CEF3_LIBS = $(CEF3_DIR)\binary_distrib\cef_binary_3.1180.None_windows\lib\Debug\libcef.lib
+CEF3_OBJS = cef3.obj cef3_structs.obj cef3_stats.obj cef3_custom.obj
+
WGL_PREFIX = swt-wgl
WGL_LIB = $(WGL_PREFIX)-$(WS_PREFIX)-$(SWT_VERSION).dll
WGL_LIBS = opengl32.lib
@@ -78,6 +86,13 @@ WEBKITCFLAGS = -c -O1\
-I"$(WEBKIT_DIR)\JavaScriptCore\ForwardingHeaders" \
-I"$(WEBKIT_SUPPORT_DIR)\win\include"
+CEF3CFLAGS = -O1 -DNDEBUG $(cflags) $(cvarsmt) $(CFLAGS) \
+ -DSWT_VERSION=$(SWT_VERSION) $(NATIVE_STATS) -DUSE_ASSEMBLER \
+ /I"$(JAVA_HOME)\include" /I"$(JAVA_HOME)\include\win32" /I. \
+ -I"$(CEF3_DIR)" \
+ -I"$(CEF3_DIR)\include\internal" \
+ -I"$(CEF3_DIR)\include\capi"
+
#CFLAGS = $(cdebug) $(cflags) $(cvarsmt) $(CFLAGS) \
CFLAGS = -O1 -DNDEBUG $(cflags) $(cvarsmt) $(CFLAGS) \
-DSWT_VERSION=$(SWT_VERSION) $(NATIVE_STATS) -DUSE_ASSEMBLER \
@@ -86,6 +101,15 @@ RCFLAGS = $(rcflags) $(rcvars) $(RCFLAGS) -DSWT_FILE_VERSION=\"$(maj_ver).$(min_
all: make_swt make_awt make_gdip make_wgl
+cef3_custom.obj: cef3_custom.c
+ cl $(CEF3CFLAGS) cef3_custom.c
+cef3_stats.obj: cef3_stats.c
+ cl $(CEF3CFLAGS) cef3_stats.c
+cef3_structs.obj: cef3_structs.c
+ cl $(CEF3CFLAGS) cef3_structs.c
+cef3.obj: cef3.c
+ cl $(CEF3CFLAGS) cef3.c
+
webkit_win32_custom.obj: webkit_win32_custom.cpp
cl $(WEBKITCFLAGS) webkit_win32_custom.cpp
webkit_win32_stats.obj: webkit_win32_stats.cpp
@@ -143,6 +167,27 @@ make_awt: $(AWT_OBJS) swt_awt.res
link @templrf
del templrf
+make_cef3: $(CEF3_OBJS) swt_cef3.res
+ echo $(ldebug) $(dlllflags) >templrf
+ echo $(CEF3_LIBS) >>templrf
+ echo $(CEF3_OBJS) >>templrf
+ echo swt_cef3.res >>templrf
+ echo -out:$(CEF3_LIB) >>templrf
+ link @templrf
+ del templrf
+
+cef3_subprocess.obj: cef3_subprocess.c
+ cl $(CEF3CFLAGS) cef3_subprocess.c
+
+make_cef3_subprocess: cef3_subprocess.obj swt_cef3.res
+ echo $(ldebug) >templrf
+ echo $(CEF3_LIBS) User32.lib >>templrf
+ echo cef3_subprocess.obj >>templrf
+ echo swt_cef3.res >>templrf
+ echo -out:cef3_subprocess.exe >>templrf
+ link @templrf
+ del templrf
+
make_webkit: $(WEBKIT_OBJS) swt_webkit.res
echo $(ldebug) $(dlllflags) >templrf
echo $(WEBKIT_LIBS) >>templrf
@@ -179,6 +224,9 @@ swt_gdip.res:
swt_awt.res:
rc $(RCFLAGS) -DSWT_ORG_FILENAME=\"$(AWT_LIB)\" -r -fo swt_awt.res swt_awt.rc
+swt_cef3.res:
+ rc $(RCFLAGS) -DSWT_ORG_FILENAME=\"$(CEF3_LIB)\" -r -fo swt_cef3.res swt_cef3.rc
+
swt_webkit.res:
rc $(RCFLAGS) -DSWT_ORG_FILENAME=\"$(WEBKIT_LIB)\" -r -fo swt_webkit.res swt_webkit.rc
diff --git a/bundles/org.eclipse.swt/buildSWT.xml b/bundles/org.eclipse.swt/buildSWT.xml
index 1cdd3b9544..5457677e9d 100644
--- a/bundles/org.eclipse.swt/buildSWT.xml
+++ b/bundles/org.eclipse.swt/buildSWT.xml
@@ -37,7 +37,7 @@
<property name="repo.releng" value="../../../eclipse.platform.releng.maps"/>
<property name="src_common" value="'bundles/org.eclipse.swt/Eclipse SWT/common/library' 'bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library' 'bundles/org.eclipse.swt/Eclipse SWT PI/common/library'"/>
- <property name="src_win32" value="${src_common} 'bundles/org.eclipse.swt/Eclipse SWT PI/win32/library' 'bundles/org.eclipse.swt/Eclipse SWT AWT/win32/library' 'bundles/org.eclipse.swt/Eclipse SWT OpenGL/win32/library' 'bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library'"/>
+ <property name="src_win32" value="${src_common} 'bundles/org.eclipse.swt/Eclipse SWT PI/win32/library' 'bundles/org.eclipse.swt/Eclipse SWT AWT/win32/library' 'bundles/org.eclipse.swt/Eclipse SWT OpenGL/win32/library' 'bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library' 'bundles/org.eclipse.swt/Eclipse SWT CEF/win32/library'"/>
<property name="src_gtk" value="${src_common} 'bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library' 'bundles/org.eclipse.swt/Eclipse SWT AWT/gtk/library' 'bundles/org.eclipse.swt/Eclipse SWT OpenGL/glx/library' 'bundles/org.eclipse.swt/Eclipse SWT PI/cairo/library' 'bundles/org.eclipse.swt/Eclipse SWT Program/gnome/library' 'bundles/org.eclipse.swt/Eclipse SWT Program/cde/library' 'bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/library' "/>
<property name="src_cocoa" value="${src_common} 'bundles/org.eclipse.swt/Eclipse SWT PI/cocoa/library' 'bundles/org.eclipse.swt/Eclipse SWT AWT/cocoa/library'"/>
<property name="src_carbon" value="${src_common} 'bundles/org.eclipse.swt/Eclipse SWT PI/carbon/library' 'bundles/org.eclipse.swt/Eclipse SWT OpenGL/carbon/library'"/>

Back to the top