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_CORE_IFWL_WIDGET_H_ | 7 #ifndef XFA_FWL_CORE_IFWL_WIDGET_H_ |
8 #define XFA_FWL_CORE_IFWL_WIDGET_H_ | 8 #define XFA_FWL_CORE_IFWL_WIDGET_H_ |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
104 if (IsLocked()) | 104 if (IsLocked()) |
105 m_iLock--; | 105 m_iLock--; |
106 } | 106 } |
107 | 107 |
108 void TransformTo(IFWL_Widget* pWidget, FX_FLOAT& fx, FX_FLOAT& fy); | 108 void TransformTo(IFWL_Widget* pWidget, FX_FLOAT& fx, FX_FLOAT& fy); |
109 void GetMatrix(CFX_Matrix& matrix, bool bGlobal = false); | 109 void GetMatrix(CFX_Matrix& matrix, bool bGlobal = false); |
110 IFWL_ThemeProvider* GetThemeProvider() const { | 110 IFWL_ThemeProvider* GetThemeProvider() const { |
111 return m_pProperties->m_pThemeProvider; | 111 return m_pProperties->m_pThemeProvider; |
112 } | 112 } |
113 | 113 |
| 114 IFWL_DataProvider* GetDataProvider() const { |
| 115 return m_pProperties->m_pDataProvider; |
| 116 } |
| 117 |
114 void SetDelegate(IFWL_WidgetDelegate* delegate) { m_pDelegate = delegate; } | 118 void SetDelegate(IFWL_WidgetDelegate* delegate) { m_pDelegate = delegate; } |
115 IFWL_WidgetDelegate* GetDelegate() { | 119 IFWL_WidgetDelegate* GetDelegate() { |
116 return m_pDelegate ? m_pDelegate : this; | 120 return m_pDelegate ? m_pDelegate : this; |
117 } | 121 } |
118 const IFWL_WidgetDelegate* GetDelegate() const { | 122 const IFWL_WidgetDelegate* GetDelegate() const { |
119 return m_pDelegate ? m_pDelegate : this; | 123 return m_pDelegate ? m_pDelegate : this; |
120 } | 124 } |
121 | 125 |
122 const IFWL_App* GetOwnerApp() const { return m_pOwnerApp; } | 126 const IFWL_App* GetOwnerApp() const { return m_pOwnerApp; } |
123 uint32_t GetEventKey() const { return m_nEventKey; } | 127 uint32_t GetEventKey() const { return m_nEventKey; } |
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
232 void NotifyDriver(); | 236 void NotifyDriver(); |
233 bool IsParent(IFWL_Widget* pParent); | 237 bool IsParent(IFWL_Widget* pParent); |
234 | 238 |
235 void* m_pLayoutItem; | 239 void* m_pLayoutItem; |
236 CFWL_Widget* m_pAssociate; | 240 CFWL_Widget* m_pAssociate; |
237 uint32_t m_nEventKey; | 241 uint32_t m_nEventKey; |
238 IFWL_WidgetDelegate* m_pDelegate; // Not owned. | 242 IFWL_WidgetDelegate* m_pDelegate; // Not owned. |
239 }; | 243 }; |
240 | 244 |
241 #endif // XFA_FWL_CORE_IFWL_WIDGET_H_ | 245 #endif // XFA_FWL_CORE_IFWL_WIDGET_H_ |
OLD | NEW |