You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
1.0 KiB
37 lines
1.0 KiB
// Copyright 2015 PDFium Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
// found in the LICENSE file.
|
|
|
|
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
|
|
|
|
#include "fxjs/cjs_runtimestub.h"
|
|
|
|
#include "fxjs/cjs_event_context_stub.h"
|
|
#include "third_party/base/ptr_util.h"
|
|
|
|
CJS_RuntimeStub::CJS_RuntimeStub(CPDFSDK_FormFillEnvironment* pFormFillEnv)
|
|
: m_pFormFillEnv(pFormFillEnv) {}
|
|
|
|
CJS_RuntimeStub::~CJS_RuntimeStub() = default;
|
|
|
|
IJS_EventContext* CJS_RuntimeStub::NewEventContext() {
|
|
if (!m_pContext)
|
|
m_pContext = pdfium::MakeUnique<CJS_EventContextStub>();
|
|
return m_pContext.get();
|
|
}
|
|
|
|
void CJS_RuntimeStub::ReleaseEventContext(IJS_EventContext* pContext) {}
|
|
|
|
CPDFSDK_FormFillEnvironment* CJS_RuntimeStub::GetFormFillEnv() const {
|
|
return m_pFormFillEnv.Get();
|
|
}
|
|
|
|
CJS_Runtime* CJS_RuntimeStub::AsCJSRuntime() {
|
|
return nullptr;
|
|
}
|
|
|
|
Optional<IJS_Runtime::JS_Error> CJS_RuntimeStub::ExecuteScript(
|
|
const WideString& script) {
|
|
return pdfium::nullopt;
|
|
}
|