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 #include "xfa/fxfa/app/xfa_ffimageedit.h" | 7 #include "xfa/fxfa/app/xfa_ffimageedit.h" |
8 | 8 |
9 #include "xfa/fwl/core/cfwl_message.h" | 9 #include "xfa/fwl/core/cfwl_message.h" |
10 #include "xfa/fwl/core/fwl_noteimp.h" | 10 #include "xfa/fwl/core/fwl_noteimp.h" |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
90 | 90 |
91 if (!PtInActiveRect(fx, fy)) | 91 if (!PtInActiveRect(fx, fy)) |
92 return FALSE; | 92 return FALSE; |
93 | 93 |
94 SetButtonDown(TRUE); | 94 SetButtonDown(TRUE); |
95 CFWL_MsgMouse ms; | 95 CFWL_MsgMouse ms; |
96 ms.m_dwCmd = FWL_MouseCommand::LeftButtonDown; | 96 ms.m_dwCmd = FWL_MouseCommand::LeftButtonDown; |
97 ms.m_dwFlags = dwFlags; | 97 ms.m_dwFlags = dwFlags; |
98 ms.m_fx = fx; | 98 ms.m_fx = fx; |
99 ms.m_fy = fy; | 99 ms.m_fy = fy; |
100 ms.m_pDstTarget = m_pNormalWidget->m_pIface; | 100 ms.m_pDstTarget = m_pNormalWidget->GetWidget(); |
101 FWLToClient(ms.m_fx, ms.m_fy); | 101 FWLToClient(ms.m_fx, ms.m_fy); |
102 TranslateFWLMessage(&ms); | 102 TranslateFWLMessage(&ms); |
103 return TRUE; | 103 return TRUE; |
104 } | 104 } |
105 | 105 |
106 void CXFA_FFImageEdit::SetFWLRect() { | 106 void CXFA_FFImageEdit::SetFWLRect() { |
107 if (!m_pNormalWidget) { | 107 if (!m_pNormalWidget) { |
108 return; | 108 return; |
109 } | 109 } |
110 CFX_RectF rtUIMargin; | 110 CFX_RectF rtUIMargin; |
(...skipping 18 matching lines...) Expand all Loading... |
129 | 129 |
130 void CXFA_FFImageEdit::OnProcessEvent(CFWL_Event* pEvent) { | 130 void CXFA_FFImageEdit::OnProcessEvent(CFWL_Event* pEvent) { |
131 CXFA_FFField::OnProcessEvent(pEvent); | 131 CXFA_FFField::OnProcessEvent(pEvent); |
132 m_pOldDelegate->OnProcessEvent(pEvent); | 132 m_pOldDelegate->OnProcessEvent(pEvent); |
133 } | 133 } |
134 | 134 |
135 void CXFA_FFImageEdit::OnDrawWidget(CFX_Graphics* pGraphics, | 135 void CXFA_FFImageEdit::OnDrawWidget(CFX_Graphics* pGraphics, |
136 const CFX_Matrix* pMatrix) { | 136 const CFX_Matrix* pMatrix) { |
137 m_pOldDelegate->OnDrawWidget(pGraphics, pMatrix); | 137 m_pOldDelegate->OnDrawWidget(pGraphics, pMatrix); |
138 } | 138 } |
OLD | NEW |