• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright 2017 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 
7 #ifndef FXJS_XFA_CJX_HOSTPSEUDOMODEL_H_
8 #define FXJS_XFA_CJX_HOSTPSEUDOMODEL_H_
9 
10 #include "fxjs/xfa/cjx_object.h"
11 #include "fxjs/xfa/jse_define.h"
12 #include "xfa/fxfa/fxfa_basic.h"
13 
14 class CFXJSE_Value;
15 class CScript_HostPseudoModel;
16 
17 class CJX_HostPseudoModel final : public CJX_Object {
18  public:
19   explicit CJX_HostPseudoModel(CScript_HostPseudoModel* model);
20   ~CJX_HostPseudoModel() override;
21 
22   // CJX_Object:
23   bool DynamicTypeIs(TypeTag eType) const override;
24 
25   JSE_METHOD(beep);
26   JSE_METHOD(documentCountInBatch);
27   JSE_METHOD(documentInBatch);
28   JSE_METHOD(exportData);
29   JSE_METHOD(getFocus);
30   JSE_METHOD(gotoURL);
31   JSE_METHOD(importData);
32   JSE_METHOD(messageBox);
33   JSE_METHOD(openList);
34   JSE_METHOD(pageDown);
35   JSE_METHOD(pageUp);
36   JSE_METHOD(print);
37   JSE_METHOD(resetData);
38   JSE_METHOD(response);
39   JSE_METHOD(setFocus);
40 
41   JSE_PROP(appType);
42   JSE_PROP(calculationsEnabled);
43   JSE_PROP(currentPage);
44   JSE_PROP(language);
45   JSE_PROP(numPages);
46   JSE_PROP(platform);
47   JSE_PROP(title);
48   JSE_PROP(validationsEnabled);
49   JSE_PROP(variation);
50   JSE_PROP(version);
51 
52   // TODO(dsinclair): Remove when xfa_basic_data_element_script is removed.
53   // Doesn't exist in spec
54   JSE_PROP(name);
55 
56  private:
57   using Type__ = CJX_HostPseudoModel;
58   using ParentType__ = CJX_Object;
59 
60   static const TypeTag static_type__ = TypeTag::HostPseudoModel;
61   static const CJX_MethodSpec MethodSpecs[];
62 };
63 
64 #endif  // FXJS_XFA_CJX_HOSTPSEUDOMODEL_H_
65