summaryrefslogtreecommitdiff
path: root/xfa/fxfa/cxfa_ffbarcode.h
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2018-01-29 20:38:16 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-01-29 20:38:16 +0000
commit59cdc7dc88310bd8cdf2ace60e0f567561d38dbb (patch)
tree298be106e7d44cb418e8ee7592428fc3d94b7796 /xfa/fxfa/cxfa_ffbarcode.h
parent32d5de5948ff8a54b24d79e1f032857874b6053f (diff)
downloadpdfium-59cdc7dc88310bd8cdf2ace60e0f567561d38dbb.tar.xz
Move barcode code to CXFA_Barcode
This CL moves the barcode specific code out of CXFA_Node and into CXFA_Barcode. The CXFA_FFBarcode widget was modified to take the barcode as a parameter. Change-Id: I8ff91cb58402665f4ba63f2eeced45feeaa9ff50 Reviewed-on: https://pdfium-review.googlesource.com/24450 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Diffstat (limited to 'xfa/fxfa/cxfa_ffbarcode.h')
-rw-r--r--xfa/fxfa/cxfa_ffbarcode.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/xfa/fxfa/cxfa_ffbarcode.h b/xfa/fxfa/cxfa_ffbarcode.h
index 93984700da..df62b8ee7f 100644
--- a/xfa/fxfa/cxfa_ffbarcode.h
+++ b/xfa/fxfa/cxfa_ffbarcode.h
@@ -7,6 +7,7 @@
#ifndef XFA_FXFA_CXFA_FFBARCODE_H_
#define XFA_FXFA_CXFA_FFBARCODE_H_
+#include "core/fxcrt/unowned_ptr.h"
#include "fxbarcode/BC_Library.h"
#include "xfa/fxfa/cxfa_ffpageview.h"
#include "xfa/fxfa/cxfa_fftextedit.h"
@@ -83,11 +84,13 @@ struct BarCodeInfo {
BC_TYPE eBCType;
};
+class CXFA_Barcode;
+
class CXFA_FFBarcode : public CXFA_FFTextEdit {
public:
static const BarCodeInfo* GetBarcodeTypeByName(const WideString& wsName);
- explicit CXFA_FFBarcode(CXFA_Node* pNode);
+ explicit CXFA_FFBarcode(CXFA_Node* pNode, CXFA_Barcode* barcode);
~CXFA_FFBarcode() override;
// CXFA_FFTextEdit
@@ -98,6 +101,9 @@ class CXFA_FFBarcode : public CXFA_FFTextEdit {
void UpdateWidgetProperty() override;
bool OnLButtonDown(uint32_t dwFlags, const CFX_PointF& point) override;
bool OnRButtonDown(uint32_t dwFlags, const CFX_PointF& point) override;
+
+ private:
+ UnownedPtr<CXFA_Barcode> barcode_;
};
#endif // XFA_FXFA_CXFA_FFBARCODE_H_