diff options
author | Grant Gayed <grant_gayed@ca.ibm.com> | 2011-12-19 10:30:39 -0500 |
---|---|---|
committer | Grant Gayed <grant_gayed@ca.ibm.com> | 2012-03-06 16:45:19 -0500 |
commit | 3cdae47da159662ce7eb57e9a6b0f13f94eaec5c (patch) | |
tree | 034bca590f4ae22ed6ffe590072d73e2acdcd174 | |
parent | 852f17f3e885ddde267886a8be3483ac6f27465d (diff) | |
download | eclipse.platform.swt-3cdae47da159662ce7eb57e9a6b0f13f94eaec5c.tar.gz eclipse.platform.swt-3cdae47da159662ce7eb57e9a6b0f13f94eaec5c.tar.xz eclipse.platform.swt-3cdae47da159662ce7eb57e9a6b0f13f94eaec5c.zip |
interface classes updated
101 files changed, 1711 insertions, 3615 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom.cpp b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom.cpp index 9ebb6ef8af..c5276bd3fa 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom.cpp +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom.cpp @@ -261,6 +261,64 @@ JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJF)(JNIEnv *env, jclass that, j } #endif +#if (!defined(NO__1VtblCall__IIFF_3I) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJFF_3I) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIFF_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jfloat arg2, jfloat arg3, jintArray arg4); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIFF_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jfloat arg2, jfloat arg3, jintArray arg4) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJFF_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jfloat arg2, jfloat arg3, jintArray arg4); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJFF_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jfloat arg2, jfloat arg3, jintArray arg4) +#endif +{ + jint *lparg4=NULL; + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIFF_3I_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJFF_3I_FUNC); +#endif + if (arg4) if ((lparg4 = env->GetIntArrayElements(arg4, NULL)) == NULL) goto fail; + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jfloat, jfloat, jint *))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, lparg4); +fail: + if (arg4 && lparg4) env->ReleaseIntArrayElements(arg4, lparg4, 0); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIFF_3I_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJFF_3I_FUNC); +#endif + return rc; +} +#endif + +#if (!defined(NO__1VtblCall__IIFF_3J) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJFF_3J) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIFF_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jfloat arg2, jfloat arg3, jlongArray arg4); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIFF_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jfloat arg2, jfloat arg3, jlongArray arg4) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJFF_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jfloat arg2, jfloat arg3, jlongArray arg4); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJFF_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jfloat arg2, jfloat arg3, jlongArray arg4) +#endif +{ + jlong *lparg4=NULL; + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIFF_3J_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJFF_3J_FUNC); +#endif + if (arg4) if ((lparg4 = env->GetLongArrayElements(arg4, NULL)) == NULL) goto fail; + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jfloat, jfloat, jlong *))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, lparg4); +fail: + if (arg4 && lparg4) env->ReleaseLongArrayElements(arg4, lparg4, 0); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIFF_3J_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJFF_3J_FUNC); +#endif + return rc; +} +#endif + #if (!defined(NO__1VtblCall__III) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJI) && defined(JNI64)) #ifndef JNI64 extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__III)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2); @@ -933,6 +991,31 @@ JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJIIJJJJ)(JNIEnv *env, jclass th } #endif +#if (!defined(NO__1VtblCall__IIIIS) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJIIS) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIIIS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jint arg3, jshort arg4); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIIIS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jint arg3, jshort arg4) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJIIS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jint arg3, jshort arg4); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJIIS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jint arg3, jshort arg4) +#endif +{ + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIIIS_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJIIS_FUNC); +#endif + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jint, jint, jshort))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, arg4); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIIIS_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJIIS_FUNC); +#endif + return rc; +} +#endif + #if (!defined(NO__1VtblCall__IIII_3B) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJII_3B) && defined(JNI64)) #ifndef JNI64 extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIII_3B)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jint arg3, jbyteArray arg4); @@ -2299,6 +2382,35 @@ fail: } #endif +#if (!defined(NO__1VtblCall__III_3S) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJI_3S) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__III_3S)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jshortArray arg3); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__III_3S)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jshortArray arg3) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJI_3S)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jshortArray arg3); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJI_3S)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jint arg2, jshortArray arg3) +#endif +{ + jshort *lparg3=NULL; + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__III_3S_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJI_3S_FUNC); +#endif + if (arg3) if ((lparg3 = env->GetShortArrayElements(arg3, NULL)) == NULL) goto fail; + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jint, jshort *))(*(jintLong **)arg1)[arg0])(arg1, arg2, lparg3); +fail: + if (arg3 && lparg3) env->ReleaseShortArrayElements(arg3, lparg3, 0); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__III_3S_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJI_3S_FUNC); +#endif + return rc; +} +#endif + #if (!defined(NO__1VtblCall__IIJ) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJ) && defined(JNI64)) #ifndef JNI64 extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2); @@ -2349,6 +2461,85 @@ JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJI)(JNIEnv *env, jclass that, } #endif +#if (!defined(NO__1VtblCall__IIJII) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJII) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJII)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJII)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJII)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJII)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4) +#endif +{ + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIJII_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJJII_FUNC); +#endif + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jint, jint))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, arg4); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIJII_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJJII_FUNC); +#endif + return rc; +} +#endif + +#if (!defined(NO__1VtblCall__IIJIIIIII_3I) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJIIIIII_3I) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJIIIIII_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4, jint arg5, jint arg6, jint arg7, jint arg8, jintArray arg9); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJIIIIII_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4, jint arg5, jint arg6, jint arg7, jint arg8, jintArray arg9) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJIIIIII_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4, jint arg5, jint arg6, jint arg7, jint arg8, jintArray arg9); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJIIIIII_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4, jint arg5, jint arg6, jint arg7, jint arg8, jintArray arg9) +#endif +{ + jint *lparg9=NULL; + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIJIIIIII_3I_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJJIIIIII_3I_FUNC); +#endif + if (arg9) if ((lparg9 = env->GetIntArrayElements(arg9, NULL)) == NULL) goto fail; + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jint, jint, jint, jint, jint, jint, jint *))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, lparg9); +fail: + if (arg9 && lparg9) env->ReleaseIntArrayElements(arg9, lparg9, 0); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIJIIIIII_3I_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJJIIIIII_3I_FUNC); +#endif + return rc; +} +#endif + +#if (!defined(NO__1VtblCall__IIJIIJI) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJIIJI) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJIIJI)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4, jlong arg5, jint arg6); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJIIJI)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4, jlong arg5, jint arg6) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJIIJI)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4, jlong arg5, jint arg6); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJIIJI)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4, jlong arg5, jint arg6) +#endif +{ + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIJIIJI_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJJIIJI_FUNC); +#endif + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jint, jint, jlong, jint))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, arg4, arg5, arg6); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIJIIJI_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJJIIJI_FUNC); +#endif + return rc; +} +#endif + #if (!defined(NO__1VtblCall__IIJIIJIIIIII) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJIIJIIIIII) && defined(JNI64)) #ifndef JNI64 extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJIIJIIIIII)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jint arg4, jlong arg5, jint arg6, jint arg7, jint arg8, jint arg9, jint arg10, jint arg11); @@ -2485,6 +2676,35 @@ JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJIJII)(JNIEnv *env, jclass tha } #endif +#if (!defined(NO__1VtblCall__IIJIJI_3J) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJIJI_3J) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJIJI_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jlong arg4, jint arg5, jlongArray arg6); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJIJI_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jlong arg4, jint arg5, jlongArray arg6) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJIJI_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jlong arg4, jint arg5, jlongArray arg6); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJIJI_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jlong arg4, jint arg5, jlongArray arg6) +#endif +{ + jlong *lparg6=NULL; + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIJIJI_3J_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJJIJI_3J_FUNC); +#endif + if (arg6) if ((lparg6 = env->GetLongArrayElements(arg6, NULL)) == NULL) goto fail; + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jint, jlong, jint, jlong *))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, arg4, arg5, lparg6); +fail: + if (arg6 && lparg6) env->ReleaseLongArrayElements(arg6, lparg6, 0); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIJIJI_3J_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJJIJI_3J_FUNC); +#endif + return rc; +} +#endif + #if (!defined(NO__1VtblCall__IIJIJJ_3I_3I_3I) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJIJJ_3I_3I_3I) && defined(JNI64)) #ifndef JNI64 extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJIJJ_3I_3I_3I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jint arg3, jlong arg4, jlong arg5, jintArray arg6, jintArray arg7, jintArray arg8); @@ -3100,6 +3320,35 @@ fail: } #endif +#if (!defined(NO__1VtblCall__IIJJJJ_3J) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJJJJ_3J) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJJJJ_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jlong arg4, jlong arg5, jlongArray arg6); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJJJJ_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jlong arg4, jlong arg5, jlongArray arg6) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJJJJ_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jlong arg4, jlong arg5, jlongArray arg6); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJJJJ_3J)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jlong arg4, jlong arg5, jlongArray arg6) +#endif +{ + jlong *lparg6=NULL; + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIJJJJ_3J_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJJJJJ_3J_FUNC); +#endif + if (arg6) if ((lparg6 = env->GetLongArrayElements(arg6, NULL)) == NULL) goto fail; + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jlong, jlong, jlong, jlong *))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, arg4, arg5, lparg6); +fail: + if (arg6 && lparg6) env->ReleaseLongArrayElements(arg6, lparg6, 0); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIJJJJ_3J_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJJJJJ_3J_FUNC); +#endif + return rc; +} +#endif + #if (!defined(NO__1VtblCall__IIJJJ_3B_3BJ) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJJJ_3B_3BJ) && defined(JNI64)) #ifndef JNI64 extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJJJ_3B_3BJ)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jlong arg4, jbyteArray arg5, jbyteArray arg6, jlong arg7); @@ -3190,6 +3439,31 @@ fail: } #endif +#if (!defined(NO__1VtblCall__IIJJS) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJJS) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJJS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jshort arg4); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJJS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jshort arg4) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJJS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jshort arg4); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJJS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jshort arg4) +#endif +{ + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIJJS_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJJJS_FUNC); +#endif + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jlong, jshort))(*(jintLong **)arg1)[arg0])(arg1, arg2, arg3, arg4); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIJJS_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJJJS_FUNC); +#endif + return rc; +} +#endif + #if (!defined(NO__1VtblCall__IIJJ_3B) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJJ_3B) && defined(JNI64)) #ifndef JNI64 extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJJ_3B)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jlong arg3, jbyteArray arg4); @@ -4285,6 +4559,35 @@ fail: } #endif +#if (!defined(NO__1VtblCall__IIJ_3S) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJJ_3S) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJ_3S)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jshortArray arg3); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIJ_3S)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jshortArray arg3) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJ_3S)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jshortArray arg3); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJJ_3S)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jlong arg2, jshortArray arg3) +#endif +{ + jshort *lparg3=NULL; + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIJ_3S_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJJ_3S_FUNC); +#endif + if (arg3) if ((lparg3 = env->GetShortArrayElements(arg3, NULL)) == NULL) goto fail; + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jlong, jshort *))(*(jintLong **)arg1)[arg0])(arg1, arg2, lparg3); +fail: + if (arg3 && lparg3) env->ReleaseShortArrayElements(arg3, lparg3, 0); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIJ_3S_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJJ_3S_FUNC); +#endif + return rc; +} +#endif + #if (!defined(NO__1VtblCall__IILorg_eclipse_swt_internal_mozilla_nsID_2I) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJLorg_eclipse_swt_internal_mozilla_nsID_2I) && defined(JNI64)) #ifndef JNI64 extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IILorg_eclipse_swt_internal_mozilla_nsID_2I)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jobject arg2, jint arg3); @@ -4699,6 +5002,31 @@ fail: } #endif +#if (!defined(NO__1VtblCall__IIS) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJS) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jshort arg2); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IIS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jshort arg2) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jshort arg2); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jshort arg2) +#endif +{ + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IIS_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJS_FUNC); +#endif + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jshort))(*(jintLong **)arg1)[arg0])(arg1, arg2); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IIS_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJS_FUNC); +#endif + return rc; +} +#endif + #if (!defined(NO__1VtblCall__IISIII) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJSIII) && defined(JNI64)) #ifndef JNI64 extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IISIII)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jshort arg2, jint arg3, jint arg4, jint arg5); @@ -5244,6 +5572,35 @@ fail: } #endif +#if (!defined(NO__1VtblCall__II_3BS) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJ_3BS) && defined(JNI64)) +#ifndef JNI64 +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__II_3BS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jshort arg3); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__II_3BS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jshort arg3) +#else +extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJ_3BS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jshort arg3); +JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__IJ_3BS)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jshort arg3) +#endif +{ + jbyte *lparg2=NULL; + jint rc = 0; +#ifndef JNI64 + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__II_3BS_FUNC); +#else + XPCOM_NATIVE_ENTER(env, that, _1VtblCall__IJ_3BS_FUNC); +#endif + if (arg2) if ((lparg2 = env->GetByteArrayElements(arg2, NULL)) == NULL) goto fail; + rc = (jint)((jint (STDMETHODCALLTYPE *)(jintLong, jbyte *, jshort))(*(jintLong **)arg1)[arg0])(arg1, lparg2, arg3); +fail: + if (arg2 && lparg2) env->ReleaseByteArrayElements(arg2, lparg2, 0); +#ifndef JNI64 + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__II_3BS_FUNC); +#else + XPCOM_NATIVE_EXIT(env, that, _1VtblCall__IJ_3BS_FUNC); +#endif + return rc; +} +#endif + #if (!defined(NO__1VtblCall__II_3B_3B) && !defined(JNI64)) || (!defined(NO__1VtblCall__IJ_3B_3B) && defined(JNI64)) #ifndef JNI64 extern "C" JNIEXPORT jint JNICALL XPCOM_NATIVE(_1VtblCall__II_3B_3B)(JNIEnv *env, jclass that, jint arg0, jintLong arg1, jbyteArray arg2, jbyteArray arg3); diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom_stats.cpp b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom_stats.cpp index f9aa31b99d..c3d7709e76 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom_stats.cpp +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom_stats.cpp @@ -14,8 +14,8 @@ #ifdef NATIVE_STATS -int XPCOM_nativeFunctionCount = 232; -int XPCOM_nativeFunctionCallCount[232]; +int XPCOM_nativeFunctionCount = 245; +int XPCOM_nativeFunctionCallCount[245]; char * XPCOM_nativeFunctionNames[] = { #ifndef JNI64 "_1Call__I", @@ -59,6 +59,16 @@ char * XPCOM_nativeFunctionNames[] = { "_1VtblCall__IJF", #endif #ifndef JNI64 + "_1VtblCall__IIFF_3I", +#else + "_1VtblCall__IJFF_3I", +#endif +#ifndef JNI64 + "_1VtblCall__IIFF_3J", +#else + "_1VtblCall__IJFF_3J", +#endif +#ifndef JNI64 "_1VtblCall__III", #else "_1VtblCall__IJI", @@ -174,6 +184,11 @@ char * XPCOM_nativeFunctionNames[] = { "_1VtblCall__IJIIJJJJ", #endif #ifndef JNI64 + "_1VtblCall__IIIIS", +#else + "_1VtblCall__IJIIS", +#endif +#ifndef JNI64 "_1VtblCall__IIII_3B", #else "_1VtblCall__IJII_3B", @@ -384,6 +399,11 @@ char * XPCOM_nativeFunctionNames[] = { "_1VtblCall__IJI_3J", #endif #ifndef JNI64 + "_1VtblCall__III_3S", +#else + "_1VtblCall__IJI_3S", +#endif +#ifndef JNI64 "_1VtblCall__IIJ", #else "_1VtblCall__IJJ", @@ -394,6 +414,21 @@ char * XPCOM_nativeFunctionNames[] = { "_1VtblCall__IJJI", #endif #ifndef JNI64 + "_1VtblCall__IIJII", +#else + "_1VtblCall__IJJII", +#endif +#ifndef JNI64 + "_1VtblCall__IIJIIIIII_3I", +#else + "_1VtblCall__IJJIIIIII_3I", +#endif +#ifndef JNI64 + "_1VtblCall__IIJIIJI", +#else + "_1VtblCall__IJJIIJI", +#endif +#ifndef JNI64 "_1VtblCall__IIJIIJIIIIII", #else "_1VtblCall__IJJIIJIIIIII", @@ -419,6 +454,11 @@ char * XPCOM_nativeFunctionNames[] = { "_1VtblCall__IJJIJII", #endif #ifndef JNI64 + "_1VtblCall__IIJIJI_3J", +#else + "_1VtblCall__IJJIJI_3J", +#endif +#ifndef JNI64 "_1VtblCall__IIJIJJ_3I_3I_3I", #else "_1VtblCall__IJJIJJ_3I_3I_3I", @@ -524,6 +564,11 @@ char * XPCOM_nativeFunctionNames[] = { "_1VtblCall__IJJJJJJ_3J", #endif #ifndef JNI64 + "_1VtblCall__IIJJJJ_3J", +#else + "_1VtblCall__IJJJJJ_3J", +#endif +#ifndef JNI64 "_1VtblCall__IIJJJ_3B_3BJ", #else "_1VtblCall__IJJJJ_3B_3BJ", @@ -539,6 +584,11 @@ char * XPCOM_nativeFunctionNames[] = { "_1VtblCall__IJJJJ_3J", #endif #ifndef JNI64 + "_1VtblCall__IIJJS", +#else + "_1VtblCall__IJJJS", +#endif +#ifndef JNI64 "_1VtblCall__IIJJ_3B", #else "_1VtblCall__IJJJ_3B", @@ -704,6 +754,11 @@ char * XPCOM_nativeFunctionNames[] = { "_1VtblCall__IJJ_3J", #endif #ifndef JNI64 + "_1VtblCall__IIJ_3S", +#else + "_1VtblCall__IJJ_3S", +#endif +#ifndef JNI64 "_1VtblCall__IILorg_eclipse_swt_internal_mozilla_nsID_2I", #else "_1VtblCall__IJLorg_eclipse_swt_internal_mozilla_nsID_2I", @@ -764,6 +819,11 @@ char * XPCOM_nativeFunctionNames[] = { "_1VtblCall__IJLorg_eclipse_swt_internal_mozilla_nsID_2_3J", #endif #ifndef JNI64 + "_1VtblCall__IIS", +#else + "_1VtblCall__IJS", +#endif +#ifndef JNI64 "_1VtblCall__IISIII", #else "_1VtblCall__IJSIII", @@ -849,6 +909,11 @@ char * XPCOM_nativeFunctionNames[] = { "_1VtblCall__IJ_3BLorg_eclipse_swt_internal_mozilla_nsID_2_3J", #endif #ifndef JNI64 + "_1VtblCall__II_3BS", +#else + "_1VtblCall__IJ_3BS", +#endif +#ifndef JNI64 "_1VtblCall__II_3B_3B", #else "_1VtblCall__IJ_3B_3B", diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom_stats.h b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom_stats.h index f3a130527f..0b0b1e0cc5 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom_stats.h +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/library/xpcom_stats.h @@ -67,6 +67,16 @@ typedef enum { _1VtblCall__IJF_FUNC, #endif #ifndef JNI64 + _1VtblCall__IIFF_3I_FUNC, +#else + _1VtblCall__IJFF_3I_FUNC, +#endif +#ifndef JNI64 + _1VtblCall__IIFF_3J_FUNC, +#else + _1VtblCall__IJFF_3J_FUNC, +#endif +#ifndef JNI64 _1VtblCall__III_FUNC, #else _1VtblCall__IJI_FUNC, @@ -182,6 +192,11 @@ typedef enum { _1VtblCall__IJIIJJJJ_FUNC, #endif #ifndef JNI64 + _1VtblCall__IIIIS_FUNC, +#else + _1VtblCall__IJIIS_FUNC, +#endif +#ifndef JNI64 _1VtblCall__IIII_3B_FUNC, #else _1VtblCall__IJII_3B_FUNC, @@ -392,6 +407,11 @@ typedef enum { _1VtblCall__IJI_3J_FUNC, #endif #ifndef JNI64 + _1VtblCall__III_3S_FUNC, +#else + _1VtblCall__IJI_3S_FUNC, +#endif +#ifndef JNI64 _1VtblCall__IIJ_FUNC, #else _1VtblCall__IJJ_FUNC, @@ -402,6 +422,21 @@ typedef enum { _1VtblCall__IJJI_FUNC, #endif #ifndef JNI64 + _1VtblCall__IIJII_FUNC, +#else + _1VtblCall__IJJII_FUNC, +#endif +#ifndef JNI64 + _1VtblCall__IIJIIIIII_3I_FUNC, +#else + _1VtblCall__IJJIIIIII_3I_FUNC, +#endif +#ifndef JNI64 + _1VtblCall__IIJIIJI_FUNC, +#else + _1VtblCall__IJJIIJI_FUNC, +#endif +#ifndef JNI64 _1VtblCall__IIJIIJIIIIII_FUNC, #else _1VtblCall__IJJIIJIIIIII_FUNC, @@ -427,6 +462,11 @@ typedef enum { _1VtblCall__IJJIJII_FUNC, #endif #ifndef JNI64 + _1VtblCall__IIJIJI_3J_FUNC, +#else + _1VtblCall__IJJIJI_3J_FUNC, +#endif +#ifndef JNI64 _1VtblCall__IIJIJJ_3I_3I_3I_FUNC, #else _1VtblCall__IJJIJJ_3I_3I_3I_FUNC, @@ -532,6 +572,11 @@ typedef enum { _1VtblCall__IJJJJJJ_3J_FUNC, #endif #ifndef JNI64 + _1VtblCall__IIJJJJ_3J_FUNC, +#else + _1VtblCall__IJJJJJ_3J_FUNC, +#endif +#ifndef JNI64 _1VtblCall__IIJJJ_3B_3BJ_FUNC, #else _1VtblCall__IJJJJ_3B_3BJ_FUNC, @@ -547,6 +592,11 @@ typedef enum { _1VtblCall__IJJJJ_3J_FUNC, #endif #ifndef JNI64 + _1VtblCall__IIJJS_FUNC, +#else + _1VtblCall__IJJJS_FUNC, +#endif +#ifndef JNI64 _1VtblCall__IIJJ_3B_FUNC, #else _1VtblCall__IJJJ_3B_FUNC, @@ -712,6 +762,11 @@ typedef enum { _1VtblCall__IJJ_3J_FUNC, #endif #ifndef JNI64 + _1VtblCall__IIJ_3S_FUNC, +#else + _1VtblCall__IJJ_3S_FUNC, +#endif +#ifndef JNI64 _1VtblCall__IILorg_eclipse_swt_internal_mozilla_nsID_2I_FUNC, #else _1VtblCall__IJLorg_eclipse_swt_internal_mozilla_nsID_2I_FUNC, @@ -772,6 +827,11 @@ typedef enum { _1VtblCall__IJLorg_eclipse_swt_internal_mozilla_nsID_2_3J_FUNC, #endif #ifndef JNI64 + _1VtblCall__IIS_FUNC, +#else + _1VtblCall__IJS_FUNC, +#endif +#ifndef JNI64 _1VtblCall__IISIII_FUNC, #else _1VtblCall__IJSIII_FUNC, @@ -857,6 +917,11 @@ typedef enum { _1VtblCall__IJ_3BLorg_eclipse_swt_internal_mozilla_nsID_2_3J_FUNC, #endif #ifndef JNI64 + _1VtblCall__II_3BS_FUNC, +#else + _1VtblCall__IJ_3BS_FUNC, +#endif +#ifndef JNI64 _1VtblCall__II_3B_3B_FUNC, #else _1VtblCall__IJ_3B_3B_FUNC, diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Download.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Download.java index 32f98c0493..19e3df1190 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Download.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Download.java @@ -187,7 +187,7 @@ int Init (int /*long*/ aSource, int /*long*/ aTarget, int /*long*/ aDisplayName, String filename = null; nsISupports supports = new nsISupports (aTarget); int /*long*/[] result = new int /*long*/[1]; - rc = supports.QueryInterface (nsIURI.NS_IURI_IID, result); + rc = supports.QueryInterface (!Mozilla.IsPre_4 ? nsIURI.NS_IURI_8_IID : nsIURI.NS_IURI_IID, result); if (rc == XPCOM.NS_OK) { /* >= 1.7 */ nsIURI target = new nsIURI (result[0]); result[0] = 0; diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePicker.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePicker.java index 27e49c1f6c..ddf543cd38 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePicker.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePicker.java @@ -101,7 +101,7 @@ int QueryInterface (int /*long*/ riid, int /*long*/ ppvObject) { AddRef (); return XPCOM.NS_OK; } - if (guid.Equals (nsIFilePicker_2.NS_IFILEPICKER_IID)) { + if (guid.Equals (nsIFilePicker_1_8.NS_IFILEPICKER_8_IID)) { XPCOM.memmove(ppvObject, new int /*long*/[] {filePicker.getAddress ()}, C.PTR_SIZEOF); AddRef (); return XPCOM.NS_OK; diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePickerFactory.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePickerFactory.java index 44dbff17f9..aaad0a5f60 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePickerFactory.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePickerFactory.java @@ -88,9 +88,19 @@ int Release () { /* nsIFactory */ int CreateInstance (int /*long*/ aOuter, int /*long*/ iid, int /*long*/ result) { - FilePicker picker = new FilePicker (); - picker.AddRef (); - XPCOM.memmove (result, new int /*long*/[] {picker.getAddress ()}, C.PTR_SIZEOF); + if (!Mozilla.IsPre_4) { + FilePicker_8 picker = new FilePicker_8 (); + picker.AddRef (); + XPCOM.memmove (result, new int /*long*/[] {picker.getAddress ()}, C.PTR_SIZEOF); + } else if (Mozilla.IsXULRunner) { + FilePicker_1_8 picker = new FilePicker_1_8 (); + picker.AddRef (); + XPCOM.memmove (result, new int /*long*/[] {picker.getAddress ()}, C.PTR_SIZEOF); + } else { + FilePicker picker = new FilePicker (); + picker.AddRef (); + XPCOM.memmove (result, new int /*long*/[] {picker.getAddress ()}, C.PTR_SIZEOF); + } return XPCOM.NS_OK; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePickerFactory_1_8.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePickerFactory_1_8.java deleted file mode 100644 index b47095b3b4..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePickerFactory_1_8.java +++ /dev/null @@ -1,44 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2007 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.swt.browser; - -import org.eclipse.swt.internal.C; -import org.eclipse.swt.internal.mozilla.*; - -class FilePickerFactory_1_8 extends FilePickerFactory { - -void createCOMInterfaces () { - /* Create each of the interfaces that this object implements */ - supports = new XPCOMObject (new int[] {2, 0, 0}) { - 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 ();} - }; - - factory = new XPCOMObject (new int[] {2, 0, 0, 3, 1}) { - 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 CreateInstance (args[0], args[1], args[2]);} - public int /*long*/ method4 (int /*long*/[] args) {return LockFactory ((int)/*64*/args[0]);} - }; -} - -/* nsIFactory */ - -int CreateInstance (int /*long*/ aOuter, int /*long*/ iid, int /*long*/ result) { - FilePicker_1_8 picker = new FilePicker_1_8 (); - picker.AddRef (); - XPCOM.memmove (result, new int /*long*/[] {picker.getAddress ()}, C.PTR_SIZEOF); - return XPCOM.NS_OK; -} - -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePickerFactory_2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePickerFactory_2.java deleted file mode 100644 index 2c968c7de5..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePickerFactory_2.java +++ /dev/null @@ -1,44 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2007 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.swt.browser; - -import org.eclipse.swt.internal.C; -import org.eclipse.swt.internal.mozilla.*; - -class FilePickerFactory_2 extends FilePickerFactory_1_8 { - -void createCOMInterfaces () { - /* Create each of the interfaces that this object implements */ - supports = new XPCOMObject (new int[] {2, 0, 0}) { - 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 ();} - }; - - factory = new XPCOMObject (new int[] {2, 0, 0, 3, 1}) { - 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 CreateInstance (args[0], args[1], args[2]);} - public int /*long*/ method4 (int /*long*/[] args) {return LockFactory ((int)/*64*/args[0]);} - }; -} - -/* nsIFactory */ - -int CreateInstance (int /*long*/ aOuter, int /*long*/ iid, int /*long*/ result) { - FilePicker_2 picker = new FilePicker_2 (); - picker.AddRef (); - XPCOM.memmove (result, new int /*long*/[] {picker.getAddress ()}, C.PTR_SIZEOF); - return XPCOM.NS_OK; -} - -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePicker_2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePicker_8.java index 28161c2c42..d229af8cb3 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePicker_2.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/FilePicker_8.java @@ -1,49 +1,49 @@ -/******************************************************************************* - * Copyright (c) 2003, 2007 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.swt.browser; - -import org.eclipse.swt.internal.mozilla.*; - -class FilePicker_2 extends FilePicker_1_8 { - -void createCOMInterfaces () { - /* Create each of the interfaces that this object implements */ - supports = new XPCOMObject (new int[] {2, 0, 0}) { - 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 ();} - }; - - filePicker = new XPCOMObject (new int[] {2, 0, 0, 3, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}) { - 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 Init (args[0], args[1], (short)args[2]);} - public int /*long*/ method4 (int /*long*/[] args) {return AppendFilters ((int)/*64*/args[0]);} - public int /*long*/ method5 (int /*long*/[] args) {return AppendFilter (args[0], args[1]);} - public int /*long*/ method6 (int /*long*/[] args) {return GetDefaultString (args[0]);} - public int /*long*/ method7 (int /*long*/[] args) {return SetDefaultString (args[0]);} - public int /*long*/ method8 (int /*long*/[] args) {return GetDefaultExtension (args[0]);} - public int /*long*/ method9 (int /*long*/[] args) {return SetDefaultExtension (args[0]);} - public int /*long*/ method10 (int /*long*/[] args) {return GetFilterIndex (args[0]);} - public int /*long*/ method11 (int /*long*/[] args) {return SetFilterIndex ((int)/*64*/args[0]);} - public int /*long*/ method12 (int /*long*/[] args) {return GetDisplayDirectory (args[0]);} - public int /*long*/ method13 (int /*long*/[] args) {return SetDisplayDirectory (args[0]);} - public int /*long*/ method14 (int /*long*/[] args) {return GetFile (args[0]);} - public int /*long*/ method15 (int /*long*/[] args) {return GetFileURL (args[0]);} - public int /*long*/ method16 (int /*long*/[] args) {return GetFiles (args[0]);} - public int /*long*/ method17 (int /*long*/[] args) {return XPCOM.NS_ERROR_NOT_IMPLEMENTED;} - public int /*long*/ method18 (int /*long*/[] args) {return XPCOM.NS_ERROR_NOT_IMPLEMENTED;} - public int /*long*/ method19 (int /*long*/[] args) {return Show (args[0]);} - }; -} - -} +/*******************************************************************************
+ * Copyright (c) 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
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.swt.browser;
+
+import org.eclipse.swt.internal.mozilla.*;
+
+class FilePicker_8 extends FilePicker_1_8 {
+
+void createCOMInterfaces () {
+ /* Create each of the interfaces that this object implements */
+ supports = new XPCOMObject (new int[] {2, 0, 0}) {
+ 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 ();}
+ };
+
+ filePicker = new XPCOMObject (new int[] {2, 0, 0, 3, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}) {
+ 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 Init (args[0], args[1], (short)args[2]);}
+ public int /*long*/ method4 (int /*long*/[] args) {return AppendFilters ((int)/*64*/args[0]);}
+ public int /*long*/ method5 (int /*long*/[] args) {return AppendFilter (args[0], args[1]);}
+ public int /*long*/ method6 (int /*long*/[] args) {return GetDefaultString (args[0]);}
+ public int /*long*/ method7 (int /*long*/[] args) {return SetDefaultString (args[0]);}
+ public int /*long*/ method8 (int /*long*/[] args) {return GetDefaultExtension (args[0]);}
+ public int /*long*/ method9 (int /*long*/[] args) {return SetDefaultExtension (args[0]);}
+ public int /*long*/ method10 (int /*long*/[] args) {return GetFilterIndex (args[0]);}
+ public int /*long*/ method11 (int /*long*/[] args) {return SetFilterIndex ((int)/*64*/args[0]);}
+ public int /*long*/ method12 (int /*long*/[] args) {return GetDisplayDirectory (args[0]);}
+ public int /*long*/ method13 (int /*long*/[] args) {return SetDisplayDirectory (args[0]);}
+ public int /*long*/ method14 (int /*long*/[] args) {return GetFile (args[0]);}
+ public int /*long*/ method15 (int /*long*/[] args) {return GetFileURL (args[0]);}
+ public int /*long*/ method16 (int /*long*/[] args) {return GetFiles (args[0]);}
+ public int /*long*/ method17 (int /*long*/[] args) {return XPCOM.NS_ERROR_NOT_IMPLEMENTED;}
+ public int /*long*/ method18 (int /*long*/[] args) {return XPCOM.NS_ERROR_NOT_IMPLEMENTED;}
+ public int /*long*/ method19 (int /*long*/[] args) {return Show (args[0]);}
+ };
+}
+
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/HelperAppLauncherDialogFactory.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/HelperAppLauncherDialogFactory.java index ca531c3972..26ae0c2807 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/HelperAppLauncherDialogFactory.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/HelperAppLauncherDialogFactory.java @@ -92,12 +92,12 @@ int CreateInstance (int /*long*/ aOuter, int /*long*/ iid, int /*long*/ result) HelperAppLauncherDialog helperAppLauncherDialog = new HelperAppLauncherDialog (); helperAppLauncherDialog.AddRef (); XPCOM.memmove (result, new int /*long*/[] {helperAppLauncherDialog.getAddress ()}, C.PTR_SIZEOF); - } else if (Mozilla.IsPre_2){ + } else if (Mozilla.IsPre_4){ HelperAppLauncherDialog_1_9 helperAppLauncherDialog = new HelperAppLauncherDialog_1_9 (); helperAppLauncherDialog.AddRef (); XPCOM.memmove (result, new int /*long*/[] {helperAppLauncherDialog.getAddress ()}, C.PTR_SIZEOF); } else { - HelperAppLauncherDialog_2 helperAppLauncherDialog = new HelperAppLauncherDialog_2 (); + HelperAppLauncherDialog_8 helperAppLauncherDialog = new HelperAppLauncherDialog_8 (); helperAppLauncherDialog.AddRef (); XPCOM.memmove (result, new int /*long*/[] {helperAppLauncherDialog.getAddress ()}, C.PTR_SIZEOF); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/HelperAppLauncherDialog_2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/HelperAppLauncherDialog_8.java index 72bfca3008..5226aa8f8c 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/HelperAppLauncherDialog_2.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/HelperAppLauncherDialog_8.java @@ -21,19 +21,19 @@ import org.eclipse.swt.widgets.*; * implemented by class HelperAppLauncherDialog_1_9. HelperAppLauncherDialogFactory * determines at runtime which of these classes to instantiate. */ -class HelperAppLauncherDialog_2 extends HelperAppLauncherDialog_1_9 { +class HelperAppLauncherDialog_8 extends HelperAppLauncherDialog_1_9 { XPCOMObject supports; XPCOMObject helperAppLauncherDialog; int refCount = 0; -HelperAppLauncherDialog_2 () { +HelperAppLauncherDialog_8 () { createCOMInterfaces (); } /* nsIHelperAppLauncherDialog */ int Show (int /*long*/ aLauncher, int /*long*/ aContext, int aReason) { - nsIHelperAppLauncher_2 helperAppLauncher = new nsIHelperAppLauncher_2 (aLauncher); + nsIHelperAppLauncher_8 helperAppLauncher = new nsIHelperAppLauncher_8 (aLauncher); return helperAppLauncher.SaveToDisk (0, 0); } @@ -55,7 +55,7 @@ int PromptForSaveToFile (int /*long*/ aLauncher, int /*long*/ aWindowContext, in String name = fileDialog.open (); shell.close (); if (name == null) { - nsIHelperAppLauncher_2 launcher = new nsIHelperAppLauncher_2 (aLauncher); + nsIHelperAppLauncher_8 launcher = new nsIHelperAppLauncher_8 (aLauncher); int rc = launcher.Cancel (XPCOM.NS_BINDING_ABORTED); if (rc != XPCOM.NS_OK) Mozilla.error (rc); return XPCOM.NS_ERROR_FAILURE; diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java index 2439036f40..a444e34f1e 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Mozilla.java @@ -62,7 +62,7 @@ class Mozilla extends WebBrowser { static int BrowserCount, NextJSFunctionIndex = 1; static Hashtable AllFunctions = new Hashtable (); static Listener DisplayListener; - static boolean Initialized, IsPre_1_8, IsPre_1_9, IsPre_2, IsXULRunner, PerformedVersionCheck, XPCOMWasGlued, XPCOMInitWasGlued; + static boolean Initialized, IsPre_1_8, IsPre_1_9, IsPre_4, IsXULRunner, PerformedVersionCheck, XPCOMWasGlued, XPCOMInitWasGlued; static String MozillaPath; static String oldProxyHostFTP, oldProxyHostHTTP, oldProxyHostSSL; static int oldProxyPortFTP = -1, oldProxyPortHTTP = -1, oldProxyPortSSL = -1, oldProxyType = -1; @@ -792,10 +792,9 @@ public void create (Composite parent, int style) { result[0] = 0; /* create the nsIWebBrowser instance */ - nsID NS_IWEBBROWSER_CID = new nsID ("F1EAC761-87E9-11d3-AF80-00A024FFC08C"); //$NON-NLS-1$ - rc = componentManager.CreateInstance (NS_IWEBBROWSER_CID, 0, nsIWebBrowser.NS_IWEBBROWSER_IID, result); + rc = componentManager.CreateInstance (XPCOM.NS_IWEBBROWSER_CID, 0, nsIWebBrowser.NS_IWEBBROWSER_8_IID, result); if (rc != XPCOM.NS_OK) { - rc = componentManager.CreateInstance (NS_IWEBBROWSER_CID, 0, nsIWebBrowser_1_9.NS_IWEBBROWSER_IID, result); + rc = componentManager.CreateInstance (XPCOM.NS_IWEBBROWSER_CID, 0, nsIWebBrowser.NS_IWEBBROWSER_IID, result); if (rc != XPCOM.NS_OK) { browser.dispose (); error (rc); @@ -863,7 +862,7 @@ public void create (Composite parent, int style) { new nsISupports (result[0]).Release (); } IsPre_1_9 = true; - IsPre_2 = true; + IsPre_4 = true; result[0] = 0; /* @@ -896,9 +895,9 @@ public void create (Composite parent, int style) { } else { /* >= 1.9 */ IsPre_1_9 = false; result[0] = 0; - rc = interfaceRequestor.GetInterface(nsIDocShell_2.NS_IDOCSHELL_IID, result); + rc = interfaceRequestor.GetInterface(nsIDocShell_1_8.NS_IDOCSHELL_8_IID, result); if (rc == XPCOM.NS_OK && result[0] != 0) { /* >=2.0 */ - IsPre_2 = false; + IsPre_4 = false; new nsISupports (result[0]).Release(); } } @@ -1283,153 +1282,131 @@ public boolean execute (String script) { * exposed as of mozilla 1.9. */ int /*long*/[] result = new int /*long*/[1]; - if (!IsPre_2) { + if (!IsPre_1_9) { int rc = XPCOM.NS_GetServiceManager (result); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); nsIServiceManager serviceManager = new nsIServiceManager (result[0]); result[0] = 0; - nsIPrincipal principal = null; - nsIPrincipal_1_9 principal_1_9 = null; byte[] aContractID = MozillaDelegate.wcsToMbcs (null, XPCOM.NS_SCRIPTSECURITYMANAGER_CONTRACTID, true); - rc = serviceManager.GetServiceByContractID (aContractID, nsIScriptSecurityManager_2.NS_ISCRIPTSECURITYMANAGER_IID, result); + rc = serviceManager.GetServiceByContractID (aContractID, nsIScriptSecurityManager.NS_ISCRIPTSECURITYMANAGER_8_IID, result); + if (!(rc == XPCOM.NS_OK && result[0] != 0)) { + result[0] = 0; + rc = serviceManager.GetServiceByContractID (aContractID, nsIScriptSecurityManager.NS_ISCRIPTSECURITYMANAGER_191_IID, result); + if (!(rc == XPCOM.NS_OK && result[0] != 0)) { + result[0] = 0; + rc = serviceManager.GetServiceByContractID (aContractID, nsIScriptSecurityManager.NS_ISCRIPTSECURITYMANAGER_IID, result); + } + } + if (rc == XPCOM.NS_OK && result[0] != 0) { - nsIScriptSecurityManager_2 securityManager = new nsIScriptSecurityManager_2 (result[0]); + nsIScriptSecurityManager securityManager = new nsIScriptSecurityManager (result[0]); result[0] = 0; rc = securityManager.GetSystemPrincipal (result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_ERROR_NULL_POINTER); - principal = new nsIPrincipal (result[0]); - result[0] = 0; securityManager.Release (); - } else { - rc = serviceManager.GetServiceByContractID (aContractID, nsIScriptSecurityManager_1_9_1.NS_ISCRIPTSECURITYMANAGER_IID, result); + if (rc == XPCOM.NS_OK && result[0] != 0) { - nsIScriptSecurityManager_1_9_1 securityManager = new nsIScriptSecurityManager_1_9_1 (result[0]); + nsIPrincipal principal = new nsIPrincipal (result[0]); result[0] = 0; - rc = securityManager.GetSystemPrincipal (result); + rc = webBrowser.QueryInterface (nsIInterfaceRequestor.NS_IINTERFACEREQUESTOR_IID, result); if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_ERROR_NULL_POINTER); - principal_1_9 = new nsIPrincipal_1_9 (result[0]); - result[0] = 0; - securityManager.Release (); - } else { - rc = serviceManager.GetServiceByContractID (aContractID, nsIScriptSecurityManager_1_9.NS_ISCRIPTSECURITYMANAGER_IID, result); - if (rc == XPCOM.NS_OK && result[0] != 0) { - nsIScriptSecurityManager_1_9 securityManager = new nsIScriptSecurityManager_1_9 (result[0]); - result[0] = 0; - rc = securityManager.GetSystemPrincipal (result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_ERROR_NULL_POINTER); - principal_1_9 = new nsIPrincipal_1_9 (result[0]); - result[0] = 0; - securityManager.Release (); - } - } - } - - if (principal != null || principal_1_9 != null) { - rc = webBrowser.QueryInterface (nsIInterfaceRequestor.NS_IINTERFACEREQUESTOR_IID, result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_ERROR_NO_INTERFACE); + if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); - nsIInterfaceRequestor interfaceRequestor = new nsIInterfaceRequestor (result[0]); - result[0] = 0; - nsID scriptGlobalObjectNSID_2 = new nsID ("4eb16819-4e81-406e-9305-6f30fcd2624a"); /* nsIScriptGlobalObject */ //$NON-NLS-1$ - rc = interfaceRequestor.GetInterface (scriptGlobalObjectNSID_2, result); - if (!(rc == XPCOM.NS_OK && result[0] != 0)) { + nsIInterfaceRequestor interfaceRequestor = new nsIInterfaceRequestor (result[0]); result[0] = 0; - nsID scriptGlobalObjectNSID_1_9_2 = new nsID ("e9f3f2c1-2d94-4722-bbd4-2bf6fdf42f48"); /* nsIScriptGlobalObject */ //$NON-NLS-1$ - rc = interfaceRequestor.GetInterface (scriptGlobalObjectNSID_1_9_2, result); + nsID scriptGlobalObjectNSID_8 = new nsID ("4eb16819-4e81-406e-9305-6f30fcd2624a"); /* nsIScriptGlobalObject */ //$NON-NLS-1$ + rc = interfaceRequestor.GetInterface (scriptGlobalObjectNSID_8, result); if (!(rc == XPCOM.NS_OK && result[0] != 0)) { result[0] = 0; - nsID scriptGlobalObjectNSID_1_9 = new nsID ("6afecd40-0b9a-4cfd-8c42-0f645cd91829"); /* nsIScriptGlobalObject */ //$NON-NLS-1$ - rc = interfaceRequestor.GetInterface (scriptGlobalObjectNSID_1_9, result); - } - } - interfaceRequestor.Release (); - - if (rc == XPCOM.NS_OK && result[0] != 0) { - int /*long*/ scriptGlobalObject = result[0]; - result[0] = 0; - rc = (int/*64*/)XPCOM.nsIScriptGlobalObject_EnsureScriptEnvironment (scriptGlobalObject, 2); /* nsIProgrammingLanguage.JAVASCRIPT */ - if (rc != XPCOM.NS_OK) error (rc); - int /*long*/ scriptContext = XPCOM.nsIScriptGlobalObject_GetScriptContext (scriptGlobalObject, 2); /* nsIProgrammingLanguage.JAVASCRIPT */ - int /*long*/ globalJSObject = XPCOM.nsIScriptGlobalObject_GetScriptGlobal (scriptGlobalObject, 2); /* nsIProgrammingLanguage.JAVASCRIPT */ - new nsISupports (scriptGlobalObject).Release (); - - if (scriptContext != 0 && globalJSObject != 0) { - /* ensure that the received nsIScriptContext implements the expected interface */ - nsID scriptContextNSID_2 = new nsID ("a7139c0e-962c-44b6-bec3-e4166bfe84eb"); /* nsIScriptContext */ //$NON-NLS-1$ - rc = new nsISupports (scriptContext).QueryInterface (scriptContextNSID_2, result); + nsID scriptGlobalObjectNSID_1_9_2 = new nsID ("e9f3f2c1-2d94-4722-bbd4-2bf6fdf42f48"); /* nsIScriptGlobalObject */ //$NON-NLS-1$ + rc = interfaceRequestor.GetInterface (scriptGlobalObjectNSID_1_9_2, result); if (!(rc == XPCOM.NS_OK && result[0] != 0)) { result[0] = 0; - nsID scriptContextNSID_1_9_2 = new nsID ("87482b5e-e019-4df5-9bc2-b2a51b1f2d28"); /* nsIScriptContext */ //$NON-NLS-1$ - rc = new nsISupports (scriptContext).QueryInterface (scriptContextNSID_1_9_2, result); - if (!(rc == XPCOM.NS_OK && result[0] != 0)) { - result[0] = 0; - nsID scriptContextNSID_1_9 = new nsID ("e7b9871d-3adc-4bf7-850d-7fb9554886bf"); /* nsIScriptContext */ //$NON-NLS-1$ - rc = new nsISupports (scriptContext).QueryInterface (scriptContextNSID_1_9, result); - } + nsID scriptGlobalObjectNSID_1_9 = new nsID ("6afecd40-0b9a-4cfd-8c42-0f645cd91829"); /* nsIScriptGlobalObject */ //$NON-NLS-1$ + rc = interfaceRequestor.GetInterface (scriptGlobalObjectNSID_1_9, result); } + } + interfaceRequestor.Release (); - if (rc == XPCOM.NS_OK && result[0] != 0) { - new nsISupports (result[0]).Release (); - result[0] = 0; - - int /*long*/ nativeContext = XPCOM.nsIScriptContext_GetNativeContext (scriptContext); - if (nativeContext != 0) { - int length = script.length (); - char[] scriptChars = new char[length]; - script.getChars(0, length, scriptChars, 0); - byte[] urlbytes = MozillaDelegate.wcsToMbcs (null, getUrl (), true); - rc = (principal != null) ? principal.GetJSPrincipals (nativeContext, result) - : principal_1_9.GetJSPrincipals (nativeContext, result); - if (rc == XPCOM.NS_OK && result[0] != 0) { - int /*long*/ principals = result[0]; + if (rc == XPCOM.NS_OK && result[0] != 0) { + int /*long*/ scriptGlobalObject = result[0]; + result[0] = 0; + rc = (int/*64*/)XPCOM.nsIScriptGlobalObject_EnsureScriptEnvironment (scriptGlobalObject, 2); /* nsIProgrammingLanguage.JAVASCRIPT */ + if (rc != XPCOM.NS_OK) { + new nsISupports (scriptGlobalObject).Release (); + } else { + int /*long*/ scriptContext = XPCOM.nsIScriptGlobalObject_GetScriptContext (scriptGlobalObject, 2); /* nsIProgrammingLanguage.JAVASCRIPT */ + int /*long*/ globalJSObject = XPCOM.nsIScriptGlobalObject_GetScriptGlobal (scriptGlobalObject, 2); /* nsIProgrammingLanguage.JAVASCRIPT */ + new nsISupports (scriptGlobalObject).Release (); + + if (scriptContext != 0 && globalJSObject != 0) { + /* ensure that the received nsIScriptContext implements the expected interface */ + nsISupports supports = new nsISupports (scriptContext); + nsID scriptContextNSID_8 = new nsID ("a7139c0e-962c-44b6-bec3-e4166bfe84eb"); /* nsIScriptContext */ //$NON-NLS-1$ + rc = supports.QueryInterface (scriptContextNSID_8, result); + if (!(rc == XPCOM.NS_OK && result[0] != 0)) { result[0] = 0; - String jsLibraryName = null; - if (principal != null) { - principal.Release (); - jsLibraryName = delegate.getJSLibraryName(); - } else { - principal_1_9.Release(); - jsLibraryName = delegate.getJSLibraryName_Pre2(); - } - if (pathBytes_JSEvaluateUCScriptForPrincipals == null) { - String mozillaPath = getMozillaPath () + jsLibraryName + '\0'; - try { - pathBytes_JSEvaluateUCScriptForPrincipals = mozillaPath.getBytes ("UTF-8"); //$NON-NLS-1$ - } catch (UnsupportedEncodingException e) { - pathBytes_JSEvaluateUCScriptForPrincipals = mozillaPath.getBytes (); - } + nsID scriptContextNSID_1_9_2 = new nsID ("87482b5e-e019-4df5-9bc2-b2a51b1f2d28"); /* nsIScriptContext */ //$NON-NLS-1$ + rc = supports.QueryInterface (scriptContextNSID_1_9_2, result); + if (!(rc == XPCOM.NS_OK && result[0] != 0)) { + result[0] = 0; + nsID scriptContextNSID_1_9 = new nsID ("e7b9871d-3adc-4bf7-850d-7fb9554886bf"); /* nsIScriptContext */ //$NON-NLS-1$ + rc = supports.QueryInterface (scriptContextNSID_1_9, result); } + } - aContractID = MozillaDelegate.wcsToMbcs (null, XPCOM.NS_CONTEXTSTACK_CONTRACTID, true); - rc = serviceManager.GetServiceByContractID (aContractID, nsIJSContextStack.NS_IJSCONTEXTSTACK_IID, result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); - serviceManager.Release (); - - nsIJSContextStack stack = new nsIJSContextStack (result[0]); - result[0] = 0; - rc = stack.Push (nativeContext); - if (rc != XPCOM.NS_OK) error (rc); - boolean success = XPCOM.JS_EvaluateUCScriptForPrincipals (pathBytes_JSEvaluateUCScriptForPrincipals, nativeContext, globalJSObject, principals, scriptChars, length, urlbytes, 0, result) != 0; + if (rc == XPCOM.NS_OK && result[0] != 0) { + new nsISupports (result[0]).Release (); result[0] = 0; - rc = stack.Pop (result); - if (rc != XPCOM.NS_OK) error (rc); - stack.Release (); - return success; + int /*long*/ nativeContext = XPCOM.nsIScriptContext_GetNativeContext (scriptContext); + if (nativeContext != 0) { + int length = script.length (); + char[] scriptChars = new char[length]; + script.getChars(0, length, scriptChars, 0); + byte[] urlbytes = MozillaDelegate.wcsToMbcs (null, getUrl (), true); + rc = principal.GetJSPrincipals (nativeContext, result); + if (rc == XPCOM.NS_OK && result[0] != 0) { + int /*long*/ principals = result[0]; + result[0] = 0; + String jsLibraryName = IsPre_4 ? delegate.getJSLibraryName_Pre4() : delegate.getJSLibraryName(); + if (pathBytes_JSEvaluateUCScriptForPrincipals == null) { + String mozillaPath = getMozillaPath () + jsLibraryName + '\0'; + try { + pathBytes_JSEvaluateUCScriptForPrincipals = mozillaPath.getBytes ("UTF-8"); //$NON-NLS-1$ + } catch (UnsupportedEncodingException e) { + pathBytes_JSEvaluateUCScriptForPrincipals = mozillaPath.getBytes (); + } + } + + aContractID = MozillaDelegate.wcsToMbcs (null, XPCOM.NS_CONTEXTSTACK_CONTRACTID, true); + rc = serviceManager.GetServiceByContractID (aContractID, nsIJSContextStack.NS_IJSCONTEXTSTACK_IID, result); + if (rc == XPCOM.NS_OK && result[0] != 0) { + nsIJSContextStack stack = new nsIJSContextStack (result[0]); + result[0] = 0; + rc = stack.Push (nativeContext); + if (rc != XPCOM.NS_OK) { + stack.Release (); + } else { + boolean success = XPCOM.JS_EvaluateUCScriptForPrincipals (pathBytes_JSEvaluateUCScriptForPrincipals, nativeContext, globalJSObject, principals, scriptChars, length, urlbytes, 0, result) != 0; + result[0] = 0; + rc = stack.Pop (result); + stack.Release (); + // should principals be Release()d too? + principal.Release (); + serviceManager.Release (); + return success; + } + } + } + } } } } } + principal.Release (); } - if (principal != null) principal.Release (); - else principal_1_9.Release(); } serviceManager.Release (); } @@ -1471,13 +1448,8 @@ static Browser getBrowser (int /*long*/ aDOMWindow) { nsIWindowWatcher windowWatcher = new nsIWindowWatcher (result[0]); result[0] = 0; /* the chrome will only be answered for the top-level nsIDOMWindow */ - if (!IsPre_2) { - nsIDOMWindow window = new nsIDOMWindow (aDOMWindow); - rc = window.GetTop (result); - } else { - nsIDOMWindow_1_9 window = new nsIDOMWindow_1_9 (aDOMWindow); - rc = window.GetTop (result); - } + nsIDOMWindow window = new nsIDOMWindow (aDOMWindow); + rc = window.GetTop (result); if (rc != XPCOM.NS_OK) Mozilla.error (rc); if (result[0] == 0) Mozilla.error (XPCOM.NS_NOINTERFACE); int /*long*/ topDOMWindow = result[0]; @@ -1581,21 +1553,12 @@ public String getText () { if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); - if (!IsPre_2) { - nsIDOMWindow window = new nsIDOMWindow (result[0]); - result[0] = 0; - rc = window.GetDocument (result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); - window.Release (); - } else { - nsIDOMWindow_1_9 window = new nsIDOMWindow_1_9 (result[0]); - result[0] = 0; - rc = window.GetDocument (result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); - window.Release (); - } + nsIDOMWindow window = new nsIDOMWindow (result[0]); + result[0] = 0; + rc = window.GetDocument (result); + if (rc != XPCOM.NS_OK) error (rc); + if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); + window.Release (); int /*long*/ document = result[0]; result[0] = 0; @@ -1695,7 +1658,7 @@ public Object getWebBrowser () { Method method = clazz.getMethod ("getInstance", new Class[0]); //$NON-NLS-1$ Object mozilla = method.invoke (null, new Object[0]); method = clazz.getMethod ("wrapXPCOMObject", new Class[] {Long.TYPE, String.class}); //$NON-NLS-1$ - webBrowserObject = method.invoke (mozilla, new Object[] {new Long (webBrowser.getAddress ()), nsIWebBrowser.NS_IWEBBROWSER_IID_STR}); + webBrowserObject = method.invoke (mozilla, new Object[] {new Long (webBrowser.getAddress ()), !IsPre_4 ? nsIWebBrowser.NS_IWEBBROWSER_8_IID_STR : nsIWebBrowser.NS_IWEBBROWSER_IID_STR}); /* * The following AddRef() is needed to offset the automatic Release() that * will be performed by JavaXPCOM when webBrowserObject is finalized. @@ -1831,7 +1794,7 @@ void initFactories (nsIServiceManager serviceManager, nsIComponentManager compon browser.dispose (); error (rc); } - if (!IsPre_2) { + if (!IsPre_4) { aContractID = MozillaDelegate.wcsToMbcs (null, XPCOM.NS_PROMPTER_CONTRACTID, true); aClassName = MozillaDelegate.wcsToMbcs (null, "swtPrompter", true); //$NON-NLS-1$ rc = componentRegistrar.RegisterFactory (XPCOM.NS_PROMPTER_CID, aClassName, aContractID, factory.getAddress ()); @@ -1879,7 +1842,7 @@ void initFactories (nsIServiceManager serviceManager, nsIComponentManager compon * If the GRE version is >= 1.9 then no Download factory is registered because this * functionality is provided by the GRE. */ - if (IsPre_2) { + if (IsPre_4) { DownloadFactory downloadFactory = new DownloadFactory (); downloadFactory.AddRef (); aContractID = MozillaDelegate.wcsToMbcs (null, XPCOM.NS_DOWNLOAD_CONTRACTID, true); @@ -1892,7 +1855,7 @@ void initFactories (nsIServiceManager serviceManager, nsIComponentManager compon downloadFactory.Release (); } - FilePickerFactory pickerFactory = !IsPre_2 ? new FilePickerFactory_2() : (isXULRunner ? new FilePickerFactory_1_8 () : new FilePickerFactory ()); + FilePickerFactory pickerFactory = new FilePickerFactory (); pickerFactory.AddRef (); aContractID = MozillaDelegate.wcsToMbcs (null, XPCOM.NS_FILEPICKER_CONTRACTID, true); aClassName = MozillaDelegate.wcsToMbcs (null, "swtFilePicker", true); //$NON-NLS-1$ @@ -2012,8 +1975,12 @@ void initXPCOM (String mozillaPath, boolean isXULRunner) { C.memset (ptr, 0, size * 2); nsDynamicFunctionLoad functionLoad = new nsDynamicFunctionLoad (); int version = Integer.getInteger(XULRUNNER_VERSION, 0).intValue(); - if (version < 2) IsPre_2 = true; - String initFunctionName = IsPre_2 ? "XRE_InitEmbedding" : "XRE_InitEmbedding2"; + if (version < 4) { + IsPre_4 = true; + } else { + nsISupports.Is8 = true; + } + String initFunctionName = IsPre_4 ? "XRE_InitEmbedding" : "XRE_InitEmbedding2"; byte[] bytes = MozillaDelegate.wcsToMbcs (null, initFunctionName, true); //$NON-NLS-1$ functionLoad.functionName = C.malloc (bytes.length); C.memmove (functionLoad.functionName, bytes, bytes.length); @@ -2031,7 +1998,7 @@ void initXPCOM (String mozillaPath, boolean isXULRunner) { browser.dispose (); error (XPCOM.NS_ERROR_NULL_POINTER); } - if (IsPre_2) { + if (IsPre_4) { rc = XPCOM.Call (functionPtr, localFile.getAddress (), localFile.getAddress (), LocationProvider.getAddress (), 0, 0); } else { rc = XPCOM.Call (functionPtr, localFile.getAddress (), localFile.getAddress (), LocationProvider.getAddress ()); @@ -3233,70 +3200,14 @@ void hookDOMListeners (nsIDOMEventTarget target, boolean isTop) { string.dispose (); } -void hookDOMListeners_1_9 (nsIDOMEventTarget_1_9 target, boolean isTop) { - nsEmbedString string = new nsEmbedString (XPCOM.DOMEVENT_FOCUS); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - string = new nsEmbedString (XPCOM.DOMEVENT_UNLOAD); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - string = new nsEmbedString (XPCOM.DOMEVENT_MOUSEDOWN); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - string = new nsEmbedString (XPCOM.DOMEVENT_MOUSEUP); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - string = new nsEmbedString (XPCOM.DOMEVENT_MOUSEMOVE); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - string = new nsEmbedString (XPCOM.DOMEVENT_MOUSEWHEEL); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - string = new nsEmbedString (XPCOM.DOMEVENT_MOUSEDRAG); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - - /* - * Only hook mouseover and mouseout if the target is a top-level frame, so that mouse moves - * between frames will not generate events. - */ - if (isTop && delegate.hookEnterExit ()) { - string = new nsEmbedString (XPCOM.DOMEVENT_MOUSEOVER); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - string = new nsEmbedString (XPCOM.DOMEVENT_MOUSEOUT); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - } - - string = new nsEmbedString (XPCOM.DOMEVENT_KEYDOWN); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - string = new nsEmbedString (XPCOM.DOMEVENT_KEYPRESS); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); - string = new nsEmbedString (XPCOM.DOMEVENT_KEYUP); - target.AddEventListener (string.getAddress (), domEventListener.getAddress (), 0); - string.dispose (); -} - void unhookDOMListeners () { int /*long*/[] result = new int /*long*/[1]; int rc = webBrowser.GetContentDOMWindow (result); if (rc != XPCOM.NS_OK || result[0] == 0) return; - nsIDOMWindow_1_9 window_1_9 = null; - nsIDOMWindow window = null; - if (!IsPre_2) { - window = new nsIDOMWindow (result[0]); - result[0] = 0; - rc = window.QueryInterface (nsIDOMEventTarget.NS_IDOMEVENTTARGET_IID, result); - } else { - window_1_9 = new nsIDOMWindow_1_9 (result[0]); - result[0] = 0; - rc = window_1_9.QueryInterface (nsIDOMEventTarget_1_9.NS_IDOMEVENTTARGET_IID, result); - } - + nsIDOMWindow window = new nsIDOMWindow (result[0]); + result[0] = 0; + rc = window.QueryInterface (!IsPre_4 ? nsIDOMEventTarget.NS_IDOMEVENTTARGET_8_IID : nsIDOMEventTarget.NS_IDOMEVENTTARGET_IID, result); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_ERROR_NO_INTERFACE); nsIDOMEventTarget target = new nsIDOMEventTarget (result[0]); @@ -3305,7 +3216,7 @@ void unhookDOMListeners () { target.Release (); /* Listeners must be unhooked in pages contained in frames */ - rc = !IsPre_2 ? window.GetFrames (result) : window_1_9.GetFrames(result); + rc = window.GetFrames (result); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_ERROR_NO_INTERFACE); nsIDOMWindowCollection frames = new nsIDOMWindowCollection (result[0]); @@ -3323,7 +3234,7 @@ void unhookDOMListeners () { nsIDOMWindow frame = new nsIDOMWindow (result[0]); result[0] = 0; - rc = frame.QueryInterface (!IsPre_2 ? nsIDOMEventTarget.NS_IDOMEVENTTARGET_IID : nsIDOMEventTarget_1_9.NS_IDOMEVENTTARGET_IID, result); + rc = frame.QueryInterface (!IsPre_4 ? nsIDOMEventTarget.NS_IDOMEVENTTARGET_8_IID : nsIDOMEventTarget.NS_IDOMEVENTTARGET_IID, result); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_ERROR_NO_INTERFACE); @@ -3335,8 +3246,7 @@ void unhookDOMListeners () { } } frames.Release (); - if (!IsPre_2) window.Release (); - else window_1_9.Release(); + window.Release (); } void unhookDOMListeners (nsIDOMEventTarget target) { @@ -3473,7 +3383,7 @@ int GetInterface (int /*long*/ riid, int /*long*/ ppvObject) { if (riid == 0 || ppvObject == 0) return XPCOM.NS_ERROR_NO_INTERFACE; nsID guid = new nsID (); XPCOM.memmove (guid, riid, nsID.sizeof); - if (guid.Equals (nsIDOMWindow.NS_IDOMWINDOW_IID) || guid.Equals(nsIDOMWindow_1_9.NS_IDOMWINDOW_IID)) { + if (guid.Equals (nsIDOMWindow.NS_IDOMWINDOW_8_IID) || guid.Equals(nsIDOMWindow.NS_IDOMWINDOW_IID)) { int /*long*/[] aContentDOMWindow = new int /*long*/[1]; int rc = webBrowser.GetContentDOMWindow (aContentDOMWindow); if (rc != XPCOM.NS_OK) error (rc); @@ -3634,27 +3544,15 @@ int OnStateChange (int /*long*/ aWebProgress, int /*long*/ aRequest, int aStateF new nsISupports (result[0]).Release (); result[0] = 0; - if (!IsPre_2) { - nsIDOMWindow domWindow = new nsIDOMWindow (window[0]); - rc = domWindow.QueryInterface (nsIDOMEventTarget.NS_IDOMEVENTTARGET_IID, result); - domWindow.Release(); - } else { - nsIDOMWindow_1_9 domWindow = new nsIDOMWindow_1_9 (window[0]); - rc = domWindow.QueryInterface (nsIDOMEventTarget_1_9.NS_IDOMEVENTTARGET_IID, result); - domWindow.Release(); - } + nsIDOMWindow domWindow = new nsIDOMWindow (window[0]); + rc = domWindow.QueryInterface (!IsPre_4 ? nsIDOMEventTarget.NS_IDOMEVENTTARGET_8_IID : nsIDOMEventTarget.NS_IDOMEVENTTARGET_IID, result); + domWindow.Release(); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_ERROR_NO_INTERFACE); - if (!IsPre_2) { - nsIDOMEventTarget target = new nsIDOMEventTarget (result[0]); - hookDOMListeners (target, isTop); - target.Release (); - } else { - nsIDOMEventTarget_1_9 target = new nsIDOMEventTarget_1_9 (result[0]); - hookDOMListeners_1_9 (target, isTop); - target.Release (); - } + nsIDOMEventTarget target = new nsIDOMEventTarget (result[0]); + hookDOMListeners (target, isTop); + target.Release (); result[0] = 0; /* @@ -3792,27 +3690,15 @@ int OnStateChange (int /*long*/ aWebProgress, int /*long*/ aRequest, int aStateF new nsISupports (result[0]).Release (); result[0] = 0; - if (!IsPre_2) { - nsIDOMWindow domWindow = new nsIDOMWindow (window[0]); - rc = domWindow.QueryInterface (nsIDOMEventTarget.NS_IDOMEVENTTARGET_IID, result); - domWindow.Release(); - } else { - nsIDOMWindow_1_9 domWindow = new nsIDOMWindow_1_9 (window[0]); - rc = domWindow.QueryInterface (nsIDOMEventTarget_1_9.NS_IDOMEVENTTARGET_IID, result); - domWindow.Release(); - } + nsIDOMWindow domWindow = new nsIDOMWindow (window[0]); + rc = domWindow.QueryInterface (!IsPre_4 ? nsIDOMEventTarget.NS_IDOMEVENTTARGET_8_IID : nsIDOMEventTarget.NS_IDOMEVENTTARGET_IID, result); + domWindow.Release(); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_ERROR_NO_INTERFACE); - if (!IsPre_2) { - nsIDOMEventTarget target = new nsIDOMEventTarget (result[0]); - hookDOMListeners (target, isTop); - target.Release (); - } else { - nsIDOMEventTarget_1_9 target = new nsIDOMEventTarget_1_9 (result[0]); - hookDOMListeners_1_9 (target, isTop); - target.Release (); - } + nsIDOMEventTarget target = new nsIDOMEventTarget (result[0]); + hookDOMListeners (target, isTop); + target.Release (); result[0] = 0; } else { registerFunctionsOnState = 0; @@ -3908,19 +3794,13 @@ int OnStateChange (int /*long*/ aWebProgress, int /*long*/ aRequest, int aStateF new nsISupports (result[0]).Release (); result[0] = 0; - rc = domWindow.QueryInterface (!IsPre_2 ? nsIDOMEventTarget.NS_IDOMEVENTTARGET_IID : nsIDOMEventTarget_1_9.NS_IDOMEVENTTARGET_IID, result); + rc = domWindow.QueryInterface (!IsPre_4 ? nsIDOMEventTarget.NS_IDOMEVENTTARGET_8_IID : nsIDOMEventTarget.NS_IDOMEVENTTARGET_IID, result); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_ERROR_NO_INTERFACE); - if (!IsPre_2) { - nsIDOMEventTarget target = new nsIDOMEventTarget (result[0]); - hookDOMListeners (target, isTop); - target.Release (); - } else { - nsIDOMEventTarget_1_9 target = new nsIDOMEventTarget_1_9 (result[0]); - hookDOMListeners_1_9 (target, isTop); - target.Release (); - } + nsIDOMEventTarget target = new nsIDOMEventTarget (result[0]); + hookDOMListeners (target, isTop); + target.Release (); result[0] = 0; /* @@ -3969,21 +3849,13 @@ int OnLocationChange (int /*long*/ aWebProgress, int /*long*/ aRequest, int /*lo if (aDOMWindow[0] == 0) error (XPCOM.NS_ERROR_NO_INTERFACE); int /*long*/[] aTop = new int /*long*/[1]; - if (!IsPre_2) { - nsIDOMWindow domWindow = new nsIDOMWindow (aDOMWindow[0]); - rc = domWindow.GetTop (aTop); - domWindow.Release (); - nsIDOMWindow topWindow = new nsIDOMWindow (aTop[0]); - topWindow.Release (); - } else { - nsIDOMWindow_1_9 domWindow = new nsIDOMWindow_1_9 (aDOMWindow[0]); - rc = domWindow.GetTop (aTop); - domWindow.Release (); - if (rc != XPCOM.NS_OK) error (rc); - if (aTop[0] == 0) error (XPCOM.NS_ERROR_NO_INTERFACE); - nsIDOMWindow_1_9 topWindow = new nsIDOMWindow_1_9 (aTop[0]); - topWindow.Release (); - } + nsIDOMWindow domWindow = new nsIDOMWindow (aDOMWindow[0]); + rc = domWindow.GetTop (aTop); + domWindow.Release (); + if (rc != XPCOM.NS_OK) error (rc); + if (aTop[0] == 0) error (XPCOM.NS_ERROR_NO_INTERFACE); + nsIDOMWindow topWindow = new nsIDOMWindow (aTop[0]); + topWindow.Release (); nsIURI location = new nsIURI (aLocation); int /*long*/ aSpec = XPCOM.nsEmbedCString_new (); @@ -4343,26 +4215,17 @@ int FocusPrevElement () { int OnShowContextMenu (int aContextFlags, int /*long*/ aEvent, int /*long*/ aNode) { nsIDOMEvent domEvent = new nsIDOMEvent (aEvent); int /*long*/[] result = new int /*long*/[1]; - int rc = domEvent.QueryInterface (IsPre_2 ? nsIDOMMouseEvent_1_9.NS_IDOMMOUSEEVENT_IID : nsIDOMMouseEvent.NS_IDOMMOUSEEVENT_IID, result); + int rc = domEvent.QueryInterface (!IsPre_4 ? nsIDOMMouseEvent.NS_IDOMMOUSEEVENT_8_IID : nsIDOMMouseEvent.NS_IDOMMOUSEEVENT_IID, result); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); int[] aScreenX = new int[1], aScreenY = new int[1]; - if (!IsPre_2) { - nsIDOMMouseEvent domMouseEvent = new nsIDOMMouseEvent (result[0]); - rc = domMouseEvent.GetScreenX (aScreenX); - if (rc != XPCOM.NS_OK) error (rc); - rc = domMouseEvent.GetScreenY (aScreenY); - if (rc != XPCOM.NS_OK) error (rc); - domMouseEvent.Release (); - } else { - nsIDOMMouseEvent_1_9 domMouseEvent = new nsIDOMMouseEvent_1_9 (result[0]); - rc = domMouseEvent.GetScreenX (aScreenX); - if (rc != XPCOM.NS_OK) error (rc); - rc = domMouseEvent.GetScreenY (aScreenY); - if (rc != XPCOM.NS_OK) error (rc); - domMouseEvent.Release (); - } + nsIDOMMouseEvent domMouseEvent = new nsIDOMMouseEvent (result[0]); + rc = domMouseEvent.GetScreenX (aScreenX); + if (rc != XPCOM.NS_OK) error (rc); + rc = domMouseEvent.GetScreenY (aScreenY); + if (rc != XPCOM.NS_OK) error (rc); + domMouseEvent.Release (); Event event = new Event (); event.x = aScreenX[0]; @@ -4584,8 +4447,7 @@ int OnHideTooltip () { return XPCOM.NS_OK; } -/* nsIDOMEventListener */ -int HandleEvent_2 (int /*long*/ event) { +int HandleEvent (int /*long*/ event) { nsIDOMEvent domEvent = new nsIDOMEvent (event); int /*long*/ type = XPCOM.nsEmbedString_new (); int rc = domEvent.GetType (type); @@ -4616,7 +4478,7 @@ int HandleEvent_2 (int /*long*/ event) { if (XPCOM.DOMEVENT_KEYDOWN.equals (typeString)) { int /*long*/[] result = new int /*long*/[1]; - rc = domEvent.QueryInterface (nsIDOMKeyEvent.NS_IDOMKEYEVENT_IID, result); + rc = domEvent.QueryInterface (!IsPre_4 ? nsIDOMKeyEvent.NS_IDOMKEYEVENT_8_IID : nsIDOMKeyEvent.NS_IDOMKEYEVENT_IID, result); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); nsIDOMKeyEvent domKeyEvent = new nsIDOMKeyEvent (result[0]); @@ -4724,7 +4586,7 @@ int HandleEvent_2 (int /*long*/ event) { } int /*long*/[] result = new int /*long*/[1]; - rc = domEvent.QueryInterface (nsIDOMKeyEvent.NS_IDOMKEYEVENT_IID, result); + rc = domEvent.QueryInterface (!IsPre_4 ? nsIDOMKeyEvent.NS_IDOMKEYEVENT_8_IID : nsIDOMKeyEvent.NS_IDOMKEYEVENT_IID, result); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); nsIDOMKeyEvent domKeyEvent = new nsIDOMKeyEvent (result[0]); @@ -4780,7 +4642,7 @@ int HandleEvent_2 (int /*long*/ event) { if (XPCOM.DOMEVENT_KEYUP.equals (typeString)) { int /*long*/[] result = new int /*long*/[1]; - rc = domEvent.QueryInterface (nsIDOMKeyEvent.NS_IDOMKEYEVENT_IID, result); + rc = domEvent.QueryInterface (!IsPre_4 ? nsIDOMKeyEvent.NS_IDOMKEYEVENT_8_IID : nsIDOMKeyEvent.NS_IDOMKEYEVENT_IID, result); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); nsIDOMKeyEvent domKeyEvent = new nsIDOMKeyEvent (result[0]); @@ -4837,7 +4699,7 @@ int HandleEvent_2 (int /*long*/ event) { /* mouse event */ int /*long*/[] result = new int /*long*/[1]; - rc = domEvent.QueryInterface (nsIDOMMouseEvent.NS_IDOMMOUSEEVENT_IID, result); + rc = domEvent.QueryInterface (!IsPre_4 ? nsIDOMMouseEvent.NS_IDOMMOUSEEVENT_8_IID : nsIDOMMouseEvent.NS_IDOMMOUSEEVENT_IID, result); if (rc != XPCOM.NS_OK) error (rc); if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); nsIDOMMouseEvent domMouseEvent = new nsIDOMMouseEvent (result[0]); @@ -4952,381 +4814,6 @@ int HandleEvent_2 (int /*long*/ event) { return XPCOM.NS_OK; } -int HandleEvent_1_9 (int /*long*/ event) { - nsIDOMEvent_1_9 domEvent = new nsIDOMEvent_1_9 (event); - int /*long*/ type = XPCOM.nsEmbedString_new (); - int rc = domEvent.GetType (type); - if (rc != XPCOM.NS_OK) error (rc); - int length = XPCOM.nsEmbedString_Length (type); - int /*long*/ buffer = XPCOM.nsEmbedString_get (type); - char[] chars = new char[length]; - XPCOM.memmove (chars, buffer, length * 2); - String typeString = new String (chars); - XPCOM.nsEmbedString_delete (type); - - if (XPCOM.DOMEVENT_UNLOAD.equals (typeString)) { - int /*long*/[] result = new int /*long*/[1]; - rc = domEvent.GetCurrentTarget (result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); - - nsIDOMEventTarget target = new nsIDOMEventTarget (result[0]); - unhookDOMListeners (target); - target.Release (); - return XPCOM.NS_OK; - } - - if (XPCOM.DOMEVENT_FOCUS.equals (typeString)) { - delegate.handleFocus (); - return XPCOM.NS_OK; - } - - if (XPCOM.DOMEVENT_KEYDOWN.equals (typeString)) { - int /*long*/[] result = new int /*long*/[1]; - rc = domEvent.QueryInterface (nsIDOMKeyEvent_1_9.NS_IDOMKEYEVENT_IID, result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); - nsIDOMKeyEvent_1_9 domKeyEvent = new nsIDOMKeyEvent_1_9 (result[0]); - result[0] = 0; - - int[] aKeyCode = new int[1]; /* PRUint32 */ - rc = domKeyEvent.GetKeyCode (aKeyCode); - if (rc != XPCOM.NS_OK) error (rc); - int keyCode = translateKey (aKeyCode[0]); - - /* - * if keyCode == lastKeyCode then either a repeating key like Shift - * is being held or a key for which key events are not sent has been - * pressed. In both of these cases a KeyDown should not be sent. - */ - if (keyCode != lastKeyCode) { - lastKeyCode = keyCode; - switch (keyCode) { - case SWT.SHIFT: - case SWT.CONTROL: - case SWT.ALT: - case SWT.CAPS_LOCK: - case SWT.NUM_LOCK: - case SWT.SCROLL_LOCK: - case SWT.COMMAND: { - /* keypress events will not be received for these keys, so send KeyDowns for them now */ - int[] aAltKey = new int[1], aCtrlKey = new int[1], aShiftKey = new int[1], aMetaKey = new int[1]; /* PRBool */ - rc = domKeyEvent.GetAltKey (aAltKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domKeyEvent.GetCtrlKey (aCtrlKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domKeyEvent.GetShiftKey (aShiftKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domKeyEvent.GetMetaKey (aMetaKey); - if (rc != XPCOM.NS_OK) error (rc); - - Event keyEvent = new Event (); - keyEvent.widget = browser; - keyEvent.type = SWT.KeyDown; - keyEvent.keyCode = keyCode; - keyEvent.stateMask = (aAltKey[0] != 0 ? SWT.ALT : 0) | (aCtrlKey[0] != 0 ? SWT.CTRL : 0) | (aShiftKey[0] != 0 ? SWT.SHIFT : 0) | (aMetaKey[0] != 0 ? SWT.COMMAND : 0); - keyEvent.stateMask &= ~keyCode; /* remove current keydown if it's a state key */ - browser.notifyListeners (keyEvent.type, keyEvent); - if (!keyEvent.doit || browser.isDisposed ()) { - domEvent.PreventDefault (); - } - break; - } - default: { - /* - * If the keydown has Meta (but not Meta+Ctrl) as a modifier then send a KeyDown event for it here - * because a corresponding keypress event will not be received for it from the DOM. If the keydown - * does not have Meta as a modifier, or has Meta+Ctrl as a modifier, then then do nothing here - * because its KeyDown event will be sent from the keypress listener. - */ - int[] aMetaKey = new int[1]; /* PRBool */ - rc = domKeyEvent.GetMetaKey (aMetaKey); - if (rc != XPCOM.NS_OK) error (rc); - if (aMetaKey[0] != 0) { - int[] aCtrlKey = new int[1]; /* PRBool */ - rc = domKeyEvent.GetCtrlKey (aCtrlKey); - if (rc != XPCOM.NS_OK) error (rc); - if (aCtrlKey[0] == 0) { - int[] aAltKey = new int[1], aShiftKey = new int[1]; /* PRBool */ - rc = domKeyEvent.GetAltKey (aAltKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domKeyEvent.GetShiftKey (aShiftKey); - if (rc != XPCOM.NS_OK) error (rc); - - Event keyEvent = new Event (); - keyEvent.widget = browser; - keyEvent.type = SWT.KeyDown; - keyEvent.keyCode = lastKeyCode; - keyEvent.stateMask = (aAltKey[0] != 0 ? SWT.ALT : 0) | (aCtrlKey[0] != 0? SWT.CTRL : 0) | (aShiftKey[0] != 0? SWT.SHIFT : 0) | (aMetaKey[0] != 0? SWT.COMMAND : 0); - browser.notifyListeners (keyEvent.type, keyEvent); - if (!keyEvent.doit || browser.isDisposed ()) { - domEvent.PreventDefault (); - } - } - } - } - } - } - - domKeyEvent.Release (); - return XPCOM.NS_OK; - } - - if (XPCOM.DOMEVENT_KEYPRESS.equals (typeString)) { - /* - * if keydown could not determine a keycode for this key then it's a - * key for which key events are not sent (eg.- the Windows key) - */ - if (lastKeyCode == 0) return XPCOM.NS_OK; - - /* - * On linux only, unexpected keypress events are received for some - * modifier keys. The workaround is to ignore these events since - * KeyDown events are sent for these keys in the keydown listener. - */ - switch (lastKeyCode) { - case SWT.CAPS_LOCK: - case SWT.NUM_LOCK: - case SWT.SCROLL_LOCK: return XPCOM.NS_OK; - } - - int /*long*/[] result = new int /*long*/[1]; - rc = domEvent.QueryInterface (nsIDOMKeyEvent_1_9.NS_IDOMKEYEVENT_IID, result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); - nsIDOMKeyEvent_1_9 domKeyEvent = new nsIDOMKeyEvent_1_9 (result[0]); - result[0] = 0; - - int[] aAltKey = new int[1], aCtrlKey = new int[1], aShiftKey = new int[1], aMetaKey = new int[1]; /* PRBool */ - rc = domKeyEvent.GetAltKey (aAltKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domKeyEvent.GetCtrlKey (aCtrlKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domKeyEvent.GetShiftKey (aShiftKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domKeyEvent.GetMetaKey (aMetaKey); - if (rc != XPCOM.NS_OK) error (rc); - domKeyEvent.Release (); - - int[] aCharCode = new int[1]; /* PRUint32 */ - rc = domKeyEvent.GetCharCode (aCharCode); - if (rc != XPCOM.NS_OK) error (rc); - lastCharCode = aCharCode[0]; - if (lastCharCode == 0) { - switch (lastKeyCode) { - case SWT.TAB: lastCharCode = SWT.TAB; break; - case SWT.CR: lastCharCode = SWT.CR; break; - case SWT.BS: lastCharCode = SWT.BS; break; - case SWT.ESC: lastCharCode = SWT.ESC; break; - case SWT.DEL: lastCharCode = SWT.DEL; break; - } - } - if (aCtrlKey[0] != 0 && (0 <= lastCharCode && lastCharCode <= 0x7F)) { - if ('a' <= lastCharCode && lastCharCode <= 'z') lastCharCode -= 'a' - 'A'; - if (64 <= lastCharCode && lastCharCode <= 95) lastCharCode -= 64; - } - - Event keyEvent = new Event (); - keyEvent.widget = browser; - keyEvent.type = SWT.KeyDown; - keyEvent.keyCode = lastKeyCode; - keyEvent.character = (char)lastCharCode; - keyEvent.stateMask = (aAltKey[0] != 0 ? SWT.ALT : 0) | (aCtrlKey[0] != 0 ? SWT.CTRL : 0) | (aShiftKey[0] != 0 ? SWT.SHIFT : 0) | (aMetaKey[0] != 0 ? SWT.COMMAND : 0); - boolean doit = true; - if (delegate.sendTraverse ()) { - doit = sendKeyEvent (keyEvent); - } else { - browser.notifyListeners (keyEvent.type, keyEvent); - doit = keyEvent.doit; - } - if (!doit || browser.isDisposed ()) { - domEvent.PreventDefault (); - } - return XPCOM.NS_OK; - } - - if (XPCOM.DOMEVENT_KEYUP.equals (typeString)) { - int /*long*/[] result = new int /*long*/[1]; - rc = domEvent.QueryInterface (nsIDOMKeyEvent_1_9.NS_IDOMKEYEVENT_IID, result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); - nsIDOMKeyEvent_1_9 domKeyEvent = new nsIDOMKeyEvent_1_9 (result[0]); - result[0] = 0; - - int[] aKeyCode = new int[1]; /* PRUint32 */ - rc = domKeyEvent.GetKeyCode (aKeyCode); - if (rc != XPCOM.NS_OK) error (rc); - int keyCode = translateKey (aKeyCode[0]); - if (keyCode == 0) { - /* indicates a key for which key events are not sent */ - domKeyEvent.Release (); - return XPCOM.NS_OK; - } - if (keyCode != lastKeyCode) { - /* keyup does not correspond to the last keydown */ - lastKeyCode = keyCode; - lastCharCode = 0; - } - - int[] aAltKey = new int[1], aCtrlKey = new int[1], aShiftKey = new int[1], aMetaKey = new int[1]; /* PRBool */ - rc = domKeyEvent.GetAltKey (aAltKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domKeyEvent.GetCtrlKey (aCtrlKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domKeyEvent.GetShiftKey (aShiftKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domKeyEvent.GetMetaKey (aMetaKey); - if (rc != XPCOM.NS_OK) error (rc); - domKeyEvent.Release (); - - Event keyEvent = new Event (); - keyEvent.widget = browser; - keyEvent.type = SWT.KeyUp; - keyEvent.keyCode = lastKeyCode; - keyEvent.character = (char)lastCharCode; - keyEvent.stateMask = (aAltKey[0] != 0 ? SWT.ALT : 0) | (aCtrlKey[0] != 0 ? SWT.CTRL : 0) | (aShiftKey[0] != 0 ? SWT.SHIFT : 0) | (aMetaKey[0] != 0 ? SWT.COMMAND : 0); - switch (lastKeyCode) { - case SWT.SHIFT: - case SWT.CONTROL: - case SWT.ALT: - case SWT.COMMAND: { - keyEvent.stateMask |= lastKeyCode; - } - } - browser.notifyListeners (keyEvent.type, keyEvent); - if (!keyEvent.doit || browser.isDisposed ()) { - domEvent.PreventDefault (); - } - lastKeyCode = lastCharCode = 0; - return XPCOM.NS_OK; - } - - /* mouse event */ - - int /*long*/[] result = new int /*long*/[1]; - rc = domEvent.QueryInterface (nsIDOMMouseEvent_1_9.NS_IDOMMOUSEEVENT_IID, result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] == 0) error (XPCOM.NS_NOINTERFACE); - nsIDOMMouseEvent_1_9 domMouseEvent = new nsIDOMMouseEvent_1_9 (result[0]); - result[0] = 0; - - /* - * MouseOver and MouseOut events are fired any time the mouse enters or exits - * any element within the Browser. To ensure that SWT events are only - * fired for mouse movements into or out of the Browser, do not fire an - * event if the element being exited (on MouseOver) or entered (on MouseExit) - * is within the Browser. - */ - if (XPCOM.DOMEVENT_MOUSEOVER.equals (typeString) || XPCOM.DOMEVENT_MOUSEOUT.equals (typeString)) { - rc = domMouseEvent.GetRelatedTarget (result); - if (rc != XPCOM.NS_OK) error (rc); - if (result[0] != 0) { - new nsISupports (result[0]).Release (); - domMouseEvent.Release (); - return XPCOM.NS_OK; - } - } - - int[] aScreenX = new int[1], aScreenY = new int[1]; /* PRInt32 */ - - /* - * The position of mouse events is received in screen-relative coordinates - * in order to handle pages with frames, since frames express their event - * coordinates relative to themselves rather than relative to their top- - * level page. Convert screen-relative coordinates to be browser-relative. - */ - rc = domMouseEvent.GetScreenX (aScreenX); - if (rc != XPCOM.NS_OK) error (rc); - rc = domMouseEvent.GetScreenY (aScreenY); - if (rc != XPCOM.NS_OK) error (rc); - Point position = new Point (aScreenX[0], aScreenY[0]); - position = browser.getDisplay ().map (null, browser, position); - - int[] aDetail = new int[1]; /* PRInt32 */ - rc = domMouseEvent.GetDetail (aDetail); - if (rc != XPCOM.NS_OK) error (rc); - short[] aButton = new short[1]; /* PRUint16 */ - rc = domMouseEvent.GetButton (aButton); - if (rc != XPCOM.NS_OK) error (rc); - int[] aAltKey = new int[1], aCtrlKey = new int[1], aShiftKey = new int[1], aMetaKey = new int[1]; /* PRBool */ - rc = domMouseEvent.GetAltKey (aAltKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domMouseEvent.GetCtrlKey (aCtrlKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domMouseEvent.GetShiftKey (aShiftKey); - if (rc != XPCOM.NS_OK) error (rc); - rc = domMouseEvent.GetMetaKey (aMetaKey); - if (rc != XPCOM.NS_OK) error (rc); - domMouseEvent.Release (); - - Event mouseEvent = new Event (); - mouseEvent.widget = browser; - mouseEvent.x = position.x; mouseEvent.y = position.y; - mouseEvent.stateMask = (aAltKey[0] != 0 ? SWT.ALT : 0) | (aCtrlKey[0] != 0 ? SWT.CTRL : 0) | (aShiftKey[0] != 0 ? SWT.SHIFT : 0) | (aMetaKey[0] != 0 ? SWT.COMMAND : 0); - - if (XPCOM.DOMEVENT_MOUSEDOWN.equals (typeString)) { - delegate.handleMouseDown (); - mouseEvent.type = SWT.MouseDown; - mouseEvent.button = aButton[0] + 1; - mouseEvent.count = aDetail[0]; - } else if (XPCOM.DOMEVENT_MOUSEUP.equals (typeString)) { - /* - * Bug on OSX. For some reason multiple mouseup events come from the DOM - * when button 3 is released on OSX. The first of these events has a count - * detail and the others do not. The workaround is to not fire received - * button 3 mouseup events that do not have a count since mouse events - * without a click count are not valid. - */ - int button = aButton[0] + 1; - int count = aDetail[0]; - if (count == 0 && button == 3) return XPCOM.NS_OK; - mouseEvent.type = SWT.MouseUp; - mouseEvent.button = button; - mouseEvent.count = count; - } else if (XPCOM.DOMEVENT_MOUSEMOVE.equals (typeString)) { - mouseEvent.type = SWT.MouseMove; - } else if (XPCOM.DOMEVENT_MOUSEWHEEL.equals (typeString)) { - mouseEvent.type = SWT.MouseWheel; - mouseEvent.count = -aDetail[0]; - } else if (XPCOM.DOMEVENT_MOUSEOVER.equals (typeString)) { - mouseEvent.type = SWT.MouseEnter; - } else if (XPCOM.DOMEVENT_MOUSEOUT.equals (typeString)) { - mouseEvent.type = SWT.MouseExit; - } else if (XPCOM.DOMEVENT_MOUSEDRAG.equals (typeString)) { - mouseEvent.type = SWT.DragDetect; - mouseEvent.button = aButton[0] + 1; - switch (mouseEvent.button) { - case 1: mouseEvent.stateMask |= SWT.BUTTON1; break; - case 2: mouseEvent.stateMask |= SWT.BUTTON2; break; - case 3: mouseEvent.stateMask |= SWT.BUTTON3; break; - case 4: mouseEvent.stateMask |= SWT.BUTTON4; break; - case 5: mouseEvent.stateMask |= SWT.BUTTON5; break; - } - } - - browser.notifyListeners (mouseEvent.type, mouseEvent); - if (browser.isDisposed ()) return XPCOM.NS_OK; - if (aDetail[0] == 2 && XPCOM.DOMEVENT_MOUSEDOWN.equals (typeString)) { - mouseEvent = new Event (); - mouseEvent.widget = browser; - mouseEvent.x = position.x; mouseEvent.y = position.y; - mouseEvent.stateMask = (aAltKey[0] != 0 ? SWT.ALT : 0) | (aCtrlKey[0] != 0 ? SWT.CTRL : 0) | (aShiftKey[0] != 0 ? SWT.SHIFT : 0) | (aMetaKey[0] != 0 ? SWT.COMMAND : 0); - mouseEvent.type = SWT.MouseDoubleClick; - mouseEvent.button = aButton[0] + 1; - mouseEvent.count = aDetail[0]; - browser.notifyListeners (mouseEvent.type, mouseEvent); - } - return XPCOM.NS_OK; -} - -int HandleEvent (int /*long*/ event) { - if (!IsPre_2) { - return HandleEvent_2(event); - } else { - return HandleEvent_1_9(event); - } -} - /* nsIBadCertListener2 */ int NotifyCertProblem (int /*long*/ socketInfo, int /*long*/ status, int /*long*/ targetSite, int /*long*/ _suppressError) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/PromptAuth2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/PromptAuth2.java index a0397e7c19..0163c1f575 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/PromptAuth2.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/PromptAuth2.java @@ -93,7 +93,7 @@ Browser getBrowser() { if (rc == XPCOM.NS_OK && result[0] != 0) { nsIComponentManager componentManager = new nsIComponentManager (result[0]); result[0] = 0; - componentManager.GetClassObject(XPCOM.NS_IWEBBROWSER_CID, nsIWebBrowser.NS_IWEBBROWSER_IID, result); + componentManager.GetClassObject(XPCOM.NS_IWEBBROWSER_CID, !Mozilla.IsPre_4 ? nsIWebBrowser.NS_IWEBBROWSER_8_IID : nsIWebBrowser.NS_IWEBBROWSER_IID, result); if (rc == XPCOM.NS_OK && result[0] != 0) { nsIWebBrowser browser = new nsIWebBrowser(result[0]); result[0] = 0; @@ -101,7 +101,7 @@ Browser getBrowser() { if (rc == XPCOM.NS_OK && result[0] != 0) { return Mozilla.getBrowser(result[0]); } - } + } } return null; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/PromptDialog.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/PromptDialog.java index b0c515b513..d7937cac15 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/PromptDialog.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/PromptDialog.java @@ -172,17 +172,10 @@ class PromptDialog extends Dialog { if (rc != XPCOM.NS_OK) Mozilla.error (rc); if (result[0] == 0) Mozilla.error (XPCOM.NS_NOINTERFACE); - if (Mozilla.IsPre_2) { - nsIDOMWindow_1_9 window = new nsIDOMWindow_1_9(result[0]); - rc = dialogs.ViewCert(window.getAddress(), cert.getAddress()); - browser.getDisplay().timerExec(-1, runnable); - window.Release(); - } else { - nsIDOMWindow window = new nsIDOMWindow(result[0]); - rc = dialogs.ViewCert(window.getAddress(), cert.getAddress()); - browser.getDisplay().timerExec(-1, runnable); - window.Release(); - } + nsIDOMWindow window = new nsIDOMWindow(result[0]); + rc = dialogs.ViewCert(window.getAddress(), cert.getAddress()); + browser.getDisplay().timerExec(-1, runnable); + window.Release(); result[0] = 0; dialogs.Release(); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Prompter.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Prompter.java index 2c3b5c9ba9..e06fab5783 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Prompter.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/browser/Prompter.java @@ -150,7 +150,7 @@ Browser getBrowser() { if (rc == XPCOM.NS_OK && result[0] != 0) { nsIComponentManager componentManager = new nsIComponentManager (result[0]); result[0] = 0; - componentManager.GetClassObject(XPCOM.NS_IWEBBROWSER_CID, nsIWebBrowser.NS_IWEBBROWSER_IID, result); + componentManager.GetClassObject(XPCOM.NS_IWEBBROWSER_CID, !Mozilla.IsPre_4 ? nsIWebBrowser.NS_IWEBBROWSER_8_IID : nsIWebBrowser.NS_IWEBBROWSER_IID, result); if (rc == XPCOM.NS_OK && result[0] != 0) { nsIWebBrowser browser = new nsIWebBrowser(result[0]); result[0] = 0; diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/XPCOM.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/XPCOM.java index a2bc0131e6..7ee5d5ee41 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/XPCOM.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/XPCOM.java @@ -674,6 +674,15 @@ static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long[] arg0) { lock.unlock(); } } +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, short arg0); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, short arg0) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0); + } finally { + lock.unlock(); + } +} static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, short[] arg0); static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, short[] arg0) { lock.lock(); @@ -747,6 +756,15 @@ static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, long[] a lock.unlock(); } } +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, short[] arg1); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, short[] arg1) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1); + } finally { + lock.unlock(); + } +} static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int[] arg1); static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int[] arg1) { lock.lock(); @@ -756,6 +774,15 @@ static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int[] ar lock.unlock(); } } +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, short[] arg1); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, short[] arg1) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1); + } finally { + lock.unlock(); + } +} static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, byte[] arg0, int[] arg1); static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, byte[] arg0, int[] arg1) { lock.lock(); @@ -792,6 +819,15 @@ static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, byte[] arg0, int ar lock.unlock(); } } +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, byte[] arg0, short arg1); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, byte[] arg0, short arg1) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1); + } finally { + lock.unlock(); + } +} static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, nsID arg1); static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, nsID arg1) { lock.lock(); @@ -992,25 +1028,6 @@ static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long [] arg0, long } } -static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, short arg0, int arg1, int arg2, int arg3); -static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, short arg0, int arg1, int arg2, int arg3) { - lock.lock(); - try { - return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2, arg3); - } finally { - lock.unlock(); - } -} -static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, short arg0, long arg1, int arg2, long arg3); -static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, short arg0, long arg1, int arg2, long arg3) { - lock.lock(); - try { - return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2, arg3); - } finally { - lock.unlock(); - } -} - static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, int[] arg0, long[] arg1, int[] arg2); static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, int[] arg0, long[] arg1, int[] arg2) { lock.lock(); @@ -1308,6 +1325,34 @@ static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, byte[] a lock.unlock(); } } +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, short arg2); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, short arg2) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2); + } finally { + lock.unlock(); + } +} +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, long arg1, short arg2); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, long arg1, short arg2) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2); + } finally { + lock.unlock(); + } +} +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1, int arg2); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1, int arg2) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2); + } finally { + lock.unlock(); + } +} + static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, byte[] arg2); static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, byte[] arg2) { lock.lock(); @@ -1389,7 +1434,43 @@ static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, byte[] a lock.unlock(); } } +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, float arg0, float arg1, int[] arg2); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, float arg0, float arg1, int[] arg2) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2); + } finally { + lock.unlock(); + } +} +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, float arg0, float arg1, long[] arg2); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, float arg0, float arg1, long[] arg2) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2); + } finally { + lock.unlock(); + } +} +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, short arg0, int arg1, int arg2, int arg3); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, short arg0, int arg1, int arg2, int arg3) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2, arg3); + } finally { + lock.unlock(); + } +} +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, short arg0, long arg1, int arg2, long arg3); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, short arg0, long arg1, int arg2, long arg3) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2, arg3); + } finally { + lock.unlock(); + } +} static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, byte[] arg0, int arg1, nsID arg2, int[] arg3); static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, byte[] arg0, int arg1, nsID arg2, int[] arg3) { lock.lock(); @@ -1733,6 +1814,33 @@ static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, long arg lock.unlock(); } } +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, long arg1, long arg2, long arg3, long[] arg4); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, long arg1, long arg2, long arg3, long[] arg4) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2, arg3, arg4); + } finally { + lock.unlock(); + } +} +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1, long arg2, int arg3, long[] arg4); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1, long arg2, int arg3, long[] arg4) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2, arg3, arg4); + } finally { + lock.unlock(); + } +} +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1, int arg2, long arg3, int arg4); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1, int arg2, long arg3, int arg4) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2, arg3, arg4); + } finally { + lock.unlock(); + } +} static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, int arg2, int arg3, int arg4); static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, int arg2, int arg3, int arg4) { lock.lock(); @@ -2234,6 +2342,15 @@ static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, long arg1 lock.unlock(); } } +static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1, int arg2, int arg3, int arg4, int arg5, int arg6, int[] arg7); +static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, long arg0, int arg1, int arg2, int arg3, int arg4, int arg5, int arg6, int[] arg7) { + lock.lock(); + try { + return _VtblCall(fnNumber, ppVtbl, arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7); + } finally { + lock.unlock(); + } +} static final native int _VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5, char[] arg6, int[] arg7, int[] arg8); static final int VtblCall(int fnNumber, int /*long*/ ppVtbl, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5, char[] arg6, int[] arg7, int[] arg8) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIAuthInformation.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIAuthInformation.java index 204179092c..74440ef863 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIAuthInformation.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIAuthInformation.java @@ -42,11 +42,8 @@ public class nsIAuthInformation extends nsISupports { } public static final int AUTH_HOST = 1; - public static final int AUTH_PROXY = 2; - public static final int NEED_DOMAIN = 4; - public static final int ONLY_PASSWORD = 8; public int GetFlags(int[] aFlags) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIAuthPrompt2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIAuthPrompt2.java index ee29667925..7eccae58a0 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIAuthPrompt2.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIAuthPrompt2.java @@ -22,7 +22,7 @@ * * IBM * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. + * - Copyright (C) 2011 IBM Corp. All Rights Reserved. * * ***** END LICENSE BLOCK ***** */ package org.eclipse.swt.internal.mozilla; @@ -42,9 +42,7 @@ public class nsIAuthPrompt2 extends nsISupports { } public static final int LEVEL_NONE = 0; - public static final int LEVEL_PW_ENCRYPTED = 1; - public static final int LEVEL_SECURE = 2; public int PromptAuth(int /*long*/ aParent, int /*long*/ aChannel, int level, int /*long*/ authInfo, char[] checkboxLabel, int[] checkValue, int[] _retval) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIBadCertListener2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIBadCertListener2.java index 361bc5d15b..cc6b530b64 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIBadCertListener2.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIBadCertListener2.java @@ -37,11 +37,11 @@ public class nsIBadCertListener2 extends nsISupports { public static final nsID NS_IBADCERTLISTENER2_IID = new nsID(NS_IBADCERTLISTENER2_IID_STR); - public nsIBadCertListener2(int /*long*/ address) { + public nsIBadCertListener2(int /*long*/ address) { super(address); } public int NotifyCertProblem(int /*long*/ socketInfo, int /*long*/ status, int /*long*/ targetSite, int[] _retval) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), socketInfo, status, targetSite, _retval); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICertOverrideService.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICertOverrideService.java index bd5752a560..29cba4536a 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICertOverrideService.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICertOverrideService.java @@ -37,14 +37,12 @@ public class nsICertOverrideService extends nsISupports { public static final nsID NS_ICERTOVERRIDESERVICE_IID = new nsID(NS_ICERTOVERRIDESERVICE_IID_STR); - public nsICertOverrideService(int /*long*/ address) { + public nsICertOverrideService(int /*long*/ address) { super(address); } public static final int ERROR_UNTRUSTED = 1; - public static final int ERROR_MISMATCH = 2; - public static final int ERROR_TIME = 4; public int RememberValidityOverride(int /*long*/ aHostName, int aPort, int /*long*/ aCert, int aOverrideBits, int aTemporary) { @@ -70,4 +68,4 @@ public class nsICertOverrideService extends nsISupports { public int IsCertUsedForOverrides(int /*long*/ aCert, int aCheckTemporaries, int aCheckPermanents, int[] _retval) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aCert, aCheckTemporaries, aCheckPermanents, _retval); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICertificateDialogs.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICertificateDialogs.java index 44d581d4bd..6faa4b8e40 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICertificateDialogs.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICertificateDialogs.java @@ -64,4 +64,4 @@ public class nsICertificateDialogs extends nsISupports { public int CrlImportStatusDialog(int /*long*/ ctx, int /*long*/ crl) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), ctx, crl); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIChannel.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIChannel.java index 5868a23a25..98cef8f59d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIChannel.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIChannel.java @@ -106,14 +106,9 @@ public class nsIChannel extends nsIRequest { } public static final int LOAD_DOCUMENT_URI = 65536; - public static final int LOAD_RETARGETED_DOCUMENT_URI = 131072; - public static final int LOAD_REPLACE = 262144; - public static final int LOAD_INITIAL_DOCUMENT_URI = 524288; - public static final int LOAD_TARGETED = 1048576; - public static final int LOAD_CALL_CONTENT_SNIFFERS = 2097152; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIClassInfo.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIClassInfo.java index 180f72101d..0d5515ac2d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIClassInfo.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIClassInfo.java @@ -66,19 +66,12 @@ public class nsIClassInfo extends nsISupports { } public static final int SINGLETON = 1; - public static final int THREADSAFE = 2; - public static final int MAIN_THREAD_ONLY = 4; - public static final int DOM_OBJECT = 8; - public static final int PLUGIN_OBJECT = 16; - public static final int EAGER_CLASSINFO = 32; - public static final int CONTENT_NODE = 64; - // public static final int RESERVED = 2147483648; public int GetFlags(int[] aFlags) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIComponentManager.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIComponentManager.java index 0dd1e04636..30c56a131f 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIComponentManager.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIComponentManager.java @@ -56,4 +56,4 @@ public class nsIComponentManager extends nsISupports { public int CreateInstanceByContractID(byte[] aContractID, int /*long*/ aDelegate, nsID aIID, int /*long*/[] result) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aContractID, aDelegate, aIID, result); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIContextMenuListener.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIContextMenuListener.java index b29155e9a4..1475e79b96 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIContextMenuListener.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIContextMenuListener.java @@ -42,18 +42,13 @@ public class nsIContextMenuListener extends nsISupports { } public static final int CONTEXT_NONE = 0; - public static final int CONTEXT_LINK = 1; - public static final int CONTEXT_IMAGE = 2; - public static final int CONTEXT_DOCUMENT = 4; - public static final int CONTEXT_TEXT = 8; - public static final int CONTEXT_INPUT = 16; public int OnShowContextMenu(int aContextFlags, int /*long*/ aEvent, int /*long*/ aNode) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), aContextFlags, aEvent, aNode); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICookie.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICookie.java index 77eb6d2b10..bc86c7d2a8 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICookie.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICookie.java @@ -70,13 +70,9 @@ public class nsICookie extends nsISupports { } public static final int STATUS_UNKNOWN = 0; - public static final int STATUS_ACCEPTED = 1; - public static final int STATUS_DOWNGRADED = 2; - public static final int STATUS_FLAGGED = 3; - public static final int STATUS_REJECTED = 4; public int GetStatus(int /*long*/ aStatus) { @@ -84,15 +80,10 @@ public class nsICookie extends nsISupports { } public static final int POLICY_UNKNOWN = 0; - public static final int POLICY_NONE = 1; - public static final int POLICY_NO_CONSENT = 2; - public static final int POLICY_IMPLICIT_CONSENT = 3; - public static final int POLICY_EXPLICIT_CONSENT = 4; - public static final int POLICY_NO_II = 5; public int GetPolicy(int /*long*/ aPolicy) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICookieService_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICookieService_1_9.java index 429bba25f8..5a5dcb541c 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICookieService_1_9.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsICookieService_1_9.java @@ -27,7 +27,7 @@ * ***** END LICENSE BLOCK ***** */ package org.eclipse.swt.internal.mozilla; -public class nsICookieService_1_9 extends nsISupports { +public class nsICookieService_1_9 extends nsISupports { static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 4; @@ -37,7 +37,7 @@ public class nsICookieService_1_9 extends nsISupports { public static final nsID NS_ICOOKIESERVICE_IID = new nsID(NS_ICOOKIESERVICE_IID_STR); - public nsICookieService_1_9(int /*long*/ address) { + public nsICookieService_1_9(int /*long*/ address) { super(address); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMDocument.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMDocument.java index 662613c0b7..99881594bb 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMDocument.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMDocument.java @@ -27,7 +27,7 @@ * ***** END LICENSE BLOCK ***** */
package org.eclipse.swt.internal.mozilla;
-public class nsIDOMDocument extends nsIDOMNode {
+public class nsIDOMDocument extends nsIDOMNode {
static final int LAST_METHOD_ID = nsIDOMNode.LAST_METHOD_ID + 17;
@@ -37,7 +37,7 @@ public class nsIDOMDocument extends nsIDOMNode { public static final nsID NS_IDOMDOCUMENT_IID =
new nsID(NS_IDOMDOCUMENT_IID_STR);
- public nsIDOMDocument(int /*long*/ address) {
+ public nsIDOMDocument(int /*long*/ address) {
super(address);
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMElement.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMElement.java index 2116d320d4..1f975f285c 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMElement.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMElement.java @@ -27,7 +27,7 @@ * ***** END LICENSE BLOCK ***** */
package org.eclipse.swt.internal.mozilla;
-public class nsIDOMElement extends nsIDOMNode {
+public class nsIDOMElement extends nsIDOMNode {
static final int LAST_METHOD_ID = nsIDOMNode.LAST_METHOD_ID + 16;
@@ -37,7 +37,7 @@ public class nsIDOMElement extends nsIDOMNode { public static final nsID NS_IDOMELEMENT_IID =
new nsID(NS_IDOMELEMENT_IID_STR);
- public nsIDOMElement(int /*long*/ address) {
+ public nsIDOMElement(int /*long*/ address) {
super(address);
}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEvent.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEvent.java index 406eaf0de1..c5f95b6eea 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEvent.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEvent.java @@ -29,22 +29,26 @@ package org.eclipse.swt.internal.mozilla; public class nsIDOMEvent extends nsISupports { - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 11; + static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + (Is8 ? 11 : 10); public static final String NS_IDOMEVENT_IID_STR = + "a66b7b80-ff46-bd97-0080-5f8ae38add32"; + + public static final String NS_IDOMEVENT_8_IID_STR = "548137e8-fd2c-48c4-8635-3033f7db79e0"; public static final nsID NS_IDOMEVENT_IID = new nsID(NS_IDOMEVENT_IID_STR); + public static final nsID NS_IDOMEVENT_8_IID = + new nsID(NS_IDOMEVENT_8_IID_STR); + public nsIDOMEvent(int /*long*/ address) { super(address); } public static final int CAPTURING_PHASE = 1; - public static final int AT_TARGET = 2; - public static final int BUBBLING_PHASE = 3; public int GetType(int /*long*/ aType) { @@ -71,7 +75,7 @@ public class nsIDOMEvent extends nsISupports { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aCancelable); } - public int GetTimeStamp(int /*long*/[] aTimeStamp) { + public int GetTimeStamp(int /*long*/ aTimeStamp) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aTimeStamp); } @@ -88,6 +92,7 @@ public class nsIDOMEvent extends nsISupports { } public int GetDefaultPrevented(int[] aDefaultPrevented) { + if (!Is8) return XPCOM.NS_COMFALSE; return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 11, getAddress(), aDefaultPrevented); } } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEventTarget.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEventTarget.java index 45e8375d07..92f48f2254 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEventTarget.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEventTarget.java @@ -32,16 +32,28 @@ public class nsIDOMEventTarget extends nsISupports { static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 3; public static final String NS_IDOMEVENTTARGET_IID_STR = - "1797d5a4-b12a-428d-9eef-a0e13839728c"; + "1c773b30-d1cf-11d2-bd95-00805f8ae3f4"; + public static final String NS_IDOMEVENTTARGET_8_IID_STR = + "1797d5a4-b12a-428d-9eef-a0e13839728c"; + public static final nsID NS_IDOMEVENTTARGET_IID = new nsID(NS_IDOMEVENTTARGET_IID_STR); + public static final nsID NS_IDOMEVENTTARGET_8_IID = + new nsID(NS_IDOMEVENTTARGET_8_IID_STR); + public nsIDOMEventTarget(int /*long*/ address) { super(address); } + public int AddEventListener(int /*long*/ type, int /*long*/ listener, int useCapture) { + if (Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), type, listener, useCapture); + } + public int AddEventListener(int /*long*/ type, int /*long*/ listener, int useCapture, int wantsUntrusted, int _argc) { + if (!Is8) return AddEventListener(type, listener, useCapture); return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), type, listener, useCapture, wantsUntrusted, _argc); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEventTarget_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEventTarget_1_9.java deleted file mode 100644 index 8441ece789..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEventTarget_1_9.java +++ /dev/null @@ -1,55 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIDOMEventTarget_1_9 extends nsISupports { - - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 3; - - public static final String NS_IDOMEVENTTARGET_IID_STR = - "1c773b30-d1cf-11d2-bd95-00805f8ae3f4"; - - public static final nsID NS_IDOMEVENTTARGET_IID = - new nsID(NS_IDOMEVENTTARGET_IID_STR); - - public nsIDOMEventTarget_1_9(int /*long*/ address) { - super(address); - } - - public int AddEventListener(int /*long*/ type, int /*long*/ listener, int useCapture) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), type, listener, useCapture); - } - - public int RemoveEventListener(int /*long*/ type, int /*long*/ listener, int useCapture) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), type, listener, useCapture); - } - - public int DispatchEvent(int /*long*/ evt, int[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), evt, _retval); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEvent_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEvent_1_9.java deleted file mode 100644 index 341723d0c7..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMEvent_1_9.java +++ /dev/null @@ -1,89 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIDOMEvent_1_9 extends nsISupports { - - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 10; - - public static final String NS_IDOMEVENT_IID_STR = - "a66b7b80-ff46-bd97-0080-5f8ae38add32"; - - public static final nsID NS_IDOMEVENT_IID = - new nsID(NS_IDOMEVENT_IID_STR); - - public nsIDOMEvent_1_9(int /*long*/ address) { - super(address); - } - - public static final int CAPTURING_PHASE = 1; - - public static final int AT_TARGET = 2; - - public static final int BUBBLING_PHASE = 3; - - public int GetType(int /*long*/ aType) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), aType); - } - - public int GetTarget(int /*long*/[] aTarget) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), aTarget); - } - - public int GetCurrentTarget(int /*long*/[] aCurrentTarget) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), aCurrentTarget); - } - - public int GetEventPhase(short[] aEventPhase) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aEventPhase); - } - - public int GetBubbles(int[] aBubbles) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress(), aBubbles); - } - - public int GetCancelable(int[] aCancelable) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aCancelable); - } - - public int GetTimeStamp(int /*long*/[] aTimeStamp) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aTimeStamp); - } - - public int StopPropagation() { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress()); - } - - public int PreventDefault() { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 9, getAddress()); - } - - public int InitEvent(int /*long*/ eventTypeArg, int canBubbleArg, int cancelableArg) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 10, getAddress(), eventTypeArg, canBubbleArg, cancelableArg); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMKeyEvent.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMKeyEvent.java index c0ef8c5cd4..b09a1ddfa0 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMKeyEvent.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMKeyEvent.java @@ -32,242 +32,153 @@ public class nsIDOMKeyEvent extends nsIDOMUIEvent { static final int LAST_METHOD_ID = nsIDOMUIEvent.LAST_METHOD_ID + 7; public static final String NS_IDOMKEYEVENT_IID_STR = - "e44d7977-20f2-442e-bc13-0f2f52992a4c"; + "028e0e6e-8b01-11d3-aae7-0010838a3123"; + public static final String NS_IDOMKEYEVENT_8_IID_STR = + "e44d7977-20f2-442e-bc13-0f2f52992a4c"; + public static final nsID NS_IDOMKEYEVENT_IID = new nsID(NS_IDOMKEYEVENT_IID_STR); + public static final nsID NS_IDOMKEYEVENT_8_IID = + new nsID(NS_IDOMKEYEVENT_8_IID_STR); + public nsIDOMKeyEvent(int /*long*/ address) { super(address); } public static final int DOM_VK_CANCEL = 3; - public static final int DOM_VK_HELP = 6; - public static final int DOM_VK_BACK_SPACE = 8; - public static final int DOM_VK_TAB = 9; - public static final int DOM_VK_CLEAR = 12; - public static final int DOM_VK_RETURN = 13; - public static final int DOM_VK_ENTER = 14; - public static final int DOM_VK_SHIFT = 16; - public static final int DOM_VK_CONTROL = 17; - public static final int DOM_VK_ALT = 18; - public static final int DOM_VK_PAUSE = 19; - public static final int DOM_VK_CAPS_LOCK = 20; - public static final int DOM_VK_ESCAPE = 27; - public static final int DOM_VK_SPACE = 32; - public static final int DOM_VK_PAGE_UP = 33; - public static final int DOM_VK_PAGE_DOWN = 34; - public static final int DOM_VK_END = 35; - public static final int DOM_VK_HOME = 36; - public static final int DOM_VK_LEFT = 37; - public static final int DOM_VK_UP = 38; - public static final int DOM_VK_RIGHT = 39; - public static final int DOM_VK_DOWN = 40; - public static final int DOM_VK_PRINTSCREEN = 44; - public static final int DOM_VK_INSERT = 45; - public static final int DOM_VK_DELETE = 46; - public static final int DOM_VK_0 = 48; - public static final int DOM_VK_1 = 49; - public static final int DOM_VK_2 = 50; - public static final int DOM_VK_3 = 51; - public static final int DOM_VK_4 = 52; - public static final int DOM_VK_5 = 53; - public static final int DOM_VK_6 = 54; - public static final int DOM_VK_7 = 55; - public static final int DOM_VK_8 = 56; - public static final int DOM_VK_9 = 57; - public static final int DOM_VK_SEMICOLON = 59; - public static final int DOM_VK_EQUALS = 61; - public static final int DOM_VK_A = 65; - public static final int DOM_VK_B = 66; - public static final int DOM_VK_C = 67; - public static final int DOM_VK_D = 68; - public static final int DOM_VK_E = 69; - public static final int DOM_VK_F = 70; - public static final int DOM_VK_G = 71; - public static final int DOM_VK_H = 72; - public static final int DOM_VK_I = 73; - public static final int DOM_VK_J = 74; - public static final int DOM_VK_K = 75; - public static final int DOM_VK_L = 76; - public static final int DOM_VK_M = 77; - public static final int DOM_VK_N = 78; - public static final int DOM_VK_O = 79; - public static final int DOM_VK_P = 80; - public static final int DOM_VK_Q = 81; - public static final int DOM_VK_R = 82; - public static final int DOM_VK_S = 83; - public static final int DOM_VK_T = 84; - public static final int DOM_VK_U = 85; - public static final int DOM_VK_V = 86; - public static final int DOM_VK_W = 87; - public static final int DOM_VK_X = 88; - public static final int DOM_VK_Y = 89; - public static final int DOM_VK_Z = 90; - public static final int DOM_VK_NUMPAD0 = 96; - public static final int DOM_VK_NUMPAD1 = 97; - public static final int DOM_VK_NUMPAD2 = 98; - public static final int DOM_VK_NUMPAD3 = 99; - public static final int DOM_VK_NUMPAD4 = 100; - public static final int DOM_VK_NUMPAD5 = 101; - public static final int DOM_VK_NUMPAD6 = 102; - public static final int DOM_VK_NUMPAD7 = 103; - public static final int DOM_VK_NUMPAD8 = 104; - public static final int DOM_VK_NUMPAD9 = 105; - public static final int DOM_VK_MULTIPLY = 106; - public static final int DOM_VK_ADD = 107; - public static final int DOM_VK_SEPARATOR = 108; - public static final int DOM_VK_SUBTRACT = 109; - public static final int DOM_VK_DECIMAL = 110; - public static final int DOM_VK_DIVIDE = 111; - public static final int DOM_VK_F1 = 112; - public static final int DOM_VK_F2 = 113; - public static final int DOM_VK_F3 = 114; - public static final int DOM_VK_F4 = 115; - public static final int DOM_VK_F5 = 116; - public static final int DOM_VK_F6 = 117; - public static final int DOM_VK_F7 = 118; - public static final int DOM_VK_F8 = 119; - public static final int DOM_VK_F9 = 120; - public static final int DOM_VK_F10 = 121; - public static final int DOM_VK_F11 = 122; - public static final int DOM_VK_F12 = 123; - public static final int DOM_VK_F13 = 124; - public static final int DOM_VK_F14 = 125; - public static final int DOM_VK_F15 = 126; - public static final int DOM_VK_F16 = 127; - public static final int DOM_VK_F17 = 128; - public static final int DOM_VK_F18 = 129; - public static final int DOM_VK_F19 = 130; - public static final int DOM_VK_F20 = 131; - public static final int DOM_VK_F21 = 132; - public static final int DOM_VK_F22 = 133; - public static final int DOM_VK_F23 = 134; - public static final int DOM_VK_F24 = 135; - public static final int DOM_VK_NUM_LOCK = 144; - public static final int DOM_VK_SCROLL_LOCK = 145; - public static final int DOM_VK_COMMA = 188; - public static final int DOM_VK_PERIOD = 190; - public static final int DOM_VK_SLASH = 191; - public static final int DOM_VK_BACK_QUOTE = 192; - public static final int DOM_VK_OPEN_BRACKET = 219; - public static final int DOM_VK_BACK_SLASH = 220; - public static final int DOM_VK_CLOSE_BRACKET = 221; - public static final int DOM_VK_QUOTE = 222; - public static final int DOM_VK_META = 224; + + /* the follow constants are defined in Mozilla 8 */ + public static final int DOM_VK_KANA = 21; + public static final int DOM_VK_HANGUL = 21; + public static final int DOM_VK_JUNJA = 23; + public static final int DOM_VK_FINAL = 24; + public static final int DOM_VK_HANJA = 25; + public static final int DOM_VK_KANJI = 25; + public static final int DOM_VK_CONVERT = 28; + public static final int DOM_VK_NONCONVERT = 29; + public static final int DOM_VK_ACCEPT = 30; + public static final int DOM_VK_MODECHANGE = 31; + public static final int DOM_VK_SELECT = 41; + public static final int DOM_VK_PRINT = 42; + public static final int DOM_VK_EXECUTE = 43; + public static final int DOM_VK_CONTEXT_MENU = 93; + public static final int DOM_VK_SLEEP = 95; + public int GetCharCode(int[] aCharCode) { return XPCOM.VtblCall(nsIDOMUIEvent.LAST_METHOD_ID + 1, getAddress(), aCharCode); diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMKeyEvent_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMKeyEvent_1_9.java deleted file mode 100644 index f83d4a6e93..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMKeyEvent_1_9.java +++ /dev/null @@ -1,299 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIDOMKeyEvent_1_9 extends nsIDOMUIEvent_1_9 { - - static final int LAST_METHOD_ID = nsIDOMUIEvent_1_9.LAST_METHOD_ID + 7; - - public static final String NS_IDOMKEYEVENT_IID_STR = - "028e0e6e-8b01-11d3-aae7-0010838a3123"; - - public static final nsID NS_IDOMKEYEVENT_IID = - new nsID(NS_IDOMKEYEVENT_IID_STR); - - public nsIDOMKeyEvent_1_9(int /*long*/ address) { - super(address); - } - - public static final int DOM_VK_CANCEL = 3; - - public static final int DOM_VK_HELP = 6; - - public static final int DOM_VK_BACK_SPACE = 8; - - public static final int DOM_VK_TAB = 9; - - public static final int DOM_VK_CLEAR = 12; - - public static final int DOM_VK_RETURN = 13; - - public static final int DOM_VK_ENTER = 14; - - public static final int DOM_VK_SHIFT = 16; - - public static final int DOM_VK_CONTROL = 17; - - public static final int DOM_VK_ALT = 18; - - public static final int DOM_VK_PAUSE = 19; - - public static final int DOM_VK_CAPS_LOCK = 20; - - public static final int DOM_VK_ESCAPE = 27; - - public static final int DOM_VK_SPACE = 32; - - public static final int DOM_VK_PAGE_UP = 33; - - public static final int DOM_VK_PAGE_DOWN = 34; - - public static final int DOM_VK_END = 35; - - public static final int DOM_VK_HOME = 36; - - public static final int DOM_VK_LEFT = 37; - - public static final int DOM_VK_UP = 38; - - public static final int DOM_VK_RIGHT = 39; - - public static final int DOM_VK_DOWN = 40; - - public static final int DOM_VK_PRINTSCREEN = 44; - - public static final int DOM_VK_INSERT = 45; - - public static final int DOM_VK_DELETE = 46; - - public static final int DOM_VK_0 = 48; - - public static final int DOM_VK_1 = 49; - - public static final int DOM_VK_2 = 50; - - public static final int DOM_VK_3 = 51; - - public static final int DOM_VK_4 = 52; - - public static final int DOM_VK_5 = 53; - - public static final int DOM_VK_6 = 54; - - public static final int DOM_VK_7 = 55; - - public static final int DOM_VK_8 = 56; - - public static final int DOM_VK_9 = 57; - - public static final int DOM_VK_SEMICOLON = 59; - - public static final int DOM_VK_EQUALS = 61; - - public static final int DOM_VK_A = 65; - - public static final int DOM_VK_B = 66; - - public static final int DOM_VK_C = 67; - - public static final int DOM_VK_D = 68; - - public static final int DOM_VK_E = 69; - - public static final int DOM_VK_F = 70; - - public static final int DOM_VK_G = 71; - - public static final int DOM_VK_H = 72; - - public static final int DOM_VK_I = 73; - - public static final int DOM_VK_J = 74; - - public static final int DOM_VK_K = 75; - - public static final int DOM_VK_L = 76; - - public static final int DOM_VK_M = 77; - - public static final int DOM_VK_N = 78; - - public static final int DOM_VK_O = 79; - - public static final int DOM_VK_P = 80; - - public static final int DOM_VK_Q = 81; - - public static final int DOM_VK_R = 82; - - public static final int DOM_VK_S = 83; - - public static final int DOM_VK_T = 84; - - public static final int DOM_VK_U = 85; - - public static final int DOM_VK_V = 86; - - public static final int DOM_VK_W = 87; - - public static final int DOM_VK_X = 88; - - public static final int DOM_VK_Y = 89; - - public static final int DOM_VK_Z = 90; - - public static final int DOM_VK_NUMPAD0 = 96; - - public static final int DOM_VK_NUMPAD1 = 97; - - public static final int DOM_VK_NUMPAD2 = 98; - - public static final int DOM_VK_NUMPAD3 = 99; - - public static final int DOM_VK_NUMPAD4 = 100; - - public static final int DOM_VK_NUMPAD5 = 101; - - public static final int DOM_VK_NUMPAD6 = 102; - - public static final int DOM_VK_NUMPAD7 = 103; - - public static final int DOM_VK_NUMPAD8 = 104; - - public static final int DOM_VK_NUMPAD9 = 105; - - public static final int DOM_VK_MULTIPLY = 106; - - public static final int DOM_VK_ADD = 107; - - public static final int DOM_VK_SEPARATOR = 108; - - public static final int DOM_VK_SUBTRACT = 109; - - public static final int DOM_VK_DECIMAL = 110; - - public static final int DOM_VK_DIVIDE = 111; - - public static final int DOM_VK_F1 = 112; - - public static final int DOM_VK_F2 = 113; - - public static final int DOM_VK_F3 = 114; - - public static final int DOM_VK_F4 = 115; - - public static final int DOM_VK_F5 = 116; - - public static final int DOM_VK_F6 = 117; - - public static final int DOM_VK_F7 = 118; - - public static final int DOM_VK_F8 = 119; - - public static final int DOM_VK_F9 = 120; - - public static final int DOM_VK_F10 = 121; - - public static final int DOM_VK_F11 = 122; - - public static final int DOM_VK_F12 = 123; - - public static final int DOM_VK_F13 = 124; - - public static final int DOM_VK_F14 = 125; - - public static final int DOM_VK_F15 = 126; - - public static final int DOM_VK_F16 = 127; - - public static final int DOM_VK_F17 = 128; - - public static final int DOM_VK_F18 = 129; - - public static final int DOM_VK_F19 = 130; - - public static final int DOM_VK_F20 = 131; - - public static final int DOM_VK_F21 = 132; - - public static final int DOM_VK_F22 = 133; - - public static final int DOM_VK_F23 = 134; - - public static final int DOM_VK_F24 = 135; - - public static final int DOM_VK_NUM_LOCK = 144; - - public static final int DOM_VK_SCROLL_LOCK = 145; - - public static final int DOM_VK_COMMA = 188; - - public static final int DOM_VK_PERIOD = 190; - - public static final int DOM_VK_SLASH = 191; - - public static final int DOM_VK_BACK_QUOTE = 192; - - public static final int DOM_VK_OPEN_BRACKET = 219; - - public static final int DOM_VK_BACK_SLASH = 220; - - public static final int DOM_VK_CLOSE_BRACKET = 221; - - public static final int DOM_VK_QUOTE = 222; - - public static final int DOM_VK_META = 224; - - public int GetCharCode(int[] aCharCode) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 1, getAddress(), aCharCode); - } - - public int GetKeyCode(int[] aKeyCode) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 2, getAddress(), aKeyCode); - } - - public int GetAltKey(int[] aAltKey) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 3, getAddress(), aAltKey); - } - - public int GetCtrlKey(int[] aCtrlKey) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 4, getAddress(), aCtrlKey); - } - - public int GetShiftKey(int[] aShiftKey) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 5, getAddress(), aShiftKey); - } - - public int GetMetaKey(int[] aMetaKey) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 6, getAddress(), aMetaKey); - } - - public int InitKeyEvent(int /*long*/ typeArg, int canBubbleArg, int cancelableArg, int /*long*/ viewArg, int ctrlKeyArg, int altKeyArg, int shiftKeyArg, int metaKeyArg, int keyCodeArg, int charCodeArg) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 7, getAddress(), typeArg, canBubbleArg, cancelableArg, viewArg, ctrlKeyArg, altKeyArg, shiftKeyArg, metaKeyArg, keyCodeArg, charCodeArg); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMMouseEvent.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMMouseEvent.java index 3420f7e577..c38626b54c 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMMouseEvent.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMMouseEvent.java @@ -32,11 +32,17 @@ public class nsIDOMMouseEvent extends nsIDOMUIEvent { static final int LAST_METHOD_ID = nsIDOMUIEvent.LAST_METHOD_ID + 11; public static final String NS_IDOMMOUSEEVENT_IID_STR = + "ff751edc-8b02-aae7-0010-8301838a3123"; + + public static final String NS_IDOMMOUSEEVENT_8_IID_STR = "73558605-f479-493e-86d1-9794cd117fef"; public static final nsID NS_IDOMMOUSEEVENT_IID = new nsID(NS_IDOMMOUSEEVENT_IID_STR); + public static final nsID NS_IDOMMOUSEEVENT_8_IID = + new nsID(NS_IDOMMOUSEEVENT_8_IID_STR); + public nsIDOMMouseEvent(int /*long*/ address) { super(address); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMMouseEvent_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMMouseEvent_1_9.java deleted file mode 100644 index f3f9c83a05..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMMouseEvent_1_9.java +++ /dev/null @@ -1,87 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIDOMMouseEvent_1_9 extends nsIDOMUIEvent_1_9 { - - static final int LAST_METHOD_ID = nsIDOMUIEvent_1_9.LAST_METHOD_ID + 11; - - public static final String NS_IDOMMOUSEEVENT_IID_STR = - "ff751edc-8b02-aae7-0010-8301838a3123"; - - public static final nsID NS_IDOMMOUSEEVENT_IID = - new nsID(NS_IDOMMOUSEEVENT_IID_STR); - - public nsIDOMMouseEvent_1_9(int /*long*/ address) { - super(address); - } - - public int GetScreenX(int[] aScreenX) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 1, getAddress(), aScreenX); - } - - public int GetScreenY(int[] aScreenY) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 2, getAddress(), aScreenY); - } - - public int GetClientX(int[] aClientX) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 3, getAddress(), aClientX); - } - - public int GetClientY(int[] aClientY) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 4, getAddress(), aClientY); - } - - public int GetCtrlKey(int[] aCtrlKey) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 5, getAddress(), aCtrlKey); - } - - public int GetShiftKey(int[] aShiftKey) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 6, getAddress(), aShiftKey); - } - - public int GetAltKey(int[] aAltKey) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 7, getAddress(), aAltKey); - } - - public int GetMetaKey(int[] aMetaKey) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 8, getAddress(), aMetaKey); - } - - public int GetButton(short[] aButton) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 9, getAddress(), aButton); - } - - public int GetRelatedTarget(int /*long*/[] aRelatedTarget) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 10, getAddress(), aRelatedTarget); - } - - public int InitMouseEvent(int /*long*/ typeArg, int canBubbleArg, int cancelableArg, int /*long*/ viewArg, int detailArg, int screenXArg, int screenYArg, int clientXArg, int clientYArg, int ctrlKeyArg, int altKeyArg, int shiftKeyArg, int metaKeyArg, short buttonArg, int /*long*/ relatedTargetArg) { - return XPCOM.VtblCall(nsIDOMUIEvent_1_9.LAST_METHOD_ID + 11, getAddress(), typeArg, canBubbleArg, cancelableArg, viewArg, detailArg, screenXArg, screenYArg, clientXArg, clientYArg, ctrlKeyArg, altKeyArg, shiftKeyArg, metaKeyArg, buttonArg, relatedTargetArg); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMNode.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMNode.java index 9ec806a3ad..e7b22df231 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMNode.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMNode.java @@ -27,7 +27,7 @@ * ***** END LICENSE BLOCK ***** */
package org.eclipse.swt.internal.mozilla;
-public class nsIDOMNode extends nsISupports {
+public class nsIDOMNode extends nsISupports {
static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 25;
@@ -37,32 +37,21 @@ public class nsIDOMNode extends nsISupports { public static final nsID NS_IDOMNODE_IID =
new nsID(NS_IDOMNODE_IID_STR);
- public nsIDOMNode(int /*long*/ address) {
+ public nsIDOMNode(int /*long*/ address) {
super(address);
}
public static final int ELEMENT_NODE = 1;
-
public static final int ATTRIBUTE_NODE = 2;
-
public static final int TEXT_NODE = 3;
-
public static final int CDATA_SECTION_NODE = 4;
-
public static final int ENTITY_REFERENCE_NODE = 5;
-
public static final int ENTITY_NODE = 6;
-
public static final int PROCESSING_INSTRUCTION_NODE = 7;
-
public static final int COMMENT_NODE = 8;
-
public static final int DOCUMENT_NODE = 9;
-
public static final int DOCUMENT_TYPE_NODE = 10;
-
public static final int DOCUMENT_FRAGMENT_NODE = 11;
-
public static final int NOTATION_NODE = 12;
public int GetNodeName(int /*long*/ aNodeName) {
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMUIEvent.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMUIEvent.java index a0540d9414..9520babad8 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMUIEvent.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMUIEvent.java @@ -32,11 +32,17 @@ public class nsIDOMUIEvent extends nsIDOMEvent { static final int LAST_METHOD_ID = nsIDOMEvent.LAST_METHOD_ID + 3; public static final String NS_IDOMUIEVENT_IID_STR = - "25f28689-3f78-47e8-8d76-15b936faf8c1"; + "a6cf90c3-15b3-11d2-932e-00805f8add32"; + public static final String NS_IDOMUIEVENT_8_IID_STR = + "25f28689-3f78-47e8-8d76-15b936faf8c1"; + public static final nsID NS_IDOMUIEVENT_IID = new nsID(NS_IDOMUIEVENT_IID_STR); + public static final nsID NS_IDOMUIEVENT_8_IID = + new nsID(NS_IDOMUIEVENT_8_IID_STR); + public nsIDOMUIEvent(int /*long*/ address) { super(address); } @@ -49,7 +55,6 @@ public class nsIDOMUIEvent extends nsIDOMEvent { return XPCOM.VtblCall(nsIDOMEvent.LAST_METHOD_ID + 2, getAddress(), aDetail); } - //nsIDOMWindow - viewArg public int InitUIEvent(int /*long*/ typeArg, int canBubbleArg, int cancelableArg, int /*long*/ viewArg, int detailArg) { return XPCOM.VtblCall(nsIDOMEvent.LAST_METHOD_ID + 3, getAddress(), typeArg, canBubbleArg, cancelableArg, viewArg, detailArg); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMUIEvent_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMUIEvent_1_9.java deleted file mode 100644 index 811e1dc4bc..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMUIEvent_1_9.java +++ /dev/null @@ -1,56 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIDOMUIEvent_1_9 extends nsIDOMEvent_1_9 { - - static final int LAST_METHOD_ID = nsIDOMEvent_1_9.LAST_METHOD_ID + 3; - - public static final String NS_IDOMUIEVENT_IID_STR = - "a6cf906b-15b3-11d2-932e-00805f8add32"; - - public static final nsID NS_IDOMUIEVENT_IID = - new nsID(NS_IDOMUIEVENT_IID_STR); - - public nsIDOMUIEvent_1_9(int /*long*/ address) { - super(address); - } - - public int GetView(int /*long*/[] aView) { - return XPCOM.VtblCall(nsIDOMEvent_1_9.LAST_METHOD_ID + 1, getAddress(), aView); - } - - public int GetDetail(int[] aDetail) { - return XPCOM.VtblCall(nsIDOMEvent_1_9.LAST_METHOD_ID + 2, getAddress(), aDetail); - } - - //nsIDOMWindow - viewArg - public int InitUIEvent(int /*long*/ typeArg, int canBubbleArg, int cancelableArg, int /*long*/ viewArg, int detailArg) { - return XPCOM.VtblCall(nsIDOMEvent_1_9.LAST_METHOD_ID + 3, getAddress(), typeArg, canBubbleArg, cancelableArg, viewArg, detailArg); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMWindow.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMWindow.java index 29ccde9ca2..2e2b9801fc 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMWindow.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMWindow.java @@ -29,83 +29,489 @@ package org.eclipse.swt.internal.mozilla; public class nsIDOMWindow extends nsISupports { - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 75; + static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + (Is8 ? 97 : 17); public static final String NS_IDOMWINDOW_IID_STR = + "a6cf906b-15b3-11d2-932e-00805f8add32"; + + public static final String NS_IDOMWINDOW_8_IID_STR = "972cb379-6bdc-4544-8b46-8d721e12e906"; public static final nsID NS_IDOMWINDOW_IID = new nsID(NS_IDOMWINDOW_IID_STR); + public static final nsID NS_IDOMWINDOW_8_IID = + new nsID(NS_IDOMWINDOW_8_IID_STR); + public nsIDOMWindow(int /*long*/ address) { super(address); } public int GetDocument(int /*long*/[] aDocument) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), aDocument); + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 3 : 1), getAddress(), aDocument); } - public int GetName(int /*long*/ aName) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aName); + public int GetParent(int /*long*/[] aParent) { + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 24 : 2), getAddress(), aParent); } - public int SetName(int /*long*/ aName) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress(), aName); + public int GetTop(int /*long*/[] aTop) { + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 21 : 3), getAddress(), aTop); } - + public int GetScrollbars(int /*long*/[] aScrollbars) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 11, getAddress(), aScrollbars); + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 11 : 4), getAddress(), aScrollbars); } - - public int GetTop(int /*long*/[] aTop) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 21, getAddress(), aTop); + + public int GetFrames(int /*long*/[] aFrames) { + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 62 : 5), getAddress(), aFrames); } - - public int GetParent(int /*long*/[] aParent) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 24, getAddress(), aParent); + + public int GetName(int /*long*/ aName) { + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 4 : 6), getAddress(), aName); + } + + public int SetName(int /*long*/ aName) { + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 5 : 7), getAddress(), aName); + } + + public int GetTextZoom(float[] aTextZoom) { + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 63 : 8), getAddress(), aTextZoom); + } + + public int SetTextZoom(float aTextZoom) { + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 64 : 9), getAddress(), aTextZoom); } public int GetScrollX(int[] aScrollX) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 45, getAddress(), aScrollX); + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 45 : 10), getAddress(), aScrollX); } public int GetScrollY(int[] aScrollY) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 47, getAddress(), aScrollY); + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 47 : 11), getAddress(), aScrollY); } public int ScrollTo(int xScroll, int yScroll) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 50, getAddress(), xScroll, yScroll); + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 50 : 12), getAddress(), xScroll, yScroll); } public int ScrollBy(int xScrollDif, int yScrollDif) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 51, getAddress(), xScrollDif, yScrollDif); + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 51 : 13), getAddress(), xScrollDif, yScrollDif); } public int GetSelection(int /*long*/[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 38, getAddress(), _retval); + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 38 : 14), getAddress(), _retval); } - public int GetFrames(int /*long*/[] aFrames) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 62, getAddress(), aFrames); + public int ScrollByLines(int numLines) { + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 65 : 15), getAddress(), numLines); } - public int GetTextZoom(float[] aTextZoom) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 63, getAddress(), aTextZoom); + public int ScrollByPages(int numPages) { + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 66 : 16), getAddress(), numPages); } - public int SetTextZoom(float aTextZoom) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 64, getAddress(), aTextZoom); + public int SizeToContent() { + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 67 : 17), getAddress()); + } + + public int GetWindow(int /*long*/[] aWindow) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), aWindow); } - public int ScrollByLines(int numLines) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 65, getAddress(), numLines); + public int GetSelf(int /*long*/[] aSelf) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), aSelf); } - public int ScrollByPages(int numPages) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 66, getAddress(), numPages); + public int GetLocation(int /*long*/[] aLocation) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aLocation); } - public int SizeToContent() { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 68, getAddress()); + public int GetHistory(int /*long*/[] aHistory) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aHistory); + } + + public int GetLocationbar(int /*long*/[] aLocationbar) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress(), aLocationbar); + } + + public int GetMenubar(int /*long*/[] aMenubar) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 9, getAddress(), aMenubar); + } + + public int GetPersonalbar(int /*long*/[] aPersonalbar) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 10, getAddress(), aPersonalbar); + } + + public int GetStatusbar(int /*long*/[] aStatusbar) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 12, getAddress(), aStatusbar); + } + + public int GetToolbar(int /*long*/[] aToolbar) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 13, getAddress(), aToolbar); + } + + public int GetStatus(int /*long*/ aStatus) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 14, getAddress(), aStatus); + } + + public int SetStatus(int /*long*/ aStatus) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 15, getAddress(), aStatus); + } + + public int Close() { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 16, getAddress()); + } + + public int Stop() { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 17, getAddress()); + } + + public int Focus() { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 18, getAddress()); + } + + public int Blur() { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 19, getAddress()); + } + + public int GetLength(int[] aLength) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 20, getAddress(), aLength); + } + + public int GetOpener(int /*long*/[] aOpener) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 22, getAddress(), aOpener); + } + + public int SetOpener(int /*long*/ aOpener) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 23, getAddress(), aOpener); + } + + public int GetFrameElement(int /*long*/[] aFrameElement) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 25, getAddress(), aFrameElement); + } + + public int GetNavigator(int /*long*/[] aNavigator) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 26, getAddress(), aNavigator); + } + + public int GetApplicationCache(int /*long*/[] aApplicationCache) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 27, getAddress(), aApplicationCache); + } + + public int Alert(int /*long*/ text) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 28, getAddress(), text); + } + + public int Confirm(int /*long*/ text, int[] _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 29, getAddress(), text, _retval); + } + + public int Prompt(int /*long*/ aMessage, int /*long*/ aInitial, int /*long*/ _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 30, getAddress(), aMessage, aInitial, _retval); + } + + public int Print() { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 31, getAddress()); + } + + public int ShowModalDialog(int /*long*/ aURI, int /*long*/ aArgs, int /*long*/ aOptions, int /*long*/[] _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 32, getAddress(), aURI, aArgs, aOptions, _retval); + } + + public int PostMessageMoz(int /*long*/ message, int /*long*/ targetOrigin, int /*long*/ cx) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 33, getAddress(), message, targetOrigin, cx); + } + + public int Atob(int /*long*/ aAsciiString, int /*long*/ _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 34, getAddress(), aAsciiString, _retval); + } + + public int Btoa(int /*long*/ aBase64Data, int /*long*/ _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 35, getAddress(), aBase64Data, _retval); + } + + public int GetSessionStorage(int /*long*/[] aSessionStorage) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 36, getAddress(), aSessionStorage); + } + + public int GetLocalStorage(int /*long*/[] aLocalStorage) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 37, getAddress(), aLocalStorage); + } + + public int MatchMedia(int /*long*/ media_query_list, int /*long*/[] _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 39, getAddress(), media_query_list, _retval); + } + + public int GetScreen(int /*long*/[] aScreen) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 40, getAddress(), aScreen); + } + + public int GetInnerWidth(int[] aInnerWidth) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 41, getAddress(), aInnerWidth); + } + + public int SetInnerWidth(int aInnerWidth) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 42, getAddress(), aInnerWidth); + } + + public int GetInnerHeight(int[] aInnerHeight) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 43, getAddress(), aInnerHeight); + } + + public int SetInnerHeight(int aInnerHeight) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 44, getAddress(), aInnerHeight); + } + + public int GetPageXOffset(int[] aPageXOffset) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 46, getAddress(), aPageXOffset); + } + + public int GetPageYOffset(int[] aPageYOffset) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 48, getAddress(), aPageYOffset); + } + + public int Scroll(int xScroll, int yScroll) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 49, getAddress(), xScroll, yScroll); + } + + public int GetScreenX(int[] aScreenX) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 52, getAddress(), aScreenX); + } + + public int SetScreenX(int aScreenX) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 53, getAddress(), aScreenX); + } + + public int GetScreenY(int[] aScreenY) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 54, getAddress(), aScreenY); + } + + public int SetScreenY(int aScreenY) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 55, getAddress(), aScreenY); + } + + public int GetOuterWidth(int[] aOuterWidth) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 56, getAddress(), aOuterWidth); + } + + public int SetOuterWidth(int aOuterWidth) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 57, getAddress(), aOuterWidth); + } + + public int GetOuterHeight(int[] aOuterHeight) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 58, getAddress(), aOuterHeight); + } + + public int SetOuterHeight(int aOuterHeight) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 59, getAddress(), aOuterHeight); + } + + public int GetComputedStyle(int /*long*/ elt, int /*long*/ pseudoElt, int /*long*/[] _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 60, getAddress(), elt, pseudoElt, _retval); + } + + public int GetWindowRoot(int /*long*/[] aWindowRoot) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 61, getAddress(), aWindowRoot); + } + + public int GetContent(int /*long*/[] aContent) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 68, getAddress(), aContent); + } + + public int GetPrompter(int /*long*/[] aPrompter) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 69, getAddress(), aPrompter); + } + + public int GetClosed(int[] aClosed) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 70, getAddress(), aClosed); + } + + public int GetCrypto(int /*long*/[] aCrypto) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 71, getAddress(), aCrypto); + } + + public int GetPkcs11(int /*long*/[] aPkcs11) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 72, getAddress(), aPkcs11); + } + + public int GetControllers(int /*long*/[] aControllers) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 73, getAddress(), aControllers); + } + + public int GetDefaultStatus(int /*long*/ aDefaultStatus) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 74, getAddress(), aDefaultStatus); + } + + public int SetDefaultStatus(int /*long*/ aDefaultStatus) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 75, getAddress(), aDefaultStatus); + } + + public int GetMozInnerScreenX(float[] aMozInnerScreenX) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 76, getAddress(), aMozInnerScreenX); + } + + public int GetMozInnerScreenY(float[] aMozInnerScreenY) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 77, getAddress(), aMozInnerScreenY); + } + + public int GetScrollMaxX(int[] aScrollMaxX) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 78, getAddress(), aScrollMaxX); + } + + public int GetScrollMaxY(int[] aScrollMaxY) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 79, getAddress(), aScrollMaxY); + } + + public int GetFullScreen(int[] aFullScreen) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 80, getAddress(), aFullScreen); + } + + public int SetFullScreen(int aFullScreen) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 81, getAddress(), aFullScreen); + } + + public int Back() { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 82, getAddress()); + } + + public int Forward() { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 83, getAddress()); + } + + public int Home() { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 84, getAddress()); + } + + public int MoveTo(int xPos, int yPos) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 85, getAddress(), xPos, yPos); + } + + public int MoveBy(int xDif, int yDif) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 86, getAddress(), xDif, yDif); + } + + public int ResizeTo(int width, int height) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 87, getAddress(), width, height); + } + + public int ResizeBy(int widthDif, int heightDif) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 88, getAddress(), widthDif, heightDif); + } + + public int Open(int /*long*/ url, int /*long*/ name, int /*long*/ options, int /*long*/[] _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 89, getAddress(), url, name, options, _retval); + } + + public int OpenDialog(int /*long*/ url, int /*long*/ name, int /*long*/ options, int /*long*/ aExtraArgument, int /*long*/[] _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 90, getAddress(), url, name, options, aExtraArgument, _retval); + } + + public int UpdateCommands(int /*long*/ action) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 91, getAddress(), action); + } + + public int Find(int /*long*/ str, int caseSensitive, int backwards, int wrapAround, int wholeWord, int searchInFrames, int showDialog, int[] _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 92, getAddress(), str, caseSensitive, backwards, wrapAround, wholeWord, searchInFrames, showDialog, _retval); + } + + public int GetMozPaintCount(int /*long*/ aMozPaintCount) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 93, getAddress(), aMozPaintCount); + } + + public int MozRequestAnimationFrame(int /*long*/ aListener) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 94, getAddress(), aListener); + } + + public int GetMozAnimationStartTime(long[] aMozAnimationStartTime) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 95, getAddress(), aMozAnimationStartTime); + } + + public int GetURL(int /*long*/[] aURL) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 96, getAddress(), aURL); + } + + public int GetGlobalStorage(int /*long*/[] aGlobalStorage) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 97, getAddress(), aGlobalStorage); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMWindow_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMWindow_1_9.java deleted file mode 100644 index c8735aa3c1..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMWindow_1_9.java +++ /dev/null @@ -1,111 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2005 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIDOMWindow_1_9 extends nsISupports { - - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 17; - - public static final String NS_IDOMWINDOW_IID_STR = - "a6cf906b-15b3-11d2-932e-00805f8add32"; - - public static final nsID NS_IDOMWINDOW_IID = - new nsID(NS_IDOMWINDOW_IID_STR); - - public nsIDOMWindow_1_9(int /*long*/ address) { - super(address); - } - - public int GetDocument(int /*long*/[] aDocument) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), aDocument); - } - - public int GetParent(int /*long*/[] aParent) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), aParent); - } - - public int GetTop(int /*long*/[] aTop) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), aTop); - } - - public int GetScrollbars(int /*long*/[] aScrollbars) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aScrollbars); - } - - public int GetFrames(int /*long*/[] aFrames) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress(), aFrames); - } - - public int GetName(int /*long*/ aName) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aName); - } - - public int SetName(int /*long*/ aName) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aName); - } - - public int GetTextZoom(float[] aTextZoom) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress(), aTextZoom); - } - - public int SetTextZoom(float aTextZoom) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 9, getAddress(), aTextZoom); - } - - public int GetScrollX(int[] aScrollX) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 10, getAddress(), aScrollX); - } - - public int GetScrollY(int[] aScrollY) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 11, getAddress(), aScrollY); - } - - public int ScrollTo(int xScroll, int yScroll) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 12, getAddress(), xScroll, yScroll); - } - - public int ScrollBy(int xScrollDif, int yScrollDif) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 13, getAddress(), xScrollDif, yScrollDif); - } - - public int GetSelection(int /*long*/[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 14, getAddress(), _retval); - } - - public int ScrollByLines(int numLines) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 15, getAddress(), numLines); - } - - public int ScrollByPages(int numPages) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 16, getAddress(), numPages); - } - - public int SizeToContent() { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 17, getAddress()); - } -}
\ No newline at end of file diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMWindow_8.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMWindow_8.java deleted file mode 100644 index 9cd5cf8e95..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDOMWindow_8.java +++ /dev/null @@ -1,111 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2005 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIDOMWindow_8 extends nsISupports { - - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 75; - - public static final String NS_IDOMWINDOW_IID_STR = - "972cb379-6bdc-4544-8b46-8d721e12e906"; - - public static final nsID NS_IDOMWINDOW_IID = - new nsID(NS_IDOMWINDOW_IID_STR); - - public nsIDOMWindow_8(int /*long*/ address) { - super(address); - } - - public int GetDocument(int /*long*/[] aDocument) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), aDocument); - } - - public int GetName(int /*long*/ aName) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aName); - } - - public int SetName(int /*long*/ aName) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress(), aName); - } - - public int GetScrollbars(int /*long*/[] aScrollbars) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 11, getAddress(), aScrollbars); - } - - public int GetTop(int /*long*/[] aTop) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 21, getAddress(), aTop); - } - - public int GetParent(int /*long*/[] aParent) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 24, getAddress(), aParent); - } - - public int GetScrollX(int[] aScrollX) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 45, getAddress(), aScrollX); - } - - public int GetScrollY(int[] aScrollY) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 47, getAddress(), aScrollY); - } - - public int ScrollTo(int xScroll, int yScroll) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 50, getAddress(), xScroll, yScroll); - } - - public int ScrollBy(int xScrollDif, int yScrollDif) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 51, getAddress(), xScrollDif, yScrollDif); - } - - public int GetSelection(int /*long*/[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 38, getAddress(), _retval); - } - - public int GetFrames(int /*long*/[] aFrames) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 62, getAddress(), aFrames); - } - - public int GetTextZoom(float[] aTextZoom) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 63, getAddress(), aTextZoom); - } - - public int SetTextZoom(float aTextZoom) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 64, getAddress(), aTextZoom); - } - - public int ScrollByLines(int numLines) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 65, getAddress(), numLines); - } - - public int ScrollByPages(int numPages) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 66, getAddress(), numPages); - } - - public int SizeToContent() { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 68, getAddress()); - } -}
\ No newline at end of file diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDataType.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDataType.java index d54f3d77ff..9093e78679 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDataType.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDataType.java @@ -42,58 +42,31 @@ public class nsIDataType extends nsISupports { } public static final short VTYPE_INT8 = 0; - public static final short VTYPE_INT16 = 1; - public static final short VTYPE_INT32 = 2; - public static final short VTYPE_INT64 = 3; - public static final short VTYPE_UINT8 = 4; - public static final short VTYPE_UINT16 = 5; - public static final short VTYPE_UINT32 = 6; - public static final short VTYPE_UINT64 = 7; - public static final short VTYPE_FLOAT = 8; - public static final short VTYPE_DOUBLE = 9; - public static final short VTYPE_BOOL = 10; - public static final short VTYPE_CHAR = 11; - public static final short VTYPE_WCHAR = 12; - public static final short VTYPE_VOID = 13; - public static final short VTYPE_ID = 14; - public static final short VTYPE_DOMSTRING = 15; - public static final short VTYPE_CHAR_STR = 16; - public static final short VTYPE_WCHAR_STR = 17; - public static final short VTYPE_INTERFACE = 18; - public static final short VTYPE_INTERFACE_IS = 19; - public static final short VTYPE_ARRAY = 20; - public static final short VTYPE_STRING_SIZE_IS = 21; - public static final short VTYPE_WSTRING_SIZE_IS = 22; - public static final short VTYPE_UTF8STRING = 23; - public static final short VTYPE_CSTRING = 24; - public static final short VTYPE_ASTRING = 25; - public static final short VTYPE_EMPTY_ARRAY = 254; - public static final short VTYPE_EMPTY = 255; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDirectoryServiceProvider2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDirectoryServiceProvider2.java index a277b15875..ad3c5d1035 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDirectoryServiceProvider2.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDirectoryServiceProvider2.java @@ -44,4 +44,4 @@ public class nsIDirectoryServiceProvider2 extends nsIDirectoryServiceProvider { public int GetFiles(byte[] prop, int /*long*/[] _retval) { return XPCOM.VtblCall(nsIDirectoryServiceProvider.LAST_METHOD_ID + 1, getAddress(), prop, _retval); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell.java index bed487cdc4..7a11c2b79d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell.java @@ -222,17 +222,11 @@ public class nsIDocShell extends nsISupports { } public static final int BUSY_FLAGS_NONE = 0; - public static final int BUSY_FLAGS_BUSY = 1; - public static final int BUSY_FLAGS_BEFORE_PAGE_LOAD = 2; - public static final int BUSY_FLAGS_PAGE_LOADING = 4; - public static final int LOAD_CMD_NORMAL = 1; - public static final int LOAD_CMD_RELOAD = 2; - public static final int LOAD_CMD_HISTORY = 4; public int GetBusyFlags(int[] aBusyFlags) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell_1_8.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell_1_8.java index 526c7595e1..0260249822 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell_1_8.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell_1_8.java @@ -37,6 +37,12 @@ public class nsIDocShell_1_8 extends nsISupports { public static final nsID NS_IDOCSHELL_IID = new nsID(NS_IDOCSHELL_IID_STR); + public static final String NS_IDOCSHELL_8_IID_STR = + "0666adf8-8738-4ca7-a917-0348f47d2f40"; + + public static final nsID NS_IDOCSHELL_8_IID = + new nsID(NS_IDOCSHELL_8_IID_STR); + public nsIDocShell_1_8(int /*long*/ address) { super(address); } @@ -50,9 +56,7 @@ public class nsIDocShell_1_8 extends nsISupports { } public static final int INTERNAL_LOAD_FLAGS_NONE = 0; - public static final int INTERNAL_LOAD_FLAGS_INHERIT_OWNER = 1; - public static final int INTERNAL_LOAD_FLAGS_DONT_SEND_REFERRER = 2; public int InternalLoad(int /*long*/ aURI, int /*long*/ aReferrer, int /*long*/ aOwner, int aFlags, char[] aWindowTarget, byte[] aTypeHint, int /*long*/ aPostDataStream, int /*long*/ aHeadersStream, int aLoadFlags, int /*long*/ aSHEntry, int firstParty, int /*long*/[] aDocShell, int /*long*/[] aRequest) { @@ -148,7 +152,6 @@ public class nsIDocShell_1_8 extends nsISupports { } public static final int ENUMERATE_FORWARDS = 0; - public static final int ENUMERATE_BACKWARDS = 1; public int GetDocShellEnumerator(int aItemType, int aDirection, int /*long*/[] _retval) { @@ -156,9 +159,7 @@ public class nsIDocShell_1_8 extends nsISupports { } public static final int APP_TYPE_UNKNOWN = 0; - public static final int APP_TYPE_MAIL = 1; - public static final int APP_TYPE_EDITOR = 2; public int GetAppType(int[] aAppType) { @@ -222,17 +223,11 @@ public class nsIDocShell_1_8 extends nsISupports { } public static final int BUSY_FLAGS_NONE = 0; - public static final int BUSY_FLAGS_BUSY = 1; - public static final int BUSY_FLAGS_BEFORE_PAGE_LOAD = 2; - public static final int BUSY_FLAGS_PAGE_LOADING = 4; - public static final int LOAD_CMD_NORMAL = 1; - public static final int LOAD_CMD_RELOAD = 2; - public static final int LOAD_CMD_HISTORY = 4; public int GetBusyFlags(int[] aBusyFlags) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell_2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell_2.java deleted file mode 100644 index e728dd7806..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDocShell_2.java +++ /dev/null @@ -1,318 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -//If this class is used then the methods have to be checked with IDL -public class nsIDocShell_2 extends nsISupports { - - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 61; - - public static final String NS_IDOCSHELL_IID_STR = - "0666adf8-8738-4ca7-a917-0348f47d2f40"; - - public static final nsID NS_IDOCSHELL_IID = - new nsID(NS_IDOCSHELL_IID_STR); - - public nsIDocShell_2(int /*long*/ address) { - super(address); - } - - public int LoadURI(int /*long*/ uri, int /*long*/ loadInfo, int aLoadFlags, int firstParty) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), uri, loadInfo, aLoadFlags, firstParty); - } - - public int LoadStream(int /*long*/ aStream, int /*long*/ aURI, int /*long*/ aContentType, int /*long*/ aContentCharset, int /*long*/ aLoadInfo) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), aStream, aURI, aContentType, aContentCharset, aLoadInfo); - } - - public static final int INTERNAL_LOAD_FLAGS_NONE = 0; - - public static final int INTERNAL_LOAD_FLAGS_INHERIT_OWNER = 1; - - public static final int INTERNAL_LOAD_FLAGS_DONT_SEND_REFERRER = 2; - - public int InternalLoad(int /*long*/ aURI, int /*long*/ aReferrer, int /*long*/ aOwner, int aFlags, char[] aWindowTarget, byte[] aTypeHint, int /*long*/ aPostDataStream, int /*long*/ aHeadersStream, int aLoadFlags, int /*long*/ aSHEntry, int firstParty, int /*long*/[] aDocShell, int /*long*/[] aRequest) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), aURI, aReferrer, aOwner, aFlags, aWindowTarget, aTypeHint, aPostDataStream, aHeadersStream, aLoadFlags, aSHEntry, firstParty, aDocShell, aRequest); - } - - public int CreateLoadInfo(int /*long*/[] loadInfo) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), loadInfo); - } - - public int PrepareForNewContentModel() { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress()); - } - - public int SetCurrentURI(int /*long*/ aURI) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aURI); - } - - public int FirePageHideNotification(int isUnload) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), isUnload); - } - - public int GetPresContext(int /*long*/[] aPresContext) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress(), aPresContext); - } - - public int GetPresShell(int /*long*/[] aPresShell) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 9, getAddress(), aPresShell); - } - - public int GetEldestPresShell(int /*long*/[] aEldestPresShell) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 10, getAddress(), aEldestPresShell); - } - - public int GetContentViewer(int /*long*/[] aContentViewer) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 11, getAddress(), aContentViewer); - } - - public int GetChromeEventHandler(int /*long*/[] aChromeEventHandler) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 12, getAddress(), aChromeEventHandler); - } - - public int SetChromeEventHandler(int /*long*/ aChromeEventHandler) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 13, getAddress(), aChromeEventHandler); - } - - public int GetDocumentCharsetInfo(int /*long*/[] aDocumentCharsetInfo) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 14, getAddress(), aDocumentCharsetInfo); - } - - public int SetDocumentCharsetInfo(int /*long*/ aDocumentCharsetInfo) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 15, getAddress(), aDocumentCharsetInfo); - } - - public int GetAllowPlugins(int[] aAllowPlugins) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 16, getAddress(), aAllowPlugins); - } - - public int SetAllowPlugins(int aAllowPlugins) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 17, getAddress(), aAllowPlugins); - } - - public int GetAllowJavascript(int[] aAllowJavascript) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 18, getAddress(), aAllowJavascript); - } - - public int SetAllowJavascript(int aAllowJavascript) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 19, getAddress(), aAllowJavascript); - } - - public int GetAllowMetaRedirects(int[] aAllowMetaRedirects) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 20, getAddress(), aAllowMetaRedirects); - } - - public int SetAllowMetaRedirects(int aAllowMetaRedirects) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 21, getAddress(), aAllowMetaRedirects); - } - - public int GetAllowSubframes(int[] aAllowSubframes) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 22, getAddress(), aAllowSubframes); - } - - public int SetAllowSubframes(int aAllowSubframes) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 23, getAddress(), aAllowSubframes); - } - - public int GetAllowImages(int[] aAllowImages) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 24, getAddress(), aAllowImages); - } - - public int SetAllowImages(int aAllowImages) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 25, getAddress(), aAllowImages); - } - - public static final int ENUMERATE_FORWARDS = 0; - - public static final int ENUMERATE_BACKWARDS = 1; - - public int GetDocShellEnumerator(int aItemType, int aDirection, int /*long*/[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 26, getAddress(), aItemType, aDirection, _retval); - } - - public static final int APP_TYPE_UNKNOWN = 0; - - public static final int APP_TYPE_MAIL = 1; - - public static final int APP_TYPE_EDITOR = 2; - - public int GetAppType(int[] aAppType) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 27, getAddress(), aAppType); - } - - public int SetAppType(int aAppType) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 28, getAddress(), aAppType); - } - - public int GetAllowAuth(int[] aAllowAuth) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 29, getAddress(), aAllowAuth); - } - - public int SetAllowAuth(int aAllowAuth) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 30, getAddress(), aAllowAuth); - } - - public int GetZoom(float[] aZoom) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 31, getAddress(), aZoom); - } - - public int SetZoom(float aZoom) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 32, getAddress(), aZoom); - } - - public int GetMarginWidth(int[] aMarginWidth) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 33, getAddress(), aMarginWidth); - } - - public int SetMarginWidth(int aMarginWidth) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 34, getAddress(), aMarginWidth); - } - - public int GetMarginHeight(int[] aMarginHeight) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 35, getAddress(), aMarginHeight); - } - - public int SetMarginHeight(int aMarginHeight) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 36, getAddress(), aMarginHeight); - } - - public int GetHasFocus(int[] aHasFocus) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 37, getAddress(), aHasFocus); - } - - public int SetHasFocus(int aHasFocus) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 38, getAddress(), aHasFocus); - } - - public int GetCanvasHasFocus(int[] aCanvasHasFocus) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 39, getAddress(), aCanvasHasFocus); - } - - public int SetCanvasHasFocus(int aCanvasHasFocus) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 40, getAddress(), aCanvasHasFocus); - } - - public int TabToTreeOwner(int forward, int[] tookFocus) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 41, getAddress(), forward, tookFocus); - } - - public static final int BUSY_FLAGS_NONE = 0; - - public static final int BUSY_FLAGS_BUSY = 1; - - public static final int BUSY_FLAGS_BEFORE_PAGE_LOAD = 2; - - public static final int BUSY_FLAGS_PAGE_LOADING = 4; - - public static final int LOAD_CMD_NORMAL = 1; - - public static final int LOAD_CMD_RELOAD = 2; - - public static final int LOAD_CMD_HISTORY = 4; - - public int GetBusyFlags(int[] aBusyFlags) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 42, getAddress(), aBusyFlags); - } - - public int GetLoadType(int[] aLoadType) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 43, getAddress(), aLoadType); - } - - public int SetLoadType(int aLoadType) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 44, getAddress(), aLoadType); - } - - public int IsBeingDestroyed(int[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 45, getAddress(), _retval); - } - - public int GetIsExecutingOnLoadHandler(int[] aIsExecutingOnLoadHandler) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 46, getAddress(), aIsExecutingOnLoadHandler); - } - - public int GetLayoutHistoryState(int /*long*/[] aLayoutHistoryState) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 47, getAddress(), aLayoutHistoryState); - } - - public int SetLayoutHistoryState(int /*long*/ aLayoutHistoryState) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 48, getAddress(), aLayoutHistoryState); - } - - public int GetShouldSaveLayoutState(int[] aShouldSaveLayoutState) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 49, getAddress(), aShouldSaveLayoutState); - } - - public int GetSecurityUI(int /*long*/[] aSecurityUI) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 50, getAddress(), aSecurityUI); - } - - public int SetSecurityUI(int /*long*/ aSecurityUI) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 51, getAddress(), aSecurityUI); - } - - public int SuspendRefreshURIs() { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 52, getAddress()); - } - - public int ResumeRefreshURIs() { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 53, getAddress()); - } - - public int BeginRestore(int /*long*/ viewer, int top) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 54, getAddress(), viewer, top); - } - - public int FinishRestore() { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 55, getAddress()); - } - - public int GetRestoringDocument(int[] aRestoringDocument) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 56, getAddress(), aRestoringDocument); - } - - public int GetUseErrorPages(int[] aUseErrorPages) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 57, getAddress(), aUseErrorPages); - } - - public int SetUseErrorPages(int aUseErrorPages) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 58, getAddress(), aUseErrorPages); - } - - public int GetPreviousTransIndex(int[] aPreviousTransIndex) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 59, getAddress(), aPreviousTransIndex); - } - - public int GetLoadedTransIndex(int[] aLoadedTransIndex) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 60, getAddress(), aLoadedTransIndex); - } - - public int HistoryPurged(int numEntries) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 61, getAddress(), numEntries); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDownload.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDownload.java index 365f51f0ee..18d308d1f0 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDownload.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIDownload.java @@ -92,4 +92,4 @@ public class nsIDownload extends nsISupports { public int SetObserver(int /*long*/ aObserver) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 13, getAddress(), aObserver); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIEmbeddingSiteWindow.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIEmbeddingSiteWindow.java index 3bb3009d49..2a720da989 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIEmbeddingSiteWindow.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIEmbeddingSiteWindow.java @@ -42,9 +42,7 @@ public class nsIEmbeddingSiteWindow extends nsISupports { } public static final int DIM_FLAGS_POSITION = 1; - public static final int DIM_FLAGS_SIZE_INNER = 2; - public static final int DIM_FLAGS_SIZE_OUTER = 4; public int SetDimensions(int flags, int x, int y, int cx, int cy) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFile.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFile.java index e5d51b0923..d8b4cb992e 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFile.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFile.java @@ -42,7 +42,6 @@ public class nsIFile extends nsISupports { } public static final int NORMAL_FILE_TYPE = 0; - public static final int DIRECTORY_TYPE = 1; public int Append(int /*long*/ node) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFilePicker_1_8.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFilePicker_1_8.java index 22b0ed3d9a..e7efb9a1b5 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFilePicker_1_8.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFilePicker_1_8.java @@ -29,14 +29,20 @@ package org.eclipse.swt.internal.mozilla; public class nsIFilePicker_1_8 extends nsISupports { - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 15; + static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + (Is8 ? 17 : 15); public static final String NS_IFILEPICKER_IID_STR = "80faf095-c807-4558-a2cc-185ed70754ea"; + public static final String NS_IFILEPICKER_8_IID_STR = + "f2c0e216-5d07-4df4-bbcb-37683077ae7e"; + public static final nsID NS_IFILEPICKER_IID = new nsID(NS_IFILEPICKER_IID_STR); + public static final nsID NS_IFILEPICKER_8_IID = + new nsID(NS_IFILEPICKER_8_IID_STR); + public nsIFilePicker_1_8(int /*long*/ address) { super(address); } @@ -55,8 +61,13 @@ public class nsIFilePicker_1_8 extends nsISupports { public static final int filterXML = 16; public static final int filterXUL = 32; public static final int filterApps = 64; + + /* the following constants are defined in mozilla 8 */ + public static final int filterAllowURLs = 128; + public static final int filterAudio = 256; + public static final int filterVideo = 512; - public int Init(int /*long*/ parent, int /*long*/ title, int mode) { + public int Init(int /*long*/ parent, int /*long*/ title, short mode) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), parent, title, mode); } @@ -113,6 +124,16 @@ public class nsIFilePicker_1_8 extends nsISupports { } public int Show(int /*long*/ _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 15, getAddress(), _retval); + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + (Is8 ? 17 : 15), getAddress(), _retval); + } + + public int GetAddToRecentDocs(int[] aAddToRecentDocs) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 15, getAddress(), aAddToRecentDocs); + } + + public int SetAddToRecentDocs(int aAddToRecentDocs) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 16, getAddress(), aAddToRecentDocs); } } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFilePicker_2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFilePicker_2.java deleted file mode 100644 index 223e9231b1..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFilePicker_2.java +++ /dev/null @@ -1,118 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIFilePicker_2 extends nsISupports { - - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 17; - - public static final String NS_IFILEPICKER_IID_STR = - "f2c0e216-5d07-4df4-bbcb-37683077ae7e"; - - public static final nsID NS_IFILEPICKER_IID = - new nsID(NS_IFILEPICKER_IID_STR); - - public nsIFilePicker_2(int /*long*/ address) { - super(address); - } - - public static final int modeOpen = 0; - public static final int modeSave = 1; - public static final int modeGetFolder = 2; - public static final int modeOpenMultiple = 3; - public static final int returnOK = 0; - public static final int returnCancel = 1; - public static final int returnReplace = 2; - public static final int filterAll = 1; - public static final int filterHTML = 2; - public static final int filterText = 4; - public static final int filterImages = 8; - public static final int filterXML = 16; - public static final int filterXUL = 32; - public static final int filterApps = 64; - - public int Init(int /*long*/ parent, int /*long*/ title, int mode) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), parent, title, mode); - } - - public int AppendFilters(int filterMask) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), filterMask); - } - - public int AppendFilter(int /*long*/ title, int /*long*/ filter) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), title, filter); - } - - public int GetDefaultString(int /*long*/ aDefaultString) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aDefaultString); - } - - public int SetDefaultString(int /*long*/ aDefaultString) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress(), aDefaultString); - } - - public int GetDefaultExtension(int /*long*/ aDefaultExtension) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aDefaultExtension); - } - - public int SetDefaultExtension(int /*long*/ aDefaultExtension) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aDefaultExtension); - } - - public int GetFilterIndex(int[] aFilterIndex) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress(), aFilterIndex); - } - - public int SetFilterIndex(int aFilterIndex) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 9, getAddress(), aFilterIndex); - } - - public int GetDisplayDirectory(int /*long*/[] aDisplayDirectory) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 10, getAddress(), aDisplayDirectory); - } - - public int SetDisplayDirectory(int /*long*/ aDisplayDirectory) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 11, getAddress(), aDisplayDirectory); - } - - public int GetFile(int /*long*/[] aFile) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 12, getAddress(), aFile); - } - - public int GetFileURL(int /*long*/[] aFileURL) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 13, getAddress(), aFileURL); - } - - public int GetFiles(int /*long*/[] aFiles) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 14, getAddress(), aFiles); - } - - public int Show(int /*long*/ _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 17, getAddress(), _retval); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFocusManager.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFocusManager.java index cf15868a10..db7af8203c 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFocusManager.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIFocusManager.java @@ -27,7 +27,7 @@ * ***** END LICENSE BLOCK ***** */
package org.eclipse.swt.internal.mozilla;
-public class nsIFocusManager extends nsISupports {
+public class nsIFocusManager extends nsISupports {
static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 17;
@@ -37,7 +37,7 @@ public class nsIFocusManager extends nsISupports { public static final nsID NS_IFOCUSMANAGER_IID =
new nsID(NS_IFOCUSMANAGER_IID_STR);
- public nsIFocusManager(int /*long*/ address) {
+ public nsIFocusManager(int /*long*/ address) {
super(address);
}
@@ -86,31 +86,18 @@ public class nsIFocusManager extends nsISupports { }
public static final int FLAG_RAISE = 1;
-
public static final int FLAG_NOSCROLL = 2;
-
public static final int FLAG_NOSWITCHFRAME = 4;
-
public static final int FLAG_BYMOUSE = 4096;
-
public static final int FLAG_BYKEY = 8192;
-
public static final int FLAG_BYMOVEFOCUS = 16384;
-
public static final int MOVEFOCUS_FORWARD = 1;
-
public static final int MOVEFOCUS_BACKWARD = 2;
-
public static final int MOVEFOCUS_FORWARDDOC = 3;
-
public static final int MOVEFOCUS_BACKWARDDOC = 4;
-
public static final int MOVEFOCUS_FIRST = 5;
-
public static final int MOVEFOCUS_LAST = 6;
-
public static final int MOVEFOCUS_ROOT = 7;
-
public static final int MOVEFOCUS_CARET = 8;
public int WindowRaised(int /*long*/ aWindow) {
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncherDialog.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncherDialog.java index 10ca834a67..b9cd22e8fe 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncherDialog.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncherDialog.java @@ -52,4 +52,4 @@ public class nsIHelperAppLauncherDialog extends nsISupports { public int ShowProgressDialog(int /*long*/ aLauncher, int /*long*/ aContext) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), aLauncher, aContext); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncherDialog_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncherDialog_1_9.java index c97f263869..0bd69ea308 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncherDialog_1_9.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncherDialog_1_9.java @@ -42,9 +42,7 @@ public class nsIHelperAppLauncherDialog_1_9 extends nsISupports { } public static final int REASON_CANTHANDLE = 0; - public static final int REASON_SERVERREQUEST = 1; - public static final int REASON_TYPESNIFFED = 2; public int Show(int /*long*/ aLauncher, int /*long*/ aWindowContext, int aReason) { @@ -54,4 +52,4 @@ public class nsIHelperAppLauncherDialog_1_9 extends nsISupports { public int PromptForSaveToFile(int /*long*/ aLauncher, int /*long*/ aWindowContext, char[] aDefaultFileName, char[] aSuggestedFileExtension, int aForcePrompt, int /*long*/[] _retval) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), aLauncher, aWindowContext, aDefaultFileName, aSuggestedFileExtension, aForcePrompt, _retval); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncher_2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncher_8.java index d90448a9dc..e8e9b9332d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncher_2.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHelperAppLauncher_8.java @@ -1,87 +1,87 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIHelperAppLauncher_2 extends nsICancelable { - - static final int LAST_METHOD_ID = nsICancelable.LAST_METHOD_ID + 11; - - public static final String NS_IHELPERAPPLAUNCHER_IID_STR = - "d9a19faf-497b-408c-b995-777d956b72c0"; - - public static final nsID NS_IHELPERAPPLAUNCHER_IID = - new nsID(NS_IHELPERAPPLAUNCHER_IID_STR); - - public nsIHelperAppLauncher_2(int /*long*/ address) { - super(address); - } - - public int GetMIMEInfo(int /*long*/[] aMIMEInfo) { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 1, getAddress(), aMIMEInfo); - } - - public int GetSource(int /*long*/[] aSource) { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 2, getAddress(), aSource); - } - - public int GetSuggestedFileName(int /*long*/ aSuggestedFileName) { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 3, getAddress(), aSuggestedFileName); - } - - public int SaveToDisk(int /*long*/ aNewFileLocation, int aRememberThisPreference) { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 4, getAddress(), aNewFileLocation, aRememberThisPreference); - } - - public int LaunchWithApplication(int /*long*/ aApplication, int aRememberThisPreference) { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 5, getAddress(), aApplication, aRememberThisPreference); - } - - public int SetWebProgressListener(int /*long*/ aWebProgressListener) { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 6, getAddress(), aWebProgressListener); - } - - public int CloseProgressWindow() { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 7, getAddress()); - } - - public int GetTargetFile(int /*long*/[] aTargetFile) { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 8, getAddress(), aTargetFile); - } - - public int GetTargetFileIsExecutable(int[] aTargetFileIsExecutable) { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 9, getAddress(), aTargetFileIsExecutable); - } - - public int GetTimeDownloadStarted(int /*long*/ aTimeDownloadStarted) { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 10, getAddress(), aTimeDownloadStarted); - } - - public int GetContentLength(int /*long*/ aContentLength) { - return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 11, getAddress(), aContentLength); - } -} +/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by Netscape are Copyright (C) 1998-1999
+ * Netscape Communications Corporation. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * IBM
+ * - Binding to permit interfacing between Mozilla and SWT
+ * - Copyright (C) 2011 IBM Corp. All Rights Reserved.
+ *
+ * ***** END LICENSE BLOCK ***** */
+package org.eclipse.swt.internal.mozilla;
+
+public class nsIHelperAppLauncher_8 extends nsICancelable {
+
+ static final int LAST_METHOD_ID = nsICancelable.LAST_METHOD_ID + 11;
+
+ public static final String NS_IHELPERAPPLAUNCHER_IID_STR =
+ "d9a19faf-497b-408c-b995-777d956b72c0";
+
+ public static final nsID NS_IHELPERAPPLAUNCHER_IID =
+ new nsID(NS_IHELPERAPPLAUNCHER_IID_STR);
+
+ public nsIHelperAppLauncher_8(int /*long*/ address) {
+ super(address);
+ }
+
+ public int GetMIMEInfo(int /*long*/[] aMIMEInfo) {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 1, getAddress(), aMIMEInfo);
+ }
+
+ public int GetSource(int /*long*/[] aSource) {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 2, getAddress(), aSource);
+ }
+
+ public int GetSuggestedFileName(int /*long*/ aSuggestedFileName) {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 3, getAddress(), aSuggestedFileName);
+ }
+
+ public int SaveToDisk(int /*long*/ aNewFileLocation, int aRememberThisPreference) {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 4, getAddress(), aNewFileLocation, aRememberThisPreference);
+ }
+
+ public int LaunchWithApplication(int /*long*/ aApplication, int aRememberThisPreference) {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 5, getAddress(), aApplication, aRememberThisPreference);
+ }
+
+ public int SetWebProgressListener(int /*long*/ aWebProgressListener) {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 6, getAddress(), aWebProgressListener);
+ }
+
+ public int CloseProgressWindow() {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 7, getAddress());
+ }
+
+ public int GetTargetFile(int /*long*/[] aTargetFile) {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 8, getAddress(), aTargetFile);
+ }
+
+ public int GetTargetFileIsExecutable(int[] aTargetFileIsExecutable) {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 9, getAddress(), aTargetFileIsExecutable);
+ }
+
+ public int GetTimeDownloadStarted(int /*long*/ aTimeDownloadStarted) {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 10, getAddress(), aTimeDownloadStarted);
+ }
+
+ public int GetContentLength(int /*long*/ aContentLength) {
+ return XPCOM.VtblCall(nsICancelable.LAST_METHOD_ID + 11, getAddress(), aContentLength);
+ }
+}
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHttpChannel.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHttpChannel.java index eb19f2a696..f72f1fd02a 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHttpChannel.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHttpChannel.java @@ -37,7 +37,7 @@ public class nsIHttpChannel extends nsIChannel { public static final nsID NS_IHTTPCHANNEL_IID = new nsID(NS_IHTTPCHANNEL_IID_STR); - public nsIHttpChannel(int /*long*/ address) { + public nsIHttpChannel(int /*long*/ address) { super(address); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHttpHeaderVisitor.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHttpHeaderVisitor.java index 556a5e22c8..0f8cf30be7 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHttpHeaderVisitor.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIHttpHeaderVisitor.java @@ -37,7 +37,7 @@ public class nsIHttpHeaderVisitor extends nsISupports { public static final nsID NS_IHTTPHEADERVISITOR_IID = new nsID(NS_IHTTPHEADERVISITOR_IID_STR); - public nsIHttpHeaderVisitor(int /*long*/ address) { + public nsIHttpHeaderVisitor(int /*long*/ address) { super(address); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIInterfaceRequestor.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIInterfaceRequestor.java index 16af6e29dc..adb2e8d3df 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIInterfaceRequestor.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIInterfaceRequestor.java @@ -44,4 +44,4 @@ public class nsIInterfaceRequestor extends nsISupports { public int GetInterface(nsID uuid, int /*long*/[] result) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), uuid, result); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIMIMEInputStream.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIMIMEInputStream.java index 2d1d44e25f..3c1fd1876f 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIMIMEInputStream.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIMIMEInputStream.java @@ -27,7 +27,7 @@ * ***** END LICENSE BLOCK ***** */ package org.eclipse.swt.internal.mozilla; -public class nsIMIMEInputStream extends nsIInputStream { +public class nsIMIMEInputStream extends nsIInputStream { static final int LAST_METHOD_ID = nsIInputStream.LAST_METHOD_ID + 4; @@ -37,7 +37,7 @@ public class nsIMIMEInputStream extends nsIInputStream { public static final nsID NS_IMIMEINPUTSTREAM_IID = new nsID(NS_IMIMEINPUTSTREAM_IID_STR); - public nsIMIMEInputStream(int /*long*/ address) { + public nsIMIMEInputStream(int /*long*/ address) { super(address); } @@ -56,4 +56,4 @@ public class nsIMIMEInputStream extends nsIInputStream { public int SetData(int /*long*/ stream) { return XPCOM.VtblCall(nsIInputStream.LAST_METHOD_ID + 4, getAddress(), stream); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrefBranch.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrefBranch.java index 943870cfa5..bc5c4eaf59 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrefBranch.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrefBranch.java @@ -32,21 +32,24 @@ public class nsIPrefBranch extends nsISupports { static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 18; public static final String NS_IPREFBRANCH_IID_STR = - "e0b6e170-691b-11e0-ae3e-0800200c9a66"; + "56c35506-f14b-11d3-99d3-ddbfac2ccf65"; + public static final String NS_IPREFBRANCH_8_IID_STR = + "e0b6e170-691b-11e0-ae3e-0800200c9a66"; + public static final nsID NS_IPREFBRANCH_IID = new nsID(NS_IPREFBRANCH_IID_STR); + public static final nsID NS_IPREFBRANCH_8_IID = + new nsID(NS_IPREFBRANCH_8_IID_STR); + public nsIPrefBranch(int /*long*/ address) { super(address); } public static final int PREF_INVALID = 0; - public static final int PREF_STRING = 32; - public static final int PREF_INT = 64; - public static final int PREF_BOOL = 128; public int GetRoot(int /*long*/[] aRoot) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrefBranch_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrefBranch_1_9.java deleted file mode 100644 index 4e3ac43c18..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrefBranch_1_9.java +++ /dev/null @@ -1,123 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIPrefBranch_1_9 extends nsISupports { - - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 18; - - public static final String NS_IPREFBRANCH_IID_STR = - "56c35506-f14b-11d3-99d3-ddbfac2ccf65"; - - public static final nsID NS_IPREFBRANCH_IID = - new nsID(NS_IPREFBRANCH_IID_STR); - - public nsIPrefBranch_1_9(int /*long*/ address) { - super(address); - } - - public static final int PREF_INVALID = 0; - - public static final int PREF_STRING = 32; - - public static final int PREF_INT = 64; - - public static final int PREF_BOOL = 128; - - public int GetRoot(int /*long*/[] aRoot) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), aRoot); - } - - public int GetPrefType(byte[] aPrefName, int[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), aPrefName, _retval); - } - - public int GetBoolPref(byte[] aPrefName, int[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), aPrefName, _retval); - } - - public int SetBoolPref(byte[] aPrefName, int aValue) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aPrefName, aValue); - } - - public int GetCharPref(byte[] aPrefName, int /*long*/[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress(), aPrefName, _retval); - } - - public int SetCharPref(byte[] aPrefName, byte[] aValue) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aPrefName, aValue); - } - - public int GetIntPref(byte[] aPrefName, int[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aPrefName, _retval); - } - - public int SetIntPref(byte[] aPrefName, int aValue) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress(), aPrefName, aValue); - } - - public int GetComplexValue(byte[] aPrefName, nsID aType, int /*long*/[] aValue) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 9, getAddress(), aPrefName, aType, aValue); - } - - public int SetComplexValue(byte[] aPrefName, nsID aType, int /*long*/ aValue) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 10, getAddress(), aPrefName, aType, aValue); - } - - public int ClearUserPref(byte[] aPrefName) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 11, getAddress(), aPrefName); - } - - public int LockPref(byte[] aPrefName) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 12, getAddress(), aPrefName); - } - - public int PrefHasUserValue(byte[] aPrefName, int[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 13, getAddress(), aPrefName, _retval); - } - - public int PrefIsLocked(byte[] aPrefName, int[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 14, getAddress(), aPrefName, _retval); - } - - public int UnlockPref(byte[] aPrefName) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 15, getAddress(), aPrefName); - } - - public int DeleteBranch(byte[] aStartingAt) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 16, getAddress(), aStartingAt); - } - - public int GetChildList(byte[] aStartingAt, int[] aCount, int /*long*/[] aChildArray) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 17, getAddress(), aStartingAt, aCount, aChildArray); - } - - public int ResetBranch(byte[] aStartingAt) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 18, getAddress(), aStartingAt); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrincipal.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrincipal.java index 4486b3cb27..dd55e933a3 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrincipal.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrincipal.java @@ -27,26 +27,31 @@ * ***** END LICENSE BLOCK ***** */ package org.eclipse.swt.internal.mozilla; -public class nsIPrincipal extends nsISerializable { +import org.eclipse.swt.internal.ole.win32.COM; - static final int LAST_METHOD_ID = nsISerializable.LAST_METHOD_ID + 26; +public class nsIPrincipal extends nsISerializable { + + static final int LAST_METHOD_ID = nsISerializable.LAST_METHOD_ID + (Is8 ? 26 : 23); public static final String NS_IPRINCIPAL_IID_STR = - "b406a2db-e547-4c95-b8e2-ad09ecb54ce0"; + "b8268b9a-2403-44ed-81e3-614075c92034"; public static final nsID NS_IPRINCIPAL_IID = new nsID(NS_IPRINCIPAL_IID_STR); - public nsIPrincipal(int /*long*/ address) { + public static final String NS_IPRINCIPAL_8_IID_STR = + "b406a2db-e547-4c95-b8e2-ad09ecb54ce0"; + + public static final nsID NS_IPRINCIPAL_8_IID = + new nsID(NS_IPRINCIPAL_8_IID_STR); + + public nsIPrincipal(int /*long*/ address) { super(address); } public static final int ENABLE_DENIED = 1; - public static final int ENABLE_UNKNOWN = 2; - public static final int ENABLE_WITH_USER_PERMISSION = 3; - public static final int ENABLE_GRANTED = 4; public int GetPreferences(int /*long*/[] prefBranch, int /*long*/[] id, int /*long*/[] subjectName, int /*long*/[] grantedList, int /*long*/[] deniedList, int[] isTrusted) { @@ -57,87 +62,102 @@ public class nsIPrincipal extends nsISerializable { return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 2, getAddress(), other, _retval); } + public int EqualsIgnoringDomain(int /*long*/ other, int[] _retval) { + if (!Is8) return COM.S_FALSE; + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 3, getAddress(), other, _retval); + } + public int GetHashValue(int[] aHashValue) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 4, getAddress(), aHashValue); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 4 : 3), getAddress(), aHashValue); } public int GetJSPrincipals(int /*long*/ cx, int /*long*/[] _retval) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 5, getAddress(), cx, _retval); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 5 : 4), getAddress(), cx, _retval); } public int GetSecurityPolicy(int /*long*/[] aSecurityPolicy) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 6, getAddress(), aSecurityPolicy); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 6 : 5), getAddress(), aSecurityPolicy); } public int SetSecurityPolicy(int /*long*/ aSecurityPolicy) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 7, getAddress(), aSecurityPolicy); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 7 : 6), getAddress(), aSecurityPolicy); } public int CanEnableCapability(byte[] capability, int /*long*/ _retval) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 8, getAddress(), capability, _retval); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 8 : 7), getAddress(), capability, _retval); } public int SetCanEnableCapability(byte[] capability, short canEnable) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 9, getAddress(), capability, canEnable); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 9 : 8), getAddress(), capability, canEnable); } public int IsCapabilityEnabled(byte[] capability, int /*long*/ annotation, int[] _retval) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 10, getAddress(), capability, annotation, _retval); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 10 : 9), getAddress(), capability, annotation, _retval); } public int EnableCapability(byte[] capability, int /*long*/[] annotation) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 11, getAddress(), capability, annotation); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 11 : 10), getAddress(), capability, annotation); } public int RevertCapability(byte[] capability, int /*long*/[] annotation) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 12, getAddress(), capability, annotation); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 12 : 11), getAddress(), capability, annotation); } public int DisableCapability(byte[] capability, int /*long*/[] annotation) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 13, getAddress(), capability, annotation); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 13 : 12), getAddress(), capability, annotation); } public int GetURI(int /*long*/[] aURI) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 14, getAddress(), aURI); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 14 : 13), getAddress(), aURI); } public int GetDomain(int /*long*/[] aDomain) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 15, getAddress(), aDomain); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 15 : 14), getAddress(), aDomain); } public int SetDomain(int /*long*/ aDomain) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 16, getAddress(), aDomain); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 16 : 15), getAddress(), aDomain); } public int GetOrigin(int /*long*/[] aOrigin) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 17, getAddress(), aOrigin); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 17 : 16), getAddress(), aOrigin); } public int GetHasCertificate(int[] aHasCertificate) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 18, getAddress(), aHasCertificate); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 18 : 17), getAddress(), aHasCertificate); } public int GetFingerprint(int /*long*/ aFingerprint) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 19, getAddress(), aFingerprint); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 19 : 18), getAddress(), aFingerprint); } public int GetPrettyName(int /*long*/ aPrettyName) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 20, getAddress(), aPrettyName); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 20 : 19), getAddress(), aPrettyName); } public int Subsumes(int /*long*/ other, int[] _retval) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 21, getAddress(), other, _retval); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 21 : 20), getAddress(), other, _retval); } public int CheckMayLoad(int /*long*/ uri, int report) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 22, getAddress(), uri, report); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 22 : 21), getAddress(), uri, report); } public int GetSubjectName(int /*long*/ aSubjectName) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 23, getAddress(), aSubjectName); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 23 : 22), getAddress(), aSubjectName); } public int GetCertificate(int /*long*/[] aCertificate) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 24, getAddress(), aCertificate); + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + (Is8 ? 24 : 23), getAddress(), aCertificate); + } + + public int GetCsp(int /*long*/[] aCsp) { + if (!Is8) return COM.S_FALSE; + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 25, getAddress(), aCsp); + } + + public int SetCsp(int /*long*/ aCsp) { + if (!Is8) return COM.S_FALSE; + return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 26, getAddress(), aCsp); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrincipal_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrincipal_1_9.java deleted file mode 100644 index 87695da6cb..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrincipal_1_9.java +++ /dev/null @@ -1,143 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2009 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIPrincipal_1_9 extends nsISerializable { - - static final int LAST_METHOD_ID = nsISerializable.LAST_METHOD_ID + 23; - - public static final String NS_IPRINCIPAL_IID_STR = - "b406a2db-e547-4c95-b8e2-ad09ecb54ce0"; - - public static final nsID NS_IPRINCIPAL_IID = - new nsID(NS_IPRINCIPAL_IID_STR); - - public nsIPrincipal_1_9(int /*long*/ address) { - super(address); - } - - public static final int ENABLE_DENIED = 1; - - public static final int ENABLE_UNKNOWN = 2; - - public static final int ENABLE_WITH_USER_PERMISSION = 3; - - public static final int ENABLE_GRANTED = 4; - - public int GetPreferences(int /*long*/[] prefBranch, int /*long*/[] id, int /*long*/[] subjectName, int /*long*/[] grantedList, int /*long*/[] deniedList, int[] isTrusted) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 1, getAddress(), prefBranch, id, subjectName, grantedList, deniedList, isTrusted); - } - - public int Equals(int /*long*/ other, int[] _retval) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 2, getAddress(), other, _retval); - } - - public int GetHashValue(int[] aHashValue) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 3, getAddress(), aHashValue); - } - - public int GetJSPrincipals(int /*long*/ cx, int /*long*/[] _retval) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 4, getAddress(), cx, _retval); - } - - public int GetSecurityPolicy(int /*long*/[] aSecurityPolicy) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 5, getAddress(), aSecurityPolicy); - } - - public int SetSecurityPolicy(int /*long*/ aSecurityPolicy) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 6, getAddress(), aSecurityPolicy); - } - - public int CanEnableCapability(byte[] capability, int /*long*/ _retval) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 7, getAddress(), capability, _retval); - } - - public int SetCanEnableCapability(byte[] capability, short canEnable) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 8, getAddress(), capability, canEnable); - } - - public int IsCapabilityEnabled(byte[] capability, int /*long*/ annotation, int[] _retval) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 9, getAddress(), capability, annotation, _retval); - } - - public int EnableCapability(byte[] capability, int /*long*/[] annotation) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 10, getAddress(), capability, annotation); - } - - public int RevertCapability(byte[] capability, int /*long*/[] annotation) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 11, getAddress(), capability, annotation); - } - - public int DisableCapability(byte[] capability, int /*long*/[] annotation) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 12, getAddress(), capability, annotation); - } - - public int GetURI(int /*long*/[] aURI) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 13, getAddress(), aURI); - } - - public int GetDomain(int /*long*/[] aDomain) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 14, getAddress(), aDomain); - } - - public int SetDomain(int /*long*/ aDomain) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 15, getAddress(), aDomain); - } - - public int GetOrigin(int /*long*/[] aOrigin) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 16, getAddress(), aOrigin); - } - - public int GetHasCertificate(int[] aHasCertificate) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 17, getAddress(), aHasCertificate); - } - - public int GetFingerprint(int /*long*/ aFingerprint) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 18, getAddress(), aFingerprint); - } - - public int GetPrettyName(int /*long*/ aPrettyName) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 19, getAddress(), aPrettyName); - } - - public int Subsumes(int /*long*/ other, int[] _retval) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 20, getAddress(), other, _retval); - } - - public int CheckMayLoad(int /*long*/ uri, int report) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 21, getAddress(), uri, report); - } - - public int GetSubjectName(int /*long*/ aSubjectName) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 22, getAddress(), aSubjectName); - } - - public int GetCertificate(int /*long*/[] aCertificate) { - return XPCOM.VtblCall(nsISerializable.LAST_METHOD_ID + 23, getAddress(), aCertificate); - } -}
\ No newline at end of file diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrompt.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrompt.java index 11d9397c60..1b87a3d975 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrompt.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPrompt.java @@ -42,37 +42,20 @@ public class nsIPrompt extends nsISupports { } public static final int BUTTON_POS_0 = 1; - public static final int BUTTON_POS_1 = 256; - public static final int BUTTON_POS_2 = 65536; - public static final int BUTTON_TITLE_OK = 1; - public static final int BUTTON_TITLE_CANCEL = 2; - public static final int BUTTON_TITLE_YES = 3; - public static final int BUTTON_TITLE_NO = 4; - public static final int BUTTON_TITLE_SAVE = 5; - public static final int BUTTON_TITLE_DONT_SAVE = 6; - public static final int BUTTON_TITLE_REVERT = 7; - public static final int BUTTON_TITLE_IS_STRING = 127; - public static final int BUTTON_POS_0_DEFAULT = 0; - public static final int BUTTON_POS_1_DEFAULT = 16777216; - public static final int BUTTON_POS_2_DEFAULT = 33554432; - public static final int BUTTON_DELAY_ENABLE = 67108864; - public static final int STD_OK_CANCEL_BUTTONS = 513; - public static final int STD_YES_NO_BUTTONS = 1027; - } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPromptFactory.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPromptFactory.java index 89990b5897..fada150e7c 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPromptFactory.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPromptFactory.java @@ -44,5 +44,4 @@ public class nsIPromptFactory extends nsISupports { public int Alert(char[] aDialogTitle, char[] aText) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), aDialogTitle, aText); } - -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPromptService.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPromptService.java index 92577e4f08..92b3a87f88 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPromptService.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIPromptService.java @@ -58,37 +58,21 @@ public class nsIPromptService extends nsISupports { } public static final int BUTTON_POS_0 = 1; - public static final int BUTTON_POS_1 = 256; - public static final int BUTTON_POS_2 = 65536; - public static final int BUTTON_TITLE_OK = 1; - public static final int BUTTON_TITLE_CANCEL = 2; - public static final int BUTTON_TITLE_YES = 3; - public static final int BUTTON_TITLE_NO = 4; - public static final int BUTTON_TITLE_SAVE = 5; - public static final int BUTTON_TITLE_DONT_SAVE = 6; - public static final int BUTTON_TITLE_REVERT = 7; - public static final int BUTTON_TITLE_IS_STRING = 127; - public static final int BUTTON_POS_0_DEFAULT = 0; - public static final int BUTTON_POS_1_DEFAULT = 16777216; - public static final int BUTTON_POS_2_DEFAULT = 33554432; - public static final int BUTTON_DELAY_ENABLE = 67108864; - public static final int STD_OK_CANCEL_BUTTONS = 513; - public static final int STD_YES_NO_BUTTONS = 1027; public int ConfirmEx(int /*long*/ aParent, char[] aDialogTitle, char[] aText, int aButtonFlags, char[] aButton0Title, char[] aButton1Title, char[] aButton2Title, char[] aCheckMsg, int[] aCheckState, int[] _retval) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIRequest.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIRequest.java index 909ad0de0c..65b548ec28 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIRequest.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIRequest.java @@ -82,20 +82,12 @@ public class nsIRequest extends nsISupports { } public static final int LOAD_NORMAL = 0; - public static final int LOAD_BACKGROUND = 1; - public static final int INHIBIT_CACHING = 128; - public static final int INHIBIT_PERSISTENT_CACHING = 256; - public static final int LOAD_BYPASS_CACHE = 512; - public static final int LOAD_FROM_CACHE = 1024; - public static final int VALIDATE_ALWAYS = 2048; - public static final int VALIDATE_NEVER = 4096; - public static final int VALIDATE_ONCE_PER_SESSION = 8192; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISSLStatus.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISSLStatus.java index 2754d624de..d26735714e 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISSLStatus.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISSLStatus.java @@ -37,7 +37,7 @@ public class nsISSLStatus extends nsISupports { public static final nsID NS_ISSLSTATUS_IID = new nsID(NS_ISSLSTATUS_IID_STR); - public nsISSLStatus(int /*long*/ address) { + public nsISSLStatus(int /*long*/ address) { super(address); } @@ -68,4 +68,4 @@ public class nsISSLStatus extends nsISupports { public int GetIsUntrusted(int[] aIsUntrusted) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aIsUntrusted); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIScriptSecurityManager_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIScriptSecurityManager.java index b2b7de895f..66955f0171 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIScriptSecurityManager_1_9.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIScriptSecurityManager.java @@ -27,9 +27,11 @@ * ***** END LICENSE BLOCK ***** */ package org.eclipse.swt.internal.mozilla; -public class nsIScriptSecurityManager_1_9 extends nsIXPCSecurityManager { +import org.eclipse.swt.internal.ole.win32.COM; - static final int LAST_METHOD_ID = nsIXPCSecurityManager.LAST_METHOD_ID + 26; +public class nsIScriptSecurityManager extends nsIXPCSecurityManager { + + static final int LAST_METHOD_ID = nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 27 : 26); public static final String NS_ISCRIPTSECURITYMANAGER_IID_STR = "3fffd8e8-3fea-442e-a0ed-2ba81ae197d5"; @@ -37,7 +39,19 @@ public class nsIScriptSecurityManager_1_9 extends nsIXPCSecurityManager { public static final nsID NS_ISCRIPTSECURITYMANAGER_IID = new nsID(NS_ISCRIPTSECURITYMANAGER_IID_STR); - public nsIScriptSecurityManager_1_9(int /*long*/ address) { + public static final String NS_ISCRIPTSECURITYMANAGER_191_IID_STR = + "f8e350b9-9f31-451a-8c8f-d10fea26b780"; + + public static final nsID NS_ISCRIPTSECURITYMANAGER_191_IID = + new nsID(NS_ISCRIPTSECURITYMANAGER_191_IID_STR); + + public static final String NS_ISCRIPTSECURITYMANAGER_8_IID_STR = + "50eda256-4dd2-4c7c-baed-96983910af9f"; + + public static final nsID NS_ISCRIPTSECURITYMANAGER_8_IID = + new nsID(NS_ISCRIPTSECURITYMANAGER_8_IID_STR); + + public nsIScriptSecurityManager(int /*long*/ address) { super(address); } @@ -45,115 +59,121 @@ public class nsIScriptSecurityManager_1_9 extends nsIXPCSecurityManager { // return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 1, getAddress(), aJSContext, aJSObject, aClassName, aProperty, aAction); // } -// public int CheckConnect(int /*long*/ aJSContext, int /*long*/ aTargetURI, byte[] aClassName, byte[] aProperty) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 2, getAddress(), aJSContext, aTargetURI, aClassName, aProperty); -// } + public int CheckConnect(int /*long*/ aJSContext, int /*long*/ aTargetURI, byte[] aClassName, byte[] aProperty) { + if (Is8) return COM.S_FALSE; + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 2, getAddress(), aJSContext, aTargetURI, aClassName, aProperty); + } public int CheckLoadURIFromScript(int /*long*/ cx, int /*long*/ uri) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 3, getAddress(), cx, uri); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 2 : 3), getAddress(), cx, uri); } public static final int STANDARD = 0; - public static final int LOAD_IS_AUTOMATIC_DOCUMENT_REPLACEMENT = 1; - public static final int ALLOW_CHROME = 2; - public static final int DISALLOW_INHERIT_PRINCIPAL = 4; - public static final int DISALLOW_SCRIPT_OR_DATA = 4; - public static final int DISALLOW_SCRIPT = 8; public int CheckLoadURIWithPrincipal(int /*long*/ aPrincipal, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 4, getAddress(), aPrincipal, uri, flags); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 3 : 4), getAddress(), aPrincipal, uri, flags); } public int CheckLoadURI(int /*long*/ from, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 5, getAddress(), from, uri, flags); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 4 : 5), getAddress(), from, uri, flags); } public int CheckLoadURIStrWithPrincipal(int /*long*/ aPrincipal, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 6, getAddress(), aPrincipal, uri, flags); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 5 : 6), getAddress(), aPrincipal, uri, flags); } public int CheckLoadURIStr(int /*long*/ from, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 7, getAddress(), from, uri, flags); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 6 : 7), getAddress(), from, uri, flags); } public int CheckFunctionAccess(int /*long*/ cx, int /*long*/ funObj, int /*long*/ targetObj) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 8, getAddress(), cx, funObj, targetObj); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 7 : 8), getAddress(), cx, funObj, targetObj); } public int CanExecuteScripts(int /*long*/ cx, int /*long*/ principal, int[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 9, getAddress(), cx, principal, _retval); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 8 : 9), getAddress(), cx, principal, _retval); } public int GetSubjectPrincipal(int /*long*/[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 10, getAddress(), _retval); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 9 : 10), getAddress(), _retval); } public int GetSystemPrincipal(int /*long*/[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 11, getAddress(), _retval); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 10 : 11), getAddress(), _retval); } // public int GetCertificatePrincipal(int /*long*/ aCertFingerprint, int /*long*/ aSubjectName, int /*long*/ aPrettyName, int /*long*/ aCert, int /*long*/ aURI, int /*long*/[] _retval) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 12, getAddress(), aCertFingerprint, aSubjectName, aPrettyName, aCert, aURI, _retval); +// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 11 : 12), getAddress(), aCertFingerprint, aSubjectName, aPrettyName, aCert, aURI, _retval); // } public int GetCodebasePrincipal(int /*long*/ aURI, int /*long*/[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 13, getAddress(), aURI, _retval); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 12 : 13), getAddress(), aURI, _retval); } // public int RequestCapability(int /*long*/ principal, byte[] capability, int /*long*/ _retval) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 14, getAddress(), principal, capability, _retval); +// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 13 : 14), getAddress(), principal, capability, _retval); // } public int IsCapabilityEnabled(byte[] capability, int[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 15, getAddress(), capability, _retval); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 14 : 15), getAddress(), capability, _retval); } - + public int EnableCapability(byte[] capability) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 16, getAddress(), capability); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 15 : 16), getAddress(), capability); } - + public int RevertCapability(byte[] capability) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 17, getAddress(), capability); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 16 : 17), getAddress(), capability); } - + public int DisableCapability(byte[] capability) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 18, getAddress(), capability); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 17 : 18), getAddress(), capability); } // public int SetCanEnableCapability(int /*long*/ certificateFingerprint, byte[] capability, !ERROR UNKNOWN C TYPE <PRInt16 >! canEnable) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 19, getAddress(), certificateFingerprint, capability, canEnable); +// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 18 : 19), getAddress(), certificateFingerprint, capability, canEnable); // } public int GetObjectPrincipal(int /*long*/ cx, int /*long*/ obj, int /*long*/[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 20, getAddress(), cx, obj, _retval); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 19 : 20), getAddress(), cx, obj, _retval); } - + public int SubjectPrincipalIsSystem(int[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 21, getAddress(), _retval); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 20 : 21), getAddress(), _retval); } - + public int CheckSameOrigin(int /*long*/ aJSContext, int /*long*/ aTargetURI) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 22, getAddress(), aJSContext, aTargetURI); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 21 : 22), getAddress(), aJSContext, aTargetURI); } - + public int CheckSameOriginURI(int /*long*/ aSourceURI, int /*long*/ aTargetURI, int reportError) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 23, getAddress(), aSourceURI, aTargetURI, reportError); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 22 : 23), getAddress(), aSourceURI, aTargetURI, reportError); } - + public int GetPrincipalFromContext(int /*long*/ cx, int /*long*/[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 24, getAddress(), cx, _retval); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 23 : 24), getAddress(), cx, _retval); } - + public int GetChannelPrincipal(int /*long*/ aChannel, int /*long*/[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 25, getAddress(), aChannel, _retval); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 24 : 25), getAddress(), aChannel, _retval); } - + public int IsSystemPrincipal(int /*long*/ aPrincipal, int[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 26, getAddress(), aPrincipal, _retval); + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + (Is8 ? 25 : 26), getAddress(), aPrincipal, _retval); + } + + public int PushContextPrincipal(int /*long*/ cx, int /*long*/ fp, int /*long*/ principal) { + if (!Is8) return COM.S_FALSE; + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 26, getAddress(), cx, fp, principal); + } + + public int PopContextPrincipal(int /*long*/ cx) { + if (!Is8) return COM.S_FALSE; + return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 27, getAddress(), cx); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIScriptSecurityManager_1_9_1.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIScriptSecurityManager_1_9_1.java deleted file mode 100644 index 25ae4813d6..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIScriptSecurityManager_1_9_1.java +++ /dev/null @@ -1,159 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIScriptSecurityManager_1_9_1 extends nsIXPCSecurityManager { - - static final int LAST_METHOD_ID = nsIXPCSecurityManager.LAST_METHOD_ID + 26; - - public static final String NS_ISCRIPTSECURITYMANAGER_IID_STR = - "f8e350b9-9f31-451a-8c8f-d10fea26b780"; - - public static final nsID NS_ISCRIPTSECURITYMANAGER_IID = - new nsID(NS_ISCRIPTSECURITYMANAGER_IID_STR); - - public nsIScriptSecurityManager_1_9_1(int /*long*/ address) { - super(address); - } - -// public int CheckPropertyAccess(int /*long*/ aJSContext, int /*long*/ aJSObject, byte[] aClassName, !ERROR UNKNOWN C TYPE <jsval >! aProperty, int aAction) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 1, getAddress(), aJSContext, aJSObject, aClassName, aProperty, aAction); -// } - - public int CheckConnect(int /*long*/ aJSContext, int /*long*/ aTargetURI, byte[] aClassName, byte[] aProperty) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 2, getAddress(), aJSContext, aTargetURI, aClassName, aProperty); - } - - public int CheckLoadURIFromScript(int /*long*/ cx, int /*long*/ uri) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 3, getAddress(), cx, uri); - } - - public static final int STANDARD = 0; - - public static final int LOAD_IS_AUTOMATIC_DOCUMENT_REPLACEMENT = 1; - - public static final int ALLOW_CHROME = 2; - - public static final int DISALLOW_INHERIT_PRINCIPAL = 4; - - public static final int DISALLOW_SCRIPT_OR_DATA = 4; - - public static final int DISALLOW_SCRIPT = 8; - - public int CheckLoadURIWithPrincipal(int /*long*/ aPrincipal, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 4, getAddress(), aPrincipal, uri, flags); - } - - public int CheckLoadURI(int /*long*/ from, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 5, getAddress(), from, uri, flags); - } - - public int CheckLoadURIStrWithPrincipal(int /*long*/ aPrincipal, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 6, getAddress(), aPrincipal, uri, flags); - } - - public int CheckLoadURIStr(int /*long*/ from, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 7, getAddress(), from, uri, flags); - } - - public int CheckFunctionAccess(int /*long*/ cx, int /*long*/ funObj, int /*long*/ targetObj) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 8, getAddress(), cx, funObj, targetObj); - } - -// public int CanExecuteScripts(int /*long*/ cx, int /*long*/ principal, int[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 9, getAddress(), cx, principal, _retval NS_OUTPARAM); -// } - -// public int GetSubjectPrincipal(int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 10, getAddress(), _retval NS_OUTPARAM); -// } - - public int GetSystemPrincipal(int /*long*/[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 11, getAddress(), _retval); - } - -// public int GetCertificatePrincipal(int /*long*/ aCertFingerprint, int /*long*/ aSubjectName, int /*long*/ aPrettyName, int /*long*/ aCert, int /*long*/ aURI, int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 12, getAddress(), aCertFingerprint, aSubjectName, aPrettyName, aCert, aURI, _retval NS_OUTPARAM); -// } - -// public int GetCodebasePrincipal(int /*long*/ aURI, int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 13, getAddress(), aURI, _retval NS_OUTPARAM); -// } - -// public int RequestCapability(int /*long*/ principal, byte[] capability, int /*long*/ _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 14, getAddress(), principal, capability, _retval NS_OUTPARAM); -// } - -// public int IsCapabilityEnabled(byte[] capability, int[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 15, getAddress(), capability, _retval NS_OUTPARAM); -// } - - public int EnableCapability(byte[] capability) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 16, getAddress(), capability); - } - - public int RevertCapability(byte[] capability) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 17, getAddress(), capability); - } - - public int DisableCapability(byte[] capability) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 18, getAddress(), capability); - } - -// public int SetCanEnableCapability(int /*long*/ certificateFingerprint, byte[] capability, !ERROR UNKNOWN C TYPE <PRInt16 >! canEnable) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 19, getAddress(), certificateFingerprint, capability, canEnable); -// } - -// public int GetObjectPrincipal(int /*long*/ cx, int /*long*/ obj, int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 20, getAddress(), cx, obj, _retval NS_OUTPARAM); -// } - -// public int SubjectPrincipalIsSystem(int[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 21, getAddress(), _retval NS_OUTPARAM); -// } - - public int CheckSameOrigin(int /*long*/ aJSContext, int /*long*/ aTargetURI) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 22, getAddress(), aJSContext, aTargetURI); - } - - public int CheckSameOriginURI(int /*long*/ aSourceURI, int /*long*/ aTargetURI, int reportError) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 23, getAddress(), aSourceURI, aTargetURI, reportError); - } - -// public int GetPrincipalFromContext(int /*long*/ cx, int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 24, getAddress(), cx, _retval NS_OUTPARAM); -// } - -// public int GetChannelPrincipal(int /*long*/ aChannel, int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 25, getAddress(), aChannel, _retval NS_OUTPARAM); -// } - -// public int IsSystemPrincipal(int /*long*/ aPrincipal, int[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 26, getAddress(), aPrincipal, _retval NS_OUTPARAM); -// } -}
\ No newline at end of file diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIScriptSecurityManager_2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIScriptSecurityManager_2.java deleted file mode 100644 index 47abf3b0f7..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIScriptSecurityManager_2.java +++ /dev/null @@ -1,155 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIScriptSecurityManager_2 extends nsIXPCSecurityManager { - - static final int LAST_METHOD_ID = nsIXPCSecurityManager.LAST_METHOD_ID + 29; - - public static final String NS_ISCRIPTSECURITYMANAGER_IID_STR = - "50eda256-4dd2-4c7c-baed-96983910af9f"; - - public static final nsID NS_ISCRIPTSECURITYMANAGER_IID = - new nsID(NS_ISCRIPTSECURITYMANAGER_IID_STR); - - public nsIScriptSecurityManager_2(int /*long*/ address) { - super(address); - } - -// public int CheckPropertyAccess(int /*long*/ aJSContext, int /*long*/ aJSObject, byte[] aClassName, !ERROR UNKNOWN C TYPE <jsval >! aProperty, int aAction) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 1, getAddress(), aJSContext, aJSObject, aClassName, aProperty, aAction); -// } - - public int CheckLoadURIFromScript(int /*long*/ cx, int /*long*/ uri) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 2, getAddress(), cx, uri); - } - - public static final int STANDARD = 0; - - public static final int LOAD_IS_AUTOMATIC_DOCUMENT_REPLACEMENT = 1; - - public static final int ALLOW_CHROME = 2; - - public static final int DISALLOW_INHERIT_PRINCIPAL = 4; - - public static final int DISALLOW_SCRIPT_OR_DATA = 4; - - public static final int DISALLOW_SCRIPT = 8; - - public int CheckLoadURIWithPrincipal(int /*long*/ aPrincipal, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 3, getAddress(), aPrincipal, uri, flags); - } - - public int CheckLoadURI(int /*long*/ from, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 4, getAddress(), from, uri, flags); - } - - public int CheckLoadURIStrWithPrincipal(int /*long*/ aPrincipal, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 5, getAddress(), aPrincipal, uri, flags); - } - - public int CheckLoadURIStr(int /*long*/ from, int /*long*/ uri, int flags) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 6, getAddress(), from, uri, flags); - } - - public int CheckFunctionAccess(int /*long*/ cx, int /*long*/ funObj, int /*long*/ targetObj) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 7, getAddress(), cx, funObj, targetObj); - } - -// public int CanExecuteScripts(int /*long*/ cx, int /*long*/ principal, int[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 8, getAddress(), cx, principal, _retval NS_OUTPARAM); -// } - -// public int GetSubjectPrincipal(int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 9, getAddress(), _retval NS_OUTPARAM); -// } - - public int GetSystemPrincipal(int /*long*/[] _retval) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 10, getAddress(), _retval); - } - -// public int GetCertificatePrincipal(int /*long*/ aCertFingerprint, int /*long*/ aSubjectName, int /*long*/ aPrettyName, int /*long*/ aCert, int /*long*/ aURI, int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 11, getAddress(), aCertFingerprint, aSubjectName, aPrettyName, aCert, aURI, _retval NS_OUTPARAM); -// } - -// public int GetCodebasePrincipal(int /*long*/ aURI, int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 12, getAddress(), aURI, _retval NS_OUTPARAM); -// } - -// public int RequestCapability(int /*long*/ principal, byte[] capability, int /*long*/ _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 13, getAddress(), principal, capability, _retval NS_OUTPARAM); -// } - -// public int IsCapabilityEnabled(byte[] capability, int[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 14, getAddress(), capability, _retval NS_OUTPARAM); -// } - - public int EnableCapability(byte[] capability) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 15, getAddress(), capability); - } - - public int RevertCapability(byte[] capability) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 16, getAddress(), capability); - } - - public int DisableCapability(byte[] capability) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 17, getAddress(), capability); - } - -// public int SetCanEnableCapability(int /*long*/ certificateFingerprint, byte[] capability, !ERROR UNKNOWN C TYPE <PRInt16 >! canEnable) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 18, getAddress(), certificateFingerprint, capability, canEnable); -// } - -// public int GetObjectPrincipal(int /*long*/ cx, int /*long*/ obj, int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 19, getAddress(), cx, obj, _retval NS_OUTPARAM); -// } - -// public int SubjectPrincipalIsSystem(int[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 20, getAddress(), _retval NS_OUTPARAM); -// } - - public int CheckSameOrigin(int /*long*/ aJSContext, int /*long*/ aTargetURI) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 21, getAddress(), aJSContext, aTargetURI); - } - - public int CheckSameOriginURI(int /*long*/ aSourceURI, int /*long*/ aTargetURI, int reportError) { - return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 22, getAddress(), aSourceURI, aTargetURI, reportError); - } - -// public int GetPrincipalFromContext(int /*long*/ cx, int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 23, getAddress(), cx, _retval NS_OUTPARAM); -// } - -// public int GetChannelPrincipal(int /*long*/ aChannel, int /*long*/[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 24, getAddress(), aChannel, _retval NS_OUTPARAM); -// } - -// public int IsSystemPrincipal(int /*long*/ aPrincipal, int[] _retval NS_OUTPARAM) { -// return XPCOM.VtblCall(nsIXPCSecurityManager.LAST_METHOD_ID + 25, getAddress(), aPrincipal, _retval NS_OUTPARAM); -// } -}
\ No newline at end of file diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISeekableStream.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISeekableStream.java index 32a49203cf..74ddd6eb3b 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISeekableStream.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISeekableStream.java @@ -37,14 +37,12 @@ public class nsISeekableStream extends nsISupports { public static final nsID NS_ISEEKABLESTREAM_IID = new nsID(NS_ISEEKABLESTREAM_IID_STR); - public nsISeekableStream(int /*long*/ address) { + public nsISeekableStream(int /*long*/ address) { super(address); } public static final int NS_SEEK_SET = 0; - public static final int NS_SEEK_CUR = 1; - public static final int NS_SEEK_END = 2; public int Seek(int whence, long offset) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISerializable.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISerializable.java index 6e2fed1778..2a7b4c6415 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISerializable.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISerializable.java @@ -27,7 +27,7 @@ * ***** END LICENSE BLOCK ***** */ package org.eclipse.swt.internal.mozilla; -public class nsISerializable extends nsISupports { +public class nsISerializable extends nsISupports { static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 2; @@ -37,7 +37,7 @@ public class nsISerializable extends nsISupports { public static final nsID NS_ISERIALIZABLE_IID = new nsID(NS_ISERIALIZABLE_IID_STR); - public nsISerializable(int /*long*/ address) { + public nsISerializable(int /*long*/ address) { super(address); } @@ -48,4 +48,4 @@ public class nsISerializable extends nsISupports { public int Write(int /*long*/ aOutputStream) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), aOutputStream); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISupports.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISupports.java index e5d3d7cdf3..6b85b54a4e 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISupports.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISupports.java @@ -37,6 +37,8 @@ public class nsISupports { static final int FIRST_METHOD_ID = IsSolaris ? 2 : 0; static final int LAST_METHOD_ID = FIRST_METHOD_ID + 2; + + public static boolean Is8; public static final String NS_ISUPPORTS_IID_STR = "00000000-0000-0000-c000-000000000046"; @@ -65,4 +67,4 @@ public class nsISupports { public int Release() { return XPCOM.VtblCall(FIRST_METHOD_ID + 2, getAddress()); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISupportsWeakReference.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISupportsWeakReference.java index 3d346248de..6d17424ad5 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISupportsWeakReference.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsISupportsWeakReference.java @@ -44,4 +44,4 @@ public class nsISupportsWeakReference extends nsISupports { public int GetWeakReference(int /*long*/[] _retval) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), _retval); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsITooltipListener.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsITooltipListener.java index e0c58a3797..85a419db5f 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsITooltipListener.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsITooltipListener.java @@ -48,4 +48,4 @@ public class nsITooltipListener extends nsISupports { public int OnHideTooltip() { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress()); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsITransfer_2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsITransfer_2.java deleted file mode 100644 index a38e586130..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsITransfer_2.java +++ /dev/null @@ -1,47 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsITransfer_2 extends nsIWebProgressListener2_2 { - - static final int LAST_METHOD_ID = nsIWebProgressListener2_2.LAST_METHOD_ID + 1; - - public static final String NS_ITRANSFER_IID_STR = - "3a982955-dc44-422e-8734-8462bf8d2121"; - - public static final nsID NS_ITRANSFER_IID = - new nsID(NS_ITRANSFER_IID_STR); - - public nsITransfer_2(int /*long*/ address) { - super(address); - } - - public int Init(int /*long*/ aSource, int /*long*/ aTarget, int /*long*/ aDisplayName, int /*long*/ aMIMEInfo, long startTime, int /*long*/ aTempFile, int /*long*/ aCancelable) { - return XPCOM.VtblCall(nsIWebProgressListener2_2.LAST_METHOD_ID + 1, getAddress(), aSource, aTarget, aDisplayName, aMIMEInfo, startTime, aTempFile, aCancelable); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIURI.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIURI.java index 9f550e50c5..d8c85a508c 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIURI.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIURI.java @@ -28,14 +28,20 @@ package org.eclipse.swt.internal.mozilla; public class nsIURI extends nsISupports { - - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 30; + + static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + (Is8 ? 32 : 26); public static final String NS_IURI_IID_STR = - "12120b20-0929-40e9-88cf-6e08766e8b23"; + "07a22cc0-0ce5-11d3-9331-00104ba0fd40"; + + public static final String NS_IURI_8_IID_STR = + "395fe045-7d18-4adb-a3fd-af98c8a1af11"; public static final nsID NS_IURI_IID = new nsID(NS_IURI_IID_STR); + + public static final nsID NS_IURI_8_IID = + new nsID(NS_IURI_8_IID_STR); public nsIURI(int /*long*/ address) { super(address); @@ -144,4 +150,34 @@ public class nsIURI extends nsISupports { public int GetOriginCharset(int /*long*/ aOriginCharset) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 26, getAddress(), aOriginCharset); } + + public int GetRef(int /*long*/ aRef) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 27, getAddress(), aRef); + } + + public int SetRef(int /*long*/ aRef) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 28, getAddress(), aRef); + } + + public int EqualsExceptRef(int /*long*/ other, int[] _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 29, getAddress(), other, _retval); + } + + public int CloneIgnoringRef(int /*long*/[] _retval) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 30, getAddress(), _retval); + } + + public int GetSpecIgnoringRef(int /*long*/ aSpecIgnoringRef) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 31, getAddress(), aSpecIgnoringRef); + } + + public int GetHasRef(int[] aHasRef) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 32, getAddress(), aHasRef); + } } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIURI_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIURI_1_9.java deleted file mode 100644 index cafdf24ce5..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIURI_1_9.java +++ /dev/null @@ -1,147 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIURI_1_9 extends nsISupports { - - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 26; - - public static final String NS_IURI_IID_STR = - "07a22cc0-0ce5-11d3-9331-00104ba0fd40"; - - public static final nsID NS_IURI_IID = - new nsID(NS_IURI_IID_STR); - - public nsIURI_1_9(int /*long*/ address) { - super(address); - } - - public int GetSpec(int /*long*/ aSpec) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), aSpec); - } - - public int SetSpec(int /*long*/ aSpec) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), aSpec); - } - - public int GetPrePath(int /*long*/ aPrePath) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), aPrePath); - } - - public int GetScheme(int /*long*/ aScheme) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aScheme); - } - - public int SetScheme(int /*long*/ aScheme) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress(), aScheme); - } - - public int GetUserPass(int /*long*/ aUserPass) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aUserPass); - } - - public int SetUserPass(int /*long*/ aUserPass) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aUserPass); - } - - public int GetUsername(int /*long*/ aUsername) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress(), aUsername); - } - - public int SetUsername(int /*long*/ aUsername) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 9, getAddress(), aUsername); - } - - public int GetPassword(int /*long*/ aPassword) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 10, getAddress(), aPassword); - } - - public int SetPassword(int /*long*/ aPassword) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 11, getAddress(), aPassword); - } - - public int GetHostPort(int /*long*/ aHostPort) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 12, getAddress(), aHostPort); - } - - public int SetHostPort(int /*long*/ aHostPort) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 13, getAddress(), aHostPort); - } - - public int GetHost(int /*long*/ aHost) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 14, getAddress(), aHost); - } - - public int SetHost(int /*long*/ aHost) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 15, getAddress(), aHost); - } - - public int GetPort(int[] aPort) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 16, getAddress(), aPort); - } - - public int SetPort(int aPort) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 17, getAddress(), aPort); - } - - public int GetPath(int /*long*/ aPath) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 18, getAddress(), aPath); - } - - public int SetPath(int /*long*/ aPath) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 19, getAddress(), aPath); - } - - public int Equals(int /*long*/ other, int[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 20, getAddress(), other, _retval); - } - - public int SchemeIs(byte[] scheme, int[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 21, getAddress(), scheme, _retval); - } - - public int Clone(int /*long*/[] _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 22, getAddress(), _retval); - } - - public int Resolve(int /*long*/ relativePath, int /*long*/ _retval) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 23, getAddress(), relativePath, _retval); - } - - public int GetAsciiSpec(int /*long*/ aAsciiSpec) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 24, getAddress(), aAsciiSpec); - } - - public int GetAsciiHost(int /*long*/ aAsciiHost) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 25, getAddress(), aAsciiHost); - } - - public int GetOriginCharset(int /*long*/ aOriginCharset) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 26, getAddress(), aOriginCharset); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIUploadChannel.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIUploadChannel.java index 08807366f7..9a8dc985b9 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIUploadChannel.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIUploadChannel.java @@ -37,7 +37,7 @@ public class nsIUploadChannel extends nsISupports { public static final nsID NS_IUPLOADCHANNEL_IID = new nsID(NS_IUPLOADCHANNEL_IID_STR); - public nsIUploadChannel(int /*long*/ address) { + public nsIUploadChannel(int /*long*/ address) { super(address); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWeakReference.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWeakReference.java index faf448bd94..8a2c302f40 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWeakReference.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWeakReference.java @@ -44,4 +44,4 @@ public class nsIWeakReference extends nsISupports { public int QueryReferent(nsID uuid, int /*long*/[] result) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), uuid, result); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowser.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowser.java index dbc1852ad4..da52ada08d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowser.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowser.java @@ -29,14 +29,20 @@ package org.eclipse.swt.internal.mozilla; public class nsIWebBrowser extends nsISupports { - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 9; + static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + (Is8 ? 9 : 7); public static final String NS_IWEBBROWSER_IID_STR = - "33e9d001-caab-4ba9-8961-54902f197202"; + "69e5df00-7b8b-11d3-af61-00a024ffc08c"; + public static final String NS_IWEBBROWSER_8_IID_STR = + "33e9d001-caab-4ba9-8961-54902f197202"; + public static final nsID NS_IWEBBROWSER_IID = new nsID(NS_IWEBBROWSER_IID_STR); + public static final nsID NS_IWEBBROWSER_8_IID = + new nsID(NS_IWEBBROWSER_8_IID_STR); + public nsIWebBrowser(int /*long*/ address) { super(address); } @@ -68,4 +74,14 @@ public class nsIWebBrowser extends nsISupports { public int GetContentDOMWindow(int /*long*/[] aContentDOMWindow) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aContentDOMWindow); } -}
\ No newline at end of file + + public int GetIsActive(int[] aIsActive) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress(), aIsActive); + } + + public int SetIsActive(int aIsActive) { + if (!Is8) return XPCOM.NS_COMFALSE; + return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 9, getAddress(), aIsActive); + } +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserChrome.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserChrome.java index 823c4a62d0..12c690e679 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserChrome.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserChrome.java @@ -42,9 +42,7 @@ public class nsIWebBrowserChrome extends nsISupports { } public static final int STATUS_SCRIPT = 1; - public static final int STATUS_SCRIPT_DEFAULT = 2; - public static final int STATUS_LINK = 3; public int SetStatus(int statusType, char[] status) { @@ -60,51 +58,28 @@ public class nsIWebBrowserChrome extends nsISupports { } public static final int CHROME_DEFAULT = 1; - public static final int CHROME_WINDOW_BORDERS = 2; - public static final int CHROME_WINDOW_CLOSE = 4; - public static final int CHROME_WINDOW_RESIZE = 8; - public static final int CHROME_MENUBAR = 16; - public static final int CHROME_TOOLBAR = 32; - public static final int CHROME_LOCATIONBAR = 64; - public static final int CHROME_STATUSBAR = 128; - public static final int CHROME_PERSONAL_TOOLBAR = 256; - public static final int CHROME_SCROLLBARS = 512; - public static final int CHROME_TITLEBAR = 1024; - public static final int CHROME_EXTRA = 2048; - public static final int CHROME_WITH_SIZE = 4096; - public static final int CHROME_WITH_POSITION = 8192; - public static final int CHROME_WINDOW_MIN = 16384; - public static final int CHROME_WINDOW_POPUP = 32768; - public static final int CHROME_WINDOW_RAISED = 33554432; - public static final int CHROME_WINDOW_LOWERED = 67108864; - public static final int CHROME_CENTER_SCREEN = 134217728; - public static final int CHROME_DEPENDENT = 268435456; - public static final int CHROME_MODAL = 536870912; - public static final int CHROME_OPENAS_DIALOG = 1073741824; - public static final int CHROME_OPENAS_CHROME = -2147483648; - public static final int CHROME_ALL = 4094; public int GetChromeFlags(int[] aChromeFlags) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserChromeFocus.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserChromeFocus.java index 6ad6792bf4..f2c0984e85 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserChromeFocus.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserChromeFocus.java @@ -48,4 +48,4 @@ public class nsIWebBrowserChromeFocus extends nsISupports { public int FocusPrevElement() { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress()); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserFocus.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserFocus.java index 788f44ee6b..509c974a4c 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserFocus.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserFocus.java @@ -72,4 +72,4 @@ public class nsIWebBrowserFocus extends nsISupports { public int SetFocusedElement(int /*long*/ aFocusedElement) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress(), aFocusedElement); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserSetup.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserSetup.java index 6ea241f427..1885facb6a 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserSetup.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserSetup.java @@ -42,19 +42,12 @@ public class nsIWebBrowserSetup extends nsISupports { } public static final int SETUP_ALLOW_PLUGINS = 1; - public static final int SETUP_ALLOW_JAVASCRIPT = 2; - public static final int SETUP_ALLOW_META_REDIRECTS = 3; - public static final int SETUP_ALLOW_SUBFRAMES = 4; - public static final int SETUP_ALLOW_IMAGES = 5; - public static final int SETUP_FOCUS_DOC_BEFORE_CONTENT = 6; - public static final int SETUP_USE_GLOBAL_HISTORY = 256; - public static final int SETUP_IS_CHROME_WRAPPER = 7; public int SetProperty(int aId, int aValue) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserStream.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserStream.java index 740ab4c595..4b69ae8e8f 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserStream.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowserStream.java @@ -52,4 +52,4 @@ public class nsIWebBrowserStream extends nsISupports { public int CloseStream() { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress()); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowser_1_9.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowser_1_9.java deleted file mode 100644 index c6d94a69af..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebBrowser_1_9.java +++ /dev/null @@ -1,71 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003, 2005 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIWebBrowser_1_9 extends nsISupports { - - static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 7; - - public static final String NS_IWEBBROWSER_IID_STR = - "69e5df00-7b8b-11d3-af61-00a024ffc08c"; - - public static final nsID NS_IWEBBROWSER_IID = - new nsID(NS_IWEBBROWSER_IID_STR); - - public nsIWebBrowser_1_9(int /*long*/ address) { - super(address); - } - - public int AddWebBrowserListener(int /*long*/ aListener, nsID aIID) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), aListener, aIID); - } - - public int RemoveWebBrowserListener(int /*long*/ aListener, nsID aIID) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), aListener, aIID); - } - - public int GetContainerWindow(int /*long*/[] aContainerWindow) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), aContainerWindow); - } - - public int SetContainerWindow(int /*long*/ aContainerWindow) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aContainerWindow); - } - - public int GetParentURIContentListener(int /*long*/[] aParentURIContentListener) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress(), aParentURIContentListener); - } - - public int SetParentURIContentListener(int /*long*/ aParentURIContentListener) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aParentURIContentListener); - } - - public int GetContentDOMWindow(int /*long*/[] aContentDOMWindow) { - return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aContentDOMWindow); - } -}
\ No newline at end of file diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebNavigation.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebNavigation.java index 24248d29eb..a4540b7ef8 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebNavigation.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebNavigation.java @@ -62,21 +62,13 @@ public class nsIWebNavigation extends nsISupports { } public static final int LOAD_FLAGS_MASK = 65535; - public static final int LOAD_FLAGS_NONE = 0; - public static final int LOAD_FLAGS_IS_REFRESH = 16; - public static final int LOAD_FLAGS_IS_LINK = 32; - public static final int LOAD_FLAGS_BYPASS_HISTORY = 64; - public static final int LOAD_FLAGS_REPLACE_HISTORY = 128; - public static final int LOAD_FLAGS_BYPASS_CACHE = 256; - public static final int LOAD_FLAGS_BYPASS_PROXY = 512; - public static final int LOAD_FLAGS_CHARSET_CHANGE = 1024; public int LoadURI(char[] uri, int loadFlags, int /*long*/ referrer, int /*long*/ postData, int /*long*/ headers) { @@ -88,9 +80,7 @@ public class nsIWebNavigation extends nsISupports { } public static final int STOP_NETWORK = 1; - public static final int STOP_CONTENT = 2; - public static final int STOP_ALL = 3; public int Stop(int stopFlags) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebNavigationInfo.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebNavigationInfo.java index e6817fab08..bf7dc9e223 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebNavigationInfo.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebNavigationInfo.java @@ -42,14 +42,11 @@ public class nsIWebNavigationInfo extends nsISupports { } public static final int UNSUPPORTED = 0; - public static final int IMAGE = 1; - public static final int PLUGIN = 2; - public static final int OTHER = 32768; public int IsTypeSupported(int /*long*/ aType, int /*long*/ aWebNav, int[] _retval) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), aType, aWebNav, _retval); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgress.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgress.java index 05fd3516b8..143ce4f98b 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgress.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgress.java @@ -42,23 +42,14 @@ public class nsIWebProgress extends nsISupports { } public static final int NOTIFY_STATE_REQUEST = 1; - public static final int NOTIFY_STATE_DOCUMENT = 2; - public static final int NOTIFY_STATE_NETWORK = 4; - public static final int NOTIFY_STATE_WINDOW = 8; - public static final int NOTIFY_STATE_ALL = 15; - public static final int NOTIFY_PROGRESS = 16; - public static final int NOTIFY_STATUS = 32; - public static final int NOTIFY_SECURITY = 64; - public static final int NOTIFY_LOCATION = 128; - public static final int NOTIFY_ALL = 255; public int AddProgressListener(int /*long*/ listener, int aNotifyMask) { diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgressListener.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgressListener.java index 2704c1bfe0..33fc8ad2cd 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgressListener.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgressListener.java @@ -42,33 +42,19 @@ public class nsIWebProgressListener extends nsISupports { } public static final int STATE_START = 1; - public static final int STATE_REDIRECTING = 2; - public static final int STATE_TRANSFERRING = 4; - public static final int STATE_NEGOTIATING = 8; - public static final int STATE_STOP = 16; - public static final int STATE_IS_REQUEST = 65536; - public static final int STATE_IS_DOCUMENT = 131072; - public static final int STATE_IS_NETWORK = 262144; - public static final int STATE_IS_WINDOW = 524288; - public static final int STATE_IS_INSECURE = 4; - public static final int STATE_IS_BROKEN = 1; - public static final int STATE_IS_SECURE = 2; - public static final int STATE_SECURE_HIGH = 262144; - public static final int STATE_SECURE_MED = 65536; - public static final int STATE_SECURE_LOW = 131072; public int OnStateChange(int /*long*/ aWebProgress, int /*long*/ aRequest, int aStateFlags, int aStatus) { @@ -90,4 +76,4 @@ public class nsIWebProgressListener extends nsISupports { public int OnSecurityChange(int /*long*/ aWebProgress, int /*long*/ aRequest, int state) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress(), aWebProgress, aRequest, state); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgressListener2_2.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgressListener2_2.java deleted file mode 100644 index 775f302ee9..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWebProgressListener2_2.java +++ /dev/null @@ -1,47 +0,0 @@ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * The Original Code is Mozilla Communicator client code, released March 31, 1998. - * - * The Initial Developer of the Original Code is - * Netscape Communications Corporation. - * Portions created by Netscape are Copyright (C) 1998-1999 - * Netscape Communications Corporation. All Rights Reserved. - * - * Contributor(s): - * - * IBM - * - Binding to permit interfacing between Mozilla and SWT - * - Copyright (C) 2003 IBM Corp. All Rights Reserved. - * - * ***** END LICENSE BLOCK ***** */ -package org.eclipse.swt.internal.mozilla; - -public class nsIWebProgressListener2_2 extends nsIWebProgressListener { - - static final int LAST_METHOD_ID = nsIWebProgressListener.LAST_METHOD_ID + 2; - - public static final String NS_IWEBPROGRESSLISTENER2_IID_STR = - "dde39de0-e4e0-11da-8ad9-0800200c9a66"; - - public static final nsID NS_IWEBPROGRESSLISTENER2_IID = - new nsID(NS_IWEBPROGRESSLISTENER2_IID_STR); - - public nsIWebProgressListener2_2(int /*long*/ address) { - super(address); - } - - public int OnProgressChange64(int /*long*/ aWebProgress, int /*long*/ aRequest, long aCurSelfProgress, long aMaxSelfProgress, long aCurTotalProgress, long aMaxTotalProgress) { - return XPCOM.VtblCall(nsIWebProgressListener.LAST_METHOD_ID + 1, getAddress(), aWebProgress, aRequest, aCurSelfProgress, aMaxSelfProgress, aCurTotalProgress, aMaxTotalProgress); - } -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWindowCreator.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWindowCreator.java index d7f5d7fb93..ef0896d71d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWindowCreator.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWindowCreator.java @@ -44,4 +44,4 @@ public class nsIWindowCreator extends nsISupports { public int CreateChromeWindow(int /*long*/ parent, int chromeFlags, int /*long*/[] _retval) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), parent, chromeFlags, _retval); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWindowWatcher.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWindowWatcher.java index 6a1fc590b2..90b46f947b 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWindowWatcher.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIWindowWatcher.java @@ -84,4 +84,4 @@ public class nsIWindowWatcher extends nsISupports { public int SetActiveWindow(int /*long*/ aActiveWindow) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 11, getAddress(), aActiveWindow); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIX509Cert.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIX509Cert.java index 6023055154..d49bd56f27 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIX509Cert.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIX509Cert.java @@ -37,7 +37,7 @@ public class nsIX509Cert extends nsISupports { public static final nsID NS_IX509CERT_IID = new nsID(NS_IX509CERT_IID_STR); - public nsIX509Cert(int /*long*/ address) { + public nsIX509Cert(int /*long*/ address) { super(address); } @@ -122,55 +122,30 @@ public class nsIX509Cert extends nsISupports { } public static final int UNKNOWN_CERT = 0; - public static final int CA_CERT = 1; - public static final int USER_CERT = 2; - public static final int EMAIL_CERT = 4; - public static final int SERVER_CERT = 8; - public static final int VERIFIED_OK = 0; - public static final int NOT_VERIFIED_UNKNOWN = 1; - public static final int CERT_REVOKED = 2; - public static final int CERT_EXPIRED = 4; - public static final int CERT_NOT_TRUSTED = 8; - public static final int ISSUER_NOT_TRUSTED = 16; - public static final int ISSUER_UNKNOWN = 32; - public static final int INVALID_CA = 64; - public static final int USAGE_NOT_ALLOWED = 128; - public static final int CERT_USAGE_SSLClient = 0; - public static final int CERT_USAGE_SSLServer = 1; - public static final int CERT_USAGE_SSLServerWithStepUp = 2; - public static final int CERT_USAGE_SSLCA = 3; - public static final int CERT_USAGE_EmailSigner = 4; - public static final int CERT_USAGE_EmailRecipient = 5; - public static final int CERT_USAGE_ObjectSigner = 6; - public static final int CERT_USAGE_UserCertImport = 7; - public static final int CERT_USAGE_VerifyCA = 8; - public static final int CERT_USAGE_ProtectedObjectSigner = 9; - public static final int CERT_USAGE_StatusResponder = 10; - public static final int CERT_USAGE_AnyCA = 11; public int GetChain(int /*long*/[] _retval) { @@ -200,4 +175,4 @@ public class nsIX509Cert extends nsISupports { public int Equals(int /*long*/ other, int[] _retval) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 27, getAddress(), other, _retval); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIX509CertValidity.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIX509CertValidity.java index 2357b4d704..23f575045a 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIX509CertValidity.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIX509CertValidity.java @@ -37,7 +37,7 @@ public class nsIX509CertValidity extends nsISupports { public static final nsID NS_IX509CERTVALIDITY_IID = new nsID(NS_IX509CERTVALIDITY_IID_STR); - public nsIX509CertValidity(int /*long*/ address) { + public nsIX509CertValidity(int /*long*/ address) { super(address); } @@ -72,4 +72,4 @@ public class nsIX509CertValidity extends nsISupports { public int GetNotAfterGMT(int /*long*/ aNotAfterGMT) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress(), aNotAfterGMT); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIXPCSecurityManager.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIXPCSecurityManager.java index 884b6d986a..55eab3890d 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIXPCSecurityManager.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/common/org/eclipse/swt/internal/mozilla/nsIXPCSecurityManager.java @@ -76,4 +76,4 @@ public class nsIXPCSecurityManager extends nsISupports { public int CanAccess(int aAction, int /*long*/ aCallContext, int /*long*/ aJSContext, int /*long*/ aJSObject, int /*long*/ aObj, int /*long*/ aClassInfo, int /*long*/ aName, int /*long*/[] aPolicy) { return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aAction, aCallContext, aJSContext, aJSObject, aObj, aClassInfo, aName, aPolicy); } -}
\ No newline at end of file +} diff --git a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/win32/org/eclipse/swt/browser/MozillaDelegate.java b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/win32/org/eclipse/swt/browser/MozillaDelegate.java index 67e33a157e..93d231b06b 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT Mozilla/win32/org/eclipse/swt/browser/MozillaDelegate.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Mozilla/win32/org/eclipse/swt/browser/MozillaDelegate.java @@ -90,7 +90,7 @@ int /*long*/ getHandle () { return browser.handle; } -String getJSLibraryName_Pre2 () { +String getJSLibraryName_Pre4 () { return "js3250.dll"; //$NON-NLS-1$ } |