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

Side by Side Diff: fpdfsdk/include/pdfwindow/PWL_Edit.h

Issue 1287193005: Use override in more classes in fpdfsdk/ (Closed) Base URL: https://pdfium.googlesource.com/pdfium@master
Patch Set: nits, 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
« no previous file with comments | « fpdfsdk/include/pdfwindow/PWL_ComboBox.h ('k') | fpdfsdk/include/pdfwindow/PWL_EditCtrl.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_PDFWINDOW_PWL_EDIT_H_ 7 #ifndef FPDFSDK_INCLUDE_PDFWINDOW_PWL_EDIT_H_
8 #define FPDFSDK_INCLUDE_PDFWINDOW_PWL_EDIT_H_ 8 #define FPDFSDK_INCLUDE_PDFWINDOW_PWL_EDIT_H_
9 9
10 #include "../../../core/include/fxcrt/fx_basic.h" 10 #include "../../../core/include/fxcrt/fx_basic.h"
(...skipping 26 matching lines...) Expand all
37 FX_DWORD nFlag) = 0; 37 FX_DWORD nFlag) = 0;
38 virtual void OnAfterKeyStroke(FX_BOOL bEditOrList, 38 virtual void OnAfterKeyStroke(FX_BOOL bEditOrList,
39 void* pPrivateData, 39 void* pPrivateData,
40 FX_BOOL& bExit, 40 FX_BOOL& bExit,
41 FX_DWORD nFlag) = 0; 41 FX_DWORD nFlag) = 0;
42 }; 42 };
43 43
44 class CPWL_Edit : public CPWL_EditCtrl, public IFX_Edit_OprNotify { 44 class CPWL_Edit : public CPWL_EditCtrl, public IFX_Edit_OprNotify {
45 public: 45 public:
46 CPWL_Edit(); 46 CPWL_Edit();
47 virtual ~CPWL_Edit(); 47 ~CPWL_Edit() override;
48 48
49 public: 49 // CPWL_EditCtrl
50 virtual CFX_ByteString GetClassName() const; 50 CFX_ByteString GetClassName() const override;
51 virtual void OnDestroy(); 51 void OnDestroy() override;
52 virtual void OnCreated(); 52 void OnCreated() override;
53 virtual void RePosChildWnd(); 53 void RePosChildWnd() override;
54 virtual CPDF_Rect GetClientRect() const; 54 CPDF_Rect GetClientRect() const override;
55 void GetThisAppearanceStream(CFX_ByteTextBuf& sAppStream) override;
56 void DrawThisAppearance(CFX_RenderDevice* pDevice,
57 CPDF_Matrix* pUser2Device) override;
58 FX_BOOL OnLButtonDown(const CPDF_Point& point, FX_DWORD nFlag) override;
59 FX_BOOL OnLButtonDblClk(const CPDF_Point& point, FX_DWORD nFlag) override;
60 FX_BOOL OnRButtonUp(const CPDF_Point& point, FX_DWORD nFlag) override;
61 FX_BOOL OnMouseWheel(short zDelta,
62 const CPDF_Point& point,
63 FX_DWORD nFlag) override;
64 FX_BOOL OnKeyDown(FX_WORD nChar, FX_DWORD nFlag) override;
65 FX_BOOL OnChar(FX_WORD nChar, FX_DWORD nFlag) override;
66 CPDF_Rect GetFocusRect() const override;
67 void OnSetFocus() override;
68 void OnKillFocus() override;
55 69
56 virtual void GetThisAppearanceStream(CFX_ByteTextBuf& sAppStream);
57 virtual void DrawThisAppearance(CFX_RenderDevice* pDevice,
58 CPDF_Matrix* pUser2Device);
59
60 virtual FX_BOOL OnLButtonDown(const CPDF_Point& point, FX_DWORD nFlag);
61 virtual FX_BOOL OnLButtonDblClk(const CPDF_Point& point, FX_DWORD nFlag);
62 virtual FX_BOOL OnRButtonUp(const CPDF_Point& point, FX_DWORD nFlag);
63 virtual FX_BOOL OnMouseWheel(short zDelta,
64 const CPDF_Point& point,
65 FX_DWORD nFlag);
66
67 virtual FX_BOOL OnKeyDown(FX_WORD nChar, FX_DWORD nFlag);
68 virtual FX_BOOL OnChar(FX_WORD nChar, FX_DWORD nFlag);
69
70 virtual CPDF_Rect GetFocusRect() const;
71
72 public:
73 void SetAlignFormatH(PWL_EDIT_ALIGNFORMAT_H nFormat = PEAH_LEFT, 70 void SetAlignFormatH(PWL_EDIT_ALIGNFORMAT_H nFormat = PEAH_LEFT,
74 FX_BOOL bPaint = TRUE); // 0:left 1:right 2:middle 71 FX_BOOL bPaint = TRUE); // 0:left 1:right 2:middle
75 void SetAlignFormatV(PWL_EDIT_ALIGNFORMAT_V nFormat = PEAV_TOP, 72 void SetAlignFormatV(PWL_EDIT_ALIGNFORMAT_V nFormat = PEAV_TOP,
76 FX_BOOL bPaint = TRUE); // 0:top 1:bottom 2:center 73 FX_BOOL bPaint = TRUE); // 0:top 1:bottom 2:center
77 74
78 void SetCharArray(int32_t nCharArray); 75 void SetCharArray(int32_t nCharArray);
79 void SetLimitChar(int32_t nLimitChar); 76 void SetLimitChar(int32_t nLimitChar);
80 77
81 void SetHorzScale(int32_t nHorzScale, FX_BOOL bPaint = TRUE); 78 void SetHorzScale(int32_t nHorzScale, FX_BOOL bPaint = TRUE);
82 void SetCharSpace(FX_FLOAT fCharSpace, FX_BOOL bPaint = TRUE); 79 void SetCharSpace(FX_FLOAT fCharSpace, FX_BOOL bPaint = TRUE);
(...skipping 29 matching lines...) Expand all
112 m_pFillerNotify = pNotify; 109 m_pFillerNotify = pNotify;
113 } 110 }
114 111
115 void GeneratePageObjects(CPDF_PageObjects* pPageObjects, 112 void GeneratePageObjects(CPDF_PageObjects* pPageObjects,
116 const CPDF_Point& ptOffset, 113 const CPDF_Point& ptOffset,
117 CFX_ArrayTemplate<CPDF_TextObject*>& ObjArray); 114 CFX_ArrayTemplate<CPDF_TextObject*>& ObjArray);
118 void GeneratePageObjects(CPDF_PageObjects* pPageObjects, 115 void GeneratePageObjects(CPDF_PageObjects* pPageObjects,
119 const CPDF_Point& ptOffset); 116 const CPDF_Point& ptOffset);
120 117
121 protected: 118 protected:
122 virtual void OnSetFocus(); 119 // IFX_Edit_OprNotify
123 virtual void OnKillFocus(); 120 void OnInsertWord(const CPVT_WordPlace& place,
124 121 const CPVT_WordPlace& oldplace) override;
125 protected: 122 void OnInsertReturn(const CPVT_WordPlace& place,
126 virtual void OnInsertWord(const CPVT_WordPlace& place, 123 const CPVT_WordPlace& oldplace) override;
127 const CPVT_WordPlace& oldplace); 124 void OnBackSpace(const CPVT_WordPlace& place,
128 virtual void OnInsertReturn(const CPVT_WordPlace& place, 125 const CPVT_WordPlace& oldplace) override;
129 const CPVT_WordPlace& oldplace); 126 void OnDelete(const CPVT_WordPlace& place,
130 virtual void OnBackSpace(const CPVT_WordPlace& place, 127 const CPVT_WordPlace& oldplace) override;
131 const CPVT_WordPlace& oldplace); 128 void OnClear(const CPVT_WordPlace& place,
132 virtual void OnDelete(const CPVT_WordPlace& place, 129 const CPVT_WordPlace& oldplace) override;
133 const CPVT_WordPlace& oldplace); 130 void OnSetText(const CPVT_WordPlace& place,
134 virtual void OnClear(const CPVT_WordPlace& place, 131 const CPVT_WordPlace& oldplace) override;
135 const CPVT_WordPlace& oldplace); 132 void OnInsertText(const CPVT_WordPlace& place,
136 virtual void OnSetText(const CPVT_WordPlace& place, 133 const CPVT_WordPlace& oldplace) override;
137 const CPVT_WordPlace& oldplace); 134 void OnAddUndo(IFX_Edit_UndoItem* pUndoItem) override;
138 virtual void OnInsertText(const CPVT_WordPlace& place,
139 const CPVT_WordPlace& oldplace);
140 virtual void OnAddUndo(IFX_Edit_UndoItem* pUndoItem);
141 135
142 private: 136 private:
143 CPVT_WordRange GetSelectWordRange() const; 137 CPVT_WordRange GetSelectWordRange() const;
144 virtual void ShowVScrollBar(FX_BOOL bShow); 138 virtual void ShowVScrollBar(FX_BOOL bShow);
145 FX_BOOL IsVScrollBarVisible() const; 139 FX_BOOL IsVScrollBarVisible() const;
146 void SetParamByFlag(); 140 void SetParamByFlag();
147 141
148 FX_FLOAT GetCharArrayAutoFontSize(int32_t nCharArray); 142 FX_FLOAT GetCharArrayAutoFontSize(int32_t nCharArray);
149 CPDF_Point GetWordRightBottomPoint(const CPVT_WordPlace& wpWord); 143 CPDF_Point GetWordRightBottomPoint(const CPVT_WordPlace& wpWord);
150 144
(...skipping 16 matching lines...) Expand all
167 CPDF_Rect m_rcOldWindow; 161 CPDF_Rect m_rcOldWindow;
168 162
169 public: 163 public:
170 void AttachFFLData(void* pData) { m_pFormFiller = pData; } 164 void AttachFFLData(void* pData) { m_pFormFiller = pData; }
171 165
172 private: 166 private:
173 void* m_pFormFiller; 167 void* m_pFormFiller;
174 }; 168 };
175 169
176 #endif // FPDFSDK_INCLUDE_PDFWINDOW_PWL_EDIT_H_ 170 #endif // FPDFSDK_INCLUDE_PDFWINDOW_PWL_EDIT_H_
OLDNEW
« no previous file with comments | « fpdfsdk/include/pdfwindow/PWL_ComboBox.h ('k') | fpdfsdk/include/pdfwindow/PWL_EditCtrl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698