OLD | NEW |
1 // Copyright 2016 PDFium Authors. All rights reserved. | 1 // Copyright 2016 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 "fpdfsdk/include/cpdfsdk_xfawidgethandler.h" | 7 #include "fpdfsdk/include/cpdfsdk_xfawidgethandler.h" |
8 | 8 |
9 #include "core/fpdfdoc/include/cpdf_interform.h" | 9 #include "core/fpdfdoc/include/cpdf_interform.h" |
10 #include "fpdfsdk/fpdfxfa/include/fpdfxfa_doc.h" | 10 #include "fpdfsdk/fpdfxfa/include/fpdfxfa_doc.h" |
11 #include "fpdfsdk/include/cpdfdoc_environment.h" | |
12 #include "fpdfsdk/include/cpdfsdk_annot.h" | 11 #include "fpdfsdk/include/cpdfsdk_annot.h" |
13 #include "fpdfsdk/include/cpdfsdk_document.h" | 12 #include "fpdfsdk/include/cpdfsdk_document.h" |
| 13 #include "fpdfsdk/include/cpdfsdk_environment.h" |
14 #include "fpdfsdk/include/cpdfsdk_interform.h" | 14 #include "fpdfsdk/include/cpdfsdk_interform.h" |
15 #include "fpdfsdk/include/cpdfsdk_pageview.h" | 15 #include "fpdfsdk/include/cpdfsdk_pageview.h" |
16 #include "fpdfsdk/include/cpdfsdk_xfawidget.h" | 16 #include "fpdfsdk/include/cpdfsdk_xfawidget.h" |
17 #include "xfa/fwl/core/include/fwl_widgethit.h" | 17 #include "xfa/fwl/core/include/fwl_widgethit.h" |
18 #include "xfa/fxfa/include/fxfa_basic.h" | 18 #include "xfa/fxfa/include/fxfa_basic.h" |
19 #include "xfa/fxfa/include/xfa_ffdocview.h" | 19 #include "xfa/fxfa/include/xfa_ffdocview.h" |
20 #include "xfa/fxfa/include/xfa_ffpageview.h" | 20 #include "xfa/fxfa/include/xfa_ffpageview.h" |
21 #include "xfa/fxfa/include/xfa_ffwidget.h" | 21 #include "xfa/fxfa/include/xfa_ffwidget.h" |
22 #include "xfa/fxfa/include/xfa_ffwidgethandler.h" | 22 #include "xfa/fxfa/include/xfa_ffwidgethandler.h" |
23 #include "xfa/fxgraphics/include/cfx_graphics.h" | 23 #include "xfa/fxgraphics/include/cfx_graphics.h" |
24 | 24 |
25 CPDFSDK_XFAWidgetHandler::CPDFSDK_XFAWidgetHandler(CPDFDoc_Environment* pApp) | 25 CPDFSDK_XFAWidgetHandler::CPDFSDK_XFAWidgetHandler(CPDFSDK_Environment* pApp) |
26 : m_pApp(pApp) {} | 26 : m_pApp(pApp) {} |
27 | 27 |
28 CPDFSDK_XFAWidgetHandler::~CPDFSDK_XFAWidgetHandler() {} | 28 CPDFSDK_XFAWidgetHandler::~CPDFSDK_XFAWidgetHandler() {} |
29 | 29 |
30 FX_BOOL CPDFSDK_XFAWidgetHandler::CanAnswer(CPDFSDK_Annot* pAnnot) { | 30 FX_BOOL CPDFSDK_XFAWidgetHandler::CanAnswer(CPDFSDK_Annot* pAnnot) { |
31 return !!pAnnot->GetXFAWidget(); | 31 return !!pAnnot->GetXFAWidget(); |
32 } | 32 } |
33 | 33 |
34 CPDFSDK_Annot* CPDFSDK_XFAWidgetHandler::NewAnnot(CPDF_Annot* pAnnot, | 34 CPDFSDK_Annot* CPDFSDK_XFAWidgetHandler::NewAnnot(CPDF_Annot* pAnnot, |
35 CPDFSDK_PageView* pPage) { | 35 CPDFSDK_PageView* pPage) { |
(...skipping 332 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
368 dwFWLFlag |= FWL_KEYFLAG_MButton; | 368 dwFWLFlag |= FWL_KEYFLAG_MButton; |
369 if (dwFlag & FWL_EVENTFLAG_RightButtonDown) | 369 if (dwFlag & FWL_EVENTFLAG_RightButtonDown) |
370 dwFWLFlag |= FWL_KEYFLAG_RButton; | 370 dwFWLFlag |= FWL_KEYFLAG_RButton; |
371 if (dwFlag & FWL_EVENTFLAG_ShiftKey) | 371 if (dwFlag & FWL_EVENTFLAG_ShiftKey) |
372 dwFWLFlag |= FWL_KEYFLAG_Shift; | 372 dwFWLFlag |= FWL_KEYFLAG_Shift; |
373 if (dwFlag & FWL_EVENTFLAG_AltKey) | 373 if (dwFlag & FWL_EVENTFLAG_AltKey) |
374 dwFWLFlag |= FWL_KEYFLAG_Alt; | 374 dwFWLFlag |= FWL_KEYFLAG_Alt; |
375 | 375 |
376 return dwFWLFlag; | 376 return dwFWLFlag; |
377 } | 377 } |
OLD | NEW |