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

Unified Diff: xfa/fwl/core/cfwl_checkbox.h

Issue 2480233003: Fold DataProviders into parent classes (Closed)
Patch Set: Review feedback Created 4 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « xfa/fwl/core/cfwl_barcode.cpp ('k') | xfa/fwl/core/cfwl_checkbox.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fwl/core/cfwl_checkbox.h
diff --git a/xfa/fwl/core/cfwl_checkbox.h b/xfa/fwl/core/cfwl_checkbox.h
index 22574b4b9c4e9261d24c7f5dae764aeb7a535873..8ab88854d8832d9e52983462cf5a3b164aa4ccf0 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_
« no previous file with comments | « xfa/fwl/core/cfwl_barcode.cpp ('k') | xfa/fwl/core/cfwl_checkbox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698