summaryrefslogtreecommitdiffstats
path: root/bundles/org.eclipse.swt
diff options
context:
space:
mode:
authorLakshmi Shanmugam <lshanmugam>2011-01-03 12:49:07 +0000
committerLakshmi Shanmugam <lshanmugam>2011-01-03 12:49:07 +0000
commit20038377a45fbdaa1f32f13cbd4067b1a6de9d10 (patch)
tree0f618addddccc15772f1862bd2d72900da3e3361 /bundles/org.eclipse.swt
parentd40cbb892cec81ea2b2e87a9b6ae9112c418cd1a (diff)
downloadeclipse.platform.swt-20038377a45fbdaa1f32f13cbd4067b1a6de9d10.tar.gz
eclipse.platform.swt-20038377a45fbdaa1f32f13cbd4067b1a6de9d10.tar.xz
eclipse.platform.swt-20038377a45fbdaa1f32f13cbd4067b1a6de9d10.zip
webkit - after review and code cleanup
Diffstat (limited to 'bundles/org.eclipse.swt')
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com.c141
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com_stats.c31
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com_stats.h27
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/make_win32.mak7
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os.c257
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os.h1
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_stats.c43
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_stats.h39
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_structs.c2
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_structs.h2
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COM.java11
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/IPropertyBag.java21
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/win32/OS.java22
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32.cpp111
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_stats.cpp11
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_stats.h7
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebDownloadDelegate.java101
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebFrameLoadDelegate.java272
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebKit.java670
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebPolicyDelegate.java94
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebResourceLoadDelegate.java163
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebUIDelegate.java383
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IDOMDocument.java24
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebCookieManager.java5
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDataSource.java16
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDocumentRepresentation.java5
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDownload.java40
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebError.java27
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebErrorPrivate.java (renamed from bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IDOMEventListener.java)14
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebFrame.java21
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebFramePrivate.java17
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebIBActions.java17
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebMutableURLRequest.java20
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebMutableURLRequestPrivate.java24
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebOpenPanelResultListener.java22
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebPolicyDecisionListener.java13
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebPreferences.java35
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLAuthenticationChallenge.java7
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLAuthenticationChallengeSender.java5
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLCredential.java7
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLProtectionSpace.java40
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLRequest.java17
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLResponse.java27
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebView.java71
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebViewPrivate.java21
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/WebKit_win32.java179
-rwxr-xr-xbundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/SWT.java10
47 files changed, 1567 insertions, 1533 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com.c b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com.c
index 6a75301484..3050b9437b 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com.c
@@ -1611,24 +1611,24 @@ fail:
}
#endif
-#if (!defined(NO_VtblCall__IIIIZ) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJJZ) && defined(JNI64))
+#if (!defined(NO_VtblCall__IIIIZ) && !defined(JNI64)) || (!defined(NO_VtblCall__IJIIZ) && defined(JNI64))
#ifndef JNI64
-JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIIIZ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jintLong arg2, jintLong arg3, jboolean arg4)
+JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIIIZ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jint arg3, jboolean arg4)
#else
-JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJJJZ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jintLong arg2, jintLong arg3, jboolean arg4)
+JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJIIZ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jint arg3, jboolean arg4)
#endif
{
jint rc = 0;
#ifndef JNI64
COM_NATIVE_ENTER(env, that, VtblCall__IIIIZ_FUNC);
#else
- COM_NATIVE_ENTER(env, that, VtblCall__IJJJZ_FUNC);
+ COM_NATIVE_ENTER(env, that, VtblCall__IJIIZ_FUNC);
#endif
- rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jintLong, jintLong, jboolean))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, arg4);
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jint, jint, jboolean))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, arg4);
#ifndef JNI64
COM_NATIVE_EXIT(env, that, VtblCall__IIIIZ_FUNC);
#else
- COM_NATIVE_EXIT(env, that, VtblCall__IJJJZ_FUNC);
+ COM_NATIVE_EXIT(env, that, VtblCall__IJIIZ_FUNC);
#endif
return rc;
}
@@ -1688,29 +1688,6 @@ fail:
}
#endif
-#if (!defined(NO_VtblCall__IIIJ) && !defined(JNI64)) || (!defined(NO_VtblCall__IJIJ) && defined(JNI64))
-#ifndef JNI64
-JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIIJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jlong arg3)
-#else
-JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJIJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jlong arg3)
-#endif
-{
- jint rc = 0;
-#ifndef JNI64
- COM_NATIVE_ENTER(env, that, VtblCall__IIIJ_FUNC);
-#else
- COM_NATIVE_ENTER(env, that, VtblCall__IJIJ_FUNC);
-#endif
- rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jint, jlong))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3);
-#ifndef JNI64
- COM_NATIVE_EXIT(env, that, VtblCall__IIIJ_FUNC);
-#else
- COM_NATIVE_EXIT(env, that, VtblCall__IJIJ_FUNC);
-#endif
- return rc;
-}
-#endif
-
#if (!defined(NO_VtblCall__IIIJ_3I) && !defined(JNI64)) || (!defined(NO_VtblCall__IJIJ_3I) && defined(JNI64))
#ifndef JNI64
JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIIJ_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jlong arg3, jintArray arg4)
@@ -2274,29 +2251,6 @@ fail:
}
#endif
-#if (!defined(NO_VtblCall__IIJJ) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJJ) && defined(JNI64))
-#ifndef JNI64
-JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIJJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3)
-#else
-JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJJJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3)
-#endif
-{
- jint rc = 0;
-#ifndef JNI64
- COM_NATIVE_ENTER(env, that, VtblCall__IIJJ_FUNC);
-#else
- COM_NATIVE_ENTER(env, that, VtblCall__IJJJ_FUNC);
-#endif
- rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jlong))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3);
-#ifndef JNI64
- COM_NATIVE_EXIT(env, that, VtblCall__IIJJ_FUNC);
-#else
- COM_NATIVE_EXIT(env, that, VtblCall__IJJJ_FUNC);
-#endif
- return rc;
-}
-#endif
-
#if (!defined(NO_VtblCall__IIJJLorg_eclipse_swt_internal_ole_win32_GUID_2J_3J) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJJLorg_eclipse_swt_internal_ole_win32_GUID_2J_3J) && defined(JNI64))
#ifndef JNI64
JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIJJLorg_eclipse_swt_internal_ole_win32_GUID_2J_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jobject arg4, jlong arg5, jlongArray arg6)
@@ -2354,6 +2308,29 @@ fail:
}
#endif
+#if (!defined(NO_VtblCall__IIJJZ) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJJZ) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIJJZ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jboolean arg4)
+#else
+JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJJJZ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jboolean arg4)
+#endif
+{
+ jint rc = 0;
+#ifndef JNI64
+ COM_NATIVE_ENTER(env, that, VtblCall__IIJJZ_FUNC);
+#else
+ COM_NATIVE_ENTER(env, that, VtblCall__IJJJZ_FUNC);
+#endif
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jlong, jboolean))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, arg4);
+#ifndef JNI64
+ COM_NATIVE_EXIT(env, that, VtblCall__IIJJZ_FUNC);
+#else
+ COM_NATIVE_EXIT(env, that, VtblCall__IJJJZ_FUNC);
+#endif
+ return rc;
+}
+#endif
+
#if (!defined(NO_VtblCall__IIJJ_3J) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJJ_3J) && defined(JNI64))
#ifndef JNI64
JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIJJ_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jlongArray arg4)
@@ -2491,33 +2468,6 @@ JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJJZ)(JNIEnv *env, jclass that, jint
}
#endif
-#if (!defined(NO_VtblCall__IIJ_3I) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJ_3I) && defined(JNI64))
-#ifndef JNI64
-JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIJ_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jintArray arg3)
-#else
-JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJJ_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jintArray arg3)
-#endif
-{
- jint *lparg3=NULL;
- jint rc = 0;
-#ifndef JNI64
- COM_NATIVE_ENTER(env, that, VtblCall__IIJ_3I_FUNC);
-#else
- COM_NATIVE_ENTER(env, that, VtblCall__IJJ_3I_FUNC);
-#endif
- if (arg3) if ((lparg3 = (*env)->GetIntArrayElements(env, arg3, NULL)) == NULL) goto fail;
- rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jint *))(*(jintLong **)arg1)[arg0])(arg1, arg2, lparg3);
-fail:
- if (arg3 && lparg3) (*env)->ReleaseIntArrayElements(env, arg3, lparg3, 0);
-#ifndef JNI64
- COM_NATIVE_EXIT(env, that, VtblCall__IIJ_3I_FUNC);
-#else
- COM_NATIVE_EXIT(env, that, VtblCall__IJJ_3I_FUNC);
-#endif
- return rc;
-}
-#endif
-
#if (!defined(NO_VtblCall__IIJ_3J) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJ_3J) && defined(JNI64))
#ifndef JNI64
JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIJ_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlongArray arg3)
@@ -3309,23 +3259,46 @@ JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJZ)(JNIEnv *env, jclass that, jint
}
#endif
-#if (!defined(NO_VtblCall__IIZI) && !defined(JNI64)) || (!defined(NO_VtblCall__IJZJ) && defined(JNI64))
+#if (!defined(NO_VtblCall__IIZI) && !defined(JNI64)) || (!defined(NO_VtblCall__IJZI) && defined(JNI64))
#ifndef JNI64
-JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIZI)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jboolean arg2, jintLong arg3)
+JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIZI)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jboolean arg2, jint arg3)
#else
-JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJZJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jboolean arg2, jintLong arg3)
+JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJZI)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jboolean arg2, jint arg3)
#endif
{
jint rc = 0;
#ifndef JNI64
COM_NATIVE_ENTER(env, that, VtblCall__IIZI_FUNC);
#else
- COM_NATIVE_ENTER(env, that, VtblCall__IJZJ_FUNC);
+ COM_NATIVE_ENTER(env, that, VtblCall__IJZI_FUNC);
#endif
- rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jboolean, jintLong))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3);
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jboolean, jint))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3);
#ifndef JNI64
COM_NATIVE_EXIT(env, that, VtblCall__IIZI_FUNC);
#else
+ COM_NATIVE_EXIT(env, that, VtblCall__IJZI_FUNC);
+#endif
+ return rc;
+}
+#endif
+
+#if (!defined(NO_VtblCall__IIZJ) && !defined(JNI64)) || (!defined(NO_VtblCall__IJZJ) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IIZJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jboolean arg2, jlong arg3)
+#else
+JNIEXPORT jint JNICALL COM_NATIVE(VtblCall__IJZJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jboolean arg2, jlong arg3)
+#endif
+{
+ jint rc = 0;
+#ifndef JNI64
+ COM_NATIVE_ENTER(env, that, VtblCall__IIZJ_FUNC);
+#else
+ COM_NATIVE_ENTER(env, that, VtblCall__IJZJ_FUNC);
+#endif
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jboolean, jlong))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3);
+#ifndef JNI64
+ COM_NATIVE_EXIT(env, that, VtblCall__IIZJ_FUNC);
+#else
COM_NATIVE_EXIT(env, that, VtblCall__IJZJ_FUNC);
#endif
return rc;
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com_stats.c b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com_stats.c
index 7b1916910e..5bfe2f0f6c 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com_stats.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com_stats.c
@@ -14,8 +14,8 @@
#ifdef NATIVE_STATS
-int COM_nativeFunctionCount = 184;
-int COM_nativeFunctionCallCount[184];
+int COM_nativeFunctionCount = 183;
+int COM_nativeFunctionCallCount[183];
char * COM_nativeFunctionNames[] = {
"AccessibleChildren",
"AccessibleObjectFromWindow",
@@ -210,7 +210,7 @@ char * COM_nativeFunctionNames[] = {
#ifndef JNI64
"VtblCall__IIIIZ",
#else
- "VtblCall__IJJJZ",
+ "VtblCall__IJIIZ",
#endif
#ifndef JNI64
"VtblCall__IIII_3I",
@@ -223,11 +223,6 @@ char * COM_nativeFunctionNames[] = {
"VtblCall__IJII_3J",
#endif
#ifndef JNI64
- "VtblCall__IIIJ",
-#else
- "VtblCall__IJIJ",
-#endif
-#ifndef JNI64
"VtblCall__IIIJ_3I",
#else
"VtblCall__IJIJ_3I",
@@ -323,11 +318,6 @@ char * COM_nativeFunctionNames[] = {
"VtblCall__IJJI_3J",
#endif
#ifndef JNI64
- "VtblCall__IIJJ",
-#else
- "VtblCall__IJJJ",
-#endif
-#ifndef JNI64
"VtblCall__IIJJLorg_eclipse_swt_internal_ole_win32_GUID_2J_3J",
#else
"VtblCall__IJJJLorg_eclipse_swt_internal_ole_win32_GUID_2J_3J",
@@ -338,6 +328,11 @@ char * COM_nativeFunctionNames[] = {
"VtblCall__IJJJLorg_eclipse_swt_internal_win32_POINT_2I",
#endif
#ifndef JNI64
+ "VtblCall__IIJJZ",
+#else
+ "VtblCall__IJJJZ",
+#endif
+#ifndef JNI64
"VtblCall__IIJJ_3J",
#else
"VtblCall__IJJJ_3J",
@@ -363,11 +358,6 @@ char * COM_nativeFunctionNames[] = {
"VtblCall__IJJZ",
#endif
#ifndef JNI64
- "VtblCall__IIJ_3I",
-#else
- "VtblCall__IJJ_3I",
-#endif
-#ifndef JNI64
"VtblCall__IIJ_3J",
#else
"VtblCall__IJJ_3J",
@@ -510,6 +500,11 @@ char * COM_nativeFunctionNames[] = {
#ifndef JNI64
"VtblCall__IIZI",
#else
+ "VtblCall__IJZI",
+#endif
+#ifndef JNI64
+ "VtblCall__IIZJ",
+#else
"VtblCall__IJZJ",
#endif
#ifndef JNI64
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com_stats.h b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com_stats.h
index 3a8cb4ae75..b68fcd1ae4 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com_stats.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/com_stats.h
@@ -218,7 +218,7 @@ typedef enum {
#ifndef JNI64
VtblCall__IIIIZ_FUNC,
#else
- VtblCall__IJJJZ_FUNC,
+ VtblCall__IJIIZ_FUNC,
#endif
#ifndef JNI64
VtblCall__IIII_3I_FUNC,
@@ -231,11 +231,6 @@ typedef enum {
VtblCall__IJII_3J_FUNC,
#endif
#ifndef JNI64
- VtblCall__IIIJ_FUNC,
-#else
- VtblCall__IJIJ_FUNC,
-#endif
-#ifndef JNI64
VtblCall__IIIJ_3I_FUNC,
#else
VtblCall__IJIJ_3I_FUNC,
@@ -331,11 +326,6 @@ typedef enum {
VtblCall__IJJI_3J_FUNC,
#endif
#ifndef JNI64
- VtblCall__IIJJ_FUNC,
-#else
- VtblCall__IJJJ_FUNC,
-#endif
-#ifndef JNI64
VtblCall__IIJJLorg_eclipse_swt_internal_ole_win32_GUID_2J_3J_FUNC,
#else
VtblCall__IJJJLorg_eclipse_swt_internal_ole_win32_GUID_2J_3J_FUNC,
@@ -346,6 +336,11 @@ typedef enum {
VtblCall__IJJJLorg_eclipse_swt_internal_win32_POINT_2I_FUNC,
#endif
#ifndef JNI64
+ VtblCall__IIJJZ_FUNC,
+#else
+ VtblCall__IJJJZ_FUNC,
+#endif
+#ifndef JNI64
VtblCall__IIJJ_3J_FUNC,
#else
VtblCall__IJJJ_3J_FUNC,
@@ -371,11 +366,6 @@ typedef enum {
VtblCall__IJJZ_FUNC,
#endif
#ifndef JNI64
- VtblCall__IIJ_3I_FUNC,
-#else
- VtblCall__IJJ_3I_FUNC,
-#endif
-#ifndef JNI64
VtblCall__IIJ_3J_FUNC,
#else
VtblCall__IJJ_3J_FUNC,
@@ -518,6 +508,11 @@ typedef enum {
#ifndef JNI64
VtblCall__IIZI_FUNC,
#else
+ VtblCall__IJZI_FUNC,
+#endif
+#ifndef JNI64
+ VtblCall__IIZJ_FUNC,
+#else
VtblCall__IJZJ_FUNC,
#endif
#ifndef JNI64
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 95a99d2f8a..954d220fe5 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
@@ -37,8 +37,8 @@ AWT_LIB = $(AWT_PREFIX)-$(WS_PREFIX)-$(SWT_VERSION).dll
AWT_LIBS = "$(JAVA_HOME)\jre\bin\jawt.lib"
AWT_OBJS = swt_awt.obj
-WEBKIT_DIR = C:\WebKit-r68077\WebKit-r68077
-WEBKIT_SUPPORT_DIR = C:\WebKit-r68077\WebKit-r68077\WebKitSupportLibrary\WebKitSupportLibrary
+WEBKIT_DIR = S:\swt-builddir\webkit\WebKit-r72896
+WEBKIT_SUPPORT_DIR = S:\swt-builddir\webkit\WebKitSupportLibrary
WEBKIT_PREFIX = swt-webkit
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
@@ -70,7 +70,8 @@ MOZILLACFLAGS = -c \
-I"$(XULRUNNER_SDK)\include\mozilla-config.h" -I"$(XULRUNNER_SDK)\include"
WEBKITCFLAGS = -c -O1\
- -DSWT_VERSION=$(SWT_VERSION) $(NATIVE_STATS) \
+ -DSWT_VERSION=$(SWT_VERSION) \
+ $(NATIVE_STATS) \
-I"$(JAVA_HOME)\include" -I"$(JAVA_HOME)\include\win32" \
-I"$(WEBKIT_DIR)" \
-I"$(WEBKIT_DIR)\WebKit\win" \
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os.c b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os.c
index 12a477f00a..31888da50d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os.c
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2010 IBM Corporation and others.
+ * Copyright (c) 2000, 2011 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
@@ -11142,48 +11142,6 @@ fail:
}
#endif
-#if (!defined(NO_MoveMemory___3D_3II) && !defined(JNI64)) || (!defined(NO_MoveMemory___3D_3JI) && defined(JNI64))
-#ifndef JNI64
-JNIEXPORT void JNICALL OS_NATIVE(MoveMemory___3D_3II)(JNIEnv *env, jclass that, jdoubleArray arg0, jintLongArray arg1, jint arg2)
-#else
-JNIEXPORT void JNICALL OS_NATIVE(MoveMemory___3D_3JI)(JNIEnv *env, jclass that, jdoubleArray arg0, jintLongArray arg1, jint arg2)
-#endif
-{
- jdouble *lparg0=NULL;
- jintLong *lparg1=NULL;
-#ifndef JNI64
- OS_NATIVE_ENTER(env, that, MoveMemory___3D_3II_FUNC);
-#else
- OS_NATIVE_ENTER(env, that, MoveMemory___3D_3JI_FUNC);
-#endif
- if (arg1) if ((lparg1 = (*env)->GetIntLongArrayElements(env, arg1, NULL)) == NULL) goto fail;
-#ifdef JNI_VERSION_1_2
- if (IS_JNI_1_2) {
- if (arg0) if ((lparg0 = (*env)->GetPrimitiveArrayCritical(env, arg0, NULL)) == NULL) goto fail;
- } else
-#endif
- {
- if (arg0) if ((lparg0 = (*env)->GetDoubleArrayElements(env, arg0, NULL)) == NULL) goto fail;
- }
- MoveMemory((PVOID)lparg0, (CONST VOID *)lparg1, arg2);
-fail:
-#ifdef JNI_VERSION_1_2
- if (IS_JNI_1_2) {
- if (arg0 && lparg0) (*env)->ReleasePrimitiveArrayCritical(env, arg0, lparg0, 0);
- } else
-#endif
- {
- if (arg0 && lparg0) (*env)->ReleaseDoubleArrayElements(env, arg0, lparg0, 0);
- }
- if (arg1 && lparg1) (*env)->ReleaseIntLongArrayElements(env, arg1, lparg1, 0);
-#ifndef JNI64
- OS_NATIVE_EXIT(env, that, MoveMemory___3D_3II_FUNC);
-#else
- OS_NATIVE_EXIT(env, that, MoveMemory___3D_3JI_FUNC);
-#endif
-}
-#endif
-
#if (!defined(NO_MoveMemory___3FII) && !defined(JNI64)) || (!defined(NO_MoveMemory___3FJI) && defined(JNI64))
#ifndef JNI64
JNIEXPORT void JNICALL OS_NATIVE(MoveMemory___3FII)(JNIEnv *env, jclass that, jfloatArray arg0, jintLong arg1, jint arg2)
@@ -17702,11 +17660,11 @@ fail:
}
#endif
-#if (!defined(NO_VtblCall__IIII_3C_3CI) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJI_3C_3CJ) && defined(JNI64))
+#if (!defined(NO_VtblCall__IIII_3C_3CI) && !defined(JNI64)) || (!defined(NO_VtblCall__IJII_3C_3CI) && defined(JNI64))
#ifndef JNI64
-JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IIII_3C_3CI)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jintLong arg2, jint arg3, jcharArray arg4, jcharArray arg5, jintLong arg6)
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IIII_3C_3CI)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jint arg3, jcharArray arg4, jcharArray arg5, jint arg6)
#else
-JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJJI_3C_3CJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jintLong arg2, jint arg3, jcharArray arg4, jcharArray arg5, jintLong arg6)
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJII_3C_3CI)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jint arg3, jcharArray arg4, jcharArray arg5, jint arg6)
#endif
{
jchar *lparg4=NULL;
@@ -17715,18 +17673,41 @@ JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJJI_3C_3CJ)(JNIEnv *env, jclass that
#ifndef JNI64
OS_NATIVE_ENTER(env, that, VtblCall__IIII_3C_3CI_FUNC);
#else
- OS_NATIVE_ENTER(env, that, VtblCall__IJJI_3C_3CJ_FUNC);
+ OS_NATIVE_ENTER(env, that, VtblCall__IJII_3C_3CI_FUNC);
#endif
if (arg4) if ((lparg4 = (*env)->GetCharArrayElements(env, arg4, NULL)) == NULL) goto fail;
if (arg5) if ((lparg5 = (*env)->GetCharArrayElements(env, arg5, NULL)) == NULL) goto fail;
- rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jintLong, jint, jchar *, jchar *, jintLong))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, lparg4, lparg5, arg6);
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jint, jint, jchar *, jchar *, jint))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, lparg4, lparg5, arg6);
fail:
if (arg5 && lparg5) (*env)->ReleaseCharArrayElements(env, arg5, lparg5, 0);
if (arg4 && lparg4) (*env)->ReleaseCharArrayElements(env, arg4, lparg4, 0);
#ifndef JNI64
OS_NATIVE_EXIT(env, that, VtblCall__IIII_3C_3CI_FUNC);
#else
- OS_NATIVE_EXIT(env, that, VtblCall__IJJI_3C_3CJ_FUNC);
+ OS_NATIVE_EXIT(env, that, VtblCall__IJII_3C_3CI_FUNC);
+#endif
+ return rc;
+}
+#endif
+
+#if (!defined(NO_VtblCall__IIIJ) && !defined(JNI64)) || (!defined(NO_VtblCall__IJIJ) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IIIJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jlong arg3)
+#else
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJIJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jlong arg3)
+#endif
+{
+ jint rc = 0;
+#ifndef JNI64
+ OS_NATIVE_ENTER(env, that, VtblCall__IIIJ_FUNC);
+#else
+ OS_NATIVE_ENTER(env, that, VtblCall__IJIJ_FUNC);
+#endif
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jint, jlong))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3);
+#ifndef JNI64
+ OS_NATIVE_EXIT(env, that, VtblCall__IIIJ_FUNC);
+#else
+ OS_NATIVE_EXIT(env, that, VtblCall__IJIJ_FUNC);
#endif
return rc;
}
@@ -17936,6 +17917,59 @@ fail:
}
#endif
+#if (!defined(NO_VtblCall__IIJI_3C_3CJ) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJI_3C_3CJ) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IIJI_3C_3CJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jcharArray arg4, jcharArray arg5, jlong arg6)
+#else
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJJI_3C_3CJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jcharArray arg4, jcharArray arg5, jlong arg6)
+#endif
+{
+ jchar *lparg4=NULL;
+ jchar *lparg5=NULL;
+ jint rc = 0;
+#ifndef JNI64
+ OS_NATIVE_ENTER(env, that, VtblCall__IIJI_3C_3CJ_FUNC);
+#else
+ OS_NATIVE_ENTER(env, that, VtblCall__IJJI_3C_3CJ_FUNC);
+#endif
+ if (arg4) if ((lparg4 = (*env)->GetCharArrayElements(env, arg4, NULL)) == NULL) goto fail;
+ if (arg5) if ((lparg5 = (*env)->GetCharArrayElements(env, arg5, NULL)) == NULL) goto fail;
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jint, jchar *, jchar *, jlong))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, lparg4, lparg5, arg6);
+fail:
+ if (arg5 && lparg5) (*env)->ReleaseCharArrayElements(env, arg5, lparg5, 0);
+ if (arg4 && lparg4) (*env)->ReleaseCharArrayElements(env, arg4, lparg4, 0);
+#ifndef JNI64
+ OS_NATIVE_EXIT(env, that, VtblCall__IIJI_3C_3CJ_FUNC);
+#else
+ OS_NATIVE_EXIT(env, that, VtblCall__IJJI_3C_3CJ_FUNC);
+#endif
+ return rc;
+}
+#endif
+
+#if (!defined(NO_VtblCall__IIJJ) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJJ) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IIJJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3)
+#else
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJJJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3)
+#endif
+{
+ jint rc = 0;
+#ifndef JNI64
+ OS_NATIVE_ENTER(env, that, VtblCall__IIJJ_FUNC);
+#else
+ OS_NATIVE_ENTER(env, that, VtblCall__IJJJ_FUNC);
+#endif
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jlong))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3);
+#ifndef JNI64
+ OS_NATIVE_EXIT(env, that, VtblCall__IIJJ_FUNC);
+#else
+ OS_NATIVE_EXIT(env, that, VtblCall__IJJJ_FUNC);
+#endif
+ return rc;
+}
+#endif
+
#if (!defined(NO_VtblCall__IIJJI_3J) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJJI_3J) && defined(JNI64))
#ifndef JNI64
JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IIJJI_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jint arg4, jlongArray arg5)
@@ -17986,30 +18020,87 @@ JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJJJJ)(JNIEnv *env, jclass that, jint
}
#endif
-#if (!defined(NO_VtblCall__IIJ_3I_3I) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJ_3J_3J) && defined(JNI64))
+#if (!defined(NO_VtblCall__IIJ_3I) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJ_3I) && defined(JNI64))
#ifndef JNI64
-JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IIJ_3I_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jintLongArray arg3, jintLongArray arg4)
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IIJ_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jintArray arg3)
#else
-JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJJ_3J_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jintLongArray arg3, jintLongArray arg4)
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJJ_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jintArray arg3)
#endif
{
- jintLong *lparg3=NULL;
- jintLong *lparg4=NULL;
+ jint *lparg3=NULL;
+ jint rc = 0;
+#ifndef JNI64
+ OS_NATIVE_ENTER(env, that, VtblCall__IIJ_3I_FUNC);
+#else
+ OS_NATIVE_ENTER(env, that, VtblCall__IJJ_3I_FUNC);
+#endif
+ if (arg3) if ((lparg3 = (*env)->GetIntArrayElements(env, arg3, NULL)) == NULL) goto fail;
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jint *))(*(jintLong **)arg1)[arg0])(arg1, arg2, lparg3);
+fail:
+ if (arg3 && lparg3) (*env)->ReleaseIntArrayElements(env, arg3, lparg3, 0);
+#ifndef JNI64
+ OS_NATIVE_EXIT(env, that, VtblCall__IIJ_3I_FUNC);
+#else
+ OS_NATIVE_EXIT(env, that, VtblCall__IJJ_3I_FUNC);
+#endif
+ return rc;
+}
+#endif
+
+#if (!defined(NO_VtblCall__IIJ_3I_3I) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJ_3I_3I) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IIJ_3I_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jintArray arg3, jintArray arg4)
+#else
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJJ_3I_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jintArray arg3, jintArray arg4)
+#endif
+{
+ jint *lparg3=NULL;
+ jint *lparg4=NULL;
jint rc = 0;
#ifndef JNI64
OS_NATIVE_ENTER(env, that, VtblCall__IIJ_3I_3I_FUNC);
#else
- OS_NATIVE_ENTER(env, that, VtblCall__IJJ_3J_3J_FUNC);
+ OS_NATIVE_ENTER(env, that, VtblCall__IJJ_3I_3I_FUNC);
#endif
- if (arg3) if ((lparg3 = (*env)->GetIntLongArrayElements(env, arg3, NULL)) == NULL) goto fail;
- if (arg4) if ((lparg4 = (*env)->GetIntLongArrayElements(env, arg4, NULL)) == NULL) goto fail;
- rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jintLong *, jintLong *))(*(jintLong **)arg1)[arg0])(arg1, arg2, lparg3, lparg4);
+ if (arg3) if ((lparg3 = (*env)->GetIntArrayElements(env, arg3, NULL)) == NULL) goto fail;
+ if (arg4) if ((lparg4 = (*env)->GetIntArrayElements(env, arg4, NULL)) == NULL) goto fail;
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jint *, jint *))(*(jintLong **)arg1)[arg0])(arg1, arg2, lparg3, lparg4);
fail:
- if (arg4 && lparg4) (*env)->ReleaseIntLongArrayElements(env, arg4, lparg4, 0);
- if (arg3 && lparg3) (*env)->ReleaseIntLongArrayElements(env, arg3, lparg3, 0);
+ if (arg4 && lparg4) (*env)->ReleaseIntArrayElements(env, arg4, lparg4, 0);
+ if (arg3 && lparg3) (*env)->ReleaseIntArrayElements(env, arg3, lparg3, 0);
#ifndef JNI64
OS_NATIVE_EXIT(env, that, VtblCall__IIJ_3I_3I_FUNC);
#else
+ OS_NATIVE_EXIT(env, that, VtblCall__IJJ_3I_3I_FUNC);
+#endif
+ return rc;
+}
+#endif
+
+#if (!defined(NO_VtblCall__IIJ_3J_3J) && !defined(JNI64)) || (!defined(NO_VtblCall__IJJ_3J_3J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IIJ_3J_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlongArray arg3, jlongArray arg4)
+#else
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJJ_3J_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlongArray arg3, jlongArray arg4)
+#endif
+{
+ jlong *lparg3=NULL;
+ jlong *lparg4=NULL;
+ jint rc = 0;
+#ifndef JNI64
+ OS_NATIVE_ENTER(env, that, VtblCall__IIJ_3J_3J_FUNC);
+#else
+ OS_NATIVE_ENTER(env, that, VtblCall__IJJ_3J_3J_FUNC);
+#endif
+ if (arg3) if ((lparg3 = (*env)->GetLongArrayElements(env, arg3, NULL)) == NULL) goto fail;
+ if (arg4) if ((lparg4 = (*env)->GetLongArrayElements(env, arg4, NULL)) == NULL) goto fail;
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jlong *, jlong *))(*(jintLong **)arg1)[arg0])(arg1, arg2, lparg3, lparg4);
+fail:
+ if (arg4 && lparg4) (*env)->ReleaseLongArrayElements(env, arg4, lparg4, 0);
+ if (arg3 && lparg3) (*env)->ReleaseLongArrayElements(env, arg3, lparg3, 0);
+#ifndef JNI64
+ OS_NATIVE_EXIT(env, that, VtblCall__IIJ_3J_3J_FUNC);
+#else
OS_NATIVE_EXIT(env, that, VtblCall__IJJ_3J_3J_FUNC);
#endif
return rc;
@@ -18130,30 +18221,60 @@ fail:
}
#endif
-#if (!defined(NO_VtblCall__II_3B_3I) && !defined(JNI64)) || (!defined(NO_VtblCall__IJ_3B_3J) && defined(JNI64))
+#if (!defined(NO_VtblCall__II_3B_3I) && !defined(JNI64)) || (!defined(NO_VtblCall__IJ_3B_3I) && defined(JNI64))
#ifndef JNI64
-JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__II_3B_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jintLongArray arg3)
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__II_3B_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jintArray arg3)
#else
-JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJ_3B_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jintLongArray arg3)
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJ_3B_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jintArray arg3)
#endif
{
jbyte *lparg2=NULL;
- jintLong *lparg3=NULL;
+ jint *lparg3=NULL;
jint rc = 0;
#ifndef JNI64
OS_NATIVE_ENTER(env, that, VtblCall__II_3B_3I_FUNC);
#else
- OS_NATIVE_ENTER(env, that, VtblCall__IJ_3B_3J_FUNC);
+ OS_NATIVE_ENTER(env, that, VtblCall__IJ_3B_3I_FUNC);
#endif
if (arg2) if ((lparg2 = (*env)->GetByteArrayElements(env, arg2, NULL)) == NULL) goto fail;
- if (arg3) if ((lparg3 = (*env)->GetIntLongArrayElements(env, arg3, NULL)) == NULL) goto fail;
- rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jbyte *, jintLong *))(*(jintLong **)arg1)[arg0])(arg1, lparg2, lparg3);
+ if (arg3) if ((lparg3 = (*env)->GetIntArrayElements(env, arg3, NULL)) == NULL) goto fail;
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jbyte *, jint *))(*(jintLong **)arg1)[arg0])(arg1, lparg2, lparg3);
fail:
- if (arg3 && lparg3) (*env)->ReleaseIntLongArrayElements(env, arg3, lparg3, 0);
+ if (arg3 && lparg3) (*env)->ReleaseIntArrayElements(env, arg3, lparg3, 0);
if (arg2 && lparg2) (*env)->ReleaseByteArrayElements(env, arg2, lparg2, 0);
#ifndef JNI64
OS_NATIVE_EXIT(env, that, VtblCall__II_3B_3I_FUNC);
#else
+ OS_NATIVE_EXIT(env, that, VtblCall__IJ_3B_3I_FUNC);
+#endif
+ return rc;
+}
+#endif
+
+#if (!defined(NO_VtblCall__II_3B_3J) && !defined(JNI64)) || (!defined(NO_VtblCall__IJ_3B_3J) && defined(JNI64))
+#ifndef JNI64
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__II_3B_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jlongArray arg3)
+#else
+JNIEXPORT jint JNICALL OS_NATIVE(VtblCall__IJ_3B_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jlongArray arg3)
+#endif
+{
+ jbyte *lparg2=NULL;
+ jlong *lparg3=NULL;
+ jint rc = 0;
+#ifndef JNI64
+ OS_NATIVE_ENTER(env, that, VtblCall__II_3B_3J_FUNC);
+#else
+ OS_NATIVE_ENTER(env, that, VtblCall__IJ_3B_3J_FUNC);
+#endif
+ if (arg2) if ((lparg2 = (*env)->GetByteArrayElements(env, arg2, NULL)) == NULL) goto fail;
+ if (arg3) if ((lparg3 = (*env)->GetLongArrayElements(env, arg3, NULL)) == NULL) goto fail;
+ rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jbyte *, jlong *))(*(jintLong **)arg1)[arg0])(arg1, lparg2, lparg3);
+fail:
+ if (arg3 && lparg3) (*env)->ReleaseLongArrayElements(env, arg3, lparg3, 0);
+ if (arg2 && lparg2) (*env)->ReleaseByteArrayElements(env, arg2, lparg2, 0);
+#ifndef JNI64
+ OS_NATIVE_EXIT(env, that, VtblCall__II_3B_3J_FUNC);
+#else
OS_NATIVE_EXIT(env, that, VtblCall__IJ_3B_3J_FUNC);
#endif
return rc;
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os.h b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os.h
index 759fa6f4cc..349ad4a3a7 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os.h
@@ -26,6 +26,7 @@
#include <shellapi.h>
#include <wininet.h>
#include <mshtmhst.h>
+#include <WinCrypt.h>
#ifndef _WIN32_WCE
#include <initguid.h>
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_stats.c b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_stats.c
index c817d59b70..edd5f02592 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_stats.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_stats.c
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2010 IBM Corporation and others.
+ * Copyright (c) 2000, 2011 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
@@ -14,8 +14,8 @@
#ifdef NATIVE_STATS
-int OS_nativeFunctionCount = 1031;
-int OS_nativeFunctionCallCount[1031];
+int OS_nativeFunctionCount = 1036;
+int OS_nativeFunctionCallCount[1036];
char * OS_nativeFunctionNames[] = {
"ACCEL_1sizeof",
"ACTCTX_1sizeof",
@@ -1132,11 +1132,6 @@ char * OS_nativeFunctionNames[] = {
"MoveMemory___3DJI",
#endif
#ifndef JNI64
- "MoveMemory___3D_3II",
-#else
- "MoveMemory___3D_3JI",
-#endif
-#ifndef JNI64
"MoveMemory___3FII",
#else
"MoveMemory___3FJI",
@@ -1833,7 +1828,12 @@ char * OS_nativeFunctionNames[] = {
#ifndef JNI64
"VtblCall__IIII_3C_3CI",
#else
- "VtblCall__IJJI_3C_3CJ",
+ "VtblCall__IJII_3C_3CI",
+#endif
+#ifndef JNI64
+ "VtblCall__IIIJ",
+#else
+ "VtblCall__IJIJ",
#endif
#ifndef JNI64
"VtblCall__IIIJI_3J",
@@ -1876,6 +1876,16 @@ char * OS_nativeFunctionNames[] = {
"VtblCall__IJJII_3J",
#endif
#ifndef JNI64
+ "VtblCall__IIJI_3C_3CJ",
+#else
+ "VtblCall__IJJI_3C_3CJ",
+#endif
+#ifndef JNI64
+ "VtblCall__IIJJ",
+#else
+ "VtblCall__IJJJ",
+#endif
+#ifndef JNI64
"VtblCall__IIJJI_3J",
#else
"VtblCall__IJJJI_3J",
@@ -1886,8 +1896,18 @@ char * OS_nativeFunctionNames[] = {
"VtblCall__IJJJJ",
#endif
#ifndef JNI64
+ "VtblCall__IIJ_3I",
+#else
+ "VtblCall__IJJ_3I",
+#endif
+#ifndef JNI64
"VtblCall__IIJ_3I_3I",
#else
+ "VtblCall__IJJ_3I_3I",
+#endif
+#ifndef JNI64
+ "VtblCall__IIJ_3J_3J",
+#else
"VtblCall__IJJ_3J_3J",
#endif
#ifndef JNI64
@@ -1913,6 +1933,11 @@ char * OS_nativeFunctionNames[] = {
#ifndef JNI64
"VtblCall__II_3B_3I",
#else
+ "VtblCall__IJ_3B_3I",
+#endif
+#ifndef JNI64
+ "VtblCall__II_3B_3J",
+#else
"VtblCall__IJ_3B_3J",
#endif
#ifndef JNI64
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_stats.h b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_stats.h
index 5f5e4433f9..7a76ec4c12 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_stats.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_stats.h
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2010 IBM Corporation and others.
+ * Copyright (c) 2000, 2011 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
@@ -1140,11 +1140,6 @@ typedef enum {
MoveMemory___3DJI_FUNC,
#endif
#ifndef JNI64
- MoveMemory___3D_3II_FUNC,
-#else
- MoveMemory___3D_3JI_FUNC,
-#endif
-#ifndef JNI64
MoveMemory___3FII_FUNC,
#else
MoveMemory___3FJI_FUNC,
@@ -1841,7 +1836,12 @@ typedef enum {
#ifndef JNI64
VtblCall__IIII_3C_3CI_FUNC,
#else
- VtblCall__IJJI_3C_3CJ_FUNC,
+ VtblCall__IJII_3C_3CI_FUNC,
+#endif
+#ifndef JNI64
+ VtblCall__IIIJ_FUNC,
+#else
+ VtblCall__IJIJ_FUNC,
#endif
#ifndef JNI64
VtblCall__IIIJI_3J_FUNC,
@@ -1884,6 +1884,16 @@ typedef enum {
VtblCall__IJJII_3J_FUNC,
#endif
#ifndef JNI64
+ VtblCall__IIJI_3C_3CJ_FUNC,
+#else
+ VtblCall__IJJI_3C_3CJ_FUNC,
+#endif
+#ifndef JNI64
+ VtblCall__IIJJ_FUNC,
+#else
+ VtblCall__IJJJ_FUNC,
+#endif
+#ifndef JNI64
VtblCall__IIJJI_3J_FUNC,
#else
VtblCall__IJJJI_3J_FUNC,
@@ -1894,8 +1904,18 @@ typedef enum {
VtblCall__IJJJJ_FUNC,
#endif
#ifndef JNI64
+ VtblCall__IIJ_3I_FUNC,
+#else
+ VtblCall__IJJ_3I_FUNC,
+#endif
+#ifndef JNI64
VtblCall__IIJ_3I_3I_FUNC,
#else
+ VtblCall__IJJ_3I_3I_FUNC,
+#endif
+#ifndef JNI64
+ VtblCall__IIJ_3J_3J_FUNC,
+#else
VtblCall__IJJ_3J_3J_FUNC,
#endif
#ifndef JNI64
@@ -1921,6 +1941,11 @@ typedef enum {
#ifndef JNI64
VtblCall__II_3B_3I_FUNC,
#else
+ VtblCall__IJ_3B_3I_FUNC,
+#endif
+#ifndef JNI64
+ VtblCall__II_3B_3J_FUNC,
+#else
VtblCall__IJ_3B_3J_FUNC,
#endif
#ifndef JNI64
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_structs.c b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_structs.c
index ccad423452..146f1f9c2d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_structs.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_structs.c
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2010 IBM Corporation and others.
+ * Copyright (c) 2000, 2011 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
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_structs.h b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_structs.h
index 1bee778c30..d366f17567 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_structs.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/library/os_structs.h
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2010 IBM Corporation and others.
+ * Copyright (c) 2000, 2011 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
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COM.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COM.java
index 64686811b0..5ceb001b10 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COM.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COM.java
@@ -675,11 +675,8 @@ public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, char[
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, char[] arg0, int arg1, int arg2, int arg3, int arg4, int [] arg5);
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, char[] arg0, long arg1, int arg2, int arg3, int arg4, long[] arg5);
-public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int[] arg1);
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, long[] arg1);
-public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, long arg1);
-
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, int[] arg2);
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1, long[] arg2);
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, long arg1, long[] arg2);
@@ -719,7 +716,8 @@ public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, int a
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, boolean arg1);
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, boolean arg0);
-public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, boolean arg0, int /*long*/ arg1);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, boolean arg0, int arg1);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, boolean arg0, long arg1);
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, CAUUID arg0);
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, CONTROLINFO arg0);
@@ -737,8 +735,6 @@ public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, GUID
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, GUID arg0, int arg1, int arg2, int arg3, int[] arg4);
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, GUID arg0, long arg1, int arg2, int arg3, int[] arg4);
-public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, long arg0, long arg1);
-
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, GUID arg0, int arg1, int arg2, int arg3, int arg4);
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, GUID arg0, int arg1, int arg2, long arg3, long arg4);
@@ -767,7 +763,8 @@ public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, int a
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, char[] pszPropName, int[] pVar, int[] pErrorLog);
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, char[] pszPropName, int pVar, int[] pErrorLog);
-public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, int /*long*/ type, int /*long*/ listener, boolean useCapture);
+public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, int type, int listener, boolean useCapture);
+public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, long type, long listener, boolean useCapture);
/** @param pStg cast=(IStorage *) */
public static final native int WriteClassStg(int /*long*/ pStg, GUID rclsid);
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/IPropertyBag.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/IPropertyBag.java
index 336bed5cac..48509f0746 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/IPropertyBag.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/IPropertyBag.java
@@ -1,17 +1,24 @@
+/*******************************************************************************
+ * Copyright (c) 2000, 2010 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.ole.win32;
+
public class IPropertyBag extends IUnknown {
-public IPropertyBag(int /*long*/ address) {
- super(address);
+public IPropertyBag (int /*long*/ address) {
+ super (address);
}
public int Read (int /*long*/ pszPropName, int /*long*/ pVar, int /*long*/[] pErrorLog) {
- return COM.VtblCall(3, getAddress(), pszPropName, pVar, pErrorLog);
-}
-
-public int Write (int /*long*/ propName, int /*long*/[] var, int /*long*/[] errorLog) {
- return COM.VtblCall(4, getAddress(), propName, var, errorLog);
+ return COM.VtblCall (3, getAddress(), pszPropName, pVar, pErrorLog);
}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/win32/OS.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/win32/OS.java
index 11ec2dfb21..a97f2657b9 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/win32/OS.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/win32/OS.java
@@ -1320,7 +1320,6 @@ public class OS extends C {
public static final int PD_ALLPAGES = 0x0;
public static final int PD_COLLATE = 0x10;
public static final int PD_PAGENUMS = 0x2;
- public static final int PD_PRINTSETUP = 0x00000040;
public static final int PD_PRINTTOFILE = 0x20;
public static final int PD_RETURNDC = 0x100;
public static final int PD_RETURNDEFAULT = 0x00000400;
@@ -5070,11 +5069,6 @@ public static final native void MoveMemory (double[] Destination, int /*long*/ S
* @param Destination cast=(PVOID),flags=no_in critical
* @param SourcePtr cast=(CONST VOID *)
*/
-public static final native void MoveMemory (double[] Destination, int /*long*/[] SourcePtr, int Length);
-/**
- * @param Destination cast=(PVOID),flags=no_in critical
- * @param SourcePtr cast=(CONST VOID *)
- */
public static final native void MoveMemory (float[] Destination, int /*long*/ SourcePtr, int Length);
/**
* @param Destination cast=(PVOID),flags=no_in critical
@@ -6744,8 +6738,10 @@ public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, char
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, short arg0, byte[] arg1, byte[] arg2, byte[] arg3);
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int[] arg0);
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, long[] arg0);
-public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, byte[] arg0, int /*long*/[] arg1);
-public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, long arg0, int /*long*/[] arg1, int /*long*/[] arg2);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, byte[] arg0, int[] arg1);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, byte[] arg0, long[] arg1);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, long arg0, int[] arg1, int[] arg2);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, long arg0, long[] arg1, long[] arg2);
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, TF_DISPLAYATTRIBUTE arg0);
public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, long arg1, long arg2);
@@ -6753,6 +6749,8 @@ public static final native int VtblCall(int fnNumber, int /*long*/ ppVtbl, long
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, int arg2);
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int arg0, long arg1);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, long arg0, long arg1);
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1);
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int[] arg0, byte[] arg1, int[] arg2);
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int[] arg0, byte[] arg1, long[] arg2);
@@ -6761,9 +6759,11 @@ public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, char
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, char[] arg0, long arg1);
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, PROPERTYKEY arg0, int arg1);
public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, PROPERTYKEY arg0, long arg1);
-public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int /*long*/ arg0, int arg1, char[] arg2, char[] arg3, int /*long*/ arg4);
-public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int arg0, int [] arg1);
-public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int arg0, long [] arg1);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, char[] arg2, char[] arg3, int arg4);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1, char[] arg2, char[] arg3, long arg4);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int arg0, int[] arg1);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, long arg0, int[] arg1);
+public static final native int VtblCall (int fnNumber, int /*long*/ ppVtbl, int arg0, long[] arg1);
public static final native boolean WaitMessage ();
/**
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32.cpp b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32.cpp
index 2e90a15a0c..2e8ed2c777 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32.cpp
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32.cpp
@@ -46,9 +46,9 @@ JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFArrayGetValueAtIndex)
#endif
#ifndef NO_CFDataCreate
-extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFDataCreate)(JNIEnv *env, jclass that, jint arg0, jbyteArray arg1, jint arg2);
+extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFDataCreate)(JNIEnv *env, jclass that, jintLong arg0, jbyteArray arg1, jint arg2);
JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFDataCreate)
- (JNIEnv *env, jclass that, jint arg0, jbyteArray arg1, jint arg2)
+ (JNIEnv *env, jclass that, jintLong arg0, jbyteArray arg1, jint arg2)
{
jbyte *lparg1=NULL;
jintLong rc = 0;
@@ -89,9 +89,9 @@ JNIEXPORT jint JNICALL WebKit_win32_NATIVE(CFDataGetLength)
#endif
#ifndef NO_CFDictionaryCreate
-extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFDictionaryCreate)(JNIEnv *env, jclass that, jint arg0, jintLongArray arg1, jintLongArray arg2, jint arg3, jintLong arg4, jintLong arg5);
+extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFDictionaryCreate)(JNIEnv *env, jclass that, jintLong arg0, jintLongArray arg1, jintLongArray arg2, jint arg3, jintLong arg4, jintLong arg5);
JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFDictionaryCreate)
- (JNIEnv *env, jclass that, jint arg0, jintLongArray arg1, jintLongArray arg2, jint arg3, jintLong arg4, jintLong arg5)
+ (JNIEnv *env, jclass that, jintLong arg0, jintLongArray arg1, jintLongArray arg2, jint arg3, jintLong arg4, jintLong arg5)
{
jintLong *lparg1=NULL;
jintLong *lparg2=NULL;
@@ -108,23 +108,10 @@ fail:
}
#endif
-#ifndef NO_CFDictionaryGetCount
-extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(CFDictionaryGetCount)(JNIEnv *env, jclass that, jintLong arg0);
-JNIEXPORT jint JNICALL WebKit_win32_NATIVE(CFDictionaryGetCount)
- (JNIEnv *env, jclass that, jintLong arg0)
-{
- jint rc = 0;
- WebKit_win32_NATIVE_ENTER(env, that, CFDictionaryGetCount_FUNC);
- rc = (jint)CFDictionaryGetCount((CFDictionaryRef)arg0);
- WebKit_win32_NATIVE_EXIT(env, that, CFDictionaryGetCount_FUNC);
- return rc;
-}
-#endif
-
#ifndef NO_CFHTTPCookieCreateWithResponseHeaderFields
-extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFHTTPCookieCreateWithResponseHeaderFields)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jintLong arg2);
+extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFHTTPCookieCreateWithResponseHeaderFields)(JNIEnv *env, jclass that, jintLong arg0, jintLong arg1, jintLong arg2);
JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFHTTPCookieCreateWithResponseHeaderFields)
- (JNIEnv *env, jclass that, jint arg0, jintLong arg1, jintLong arg2)
+ (JNIEnv *env, jclass that, jintLong arg0, jintLong arg1, jintLong arg2)
{
jintLong rc = 0;
WebKit_win32_NATIVE_ENTER(env, that, CFHTTPCookieCreateWithResponseHeaderFields_FUNC);
@@ -135,13 +122,13 @@ JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFHTTPCookieCreateWithResponseHea
#endif
#ifndef NO_CFHTTPCookieGetFlags
-extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFHTTPCookieGetFlags)(JNIEnv *env, jclass that, jintLong arg0);
-JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFHTTPCookieGetFlags)
+extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(CFHTTPCookieGetFlags)(JNIEnv *env, jclass that, jintLong arg0);
+JNIEXPORT jint JNICALL WebKit_win32_NATIVE(CFHTTPCookieGetFlags)
(JNIEnv *env, jclass that, jintLong arg0)
{
- jintLong rc = 0;
+ jint rc = 0;
WebKit_win32_NATIVE_ENTER(env, that, CFHTTPCookieGetFlags_FUNC);
- rc = (jintLong)CFHTTPCookieGetFlags((CFHTTPCookieRef)arg0);
+ rc = (jint)CFHTTPCookieGetFlags((CFHTTPCookieRef)arg0);
WebKit_win32_NATIVE_EXIT(env, that, CFHTTPCookieGetFlags_FUNC);
return rc;
}
@@ -232,19 +219,6 @@ JNIEXPORT void JNICALL WebKit_win32_NATIVE(CFRelease)
}
#endif
-#ifndef NO_CFRetain
-extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(CFRetain)(JNIEnv *env, jclass that, jintLong arg0);
-JNIEXPORT jint JNICALL WebKit_win32_NATIVE(CFRetain)
- (JNIEnv *env, jclass that, jintLong arg0)
-{
- jint rc = 0;
- WebKit_win32_NATIVE_ENTER(env, that, CFRetain_FUNC);
- rc = (jint)CFRetain((CFTypeRef)arg0);
- WebKit_win32_NATIVE_EXIT(env, that, CFRetain_FUNC);
- return rc;
-}
-#endif
-
#ifndef NO_CFStringCreateWithCharacters
extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(CFStringCreateWithCharacters)(JNIEnv *env, jclass that, jintLong arg0, jcharArray arg1, jint arg2);
JNIEXPORT jint JNICALL WebKit_win32_NATIVE(CFStringCreateWithCharacters)
@@ -302,9 +276,9 @@ JNIEXPORT jint JNICALL WebKit_win32_NATIVE(CFStringGetLength)
#endif
#ifndef NO_CFURLCreateWithString
-extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFURLCreateWithString)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jintLong arg2);
+extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFURLCreateWithString)(JNIEnv *env, jclass that, jintLong arg0, jintLong arg1, jintLong arg2);
JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFURLCreateWithString)
- (JNIEnv *env, jclass that, jint arg0, jintLong arg1, jintLong arg2)
+ (JNIEnv *env, jclass that, jintLong arg0, jintLong arg1, jintLong arg2)
{
jintLong rc = 0;
WebKit_win32_NATIVE_ENTER(env, that, CFURLCreateWithString_FUNC);
@@ -327,6 +301,19 @@ JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFURLRequestCopyHTTPRequestBody)
}
#endif
+#ifndef NO_CFURLRequestCreateMutableCopy
+extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFURLRequestCreateMutableCopy)(JNIEnv *env, jclass that, jintLong arg0, jintLong arg1);
+JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(CFURLRequestCreateMutableCopy)
+ (JNIEnv *env, jclass that, jintLong arg0, jintLong arg1)
+{
+ jintLong rc = 0;
+ WebKit_win32_NATIVE_ENTER(env, that, CFURLRequestCreateMutableCopy_FUNC);
+ rc = (jintLong)CFURLRequestCreateMutableCopy((CFAllocatorRef)arg0, (CFURLRequestRef)arg1);
+ WebKit_win32_NATIVE_EXIT(env, that, CFURLRequestCreateMutableCopy_FUNC);
+ return rc;
+}
+#endif
+
#ifndef NO_CFURLRequestSetHTTPRequestBody
extern "C" JNIEXPORT void JNICALL WebKit_win32_NATIVE(CFURLRequestSetHTTPRequestBody)(JNIEnv *env, jclass that, jintLong arg0, jintLong arg1);
JNIEXPORT void JNICALL WebKit_win32_NATIVE(CFURLRequestSetHTTPRequestBody)
@@ -338,6 +325,17 @@ JNIEXPORT void JNICALL WebKit_win32_NATIVE(CFURLRequestSetHTTPRequestBody)
}
#endif
+#ifndef NO_CFURLRequestSetURL
+extern "C" JNIEXPORT void JNICALL WebKit_win32_NATIVE(CFURLRequestSetURL)(JNIEnv *env, jclass that, jintLong arg0, jintLong arg1);
+JNIEXPORT void JNICALL WebKit_win32_NATIVE(CFURLRequestSetURL)
+ (JNIEnv *env, jclass that, jintLong arg0, jintLong arg1)
+{
+ WebKit_win32_NATIVE_ENTER(env, that, CFURLRequestSetURL_FUNC);
+ CFURLRequestSetURL((CFMutableURLRequestRef)arg0, (CFURLRef)arg1);
+ WebKit_win32_NATIVE_EXIT(env, that, CFURLRequestSetURL_FUNC);
+}
+#endif
+
#ifndef NO_JSClassCreate
extern "C" JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(JSClassCreate)(JNIEnv *env, jclass that, jintLong arg0);
JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(JSClassCreate)
@@ -407,19 +405,6 @@ fail:
}
#endif
-#ifndef NO_JSGlobalContextCreate
-extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(JSGlobalContextCreate)(JNIEnv *env, jclass that, jintLong arg0);
-JNIEXPORT jint JNICALL WebKit_win32_NATIVE(JSGlobalContextCreate)
- (JNIEnv *env, jclass that, jintLong arg0)
-{
- jint rc = 0;
- WebKit_win32_NATIVE_ENTER(env, that, JSGlobalContextCreate_FUNC);
- rc = (jint)JSGlobalContextCreate((JSClassRef)arg0);
- WebKit_win32_NATIVE_EXIT(env, that, JSGlobalContextCreate_FUNC);
- return rc;
-}
-#endif
-
#ifndef NO_JSGlobalContextRetain
extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(JSGlobalContextRetain)(JNIEnv *env, jclass that, jintLong arg0);
JNIEXPORT jint JNICALL WebKit_win32_NATIVE(JSGlobalContextRetain)
@@ -480,19 +465,6 @@ fail:
}
#endif
-#ifndef NO_JSObjectIsFunction
-extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(JSObjectIsFunction)(JNIEnv *env, jclass that, jintLong arg0, jintLong arg1);
-JNIEXPORT jint JNICALL WebKit_win32_NATIVE(JSObjectIsFunction)
- (JNIEnv *env, jclass that, jintLong arg0, jintLong arg1)
-{
- jint rc = 0;
- WebKit_win32_NATIVE_ENTER(env, that, JSObjectIsFunction_FUNC);
- rc = (jint)JSObjectIsFunction((JSContextRef)arg0, (JSObjectRef)arg1);
- WebKit_win32_NATIVE_EXIT(env, that, JSObjectIsFunction_FUNC);
- return rc;
-}
-#endif
-
#ifndef NO_JSObjectMake
extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(JSObjectMake)(JNIEnv *env, jclass that, jintLong arg0, jintLong arg1, jintLong arg2);
JNIEXPORT jint JNICALL WebKit_win32_NATIVE(JSObjectMake)
@@ -733,17 +705,6 @@ JNIEXPORT jintLong JNICALL WebKit_win32_NATIVE(JSValueMakeUndefined)
}
#endif
-#ifndef NO_JSValueProtect
-extern "C" JNIEXPORT void JNICALL WebKit_win32_NATIVE(JSValueProtect)(JNIEnv *env, jclass that, jintLong arg0, jintLong arg1);
-JNIEXPORT void JNICALL WebKit_win32_NATIVE(JSValueProtect)
- (JNIEnv *env, jclass that, jintLong arg0, jintLong arg1)
-{
- WebKit_win32_NATIVE_ENTER(env, that, JSValueProtect_FUNC);
- JSValueProtect((JSContextRef)arg0, (JSValueRef)arg1);
- WebKit_win32_NATIVE_EXIT(env, that, JSValueProtect_FUNC);
-}
-#endif
-
#ifndef NO_JSValueToBoolean
extern "C" JNIEXPORT jint JNICALL WebKit_win32_NATIVE(JSValueToBoolean)(JNIEnv *env, jclass that, jintLong arg0, jintLong arg1);
JNIEXPORT jint JNICALL WebKit_win32_NATIVE(JSValueToBoolean)
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_stats.cpp b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_stats.cpp
index a1b72604a1..75496ddc22 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_stats.cpp
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_stats.cpp
@@ -18,8 +18,8 @@
#ifdef NATIVE_STATS
-int WebKit_win32_nativeFunctionCount = 64;
-int WebKit_win32_nativeFunctionCallCount[64];
+int WebKit_win32_nativeFunctionCount = 61;
+int WebKit_win32_nativeFunctionCallCount[61];
char * WebKit_win32_nativeFunctionNames[] = {
"CFArrayGetCount",
"CFArrayGetValueAtIndex",
@@ -27,7 +27,6 @@ char * WebKit_win32_nativeFunctionNames[] = {
"CFDataGetBytePtr",
"CFDataGetLength",
"CFDictionaryCreate",
- "CFDictionaryGetCount",
"CFHTTPCookieCreateWithResponseHeaderFields",
"CFHTTPCookieGetFlags",
"CFHTTPCookieGetName",
@@ -37,20 +36,20 @@ char * WebKit_win32_nativeFunctionNames[] = {
"CFHTTPCookieStorageDeleteCookie",
"CFHTTPCookieStorageSetCookie",
"CFRelease",
- "CFRetain",
"CFStringCreateWithCharacters",
"CFStringGetCharacterAtIndex",
"CFStringGetCharactersPtr",
"CFStringGetLength",
"CFURLCreateWithString",
"CFURLRequestCopyHTTPRequestBody",
+ "CFURLRequestCreateMutableCopy",
"CFURLRequestSetHTTPRequestBody",
+ "CFURLRequestSetURL",
"JSClassCreate",
"JSClassDefinition_1sizeof",
"JSClassRetain",
"JSContextGetGlobalObject",
"JSEvaluateScript",
- "JSGlobalContextCreate",
"JSGlobalContextRetain",
"JSObjectCallAsFunctionProc_1CALLBACK",
"JSObjectGetPrivate",
@@ -58,7 +57,6 @@ char * WebKit_win32_nativeFunctionNames[] = {
"JSObjectGetPropertyAtIndex",
"JSObjectGetPropertyProc_1CALLBACK",
"JSObjectHasPropertyProc_1CALLBACK",
- "JSObjectIsFunction",
"JSObjectMake",
"JSObjectMakeArray",
"JSObjectMakeFunctionWithCallback",
@@ -76,7 +74,6 @@ char * WebKit_win32_nativeFunctionNames[] = {
"JSValueMakeNumber",
"JSValueMakeString",
"JSValueMakeUndefined",
- "JSValueProtect",
"JSValueToBoolean",
"JSValueToNumber",
"JSValueToStringCopy",
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_stats.h b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_stats.h
index a6996cb411..355b1a3c1e 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_stats.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/library/webkit_win32_stats.h
@@ -35,7 +35,6 @@ typedef enum {
CFDataGetBytePtr_FUNC,
CFDataGetLength_FUNC,
CFDictionaryCreate_FUNC,
- CFDictionaryGetCount_FUNC,
CFHTTPCookieCreateWithResponseHeaderFields_FUNC,
CFHTTPCookieGetFlags_FUNC,
CFHTTPCookieGetName_FUNC,
@@ -45,20 +44,20 @@ typedef enum {
CFHTTPCookieStorageDeleteCookie_FUNC,
CFHTTPCookieStorageSetCookie_FUNC,
CFRelease_FUNC,
- CFRetain_FUNC,
CFStringCreateWithCharacters_FUNC,
CFStringGetCharacterAtIndex_FUNC,
CFStringGetCharactersPtr_FUNC,
CFStringGetLength_FUNC,
CFURLCreateWithString_FUNC,
CFURLRequestCopyHTTPRequestBody_FUNC,
+ CFURLRequestCreateMutableCopy_FUNC,
CFURLRequestSetHTTPRequestBody_FUNC,
+ CFURLRequestSetURL_FUNC,
JSClassCreate_FUNC,
JSClassDefinition_1sizeof_FUNC,
JSClassRetain_FUNC,
JSContextGetGlobalObject_FUNC,
JSEvaluateScript_FUNC,
- JSGlobalContextCreate_FUNC,
JSGlobalContextRetain_FUNC,
JSObjectCallAsFunctionProc_1CALLBACK_FUNC,
JSObjectGetPrivate_FUNC,
@@ -66,7 +65,6 @@ typedef enum {
JSObjectGetPropertyAtIndex_FUNC,
JSObjectGetPropertyProc_1CALLBACK_FUNC,
JSObjectHasPropertyProc_1CALLBACK_FUNC,
- JSObjectIsFunction_FUNC,
JSObjectMake_FUNC,
JSObjectMakeArray_FUNC,
JSObjectMakeFunctionWithCallback_FUNC,
@@ -84,7 +82,6 @@ typedef enum {
JSValueMakeNumber_FUNC,
JSValueMakeString_FUNC,
JSValueMakeUndefined_FUNC,
- JSValueProtect_FUNC,
JSValueToBoolean_FUNC,
JSValueToNumber_FUNC,
JSValueToStringCopy_FUNC,
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebDownloadDelegate.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebDownloadDelegate.java
index 99c03bc184..1c6b193e4a 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebDownloadDelegate.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebDownloadDelegate.java
@@ -22,9 +22,9 @@ import org.eclipse.swt.widgets.*;
class WebDownloadDelegate {
COMObject iWebDownloadDelegate;
- int refCount = 0;
Browser browser;
+ int refCount = 0;
int status = -1;
int size;
long totalSize;
@@ -34,11 +34,11 @@ class WebDownloadDelegate {
static final int DOWNLOAD_CANCELLED = 1;
static final int DOWNLOAD_ERROR = 3;
-WebDownloadDelegate() {
- createCOMInterfaces();
+WebDownloadDelegate () {
+ createCOMInterfaces ();
}
-int AddRef() {
+int AddRef () {
refCount++;
return refCount;
}
@@ -48,47 +48,47 @@ void createCOMInterfaces () {
public int /*long*/ method0 (int /*long*/[] args) {return QueryInterface (args[0], args[1]);}
public int /*long*/ method1 (int /*long*/[] args) {return AddRef ();}
public int /*long*/ method2 (int /*long*/[] args) {return Release ();}
- public int /*long*/ method3 (int /*long*/[] args) {return decideDestinationWithSuggestedFilename(args[0], args[1]);}
+ public int /*long*/ method3 (int /*long*/[] args) {return decideDestinationWithSuggestedFilename (args[0], args[1]);}
public int /*long*/ method4 (int /*long*/[] args) {return COM.E_NOTIMPL;}
- public int /*long*/ method5 (int /*long*/[] args) {return didCreateDestination(args[0], args[1]);}
- public int /*long*/ method6 (int /*long*/[] args) {return didFailWithError(args[0], args[1]);}
+ public int /*long*/ method5 (int /*long*/[] args) {return didCreateDestination (args[0], args[1]);}
+ public int /*long*/ method6 (int /*long*/[] args) {return didFailWithError (args[0], args[1]);}
public int /*long*/ method7 (int /*long*/[] args) {return COM.E_NOTIMPL;}
- public int /*long*/ method8 (int /*long*/[] args) {return didReceiveDataOfLength(args[0], args[1]);}
- public int /*long*/ method9 (int /*long*/[] args) {return didReceiveResponse(args[0], args[1]);}
+ public int /*long*/ method8 (int /*long*/[] args) {return didReceiveDataOfLength (args[0], args[1]);}
+ public int /*long*/ method9 (int /*long*/[] args) {return didReceiveResponse (args[0], args[1]);}
public int /*long*/ method10 (int /*long*/[] args){return COM.E_NOTIMPL;}
public int /*long*/ method11 (int /*long*/[] args){return COM.E_NOTIMPL;}
- public int /*long*/ method12 (int /*long*/[] args){return willSendRequest(args[0], args[1], args[2], args[3]);}
- public int /*long*/ method13 (int /*long*/[] args){return didBegin(args[0]);}
- public int /*long*/ method14 (int /*long*/[] args){return didFinish(args[0]);}
+ public int /*long*/ method12 (int /*long*/[] args){return willSendRequest (args[0], args[1], args[2], args[3]);}
+ public int /*long*/ method13 (int /*long*/[] args){return didBegin (args[0]);}
+ public int /*long*/ method14 (int /*long*/[] args){return didFinish (args[0]);}
};
}
-int decideDestinationWithSuggestedFilename(int /*long*/ download, int /*long*/ filename) {
- String name = WebKit.extractBSTR(filename);
- FileDialog dialog = new FileDialog(browser.getShell(), SWT.SAVE);
- dialog.setText(SWT.getMessage ("SWT_FileDownload")); //$NON-NLS-1$
- dialog.setFileName(name);
- dialog.setOverwrite(true);
- String path = dialog.open();
- IWebDownload iwebdownload = new IWebDownload(download);
- iwebdownload.setDeletesFileUponFailure(false);
+int decideDestinationWithSuggestedFilename (int /*long*/ download, int /*long*/ filename) {
+ String name = WebKit.extractBSTR (filename);
+ FileDialog dialog = new FileDialog (browser.getShell(), SWT.SAVE);
+ dialog.setText (SWT.getMessage ("SWT_FileDownload")); //$NON-NLS-1$
+ dialog.setFileName (name);
+ dialog.setOverwrite (true);
+ String path = dialog.open ();
+ IWebDownload iwebdownload = new IWebDownload (download);
+ iwebdownload.setDeletesFileUponFailure (0);
if (path == null) {
/* cancel pressed */
// cancelling the download here causes crash, so set the cancelled status and call cancel in didCreateDestination
// iwebdownload.cancel();
status = DOWNLOAD_CANCELLED;
- iwebdownload.setDestination(WebKit.createBSTR(""), true); //$NON-NLS-1$
+ iwebdownload.setDestination (WebKit.createBSTR (""), 1); //$NON-NLS-1$
} else {
- File file = new File(path);
- if (file.exists()) file.delete();
- iwebdownload.setDestination(WebKit.createBSTR(path), true);
- openDownloadWindow(download, path);
+ File file = new File (path);
+ if (file.exists ()) file.delete ();
+ iwebdownload.setDestination (WebKit.createBSTR (path), 1);
+ openDownloadWindow (download, path);
}
return COM.S_OK;
}
-int didBegin(int /*long*/ download) {
- new IWebDownload(download).AddRef();
+int didBegin (int /*long*/ download) {
+ new IWebDownload (download).AddRef ();
status = -1;
size = 0;
totalSize = 0;
@@ -96,44 +96,44 @@ int didBegin(int /*long*/ download) {
return COM.S_OK;
}
-int didCreateDestination(int /*long*/ download, int /*long*/ destination) {
+int didCreateDestination (int /*long*/ download, int /*long*/ destination) {
if (status == DOWNLOAD_CANCELLED) {
/* user cancelled download in the file dialog */
- IWebDownload iwebdownload = new IWebDownload(download);
- iwebdownload.cancel();
- new IWebDownload(download).Release();
+ IWebDownload iwebdownload = new IWebDownload (download);
+ iwebdownload.cancel ();
+ new IWebDownload (download).Release ();
}
return COM.S_OK;
}
-int didFailWithError(int /*long*/ download, int /*long*/ error) {
- new IWebDownload(download).Release();
+int didFailWithError (int /*long*/ download, int /*long*/ error) {
+ new IWebDownload (download).Release ();
status = DOWNLOAD_ERROR;
return COM.S_OK;
}
-int didFinish(int /*long*/ download) {
- new IWebDownload(download).Release();
+int didFinish (int /*long*/ download) {
+ new IWebDownload (download).Release ();
status = DOWNLOAD_FINISHED;
return COM.S_OK;
}
-int didReceiveDataOfLength(int /*long*/ download, int /*long*/ length) {
+int didReceiveDataOfLength (int /*long*/ download, int /*long*/ length) {
size += length;
return COM.S_OK;
}
-int didReceiveResponse(int /*long*/ download, int /*long*/ response) {
+int didReceiveResponse (int /*long*/ download, int /*long*/ response) {
if (response != 0) {
- IWebURLResponse urlResponse = new IWebURLResponse(response);
+ IWebURLResponse urlResponse = new IWebURLResponse (response);
long [] size = new long [1];
- int hr = urlResponse.expectedContentLength(size);
+ int hr = urlResponse.expectedContentLength (size);
if (hr == COM.S_OK) totalSize = size[0];
int /*long*/[] result = new int /*long*/ [1];
- hr = urlResponse.URL(result);
+ hr = urlResponse.URL (result);
if (hr == COM.S_OK && result[0] !=0) {
- url = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ url = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
}
}
return COM.S_OK;
@@ -182,10 +182,10 @@ void openDownloadWindow (final int /*long*/ webkitDownload, String name) {
cancel.setLayoutData (data);
final Listener cancelListener = new Listener () {
public void handleEvent (Event event) {
- IWebDownload iwebdownload = new IWebDownload(webkitDownload);
- iwebdownload.cancel();
+ IWebDownload iwebdownload = new IWebDownload (webkitDownload);
+ iwebdownload.cancel ();
status = DOWNLOAD_CANCELLED;
- iwebdownload.Release();
+ iwebdownload.Release ();
}
};
cancel.addListener (SWT.Selection, cancelListener);
@@ -249,14 +249,15 @@ int Release () {
return refCount;
}
-void setBrowser(Browser browser) {
+void setBrowser (Browser browser) {
this.browser = browser;
}
-int willSendRequest(int /*long*/ download, int /*long*/ request, int /*long*/ redirectResponse, int /*long*/ finalRequest) {
- IWebMutableURLRequest req = new IWebMutableURLRequest(request);
- req.AddRef();
+int willSendRequest (int /*long*/ download, int /*long*/ request, int /*long*/ redirectResponse, int /*long*/ finalRequest) {
+ IWebMutableURLRequest req = new IWebMutableURLRequest (request);
+ req.AddRef ();
OS.MoveMemory (finalRequest, new int /*long*/[] {request}, C.PTR_SIZEOF);
return COM.S_OK;
}
+
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebFrameLoadDelegate.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebFrameLoadDelegate.java
index 81eebc7395..38f9b26683 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebFrameLoadDelegate.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebFrameLoadDelegate.java
@@ -33,8 +33,8 @@ class WebFrameLoadDelegate {
static final String OBJECTNAME_EXTERNAL = "external"; //$NON-NLS-1$
-WebFrameLoadDelegate() {
- createCOMInterfaces();
+WebFrameLoadDelegate () {
+ createCOMInterfaces ();
}
void addEventHandlers (boolean top) {
@@ -74,7 +74,7 @@ void addEventHandlers (boolean top) {
}
}
-int AddRef() {
+int AddRef () {
refCount++;
return refCount;
}
@@ -97,7 +97,7 @@ void createCOMInterfaces () {
public int /*long*/ method13 (int /*long*/[] args){return COM.E_NOTIMPL;}
public int /*long*/ method14 (int /*long*/[] args){return COM.S_OK;}
public int /*long*/ method15 (int /*long*/[] args){return COM.S_OK;}
- public int /*long*/ method16 (int /*long*/[] args){return didClearWindowObject(args[0], args[1], args[2], args[3]);}
+ public int /*long*/ method16 (int /*long*/[] args){return didClearWindowObject (args[0], args[1], args[2], args[3]);}
};
/* Callbacks that take double parameters require custom callbacks that instead pass pointers to the doubles. */
@@ -110,29 +110,29 @@ void createCOMInterfaces () {
COM.MoveMemory (pVtable[0], funcs, OS.PTR_SIZEOF * funcs.length);
}
-int didChangeLocationWithinPageForFrame(int /*long*/ webView, int /*long*/ frame) {
- IWebFrame iwebframe = new IWebFrame(frame);
+int didChangeLocationWithinPageForFrame (int /*long*/ webView, int /*long*/ frame) {
+ IWebFrame iwebframe = new IWebFrame (frame);
int /*long*/[] result = new int /*long*/[1];
- int hr = iwebframe.dataSource(result);
+ int hr = iwebframe.dataSource (result);
if (hr != COM.S_OK || result[0] == 0) {
- return COM.S_OK;
- }
- IWebDataSource dataSource = new IWebDataSource(result[0]);
+ return COM.S_OK;
+ }
+ IWebDataSource dataSource = new IWebDataSource (result[0]);
result[0] = 0;
- hr = dataSource.request(result);
- dataSource.Release();
+ hr = dataSource.request (result);
+ dataSource.Release ();
if (hr != COM.S_OK || result[0] == 0) {
- return COM.S_OK;
- }
- IWebURLRequest request = new IWebURLRequest(result[0]);
+ return COM.S_OK;
+ }
+ IWebURLRequest request = new IWebURLRequest (result[0]);
result[0] = 0;
- hr = request.URL(result);
- request.Release();
+ hr = request.URL (result);
+ request.Release ();
if (hr != COM.S_OK || result[0] == 0) {
- return COM.S_OK;
- }
- String url2 = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ return COM.S_OK;
+ }
+ String url2 = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
if (url2.length() == 0) return COM.S_OK;
/*
* If the URI indicates that the page is being rendered from memory
@@ -146,40 +146,40 @@ int didChangeLocationWithinPageForFrame(int /*long*/ webView, int /*long*/ frame
url2 = WebKit.ABOUT_BLANK + url2.substring (length);
}
}
- final Display display = browser.getDisplay();
+ final Display display = browser.getDisplay ();
result[0] = 0;
- IWebView iWebView = new IWebView(webView);
- hr = iWebView.mainFrame(result);
+ IWebView iWebView = new IWebView (webView);
+ hr = iWebView.mainFrame (result);
boolean top = false;
if (hr == COM.S_OK && result[0] != 0) {
top = frame == result[0];
- new IWebFrame(result[0]).Release();
- }
+ new IWebFrame (result[0]).Release ();
+ }
if (top) {
- StatusTextEvent statusText = new StatusTextEvent(browser);
+ StatusTextEvent statusText = new StatusTextEvent (browser);
statusText.display = display;
statusText.widget = browser;
statusText.text = url2;
StatusTextListener[] statusTextListeners = browser.webBrowser.statusTextListeners;
for (int i = 0; i < statusTextListeners.length; i++) {
- statusTextListeners[i].changed(statusText);
+ statusTextListeners[i].changed (statusText);
}
}
- LocationEvent location = new LocationEvent(browser);
+ LocationEvent location = new LocationEvent (browser);
location.display = display;
location.widget = browser;
location.location = url2;
location.top = top;
LocationListener[] locationListeners = browser.webBrowser.locationListeners;
for (int i = 0; i < locationListeners.length; i++) {
- locationListeners[i].changed(location);
+ locationListeners[i].changed (location);
}
return COM.S_OK;
}
-int didClearWindowObject(int /*long*/ webView, int /*long*/ context, int /*long*/ windowScriptObject, int /*long*/ frame) {
- WebKit_win32.JSGlobalContextRetain(context);
+int didClearWindowObject (int /*long*/ webView, int /*long*/ context, int /*long*/ windowScriptObject, int /*long*/ frame) {
+ WebKit_win32.JSGlobalContextRetain (context);
int /*long*/ globalObject = WebKit_win32.JSContextGetGlobalObject (context);
int /*long*/ privateData = ((WebKit)browser.webBrowser).webViewData;
int /*long*/ externalObject = WebKit_win32.JSObjectMake (context, WebKit.ExternalClass, privateData);
@@ -199,38 +199,38 @@ int didClearWindowObject(int /*long*/ webView, int /*long*/ context, int /*long*
browser.execute (current.functionString);
}
- IWebView iwebView = new IWebView(webView);
+ IWebView iwebView = new IWebView (webView);
int /*long*/[] mainFrame = new int /*long*/[1];
- iwebView.mainFrame(mainFrame);
+ iwebView.mainFrame (mainFrame);
boolean top = mainFrame[0] == frame;
addEventHandlers (top);
return COM.S_OK;
}
-int didCommitLoadForFrame(int /*long*/ webview, int /*long*/ frame) {
- IWebFrame iWebFrame = new IWebFrame(frame);
+int didCommitLoadForFrame (int /*long*/ webview, int /*long*/ frame) {
+ IWebFrame iWebFrame = new IWebFrame (frame);
int /*long*/[] result = new int /*long*/[1];
- int hr = iWebFrame.dataSource(result);
+ int hr = iWebFrame.dataSource (result);
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
}
- IWebDataSource dataSource = new IWebDataSource(result[0]);
+ IWebDataSource dataSource = new IWebDataSource (result[0]);
result[0] = 0;
- hr = dataSource.request(result);
- dataSource.Release();
+ hr = dataSource.request (result);
+ dataSource.Release ();
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
- }
- IWebMutableURLRequest request = new IWebMutableURLRequest(result[0]);
+ }
+ IWebMutableURLRequest request = new IWebMutableURLRequest (result[0]);
result[0] = 0;
- hr = request.URL(result);
- request.Release();
+ hr = request.URL (result);
+ request.Release ();
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
- }
- String url2 = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
- if (url2.length() == 0) return COM.S_OK;
+ }
+ String url2 = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
+ if (url2.length () == 0) return COM.S_OK;
/*
* 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.
@@ -243,15 +243,15 @@ int didCommitLoadForFrame(int /*long*/ webview, int /*long*/ frame) {
url2 = WebKit.ABOUT_BLANK + url2.substring (length);
}
}
- Display display = browser.getDisplay();
+ Display display = browser.getDisplay ();
result[0] = 0;
- IWebView iwebView = new IWebView(webview);
- hr = iwebView.mainFrame(result);
+ IWebView iwebView = new IWebView (webview);
+ hr = iwebView.mainFrame (result);
boolean top = false;
if (hr == COM.S_OK && result[0] != 0) {
top = frame == result[0];
- new IWebFrame(result[0]).Release();
- }
+ new IWebFrame (result[0]).Release ();
+ }
if (top) {
/* reset resource status variables */
this.url = url2;
@@ -263,7 +263,7 @@ int didCommitLoadForFrame(int /*long*/ webview, int /*long*/ frame) {
* first webView_didCommitLoadForFrame callback received for a setText() invocation
* then do not send any events or re-install registered BrowserFunctions.
*/
- if (url2.startsWith(WebKit.ABOUT_BLANK) && html != null) return COM.S_OK;
+ if (url2.startsWith (WebKit.ABOUT_BLANK) && html != null) return COM.S_OK;
/* re-install registered functions */
Enumeration elements = browser.webBrowser.functions.elements ();
@@ -272,78 +272,88 @@ int didCommitLoadForFrame(int /*long*/ webview, int /*long*/ frame) {
browser.webBrowser.execute (function.functionString);
}
- ProgressEvent progress = new ProgressEvent(browser);
+ ProgressEvent progress = new ProgressEvent (browser);
progress.display = display;
progress.widget = browser;
progress.current = 1;
progress.total = WebKit.MAX_PROGRESS;
ProgressListener[] progressListeners = browser.webBrowser.progressListeners;
for (int i = 0; i < progressListeners.length; i++) {
- progressListeners[i].changed(progress);
+ progressListeners[i].changed (progress);
}
- if (browser.isDisposed()) return COM.S_OK;
+ if (browser.isDisposed ()) return COM.S_OK;
- StatusTextEvent statusText = new StatusTextEvent(browser);
+ StatusTextEvent statusText = new StatusTextEvent (browser);
statusText.display = display;
statusText.widget = browser;
statusText.text = url2;
StatusTextListener[] statusTextListeners = browser.webBrowser.statusTextListeners;
for (int i = 0; i < statusTextListeners.length; i++) {
- statusTextListeners[i].changed(statusText);
+ statusTextListeners[i].changed (statusText);
}
- if (browser.isDisposed()) return COM.S_OK;
+ if (browser.isDisposed ()) return COM.S_OK;
}
- LocationEvent location = new LocationEvent(browser);
+ LocationEvent location = new LocationEvent (browser);
location.display = display;
location.widget = browser;
location.location = url2;
location.top = top;
LocationListener[] locationListeners = browser.webBrowser.locationListeners;
for (int i = 0; i < locationListeners.length; i++) {
- locationListeners[i].changed(location);
+ locationListeners[i].changed (location);
}
return COM.S_OK;
}
-int didFailProvisionalLoadWithError(int /*long*/ webView, int /*long*/ error, int /*long*/ frame) {
- IWebError iweberror = new IWebError(error);
+int didFailProvisionalLoadWithError (int /*long*/ webView, int /*long*/ error, int /*long*/ frame) {
+ IWebError iweberror = new IWebError (error);
int [] errorCode = new int [1];
- int hr = iweberror.code(errorCode);
+ int hr = iweberror.code (errorCode);
if (WebKit_win32.WebURLErrorBadURL < errorCode[0]) return COM.S_OK;;
String failingURLString = null;
int /*long*/[] failingURL = new int /*long*/[1];
hr = iweberror.failingURL (failingURL);
if (hr == COM.S_OK && failingURL[0] != 0) {
- failingURLString = WebKit.extractBSTR(failingURL[0]);
- COM.SysFreeString(failingURL[0]);
+ failingURLString = WebKit.extractBSTR (failingURL[0]);
+ COM.SysFreeString (failingURL[0]);
}
if (failingURLString != null && WebKit_win32.WebURLErrorServerCertificateNotYetValid <= errorCode[0] && errorCode[0] <= WebKit_win32.WebURLErrorSecureConnectionFailed) {
/* handle invalid certificate error */
int /*long*/[] result = new int /*long*/[1];
- hr = iweberror.localizedDescription(result);
+ hr = iweberror.localizedDescription (result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return COM.S_OK;
+ }
+ String description = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
+
+ result[0] = 0;
+ hr = iweberror.QueryInterface (WebKit_win32.IID_IWebErrorPrivate, result);
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
}
- String description = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+
+ IWebErrorPrivate webErrorPrivate = new IWebErrorPrivate (result[0]);
+ result[0] = 0;
int /*long*/[] certificate = new int /*long*/[1];
- hr = iweberror.sslPeerCertificate(certificate);
+ hr = webErrorPrivate.sslPeerCertificate (certificate);
+ webErrorPrivate.Release ();
if (hr != COM.S_OK || certificate[0] == 0) {
return COM.S_OK;
}
- if (showCertificateDialog(webView, failingURLString, description, certificate[0])){
- IWebFrame iWebFrame = new IWebFrame(frame);
+ if (showCertificateDialog (webView, failingURLString, description, certificate[0])){
+ IWebFrame iWebFrame = new IWebFrame (frame);
hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebMutableURLRequest, 0, WebKit_win32.IID_IWebMutableURLRequest, result);
if (hr != COM.S_OK || result[0] == 0) {
certificate[0] = 0;
return COM.S_OK;
}
IWebMutableURLRequest request = new IWebMutableURLRequest (result[0]);
- request.setURL(failingURL[0]);
- request.setAllowsAnyHTTPSCertificate();
- iWebFrame.loadRequest(request.getAddress());
- request.Release();
+ request.setURL (failingURL[0]);
+ request.setAllowsAnyHTTPSCertificate ();
+ iWebFrame.loadRequest (request.getAddress ());
+ request.Release ();
}
certificate[0] = 0;
return COM.S_OK;
@@ -351,48 +361,48 @@ int didFailProvisionalLoadWithError(int /*long*/ webView, int /*long*/ error, in
/* handle other types of errors */
int /*long*/[] result = new int /*long*/[1];
- hr = iweberror.localizedDescription(result);
+ hr = iweberror.localizedDescription (result);
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
}
- String description = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
- if (!browser.isDisposed()) {
+ String description = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
+ if (!browser.isDisposed ()) {
String message = failingURLString != null ? failingURLString + "\n\n" : ""; //$NON-NLS-1$ //$NON-NLS-2$
message += Compatibility.getMessage ("SWT_Page_Load_Failed", new Object[] {description}); //$NON-NLS-1$
- MessageBox messageBox = new MessageBox(browser.getShell(), SWT.OK | SWT.ICON_ERROR);
- messageBox.setMessage(message);
- messageBox.open();
+ MessageBox messageBox = new MessageBox (browser.getShell (), SWT.OK | SWT.ICON_ERROR);
+ messageBox.setMessage (message);
+ messageBox.open ();
}
return COM.S_OK;
}
-int didFinishLoadForFrame(int /*long*/ webview, int /*long*/ frame) {
- IWebView iWebView = new IWebView(webview);
+int didFinishLoadForFrame (int /*long*/ webview, int /*long*/ frame) {
+ IWebView iWebView = new IWebView (webview);
int /*long*/[] iWebFrame = new int /*long*/[1];
- int hr = iWebView.mainFrame(iWebFrame);
+ int hr = iWebView.mainFrame (iWebFrame);
if (hr != COM.S_OK || iWebFrame[0] == 0) {
return COM.S_OK;
- }
+ }
boolean top = frame == iWebFrame[0];
- new IWebFrame(iWebFrame[0]).Release();
+ new IWebFrame (iWebFrame[0]).Release();
if (top) {
/*
* If html 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 (html != null) {
- if (getUrl().startsWith(WebKit.ABOUT_BLANK)) {
+ if (getUrl ().startsWith (WebKit.ABOUT_BLANK)) {
((WebKit)browser.webBrowser).loadingText = true;
- int /*long*/ string = WebKit.createBSTR(html);
+ int /*long*/ string = WebKit.createBSTR (html);
int /*long*/ URLString;
if (((WebKit)browser.webBrowser).untrustedText) {
- URLString = WebKit.createBSTR(WebKit.ABOUT_BLANK);
+ URLString = WebKit.createBSTR (WebKit.ABOUT_BLANK);
} else {
- URLString = WebKit.createBSTR(WebKit.URI_FILEROOT);
+ URLString = WebKit.createBSTR (WebKit.URI_FILEROOT);
}
- IWebFrame mainFrame = new IWebFrame(frame);
- mainFrame.loadHTMLString(string, URLString);
+ IWebFrame mainFrame = new IWebFrame (frame);
+ mainFrame.loadHTMLString (string, URLString);
html = null;
}
}
@@ -403,7 +413,7 @@ int didFinishLoadForFrame(int /*long*/ webview, int /*long*/ frame) {
* second callback to come before sending the title or completed events.
*/
if (!((WebKit)browser.webBrowser).loadingText) {
- if (browser.isDisposed()) return COM.S_OK;
+ if (browser.isDisposed ()) return COM.S_OK;
/*
* To be consistent with other platforms a title event should be fired when a
* page has completed loading. A page with a <title> tag will do this
@@ -411,76 +421,76 @@ int didFinishLoadForFrame(int /*long*/ webview, int /*long*/ frame) {
* without a <title> tag will not do this by default, so fire the event
* here with the page's url as the title.
*/
- Display display = browser.getDisplay();
- IWebFrame mainFrame = new IWebFrame(frame);
+ Display display = browser.getDisplay ();
+ IWebFrame mainFrame = new IWebFrame (frame);
int /*long*/[] result = new int /*long*/[1];
- hr = mainFrame.dataSource(result);
+ hr = mainFrame.dataSource (result);
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
}
- IWebDataSource dataSource = new IWebDataSource(result[0]);
+ IWebDataSource dataSource = new IWebDataSource (result[0]);
result[0] = 0;
- hr = dataSource.pageTitle(result);
- dataSource.Release();
+ hr = dataSource.pageTitle (result);
+ dataSource.Release ();
if (hr != COM.S_OK) {
return COM.S_OK;
}
String title = null;
if (result[0] != 0) {
- title = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ title = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
}
- if (title == null || title.length() == 0) { /* page has no title */
- TitleEvent newEvent = new TitleEvent(browser);
+ if (title == null || title.length () == 0) { /* page has no title */
+ TitleEvent newEvent = new TitleEvent (browser);
newEvent.display = display;
newEvent.widget = browser;
- newEvent.title = getUrl();
+ newEvent.title = getUrl ();
TitleListener[] titleListeners = browser.webBrowser.titleListeners;
for (int i = 0; i < titleListeners.length; i++) {
- titleListeners[i].changed(newEvent);
+ titleListeners[i].changed (newEvent);
}
- if (browser.isDisposed()) return COM.S_OK;
+ if (browser.isDisposed ()) return COM.S_OK;
}
- ProgressEvent progress = new ProgressEvent(browser);
+ ProgressEvent progress = new ProgressEvent (browser);
progress.display = display;
progress.widget = browser;
progress.current = WebKit.MAX_PROGRESS;
progress.total = WebKit.MAX_PROGRESS;
ProgressListener[] progressListeners = browser.webBrowser.progressListeners;
for (int i = 0; i < progressListeners.length; i++) {
- progressListeners[i].completed(progress);
+ progressListeners[i].completed (progress);
}
}
((WebKit)browser.webBrowser).loadingText = false;
- if (browser.isDisposed()) return COM.S_OK;
+ if (browser.isDisposed ()) return COM.S_OK;
}
return COM.S_OK;
}
-int didReceiveTitle(int /*long*/ webView, int /*long*/ title, int /*long*/ frame) {
+int didReceiveTitle (int /*long*/ webView, int /*long*/ title, int /*long*/ frame) {
int /*long*/[] mainFrame = new int /*long*/[1];
- IWebView iWebView = new IWebView(webView);
- int hr = iWebView.mainFrame(mainFrame);
+ IWebView iWebView = new IWebView (webView);
+ int hr = iWebView.mainFrame (mainFrame);
if (hr != COM.S_OK || frame == 0) {
return COM.S_OK;
}
if (frame == mainFrame[0]) {
- String newTitle = WebKit.extractBSTR(title);
- TitleEvent newEvent = new TitleEvent(browser);
- newEvent.display = browser.getDisplay();
+ String newTitle = WebKit.extractBSTR (title);
+ TitleEvent newEvent = new TitleEvent (browser);
+ newEvent.display = browser.getDisplay ();
newEvent.widget = browser;
newEvent.title = newTitle;
TitleListener[] titleListeners = browser.webBrowser.titleListeners;
for (int i = 0; i < titleListeners.length; i++) {
- titleListeners[i].changed(newEvent);
+ titleListeners[i].changed (newEvent);
}
}
- new IWebFrame(mainFrame[0]).Release();
+ new IWebFrame (mainFrame[0]).Release ();
return COM.S_OK;
}
-int didStartProvisionalLoadForFrame(int /*long*/ webView, int /*long*/ frame) {
+int didStartProvisionalLoadForFrame (int /*long*/ webView, int /*long*/ frame) {
return COM.S_OK;
}
@@ -497,7 +507,7 @@ int /*long*/ getAddress () {
String getUrl () {
/* WebKit auto-navigates to about:blank at startup */
- if (url == null || url.length() == 0) return WebKit.ABOUT_BLANK;
+ if (url == null || url.length () == 0) return WebKit.ABOUT_BLANK;
return url;
}
@@ -535,8 +545,8 @@ void setBrowser (Browser browser) {
boolean showCertificateDialog (int /*long*/ webView, final String failingUrlString, final String description, int /*long*/ certificate) {
Shell parent = browser.getShell ();
- final Shell shell = new Shell(parent, SWT.APPLICATION_MODAL | SWT.DIALOG_TRIM);
- shell.setText(Compatibility.getMessage("SWT_InvalidCert_Title")); //$NON-NLS-1$
+ final Shell shell = new Shell (parent, SWT.APPLICATION_MODAL | SWT.DIALOG_TRIM);
+ shell.setText (Compatibility.getMessage("SWT_InvalidCert_Title")); //$NON-NLS-1$
shell.setLayout (new GridLayout ());
Label label = new Label (shell, SWT.WRAP);
//if unable to get host, show the url
@@ -565,7 +575,7 @@ boolean showCertificateDialog (int /*long*/ webView, final String failingUrlStri
final boolean[] result = new boolean[1];
final Button[] buttons = new Button[3];
Listener listener = new Listener() {
- public void handleEvent(Event event) {
+ public void handleEvent (Event event) {
if (event.widget == buttons[2]) {
//showCertificate() //:TODO Not sure how to show the certificate
} else {
@@ -596,12 +606,12 @@ boolean showCertificateDialog (int /*long*/ webView, final String failingUrlStri
shell.setDefaultButton (buttons[0]);
shell.pack ();
- Rectangle parentSize = parent.getBounds();
- Rectangle shellSize = shell.getBounds();
+ Rectangle parentSize = parent.getBounds ();
+ Rectangle shellSize = shell.getBounds ();
int x, y;
- x = parent.getLocation().x + (parentSize.width - shellSize.width)/2;
- y = parent.getLocation().y + (parentSize.height - shellSize.height)/2;
- shell.setLocation(x, y);
+ x = parent.getLocation ().x + (parentSize.width - shellSize.width)/2;
+ y = parent.getLocation ().y + (parentSize.height - shellSize.height)/2;
+ shell.setLocation (x, y);
shell.open ();
Display display = browser.getDisplay ();
while (!shell.isDisposed ()) {
@@ -609,5 +619,5 @@ boolean showCertificateDialog (int /*long*/ webView, final String failingUrlStri
}
return result[0];
}
-}
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebKit.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebKit.java
index 1e2e34f255..aca792a4c2 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebKit.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebKit.java
@@ -25,6 +25,8 @@ import org.eclipse.swt.widgets.*;
class WebKit extends WebBrowser {
IWebView webView;
int /*long*/ webViewWindowHandle, webViewData;
+ int refCount = 0;
+ int lastKeyCode, lastCharCode;
WebDownloadDelegate webDownloadDelegate;
WebFrameLoadDelegate webFrameLoadDelegate;
@@ -32,16 +34,13 @@ class WebKit extends WebBrowser {
WebResourceLoadDelegate webResourceLoadDelegate;
WebUIDelegate webUIDelegate;
- int refCount = 0;
- int lastKeyCode, lastCharCode;
-
- boolean loadingText = false;
- boolean untrustedText;
boolean ignoreDispose;
+ boolean loadingText = false;
+ boolean traverseNext = true;
boolean traverseOut = false;
+ boolean untrustedText;
String lastNavigateURL;
BrowserFunction eventFunction;
- protected boolean traverseNext = true;
static int /*long*/ ExternalClass;
static boolean webkitRegistered = false;
@@ -75,8 +74,6 @@ class WebKit extends WebBrowser {
static final String DOMEVENT_MOUSEOVER = "mouseover"; //$NON-NLS-1$
static final String DOMEVENT_MOUSEWHEEL = "mousewheel"; //$NON-NLS-1$
- static final char SEPARATOR_FILE = System.getProperty ("file.separator").charAt(0); //$NON-NLS-1$
-
static {
/* ensure that webkit's COM objects are registered */
TCHAR lpLibFileName = new TCHAR (0, "WebKit.dll", true); //$NON-NLS-1$
@@ -103,131 +100,131 @@ static {
JSObjectCallAsFunctionProc = new Callback (WebKit.class, "JSObjectCallAsFunctionProc", 6); //$NON-NLS-1$
if (JSObjectCallAsFunctionProc.getAddress () == 0) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
- NativeClearSessions = new Runnable() {
- public void run() {
+ NativeClearSessions = new Runnable () {
+ public void run () {
int /*long*/[] result = new int /*long*/[1];
- int hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebCookieManager, 0, WebKit_win32.IID_IWebCookieManager, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return;
- }
- IWebCookieManager cookieManager = new IWebCookieManager(result[0]);
+ int hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebCookieManager, 0, WebKit_win32.IID_IWebCookieManager, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return;
+ }
+ IWebCookieManager cookieManager = new IWebCookieManager (result[0]);
int /*long*/[] storage = new int /*long*/[1];
- hr = cookieManager.cookieStorage(storage);
- cookieManager.Release();
+ hr = cookieManager.cookieStorage (storage);
+ cookieManager.Release ();
if (hr != COM.S_OK || storage[0] == 0) {
return;
}
- int /*long*/ cookies = WebKit_win32.CFHTTPCookieStorageCopyCookies(storage[0]);
+ int /*long*/ cookies = WebKit_win32.CFHTTPCookieStorageCopyCookies (storage[0]);
if (cookies != 0) {
- int count = WebKit_win32.CFArrayGetCount(cookies);
+ int count = WebKit_win32.CFArrayGetCount (cookies);
for (int i = 0; i < count; i++) {
- int /*long*/ cookie = WebKit_win32.CFArrayGetValueAtIndex(cookies, i);
- int /*long*/ flags = WebKit_win32.CFHTTPCookieGetFlags(cookie);
+ int /*long*/ cookie = WebKit_win32.CFArrayGetValueAtIndex (cookies, i);
+ int /*long*/ flags = WebKit_win32.CFHTTPCookieGetFlags (cookie);
if ((flags & WebKit_win32.CFHTTPCookieSessionOnlyFlag) != 0) {
- WebKit_win32.CFHTTPCookieStorageDeleteCookie(storage[0], cookie);
+ WebKit_win32.CFHTTPCookieStorageDeleteCookie (storage[0], cookie);
}
}
- WebKit_win32.CFRelease(cookies);
+ WebKit_win32.CFRelease (cookies);
}
-// WebKit_win32.CFRelease(storage[0]); //intentionally commented, causes crash
+// WebKit_win32.CFRelease (storage[0]); //intentionally commented, causes crash
}
};
NativeGetCookie = new Runnable () {
public void run () {
int /*long*/[] result = new int /*long*/[1];
- int hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebCookieManager, 0, WebKit_win32.IID_IWebCookieManager, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return;
- }
- IWebCookieManager cookieManager = new IWebCookieManager(result[0]);
+ int hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebCookieManager, 0, WebKit_win32.IID_IWebCookieManager, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return;
+ }
+ IWebCookieManager cookieManager = new IWebCookieManager (result[0]);
int /*long*/[] storage = new int /*long*/[1];
- hr = cookieManager.cookieStorage(storage);
- cookieManager.Release();
+ hr = cookieManager.cookieStorage (storage);
+ cookieManager.Release ();
if (hr != COM.S_OK || storage[0] == 0) {
- return;
- }
- char [] array = CookieUrl.toCharArray();
- int /*long*/ string = WebKit_win32.CFStringCreateWithCharacters(0, array, array.length);
+ return;
+ }
+ char [] array = CookieUrl.toCharArray ();
+ int /*long*/ string = WebKit_win32.CFStringCreateWithCharacters (0, array, array.length);
if (string != 0) {
- int /*long*/ cfUrl = WebKit_win32.CFURLCreateWithString(0, string, 0);
+ int /*long*/ cfUrl = WebKit_win32.CFURLCreateWithString (0, string, 0);
if (cfUrl != 0) {
- boolean secure = CookieUrl.startsWith(PROTOCOL_HTTPS);
- int /*long*/ cookiesArray = WebKit_win32.CFHTTPCookieStorageCopyCookiesForURL(storage[0], cfUrl, secure);
+ boolean secure = CookieUrl.startsWith (PROTOCOL_HTTPS);
+ int /*long*/ cookiesArray = WebKit_win32.CFHTTPCookieStorageCopyCookiesForURL (storage[0], cfUrl, secure);
if (cookiesArray != 0) {
- int count = WebKit_win32.CFArrayGetCount(cookiesArray);
+ int count = WebKit_win32.CFArrayGetCount (cookiesArray);
for (int i = 0; i < count; i++) {
- int /*long*/ cookie = WebKit_win32.CFArrayGetValueAtIndex(cookiesArray, i);
+ int /*long*/ cookie = WebKit_win32.CFArrayGetValueAtIndex (cookiesArray, i);
if (cookie != 0) {
- int /*long*/ cookieName = WebKit_win32.CFHTTPCookieGetName(cookie);
+ int /*long*/ cookieName = WebKit_win32.CFHTTPCookieGetName (cookie);
if (cookieName != 0) {
- char[] name = stringFromCFString(cookieName);
- if (CookieName.equals(new String(name))) {
- int /*long*/ value = WebKit_win32.CFHTTPCookieGetValue(cookie);
- if (value != 0) CookieValue = new String (stringFromCFString(value));
+ char[] name = stringFromCFString (cookieName);
+ if (CookieName.equals (new String (name))) {
+ int /*long*/ value = WebKit_win32.CFHTTPCookieGetValue (cookie);
+ if (value != 0) CookieValue = new String (stringFromCFString (value));
break;
}
}
}
}
- WebKit_win32.CFRelease(cookiesArray);
+ WebKit_win32.CFRelease (cookiesArray);
}
- WebKit_win32.CFRelease(cfUrl);
+ WebKit_win32.CFRelease (cfUrl);
}
- WebKit_win32.CFRelease(string);
+ WebKit_win32.CFRelease (string);
}
-// WebKit_win32.CFRelease(storage[0]); //intentionally commented, causes crash
+// WebKit_win32.CFRelease (storage[0]); //intentionally commented, causes crash
}
};
NativeSetCookie = new Runnable () {
public void run () {
int /*long*/[] result = new int /*long*/[1];
- int hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebCookieManager, 0, WebKit_win32.IID_IWebCookieManager, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return;
- }
- IWebCookieManager cookieManager = new IWebCookieManager(result[0]);
+ int hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebCookieManager, 0, WebKit_win32.IID_IWebCookieManager, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return;
+ }
+ IWebCookieManager cookieManager = new IWebCookieManager (result[0]);
int /*long*/[] storage = new int /*long*/[1];
- hr = cookieManager.cookieStorage(storage);
- cookieManager.Release();
+ hr = cookieManager.cookieStorage (storage);
+ cookieManager.Release ();
if (hr != COM.S_OK || storage[0] == 0) {
- return;
- }
+ return;
+ }
- char [] array = CookieUrl.toCharArray();
- int /*long*/ string = WebKit_win32.CFStringCreateWithCharacters(0, array, array.length);
+ char [] array = CookieUrl.toCharArray ();
+ int /*long*/ string = WebKit_win32.CFStringCreateWithCharacters (0, array, array.length);
if (string != 0) {
- int /*long*/ cfUrl = WebKit_win32.CFURLCreateWithString(0, string, 0);
+ int /*long*/ cfUrl = WebKit_win32.CFURLCreateWithString (0, string, 0);
if (cfUrl != 0) {
- array = CookieValue.toCharArray();
- int /*long*/ value = WebKit_win32.CFStringCreateWithCharacters(0, array, array.length);
+ array = CookieValue.toCharArray ();
+ int /*long*/ value = WebKit_win32.CFStringCreateWithCharacters (0, array, array.length);
if (value != 0) {
- array = HEADER_SETCOOKIE.toCharArray();
- int /*long*/ key = WebKit_win32.CFStringCreateWithCharacters(0, array, array.length);
+ array = HEADER_SETCOOKIE.toCharArray ();
+ int /*long*/ key = WebKit_win32.CFStringCreateWithCharacters (0, array, array.length);
if (key != 0) {
- int /*long*/ headers = WebKit_win32.CFDictionaryCreate(0, new int /*long*/ []{key}, new int /*long*/ []{value}, 1, WebKit_win32.kCFCopyStringDictionaryKeyCallBacks(), WebKit_win32.kCFTypeDictionaryValueCallBacks());
+ int /*long*/ headers = WebKit_win32.CFDictionaryCreate (0, new int /*long*/ []{key}, new int /*long*/ []{value}, 1, WebKit_win32.kCFCopyStringDictionaryKeyCallBacks (), WebKit_win32.kCFTypeDictionaryValueCallBacks ());
if (headers != 0) {
- int /*long*/ cookies = WebKit_win32.CFHTTPCookieCreateWithResponseHeaderFields(0, headers, cfUrl);
+ int /*long*/ cookies = WebKit_win32.CFHTTPCookieCreateWithResponseHeaderFields (0, headers, cfUrl);
if (cookies != 0) {
- int /*long*/ cookie = WebKit_win32.CFArrayGetValueAtIndex(cookies, 0);
+ int /*long*/ cookie = WebKit_win32.CFArrayGetValueAtIndex (cookies, 0);
if (cookie != 0) {
- WebKit_win32.CFHTTPCookieStorageSetCookie(storage[0], cookie);
+ WebKit_win32.CFHTTPCookieStorageSetCookie (storage[0], cookie);
CookieResult = true;
}
- WebKit_win32.CFRelease(cookies);
+ WebKit_win32.CFRelease (cookies);
}
- WebKit_win32.CFRelease(headers);
+ WebKit_win32.CFRelease (headers);
}
- WebKit_win32.CFRelease(key);
+ WebKit_win32.CFRelease (key);
}
- WebKit_win32.CFRelease(value);
+ WebKit_win32.CFRelease (value);
}
- WebKit_win32.CFRelease(cfUrl);
+ WebKit_win32.CFRelease (cfUrl);
}
- WebKit_win32.CFRelease(string);
+ WebKit_win32.CFRelease (string);
}
-// WebKit_win32.CFRelease(storage[0]); //intentionally commented, causes crash
+// WebKit_win32.CFRelease (storage[0]); //intentionally commented, causes crash
}
};
@@ -252,9 +249,9 @@ static String extractBSTR (int /*long*/ bstrString) {
static Browser findBrowser (int /*long*/ webView) {
if (webView == 0) return null;
- IWebView iwebView = new IWebView(webView);
+ IWebView iwebView = new IWebView (webView);
int /*long*/[] result = new int /*long*/[1];
- int hr = iwebView.hostWindow(result);
+ int hr = iwebView.hostWindow (result);
if (hr == COM.S_OK && result[0] != 0) {
Widget widget = Display.getCurrent ().findWidget (result[0]);
if (widget != null && widget instanceof Browser) return (Browser)widget;
@@ -263,7 +260,7 @@ static Browser findBrowser (int /*long*/ webView) {
}
static int /*long*/ JSObjectCallAsFunctionProc (int /*long*/ ctx, int /*long*/ function, int /*long*/ thisObject, int /*long*/ argumentCount, int /*long*/ arguments, int /*long*/ exception) {
- WebKit_win32.JSGlobalContextRetain(ctx);
+ WebKit_win32.JSGlobalContextRetain (ctx);
if (WebKit_win32.JSValueIsObjectOfClass (ctx, thisObject, ExternalClass) == 0) {
return WebKit_win32.JSValueMakeUndefined (ctx);
}
@@ -285,7 +282,7 @@ static int /*long*/ JSObjectGetPropertyProc (int /*long*/ ctx, int /*long*/ obje
bytes = (FUNCTIONNAME_CALLJAVA + '\0').getBytes ();
}
int /*long*/ name = WebKit_win32.JSStringCreateWithUTF8CString (bytes);
- int /*long*/ addr = WebKit_win32.JSObjectCallAsFunctionProc_CALLBACK(WebKit.JSObjectCallAsFunctionProc.getAddress());
+ int /*long*/ addr = WebKit_win32.JSObjectCallAsFunctionProc_CALLBACK(WebKit.JSObjectCallAsFunctionProc.getAddress ());
int /*long*/ function = WebKit_win32.JSObjectMakeFunctionWithCallback (ctx, name, addr);
WebKit_win32.JSStringRelease (name);
return function;
@@ -302,33 +299,33 @@ static int /*long*/ JSObjectHasPropertyProc (int /*long*/ ctx, int /*long*/ obje
return result;
}
-static char[] stringFromCFString(int /*long*/ cfString) {
+static char[] stringFromCFString (int /*long*/ cfString) {
if (cfString == 0) return null;
- int length = WebKit_win32.CFStringGetLength(cfString);
- int /*long*/ ptr = WebKit_win32.CFStringGetCharactersPtr(cfString);
+ int length = WebKit_win32.CFStringGetLength (cfString);
+ int /*long*/ ptr = WebKit_win32.CFStringGetCharactersPtr (cfString);
char [] string = new char[length];
if (ptr != 0) {
- OS.MoveMemory(string, ptr, C.PTR_SIZEOF);
+ OS.MoveMemory (string, ptr, C.PTR_SIZEOF);
} else {
for (int j = 0; j < length; j++) {
- string[j] = WebKit_win32.CFStringGetCharacterAtIndex(cfString, j);
+ string[j] = WebKit_win32.CFStringGetCharacterAtIndex (cfString, j);
}
}
return string;
}
-static String stringFromJSString(int /*long*/ jsString) {
+static String stringFromJSString (int /*long*/ jsString) {
if (jsString == 0) return null;
- int length = WebKit_win32.JSStringGetLength(jsString);
+ int length = WebKit_win32.JSStringGetLength (jsString);
byte [] string = new byte[length + 1];
- WebKit_win32.JSStringGetUTF8CString(jsString, string, length + 1);
- return new String(string);
+ WebKit_win32.JSStringGetUTF8CString (jsString, string, length + 1);
+ return new String (string);
}
public boolean back () {
int /*long*/[] result = new int /*long*/[1];
- webView.goBack(result);
+ webView.goBack (result);
return result[0] == 0 ? false : true;
}
@@ -385,7 +382,7 @@ Object convertToJava (int /*long*/ ctx, int /*long*/ value) {
}
case WebKit_win32.kJSTypeNumber: {
double result = WebKit_win32.JSValueToNumber (ctx, value, null);
- return new Double(result);
+ return new Double (result);
}
case WebKit_win32.kJSTypeString: {
int /*long*/ string = WebKit_win32.JSValueToStringCopy (ctx, value, null);
@@ -481,101 +478,101 @@ public void create (Composite parent, int style) {
if (ExternalClass == 0) {
JSClassDefinition jsClassDefinition = new JSClassDefinition ();
- byte[] bytes = (CLASSNAME_EXTERNAL + '\0').getBytes();
+ byte[] bytes = (CLASSNAME_EXTERNAL + '\0').getBytes ();
jsClassDefinition.className = C.malloc (bytes.length);
OS.memmove (jsClassDefinition.className, bytes, bytes.length);
//custom callbacks for hasProperty, getProperty and callAsFunction
- int /*long*/ addr = WebKit_win32.JSObjectHasPropertyProc_CALLBACK(JSObjectHasPropertyProc.getAddress());
+ int /*long*/ addr = WebKit_win32.JSObjectHasPropertyProc_CALLBACK (JSObjectHasPropertyProc.getAddress ());
jsClassDefinition.hasProperty = addr;
- addr = WebKit_win32.JSObjectGetPropertyProc_CALLBACK(JSObjectGetPropertyProc.getAddress());
+ addr = WebKit_win32.JSObjectGetPropertyProc_CALLBACK (JSObjectGetPropertyProc.getAddress ());
jsClassDefinition.getProperty = addr;
int /*long*/ classDefinitionPtr = C.malloc (JSClassDefinition.sizeof);
WebKit_win32.memmove (classDefinitionPtr, jsClassDefinition, JSClassDefinition.sizeof);
ExternalClass = WebKit_win32.JSClassCreate (classDefinitionPtr);
- WebKit_win32.JSClassRetain(ExternalClass);
+ WebKit_win32.JSClassRetain (ExternalClass);
}
int /*long*/[] result = new int /*long*/[1];
- int hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebView, 0, WebKit_win32.IID_IWebView, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return;
- }
- webView = new IWebView (result[0]);
- webViewData = C.malloc (C.PTR_SIZEOF);
- C.memmove (webViewData, new int /*long*/[] {webView.getAddress()}, C.PTR_SIZEOF);
- hr = webView.setHostWindow (browser.handle);
- if (hr != COM.S_OK) {
- return;
- }
- hr = webView.initWithFrame (new RECT (), 100, 100);
- if (hr != COM.S_OK) {
- return;
- }
- result[0] = 0;
- hr = webView.QueryInterface (WebKit_win32.IID_IWebViewPrivate, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return;
- }
- IWebViewPrivate webViewPrivate = new IWebViewPrivate (result[0]);
- result[0] = 0;
- hr = webViewPrivate.viewWindow (result);
- if (hr != COM.S_OK || result[0] == 0) {
- return;
- }
- webViewPrivate.Release ();
- webViewWindowHandle = result[0];
-
- result[0] = 0;
- webFrameLoadDelegate = new WebFrameLoadDelegate ();
+ int hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebView, 0, WebKit_win32.IID_IWebView, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return;
+ }
+ webView = new IWebView (result[0]);
+ webViewData = C.malloc (C.PTR_SIZEOF);
+ C.memmove (webViewData, new int /*long*/[] {webView.getAddress()}, C.PTR_SIZEOF);
+ hr = webView.setHostWindow (browser.handle);
+ if (hr != COM.S_OK) {
+ return;
+ }
+ hr = webView.initWithFrame (new RECT (), 100, 100);
+ if (hr != COM.S_OK) {
+ return;
+ }
+ result[0] = 0;
+ hr = webView.QueryInterface (WebKit_win32.IID_IWebViewPrivate, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return;
+ }
+ IWebViewPrivate webViewPrivate = new IWebViewPrivate (result[0]);
+ result[0] = 0;
+ hr = webViewPrivate.viewWindow (result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return;
+ }
+ webViewPrivate.Release ();
+ webViewWindowHandle = result[0];
+
+ result[0] = 0;
+ webFrameLoadDelegate = new WebFrameLoadDelegate ();
hr = webView.setFrameLoadDelegate (webFrameLoadDelegate.getAddress ());
- if (hr != COM.S_OK) {
- return;
- }
- webFrameLoadDelegate.setBrowser(browser);
-
- webUIDelegate = new WebUIDelegate ();
+ if (hr != COM.S_OK) {
+ return;
+ }
+ webFrameLoadDelegate.setBrowser (browser);
+
+ webUIDelegate = new WebUIDelegate ();
hr = webView.setUIDelegate (webUIDelegate.getAddress ());
- if (hr != COM.S_OK) {
- return;
- }
- webUIDelegate.setBrowser(browser);
+ if (hr != COM.S_OK) {
+ return;
+ }
+ webUIDelegate.setBrowser (browser);
- webResourceLoadDelegate = new WebResourceLoadDelegate ();
+ webResourceLoadDelegate = new WebResourceLoadDelegate ();
hr = webView.setResourceLoadDelegate (webResourceLoadDelegate.getAddress ());
- if (hr != COM.S_OK) {
- return;
- }
- webResourceLoadDelegate.setBrowser(browser);
-
- webDownloadDelegate = new WebDownloadDelegate ();
+ if (hr != COM.S_OK) {
+ return;
+ }
+ webResourceLoadDelegate.setBrowser (browser);
+
+ webDownloadDelegate = new WebDownloadDelegate ();
hr = webView.setDownloadDelegate (webDownloadDelegate.getAddress ());
- if (hr != COM.S_OK) {
- return;
- }
- webDownloadDelegate.setBrowser(browser);
-
- webPolicyDelegate = new WebPolicyDelegate ();
- hr = webView.setPolicyDelegate (webPolicyDelegate.getAddress());
- if (hr != COM.S_OK) {
- return;
- }
- webPolicyDelegate.setBrowser(browser);
-
- result[0] = 0;
- webView.preferences(result);
+ if (hr != COM.S_OK) {
+ return;
+ }
+ webDownloadDelegate.setBrowser (browser);
+
+ webPolicyDelegate = new WebPolicyDelegate ();
+ hr = webView.setPolicyDelegate (webPolicyDelegate.getAddress ());
+ if (hr != COM.S_OK) {
+ return;
+ }
+ webPolicyDelegate.setBrowser (browser);
+
+ result[0] = 0;
+ webView.preferences (result);
if (hr == COM.S_OK && result[0] != 0) {
- IWebPreferences preferences = new IWebPreferences(result[0]);
- preferences.setJavaScriptCanOpenWindowsAutomatically(true);
- preferences.setJavaEnabled(false); //disable applets
- preferences.setTabsToLinks(true);
- preferences.setFontSmoothing(WebKit_win32.FontSmoothingTypeWindows);
- preferences.Release();
+ IWebPreferences preferences = new IWebPreferences (result[0]);
+ preferences.setJavaScriptCanOpenWindowsAutomatically (1);
+ preferences.setJavaEnabled (0); //disable applets
+ preferences.setTabsToLinks (0);
+ preferences.setFontSmoothing (WebKit_win32.FontSmoothingTypeWindows);
+ preferences.Release ();
}
- final Listener filter = new Listener() {
- public void handleEvent(Event event) {
+ final Listener filter = new Listener () {
+ public void handleEvent (Event event) {
switch (event.type) {
case SWT.Traverse: {
traverseNext = event.detail != SWT.TRAVERSE_TAB_PREVIOUS;
@@ -584,20 +581,20 @@ public void create (Composite parent, int style) {
}
}
};
- Listener listener = new Listener() {
- public void handleEvent(Event e) {
+ Listener listener = new Listener () {
+ public void handleEvent (Event e) {
switch (e.type) {
case SWT.Activate: {
- browser.getDisplay().removeFilter(SWT.Traverse, filter);
+ browser.getDisplay ().removeFilter (SWT.Traverse, filter);
break;
}
case SWT.Deactivate: {
- browser.getDisplay().removeFilter(SWT.Traverse, filter);
- browser.getDisplay().addFilter(SWT.Traverse, filter);
+ browser.getDisplay ().removeFilter (SWT.Traverse, filter);
+ browser.getDisplay ().addFilter (SWT.Traverse, filter);
break;
}
case SWT.Dispose: {
- browser.getDisplay().removeFilter(SWT.Traverse, filter);
+ browser.getDisplay ().removeFilter (SWT.Traverse, filter);
/* make this handler run after other dispose listeners */
if (ignoreDispose) {
ignoreDispose = false;
@@ -606,19 +603,19 @@ public void create (Composite parent, int style) {
ignoreDispose = true;
browser.notifyListeners (e.type, e);
e.type = SWT.NONE;
- onDispose();
+ onDispose ();
break;
}
case SWT.FocusIn: {
- onFocus();
+ onFocus ();
break;
}
case SWT.Resize: {
- Rectangle bounds = browser.getClientArea();
- OS.SetWindowPos (webViewWindowHandle, 0, bounds.x, bounds.y, bounds.width, bounds.height, OS.SWP_DRAWFRAME);
- //not required, browser.setVisible() takes care of this
- //OS.ShowWindow (webViewWindowHandle, browser.getVisible () ? OS.SW_SHOW : OS.SW_HIDE);
- break;
+ Rectangle bounds = browser.getClientArea ();
+ OS.SetWindowPos (webViewWindowHandle, 0, bounds.x, bounds.y, bounds.width, bounds.height, OS.SWP_DRAWFRAME);
+ //not required, browser.setVisible() takes care of this
+ //OS.ShowWindow (webViewWindowHandle, browser.getVisible () ? OS.SW_SHOW : OS.SW_HIDE);
+ break;
}
case SWT.Traverse: {
if (traverseOut) {
@@ -632,19 +629,19 @@ public void create (Composite parent, int style) {
}
}
};
- browser.addListener(SWT.Dispose, listener);
- browser.addListener(SWT.KeyDown, listener); /* needed for tabbing into the Browser */
- browser.addListener(SWT.FocusIn, listener);
- browser.addListener(SWT.Resize, listener);
- browser.addListener(SWT.Traverse, listener);
- browser.addListener(SWT.Activate, listener);
- browser.addListener(SWT.Deactivate, listener);
- if (!browser.isFocusControl()) {
- browser.getDisplay().addFilter(SWT.Traverse, filter);
+ browser.addListener (SWT.Dispose, listener);
+ browser.addListener (SWT.KeyDown, listener); /* needed for tabbing into the Browser */
+ browser.addListener (SWT.FocusIn, listener);
+ browser.addListener (SWT.Resize, listener);
+ browser.addListener (SWT.Traverse, listener);
+ browser.addListener (SWT.Activate, listener);
+ browser.addListener (SWT.Deactivate, listener);
+ if (!browser.isFocusControl ()) {
+ browser.getDisplay ().addFilter (SWT.Traverse, filter);
}
eventFunction = new BrowserFunction (browser, "HandleWebKitEvent") { //$NON-NLS-1$
- public Object function(Object[] arguments) {
+ public Object function (Object[] arguments) {
return handleEvent (arguments) ? Boolean.TRUE : Boolean.FALSE;
};
};
@@ -652,39 +649,39 @@ public void create (Composite parent, int style) {
public boolean execute (String script) {
int /*long*/[] result = new int /*long*/[1];
- int hr = webView.mainFrame(result);
+ int hr = webView.mainFrame (result);
if (hr != COM.S_OK || result[0] == 0) {
- return false;
- }
- IWebFrame frame = new IWebFrame(result[0]);
- int /*long*/ context = frame.globalContext();
+ return false;
+ }
+ IWebFrame frame = new IWebFrame (result[0]);
+ int /*long*/ context = frame.globalContext ();
if (context == 0) {
- return false;
- }
+ return false;
+ }
byte[] bytes = null;
try {
- bytes = (script + '\0').getBytes("UTF-8"); //$NON-NLS-1$
+ bytes = (script + '\0').getBytes ("UTF-8"); //$NON-NLS-1$
} catch (UnsupportedEncodingException e) {
- bytes = (script + '\0').getBytes();
+ bytes = (script + '\0').getBytes ();
}
- int /*long*/ scriptString = WebKit_win32.JSStringCreateWithUTF8CString(bytes);
+ int /*long*/ scriptString = WebKit_win32.JSStringCreateWithUTF8CString (bytes);
if (scriptString == 0) return false;
try {
- bytes = (getUrl() + '\0').getBytes("UTF-8"); //$NON-NLS-1$
+ bytes = (getUrl () + '\0').getBytes ("UTF-8"); //$NON-NLS-1$
} catch (UnsupportedEncodingException e) {
- bytes = (getUrl() + '\0').getBytes();
+ bytes = (getUrl () + '\0').getBytes ();
}
- int /*long*/ urlString = WebKit_win32.JSStringCreateWithUTF8CString(bytes);
+ int /*long*/ urlString = WebKit_win32.JSStringCreateWithUTF8CString (bytes);
if (urlString == 0) return false;
- WebKit_win32.JSEvaluateScript(context, scriptString, 0, urlString, 0, null);
- WebKit_win32.JSStringRelease(urlString);
- WebKit_win32.JSStringRelease(scriptString);
+ WebKit_win32.JSEvaluateScript (context, scriptString, 0, urlString, 0, null);
+ WebKit_win32.JSStringRelease (urlString);
+ WebKit_win32.JSStringRelease (scriptString);
return hr != COM.S_OK;
}
public boolean forward () {
int /*long*/[] result = new int /*long*/[1];
- webView.goForward(result);
+ webView.goForward (result);
return result[0] != 0;
}
@@ -694,38 +691,38 @@ public String getBrowserType () {
public String getText () {
int /*long*/[] result = new int /*long*/[1];
- int hr = webView.mainFrame(result);
+ int hr = webView.mainFrame (result);
if (hr != COM.S_OK || result[0] == 0) {
- return EMPTY_STRING;
- }
- IWebFrame mainFrame = new IWebFrame(result[0]);
+ return EMPTY_STRING;
+ }
+ IWebFrame mainFrame = new IWebFrame (result[0]);
result[0] = 0;
- hr = mainFrame.dataSource(result);
- mainFrame.Release();
+ hr = mainFrame.dataSource (result);
+ mainFrame.Release ();
if (hr != COM.S_OK || result[0] == 0) {
- return EMPTY_STRING;
- }
- IWebDataSource dataSource = new IWebDataSource(result[0]);
+ return EMPTY_STRING;
+ }
+ IWebDataSource dataSource = new IWebDataSource (result[0]);
result[0] = 0;
- hr = dataSource.representation(result);
- dataSource.Release();
+ hr = dataSource.representation (result);
+ dataSource.Release ();
if (hr != COM.S_OK || result[0] == 0) {
- return EMPTY_STRING;
- }
- IWebDocumentRepresentation representation = new IWebDocumentRepresentation(result[0]);
+ return EMPTY_STRING;
+ }
+ IWebDocumentRepresentation representation = new IWebDocumentRepresentation (result[0]);
result[0] = 0;
- hr = representation.documentSource(result);
- representation.Release();
+ hr = representation.documentSource (result);
+ representation.Release ();
if (hr != COM.S_OK || result[0] == 0) {
- return EMPTY_STRING;
- }
- String source = extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ return EMPTY_STRING;
+ }
+ String source = extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
return source;
}
public String getUrl () {
- return webFrameLoadDelegate.getUrl();
+ return webFrameLoadDelegate.getUrl ();
}
boolean handleEvent (Object[] arguments) {
@@ -968,17 +965,17 @@ boolean handleEvent (Object[] arguments) {
public boolean isBackEnabled () {
int /*long*/[] result = new int /*long*/[1];
- int hr = webView.QueryInterface (WebKit_win32.IID_IWebIBActions, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return false;
- }
- IWebIBActions webIBActions = new IWebIBActions(result[0]);
- webIBActions.canGoBack(webView.getAddress(), result);
- webIBActions.Release();
- return result[0] != 0;
+ int hr = webView.QueryInterface (WebKit_win32.IID_IWebIBActions, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return false;
+ }
+ IWebIBActions webIBActions = new IWebIBActions (result[0]);
+ webIBActions.canGoBack (webView.getAddress (), result);
+ webIBActions.Release ();
+ return result[0] != 0;
}
-public boolean isFocusControl() {
+public boolean isFocusControl () {
int /*long*/ hwndFocus = OS.GetFocus ();
if (hwndFocus != 0 && hwndFocus == webViewWindowHandle) return true;
return false;
@@ -986,43 +983,35 @@ public boolean isFocusControl() {
public boolean isForwardEnabled () {
int /*long*/[] result = new int /*long*/[1];
- int hr = webView.QueryInterface (WebKit_win32.IID_IWebIBActions, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return false;
- }
- IWebIBActions webIBActions = new IWebIBActions(result[0]);
- webIBActions.canGoForward(webView.getAddress(), result);
- webIBActions.Release();
- return result[0] != 0;
+ int hr = webView.QueryInterface (WebKit_win32.IID_IWebIBActions, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return false;
+ }
+ IWebIBActions webIBActions = new IWebIBActions (result[0]);
+ webIBActions.canGoForward (webView.getAddress (), result);
+ webIBActions.Release ();
+ return result[0] != 0;
}
-void onDispose() {
+void onDispose () {
/* Browser could have been disposed by one of the Dispose listeners */
- if (!browser.isDisposed()) {
+ if (!browser.isDisposed ()) {
/* invoke onbeforeunload handlers but don't prompt with message box*/
if (!browser.isClosing) {
webUIDelegate.prompt = false;
- shouldClose();
+ shouldClose ();
webUIDelegate.prompt = true;
}
}
C.free (webViewData);
-// webView.close();
- webView.setHostWindow(0);
-
- webView.setFrameLoadDelegate(0);
- webView.setResourceLoadDelegate(0);
- webView.setUIDelegate(0);
- webView.setPolicyDelegate(0);
- webView.setDownloadDelegate(0);
-
- webView.Release();
-
- webView = null;
webViewWindowHandle = 0;
webFrameLoadDelegate.html = null;
webUIDelegate.lastHoveredLinkURL = lastNavigateURL = null;
+
+ webView.close ();
+ webView.Release ();
+ webView = null;
Enumeration elements = functions.elements ();
while (elements.hasMoreElements ()) {
@@ -1031,28 +1020,29 @@ void onDispose() {
functions = null;
}
-void onFocus() {
+void onFocus () {
+ if (webViewWindowHandle == 0) return;
OS.SetFocus (webViewWindowHandle);
int /*long*/[] result = new int /*long*/[1];
int hr = webView.QueryInterface (WebKit_win32.IID_IWebViewPrivate, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return;
- }
- IWebViewPrivate webViewPrivate = new IWebViewPrivate (result[0]);
- webViewPrivate.setInitialFocus(traverseNext);
- webViewPrivate.Release();
+ if (hr != COM.S_OK || result[0] == 0) {
+ return;
+ }
+ IWebViewPrivate webViewPrivate = new IWebViewPrivate (result[0]);
+ webViewPrivate.setInitialFocus (traverseNext ? 1 : 0);
+ webViewPrivate.Release ();
}
public void refresh () {
webFrameLoadDelegate.html = null;
int /*long*/[] result = new int /*long*/[1];
- int hr = webView.QueryInterface (WebKit_win32.IID_IWebIBActions, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return;
- }
- IWebIBActions webIBActions = new IWebIBActions(result[0]);
- webIBActions.reload(webView.getAddress());
- webIBActions.Release();
+ int hr = webView.QueryInterface (WebKit_win32.IID_IWebIBActions, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return;
+ }
+ IWebIBActions webIBActions = new IWebIBActions (result[0]);
+ webIBActions.reload (webView.getAddress ());
+ webIBActions.Release ();
}
boolean sendKeyEvent (Event event) {
@@ -1107,39 +1097,39 @@ public boolean setText (String html, boolean trusted) {
IWebFrame frame = new IWebFrame (result[0]);
result[0] = 0;
- hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebMutableURLRequest, 0, WebKit_win32.IID_IWebMutableURLRequest, result);
- if (hr != COM.S_OK || result[0] == 0) {
- frame.Release();
- return false;
- }
- IWebMutableURLRequest request = new IWebMutableURLRequest (result[0]);
-
- int /*long*/ urlString = createBSTR (ABOUT_BLANK);
- hr = request.setURL (urlString);
- COM.SysFreeString (urlString);
-
+ hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebMutableURLRequest, 0, WebKit_win32.IID_IWebMutableURLRequest, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ frame.Release ();
+ return false;
+ }
+ IWebMutableURLRequest request = new IWebMutableURLRequest (result[0]);
+
+ int /*long*/ urlString = createBSTR (ABOUT_BLANK);
+ hr = request.setURL (urlString);
+ COM.SysFreeString (urlString);
+
if (hr == COM.S_OK) {
hr = frame.loadRequest (request.getAddress ());
- }
- frame.Release();
- request.Release();
- return hr == COM.S_OK;
+ }
+ frame.Release ();
+ request.Release ();
+ return hr == COM.S_OK;
}
public boolean setUrl (String url, String postData, String[] headers) {
- if (url.length() == 0) return false;
+ if (url.length () == 0) return false;
/*
* WebKit 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);
+ new URL (url);
} catch (MalformedURLException e) {
String testUrl = null;
- if (url.length() > 1 && url.charAt(0) == SEPARATOR_FILE && url.charAt(1) == SEPARATOR_FILE) {
+ if (new File (url).isAbsolute ()) {
/* appears to be a local file */
- testUrl = PROTOCOL_FILE + url.substring(1);
+ testUrl = PROTOCOL_FILE + url;
} else {
testUrl = PROTOCOL_HTTP + url;
}
@@ -1154,27 +1144,27 @@ public boolean setUrl (String url, String postData, String[] headers) {
lastNavigateURL = url;
int /*long*/[] result = new int /*long*/[1];
int hr = webView.mainFrame (result);
- if (hr != COM.S_OK || result[0] == 0) {
- return false;
- }
- IWebFrame frame = new IWebFrame (result[0]);
-
- result[0] = 0;
- hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebMutableURLRequest, 0, WebKit_win32.IID_IWebMutableURLRequest, result);
- if (hr != COM.S_OK || result[0] == 0) {
- frame.Release();
- return false;
- }
- IWebMutableURLRequest request = new IWebMutableURLRequest (result[0]);
-
- if (postData != null) { //TODO: POST
+ if (hr != COM.S_OK || result[0] == 0) {
+ return false;
+ }
+ IWebFrame frame = new IWebFrame (result[0]);
+
+ result[0] = 0;
+ hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebMutableURLRequest, 0, WebKit_win32.IID_IWebMutableURLRequest, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ frame.Release ();
+ return false;
+ }
+ IWebMutableURLRequest request = new IWebMutableURLRequest (result[0]);
+
+ if (postData != null) { //TODO: POST
// webResourceLoadDelegate.postData = postData;
-// int /*long*/ postString = createBSTR(POST);
-// hr = request.setHTTPMethod(postString);
-// COM.SysFreeString(postString);
+// int /*long*/ postString = createBSTR (POST);
+// hr = request.setHTTPMethod (postString);
+// COM.SysFreeString (postString);
//
// result[0] = 0;
-// hr = request.QueryInterface(WebKit_win32.IID_IWebMutableURLRequestPrivate, result);
+// hr = request.QueryInterface (WebKit_win32.IID_IWebMutableURLRequestPrivate, result);
// if (hr == COM.S_OK && result[0] != 0) {
// IWebMutableURLRequestPrivate requestPrivate = new IWebMutableURLRequestPrivate(result[0]);
// int cfRequest = requestPrivate.cfRequest();
@@ -1187,30 +1177,30 @@ public boolean setUrl (String url, String postData, String[] headers) {
// int /*long*/ bytePtr = WebKit_win32.CFDataGetBytePtr(dataGet);
// }
}
- hr = COM.S_OK; //TODO: once post code is completed, remove this line if not required
+ hr = COM.S_OK; //TODO: once post code is completed, remove this line if not required
if (headers != null) {
for (int i = 0; i < headers.length; i++) {
String current = headers[i];
if (current != null) {
- int index = current.indexOf(':');
+ 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) {
- int /*long*/ valueString = createBSTR(value);
- if (key.equalsIgnoreCase(USER_AGENT)) {
+ String key = current.substring (0, index).trim ();
+ String value = current.substring (index + 1).trim ();
+ if (key.length () > 0 && value.length () > 0) {
+ int /*long*/ valueString = createBSTR (value);
+ if (key.equalsIgnoreCase (USER_AGENT)) {
/*
* Feature of WebKit. The user-agent header value cannot be overridden
* here. The workaround is to temporarily set the value on the WebView
* and then remove it after the loading of the request has begun.
*/
- hr = webView.setCustomUserAgent(valueString);
+ hr = webView.setCustomUserAgent (valueString);
} else {
- int /*long*/ keyString = createBSTR(key);
- hr = request.setValue(valueString, keyString);
- COM.SysFreeString(keyString);
+ int /*long*/ keyString = createBSTR (key);
+ hr = request.setValue (valueString, keyString);
+ COM.SysFreeString (keyString);
}
- COM.SysFreeString(valueString);
+ COM.SysFreeString (valueString);
}
}
}
@@ -1223,10 +1213,10 @@ public boolean setUrl (String url, String postData, String[] headers) {
if (hr == COM.S_OK) {
hr = frame.loadRequest (request.getAddress ());
}
- webView.setCustomUserAgent(0);
+ webView.setCustomUserAgent (0);
}
- frame.Release();
- request.Release();
+ frame.Release ();
+ request.Release ();
return hr == COM.S_OK;
}
@@ -1235,26 +1225,26 @@ boolean shouldClose () {
int /*long*/[] result = new int /*long*/[1];
int hr = webView.QueryInterface (WebKit_win32.IID_IWebViewPrivate, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return false;
- }
- IWebViewPrivate webViewPrivate = new IWebViewPrivate (result[0]);
- result[0] = 0;
- //This function will fire the before unload handler for a page
- webViewPrivate.shouldClose(result);
- webViewPrivate.Release();
- return result[0] != 0;
+ if (hr != COM.S_OK || result[0] == 0) {
+ return false;
+ }
+ IWebViewPrivate webViewPrivate = new IWebViewPrivate (result[0]);
+ result[0] = 0;
+ //This function will fire the before unload handler for a page
+ webViewPrivate.shouldClose (result);
+ webViewPrivate.Release ();
+ return result[0] != 0;
}
public void stop () {
webFrameLoadDelegate.html = null;
int /*long*/[] result = new int /*long*/[1];
- int hr = webView.QueryInterface (WebKit_win32.IID_IWebIBActions, result);
- if (hr != COM.S_OK || result[0] == 0) {
- return;
- }
- IWebIBActions webIBActions = new IWebIBActions(result[0]);
- webIBActions.stopLoading(webView.getAddress());
- webIBActions.Release();
+ int hr = webView.QueryInterface (WebKit_win32.IID_IWebIBActions, result);
+ if (hr != COM.S_OK || result[0] == 0) {
+ return;
+ }
+ IWebIBActions webIBActions = new IWebIBActions (result[0]);
+ webIBActions.stopLoading (webView.getAddress ());
+ webIBActions.Release ();
}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebPolicyDelegate.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebPolicyDelegate.java
index 346a2d1be5..ce7483fed0 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebPolicyDelegate.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebPolicyDelegate.java
@@ -23,11 +23,11 @@ class WebPolicyDelegate {
Browser browser;
-WebPolicyDelegate() {
- createCOMInterfaces();
+WebPolicyDelegate () {
+ createCOMInterfaces ();
}
-int AddRef() {
+int AddRef () {
refCount++;
return refCount;
}
@@ -40,51 +40,51 @@ void createCOMInterfaces () {
public int /*long*/ method3 (int /*long*/[] args) {return decidePolicyForNavigationAction (args[0], args[1], args[2], args[3], args[4]);}
public int /*long*/ method4 (int /*long*/[] args) {return decidePolicyForNewWindowAction (args[0], args[1], args[2], args[3], args[4]);}
public int /*long*/ method5 (int /*long*/[] args) {return decidePolicyForMIMEType (args[0], args[1], args[2], args[3], args[4]);}
- public int /*long*/ method6 (int /*long*/[] args) {return unableToImplementPolicyWithError(args[0], args[1], args[2]);}
+ public int /*long*/ method6 (int /*long*/[] args) {return unableToImplementPolicyWithError (args[0], args[1], args[2]);}
};
}
-int decidePolicyForMIMEType(int /*long*/ webView, int /*long*/ type, int /*long*/ request, int /*long*/ frame,
+int decidePolicyForMIMEType (int /*long*/ webView, int /*long*/ type, int /*long*/ request, int /*long*/ frame,
int /*long*/ listener) {
- IWebView iwebView = new IWebView(webView);
+ IWebView iwebView = new IWebView (webView);
int /*long*/[] canShow = new int /*long*/[1];
- iwebView.canShowMIMEType(type, canShow);
- IWebPolicyDecisionListener pdListener = new IWebPolicyDecisionListener(listener);
+ iwebView.canShowMIMEType (type, canShow);
+ IWebPolicyDecisionListener pdListener = new IWebPolicyDecisionListener (listener);
if (canShow[0] != 0) {
- pdListener.use();
+ pdListener.use ();
} else {
- pdListener.download();
+ pdListener.download ();
}
return COM.S_OK;
}
-int decidePolicyForNavigationAction(int /*long*/ webView, int /*long*/ actionInformation, int /*long*/ request, int /*long*/ frame,
+int decidePolicyForNavigationAction (int /*long*/ webView, int /*long*/ actionInformation, int /*long*/ request, int /*long*/ frame,
int /*long*/ listener) {
- IWebURLRequest iwebUrlRequest = new IWebURLRequest(request);
+ IWebURLRequest iwebUrlRequest = new IWebURLRequest (request);
int /*long*/[] result = new int /*long*/ [1];
- int hr = iwebUrlRequest.URL(result);
+ int hr = iwebUrlRequest.URL (result);
if (hr != COM.S_OK || result[0] == 0) {
- return COM.S_OK;
- }
- String url = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
- IWebPolicyDecisionListener pdListener = new IWebPolicyDecisionListener(listener);
+ return COM.S_OK;
+ }
+ String url = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
+ IWebPolicyDecisionListener pdListener = new IWebPolicyDecisionListener (listener);
if (((WebKit)browser.webBrowser).loadingText) {
/*
* WebKit is auto-navigating to about:blank in response to a loadHTMLString()
* invocation. This navigate should always proceed without sending an event
* since it is preceded by an explicit navigate to about:blank in setText().
*/
- pdListener.use();
+ pdListener.use ();
return COM.S_OK;
}
- if (url.length() == 0) {
- pdListener.ignore();
+ if (url.length () == 0) {
+ pdListener.ignore ();
return COM.S_OK;
}
- if (url.startsWith("file://") && browser.webBrowser.getUrl().startsWith(WebKit.ABOUT_BLANK) && ((WebKit)browser.webBrowser).untrustedText) {
+ if (url.startsWith ("file://") && browser.webBrowser.getUrl ().startsWith (WebKit.ABOUT_BLANK) && ((WebKit)browser.webBrowser).untrustedText) {
/* indicates an attempt to access the local file system from untrusted content */
- pdListener.ignore();
+ pdListener.ignore ();
return COM.S_OK;
}
/*
@@ -99,41 +99,41 @@ int decidePolicyForNavigationAction(int /*long*/ webView, int /*long*/ actionInf
url = WebKit.ABOUT_BLANK + url.substring (length);
}
}
- LocationEvent newEvent = new LocationEvent(browser);
- newEvent.display = browser.getDisplay();
+ LocationEvent newEvent = new LocationEvent (browser);
+ newEvent.display = browser.getDisplay ();
newEvent.widget = browser;
newEvent.location = url;
newEvent.doit = true;
LocationListener[] locationListeners = browser.webBrowser.locationListeners;
if (locationListeners != null) {
for (int i = 0; i < locationListeners.length; i++) {
- locationListeners[i].changing(newEvent);
+ locationListeners[i].changing (newEvent);
}
}
if (newEvent.doit) {
if (browser.webBrowser.jsEnabledChanged) {
browser.webBrowser.jsEnabledChanged = false;
- IWebView view = new IWebView(webView);
+ IWebView view = new IWebView (webView);
result[0] = 0;
- hr = view.preferences(result);
+ hr = view.preferences (result);
if (hr == COM.S_OK && result[0] != 0) {
- IWebPreferences preferences = new IWebPreferences(result[0]);
- hr = preferences.setJavaScriptEnabled(browser.webBrowser.jsEnabled);
- view.setPreferences(preferences.getAddress());
- preferences.Release();
+ IWebPreferences preferences = new IWebPreferences (result[0]);
+ hr = preferences.setJavaScriptEnabled (browser.webBrowser.jsEnabled ? 1 : 0);
+ view.setPreferences (preferences.getAddress());
+ preferences.Release ();
}
}
- pdListener.use();
+ pdListener.use ();
((WebKit)browser.webBrowser).lastNavigateURL = url;
} else {
- pdListener.ignore();
+ pdListener.ignore ();
}
return COM.S_OK;
}
-int decidePolicyForNewWindowAction(int /*long*/ webView, int /*long*/ actionInformation, int /*long*/ request, int /*long*/ frameName,
+int decidePolicyForNewWindowAction (int /*long*/ webView, int /*long*/ actionInformation, int /*long*/ request, int /*long*/ frameName,
int /*long*/ listener) {
- IWebPolicyDecisionListener pdListener = new IWebPolicyDecisionListener(listener);
+ IWebPolicyDecisionListener pdListener = new IWebPolicyDecisionListener (listener);
pdListener.use();
return COM.S_OK;
}
@@ -181,28 +181,28 @@ void setBrowser (Browser browser) {
this.browser = browser;
}
-int unableToImplementPolicyWithError(int /*long*/ webView, int /*long*/ error, int /*long*/ frame) {
- IWebError iweberror = new IWebError(error);
+int unableToImplementPolicyWithError (int /*long*/ webView, int /*long*/ error, int /*long*/ frame) {
+ IWebError iweberror = new IWebError (error);
String failingURL = null;
int /*long*/[] result = new int /*long*/[1];
int hr = iweberror.failingURL (result);
if (hr == COM.S_OK && result[0] != 0) {
- failingURL = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ failingURL = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
}
result[0] = 0;
- hr = iweberror.localizedDescription(result);
+ hr = iweberror.localizedDescription (result);
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
}
- String description = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
- if (!browser.isDisposed() && description != null) {
+ String description = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
+ if (!browser.isDisposed () && description != null) {
String message = failingURL != null ? failingURL + "\n\n" : ""; //$NON-NLS-1$ //$NON-NLS-2$
message += Compatibility.getMessage ("SWT_Page_Load_Failed", new Object[] {description}); //$NON-NLS-1$
- MessageBox messageBox = new MessageBox(browser.getShell(), SWT.OK | SWT.ICON_ERROR);
- messageBox.setMessage(message);
- messageBox.open();
+ MessageBox messageBox = new MessageBox (browser.getShell (), SWT.OK | SWT.ICON_ERROR);
+ messageBox.setMessage (message);
+ messageBox.open ();
}
return COM.S_OK;
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebResourceLoadDelegate.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebResourceLoadDelegate.java
index 234eff1280..b93c2ca94d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebResourceLoadDelegate.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebResourceLoadDelegate.java
@@ -25,11 +25,11 @@ class WebResourceLoadDelegate {
Browser browser;
String postData;
-WebResourceLoadDelegate() {
- createCOMInterfaces();
+WebResourceLoadDelegate () {
+ createCOMInterfaces ();
}
-int AddRef() {
+int AddRef () {
refCount++;
return refCount;
}
@@ -51,8 +51,8 @@ void createCOMInterfaces () {
};
}
-int didReceiveAuthenticationChallenge(int /*long*/ webView, int /*long*/ identifier, int /*long*/ challenge, int /*long*/ dataSource) {
- IWebURLAuthenticationChallenge iweburlChallenge = new IWebURLAuthenticationChallenge(challenge);
+int didReceiveAuthenticationChallenge (int /*long*/ webView, int /*long*/ identifier, int /*long*/ challenge, int /*long*/ dataSource) {
+ IWebURLAuthenticationChallenge iweburlChallenge = new IWebURLAuthenticationChallenge (challenge);
/*
* Do not invoke the listeners if this challenge has been failed too many
* times because a listener is likely giving incorrect credentials repeatedly
@@ -61,8 +61,8 @@ int didReceiveAuthenticationChallenge(int /*long*/ webView, int /*long*/ identif
int /*long*/ [] result = new int /*long*/ [1];
int hr = iweburlChallenge.previousFailureCount (result);
if (hr != COM.S_OK) {
- return COM.S_OK;
- }
+ return COM.S_OK;
+ }
if (result[0] < 3) {
AuthenticationListener[] authenticationListeners = browser.webBrowser.authenticationListeners;
for (int i = 0; i < authenticationListeners.length; i++) {
@@ -74,10 +74,10 @@ int didReceiveAuthenticationChallenge(int /*long*/ webView, int /*long*/ identif
hr = iweburlChallenge.sender (result);
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
- }
- IWebURLAuthenticationChallengeSender challengeSender = new IWebURLAuthenticationChallengeSender(result[0]);
- challengeSender.cancelAuthenticationChallenge(challenge);
- challengeSender.Release();
+ }
+ IWebURLAuthenticationChallengeSender challengeSender = new IWebURLAuthenticationChallengeSender (result[0]);
+ challengeSender.cancelAuthenticationChallenge (challenge);
+ challengeSender.Release ();
return COM.S_OK;
}
if (event.user != null && event.password != null) {
@@ -85,19 +85,19 @@ int didReceiveAuthenticationChallenge(int /*long*/ webView, int /*long*/ identif
hr = iweburlChallenge.sender (result);
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
- }
- IWebURLAuthenticationChallengeSender challengeSender = new IWebURLAuthenticationChallengeSender(result[0]);
+ }
+ IWebURLAuthenticationChallengeSender challengeSender = new IWebURLAuthenticationChallengeSender (result[0]);
result[0] = 0;
- hr = WebKit_win32.WebKitCreateInstance(WebKit_win32.CLSID_IWebURLCredential, 0, WebKit_win32.IID_IWebURLCredential, result);
+ hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebURLCredential, 0, WebKit_win32.IID_IWebURLCredential, result);
if (hr == COM.S_OK && result[0] != 0) {
- IWebURLCredential credential = new IWebURLCredential(result[0]);
- int /*long*/ user = WebKit.createBSTR(event.user);
- int /*long*/ password = WebKit.createBSTR(event.password);
- credential.initWithUser(user, password, WebKit_win32.WebURLCredentialPersistenceForSession);
- challengeSender.useCredential(result[0], challenge);
- credential.Release();
- }
- challengeSender.Release();
+ IWebURLCredential credential = new IWebURLCredential (result[0]);
+ int /*long*/ user = WebKit.createBSTR (event.user);
+ int /*long*/ password = WebKit.createBSTR (event.password);
+ credential.initWithUser (user, password, WebKit_win32.WebURLCredentialPersistenceForSession);
+ challengeSender.useCredential (result[0], challenge);
+ credential.Release ();
+ }
+ challengeSender.Release ();
return COM.S_OK;
}
}
@@ -112,44 +112,44 @@ int didReceiveAuthenticationChallenge(int /*long*/ webView, int /*long*/ identif
result[0] = 0;
hr = proposedCredential.user (result);
if (hr == COM.S_OK && result[0] != 0) {
- userReturn[0] = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ userReturn[0] = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
result[0] = 0;
hr = proposedCredential.hasPassword (result);
if (hr == COM.S_OK && result[0] != 0) {
result[0] = 0;
hr = proposedCredential.password (result);
if (hr == COM.S_OK && result[0] != 0) {
- passwordReturn[0] = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ passwordReturn[0] = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
}
}
}
- proposedCredential.Release();
+ proposedCredential.Release ();
}
result[0] = 0;
hr = iweburlChallenge.protectionSpace (result);
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
}
- IWebURLProtectionSpace space = new IWebURLProtectionSpace(result[0]);
+ IWebURLProtectionSpace space = new IWebURLProtectionSpace (result[0]);
String host = null, realm = null;
result[0] = 0;
- hr = space.isProxy(result);
+ hr = space.isProxy (result);
hr = space.host (result);
if (hr == COM.S_OK && result[0] != 0) {
- host = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ host = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
result[0] = 0;
hr = space.port (result);
if (hr == COM.S_OK) {
host += ":" + result[0];
result[0] = 0;
hr = space.realm (result);
- space.Release();
+ space.Release ();
if (hr == COM.S_OK && result[0] != 0) {
- realm = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ realm = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
}
}
}
@@ -160,23 +160,23 @@ int didReceiveAuthenticationChallenge(int /*long*/ webView, int /*long*/ identif
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
}
- IWebURLAuthenticationChallengeSender challengeSender = new IWebURLAuthenticationChallengeSender(result[0]);
+ IWebURLAuthenticationChallengeSender challengeSender = new IWebURLAuthenticationChallengeSender (result[0]);
if (!response) {
- challengeSender.cancelAuthenticationChallenge(challenge);
- challengeSender.Release();
+ challengeSender.cancelAuthenticationChallenge (challenge);
+ challengeSender.Release ();
return COM.S_OK;
}
result[0] = 0;
- hr = WebKit_win32.WebKitCreateInstance(WebKit_win32.CLSID_IWebURLCredential, 0, WebKit_win32.IID_IWebURLCredential, result);
+ hr = WebKit_win32.WebKitCreateInstance (WebKit_win32.CLSID_WebURLCredential, 0, WebKit_win32.IID_IWebURLCredential, result);
if (hr == COM.S_OK && result[0] != 0) {
- IWebURLCredential credential = new IWebURLCredential(result[0]);
- int /*long*/ user = WebKit.createBSTR(userReturn[0]);
- int /*long*/ password = WebKit.createBSTR(passwordReturn[0]);
- credential.initWithUser(user, password, WebKit_win32.WebURLCredentialPersistenceForSession);
- challengeSender.useCredential(result[0], challenge);
- credential.Release();
+ IWebURLCredential credential = new IWebURLCredential (result[0]);
+ int /*long*/ user = WebKit.createBSTR (userReturn[0]);
+ int /*long*/ password = WebKit.createBSTR (passwordReturn[0]);
+ credential.initWithUser (user, password, WebKit_win32.WebURLCredentialPersistenceForSession);
+ challengeSender.useCredential (result[0], challenge);
+ credential.Release ();
}
- challengeSender.Release();
+ challengeSender.Release ();
return COM.S_OK;
}
@@ -191,39 +191,39 @@ int /*long*/ getAddress () {
return iWebResourceLoadDelegate.getAddress ();
}
-int identifierForInitialRequest(int /*long*/ webView, int /*long*/ request, int /*long*/ dataSource, int /*long*/ identifier) {
- if (browser.isDisposed()) return COM.S_OK;
+int identifierForInitialRequest (int /*long*/ webView, int /*long*/ request, int /*long*/ dataSource, int /*long*/ identifier) {
+ if (browser.isDisposed ()) return COM.S_OK;
- IWebDataSource source = new IWebDataSource(dataSource);
+ IWebDataSource source = new IWebDataSource (dataSource);
int /*long*/[] frame = new int /*long*/[1];
- int hr = source.webFrame(frame);
+ int hr = source.webFrame (frame);
if (hr != COM.S_OK || frame[0] == 0) {
return COM.S_OK;
}
- new IWebFrame(frame[0]).Release();
+ new IWebFrame (frame[0]).Release ();
int /*long*/[] mainFrame = new int /*long*/[1];
- IWebView iWebView = new IWebView(webView);
- hr = iWebView.mainFrame(mainFrame);
+ IWebView iWebView = new IWebView (webView);
+ hr = iWebView.mainFrame (mainFrame);
if (hr != COM.S_OK || mainFrame[0] == 0) {
return COM.S_OK;
}
- new IWebFrame(mainFrame[0]).Release();
+ new IWebFrame (mainFrame[0]).Release ();
if (frame[0] == mainFrame[0]) {
- int /*long*/ progress = OS.malloc(C.PTR_SIZEOF);
- iWebView.estimatedProgress(progress);
+ int /*long*/ progress = OS.malloc (8);
+ iWebView.estimatedProgress (progress);
double [] estimate = new double[1];
- OS.MoveMemory(estimate, progress, 8);
- OS.free(progress);
+ OS.MoveMemory (estimate, progress, 8);
+ OS.free (progress);
progress = (int) (estimate[0] * 100);
- ProgressEvent progressEvent = new ProgressEvent(browser);
- progressEvent.display = browser.getDisplay();
+ ProgressEvent progressEvent = new ProgressEvent (browser);
+ progressEvent.display = browser.getDisplay ();
progressEvent.widget = browser;
progressEvent.current = (int)(progress);
- progressEvent.total = Math.max((int)progress, WebKit.MAX_PROGRESS);
+ progressEvent.total = Math.max ((int)progress, WebKit.MAX_PROGRESS);
ProgressListener[] progressListeners = browser.webBrowser.progressListeners;
for (int i = 0; i < progressListeners.length; i++) {
- progressListeners[i].changed(progressEvent);
+ progressListeners[i].changed (progressEvent);
}
}
return COM.S_OK;
@@ -301,12 +301,12 @@ boolean showAuthenticationDialog (final String[] user, final String[] password,
final boolean[] result = new boolean[1];
final Button[] buttons = new Button[2];
- Listener listener = new Listener() {
- public void handleEvent(Event event) {
- user[0] = userText.getText();
- password[0] = passwordText.getText();
+ Listener listener = new Listener () {
+ public void handleEvent (Event event) {
+ user[0] = userText.getText ();
+ password[0] = passwordText.getText ();
result[0] = event.widget == buttons[1];
- shell.close();
+ shell.close ();
}
};
@@ -326,12 +326,12 @@ boolean showAuthenticationDialog (final String[] user, final String[] password,
shell.setDefaultButton (buttons[1]);
shell.pack ();
- Rectangle parentSize = parent.getBounds();
- Rectangle shellSize = shell.getBounds();
+ Rectangle parentSize = parent.getBounds ();
+ Rectangle shellSize = shell.getBounds ();
int x, y;
x = parent.getLocation().x + (parentSize.width - shellSize.width)/2;
y = parent.getLocation().y + (parentSize.height - shellSize.height)/2;
- shell.setLocation(x, y);
+ shell.setLocation (x, y);
shell.open ();
Display display = browser.getDisplay ();
while (!shell.isDisposed ()) {
@@ -341,34 +341,35 @@ boolean showAuthenticationDialog (final String[] user, final String[] password,
return result[0];
}
-int willSendRequest(int /*long*/ webView, int /*long*/ identifier, int /*long*/ request, int /*long*/ redirectResponse, int /*long*/ dataSource, int /*long*/ newRequest) {
- IWebURLRequest req = new IWebURLRequest(request);
+int willSendRequest (int /*long*/ webView, int /*long*/ identifier, int /*long*/ request, int /*long*/ redirectResponse, int /*long*/ dataSource, int /*long*/ newRequest) {
+ IWebURLRequest req = new IWebURLRequest (request);
int /*long*/[] result = new int /*long*/ [1];
- int hr = req.URL(result);
+ int hr = req.URL (result);
if (hr == COM.S_OK && result[0] != 0) {
- String url = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ String url = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
/*
* file://c|/ doesn't work on Webkit but works on other browsers.
* So change file:// to file:/// to be consistent
*/
- if (url.startsWith(WebKit.PROTOCOL_FILE) && !url.startsWith(WebKit.URI_FILEROOT)) {
+ if (url.startsWith (WebKit.PROTOCOL_FILE) && !url.startsWith (WebKit.URI_FILEROOT)) {
int length = WebKit.PROTOCOL_FILE.length ();
- url = WebKit.URI_FILEROOT + url.substring(length);
+ url = WebKit.URI_FILEROOT + url.substring (length);
result[0] = 0;
- hr = req.mutableCopy(result);
+ hr = req.mutableCopy (result);
if (hr == COM.S_OK && result[0] != 0) {
- IWebMutableURLRequest mReq = new IWebMutableURLRequest(result[0]);
+ IWebMutableURLRequest mReq = new IWebMutableURLRequest (result[0]);
int /*long*/ urlString = WebKit.createBSTR (url);
- mReq.setURL(urlString);
- OS.MoveMemory (newRequest, new int /*long*/[] {mReq.getAddress()}, C.PTR_SIZEOF);
+ mReq.setURL (urlString);
+ OS.MoveMemory (newRequest, new int /*long*/[] {mReq.getAddress ()}, C.PTR_SIZEOF);
return COM.S_OK;
}
}
- }
+ }
req.AddRef ();
OS.MoveMemory (newRequest, new int /*long*/[] {request}, C.PTR_SIZEOF);
return COM.S_OK;
}
+
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebUIDelegate.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebUIDelegate.java
index bdfd08325b..2d0fc1dfb2 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebUIDelegate.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/browser/WebUIDelegate.java
@@ -39,66 +39,66 @@ int AddRef () {
return refCount;
}
-int canTakeFocus(int /*long*/ sender, int /*long*/ forward, int /*long*/ result) {
+int canTakeFocus (int /*long*/ sender, int /*long*/ forward, int /*long*/ result) {
int [] response = new int[1];
response[0] = 1;
- OS.MoveMemory(result, response, C.PTR_SIZEOF);
+ OS.MoveMemory (result, response, C.PTR_SIZEOF);
return COM.S_OK;
}
-int contextMenuItemsForElement(int /*long*/ sender, int /*long*/ element, int /*long*/ defaultItemsHMenu, int /*long*/ resultHMenu) {
- Point pt = browser.getDisplay().getCursorLocation();
- Event event = new Event();
+int contextMenuItemsForElement (int /*long*/ sender, int /*long*/ element, int /*long*/ defaultItemsHMenu, int /*long*/ resultHMenu) {
+ Point pt = browser.getDisplay ().getCursorLocation ();
+ Event event = new Event ();
event.x = pt.x;
event.y = pt.y;
- browser.notifyListeners(SWT.MenuDetect, event);
- Menu menu = browser.getMenu();
+ browser.notifyListeners (SWT.MenuDetect, event);
+ Menu menu = browser.getMenu ();
if (event.doit) {
- if (menu != null && !menu.isDisposed()) {
+ if (menu != null && !menu.isDisposed ()) {
if (event.x != pt.x || event.y != pt.y) {
- menu.setLocation(event.x, event.y);
+ menu.setLocation (event.x, event.y);
}
- menu.setVisible(true);
+ menu.setVisible (true);
} else {
- OS.MoveMemory(resultHMenu, new long[] {defaultItemsHMenu}, C.PTR_SIZEOF);
+ OS.MoveMemory (resultHMenu, new long[] {defaultItemsHMenu}, C.PTR_SIZEOF);
return COM.S_OK;
}
}
- OS.MoveMemory(resultHMenu, new /*long*/ int []{0}, C.PTR_SIZEOF);
+ OS.MoveMemory (resultHMenu, new /*long*/ int []{0}, C.PTR_SIZEOF);
return COM.S_OK;
}
void createCOMInterfaces () {
iWebUIDelegate = new COMObject (new int[] {2, 0, 0, 3, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 4, 4, 2, 3, 4, 4, 3, 3, 3, 3, 5, 3, 1, 3, 2, 2, 2, 2, 3, 2, 3, 1, 1, 0, 0, 1, 1, 2, 2, 2, 2, 3, 5, 2, 2, 3, 1, 2, 2, 4, 10, 3}) {
- public int /*long*/ method0 (int /*long*/[] args) {return QueryInterface(args[0], args[1]);}
- public int /*long*/ method1 (int /*long*/[] args) {return AddRef();}
- public int /*long*/ method2 (int /*long*/[] args) {return Release();}
+ public int /*long*/ method0 (int /*long*/[] args) {return QueryInterface (args[0], args[1]);}
+ public int /*long*/ method1 (int /*long*/[] args) {return AddRef ();}
+ public int /*long*/ method2 (int /*long*/[] args) {return Release ();}
public int /*long*/ method3 (int /*long*/[] args) {return createWebViewWithRequest (args[0], args[1], args[2]);}
- public int /*long*/ method4 (int /*long*/[] args) {return webViewShow(args[0]);}
+ public int /*long*/ method4 (int /*long*/[] args) {return webViewShow (args[0]);}
public int /*long*/ method5 (int /*long*/[] args) {return webViewClose (args[0]);}
public int /*long*/ method6 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method7 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method8 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method9 (int /*long*/[] args) {return COM.E_NOTIMPL;}
- public int /*long*/ method10 (int /*long*/[] args) {return setStatusText(args[0], args[1]);}
+ public int /*long*/ method10 (int /*long*/[] args) {return setStatusText (args[0], args[1]);}
public int /*long*/ method11 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method12 (int /*long*/[] args) {return COM.E_NOTIMPL;}
- public int /*long*/ method13 (int /*long*/[] args) {return setToolbarsVisible(args[0], args[1]);}
+ public int /*long*/ method13 (int /*long*/[] args) {return setToolbarsVisible (args[0], args[1]);}
public int /*long*/ method14 (int /*long*/[] args) {return COM.E_NOTIMPL;}
- public int /*long*/ method15 (int /*long*/[] args) {return setStatusBarVisible(args[0], args[1]);}
+ public int /*long*/ method15 (int /*long*/[] args) {return setStatusBarVisible (args[0], args[1]);}
public int /*long*/ method16 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method17 (int /*long*/[] args) {return COM.E_NOTIMPL;}
- public int /*long*/ method18 (int /*long*/[] args) {return setFrame(args[0], args[1]);}
+ public int /*long*/ method18 (int /*long*/[] args) {return setFrame (args[0], args[1]);}
public int /*long*/ method19 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method20 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method21 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method22 (int /*long*/[] args) {return runJavaScriptAlertPanelWithMessage (args[0], args[1]);}
- public int /*long*/ method23 (int /*long*/[] args) {return runJavaScriptConfirmPanelWithMessage(args[0], args[1], args[2]);}
- public int /*long*/ method24 (int /*long*/[] args) {return runJavaScriptTextInputPanelWithPrompt(args[0], args[1], args[2], args[3]);}
- public int /*long*/ method25 (int /*long*/[] args) {return runBeforeUnloadConfirmPanelWithMessage(args[0], args[1], args[2], args[3]);}
- public int /*long*/ method26 (int /*long*/[] args) {return runOpenPanelForFileButtonWithResultListener(args[0], args[1]);}
- public int /*long*/ method27 (int /*long*/[] args) {return mouseDidMoveOverElement(args[0], args[1], args[2]);}
- public int /*long*/ method28 (int /*long*/[] args) {return contextMenuItemsForElement(args[0], args[1], args[2], args[3]);}
+ public int /*long*/ method23 (int /*long*/[] args) {return runJavaScriptConfirmPanelWithMessage (args[0], args[1], args[2]);}
+ public int /*long*/ method24 (int /*long*/[] args) {return runJavaScriptTextInputPanelWithPrompt (args[0], args[1], args[2], args[3]);}
+ public int /*long*/ method25 (int /*long*/[] args) {return runBeforeUnloadConfirmPanelWithMessage (args[0], args[1], args[2], args[3]);}
+ public int /*long*/ method26 (int /*long*/[] args) {return runOpenPanelForFileButtonWithResultListener (args[0], args[1]);}
+ public int /*long*/ method27 (int /*long*/[] args) {return mouseDidMoveOverElement (args[0], args[1], args[2]);}
+ public int /*long*/ method28 (int /*long*/[] args) {return contextMenuItemsForElement (args[0], args[1], args[2], args[3]);}
public int /*long*/ method29 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method30 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method31 (int /*long*/[] args) {return COM.E_NOTIMPL;}
@@ -112,8 +112,8 @@ void createCOMInterfaces () {
public int /*long*/ method39 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method40 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method41 (int /*long*/[] args) {return COM.E_NOTIMPL;}
- public int /*long*/ method42 (int /*long*/[] args) {return canTakeFocus(args[0], args[1], args[2]);}
- public int /*long*/ method43 (int /*long*/[] args) {return takeFocus(args[0], args[1]);}
+ public int /*long*/ method42 (int /*long*/[] args) {return canTakeFocus (args[0], args[1], args[2]);}
+ public int /*long*/ method43 (int /*long*/[] args) {return takeFocus (args[0], args[1]);}
public int /*long*/ method44 (int /*long*/[] args) {return COM.E_NOTIMPL;}
public int /*long*/ method45 (int /*long*/[] args) {return COM.S_OK;}
public int /*long*/ method46 (int /*long*/[] args) {return COM.E_NOTIMPL;}
@@ -139,15 +139,15 @@ void createCOMInterfaces () {
};
}
-int createWebViewWithRequest(int /*long*/ sender, int /*long*/ request, int /*long*/ webView) {
- WindowEvent newEvent = new WindowEvent(browser);
- newEvent.display = browser.getDisplay();
+int createWebViewWithRequest (int /*long*/ sender, int /*long*/ request, int /*long*/ webView) {
+ WindowEvent newEvent = new WindowEvent (browser);
+ newEvent.display = browser.getDisplay ();
newEvent.widget = browser;
newEvent.required = true;
OpenWindowListener[] openWindowListeners = browser.webBrowser.openWindowListeners;
if (openWindowListeners != null) {
for (int i = 0; i < openWindowListeners.length; i++) {
- openWindowListeners[i].open(newEvent);
+ openWindowListeners[i].open (newEvent);
}
}
IWebView iwebview = null;
@@ -155,27 +155,27 @@ int createWebViewWithRequest(int /*long*/ sender, int /*long*/ request, int /*lo
if (newEvent.browser != null && newEvent.browser.webBrowser instanceof WebKit) {
browser = newEvent.browser;
}
- if (browser != null && !browser.isDisposed()) {
+ if (browser != null && !browser.isDisposed ()) {
iwebview = ((WebKit)browser.webBrowser).webView;
- OS.MoveMemory(webView, new int /*long*/[] {iwebview.getAddress ()}, OS.PTR_SIZEOF);
+ OS.MoveMemory (webView, new int /*long*/[] {iwebview.getAddress ()}, OS.PTR_SIZEOF);
if (request != 0) {
- IWebURLRequest req = new IWebURLRequest(request);
+ IWebURLRequest req = new IWebURLRequest (request);
int /*long*/[] result = new int /*long*/[1];
- int hr = req.URL(result);
+ int hr = req.URL (result);
if (hr != COM.S_OK || result[0] == 0) {
- return COM.S_OK;
- }
- String sUrl = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
- if (sUrl.length() != 0) {
+ return COM.S_OK;
+ }
+ String sUrl = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
+ if (sUrl.length () != 0) {
result[0] = 0;
- hr = iwebview.mainFrame(result);
+ hr = iwebview.mainFrame (result);
if (hr != COM.S_OK || result[0] == 0) {
- return COM.S_OK;
- }
- IWebFrame mainFrame = new IWebFrame(result[0]);
- mainFrame.loadRequest(req.getAddress());
- mainFrame.Release();
+ return COM.S_OK;
+ }
+ IWebFrame mainFrame = new IWebFrame (result[0]);
+ mainFrame.loadRequest (req.getAddress ());
+ mainFrame.Release ();
}
}
return COM.S_OK;
@@ -194,108 +194,108 @@ int /*long*/ getAddress () {
return iWebUIDelegate.getAddress ();
}
-int mouseDidMoveOverElement(int /*long*/ sender, int /*long*/ elementInformation, int /*long*/ modifierFlags) {
+int mouseDidMoveOverElement (int /*long*/ sender, int /*long*/ elementInformation, int /*long*/ modifierFlags) {
if (elementInformation == 0) return COM.S_OK;
- IPropertyBag info = new IPropertyBag(elementInformation);
- int /*long*/ key = WebKit.createBSTR("WebElementLinkURLKey"); //$NON-NLS-N$
- int /*long*/ hHeap = OS.GetProcessHeap();
- int /*long*/ resultPtr = OS.HeapAlloc(hHeap, OS.HEAP_ZERO_MEMORY, VARIANT.sizeof);
- int hr = info.Read(key, resultPtr, null);
+ IPropertyBag info = new IPropertyBag (elementInformation);
+ int /*long*/ key = WebKit.createBSTR ("WebElementLinkURLKey"); //$NON-NLS-N$
+ int /*long*/ hHeap = OS.GetProcessHeap ();
+ int /*long*/ resultPtr = OS.HeapAlloc (hHeap, OS.HEAP_ZERO_MEMORY, VARIANT.sizeof);
+ int hr = info.Read (key, resultPtr, null);
if (hr != COM.S_OK || resultPtr == 0) {
return COM.S_OK;
}
String value = null;
- VARIANT v = new VARIANT();
- COM.MoveMemory(v, resultPtr, VARIANT.sizeof);
- if (v.vt == COM.VT_BSTR) value = WebKit.extractBSTR(v.lVal);
- OS.HeapFree(hHeap, 0, resultPtr);
+ VARIANT v = new VARIANT ();
+ COM.MoveMemory (v, resultPtr, VARIANT.sizeof);
+ if (v.vt == COM.VT_BSTR) value = WebKit.extractBSTR (v.lVal);
+ OS.HeapFree (hHeap, 0, resultPtr);
StatusTextListener[] statusTextListeners = browser.webBrowser.statusTextListeners;
- if (value == null || value.length() == 0) {
+ if (value == null || value.length () == 0) {
/* not currently over a link */
if (lastHoveredLinkURL == null) return COM.S_OK;
lastHoveredLinkURL = null;
- StatusTextEvent statusText = new StatusTextEvent(browser);
- statusText.display = browser.getDisplay();
+ StatusTextEvent statusText = new StatusTextEvent (browser);
+ statusText.display = browser.getDisplay ();
statusText.widget = browser;
statusText.text = ""; //$NON-NLS-1$
for (int i = 0; i < statusTextListeners.length; i++) {
- statusTextListeners[i].changed(statusText);
+ statusTextListeners[i].changed (statusText);
}
return COM.S_OK;
}
- if (value.equals(lastHoveredLinkURL)) return COM.S_OK;
+ if (value.equals (lastHoveredLinkURL)) return COM.S_OK;
lastHoveredLinkURL = value;
- StatusTextEvent statusText = new StatusTextEvent(browser);
- statusText.display = browser.getDisplay();
+ StatusTextEvent statusText = new StatusTextEvent (browser);
+ statusText.display = browser.getDisplay ();
statusText.widget = browser;
statusText.text = value;
for (int i = 0; i < statusTextListeners.length; i++) {
- statusTextListeners[i].changed(statusText);
+ statusTextListeners[i].changed (statusText);
}
return COM.S_OK;
}
int printFrame (int /*long*/ webView, int /*long*/ frame) {
- IWebFrame iwebFrame = new IWebFrame(frame);
- PRINTDLG pd = new PRINTDLG();
+ IWebFrame iwebFrame = new IWebFrame (frame);
+ PRINTDLG pd = new PRINTDLG ();
pd.lStructSize = PRINTDLG.sizeof;
pd.Flags = OS.PD_RETURNDC;
- OS.PrintDlg(pd);
+ OS.PrintDlg (pd);
int /*long*/ printDC = pd.hDC;
int /*long*/[] result = new int /*long*/[1];
- int hr = iwebFrame.QueryInterface(WebKit_win32.IID_IWebFramePrivate, result);
+ int hr = iwebFrame.QueryInterface (WebKit_win32.IID_IWebFramePrivate, result);
if (hr != COM.S_OK || result[0] == 0) {
return COM.S_OK;
}
- IWebFramePrivate privateFrame = new IWebFramePrivate(result[0]);
- privateFrame.setInPrintingMode(true, printDC);
+ IWebFramePrivate privateFrame = new IWebFramePrivate (result[0]);
+ privateFrame.setInPrintingMode (1, printDC);
int [] count = new int [1];
- hr = privateFrame.getPrintedPageCount(printDC, count);
+ hr = privateFrame.getPrintedPageCount (printDC, count);
if (hr != COM.S_OK || count[0] == 0) {
- privateFrame.Release();
+ privateFrame.Release ();
return COM.S_OK;
}
int pageCount = count[0];
String jobName = null;
result[0] = 0;
- hr = iwebFrame.dataSource(result);
+ hr = iwebFrame.dataSource (result);
if (hr == COM.S_OK && result[0] != 0) {
- IWebDataSource dataSource = new IWebDataSource(result[0]);
+ IWebDataSource dataSource = new IWebDataSource (result[0]);
result[0] = 0;
- hr = dataSource.pageTitle(result);
- dataSource.Release();
+ hr = dataSource.pageTitle (result);
+ dataSource.Release ();
if (hr == COM.S_OK && result[0] != 0) {
- jobName = WebKit.extractBSTR(result[0]);
- COM.SysFreeString(result[0]);
+ jobName = WebKit.extractBSTR (result[0]);
+ COM.SysFreeString (result[0]);
}
}
- DOCINFO di = new DOCINFO();
+ DOCINFO di = new DOCINFO ();
di.cbSize = DOCINFO.sizeof;
- int /*long*/ hHeap = OS.GetProcessHeap();
+ int /*long*/ hHeap = OS.GetProcessHeap ();
int /*long*/ lpszDocName = 0;
- if (jobName != null && jobName.length() != 0) {
+ if (jobName != null && jobName.length () != 0) {
/* Use the character encoding for the default locale */
- TCHAR buffer = new TCHAR(0, jobName, true);
- int byteCount = buffer.length() * TCHAR.sizeof;
- lpszDocName = OS.HeapAlloc(hHeap, OS.HEAP_ZERO_MEMORY, byteCount);
- OS.MoveMemory(lpszDocName, buffer, byteCount);
+ TCHAR buffer = new TCHAR (0, jobName, true);
+ int byteCount = buffer.length () * TCHAR.sizeof;
+ lpszDocName = OS.HeapAlloc (hHeap, OS.HEAP_ZERO_MEMORY, byteCount);
+ OS.MoveMemory (lpszDocName, buffer, byteCount);
di.lpszDocName = lpszDocName;
}
- int rc = OS.StartDoc(printDC, di);
+ int rc = OS.StartDoc (printDC, di);
if (lpszDocName != 0) OS.HeapFree(hHeap, 0, lpszDocName);
if (rc >= 0) {
for (int i = 0; i < pageCount; i++) {
- OS.StartPage(printDC);
- privateFrame.spoolPages(printDC, i, i, null);
- OS.EndPage(printDC);
+ OS.StartPage (printDC);
+ privateFrame.spoolPages (printDC, i, i, null);
+ OS.EndPage (printDC);
}
- privateFrame.setInPrintingMode(false, printDC);
- OS.EndDoc(printDC);
+ privateFrame.setInPrintingMode (0, printDC);
+ OS.EndDoc (printDC);
}
- privateFrame.Release();
+ privateFrame.Release ();
return COM.S_OK;
}
@@ -330,153 +330,153 @@ int Release () {
int runBeforeUnloadConfirmPanelWithMessage (int /*long*/ sender, int /*long*/ message, int /*long*/ initiatedByFrame, int /*long*/ result) {
if (!prompt) return COM.S_OK;
- Shell parent = browser.getShell();
+ Shell parent = browser.getShell ();
String string = WebKit.extractBSTR (message);
- StringBuffer text = new StringBuffer(Compatibility.getMessage("SWT_OnBeforeUnload_Message1")); //$NON-NLS-1$
- text.append("\n\n"); //$NON-NLS-1$
- text.append(string);
- text.append("\n\n"); //$NON-NLS-1$
- text.append(Compatibility.getMessage("SWT_OnBeforeUnload_Message2")); //$NON-NLS-1$
- MessageBox box = new MessageBox(parent, SWT.OK | SWT.CANCEL | SWT.ICON_QUESTION);
- box.setMessage (text.toString());
+ StringBuffer text = new StringBuffer (Compatibility.getMessage ("SWT_OnBeforeUnload_Message1")); //$NON-NLS-1$
+ text.append ("\n\n"); //$NON-NLS-1$
+ text.append (string);
+ text.append ("\n\n"); //$NON-NLS-1$
+ text.append (Compatibility.getMessage ("SWT_OnBeforeUnload_Message2")); //$NON-NLS-1$
+ MessageBox box = new MessageBox (parent, SWT.OK | SWT.CANCEL | SWT.ICON_QUESTION);
+ box.setMessage (text.toString ());
int [] response = new int[1];
response[0] = box.open () == SWT.OK ? 1 : 0;
- OS.MoveMemory(result, response, C.PTR_SIZEOF);
+ OS.MoveMemory (result, response, C.PTR_SIZEOF);
return COM.S_OK;
}
int runJavaScriptAlertPanelWithMessage (int /*long*/ sender, int /*long*/ message) {
- Shell parent = browser.getShell();
+ Shell parent = browser.getShell ();
String string = WebKit.extractBSTR (message);
- MessageBox box = new MessageBox(parent, SWT.OK | SWT.ICON_WARNING);
- box.setText("Javascript"); //$NON-NLS-1$
+ MessageBox box = new MessageBox (parent, SWT.OK | SWT.ICON_WARNING);
+ box.setText ("Javascript"); //$NON-NLS-1$
box.setMessage (string);
box.open ();
return COM.S_OK;
}
int runJavaScriptConfirmPanelWithMessage (int /*long*/ sender, int /*long*/ message, int /*long*/ result) {
- Shell parent = browser.getShell();
+ Shell parent = browser.getShell ();
String string = WebKit.extractBSTR (message);
- MessageBox box = new MessageBox(parent, SWT.OK | SWT.CANCEL | SWT.ICON_QUESTION);
- box.setText("Javascript"); //$NON-NLS-1$
+ MessageBox box = new MessageBox (parent, SWT.OK | SWT.CANCEL | SWT.ICON_QUESTION);
+ box.setText ("Javascript"); //$NON-NLS-1$
box.setMessage (string);
int [] response = new int[1];
response[0] = box.open () == SWT.OK ? 1 : 0;
- OS.MoveMemory(result, response, C.PTR_SIZEOF);
+ OS.MoveMemory (result, response, C.PTR_SIZEOF);
return COM.S_OK;
}
-int runJavaScriptTextInputPanelWithPrompt(int /*long*/ sender, int /*long*/ message, int /*long*/ defaultText, int /*long*/ result) {
- Shell parent = browser.getShell();
+int runJavaScriptTextInputPanelWithPrompt (int /*long*/ sender, int /*long*/ message, int /*long*/ defaultText, int /*long*/ result) {
+ Shell parent = browser.getShell ();
String string = WebKit.extractBSTR (message);
- TextPrompter prompt = new TextPrompter(parent, SWT.APPLICATION_MODAL | SWT.DIALOG_TRIM);
- prompt.setText("Javascript"); //$NON-NLS-1$
+ TextPrompter prompt = new TextPrompter (parent, SWT.APPLICATION_MODAL | SWT.DIALOG_TRIM);
+ prompt.setText ("Javascript"); //$NON-NLS-1$
prompt.setMessage (string);
string = WebKit.extractBSTR (defaultText);
- prompt.setDefaultText(string);
+ prompt.setDefaultText (string);
string = prompt.open ();
int /*long*/ [] response = new int /*long*/ [1];
if (string != null) {
- response[0] = WebKit.createBSTR(string);
+ response[0] = WebKit.createBSTR (string);
}
- OS.MoveMemory(result, response, C.PTR_SIZEOF);
+ OS.MoveMemory (result, response, C.PTR_SIZEOF);
return COM.S_OK;
}
int runOpenPanelForFileButtonWithResultListener (int /*long*/ sender, int /*long*/ resultListener) {
- Shell parent = browser.getShell();
- FileDialog dialog = new FileDialog(parent, SWT.NONE);
- String result = dialog.open();
- IWebOpenPanelResultListener listener = new IWebOpenPanelResultListener(resultListener);
+ Shell parent = browser.getShell ();
+ FileDialog dialog = new FileDialog (parent, SWT.NONE);
+ String result = dialog.open ();
+ IWebOpenPanelResultListener listener = new IWebOpenPanelResultListener (resultListener);
if (result == null) {
- listener.cancel();
+ listener.cancel ();
} else {
- listener.chooseFilename(WebKit.createBSTR(result));
+ listener.chooseFilename (WebKit.createBSTR (result));
}
return COM.S_OK;
}
-void setBrowser(Browser browser) {
+void setBrowser (Browser browser) {
this.browser = browser;
}
-int setFrame(int /*long*/ sender, int /*long*/ frame) {
- RECT rect = new RECT();
- COM.MoveMemory(rect, frame, RECT.sizeof);
+int setFrame (int /*long*/ sender, int /*long*/ frame) {
+ RECT rect = new RECT ();
+ COM.MoveMemory (rect, frame, RECT.sizeof);
/* convert to SWT system coordinates */
- location = browser.getDisplay().map(browser, null, (int)rect.left, (int)rect.top);
+ location = browser.getDisplay ().map (browser, null, (int)rect.left, (int)rect.top);
int x = (int)(rect.right - rect.left);
int y = (int)(rect.bottom - rect.top);
if (y < 0 || x < 0 || (x == 0 && y == 0)) return COM.S_OK;
- size = new Point(x, y);
+ size = new Point (x, y);
return COM.S_OK;
}
-int setMenuBarVisible(int /*long*/ sender, int /*long*/ visible) {
+int setMenuBarVisible (int /*long*/ sender, int /*long*/ visible) {
/* Note. Webkit only emits the notification when the status bar should be hidden. */
menuBar = visible == 1;
return COM.S_OK;
}
-int setStatusBarVisible(int /*long*/ sender, int /*long*/ visible) {
+int setStatusBarVisible (int /*long*/ sender, int /*long*/ visible) {
/* Note. Webkit only emits the notification when the status bar should be hidden. */
statusBar = visible == 1;
return COM.S_OK;
}
-int setStatusText(int /*long*/ sender, int /*long*/ text) {
- String statusText = WebKit.extractBSTR(text);
- if (statusText.length() == 0) return COM.S_OK;
- StatusTextEvent statusTextEvent = new StatusTextEvent(browser);
- statusTextEvent.display = browser.getDisplay();
+int setStatusText (int /*long*/ sender, int /*long*/ text) {
+ String statusText = WebKit.extractBSTR (text);
+ if (statusText.length () == 0) return COM.S_OK;
+ StatusTextEvent statusTextEvent = new StatusTextEvent (browser);
+ statusTextEvent.display = browser.getDisplay ();
statusTextEvent.widget = browser;
statusTextEvent.text = statusText;
StatusTextListener[] statusTextListeners = browser.webBrowser.statusTextListeners;
for (int i = 0; i < statusTextListeners.length; i++) {
- statusTextListeners[i].changed(statusTextEvent);
+ statusTextListeners[i].changed (statusTextEvent);
}
return COM.S_OK;
}
-int setToolbarsVisible(int /*long*/ sender, int /*long*/ visible) {
+int setToolbarsVisible (int /*long*/ sender, int /*long*/ visible) {
/* Note. Webkit only emits the notification when the status bar should be hidden. */
toolBar = visible == 1;
return COM.S_OK;
}
-int takeFocus(int /*long*/ sender, int /*long*/ forward) {
+int takeFocus (int /*long*/ sender, int /*long*/ forward) {
int traveralCode = forward == 0 ? SWT.TRAVERSE_TAB_PREVIOUS : SWT.TRAVERSE_TAB_NEXT;
((WebKit)browser.webBrowser).traverseOut = true;
- browser.traverse(traveralCode);
+ browser.traverse (traveralCode);
return COM.S_OK;
}
-int webViewClose(int /*long*/ sender) {
- WindowEvent newEvent = new WindowEvent(browser);
- newEvent.display = browser.getDisplay();
+int webViewClose (int /*long*/ sender) {
+ WindowEvent newEvent = new WindowEvent (browser);
+ newEvent.display = browser.getDisplay ();
newEvent.widget = browser;
CloseWindowListener[] closeWindowListeners = browser.webBrowser.closeWindowListeners;
for (int i = 0; i < closeWindowListeners.length; i++) {
- closeWindowListeners[i].close(newEvent);
+ closeWindowListeners[i].close (newEvent);
}
- browser.dispose();
+ browser.dispose ();
return COM.S_OK;
}
-int webViewFrame(int /*long*/ sender, int /*long*/ frame) {
- RECT rect = new RECT();
- OS.MoveMemory(frame, rect, RECT.sizeof);
+int webViewFrame (int /*long*/ sender, int /*long*/ frame) {
+ RECT rect = new RECT ();
+ OS.MoveMemory (frame, rect, RECT.sizeof);
return COM.S_OK;
}
-int webViewShow(int /*long*/ sender) {
- Shell parent = browser.getShell();
- Point pt = parent.getSize();
- parent.setSize(pt.x+1, pt.y);
- parent.setSize(pt.x, pt.y);
- WindowEvent newEvent = new WindowEvent(browser);
- newEvent.display = browser.getDisplay();
+int webViewShow (int /*long*/ sender) {
+ Shell parent = browser.getShell ();
+ Point pt = parent.getSize ();
+ parent.setSize (pt.x+1, pt.y);
+ parent.setSize (pt.x, pt.y);
+ WindowEvent newEvent = new WindowEvent (browser);
+ newEvent.display = browser.getDisplay ();
newEvent.widget = browser;
if (location != null) newEvent.location = location;
if (size != null) newEvent.size = size;
@@ -492,7 +492,7 @@ int webViewShow(int /*long*/ sender) {
newEvent.toolBar = toolBar;
VisibilityWindowListener[] visibilityWindowListeners = browser.webBrowser.visibilityWindowListeners;
for (int i = 0; i < visibilityWindowListeners.length; i++) {
- visibilityWindowListeners[i].show(newEvent);
+ visibilityWindowListeners[i].show (newEvent);
}
location = null;
size = null;
@@ -513,57 +513,58 @@ class TextPrompter extends Dialog {
return message;
}
public String open () {
- final Shell dialog = new Shell(getParent(), getStyle());
- dialog.setText(getText());
- dialog.setLayout(new GridLayout());
- Label label = new Label(dialog, SWT.NONE);
- label.setText(message);
- label.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
- final Text textBox = new Text(dialog, SWT.SINGLE | SWT.BORDER);
- GridData data = new GridData(GridData.FILL_HORIZONTAL);
+ final Shell dialog = new Shell (getParent (), getStyle ());
+ dialog.setText (getText ());
+ dialog.setLayout (new GridLayout ());
+ Label label = new Label (dialog, SWT.NONE);
+ label.setText (message);
+ label.setLayoutData (new GridData (GridData.FILL_HORIZONTAL));
+ final Text textBox = new Text (dialog, SWT.SINGLE | SWT.BORDER);
+ GridData data = new GridData (GridData.FILL_HORIZONTAL);
data.widthHint = 300;
- textBox.setLayoutData(data);
- textBox.setText(text);
- Composite buttons = new Composite(dialog, SWT.NONE);
- GridLayout grid = new GridLayout();
+ textBox.setLayoutData (data);
+ textBox.setText (text);
+ Composite buttons = new Composite (dialog, SWT.NONE);
+ GridLayout grid = new GridLayout ();
grid.numColumns = 2;
- buttons.setLayout(grid);
- buttons.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_END));
- Button ok = new Button(buttons, SWT.PUSH);
- ok.setText(SWT.getMessage("SWT_OK"));
- data = new GridData();
+ buttons.setLayout (grid);
+ buttons.setLayoutData (new GridData (GridData.HORIZONTAL_ALIGN_END));
+ Button ok = new Button (buttons, SWT.PUSH);
+ ok.setText (SWT.getMessage ("SWT_OK"));
+ data = new GridData ();
data.widthHint = 75;
- ok.setLayoutData(data);
- ok.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- result = textBox.getText();
- dialog.dispose();
+ ok.setLayoutData (data);
+ ok.addSelectionListener (new SelectionAdapter () {
+ public void widgetSelected (SelectionEvent e) {
+ result = textBox.getText ();
+ dialog.dispose ();
}
});
- Button cancel = new Button(buttons, SWT.PUSH);
- cancel.setText(SWT.getMessage("SWT_Cancel"));
- data = new GridData();
+ Button cancel = new Button (buttons, SWT.PUSH);
+ cancel.setText (SWT.getMessage ("SWT_Cancel"));
+ data = new GridData ();
data.widthHint = 75;
- cancel.setLayoutData(data);
- cancel.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- dialog.dispose();
+ cancel.setLayoutData (data);
+ cancel.addSelectionListener (new SelectionAdapter () {
+ public void widgetSelected (SelectionEvent e) {
+ dialog.dispose ();
}
});
- dialog.setDefaultButton(ok);
- dialog.pack();
- dialog.open();
- Display display = getParent().getDisplay();
- while (!dialog.isDisposed()) {
- if (!display.readAndDispatch()) display.sleep();
+ dialog.setDefaultButton (ok);
+ dialog.pack ();
+ dialog.open ();
+ Display display = getParent ().getDisplay ();
+ while (!dialog.isDisposed ()) {
+ if (!display.readAndDispatch ()) display.sleep ();
}
return result;
}
- public void setDefaultText(String text) {
+ public void setDefaultText (String text) {
this.text = text;
}
public void setMessage (String string) {
message = string;
}
}
+
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IDOMDocument.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IDOMDocument.java
deleted file mode 100644
index 6bfa6aface..0000000000
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IDOMDocument.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2010 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.webkit;
-
-import org.eclipse.swt.internal.ole.win32.*;
-
-public class IDOMDocument extends IUnknown {
-
-public IDOMDocument(int /*long*/ address) {
- super(address);
-}
-
-public int addEventListener (int /*long*/ type, int /*long*/ listener, boolean useCapture) {
- return COM.VtblCall (40, getAddress (), type, listener, useCapture);
-}
-}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebCookieManager.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebCookieManager.java
index 9fe6c4d8f1..519c960ad9 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebCookieManager.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebCookieManager.java
@@ -10,12 +10,13 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebCookieManager extends IUnknown {
-public IWebCookieManager(int /*long*/ address) {
- super(address);
+public IWebCookieManager (int /*long*/ address) {
+ super (address);
}
public int cookieStorage (int /*long*/[] storage) {
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDataSource.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDataSource.java
index 46b4ee9cdd..beb32f3b8a 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDataSource.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDataSource.java
@@ -10,27 +10,29 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebDataSource extends IUnknown {
public IWebDataSource (int /*long*/ address) {
- super(address);
-}
-
-public int pageTitle (int /*long*/[] title) {
- return COM.VtblCall (12, getAddress (), title);
+ super (address);
}
public int representation (int /*long*/[] rep) {
return COM.VtblCall (5, getAddress (), rep);
}
+public int webFrame (int /*long*/[] frame) {
+ return COM.VtblCall (6, getAddress (), frame);
+}
+
public int request (int /*long*/[] request) {
return COM.VtblCall (8, getAddress (), request);
}
-public int webFrame (int /*long*/[] frame) {
- return COM.VtblCall (6, getAddress (), frame);
+public int pageTitle (int /*long*/[] title) {
+ return COM.VtblCall (12, getAddress (), title);
}
+
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDocumentRepresentation.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDocumentRepresentation.java
index 577987cf80..3370b5e70d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDocumentRepresentation.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDocumentRepresentation.java
@@ -10,12 +10,13 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebDocumentRepresentation extends IUnknown {
-public IWebDocumentRepresentation(int /*long*/ address) {
- super(address);
+public IWebDocumentRepresentation (int /*long*/ address) {
+ super (address);
}
public int documentSource (int /*long*/[] source) {
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDownload.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDownload.java
index 968ee0bbfe..392b29644d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDownload.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebDownload.java
@@ -10,31 +10,25 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebDownload extends IUnknown {
- public IWebDownload(int /*long*/ address) {
- super(address);
- }
-
- public int cancel () {
- return COM.VtblCall(4, getAddress());
- }
-
- public int cancelForResume () {
- return COM.VtblCall(5, getAddress());
- }
-
- public int setDeletesFileUponFailure (boolean deletesFileUponFailure) {
- return COM.VtblCall(12, getAddress(), deletesFileUponFailure);
- }
-
- public int setDestination (int /*long*/ path, boolean allowOverwrite) {
- return COM.VtblCall(13, getAddress(), path, allowOverwrite);
- }
-
- public int start () {
- return COM.VtblCall(6, getAddress());
- }
+public IWebDownload (int /*long*/ address) {
+ super (address);
+}
+
+public int cancel () {
+ return COM.VtblCall (4, getAddress ());
+}
+
+public int setDeletesFileUponFailure (int deletesFileUponFailure) {
+ return COM.VtblCall (12, getAddress (), deletesFileUponFailure);
+}
+
+public int setDestination (int /*long*/ path, int allowOverwrite) {
+ return COM.VtblCall (13, getAddress(), path, allowOverwrite);
+}
+
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebError.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebError.java
index 10b4532917..d2e0acbc39 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebError.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebError.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebError extends IUnknown {
@@ -22,28 +23,24 @@ public int code (int[] result) {
return COM.VtblCall (4, getAddress (), result);
}
-public int domain (int[] result) {
- return COM.VtblCall (5, getAddress (), result);
-}
-
-public int failingURL (int /*long*/[] result) {
- return COM.VtblCall (12, getAddress (), result);
-}
+//public int domain (int /*long*/[] result) {
+// return COM.VtblCall (5, getAddress (), result);
+//}
public int localizedDescription (int /*long*/[] result) {
return COM.VtblCall (6, getAddress (), result);
}
-public int localizedFailureReason (int /*long*/[] result) {
- return COM.VtblCall (7, getAddress (), result);
-}
+//public int localizedFailureReason (int /*long*/[] result) {
+// return COM.VtblCall (7, getAddress (), result);
+//}
-public int sslPeerCertificate (int /*long*/[] result) {
- return COM.VtblCall (12, getAddress (), result);
-}
+//public int userInfo (int /*long*/[] result) {
+//return COM.VtblCall (11, getAddress (), result);
+//}
-public int userInfo (int /*long*/[] result) {
- return COM.VtblCall (11, getAddress (), result);
+public int failingURL (int /*long*/[] result) {
+ return COM.VtblCall (12, getAddress (), result);
}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IDOMEventListener.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebErrorPrivate.java
index 5b4480b92e..bd091cdc8c 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IDOMEventListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebErrorPrivate.java
@@ -10,11 +10,17 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
-public class IDOMEventListener extends IUnknown {
+public class IWebErrorPrivate extends IUnknown {
+
+public IWebErrorPrivate (int /*long*/ address) {
+ super (address);
+}
+
+public int sslPeerCertificate (int /*long*/[] result) {
+ return COM.VtblCall (3, getAddress (), result);
+}
- public IDOMEventListener(int address) {
- super(address);
- }
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebFrame.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebFrame.java
index 17f28eed93..4868c22595 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebFrame.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebFrame.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebFrame extends IUnknown {
@@ -18,28 +19,20 @@ public IWebFrame (int /*long*/ address) {
super (address);
}
-public int dataSource (int /*long*/[] source) {
- return COM.VtblCall (13, getAddress (), source);
-}
-
-public int DOMDocument (int /*long*/[] document) {
- return COM.VtblCall (6, getAddress (), document);
-}
-
-public int /*long*/ globalContext () {
- return COM.VtblCall (23, getAddress ());
+public int loadRequest (int /*long*/ request) {
+ return COM.VtblCall (8, getAddress (), request);
}
public int loadHTMLString (int /*long*/ string, int /*long*/ baseURL) {
return COM.VtblCall (10, getAddress (), string, baseURL);
}
-public int loadRequest (int /*long*/ request) {
- return COM.VtblCall (8, getAddress (), request);
+public int dataSource (int /*long*/[] source) {
+ return COM.VtblCall (13, getAddress (), source);
}
-public int name (int /*long*/[] frameName) {
- return COM.VtblCall (3, getAddress (), frameName);
+public int /*long*/ globalContext () {
+ return COM.VtblCall (23, getAddress ());
}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebFramePrivate.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebFramePrivate.java
index cc5cecd851..aefc007ed9 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebFramePrivate.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebFramePrivate.java
@@ -10,27 +10,24 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebFramePrivate extends IUnknown {
-public IWebFramePrivate(int /*long*/ address) {
- super(address);
+public IWebFramePrivate (int /*long*/ address) {
+ super (address);
}
-public int frameBounds (int /*long*/[] result) {
- return COM.VtblCall (16, getAddress (), result);
+public int setInPrintingMode (int value, int /*long*/ printDC) {
+ return COM.VtblCall (8, getAddress (), value, printDC);
}
-public int getPrintedPageCount (int /*long*/ printDC, int [] pageCount) {
+public int getPrintedPageCount (int /*long*/ printDC, int[] pageCount) {
return COM.VtblCall (9, getAddress (), printDC, pageCount);
}
-public int setInPrintingMode (boolean value, int /*long*/ printDC) {
- return COM.VtblCall (8, getAddress (), value, printDC);
-}
-
-public int spoolPages (int /*long*/ printDC, int startPage, int endPage, int [] ctx) {
+public int spoolPages (int /*long*/ printDC, int startPage, int endPage, int /*long*/[] ctx) {
return COM.VtblCall (10, getAddress (), printDC, startPage, endPage, ctx);
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebIBActions.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebIBActions.java
index 4fe2576995..1c3498dfff 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebIBActions.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebIBActions.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebIBActions extends IUnknown {
@@ -18,20 +19,20 @@ public IWebIBActions (int /*long*/ address) {
super (address);
}
-public int canGoBack (int /*long*/ sender, int /*long*/[] result) {
- return COM.VtblCall (6, getAddress (), sender, result);
-}
-
-public int canGoForward (int /*long*/ sender, int /*long*/[] result) {
- return COM.VtblCall (8, getAddress (), sender, result);
+public int stopLoading (int /*long*/ sender) {
+ return COM.VtblCall (4, getAddress (), sender);
}
public int reload (int /*long*/ sender) {
return COM.VtblCall (5, getAddress (), sender);
}
-public int stopLoading (int /*long*/ sender) {
- return COM.VtblCall (4, getAddress (), sender);
+public int canGoBack (int /*long*/ sender, int[] result) {
+ return COM.VtblCall (6, getAddress (), sender, result);
+}
+
+public int canGoForward (int /*long*/ sender, int[] result) {
+ return COM.VtblCall (8, getAddress (), sender, result);
}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebMutableURLRequest.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebMutableURLRequest.java
index 6ffe60a2f7..10bd43fc43 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebMutableURLRequest.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebMutableURLRequest.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebMutableURLRequest extends IWebURLRequest {
@@ -18,17 +19,13 @@ public IWebMutableURLRequest (int /*long*/ address) {
super (address);
}
-public int setAllowsAnyHTTPSCertificate () {
- return COM.VtblCall (29, getAddress ());
-}
-
-public int setHTTPBody (int /*long*/ data) {
- return COM.VtblCall (21, getAddress (), data);
-}
+//public int setHTTPBody (int /*long*/ data) {
+// return COM.VtblCall (21, getAddress (), data);
+//}
-public int setHTTPBodyStream (int /*long*/ data) {
- return COM.VtblCall (22, getAddress (), data);
-}
+//public int setHTTPBodyStream (int /*long*/ data) {
+// return COM.VtblCall (22, getAddress (), data);
+//}
public int setHTTPMethod (int post) {
return COM.VtblCall (23, getAddress (), post);
@@ -42,5 +39,8 @@ public int setValue (int /*long*/ value, int /*long*/ field) {
return COM.VtblCall (28, getAddress (), value, field);
}
+public int setAllowsAnyHTTPSCertificate () {
+ return COM.VtblCall (29, getAddress ());
+}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebMutableURLRequestPrivate.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebMutableURLRequestPrivate.java
index 7a65407e67..eb24b490f0 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebMutableURLRequestPrivate.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebMutableURLRequestPrivate.java
@@ -10,19 +10,21 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebMutableURLRequestPrivate extends IUnknown {
- public IWebMutableURLRequestPrivate(int /*long*/ address) {
- super(address);
- }
-
- public int cfRequest () {
- return COM.VtblCall (4, getAddress ());
- }
-
- public int setClientCertificate (int /*long*/ cert) {
- return COM.VtblCall (3, getAddress (), cert);
- }
+public IWebMutableURLRequestPrivate (int /*long*/ address) {
+ super (address);
+}
+
+//public int setClientCertificate (int /*long*/ cert) {
+//return COM.VtblCall (3, getAddress (), cert);
+//}
+
+public int cfRequest () {
+ return COM.VtblCall (4, getAddress ());
+}
+
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebOpenPanelResultListener.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebOpenPanelResultListener.java
index 9c106a1734..ec5095b81e 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebOpenPanelResultListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebOpenPanelResultListener.java
@@ -14,16 +14,16 @@ import org.eclipse.swt.internal.ole.win32.*;
public class IWebOpenPanelResultListener extends IUnknown {
- public IWebOpenPanelResultListener(int /*long*/ address) {
- super(address);
- }
-
- public int cancel () {
- return COM.VtblCall (4, getAddress ());
- }
-
- public int chooseFilename (int /*long*/ fileName) {
- return COM.VtblCall (3, getAddress (), fileName);
- }
+public IWebOpenPanelResultListener (int /*long*/ address) {
+ super (address);
+}
+
+public int chooseFilename (int /*long*/ fileName) {
+ return COM.VtblCall (3, getAddress (), fileName);
+}
+
+public int cancel () {
+ return COM.VtblCall (4, getAddress ());
+}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebPolicyDecisionListener.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebPolicyDecisionListener.java
index cd69a01640..57f0badf73 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebPolicyDecisionListener.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebPolicyDecisionListener.java
@@ -10,12 +10,17 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebPolicyDecisionListener extends IUnknown{
-public IWebPolicyDecisionListener(int /*long*/ address) {
- super(address);
+public IWebPolicyDecisionListener (int /*long*/ address) {
+ super (address);
+}
+
+public int use () {
+ return COM.VtblCall (3, getAddress ());
}
public int download () {
@@ -26,8 +31,4 @@ public int ignore () {
return COM.VtblCall (5, getAddress ());
}
-public int use () {
- return COM.VtblCall (3, getAddress ());
-}
-
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebPreferences.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebPreferences.java
index e6f93bed64..1e2f044431 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebPreferences.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebPreferences.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebPreferences extends IUnknown {
@@ -18,44 +19,24 @@ public IWebPreferences (int /*long*/ address) {
super (address);
}
-public int isJavaEnabled (int [] enabled) {
- return COM.VtblCall (32, getAddress (), enabled);
-}
-
-public int isJavaScriptEnabled (int [] enabled) {
- return COM.VtblCall (34, getAddress (), enabled);
-}
-
-public int javaScriptCanOpenWindowsAutomatically (int [] enabled) {
- return COM.VtblCall (36, getAddress (), enabled);
-}
-
-public int setCookieStorageAcceptPolicy (int acceptPolicy) {
- return COM.VtblCall (67, getAddress (), acceptPolicy);
-}
-
-public int setJavaEnabled (boolean enabled) {
+public int setJavaEnabled (int enabled) {
return COM.VtblCall (33, getAddress (), enabled);
}
-public int setJavaScriptCanOpenWindowsAutomatically (boolean enabled) {
- return COM.VtblCall (37, getAddress (), enabled);
-}
-
-public int setJavaScriptEnabled (boolean enabled) {
+public int setJavaScriptEnabled (int enabled) {
return COM.VtblCall (35, getAddress (), enabled);
}
-public int setFontSmoothing (int smoothingType) {
- return COM.VtblCall (63, getAddress (), smoothingType);
+public int setJavaScriptCanOpenWindowsAutomatically (int enabled) {
+ return COM.VtblCall (37, getAddress (), enabled);
}
-public int setTabsToLinks (boolean enabled) {
+public int setTabsToLinks (int enabled) {
return COM.VtblCall (52, getAddress (), enabled);
}
-public int standardPreferences (int /*long*/[] preferences) {
- return COM.VtblCall (3, getAddress (), preferences);
+public int setFontSmoothing (int smoothingType) {
+ return COM.VtblCall (63, getAddress (), smoothingType);
}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLAuthenticationChallenge.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLAuthenticationChallenge.java
index a4333b850d..4b91e13de7 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLAuthenticationChallenge.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLAuthenticationChallenge.java
@@ -10,15 +10,16 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebURLAuthenticationChallenge extends IUnknown {
-public IWebURLAuthenticationChallenge(int /*long*/ address) {
- super(address);
+public IWebURLAuthenticationChallenge (int /*long*/ address) {
+ super (address);
}
-public int previousFailureCount (int /*long*/[] result) {
+public int previousFailureCount (int[] result) {
return COM.VtblCall (7, getAddress (), result);
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLAuthenticationChallengeSender.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLAuthenticationChallengeSender.java
index abb9953fd5..0e22796770 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLAuthenticationChallengeSender.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLAuthenticationChallengeSender.java
@@ -10,12 +10,13 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebURLAuthenticationChallengeSender extends IUnknown {
-public IWebURLAuthenticationChallengeSender(int /*long*/ address) {
- super(address);
+public IWebURLAuthenticationChallengeSender (int /*long*/ address) {
+ super (address);
}
public int cancelAuthenticationChallenge (int /*long*/ challenge) {
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLCredential.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLCredential.java
index 1ffa4a40fe..82b2d9fa1d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLCredential.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLCredential.java
@@ -10,15 +10,16 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebURLCredential extends IUnknown {
-public IWebURLCredential(int /*long*/ address) {
- super(address);
+public IWebURLCredential (int /*long*/ address) {
+ super (address);
}
-public int hasPassword (int /*long*/[] result) {
+public int hasPassword (int[] result) {
return COM.VtblCall (3, getAddress (), result);
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLProtectionSpace.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLProtectionSpace.java
index c9bde7f565..cfa231b0f5 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLProtectionSpace.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLProtectionSpace.java
@@ -10,29 +10,29 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebURLProtectionSpace extends IUnknown {
- public IWebURLProtectionSpace(int /*long*/ address) {
- super(address);
- }
-
- public int host (int /*long*/[] result) {
- return COM.VtblCall (4, getAddress (), result);
- }
-
- public int isProxy (int /*long*/[] result) {
- return COM.VtblCall (7, getAddress (), result);
- }
-
- public int port (int /*long*/[] result) {
- return COM.VtblCall (8, getAddress (), result);
- }
-
- public int realm (int /*long*/[] result) {
- return COM.VtblCall (11, getAddress (), result);
- }
-
+public IWebURLProtectionSpace(int /*long*/ address) {
+ super(address);
+}
+
+public int host (int /*long*/[] result) {
+ return COM.VtblCall (4, getAddress (), result);
+}
+
+public int isProxy (int[] result) {
+ return COM.VtblCall (7, getAddress (), result);
+}
+
+public int port (int[] result) {
+ return COM.VtblCall (8, getAddress (), result);
+}
+
+public int realm (int /*long*/[] result) {
+ return COM.VtblCall (11, getAddress (), result);
+}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLRequest.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLRequest.java
index 4497bfda3b..a50df25b42 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLRequest.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLRequest.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebURLRequest extends IUnknown {
@@ -18,20 +19,20 @@ public IWebURLRequest (int /*long*/ address) {
super (address);
}
-public int HTTPBody (int /*long*/ []result) {
- return COM.VtblCall (6, getAddress (), result);
-}
+//public int HTTPBody (int /*long*/[] result) {
+// return COM.VtblCall (6, getAddress (), result);
+//}
-public int HTTPMethod (int /*long*/ []result) {
+public int HTTPMethod (int /*long*/[] result) {
return COM.VtblCall (8, getAddress (), result);
}
-public int mutableCopy (int /*long*/ []result) {
- return COM.VtblCall (16, getAddress (), result);
+public int URL (int /*long*/[] result) {
+ return COM.VtblCall (13, getAddress (), result);
}
-public int URL (int /*long*/ []result) {
- return COM.VtblCall (13, getAddress (), result);
+public int mutableCopy (int /*long*/[] result) {
+ return COM.VtblCall (16, getAddress (), result);
}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLResponse.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLResponse.java
index 901031070e..8476e88a26 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLResponse.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebURLResponse.java
@@ -10,24 +10,21 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebURLResponse extends IUnknown {
- public IWebURLResponse (int /*long*/ address) {
- super(address);
- }
-
- public int expectedContentLength (long [] result) {
- return COM.VtblCall (3, getAddress (), result);
- }
-
- public int suggestedFilename (int /*long*/ []result) {
- return COM.VtblCall (8, getAddress (), result);
- }
-
- public int URL (int /*long*/ []result) {
- return COM.VtblCall (8, getAddress (), result);
- }
+public IWebURLResponse (int /*long*/ address) {
+ super (address);
+}
+
+public int expectedContentLength (long[] result) {
+ return COM.VtblCall (3, getAddress (), result);
+}
+
+public int URL (int /*long*/[] result) {
+ return COM.VtblCall (8, getAddress (), result);
+}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebView.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebView.java
index 8b3426f5b5..a31fdf4ff7 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebView.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebView.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
import org.eclipse.swt.internal.win32.*;
@@ -19,80 +20,72 @@ public IWebView (int /*long*/ address) {
super (address);
}
-public int canShowMIMEType (int /*long*/mimeType, int /*long*/ [] canShow) {
- return COM.VtblCall(3, getAddress(), mimeType, canShow);
+public int canShowMIMEType (int /*long*/ mimeType, int[] canShow) {
+ return COM.VtblCall (3, getAddress (), mimeType, canShow);
}
-public int close () {
- return COM.VtblCall(70, getAddress());
-}
-
-public int estimatedProgress (int /*long*/ estimatedProgress) {
- return COM.VtblCall (51, getAddress (), estimatedProgress);
+public int initWithFrame (RECT frame, int /*long*/ frameName, int /*long*/ groupName) {
+ return COM.VtblCall (9, getAddress(), frame, frameName, groupName);
}
-public int goBack (int /*long*/[] succeeded) {
- return COM.VtblCall(24, getAddress(), succeeded);
+public int setUIDelegate (int /*long*/ delegate) {
+ return COM.VtblCall (10, getAddress (), delegate);
}
-public int goForward (int /*long*/[] succeeded) {
- return COM.VtblCall(25, getAddress(), succeeded);
+public int setResourceLoadDelegate (int /*long*/ delegate) {
+ return COM.VtblCall (12, getAddress (), delegate);
}
-public int hostWindow (int /*long*/[] window) {
- return COM.VtblCall (46, getAddress (), window);
+public int setDownloadDelegate (int /*long*/ delegate) {
+ return COM.VtblCall (14, getAddress (), delegate);
}
-public int initWithFrame (RECT frame, int /*long*/ frameName, int /*long*/ groupName) {
- return COM.VtblCall (9, getAddress(), frame, frameName, groupName);
+public int setFrameLoadDelegate (int /*long*/ delegate) {
+ return COM.VtblCall (16, getAddress (), delegate);
}
-public int isLoading (int /*long*/[] isLoading) {
- return COM.VtblCall (52, getAddress (), isLoading);
+public int setPolicyDelegate (int /*long*/ delegate) {
+ return COM.VtblCall (18, getAddress (), delegate);
}
public int mainFrame (int /*long*/[] frame) {
return COM.VtblCall (20, getAddress (), frame);
}
-public int preferences (int /*long*/[] prefs) {
- return COM.VtblCall (42, getAddress (), prefs);
+public int goBack (int[] succeeded) {
+ return COM.VtblCall (24, getAddress(), succeeded);
+}
+
+public int goForward (int[] succeeded) {
+ return COM.VtblCall (25, getAddress(), succeeded);
}
-public int setCustomUserAgent(int /*long*/ valueString) {
+public int setCustomUserAgent (int /*long*/ valueString) {
return COM.VtblCall (31, getAddress (), valueString);
}
-public int setDownloadDelegate (int /*long*/ delegate) {
- return COM.VtblCall (14, getAddress (), delegate);
+public int setPreferences (int /*long*/ prefs) {
+ return COM.VtblCall (41, getAddress (), prefs);
}
-public int setFrameLoadDelegate (int /*long*/ delegate) {
- return COM.VtblCall (16, getAddress (), delegate);
+public int preferences (int /*long*/[] prefs) {
+ return COM.VtblCall (42, getAddress (), prefs);
}
public int setHostWindow (int /*long*/ window) {
return COM.VtblCall (45, getAddress (), window);
}
-public int setPolicyDelegate (int /*long*/ delegate) {
- return COM.VtblCall (18, getAddress (), delegate);
-}
-
-public int setPreferences (int /*long*/ prefs) {
- return COM.VtblCall (41, getAddress (), prefs);
-}
-
-public int setResourceLoadDelegate (int /*long*/ delegate) {
- return COM.VtblCall (12, getAddress (), delegate);
+public int hostWindow (int /*long*/[] window) {
+ return COM.VtblCall (46, getAddress (), window);
}
-public int setUIDelegate (int /*long*/ delegate) {
- return COM.VtblCall (10, getAddress (), delegate);
+public int estimatedProgress (int /*long*/ estimatedProgress) {
+ return COM.VtblCall (51, getAddress (), estimatedProgress);
}
-public int stringByEvaluatingJavaScriptFromString(int /*long*/ script, int /*long*/ [] result) {
- return COM.VtblCall(39, getAddress (), script, result);
+public int close () {
+ return COM.VtblCall(70, getAddress());
}
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebViewPrivate.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebViewPrivate.java
index e04afc5635..c27eef926d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebViewPrivate.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/IWebViewPrivate.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.swt.internal.webkit;
+
import org.eclipse.swt.internal.ole.win32.*;
public class IWebViewPrivate extends IUnknown {
@@ -18,28 +19,16 @@ public IWebViewPrivate (int /*long*/ address) {
super (address);
}
-public int clearFocusNode () {
- return COM.VtblCall (27, getAddress ());
+public int viewWindow (int /*long*/[] window) {
+ return COM.VtblCall (5, getAddress (), window);
}
-public int setInitialFocus(boolean forwardEnabled) {
+public int setInitialFocus (int forwardEnabled) {
return COM.VtblCall (28, getAddress (), forwardEnabled);
}
-public int setTabKeyCyclesThroughElements(boolean cycles) {
- return COM.VtblCall (21, getAddress (), cycles);
-}
-
-public int shouldClose (int /*long*/[] result) {
+public int shouldClose (int[] result) {
return COM.VtblCall (33, getAddress (), result);
}
-public int tabKeyCyclesThroughElements (int /*long*/[] result) {
- return COM.VtblCall (22, getAddress (), result);
-}
-
-public int viewWindow (int /*long*/[] window) {
- return COM.VtblCall (5, getAddress (), window);
-}
-
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/WebKit_win32.java b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/WebKit_win32.java
index 7ca185c979..fceb3095ed 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/WebKit_win32.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT WebKit/win32/org/eclipse/swt/internal/webkit/WebKit_win32.java
@@ -16,16 +16,16 @@ import org.eclipse.swt.internal.win32.*;
/** @jniclass flags=cpp */
public class WebKit_win32 extends C {
- public static final GUID CLSID_DOMEventListener = IIDFromString("{AC3D1BC3-4976-4431-8A19-4812C5EFE39C}"); //$NON-NLS-1$
+ //public static final GUID CLSID_DOMEventListener = IIDFromString("{AC3D1BC3-4976-4431-8A19-4812C5EFE39C}"); //$NON-NLS-1$
public static final GUID CLSID_WebCookieManager = IIDFromString("{3F35F332-BB2B-49b3-AEDD-27B317687E07}"); //$NON-NLS-1$
public static final GUID CLSID_WebMutableURLRequest = IIDFromString("{a062ecc3-bb1b-4694-a569-f59e0ad6be0c}"); //$NON-NLS-1$
public static final GUID CLSID_WebPreferences = IIDFromString("{67B89F90-F778-438B-ABBF-34D1ACBF8651}"); //$NON-NLS-1$
- public static final GUID CLSID_WebScrollBar = IIDFromString("{24A53AD5-AA9F-44e6-AA22-2C7C250B661A}"); //$NON-NLS-1$
- public static final GUID CLSID_IWebURLCredential = IIDFromString("{7433F53B-7FE9-484a-9432-72909457A646}"); //$NON-NLS-1$
+ public static final GUID CLSID_WebURLCredential = IIDFromString("{7433F53B-7FE9-484a-9432-72909457A646}"); //$NON-NLS-1$
public static final GUID CLSID_WebView = IIDFromString("{d6bca079-f61c-4e1e-b453-32a0477d02e3}"); //$NON-NLS-1$
- public static final GUID IID_IDOMEventListener = IIDFromString("{7f8a0a96-f864-44fb-87fb-c5f03666e8e6}"); //$NON-NLS-1$
- public static final GUID IID_IWebDownloadDelegate = IIDFromString("{16A32AE6-C862-40cd-9225-2CAF823F40F9}"); //$NON-NLS-1$
+ //public static final GUID IID_IDOMEventListener = IIDFromString("{7f8a0a96-f864-44fb-87fb-c5f03666e8e6}"); //$NON-NLS-1$
public static final GUID IID_IWebCookieManager = IIDFromString("{7053FE94-3623-444f-A298-209A90879A8C}"); //$NON-NLS-1$
+ public static final GUID IID_IWebDownloadDelegate = IIDFromString("{16A32AE6-C862-40cd-9225-2CAF823F40F9}"); //$NON-NLS-1$
+ public static final GUID IID_IWebErrorPrivate = IIDFromString("{19FED49C-7016-48a6-B5C6-07ADE116531B}"); //$NON-NLS-1$
public static final GUID IID_IWebFrameLoadDelegate = IIDFromString("{3354665B-84BA-4fdf-B35E-BF5CF9D96026}"); //$NON-NLS-1$
public static final GUID IID_IWebFramePrivate = IIDFromString("{A1657D07-4881-4475-9D10-76548731D448}"); //$NON-NLS-1$
public static final GUID IID_IWebIBActions = IIDFromString("{8F0E3A30-B924-44f8-990A-1AE61ED6C632}"); //$NON-NLS-1$
@@ -34,11 +34,10 @@ public class WebKit_win32 extends C {
public static final GUID IID_IWebPolicyDelegate = IIDFromString("{9B0BAE6C-A496-4000-9E22-2E89F0747401}"); //$NON-NLS-1$
public static final GUID IID_IWebPreferences = IIDFromString("{0930D594-A5A3-46e1-858E-AB17A13CD28E}"); //$NON-NLS-1$
public static final GUID IID_IWebResourceLoadDelegate = IIDFromString("{AF3289AA-90DB-4ca4-A112-A1E5F0517953}"); //$NON-NLS-1$
- public static final GUID IID_IWebScrollBarPrivate = IIDFromString("{6C585B08-2E4F-4594-9B90-0425E3A33FD0}"); //$NON-NLS-1$
public static final GUID IID_IWebUIDelegate = IIDFromString("{042B7EE3-A5A4-4a8f-8C33-775CD9E89C7C}"); //$NON-NLS-1$
+ public static final GUID IID_IWebURLCredential = IIDFromString("{A1E9D765-FACE-4189-BBE3-AED7EBF65EBD}"); //$NON-NLS-1$
public static final GUID IID_IWebView = IIDFromString("{174BBEFD-058E-49C7-91DF-6F110AA4AC28}"); //$NON-NLS-1$
public static final GUID IID_IWebViewPrivate = IIDFromString("{44914369-DEB5-4fcf-A6A3-30C02E73154F}"); //$NON-NLS-1$
- public static final GUID IID_IWebURLCredential = IIDFromString("{A1E9D765-FACE-4189-BBE3-AED7EBF65EBD}"); //$NON-NLS-1$
public static final int CFHTTPCookieSessionOnlyFlag = 1 << 1;
public static final int FontSmoothingTypeWindows = 4;
@@ -56,135 +55,138 @@ public class WebKit_win32 extends C {
public static final int WebURLErrorServerCertificateNotYetValid = -1204;
public static final int WebURLErrorSecureConnectionFailed = -1200;
+static GUID IIDFromString (String lpsz) {
+ int length = lpsz.length ();
+ char[] buffer = new char[length + 1];
+ lpsz.getChars (0, length, buffer, 0);
+ GUID lpiid = new GUID ();
+ if (COM.IIDFromString (buffer, lpiid) == COM.S_OK) return lpiid;
+ return null;
+}
+
/**
* @param theArray cast=(CFArrayRef)
*/
-public static final native int CFArrayGetCount(int /*long*/ theArray);
+public static final native int CFArrayGetCount (int /*long*/ theArray);
/**
* @param theArray cast=(CFArrayRef)
* @param idx cast=(CFIndex)
*/
-public static final native int /*long*/ CFArrayGetValueAtIndex(int /*long*/ theArray, int idx);
+public static final native int /*long*/ CFArrayGetValueAtIndex (int /*long*/ theArray, int idx);
/**
* @param allocator cast=(CFAllocatorRef)
* @param bytes cast=(const UInt8 *)
* @param length cast=(CFIndex)
*/
-public static final native int /*long*/ CFDataCreate(int allocator, byte [] bytes, int length);
+public static final native int /*long*/ CFDataCreate (int /*long*/ allocator, byte [] bytes, int length);
/**
* @param theData cast=(CFDataRef)
*/
-public static final native int /*long*/ CFDataGetBytePtr(int /*long*/ theData);
+public static final native int /*long*/ CFDataGetBytePtr (int /*long*/ theData);
/**
* @param theData cast=(CFDataRef)
*/
-public static final native int CFDataGetLength(int /*long*/ theData);
+public static final native int CFDataGetLength (int /*long*/ theData);
/**
* @param allocator cast=(CFAllocatorRef)
- * @param keys cast=(const void **)
- * @param values cast=(const void **)
- * @param numValues cast=(CFIndex)
- * @param keyCallBacks cast=(const CFDictionaryKeyCallBacks *)
- * @param valueCallBacks cast=(const CFDictionaryValueCallBacks *)
+ * @param keys cast=(const void **)
+ * @param values cast=(const void **)
+ * @param numValues cast=(CFIndex)
+ * @param keyCallBacks cast=(const CFDictionaryKeyCallBacks *)
+ * @param valueCallBacks cast=(const CFDictionaryValueCallBacks *)
*/
-public static final native int /*long*/ CFDictionaryCreate(int allocator, int /*long*/ [] keys, int /*long*/ [] values, int numValues, int /*long*/ keyCallBacks, int /*long*/ valueCallBacks);
-/**
- * @param dictionary cast=(CFDictionaryRef)
- */
-public static final native int CFDictionaryGetCount(int /*long*/ dictionary);
+public static final native int /*long*/ CFDictionaryCreate (int /*long*/ allocator, int /*long*/[] keys, int /*long*/[] values, int numValues, int /*long*/ keyCallBacks, int /*long*/ valueCallBacks);
/**
* @param inAllocator cast=(CFAllocatorRef)
* @param headerFields cast=(CFDictionaryRef)
* @param inURL cast=(CFURLRef)
*/
-public static final native int /*long*/ CFHTTPCookieCreateWithResponseHeaderFields(int inAllocator, int /*long*/ headerFields, int /*long*/ inURL);
+public static final native int /*long*/ CFHTTPCookieCreateWithResponseHeaderFields (int /*long*/ inAllocator, int /*long*/ headerFields, int /*long*/ inURL);
/**
* @param inCookie cast=(CFHTTPCookieRef)
*/
-public static final native int /*long*/ CFHTTPCookieGetFlags(int /*long*/ inCookie);
+public static final native int CFHTTPCookieGetFlags (int /*long*/ inCookie);
/**
* @param inCookie cast=(CFHTTPCookieRef)
*/
-public static final native int /*long*/ CFHTTPCookieGetName(int /*long*/ inCookie);
+public static final native int /*long*/ CFHTTPCookieGetName (int /*long*/ inCookie);
/**
* @param inCookie cast=(CFHTTPCookieRef)
*/
-public static final native int /*long*/ CFHTTPCookieGetValue(int /*long*/ inCookie);
+public static final native int /*long*/ CFHTTPCookieGetValue (int /*long*/ inCookie);
/**
* @param inCookieStorage cast=(CFHTTPCookieStorageRef)
*/
-public static final native int /*long*/ CFHTTPCookieStorageCopyCookies(int /*long*/ inCookieStorage);
+public static final native int /*long*/ CFHTTPCookieStorageCopyCookies (int /*long*/ inCookieStorage);
/**
* @param inCookieStorage cast=(CFHTTPCookieStorageRef)
* @param inURL cast=(CFURLRef)
* @param sendSecureCookies cast=(Boolean)
*/
-public static final native int /*long*/ CFHTTPCookieStorageCopyCookiesForURL(int /*long*/ inCookieStorage,int /*long*/ inURL, boolean sendSecureCookies);
+public static final native int /*long*/ CFHTTPCookieStorageCopyCookiesForURL (int /*long*/ inCookieStorage, int /*long*/ inURL, boolean sendSecureCookies);
/**
* @param inCookieStorage cast=(CFHTTPCookieStorageRef)
* @param inCookie cast=(CFHTTPCookieRef)
*/
-public static final native void CFHTTPCookieStorageDeleteCookie(int /*long*/ inCookieStorage, int /*long*/ inCookie);
+public static final native void CFHTTPCookieStorageDeleteCookie (int /*long*/ inCookieStorage, int /*long*/ inCookie);
/**
* @param inCookieStorage cast=(CFHTTPCookieStorageRef)
* @param inCookie cast=(CFHTTPCookieRef)
*/
-public static final native void CFHTTPCookieStorageSetCookie(int /*long*/ inCookieStorage, int /*long*/ inCookie);
-/**
- * @param cf cast=(CFTypeRef)
- */
-public static final native void CFRelease(int /*long*/ cf);
+public static final native void CFHTTPCookieStorageSetCookie (int /*long*/ inCookieStorage, int /*long*/ inCookie);
/**
* @param cf cast=(CFTypeRef)
*/
-public static final native int CFRetain(int /*long*/ cf);
+public static final native void CFRelease (int /*long*/ cf);
/**
* @param alloc cast=(CFAllocatorRef)
- * @param chars cast=(const UniChar *)
- * @param numChars cast=(CFIndex)
+ * @param chars cast=(const UniChar *)
+ * @param numChars cast=(CFIndex)
*/
-public static final native int CFStringCreateWithCharacters(int /*long*/ alloc, char [] chars, int numChars);
+public static final native int CFStringCreateWithCharacters (int /*long*/ alloc, char[] chars, int numChars);
/**
* @param theString cast=(CFStringRef)
* @param idx cast=(CFIndex)
*/
-public static final native char CFStringGetCharacterAtIndex(int /*long*/ theString, int idx);
+public static final native char CFStringGetCharacterAtIndex (int /*long*/ theString, int idx);
/**
* @param theString cast=(CFStringRef)
*/
-public static final native int /*long*/ CFStringGetCharactersPtr(int /*long*/ theString);
+public static final native int /*long*/ CFStringGetCharactersPtr (int /*long*/ theString);
/**
* @param theString cast=(CFStringRef)
*/
-public static final native int CFStringGetLength(int /*long*/ theString);
+public static final native int CFStringGetLength (int /*long*/ theString);
/**
* @param allocator cast=(CFAllocatorRef)
- * @param URLString cast=(CFStringRef)
- * @param baseURL cast=(CFURLRef)
+ * @param URLString cast=(CFStringRef)
+ * @param baseURL cast=(CFURLRef)
+ */
+public static final native int /*long*/ CFURLCreateWithString (int /*long*/ allocator, int /*long*/ URLString, int /*long*/ baseURL);
+/**
+ * @param alloc cast=(CFAllocatorRef)
+ * @param origRequest cast=(CFURLRequestRef)
*/
-public static final native int /*long*/ CFURLCreateWithString(int allocator, int /*long*/ URLString, int /*long*/ baseURL);
+public static final native int /*long*/ CFURLRequestCreateMutableCopy (int /*long*/ alloc, int /*long*/ origRequest);
/**
* @param request cast=(CFURLRequestRef)
*/
-public static final native int /*long*/ CFURLRequestCopyHTTPRequestBody(int /*long*/ request);
+public static final native int /*long*/ CFURLRequestCopyHTTPRequestBody (int /*long*/ request);
/**
* @param mutableHTTPRequest cast=(CFMutableURLRequestRef)
* @param httpBody cast=(CFDataRef)
*/
-public static final native void CFURLRequestSetHTTPRequestBody(int /*long*/ mutableHTTPRequest, int /*long*/ httpBody);
-static GUID IIDFromString (String lpsz) {
- int length = lpsz.length ();
- char[] buffer = new char[length + 1];
- lpsz.getChars (0, length, buffer, 0);
- GUID lpiid = new GUID ();
- if (COM.IIDFromString (buffer, lpiid) == COM.S_OK) return lpiid;
- return null;
-}
+public static final native void CFURLRequestSetHTTPRequestBody (int /*long*/ mutableHTTPRequest, int /*long*/ httpBody);
+/**
+ * @param mutableRequest cast=(CFMutableURLRequestRef)
+ * @param url cast=(CFURLRef)
+ */
+public static final native void CFURLRequestSetURL (int /*long*/ mutableRequest, int /*long*/ url);
+
/**
* @param definition cast=(const JSClassDefinition*)
*/
public static final native int /*long*/ JSClassCreate (int /*long*/ definition);
-public static final native int JSClassDefinition_sizeof ();
/**
* @param jsClass cast=(JSClassRef)
*/
@@ -192,7 +194,7 @@ public static final native int /*long*/ JSClassRetain (int /*long*/ jsClass);
/**
* @param ctx cast=(JSContextRef)
*/
-public static final native int /*long*/ JSContextGetGlobalObject(int /*long*/ ctx);
+public static final native int /*long*/ JSContextGetGlobalObject (int /*long*/ ctx);
/**
* @param ctx cast=(JSContextRef)
* @param script cast=(JSStringRef)
@@ -200,17 +202,11 @@ public static final native int /*long*/ JSContextGetGlobalObject(int /*long*/ ct
* @param sourceURL cast=(JSStringRef)
* @param exception cast=(JSValueRef *)
*/
-public static final native int /*long*/ JSEvaluateScript(int /*long*/ ctx, int /*long*/ script, int /*long*/ thisObject, int /*long*/ sourceURL, int startingLineNumber, int /*long*/[] exception);
-/**
- * @param globalObjectClass cast=(JSClassRef)
- */
-public static final native int /*long*/ JSGlobalContextCreate(int /*long*/ globalObjectClass);
+public static final native int /*long*/ JSEvaluateScript (int /*long*/ ctx, int /*long*/ script, int /*long*/ thisObject, int /*long*/ sourceURL, int startingLineNumber, int /*long*/[] exception);
/**
* @param ctx cast=(JSGlobalContextRef)
*/
-public static final native int JSGlobalContextRetain(int /*long*/ ctx);
-/** @method flags=no_gen */
-public static final native int /*long*/ JSObjectCallAsFunctionProc_CALLBACK (int /*long*/ func);
+public static final native int JSGlobalContextRetain (int /*long*/ ctx);
/**
* @param object cast=(JSObjectRef)
*/
@@ -229,21 +225,12 @@ public static final native int /*long*/ JSObjectGetProperty (int /*long*/ ctx, i
* @param exception cast=(JSValueRef*)
*/
public static final native int /*long*/ JSObjectGetPropertyAtIndex (int /*long*/ ctx, int /*long*/ object, int propertyIndex, int /*long*/[] exception);
-/** @method flags=no_gen */
-public static final native int /*long*/ JSObjectGetPropertyProc_CALLBACK (int /*long*/ func);
-/** @method flags=no_gen */
-public static final native int /*long*/ JSObjectHasPropertyProc_CALLBACK (int /*long*/ func);
-/**
- * @param ctx cast=(JSContextRef)
- * @param object cast=(JSObjectRef)
- */
-public static final native int JSObjectIsFunction(int /*long*/ ctx, int /*long*/ object);
/**
* @param ctx cast=(JSContextRef)
* @param jsClass cast=(JSClassRef)
* @param data cast=(void *)
*/
-public static final native int JSObjectMake(int /*long*/ ctx, int /*long*/ jsClass, int /*long*/ data);
+public static final native int JSObjectMake (int /*long*/ ctx, int /*long*/ jsClass, int /*long*/ data);
/**
* @param ctx cast=(JSContextRef)
* @param argumentCount cast=(size_t)
@@ -256,7 +243,7 @@ public static final native int /*long*/ JSObjectMakeArray (int /*long*/ ctx, int
* @param name cast=(JSStringRef)
* @param callAsFunction cast=(JSObjectCallAsFunctionCallback)
*/
-public static final native int JSObjectMakeFunctionWithCallback(int /*long*/ ctx, int /*long*/ name, int /*long*/ callAsFunction);
+public static final native int JSObjectMakeFunctionWithCallback (int /*long*/ ctx, int /*long*/ name, int /*long*/ callAsFunction);
/**
* @param ctx cast=(JSContextRef)
* @param object cast=(JSObjectRef)
@@ -265,15 +252,15 @@ public static final native int JSObjectMakeFunctionWithCallback(int /*long*/ ctx
* @param attributes cast=(JSPropertyAttributes)
* @param exception cast=(JSValueRef *)
*/
-public static final native void JSObjectSetProperty(int /*long*/ ctx, int /*long*/ object, int /*long*/ propertyName, int /*long*/ value, int /*long*/ attributes, int /*long*/[] exception);
+public static final native void JSObjectSetProperty (int /*long*/ ctx, int /*long*/ object, int /*long*/ propertyName, int /*long*/ value, int /*long*/ attributes, int /*long*/[] exception);
/**
* @param string cast=(const char*)
*/
-public static final native int /*long*/ JSStringCreateWithUTF8CString(byte[] string);
+public static final native int /*long*/ JSStringCreateWithUTF8CString (byte[] string);
/**
* @param string cast=(JSStringRef)
*/
-public static final native int JSStringGetLength(int /*long*/ string);
+public static final native int JSStringGetLength (int /*long*/ string);
/**
* @param string cast=(JSStringRef)
*/
@@ -282,9 +269,8 @@ public static final native int /*long*/ JSStringGetMaximumUTF8CStringSize (int /
* @param string cast=(JSStringRef)
* @param buffer cast=(char *)
* @param bufferSize cast=(size_t)
- * @return
*/
-public static final native int JSStringGetUTF8CString(int /*long*/ string, byte[] buffer, int /*long*/ bufferSize);
+public static final native int JSStringGetUTF8CString (int /*long*/ string, byte[] buffer, int /*long*/ bufferSize);
/**
* @param a cast=(JSStringRef)
* @param b cast=(const char *)
@@ -293,12 +279,12 @@ public static final native int JSStringIsEqualToUTF8CString (int /*long*/ a, byt
/**
* @param string cast=(JSStringRef)
*/
-public static final native void JSStringRelease(int /*long*/ string);
+public static final native void JSStringRelease (int /*long*/ string);
/**
* @param ctx cast=(JSContextRef)
* @param value cast=(JSValueRef)
*/
-public static final native int JSValueGetType(int /*long*/ ctx, int /*long*/ value);
+public static final native int JSValueGetType (int /*long*/ ctx, int /*long*/ value);
/**
* @param ctx cast=(JSContextRef)
* @param value cast=(JSValueRef)
@@ -309,21 +295,21 @@ public static final native int JSValueIsObjectOfClass (int /*long*/ ctx, int /*l
* @param ctx cast=(JSContextRef)
* @param b cast=(bool)
*/
-public static final native int /*long*/ JSValueMakeBoolean(int /*long*/ ctx, int /*long*/ b);
+public static final native int /*long*/ JSValueMakeBoolean (int /*long*/ ctx, int /*long*/ b);
/**
* @param ctx cast=(JSContextRef)
*/
-public static final native int /*long*/ JSValueMakeNull(int /*long*/ ctx);
+public static final native int /*long*/ JSValueMakeNull (int /*long*/ ctx);
/**
* @param ctx cast=(JSContextRef)
* @param number cast=(double)
*/
-public static final native int /*long*/ JSValueMakeNumber(int /*long*/ ctx, double number);
+public static final native int /*long*/ JSValueMakeNumber (int /*long*/ ctx, double number);
/**
* @param ctx cast=(JSContextRef)
* @param string cast=(JSStringRef)
*/
-public static final native int /*long*/ JSValueMakeString(int /*long*/ ctx, int /*long*/ string);
+public static final native int /*long*/ JSValueMakeString (int /*long*/ ctx, int /*long*/ string);
/**
* @param ctx cast=(JSContextRef)
*/
@@ -332,11 +318,6 @@ public static final native int /*long*/ JSValueMakeUndefined (int /*long*/ ctx);
* @param ctx cast=(JSContextRef)
* @param value cast=(JSValueRef)
*/
-public static final native void JSValueProtect(int /*long*/ ctx, int /*long*/ value);
-/**
- * @param ctx cast=(JSContextRef)
- * @param value cast=(JSValueRef)
- */
public static final native int JSValueToBoolean (int /*long*/ ctx, int /*long*/ value);
/**
* @param ctx cast=(JSContextRef)
@@ -351,9 +332,11 @@ public static final native double JSValueToNumber (int /*long*/ ctx, int /*long*
*/
public static final native int /*long*/ JSValueToStringCopy (int /*long*/ ctx, int /*long*/ value, int /*long*/[] exception);
/** @method flags=const address*/
-public static final native int /*long*/ kCFCopyStringDictionaryKeyCallBacks();
+public static final native int /*long*/ kCFCopyStringDictionaryKeyCallBacks ();
/** @method flags=const address*/
-public static final native int /*long*/ kCFTypeDictionaryValueCallBacks();
+public static final native int /*long*/ kCFTypeDictionaryValueCallBacks ();
+
+public static final native int JSClassDefinition_sizeof ();
/**
* @param dest cast=(void *)
* @param src cast=(const void *),flags=no_out
@@ -369,6 +352,14 @@ public static final int WebKitCreateInstance (GUID clsid, int /*long*/ pUnkOuter
OS.IIDFromString ((iid.toString () + '\0').toCharArray (), refiid);
return WebKitCreateInstance (rclsid, pUnkOuter, refiid, ppvObject);
}
-/** @method flags=no_gen */
+
+/** @method flags=no_gen */
+public static final native int /*long*/ JSObjectCallAsFunctionProc_CALLBACK (int /*long*/ func);
+/** @method flags=no_gen */
+public static final native int /*long*/ JSObjectGetPropertyProc_CALLBACK (int /*long*/ func);
+/** @method flags=no_gen */
+public static final native int /*long*/ JSObjectHasPropertyProc_CALLBACK (int /*long*/ func);
+/** @method flags=no_gen */
public static final native int /*long*/ willPerformClientRedirectToURL_CALLBACK (int /*long*/ func);
+
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/SWT.java b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/SWT.java
index 7d4f23c267..775feda005 100755
--- a/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/SWT.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/common/org/eclipse/swt/SWT.java
@@ -2029,6 +2029,16 @@ public class SWT {
*/
public static final int MOZILLA = 1 << 15;
+ /**
+ * Style constant specifying that a Browser should use WebKit
+ * for rendering its content (value is 1&lt;&lt;16).
+ * <p>
+ * <p><b>Used By:</b><ul>
+ * <li><code>Browser</code></li>
+ * </ul></p>
+ *
+ * @since 3.7
+ */
public static final int WEBKIT = 1 << 16;
/**