mirror of
https://pdfium.googlesource.com/pdfium
synced 2026-08-02 05:04:39 +08:00
Mass rename a common variable name to follow Google C++ style via search and replace. Lean on the compiler to find shadow variables and use "ctx" as the alternate name for those cases. Bug: 42271580 Change-Id: Ic09613ee36927023127b44f2a1fd671a59b05295 Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/137690 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
39 lines
1.1 KiB
C++
39 lines
1.1 KiB
C++
// Copyright 2018 The PDFium Authors
|
|
// 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
|
|
|
|
#ifndef FXJS_CJS_RUNTIMESTUB_H_
|
|
#define FXJS_CJS_RUNTIMESTUB_H_
|
|
|
|
#include <memory>
|
|
|
|
#include "core/fxcrt/unowned_ptr.h"
|
|
#include "core/fxcrt/widestring.h"
|
|
#include "fxjs/ijs_runtime.h"
|
|
|
|
class CPDFSDK_FormFillEnvironment;
|
|
class IJS_EventContext;
|
|
|
|
class CJS_RuntimeStub final : public IJS_Runtime {
|
|
public:
|
|
explicit CJS_RuntimeStub(CPDFSDK_FormFillEnvironment* pFormFillEnv);
|
|
~CJS_RuntimeStub() override;
|
|
|
|
// IJS_Runtime:
|
|
CJS_Runtime* AsCJSRuntime() override;
|
|
IJS_EventContext* NewEventContext() override;
|
|
void ReleaseEventContext(IJS_EventContext* context) override;
|
|
CPDFSDK_FormFillEnvironment* GetFormFillEnv() const override;
|
|
|
|
std::optional<IJS_Runtime::JS_Error> ExecuteScript(
|
|
const WideString& script) override;
|
|
|
|
private:
|
|
UnownedPtr<CPDFSDK_FormFillEnvironment> const form_fill_env_;
|
|
std::unique_ptr<IJS_EventContext> context_;
|
|
};
|
|
|
|
#endif // FXJS_CJS_RUNTIMESTUB_H_
|