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_CARETIMP_H_ | 7 #ifndef XFA_FWL_BASEWIDGET_FWL_CARETIMP_H_ |
8 #define XFA_FWL_BASEWIDGET_FWL_CARETIMP_H_ | 8 #define XFA_FWL_BASEWIDGET_FWL_CARETIMP_H_ |
9 | 9 |
10 #include "xfa/fwl/core/fwl_widgetimp.h" | 10 #include "xfa/fwl/core/fwl_widgetimp.h" |
(...skipping 25 matching lines...) Expand all Loading... |
36 FWL_Error SetColor(CFX_Color crFill); | 36 FWL_Error SetColor(CFX_Color crFill); |
37 | 37 |
38 protected: | 38 protected: |
39 friend class CFWL_CaretImpDelegate; | 39 friend class CFWL_CaretImpDelegate; |
40 friend class CFWL_CaretTimer; | 40 friend class CFWL_CaretTimer; |
41 | 41 |
42 class CFWL_CaretTimer : public IFWL_Timer { | 42 class CFWL_CaretTimer : public IFWL_Timer { |
43 public: | 43 public: |
44 explicit CFWL_CaretTimer(CFWL_CaretImp* pCaret); | 44 explicit CFWL_CaretTimer(CFWL_CaretImp* pCaret); |
45 ~CFWL_CaretTimer() override {} | 45 ~CFWL_CaretTimer() override {} |
46 int32_t Run(FWL_HTIMER hTimer) override; | 46 void Run(IFWL_TimerInfo* hTimer) override; |
47 CFWL_CaretImp* const m_pCaret; | 47 CFWL_CaretImp* const m_pCaret; |
48 }; | 48 }; |
49 | 49 |
50 void DrawCaretBK(CFX_Graphics* pGraphics, | 50 void DrawCaretBK(CFX_Graphics* pGraphics, |
51 IFWL_ThemeProvider* pTheme, | 51 IFWL_ThemeProvider* pTheme, |
52 const CFX_Matrix* pMatrix); | 52 const CFX_Matrix* pMatrix); |
53 | 53 |
54 CFWL_CaretTimer* m_pTimer; | 54 CFWL_CaretTimer* m_pTimer; |
55 FWL_HTIMER m_hTimer; | 55 IFWL_TimerInfo* m_pTimerInfo; |
56 uint32_t m_dwElapse; | 56 uint32_t m_dwElapse; |
57 CFX_Color m_crFill; | 57 CFX_Color m_crFill; |
58 FX_BOOL m_bSetColor; | 58 FX_BOOL m_bSetColor; |
59 }; | 59 }; |
60 | 60 |
61 class CFWL_CaretImpDelegate : public CFWL_WidgetImpDelegate { | 61 class CFWL_CaretImpDelegate : public CFWL_WidgetImpDelegate { |
62 public: | 62 public: |
63 CFWL_CaretImpDelegate(CFWL_CaretImp* pOwner); | 63 CFWL_CaretImpDelegate(CFWL_CaretImp* pOwner); |
64 void OnProcessMessage(CFWL_Message* pMessage) override; | 64 void OnProcessMessage(CFWL_Message* pMessage) override; |
65 void OnDrawWidget(CFX_Graphics* pGraphics, | 65 void OnDrawWidget(CFX_Graphics* pGraphics, |
66 const CFX_Matrix* pMatrix = NULL) override; | 66 const CFX_Matrix* pMatrix = NULL) override; |
67 | 67 |
68 protected: | 68 protected: |
69 CFWL_CaretImp* m_pOwner; | 69 CFWL_CaretImp* m_pOwner; |
70 }; | 70 }; |
71 | 71 |
72 #endif // XFA_FWL_BASEWIDGET_FWL_CARETIMP_H_ | 72 #endif // XFA_FWL_BASEWIDGET_FWL_CARETIMP_H_ |
OLD | NEW |