summaryrefslogtreecommitdiff
path: root/xfa/fwl/core/fwl_widgetimp.h
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-04-28 10:51:13 -0700
committerCommit bot <commit-bot@chromium.org>2016-04-28 10:51:13 -0700
commit7322343b9322b93d97077575f95a00dcca3f0451 (patch)
tree36337e0a2aff2147a9067477f982496129f0f7a1 /xfa/fwl/core/fwl_widgetimp.h
parente6ebf7af7ea94d48091be300cec84b499d3b8ae0 (diff)
downloadpdfium-7322343b9322b93d97077575f95a00dcca3f0451.tar.xz
More FWL interface cleanup.
This CL merges the IFWL_Target class into IFWL_Widget and IFWL_Thread into IFWL_App. The IFWL_WidgetMgrDelegate, IFWL_NoteDriver and IFWL_NotThread are removed in favour of their concrete classes. Review-Url: https://codereview.chromium.org/1921853006
Diffstat (limited to 'xfa/fwl/core/fwl_widgetimp.h')
-rw-r--r--xfa/fwl/core/fwl_widgetimp.h24
1 files changed, 14 insertions, 10 deletions
diff --git a/xfa/fwl/core/fwl_widgetimp.h b/xfa/fwl/core/fwl_widgetimp.h
index 2e5e761512..9381a4203d 100644
--- a/xfa/fwl/core/fwl_widgetimp.h
+++ b/xfa/fwl/core/fwl_widgetimp.h
@@ -11,23 +11,27 @@
#include "core/fxcrt/include/fx_system.h"
#include "xfa/fwl/core/cfwl_event.h"
#include "xfa/fwl/core/cfwl_themepart.h"
-#include "xfa/fwl/core/fwl_targetimp.h"
#include "xfa/fwl/core/ifwl_widgetdelegate.h"
#include "xfa/fwl/theme/cfwl_widgettp.h"
+class CFWL_AppImp;
class CFWL_MsgKey;
-class CFWL_ThreadImp;
class CFWL_WidgetImpProperties;
class CFWL_WidgetMgr;
+class IFWL_App;
class IFWL_DataProvider;
-class IFWL_Thread;
class IFWL_ThemeProvider;
class IFWL_Widget;
-class CFWL_WidgetImp : public CFWL_TargetImp {
+class CFWL_WidgetImp {
public:
+ virtual ~CFWL_WidgetImp();
+
virtual FWL_ERR Initialize();
virtual FWL_ERR Finalize();
+ virtual FWL_ERR GetClassName(CFX_WideString& wsClass) const;
+ virtual uint32_t GetClassID() const;
+ virtual FX_BOOL IsInstance(const CFX_WideStringC& wsClass) const;
virtual FWL_ERR GetWidgetRect(CFX_RectF& rect, FX_BOOL bAutoSize = FALSE);
virtual FWL_ERR GetGlobalRect(CFX_RectF& rect);
@@ -64,16 +68,18 @@ class CFWL_WidgetImp : public CFWL_TargetImp {
virtual FWL_ERR SetThemeProvider(IFWL_ThemeProvider* pThemeProvider);
virtual FWL_ERR SetDataProvider(IFWL_DataProvider* pDataProvider);
virtual IFWL_WidgetDelegate* SetDelegate(IFWL_WidgetDelegate* pDelegate);
- virtual IFWL_Thread* GetOwnerThread() const;
- FWL_ERR SetOwnerThread(CFWL_ThreadImp* pOwnerThread);
+ virtual IFWL_App* GetOwnerApp() const;
+ FWL_ERR SetOwnerApp(CFWL_AppImp* pOwnerApp);
IFWL_Widget* GetInterface() const;
void SetInterface(IFWL_Widget* pInterface);
CFX_SizeF GetOffsetFromParent(IFWL_Widget* pParent);
protected:
+ friend class CFWL_WidgetImpDelegate;
+
CFWL_WidgetImp(const CFWL_WidgetImpProperties& properties,
IFWL_Widget* pOuter);
- virtual ~CFWL_WidgetImp();
+
FX_BOOL IsEnabled() const;
FX_BOOL IsVisible() const;
FX_BOOL IsActive() const;
@@ -141,10 +147,8 @@ class CFWL_WidgetImp : public CFWL_TargetImp {
FX_BOOL IsParent(IFWL_Widget* pParent);
- friend class CFWL_WidgetImpDelegate;
-
CFWL_WidgetMgr* m_pWidgetMgr;
- CFWL_ThreadImp* m_pOwnerThread;
+ CFWL_AppImp* m_pOwnerApp;
CFWL_WidgetImpProperties* m_pProperties;
CFX_PrivateData* m_pPrivateData;
IFWL_WidgetDelegate* m_pDelegate;