summaryrefslogtreecommitdiff
path: root/xfa/fwl/core/cfwl_checkbox.h
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-11-07 10:28:47 -0800
committerCommit bot <commit-bot@chromium.org>2016-11-07 10:28:47 -0800
commiteb3f68cc7f25a1e28464eb251161b8f08fcd04bc (patch)
tree36e565bac1a7760e605b181b7da4c08bda151cdd /xfa/fwl/core/cfwl_checkbox.h
parenta97fc7c6392c0adbd702bdf898cb9e20cee00a3e (diff)
downloadpdfium-eb3f68cc7f25a1e28464eb251161b8f08fcd04bc.tar.xz
Fold DataProviders into parent classes
This CL removes the data provider classes and folds the code into the parent classes. Review-Url: https://codereview.chromium.org/2480233003
Diffstat (limited to 'xfa/fwl/core/cfwl_checkbox.h')
-rw-r--r--xfa/fwl/core/cfwl_checkbox.h25
1 files changed, 9 insertions, 16 deletions
diff --git a/xfa/fwl/core/cfwl_checkbox.h b/xfa/fwl/core/cfwl_checkbox.h
index 22574b4b9c..8ab88854d8 100644
--- a/xfa/fwl/core/cfwl_checkbox.h
+++ b/xfa/fwl/core/cfwl_checkbox.h
@@ -10,7 +10,7 @@
#include "xfa/fwl/core/cfwl_widget.h"
#include "xfa/fwl/core/ifwl_checkbox.h"
-class CFWL_CheckBox : public CFWL_Widget {
+class CFWL_CheckBox : public CFWL_Widget, public IFWL_CheckBoxDP {
public:
CFWL_CheckBox(const IFWL_App*);
~CFWL_CheckBox() override;
@@ -22,23 +22,16 @@ class CFWL_CheckBox : public CFWL_Widget {
int32_t GetCheckState();
FWL_Error SetCheckState(int32_t iCheck);
- protected:
- class CFWL_CheckBoxDP : public IFWL_CheckBoxDP {
- public:
- CFWL_CheckBoxDP();
+ // IFWL_DataProvider
+ FWL_Error GetCaption(IFWL_Widget* pWidget,
+ CFX_WideString& wsCaption) override;
- // IFWL_DataProvider
- FWL_Error GetCaption(IFWL_Widget* pWidget,
- CFX_WideString& wsCaption) override;
+ // IFWL_CheckBoxDP
+ FX_FLOAT GetBoxSize(IFWL_Widget* pWidget) override;
- // IFWL_CheckBoxDP
- FX_FLOAT GetBoxSize(IFWL_Widget* pWidget) override;
-
- FX_FLOAT m_fBoxHeight;
- CFX_WideString m_wsCaption;
- };
-
- CFWL_CheckBoxDP m_checkboxData;
+ private:
+ FX_FLOAT m_fBoxHeight;
+ CFX_WideString m_wsCaption;
};
#endif // XFA_FWL_CORE_CFWL_CHECKBOX_H_