diff options
author | Tom Sepez <tsepez@chromium.org> | 2018-07-16 21:52:56 +0000 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2018-07-16 21:52:56 +0000 |
commit | f9d49da715deeb0efa6eaaf8ac43727ae28f8749 (patch) | |
tree | b03ec7b1168c04a3f75aa92ae2689626df3b1386 /xfa/fxfa/parser/cxfa_layoutcontext.h | |
parent | 98b356a36bc9291a4f222d092afeeea0d5b5f379 (diff) | |
download | pdfium-f9d49da715deeb0efa6eaaf8ac43727ae28f8749.tar.xz |
Use UnownedPtr/Optional in cfxa_layoutcontext.cpp
Introduce cfxa_layoutcontext.cpp to satisfy chromium style ctor check.
Fix typo in class forward declaration in cfxa_layoutcontext.h
Change-Id: I2b29bf61a21be0f895faf8984897c5655a4f0e89
Reviewed-on: https://pdfium-review.googlesource.com/37950
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
Diffstat (limited to 'xfa/fxfa/parser/cxfa_layoutcontext.h')
-rw-r--r-- | xfa/fxfa/parser/cxfa_layoutcontext.h | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/xfa/fxfa/parser/cxfa_layoutcontext.h b/xfa/fxfa/parser/cxfa_layoutcontext.h index a133ee19d9..9927d3e534 100644 --- a/xfa/fxfa/parser/cxfa_layoutcontext.h +++ b/xfa/fxfa/parser/cxfa_layoutcontext.h @@ -9,24 +9,21 @@ #include <vector> -class CXFA_ItemLayoutProcess; +#include "core/fxcrt/unowned_ptr.h" +#include "third_party/base/optional.h" + +class CXFA_ItemLayoutProcessor; class CXFA_Node; class CXFA_LayoutContext { public: - CXFA_LayoutContext() - : m_prgSpecifiedColumnWidths(nullptr), - m_fCurColumnWidth(0), - m_bCurColumnWidthAvaiable(false), - m_pOverflowProcessor(nullptr), - m_pOverflowNode(nullptr) {} - ~CXFA_LayoutContext() {} - - std::vector<float>* m_prgSpecifiedColumnWidths; - float m_fCurColumnWidth; - bool m_bCurColumnWidthAvaiable; - CXFA_ItemLayoutProcessor* m_pOverflowProcessor; - CXFA_Node* m_pOverflowNode; + CXFA_LayoutContext(); + ~CXFA_LayoutContext(); + + Optional<float> m_fCurColumnWidth; + UnownedPtr<std::vector<float>> m_prgSpecifiedColumnWidths; + UnownedPtr<CXFA_ItemLayoutProcessor> m_pOverflowProcessor; + UnownedPtr<CXFA_Node> m_pOverflowNode; }; #endif // XFA_FXFA_PARSER_CXFA_LAYOUTCONTEXT_H_ |