summaryrefslogtreecommitdiff
path: root/fpdfsdk/fsdk_actionhandler.cpp
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-10-11 12:38:01 -0700
committerCommit bot <commit-bot@chromium.org>2016-10-11 12:38:01 -0700
commit82e1767b757d96e6b81d3e42b24048a9bea387a8 (patch)
treeb7d14dfcd42ce6acf7a5552be0ff185cf0a9ed58 /fpdfsdk/fsdk_actionhandler.cpp
parent9fa95efa11f211a6faf9b2adb27211f784aee89a (diff)
downloadpdfium-82e1767b757d96e6b81d3e42b24048a9bea387a8.tar.xz
Convert IJS_Runtime to CPDFSDK_FormFillEnvironment
This CL changes the use of CPDFSDK_Document to CPDFSDK_FormFillEnvironment. Review-Url: https://codereview.chromium.org/2394313002
Diffstat (limited to 'fpdfsdk/fsdk_actionhandler.cpp')
-rw-r--r--fpdfsdk/fsdk_actionhandler.cpp11
1 files changed, 0 insertions, 11 deletions
diff --git a/fpdfsdk/fsdk_actionhandler.cpp b/fpdfsdk/fsdk_actionhandler.cpp
index f6ba4c9d9c..8a2b1fa768 100644
--- a/fpdfsdk/fsdk_actionhandler.cpp
+++ b/fpdfsdk/fsdk_actionhandler.cpp
@@ -155,8 +155,6 @@ FX_BOOL CPDFSDK_ActionHandler::ExecuteLinkAction(
CFX_WideString swJS = action.GetJavaScript();
if (!swJS.IsEmpty()) {
IJS_Runtime* pRuntime = pFormFillEnv->GetJSRuntime();
- pRuntime->SetReaderDocument(pDocument);
-
IJS_Context* pContext = pRuntime->NewContext();
pContext->OnLink_MouseUp(pFormFillEnv);
@@ -284,8 +282,6 @@ FX_BOOL CPDFSDK_ActionHandler::ExecuteScreenAction(
CFX_WideString swJS = action.GetJavaScript();
if (!swJS.IsEmpty()) {
IJS_Runtime* pRuntime = pDocument->GetJsRuntime();
- pRuntime->SetReaderDocument(pDocument);
-
IJS_Context* pContext = pRuntime->NewContext();
CFX_WideString csInfo;
FX_BOOL bRet = pContext->RunScript(swJS, &csInfo);
@@ -327,8 +323,6 @@ FX_BOOL CPDFSDK_ActionHandler::ExecuteBookMark(
CFX_WideString swJS = action.GetJavaScript();
if (!swJS.IsEmpty()) {
IJS_Runtime* pRuntime = pDocument->GetJsRuntime();
- pRuntime->SetReaderDocument(pDocument);
-
IJS_Context* pContext = pRuntime->NewContext();
pContext->OnBookmark_MouseUp(pBookmark);
@@ -478,8 +472,6 @@ void CPDFSDK_ActionHandler::RunFieldJavaScript(CPDFSDK_Document* pDocument,
ASSERT(type != CPDF_AAction::Format);
IJS_Runtime* pRuntime = pDocument->GetJsRuntime();
- pRuntime->SetReaderDocument(pDocument);
-
IJS_Context* pContext = pRuntime->NewContext();
switch (type) {
case CPDF_AAction::CursorEnter:
@@ -532,7 +524,6 @@ void CPDFSDK_ActionHandler::RunDocumentOpenJavaScript(
const CFX_WideString& sScriptName,
const CFX_WideString& script) {
IJS_Runtime* pRuntime = pDocument->GetJsRuntime();
- pRuntime->SetReaderDocument(pDocument);
IJS_Context* pContext = pRuntime->NewContext();
pContext->OnDoc_Open(pDocument->GetEnv(), sScriptName);
@@ -550,8 +541,6 @@ void CPDFSDK_ActionHandler::RunDocumentPageJavaScript(
CPDF_AAction::AActionType type,
const CFX_WideString& script) {
IJS_Runtime* pRuntime = pDocument->GetJsRuntime();
- pRuntime->SetReaderDocument(pDocument);
-
IJS_Context* pContext = pRuntime->NewContext();
switch (type) {
case CPDF_AAction::OpenPage: