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

Side by Side Diff: xfa/fwl/lightwidget/cfwl_barcode.h

Issue 1834323003: Move xfa/include/fwl/{theme,lightwidget} to xfa/fwl (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 8 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
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 XFA_INCLUDE_FWL_LIGHTWIDGET_BARCODE_H_ 7 #ifndef XFA_FWL_LIGHTWIDGET_CFWL_BARCODE_H_
8 #define XFA_INCLUDE_FWL_LIGHTWIDGET_BARCODE_H_ 8 #define XFA_FWL_LIGHTWIDGET_CFWL_BARCODE_H_
9 9
10 #include "xfa/fwl/basewidget/ifwl_barcode.h" 10 #include "xfa/fwl/basewidget/ifwl_barcode.h"
11 #include "xfa/fwl/core/fwl_error.h" 11 #include "xfa/fwl/core/fwl_error.h"
12 #include "xfa/include/fwl/lightwidget/edit.h" 12 #include "xfa/fwl/lightwidget/cfwl_edit.h"
13 13
14 class CFWL_Widget; 14 class CFWL_Widget;
15 class CFWL_WidgetProperties; 15 class CFWL_WidgetProperties;
16 16
17 class CFWL_Barcode : public CFWL_Edit { 17 class CFWL_Barcode : public CFWL_Edit {
18 public: 18 public:
19 static CFWL_Barcode* Create(); 19 static CFWL_Barcode* Create();
20 FWL_ERR Initialize(const CFWL_WidgetProperties* pProperties = NULL); 20 FWL_ERR Initialize(const CFWL_WidgetProperties* pProperties = NULL);
21 void SetType(BC_TYPE type); 21 void SetType(BC_TYPE type);
22 FX_BOOL IsProtectedType(); 22 FX_BOOL IsProtectedType();
23 23
24 public:
25 void SetCharEncoding(BC_CHAR_ENCODING encoding) { 24 void SetCharEncoding(BC_CHAR_ENCODING encoding) {
26 m_barcodeData.m_dwAttributeMask |= FWL_BCDATTRIBUTE_CHARENCODING; 25 m_barcodeData.m_dwAttributeMask |= FWL_BCDATTRIBUTE_CHARENCODING;
27 m_barcodeData.m_eCharEncoding = encoding; 26 m_barcodeData.m_eCharEncoding = encoding;
28 } 27 }
29 void SetModuleHeight(int32_t height) { 28 void SetModuleHeight(int32_t height) {
30 m_barcodeData.m_dwAttributeMask |= FWL_BCDATTRIBUTE_MODULEHEIGHT; 29 m_barcodeData.m_dwAttributeMask |= FWL_BCDATTRIBUTE_MODULEHEIGHT;
31 m_barcodeData.m_nModuleHeight = height; 30 m_barcodeData.m_nModuleHeight = height;
32 } 31 }
33 void SetModuleWidth(int32_t width) { 32 void SetModuleWidth(int32_t width) {
34 m_barcodeData.m_dwAttributeMask |= FWL_BCDATTRIBUTE_MODULEWIDTH; 33 m_barcodeData.m_dwAttributeMask |= FWL_BCDATTRIBUTE_MODULEWIDTH;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 } 72 }
74 void SetTruncated(FX_BOOL truncated) { 73 void SetTruncated(FX_BOOL truncated) {
75 m_barcodeData.m_dwAttributeMask |= FWL_BCDATTRIBUTE_TRUNCATED; 74 m_barcodeData.m_dwAttributeMask |= FWL_BCDATTRIBUTE_TRUNCATED;
76 m_barcodeData.m_bTruncated = truncated; 75 m_barcodeData.m_bTruncated = truncated;
77 } 76 }
78 void ResetBarcodeAttributes() { m_barcodeData.m_dwAttributeMask = 0; } 77 void ResetBarcodeAttributes() { m_barcodeData.m_dwAttributeMask = 0; }
79 78
80 protected: 79 protected:
81 CFWL_Barcode(); 80 CFWL_Barcode();
82 virtual ~CFWL_Barcode(); 81 virtual ~CFWL_Barcode();
82
83 class CFWL_BarcodeDP : public IFWL_BarcodeDP { 83 class CFWL_BarcodeDP : public IFWL_BarcodeDP {
84 public: 84 public:
85 virtual FWL_ERR GetCaption(IFWL_Widget* pWidget, CFX_WideString& wsCaption); 85 virtual FWL_ERR GetCaption(IFWL_Widget* pWidget, CFX_WideString& wsCaption);
86 BC_CHAR_ENCODING m_eCharEncoding; 86 BC_CHAR_ENCODING m_eCharEncoding;
87 virtual BC_CHAR_ENCODING GetCharEncoding() { return m_eCharEncoding; } 87 virtual BC_CHAR_ENCODING GetCharEncoding() { return m_eCharEncoding; }
88 int32_t m_nModuleHeight, m_nModuleWidth; 88 int32_t m_nModuleHeight, m_nModuleWidth;
89 virtual int32_t GetModuleHeight() { return m_nModuleHeight; } 89 virtual int32_t GetModuleHeight() { return m_nModuleHeight; }
90 virtual int32_t GetModuleWidth() { return m_nModuleWidth; } 90 virtual int32_t GetModuleWidth() { return m_nModuleWidth; }
91 int32_t m_nDataLength; 91 int32_t m_nDataLength;
92 virtual int32_t GetDataLength() { return m_nDataLength; } 92 virtual int32_t GetDataLength() { return m_nDataLength; }
(...skipping 17 matching lines...) Expand all
110 virtual FX_BOOL GetTruncated() { return m_bTruncated; } 110 virtual FX_BOOL GetTruncated() { return m_bTruncated; }
111 uint32_t m_dwAttributeMask; 111 uint32_t m_dwAttributeMask;
112 virtual uint32_t GetBarcodeAttributeMask() { return m_dwAttributeMask; } 112 virtual uint32_t GetBarcodeAttributeMask() { return m_dwAttributeMask; }
113 113
114 public: 114 public:
115 CFWL_BarcodeDP() : m_dwAttributeMask(0) {} 115 CFWL_BarcodeDP() : m_dwAttributeMask(0) {}
116 }; 116 };
117 CFWL_BarcodeDP m_barcodeData; 117 CFWL_BarcodeDP m_barcodeData;
118 }; 118 };
119 119
120 #endif // XFA_INCLUDE_FWL_LIGHTWIDGET_BARCODE_H_ 120 #endif // XFA_FWL_LIGHTWIDGET_CFWL_BARCODE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698