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 XFA_FDE_FDE_ITERATOR_H_ | 7 #ifndef XFA_FDE_FDE_ITERATOR_H_ |
8 #define XFA_FDE_FDE_ITERATOR_H_ | 8 #define XFA_FDE_FDE_ITERATOR_H_ |
9 | 9 |
10 #include "xfa/fde/fde_visualset.h" | 10 #include "xfa/fde/fde_visualset.h" |
11 #include "xfa/fgas/crt/fgas_memory.h" | 11 #include "xfa/fgas/crt/fgas_memory.h" |
12 #include "xfa/fgas/crt/fgas_utils.h" | 12 #include "xfa/fgas/crt/fgas_utils.h" |
13 | 13 |
14 struct FDE_CANVASITEM { | 14 struct FDE_CANVASITEM { |
15 IFDE_CanvasSet* pCanvas; | 15 IFDE_CanvasSet* pCanvas; |
16 FDE_TEXTEDITPIECE* hCanvas; | 16 FDE_TEXTEDITPIECE* hCanvas; |
17 FX_POSITION hPos; | 17 FX_POSITION hPos; |
18 }; | 18 }; |
19 | 19 |
20 class CFDE_VisualSetIterator : public CFX_Target { | 20 class CFDE_VisualSetIterator : public CFX_Target { |
21 public: | 21 public: |
22 CFDE_VisualSetIterator(); | 22 CFDE_VisualSetIterator(); |
23 ~CFDE_VisualSetIterator() override; | 23 ~CFDE_VisualSetIterator() override; |
24 | 24 |
25 FX_BOOL AttachCanvas(IFDE_CanvasSet* pCanvas); | 25 bool AttachCanvas(IFDE_CanvasSet* pCanvas); |
26 FX_BOOL FilterObjects(uint32_t dwObjects = 0xFFFFFFFF); | 26 bool FilterObjects(uint32_t dwObjects = 0xFFFFFFFF); |
27 | 27 |
28 void Reset(); | 28 void Reset(); |
29 FDE_TEXTEDITPIECE* GetNext(IFDE_VisualSet*& pVisualSet, | 29 FDE_TEXTEDITPIECE* GetNext(IFDE_VisualSet*& pVisualSet, |
30 FDE_TEXTEDITPIECE** phCanvasObj = nullptr, | 30 FDE_TEXTEDITPIECE** phCanvasObj = nullptr, |
31 IFDE_CanvasSet** ppCanvasSet = nullptr); | 31 IFDE_CanvasSet** ppCanvasSet = nullptr); |
32 | 32 |
33 protected: | 33 protected: |
34 uint32_t m_dwFilter; | 34 uint32_t m_dwFilter; |
35 CFX_StackTemplate<FDE_CANVASITEM> m_CanvasStack; | 35 CFX_StackTemplate<FDE_CANVASITEM> m_CanvasStack; |
36 }; | 36 }; |
37 | 37 |
38 #endif // XFA_FDE_FDE_ITERATOR_H_ | 38 #endif // XFA_FDE_FDE_ITERATOR_H_ |
OLD | NEW |