diff options
author | dsinclair <dsinclair@chromium.org> | 2016-05-04 14:11:13 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-05-04 14:11:13 -0700 |
commit | b7675f63684ebff68c688a1c7b160596b6747c3e (patch) | |
tree | b677ff8fd5eb74ad27ffefb97681ffe92e1bb89b /xfa/fwl/core | |
parent | ef43608928148bac9b73f6919188efd87feccf95 (diff) | |
download | pdfium-b7675f63684ebff68c688a1c7b160596b6747c3e.tar.xz |
Cleanup CFWL_ThemePart data.
The m_dwData pointer was being used as a generic way to pass around data. There
were only two places we were reading that data. This Cl changes to have two
specific flags and removes the generic pointer.
Review-Url: https://codereview.chromium.org/1950973003
Diffstat (limited to 'xfa/fwl/core')
-rw-r--r-- | xfa/fwl/core/cfwl_themepart.h | 6 | ||||
-rw-r--r-- | xfa/fwl/core/fwl_formimp.cpp | 4 |
2 files changed, 6 insertions, 4 deletions
diff --git a/xfa/fwl/core/cfwl_themepart.h b/xfa/fwl/core/cfwl_themepart.h index df75a94f85..5bdf1530a5 100644 --- a/xfa/fwl/core/cfwl_themepart.h +++ b/xfa/fwl/core/cfwl_themepart.h @@ -85,7 +85,8 @@ class CFWL_ThemePart { : m_pWidget(nullptr), m_iPart(CFWL_Part::None), m_dwStates(CFWL_PartState_Normal), - m_dwData(0), + m_bMaximize(false), + m_bStaticBackground(false), m_pData(nullptr) { m_rtPart.Reset(); m_matrix.SetIdentity(); @@ -96,7 +97,8 @@ class CFWL_ThemePart { IFWL_Widget* m_pWidget; CFWL_Part m_iPart; uint32_t m_dwStates; - uint32_t m_dwData; + bool m_bMaximize; + bool m_bStaticBackground; void* m_pData; }; diff --git a/xfa/fwl/core/fwl_formimp.cpp b/xfa/fwl/core/fwl_formimp.cpp index 34663d7e0d..539a48dde0 100644 --- a/xfa/fwl/core/fwl_formimp.cpp +++ b/xfa/fwl/core/fwl_formimp.cpp @@ -330,7 +330,7 @@ FWL_ERR CFWL_FormImp::DrawWidget(CFX_Graphics* pGraphics, param.m_dwStates = CFWL_PartState_Hovered; } param.m_rtPart = m_pMaxBox->m_rtBtn; - param.m_dwData = m_bMaximized; + param.m_bMaximize = m_bMaximized; pTheme->DrawBackground(¶m); } if (m_pMinBox) { @@ -358,7 +358,7 @@ FWL_ERR CFWL_FormImp::DrawWidget(CFX_Graphics* pGraphics, param.m_iPart = CFWL_Part::MaximizeBox; param.m_dwStates = m_pMaxBox->GetPartState(); param.m_rtPart = m_pMaxBox->m_rtBtn; - param.m_dwData = m_bMaximized; + param.m_bMaximize = m_bMaximized; pTheme->DrawBackground(¶m); } if (m_pMinBox) { |