Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(300)

Side by Side Diff: fpdfsdk/include/formfiller/FFL_ComboBox.h

Issue 1279123006: Merge to XFA: Cleanup: Mark methods with the override keyword. (Closed) Base URL: https://pdfium.googlesource.com/pdfium@xfa
Patch Set: rebase Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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_FORMFILLER_FFL_COMBOBOX_H_ 7 #ifndef FPDFSDK_INCLUDE_FORMFILLER_FFL_COMBOBOX_H_
8 #define FPDFSDK_INCLUDE_FORMFILLER_FFL_COMBOBOX_H_ 8 #define FPDFSDK_INCLUDE_FORMFILLER_FFL_COMBOBOX_H_
9 9
10 #include "../../../core/include/fxcrt/fx_string.h" 10 #include "../../../core/include/fxcrt/fx_string.h"
11 #include "FFL_FormFiller.h" 11 #include "FFL_FormFiller.h"
12 12
13 class CBA_FontMap; 13 class CBA_FontMap;
14 class CPDFSDK_Document; 14 class CPDFSDK_Document;
15 15
16 struct FFL_ComboBoxState { 16 struct FFL_ComboBoxState {
17 int nIndex; 17 int nIndex;
18 int nStart; 18 int nStart;
19 int nEnd; 19 int nEnd;
20 CFX_WideString sValue; 20 CFX_WideString sValue;
21 }; 21 };
22 22
23 class CFFL_ComboBox : public CFFL_FormFiller, 23 class CFFL_ComboBox : public CFFL_FormFiller,
24 public IPWL_FocusHandler, 24 public IPWL_FocusHandler,
25 public IPWL_Edit_Notify { 25 public IPWL_Edit_Notify {
26 public: 26 public:
27 CFFL_ComboBox(CPDFDoc_Environment* pApp, CPDFSDK_Annot* pWidget); 27 CFFL_ComboBox(CPDFDoc_Environment* pApp, CPDFSDK_Annot* pWidget);
28 virtual ~CFFL_ComboBox(); 28 ~CFFL_ComboBox() override;
29 29
30 virtual PWL_CREATEPARAM GetCreateParam(); 30 // CFFL_FormFiller:
31 virtual CPWL_Wnd* NewPDFWindow(const PWL_CREATEPARAM& cp, 31 PWL_CREATEPARAM GetCreateParam() override;
32 CPDFSDK_PageView* pPageView); 32 CPWL_Wnd* NewPDFWindow(const PWL_CREATEPARAM& cp,
33 CPDFSDK_PageView* pPageView) override;
34 FX_BOOL OnChar(CPDFSDK_Annot* pAnnot, FX_UINT nChar, FX_UINT nFlags) override;
35 FX_BOOL IsDataChanged(CPDFSDK_PageView* pPageView) override;
36 void SaveData(CPDFSDK_PageView* pPageView) override;
37 void GetActionData(CPDFSDK_PageView* pPageView,
38 CPDF_AAction::AActionType type,
39 PDFSDK_FieldAction& fa) override;
40 void SetActionData(CPDFSDK_PageView* pPageView,
41 CPDF_AAction::AActionType type,
42 const PDFSDK_FieldAction& fa) override;
43 FX_BOOL IsActionDataChanged(CPDF_AAction::AActionType type,
44 const PDFSDK_FieldAction& faOld,
45 const PDFSDK_FieldAction& faNew) override;
46 void SaveState(CPDFSDK_PageView* pPageView) override;
47 void RestoreState(CPDFSDK_PageView* pPageView) override;
48 CPWL_Wnd* ResetPDFWindow(CPDFSDK_PageView* pPageView,
49 FX_BOOL bRestoreValue) override;
50 void OnKeyStroke(FX_BOOL bKeyDown, FX_DWORD nFlag) override;
33 51
34 virtual FX_BOOL OnChar(CPDFSDK_Annot* pAnnot, FX_UINT nChar, FX_UINT nFlags); 52 // IPWL_FocusHandler:
53 void OnSetFocus(CPWL_Wnd* pWnd) override;
54 void OnKillFocus(CPWL_Wnd* pWnd) override;
35 55
36 virtual FX_BOOL IsDataChanged(CPDFSDK_PageView* pPageView); 56 // IPWL_Edit_Notify:
37 virtual void SaveData(CPDFSDK_PageView* pPageView); 57 void OnAddUndo(CPWL_Edit* pEdit) override;
38
39 virtual void GetActionData(CPDFSDK_PageView* pPageView,
40 CPDF_AAction::AActionType type,
41 PDFSDK_FieldAction& fa);
42 virtual void SetActionData(CPDFSDK_PageView* pPageView,
43 CPDF_AAction::AActionType type,
44 const PDFSDK_FieldAction& fa);
45 virtual FX_BOOL IsActionDataChanged(CPDF_AAction::AActionType type,
46 const PDFSDK_FieldAction& faOld,
47 const PDFSDK_FieldAction& faNew);
48 virtual void SaveState(CPDFSDK_PageView* pPageView);
49 virtual void RestoreState(CPDFSDK_PageView* pPageView);
50
51 virtual CPWL_Wnd* ResetPDFWindow(CPDFSDK_PageView* pPageView,
52 FX_BOOL bRestoreValue);
53 virtual void OnKeyStroke(FX_BOOL bKeyDown, FX_UINT nFlag);
54 58
55 virtual FX_BOOL IsFieldFull(CPDFSDK_PageView* pPageView); 59 virtual FX_BOOL IsFieldFull(CPDFSDK_PageView* pPageView);
56 60
57 public:
58 virtual void OnSetFocus(CPWL_Wnd* pWnd);
59 virtual void OnKillFocus(CPWL_Wnd* pWnd);
60
61 public:
62 virtual void OnAddUndo(CPWL_Edit* pEdit);
63
64 public:
65 virtual FX_BOOL CanCopy(CPDFSDK_Document* pDocument);
66 virtual FX_BOOL CanCut(CPDFSDK_Document* pDocument);
67 virtual FX_BOOL CanPaste(CPDFSDK_Document* pDocument);
68
69 private: 61 private:
70 CFX_WideString GetSelectExportText(); 62 CFX_WideString GetSelectExportText();
71 63
72 private:
73 CBA_FontMap* m_pFontMap; 64 CBA_FontMap* m_pFontMap;
74 FFL_ComboBoxState m_State; 65 FFL_ComboBoxState m_State;
75 }; 66 };
76 67
77 #endif // FPDFSDK_INCLUDE_FORMFILLER_FFL_COMBOBOX_H_ 68 #endif // FPDFSDK_INCLUDE_FORMFILLER_FFL_COMBOBOX_H_
OLDNEW
« no previous file with comments | « core/src/fpdfapi/fpdf_page/fpdf_page_colors.cpp ('k') | fpdfsdk/include/formfiller/FFL_FormFiller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698