summaryrefslogtreecommitdiff
path: root/xfa/fxjse/context.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'xfa/fxjse/context.cpp')
-rw-r--r--xfa/fxjse/context.cpp52
1 files changed, 0 insertions, 52 deletions
diff --git a/xfa/fxjse/context.cpp b/xfa/fxjse/context.cpp
index 83af487632..abb30c5dc5 100644
--- a/xfa/fxjse/context.cpp
+++ b/xfa/fxjse/context.cpp
@@ -37,12 +37,6 @@ FXJSE_HVALUE FXJSE_Context_GetGlobalObject(FXJSE_HCONTEXT hContext) {
return reinterpret_cast<FXJSE_HVALUE>(lpValue);
}
-FXJSE_HRUNTIME FXJSE_Context_GetRuntime(FXJSE_HCONTEXT hContext) {
- CFXJSE_Context* pContext = reinterpret_cast<CFXJSE_Context*>(hContext);
- return pContext ? reinterpret_cast<FXJSE_HRUNTIME>(pContext->GetRuntime())
- : NULL;
-}
-
static const FX_CHAR* szCompatibleModeScripts[] = {
"(function(global, list) {\n"
" 'use strict';\n"
@@ -127,52 +121,6 @@ v8::Local<v8::Object> FXJSE_CreateReturnValue(v8::Isolate* pIsolate,
return hReturnValue;
}
-FX_BOOL FXJSE_ReturnValue_GetMessage(FXJSE_HVALUE hRetValue,
- CFX_ByteString& utf8Name,
- CFX_ByteString& utf8Message) {
- CFXJSE_Value* lpValue = reinterpret_cast<CFXJSE_Value*>(hRetValue);
- if (!lpValue) {
- return FALSE;
- }
- v8::Isolate* pIsolate = lpValue->GetIsolate();
- CFXJSE_ScopeUtil_IsolateHandleRootContext scope(pIsolate);
- v8::Local<v8::Value> hValue =
- v8::Local<v8::Value>::New(pIsolate, lpValue->DirectGetValue());
- if (!hValue->IsObject()) {
- return FALSE;
- }
- v8::String::Utf8Value hStringVal0(
- hValue.As<v8::Object>()->Get(0)->ToString());
- utf8Name = *hStringVal0;
- v8::String::Utf8Value hStringVal1(
- hValue.As<v8::Object>()->Get(1)->ToString());
- utf8Message = *hStringVal1;
- return TRUE;
-}
-
-FX_BOOL FXJSE_ReturnValue_GetLineInfo(FXJSE_HVALUE hRetValue,
- int32_t& nLine,
- int32_t& nCol) {
- CFXJSE_Value* lpValue = reinterpret_cast<CFXJSE_Value*>(hRetValue);
- if (!lpValue) {
- return FALSE;
- }
- v8::Isolate* pIsolate = lpValue->GetIsolate();
- CFXJSE_ScopeUtil_IsolateHandleRootContext scope(pIsolate);
- v8::Local<v8::Value> hValue =
- v8::Local<v8::Value>::New(pIsolate, lpValue->DirectGetValue());
- if (!hValue->IsObject()) {
- return FALSE;
- }
- v8::MaybeLocal<v8::Int32> maybe_int =
- hValue.As<v8::Object>()->Get(3)->ToInt32(pIsolate->GetCurrentContext());
- nLine = maybe_int.FromMaybe(v8::Local<v8::Int32>())->Value();
- maybe_int =
- hValue.As<v8::Object>()->Get(5)->ToInt32(pIsolate->GetCurrentContext());
- nCol = maybe_int.FromMaybe(v8::Local<v8::Int32>())->Value();
- return TRUE;
-}
-
CFXJSE_Context* CFXJSE_Context::Create(v8::Isolate* pIsolate,
const FXJSE_CLASS* lpGlobalClass,
void* lpGlobalObject) {