| 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_FWL_CORE_IFWL_CHECKBOX_H_ | 7 #ifndef XFA_FWL_CORE_IFWL_CHECKBOX_H_ | 
| 8 #define XFA_FWL_CORE_IFWL_CHECKBOX_H_ | 8 #define XFA_FWL_CORE_IFWL_CHECKBOX_H_ | 
| 9 | 9 | 
| 10 #include "xfa/fwl/core/cfwl_event.h" | 10 #include "xfa/fwl/core/cfwl_event.h" | 
| 11 #include "xfa/fwl/core/cfwl_widgetproperties.h" | 11 #include "xfa/fwl/core/cfwl_widgetproperties.h" | 
| 12 #include "xfa/fwl/core/ifwl_dataprovider.h" |  | 
| 13 #include "xfa/fwl/core/ifwl_widget.h" | 12 #include "xfa/fwl/core/ifwl_widget.h" | 
| 14 | 13 | 
| 15 #define FWL_STYLEEXT_CKB_Left (0L << 0) | 14 #define FWL_STYLEEXT_CKB_Left (0L << 0) | 
| 16 #define FWL_STYLEEXT_CKB_Center (1L << 0) | 15 #define FWL_STYLEEXT_CKB_Center (1L << 0) | 
| 17 #define FWL_STYLEEXT_CKB_Right (2L << 0) | 16 #define FWL_STYLEEXT_CKB_Right (2L << 0) | 
| 18 #define FWL_STYLEEXT_CKB_Top (0L << 2) | 17 #define FWL_STYLEEXT_CKB_Top (0L << 2) | 
| 19 #define FWL_STYLEEXT_CKB_VCenter (1L << 2) | 18 #define FWL_STYLEEXT_CKB_VCenter (1L << 2) | 
| 20 #define FWL_STYLEEXT_CKB_Bottom (2L << 2) | 19 #define FWL_STYLEEXT_CKB_Bottom (2L << 2) | 
| 21 #define FWL_STYLEEXT_CKB_LeftText (1L << 4) | 20 #define FWL_STYLEEXT_CKB_LeftText (1L << 4) | 
| 22 #define FWL_STYLEEXT_CKB_MultiLine (1L << 5) | 21 #define FWL_STYLEEXT_CKB_MultiLine (1L << 5) | 
| (...skipping 17 matching lines...) Expand all  Loading... | 
| 40 #define FWL_STATE_CKB_Pressed (1 << (FWL_WGTSTATE_MAX + 1)) | 39 #define FWL_STATE_CKB_Pressed (1 << (FWL_WGTSTATE_MAX + 1)) | 
| 41 #define FWL_STATE_CKB_Unchecked (0 << (FWL_WGTSTATE_MAX + 2)) | 40 #define FWL_STATE_CKB_Unchecked (0 << (FWL_WGTSTATE_MAX + 2)) | 
| 42 #define FWL_STATE_CKB_Checked (1 << (FWL_WGTSTATE_MAX + 2)) | 41 #define FWL_STATE_CKB_Checked (1 << (FWL_WGTSTATE_MAX + 2)) | 
| 43 #define FWL_STATE_CKB_Neutral (2 << (FWL_WGTSTATE_MAX + 2)) | 42 #define FWL_STATE_CKB_Neutral (2 << (FWL_WGTSTATE_MAX + 2)) | 
| 44 #define FWL_STATE_CKB_CheckMask (3L << (FWL_WGTSTATE_MAX + 2)) | 43 #define FWL_STATE_CKB_CheckMask (3L << (FWL_WGTSTATE_MAX + 2)) | 
| 45 | 44 | 
| 46 class CFWL_MsgMouse; | 45 class CFWL_MsgMouse; | 
| 47 class CFWL_WidgetProperties; | 46 class CFWL_WidgetProperties; | 
| 48 class IFWL_Widget; | 47 class IFWL_Widget; | 
| 49 | 48 | 
| 50 class IFWL_CheckBoxDP : public IFWL_DataProvider { | 49 class IFWL_CheckBoxDP : public IFWL_Widget::DataProvider { | 
| 51  public: | 50  public: | 
| 52   virtual FX_FLOAT GetBoxSize(IFWL_Widget* pWidget) = 0; | 51   virtual FX_FLOAT GetBoxSize(IFWL_Widget* pWidget) = 0; | 
| 53 }; | 52 }; | 
| 54 | 53 | 
| 55 class IFWL_CheckBox : public IFWL_Widget { | 54 class IFWL_CheckBox : public IFWL_Widget { | 
| 56  public: | 55  public: | 
| 57   IFWL_CheckBox(const IFWL_App* app, | 56   IFWL_CheckBox(const IFWL_App* app, | 
| 58                 std::unique_ptr<CFWL_WidgetProperties> properties); | 57                 std::unique_ptr<CFWL_WidgetProperties> properties); | 
| 59   ~IFWL_CheckBox() override; | 58   ~IFWL_CheckBox() override; | 
| 60 | 59 | 
| (...skipping 24 matching lines...) Expand all  Loading... | 
| 85   CFX_RectF m_rtClient; | 84   CFX_RectF m_rtClient; | 
| 86   CFX_RectF m_rtBox; | 85   CFX_RectF m_rtBox; | 
| 87   CFX_RectF m_rtCaption; | 86   CFX_RectF m_rtCaption; | 
| 88   CFX_RectF m_rtFocus; | 87   CFX_RectF m_rtFocus; | 
| 89   uint32_t m_dwTTOStyles; | 88   uint32_t m_dwTTOStyles; | 
| 90   int32_t m_iTTOAlign; | 89   int32_t m_iTTOAlign; | 
| 91   bool m_bBtnDown; | 90   bool m_bBtnDown; | 
| 92 }; | 91 }; | 
| 93 | 92 | 
| 94 #endif  // XFA_FWL_CORE_IFWL_CHECKBOX_H_ | 93 #endif  // XFA_FWL_CORE_IFWL_CHECKBOX_H_ | 
| OLD | NEW | 
|---|