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_BASEWIDGET_FWL_PICTUREBOXIMP_H_ | 7 #ifndef XFA_FWL_BASEWIDGET_FWL_PICTUREBOXIMP_H_ |
8 #define XFA_FWL_BASEWIDGET_FWL_PICTUREBOXIMP_H_ | 8 #define XFA_FWL_BASEWIDGET_FWL_PICTUREBOXIMP_H_ |
9 | 9 |
10 #include "xfa/fwl/core/fwl_widgetimp.h" | 10 #include "xfa/fwl/core/fwl_widgetimp.h" |
(...skipping 17 matching lines...) Expand all Loading... |
28 FWL_Error GetWidgetRect(CFX_RectF& rect, FX_BOOL bAutoSize = FALSE) override; | 28 FWL_Error GetWidgetRect(CFX_RectF& rect, FX_BOOL bAutoSize = FALSE) override; |
29 FWL_Error Update() override; | 29 FWL_Error Update() override; |
30 FWL_Error DrawWidget(CFX_Graphics* pGraphics, | 30 FWL_Error DrawWidget(CFX_Graphics* pGraphics, |
31 const CFX_Matrix* pMatrix = nullptr) override; | 31 const CFX_Matrix* pMatrix = nullptr) override; |
32 | 32 |
33 protected: | 33 protected: |
34 friend class CFWL_PictureBoxImpDelegate; | 34 friend class CFWL_PictureBoxImpDelegate; |
35 | 35 |
36 void DrawBkground(CFX_Graphics* pGraphics, | 36 void DrawBkground(CFX_Graphics* pGraphics, |
37 IFWL_ThemeProvider* pTheme, | 37 IFWL_ThemeProvider* pTheme, |
38 const CFX_Matrix* pMatrix = NULL); | 38 const CFX_Matrix* pMatrix = nullptr); |
39 | 39 |
40 FX_BOOL VStyle(FX_BOOL dwStyle); | 40 FX_BOOL VStyle(FX_BOOL dwStyle); |
41 CFX_RectF m_rtClient; | 41 CFX_RectF m_rtClient; |
42 CFX_RectF m_rtImage; | 42 CFX_RectF m_rtImage; |
43 CFX_Matrix m_matrix; | 43 CFX_Matrix m_matrix; |
44 FX_BOOL m_bTop; | 44 FX_BOOL m_bTop; |
45 FX_BOOL m_bVCenter; | 45 FX_BOOL m_bVCenter; |
46 FX_BOOL m_bButton; | 46 FX_BOOL m_bButton; |
47 }; | 47 }; |
48 | 48 |
49 class CFWL_PictureBoxImpDelegate : public CFWL_WidgetImpDelegate { | 49 class CFWL_PictureBoxImpDelegate : public CFWL_WidgetImpDelegate { |
50 public: | 50 public: |
51 CFWL_PictureBoxImpDelegate(CFWL_PictureBoxImp* pOwner); | 51 CFWL_PictureBoxImpDelegate(CFWL_PictureBoxImp* pOwner); |
52 void OnDrawWidget(CFX_Graphics* pGraphics, | 52 void OnDrawWidget(CFX_Graphics* pGraphics, |
53 const CFX_Matrix* pMatrix = NULL) override; | 53 const CFX_Matrix* pMatrix = nullptr) override; |
54 | 54 |
55 protected: | 55 protected: |
56 CFWL_PictureBoxImp* m_pOwner; | 56 CFWL_PictureBoxImp* m_pOwner; |
57 }; | 57 }; |
58 | 58 |
59 #endif // XFA_FWL_BASEWIDGET_FWL_PICTUREBOXIMP_H_ | 59 #endif // XFA_FWL_BASEWIDGET_FWL_PICTUREBOXIMP_H_ |
OLD | NEW |