From db56ae99262fd517d79744e9f195857c575e09ef Mon Sep 17 00:00:00 2001 From: "dbradley%netscape.com" Date: Mon, 28 Apr 2003 16:51:38 +0000 Subject: [PATCH] Bug 203093 - Move ActiveXObject --> NSActiveXObject. r=adamlock, sr=alecf, a=sspitzer --- js/src/xpconnect/src/XPCIDispatchExtension.cpp | 8 ++++++-- js/src/xpconnect/src/xpcjsruntime.cpp | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/js/src/xpconnect/src/XPCIDispatchExtension.cpp b/js/src/xpconnect/src/XPCIDispatchExtension.cpp index 956503ab3c4..5f2c5b37209 100644 --- a/js/src/xpconnect/src/XPCIDispatchExtension.cpp +++ b/js/src/xpconnect/src/XPCIDispatchExtension.cpp @@ -134,11 +134,15 @@ ActiveXConstructor(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, JSBool XPCIDispatchExtension::Initialize(JSContext * aJSContext, JSObject * aGlobalJSObj) { - JSBool result = JS_DefineFunction(aJSContext, aGlobalJSObj, "ActiveXObject", + JSBool result = JS_DefineFunction(aJSContext, aGlobalJSObj, + nsXPConnect::GetRuntime()->GetStringName( + XPCJSRuntime::IDX_ACTIVEX_OBJECT), ActiveXConstructor, 1, 0) != nsnull; #ifdef XPC_COMOBJECT if(result) - result = JS_DefineFunction(aJSContext, aGlobalJSObj, "COMObject", + result = JS_DefineFunction(aJSContext, aGlobalJSObj, + nsXPConnect::GetRuntime()->GetStringName( + XPCJSRuntime::IDX_COM_OBJECT), COMObjectConstructor, 1, 0) != nsnull; #endif return result; diff --git a/js/src/xpconnect/src/xpcjsruntime.cpp b/js/src/xpconnect/src/xpcjsruntime.cpp index 8175a80a411..9887f219857 100644 --- a/js/src/xpconnect/src/xpcjsruntime.cpp +++ b/js/src/xpconnect/src/xpcjsruntime.cpp @@ -53,7 +53,7 @@ const char* XPCJSRuntime::mStrings[] = { "prototype", // IDX_PROTOTYPE "createInstance" // IDX_CREATE_INSTANCE #ifdef XPC_IDISPATCH_SUPPORT - , "ActiveXObject" // IDX_ACTIVEX_OBJECT + , "NSActiveXObject" // IDX_ACTIVEX_OBJECT , "COMObject" // IDX_COMOBJECT #endif };