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 "Document.h" | 7 #include "fpdfsdk/src/javascript/Document.h" |
8 | 8 |
9 #include "Field.h" | |
10 #include "Icon.h" | |
11 #include "JS_Context.h" | |
12 #include "JS_Define.h" | |
13 #include "JS_EventHandler.h" | |
14 #include "JS_Object.h" | |
15 #include "JS_Runtime.h" | |
16 #include "JS_Value.h" | |
17 #include "app.h" | |
18 #include "fpdfsdk/include/fsdk_mgr.h" // For CPDFDoc_Environment. | 9 #include "fpdfsdk/include/fsdk_mgr.h" // For CPDFDoc_Environment. |
19 #include "fpdfsdk/include/javascript/IJavaScript.h" | 10 #include "fpdfsdk/include/javascript/IJavaScript.h" |
20 #include "resource.h" | 11 #include "fpdfsdk/src/javascript/Field.h" |
| 12 #include "fpdfsdk/src/javascript/Icon.h" |
| 13 #include "fpdfsdk/src/javascript/JS_Context.h" |
| 14 #include "fpdfsdk/src/javascript/JS_Define.h" |
| 15 #include "fpdfsdk/src/javascript/JS_EventHandler.h" |
| 16 #include "fpdfsdk/src/javascript/JS_Object.h" |
| 17 #include "fpdfsdk/src/javascript/JS_Runtime.h" |
| 18 #include "fpdfsdk/src/javascript/JS_Value.h" |
| 19 #include "fpdfsdk/src/javascript/app.h" |
| 20 #include "fpdfsdk/src/javascript/resource.h" |
21 #include "third_party/base/numerics/safe_math.h" | 21 #include "third_party/base/numerics/safe_math.h" |
22 | 22 |
23 static v8::Isolate* GetIsolate(IJS_Context* cc) { | 23 static v8::Isolate* GetIsolate(IJS_Context* cc) { |
24 CJS_Context* pContext = (CJS_Context*)cc; | 24 CJS_Context* pContext = (CJS_Context*)cc; |
25 CJS_Runtime* pRuntime = pContext->GetJSRuntime(); | 25 CJS_Runtime* pRuntime = pContext->GetJSRuntime(); |
26 return pRuntime->GetIsolate(); | 26 return pRuntime->GetIsolate(); |
27 } | 27 } |
28 | 28 |
29 BEGIN_JS_STATIC_CONST(CJS_PrintParamsObj) | 29 BEGIN_JS_STATIC_CONST(CJS_PrintParamsObj) |
30 END_JS_STATIC_CONST() | 30 END_JS_STATIC_CONST() |
(...skipping 1604 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1635 CJS_DelayData* pData = DelayDataForFieldAndControlIndex.GetAt(i); | 1635 CJS_DelayData* pData = DelayDataForFieldAndControlIndex.GetAt(i); |
1636 Field::DoDelay(m_pDocument, pData); | 1636 Field::DoDelay(m_pDocument, pData); |
1637 DelayDataForFieldAndControlIndex.SetAt(i, NULL); | 1637 DelayDataForFieldAndControlIndex.SetAt(i, NULL); |
1638 delete pData; | 1638 delete pData; |
1639 } | 1639 } |
1640 } | 1640 } |
1641 | 1641 |
1642 CJS_Document* Document::GetCJSDoc() const { | 1642 CJS_Document* Document::GetCJSDoc() const { |
1643 return static_cast<CJS_Document*>(m_pJSObject); | 1643 return static_cast<CJS_Document*>(m_pJSObject); |
1644 } | 1644 } |
OLD | NEW |