summaryrefslogtreecommitdiffstats
path: root/WebCore/bridge/NP_jsobject.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/bridge/NP_jsobject.cpp')
-rw-r--r--WebCore/bridge/NP_jsobject.cpp22
1 files changed, 5 insertions, 17 deletions
diff --git a/WebCore/bridge/NP_jsobject.cpp b/WebCore/bridge/NP_jsobject.cpp
index 4a6a2b1..59900c5 100644
--- a/WebCore/bridge/NP_jsobject.cpp
+++ b/WebCore/bridge/NP_jsobject.cpp
@@ -31,12 +31,10 @@
#include "PlatformString.h"
#include "StringSourceProvider.h"
-#ifdef ANDROID_NPN_SETEXCEPTION
-#include "c_runtime.h"
-#endif // ANDROID_NPN_SETEXCEPTION
#include "c_utility.h"
#include "c_instance.h"
#include "IdentifierRep.h"
+#include "JSDOMBinding.h"
#include "npruntime_impl.h"
#include "npruntime_priv.h"
#include "runtime_root.h"
@@ -126,7 +124,7 @@ bool _NPN_InvokeDefault(NPP, NPObject* o, const NPVariant* args, uint32_t argCou
getListFromVariantArgs(exec, args, argCount, rootObject, argList);
ProtectedPtr<JSGlobalObject> globalObject = rootObject->globalObject();
globalObject->globalData()->timeoutChecker.start();
- JSValue resultV = call(exec, function, callType, callData, function, argList);
+ JSValue resultV = JSC::call(exec, function, callType, callData, function, argList);
globalObject->globalData()->timeoutChecker.stop();
// Convert and return the result of the function call.
@@ -176,7 +174,7 @@ bool _NPN_Invoke(NPP npp, NPObject* o, NPIdentifier methodName, const NPVariant*
getListFromVariantArgs(exec, args, argCount, rootObject, argList);
ProtectedPtr<JSGlobalObject> globalObject = rootObject->globalObject();
globalObject->globalData()->timeoutChecker.start();
- JSValue resultV = call(exec, function, callType, callData, obj->imp, argList);
+ JSValue resultV = JSC::call(exec, function, callType, callData, obj->imp, argList);
globalObject->globalData()->timeoutChecker.stop();
// Convert and return the result of the function call.
@@ -206,7 +204,7 @@ bool _NPN_Evaluate(NPP, NPObject* o, NPString* s, NPVariant* variant)
String scriptString = convertNPStringToUTF16(s);
ProtectedPtr<JSGlobalObject> globalObject = rootObject->globalObject();
globalObject->globalData()->timeoutChecker.start();
- Completion completion = JSC::evaluate(globalObject->globalExec(), globalObject->globalScopeChain(), makeSource(scriptString));
+ Completion completion = JSC::evaluate(globalObject->globalExec(), globalObject->globalScopeChain(), makeSource(scriptString), JSC::JSValue());
globalObject->globalData()->timeoutChecker.stop();
ComplType type = completion.complType();
@@ -379,21 +377,11 @@ bool _NPN_HasMethod(NPP, NPObject* o, NPIdentifier methodName)
return false;
}
-#ifdef ANDROID_NPN_SETEXCEPTION
-void _NPN_SetException(NPObject* o, const NPUTF8* message)
-#else
void _NPN_SetException(NPObject*, const NPUTF8* message)
-#endif
{
-#ifdef ANDROID_NPN_SETEXCEPTION
- if (o->_class == NPScriptObjectClass) {
- JSC::Bindings::SetGlobalException(message);
- }
-#else
// Ignorning the NPObject param is consistent with the Mozilla implementation.
UString exception(message);
CInstance::setGlobalException(exception);
-#endif // ANDROID_NPN_SETEXCEPTION
}
bool _NPN_Enumerate(NPP, NPObject* o, NPIdentifier** identifier, uint32_t* count)
@@ -456,7 +444,7 @@ bool _NPN_Construct(NPP, NPObject* o, const NPVariant* args, uint32_t argCount,
getListFromVariantArgs(exec, args, argCount, rootObject, argList);
ProtectedPtr<JSGlobalObject> globalObject = rootObject->globalObject();
globalObject->globalData()->timeoutChecker.start();
- JSValue resultV = construct(exec, constructor, constructType, constructData, argList);
+ JSValue resultV = JSC::construct(exec, constructor, constructType, constructData, argList);
globalObject->globalData()->timeoutChecker.stop();
// Convert and return the result.