OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #ifndef FPDFSDK_INCLUDE_FSDK_BASEFORM_H_ | 7 #ifndef FPDFSDK_INCLUDE_FSDK_BASEFORM_H_ |
8 #define FPDFSDK_INCLUDE_FSDK_BASEFORM_H_ | 8 #define FPDFSDK_INCLUDE_FSDK_BASEFORM_H_ |
9 | 9 |
10 #if _FX_OS_ == _FX_ANDROID_ | 10 #if _FX_OS_ == _FX_ANDROID_ |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 CFX_WideString sChange; // in[out] | 49 CFX_WideString sChange; // in[out] |
50 CFX_WideString sChangeEx; // in | 50 CFX_WideString sChangeEx; // in |
51 FX_BOOL bKeyDown; // in | 51 FX_BOOL bKeyDown; // in |
52 int nSelEnd; // in[out] | 52 int nSelEnd; // in[out] |
53 int nSelStart; // in[out] | 53 int nSelStart; // in[out] |
54 CFX_WideString sValue; // in[out] | 54 CFX_WideString sValue; // in[out] |
55 FX_BOOL bWillCommit; // in | 55 FX_BOOL bWillCommit; // in |
56 FX_BOOL bFieldFull; // in | 56 FX_BOOL bFieldFull; // in |
57 FX_BOOL bRC; // in[out] | 57 FX_BOOL bRC; // in[out] |
58 } PDFSDK_FieldAction; | 58 } PDFSDK_FieldAction; |
| 59 |
59 class CPDFSDK_Widget : public CPDFSDK_Annot { | 60 class CPDFSDK_Widget : public CPDFSDK_Annot { |
60 public: | 61 public: |
61 CPDFSDK_Widget(CPDF_Annot* pAnnot, | 62 CPDFSDK_Widget(CPDF_Annot* pAnnot, |
62 CPDFSDK_PageView* pPageView, | 63 CPDFSDK_PageView* pPageView, |
63 CPDFSDK_InterForm* pInterForm); | 64 CPDFSDK_InterForm* pInterForm); |
64 virtual ~CPDFSDK_Widget(); | 65 ~CPDFSDK_Widget() override; |
65 | 66 |
66 virtual CFX_ByteString GetSubType() const; | 67 // CPDFSDK_Annot |
| 68 CFX_ByteString GetSubType() const override; |
| 69 CPDF_Action GetAAction(CPDF_AAction::AActionType eAAT) override; |
67 | 70 |
68 virtual CPDF_Action GetAAction(CPDF_AAction::AActionType eAAT); | 71 int GetLayoutOrder() const override { return 2; } |
69 | 72 |
| 73 // Possible values from PDF 32000-1:2008, table 221. |
| 74 // FIELDFLAG_READONLY |
| 75 // FIELDFLAG_REQUIRED |
| 76 // FIELDFLAG_NOEXPORT |
70 int GetFieldType() const; | 77 int GetFieldType() const; |
71 // define layout order to 2. | |
72 virtual int GetLayoutOrder() const { return 2; } | |
73 /* | |
74 FIELDFLAG_READONLY | |
75 FIELDFLAG_REQUIRED | |
76 FIELDFLAG_NOEXPORT | |
77 */ | |
78 | 78 |
79 int GetFieldFlags() const; | 79 int GetFieldFlags() const; |
80 int GetRotate() const; | 80 int GetRotate() const; |
81 | 81 |
82 FX_BOOL GetFillColor(FX_COLORREF& color) const; | 82 FX_BOOL GetFillColor(FX_COLORREF& color) const; |
83 FX_BOOL GetBorderColor(FX_COLORREF& color) const; | 83 FX_BOOL GetBorderColor(FX_COLORREF& color) const; |
84 FX_BOOL GetTextColor(FX_COLORREF& color) const; | 84 FX_BOOL GetTextColor(FX_COLORREF& color) const; |
85 FX_FLOAT GetFontSize() const; | 85 FX_FLOAT GetFontSize() const; |
86 | 86 |
87 int GetSelectedIndex(int nIndex) const; | 87 int GetSelectedIndex(int nIndex) const; |
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
299 static CPDF_Rect GetAnnotRect(CPDFSDK_Annot* pAnnot); | 299 static CPDF_Rect GetAnnotRect(CPDFSDK_Annot* pAnnot); |
300 | 300 |
301 CPDFSDK_PageView* m_pPageView; | 301 CPDFSDK_PageView* m_pPageView; |
302 CFX_ByteString m_sType; | 302 CFX_ByteString m_sType; |
303 CFX_ByteString m_sSubType; | 303 CFX_ByteString m_sSubType; |
304 int m_nTabs; | 304 int m_nTabs; |
305 CPDFSDK_Annots m_Annots; | 305 CPDFSDK_Annots m_Annots; |
306 }; | 306 }; |
307 | 307 |
308 #endif // FPDFSDK_INCLUDE_FSDK_BASEFORM_H_ | 308 #endif // FPDFSDK_INCLUDE_FSDK_BASEFORM_H_ |
OLD | NEW |