Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(376)

Side by Side Diff: xfa/fwl/core/ifwl_picturebox.h

Issue 2436103002: Remove FWL globals. (Closed)
Patch Set: Review feedback Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « xfa/fwl/core/ifwl_monthcalendar.cpp ('k') | xfa/fwl/core/ifwl_picturebox.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_PICTUREBOX_H_ 7 #ifndef XFA_FWL_CORE_IFWL_PICTUREBOX_H_
8 #define XFA_FWL_CORE_IFWL_PICTUREBOX_H_ 8 #define XFA_FWL_CORE_IFWL_PICTUREBOX_H_
9 9
10 #include "xfa/fwl/core/cfwl_widgetimpproperties.h" 10 #include "xfa/fwl/core/cfwl_widgetimpproperties.h"
(...skipping 26 matching lines...) Expand all
37 virtual CFX_DIBitmap* GetPicture(IFWL_Widget* pWidget) = 0; 37 virtual CFX_DIBitmap* GetPicture(IFWL_Widget* pWidget) = 0;
38 virtual CFX_DIBitmap* GetErrorPicture(IFWL_Widget* pWidget) = 0; 38 virtual CFX_DIBitmap* GetErrorPicture(IFWL_Widget* pWidget) = 0;
39 virtual CFX_DIBitmap* GetInitialPicture(IFWL_Widget* pWidget) = 0; 39 virtual CFX_DIBitmap* GetInitialPicture(IFWL_Widget* pWidget) = 0;
40 virtual int32_t GetOpacity(IFWL_Widget* pWidget) = 0; 40 virtual int32_t GetOpacity(IFWL_Widget* pWidget) = 0;
41 virtual int32_t GetFlipMode(IFWL_Widget* pWidget) = 0; 41 virtual int32_t GetFlipMode(IFWL_Widget* pWidget) = 0;
42 virtual FWL_Error GetMatrix(IFWL_Widget* pWidget, CFX_Matrix& matrix) = 0; 42 virtual FWL_Error GetMatrix(IFWL_Widget* pWidget, CFX_Matrix& matrix) = 0;
43 }; 43 };
44 44
45 class IFWL_PictureBox : public IFWL_Widget { 45 class IFWL_PictureBox : public IFWL_Widget {
46 public: 46 public:
47 explicit IFWL_PictureBox(const CFWL_WidgetImpProperties& properties); 47 explicit IFWL_PictureBox(const IFWL_App* app,
48 const CFWL_WidgetImpProperties& properties);
48 ~IFWL_PictureBox() override; 49 ~IFWL_PictureBox() override;
49 50
50 // IFWL_Widget 51 // IFWL_Widget
52 void Initialize() override;
53 void Finalize() override;
51 FWL_Type GetClassID() const override; 54 FWL_Type GetClassID() const override;
52 FWL_Error Initialize() override;
53 void Finalize() override;
54 FWL_Error GetWidgetRect(CFX_RectF& rect, FX_BOOL bAutoSize = FALSE) override; 55 FWL_Error GetWidgetRect(CFX_RectF& rect, FX_BOOL bAutoSize = FALSE) override;
55 FWL_Error Update() override; 56 FWL_Error Update() override;
56 FWL_Error DrawWidget(CFX_Graphics* pGraphics, 57 FWL_Error DrawWidget(CFX_Graphics* pGraphics,
57 const CFX_Matrix* pMatrix = nullptr) override; 58 const CFX_Matrix* pMatrix = nullptr) override;
58 59
59 protected: 60 protected:
60 friend class CFWL_PictureBoxImpDelegate; 61 friend class CFWL_PictureBoxImpDelegate;
61 62
62 void DrawBkground(CFX_Graphics* pGraphics, 63 void DrawBkground(CFX_Graphics* pGraphics,
63 IFWL_ThemeProvider* pTheme, 64 IFWL_ThemeProvider* pTheme,
(...skipping 12 matching lines...) Expand all
76 public: 77 public:
77 CFWL_PictureBoxImpDelegate(IFWL_PictureBox* pOwner); 78 CFWL_PictureBoxImpDelegate(IFWL_PictureBox* pOwner);
78 void OnDrawWidget(CFX_Graphics* pGraphics, 79 void OnDrawWidget(CFX_Graphics* pGraphics,
79 const CFX_Matrix* pMatrix = nullptr) override; 80 const CFX_Matrix* pMatrix = nullptr) override;
80 81
81 protected: 82 protected:
82 IFWL_PictureBox* m_pOwner; 83 IFWL_PictureBox* m_pOwner;
83 }; 84 };
84 85
85 #endif // XFA_FWL_CORE_IFWL_PICTUREBOX_H_ 86 #endif // XFA_FWL_CORE_IFWL_PICTUREBOX_H_
OLDNEW
« no previous file with comments | « xfa/fwl/core/ifwl_monthcalendar.cpp ('k') | xfa/fwl/core/ifwl_picturebox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698