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_CFWL_WIDGET_H_ | 7 #ifndef XFA_FWL_CFWL_WIDGET_H_ |
8 #define XFA_FWL_CFWL_WIDGET_H_ | 8 #define XFA_FWL_CFWL_WIDGET_H_ |
9 #include <memory> | 9 #include <memory> |
10 | 10 |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
112 void SetFocus(bool bFocus); | 112 void SetFocus(bool bFocus); |
113 void RepaintRect(const CFX_RectF& pRect); | 113 void RepaintRect(const CFX_RectF& pRect); |
114 void Repaint(); | 114 void Repaint(); |
115 | 115 |
116 protected: | 116 protected: |
117 CFWL_Widget(const CFWL_App* app, | 117 CFWL_Widget(const CFWL_App* app, |
118 std::unique_ptr<CFWL_WidgetProperties> properties, | 118 std::unique_ptr<CFWL_WidgetProperties> properties, |
119 CFWL_Widget* pOuter); | 119 CFWL_Widget* pOuter); |
120 | 120 |
121 bool IsEnabled() const; | 121 bool IsEnabled() const; |
122 bool IsActive() const; | |
123 bool IsLocked() const { return m_iLock > 0; } | 122 bool IsLocked() const { return m_iLock > 0; } |
124 bool HasBorder() const; | 123 bool HasBorder() const; |
125 bool HasEdge() const; | 124 bool HasEdge() const; |
126 CFX_RectF GetEdgeRect(); | 125 CFX_RectF GetEdgeRect(); |
127 FX_FLOAT GetBorderSize(bool bCX); | 126 FX_FLOAT GetBorderSize(bool bCX); |
128 FX_FLOAT GetEdgeWidth(); | 127 FX_FLOAT GetEdgeWidth(); |
129 CFX_RectF GetRelativeRect(); | 128 CFX_RectF GetRelativeRect(); |
130 void* GetThemeCapacity(CFWL_WidgetCapacity dwCapacity); | 129 void* GetThemeCapacity(CFWL_WidgetCapacity dwCapacity); |
131 IFWL_ThemeProvider* GetAvailableTheme(); | 130 IFWL_ThemeProvider* GetAvailableTheme(); |
132 CFX_SizeF CalcTextSize(const CFX_WideString& wsText, | 131 CFX_SizeF CalcTextSize(const CFX_WideString& wsText, |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
189 const CFX_Matrix* pMatrix); | 188 const CFX_Matrix* pMatrix); |
190 void NotifyDriver(); | 189 void NotifyDriver(); |
191 bool IsParent(CFWL_Widget* pParent); | 190 bool IsParent(CFWL_Widget* pParent); |
192 | 191 |
193 CXFA_FFWidget* m_pLayoutItem; | 192 CXFA_FFWidget* m_pLayoutItem; |
194 uint32_t m_nEventKey; | 193 uint32_t m_nEventKey; |
195 IFWL_WidgetDelegate* m_pDelegate; // Not owned. | 194 IFWL_WidgetDelegate* m_pDelegate; // Not owned. |
196 }; | 195 }; |
197 | 196 |
198 #endif // XFA_FWL_CFWL_WIDGET_H_ | 197 #endif // XFA_FWL_CFWL_WIDGET_H_ |
OLD | NEW |