Chromium Code Reviews| Index: fpdfsdk/include/fsdk_annothandler.h |
| diff --git a/fpdfsdk/include/fsdk_annothandler.h b/fpdfsdk/include/fsdk_annothandler.h |
| index 369a080a9b2f2134a349c6f50af04158bf9cc085..03f5fff6eed456b281863ee0abd02e1a18cac094 100644 |
| --- a/fpdfsdk/include/fsdk_annothandler.h |
| +++ b/fpdfsdk/include/fsdk_annothandler.h |
| @@ -122,7 +122,7 @@ class IPDFSDK_AnnotHandler { |
| class CPDFSDK_BFAnnotHandler : public IPDFSDK_AnnotHandler { |
| public: |
| - CPDFSDK_BFAnnotHandler(CPDFDoc_Environment* pApp) |
| + explicit CPDFSDK_BFAnnotHandler(CPDFDoc_Environment* pApp) |
| : m_pApp(pApp), m_pFormFiller(NULL) {} |
| ~CPDFSDK_BFAnnotHandler() override {} |
| @@ -303,38 +303,22 @@ class CPDFSDK_AnnotHandlerMgr { |
| CPDFDoc_Environment* m_pApp; |
| }; |
| -typedef int (*AI_COMPARE)(CPDFSDK_Annot* p1, CPDFSDK_Annot* p2); |
| - |
| class CPDFSDK_AnnotIterator { |
| public: |
| - CPDFSDK_AnnotIterator(CPDFSDK_PageView* pPageView, |
| - FX_BOOL bReverse, |
| - FX_BOOL bIgnoreTopmost = FALSE, |
|
Lei Zhang
2015/10/21 14:24:16
Never explicitly set, thus there's dead code in th
|
| - FX_BOOL bCircle = FALSE, |
| - CFX_PtrArray* pList = NULL); |
| - virtual ~CPDFSDK_AnnotIterator() {} |
| - |
| - virtual CPDFSDK_Annot* Next(const CPDFSDK_Annot* pCurrent); |
| - virtual CPDFSDK_Annot* Prev(const CPDFSDK_Annot* pCurrent); |
| - virtual CPDFSDK_Annot* Next(int& index); |
| - virtual CPDFSDK_Annot* Prev(int& index); |
| - virtual int Count() { return m_pIteratorAnnotList.GetSize(); } |
| - |
| - virtual FX_BOOL InitIteratorAnnotList(CPDFSDK_PageView* pPageView, |
| - CFX_PtrArray* pList = NULL); |
| + CPDFSDK_AnnotIterator(CPDFSDK_PageView* pPageView, bool bReverse); |
| + ~CPDFSDK_AnnotIterator(); |
| - void InsertSort(CFX_PtrArray& arrayList, AI_COMPARE pCompare); |
| + CPDFSDK_Annot* Next(int* index); |
| + CPDFSDK_Annot* Prev(int* index); |
|
Lei Zhang
2015/10/21 14:24:16
Also dead, but leaving it in for completeness.
|
| + int Count() const { return m_pIteratorAnnotList.GetSize(); } |
| protected: |
| - CPDFSDK_Annot* NextAnnot(const CPDFSDK_Annot* pCurrent); |
| - CPDFSDK_Annot* PrevAnnot(const CPDFSDK_Annot* pCurrent); |
| - CPDFSDK_Annot* NextAnnot(int& index); |
| - CPDFSDK_Annot* PrevAnnot(int& index); |
| + CPDFSDK_Annot* NextAnnot(int* index); |
| + CPDFSDK_Annot* PrevAnnot(int* index); |
| + void InsertSort(); |
| CFX_PtrArray m_pIteratorAnnotList; |
| - FX_BOOL m_bReverse; |
| - FX_BOOL m_bIgnoreTopmost; |
| - FX_BOOL m_bCircle; |
| + const bool m_bReverse; |
| }; |
| #endif // FPDFSDK_INCLUDE_FSDK_ANNOTHANDLER_H_ |