summaryrefslogtreecommitdiff
path: root/xfa/fwl/lightwidget
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-05-05 10:28:02 -0700
committerCommit bot <commit-bot@chromium.org>2016-05-05 10:28:03 -0700
commitb4d40ffae3f955fab2fac838430c89aca452c45f (patch)
tree046c0a461e9dc0dc295da5839b831e4b53526541 /xfa/fwl/lightwidget
parent439bb9e0b2f72cd1ede65b84130fe9ed573f74b0 (diff)
downloadpdfium-b4d40ffae3f955fab2fac838430c89aca452c45f.tar.xz
Remove CLASSHASH defines in favour of an enum class.
This Cl updates all the CLASSHASH defines to use an enum class. A few defines where unabled and were either updated or removed if the number no longer exists in the code base. Review-Url: https://codereview.chromium.org/1946213003
Diffstat (limited to 'xfa/fwl/lightwidget')
-rw-r--r--xfa/fwl/lightwidget/cfwl_theme.cpp2
-rw-r--r--xfa/fwl/lightwidget/cfwl_theme.h2
-rw-r--r--xfa/fwl/lightwidget/cfwl_widget.cpp4
-rw-r--r--xfa/fwl/lightwidget/cfwl_widget.h3
4 files changed, 6 insertions, 5 deletions
diff --git a/xfa/fwl/lightwidget/cfwl_theme.cpp b/xfa/fwl/lightwidget/cfwl_theme.cpp
index 594dbd84a4..a070e046c1 100644
--- a/xfa/fwl/lightwidget/cfwl_theme.cpp
+++ b/xfa/fwl/lightwidget/cfwl_theme.cpp
@@ -45,7 +45,7 @@ CFWL_Theme::CFWL_Theme() {
CFWL_Theme::~CFWL_Theme() {}
-FX_BOOL CFWL_Theme::IsValidWidget(IFWL_Widget* pWidget) {
+bool CFWL_Theme::IsValidWidget(IFWL_Widget* pWidget) {
return !!GetTheme(pWidget);
}
diff --git a/xfa/fwl/lightwidget/cfwl_theme.h b/xfa/fwl/lightwidget/cfwl_theme.h
index ba20013c10..1de1fb607c 100644
--- a/xfa/fwl/lightwidget/cfwl_theme.h
+++ b/xfa/fwl/lightwidget/cfwl_theme.h
@@ -26,7 +26,7 @@ class CFWL_Theme : public IFWL_ThemeProvider {
~CFWL_Theme() override;
// IFWL_ThemeProvider:
- FX_BOOL IsValidWidget(IFWL_Widget* pWidget) override;
+ bool IsValidWidget(IFWL_Widget* pWidget) override;
uint32_t GetThemeID(IFWL_Widget* pWidget) override;
uint32_t SetThemeID(IFWL_Widget* pWidget,
uint32_t dwThemeID,
diff --git a/xfa/fwl/lightwidget/cfwl_widget.cpp b/xfa/fwl/lightwidget/cfwl_widget.cpp
index e1959797b3..8d3237605f 100644
--- a/xfa/fwl/lightwidget/cfwl_widget.cpp
+++ b/xfa/fwl/lightwidget/cfwl_widget.cpp
@@ -29,9 +29,9 @@ FWL_Error CFWL_Widget::GetClassName(CFX_WideString& wsClass) const {
return m_pIface->GetClassName(wsClass);
}
-uint32_t CFWL_Widget::GetClassID() const {
+FWL_Type CFWL_Widget::GetClassID() const {
if (!m_pIface)
- return 0;
+ return FWL_Type::Unknown;
return m_pIface->GetClassID();
}
diff --git a/xfa/fwl/lightwidget/cfwl_widget.h b/xfa/fwl/lightwidget/cfwl_widget.h
index fd30b71b4c..1c29b1f58e 100644
--- a/xfa/fwl/lightwidget/cfwl_widget.h
+++ b/xfa/fwl/lightwidget/cfwl_widget.h
@@ -20,9 +20,10 @@ class CFWL_WidgetMgr;
class CFWL_Widget {
public:
virtual ~CFWL_Widget();
+
IFWL_Widget* GetWidget();
FWL_Error GetClassName(CFX_WideString& wsClass) const;
- uint32_t GetClassID() const;
+ FWL_Type GetClassID() const;
virtual FX_BOOL IsInstance(const CFX_WideStringC& wsClass) const;
FWL_Error GetWidgetRect(CFX_RectF& rect, FX_BOOL bAutoSize = FALSE);