Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(323)

Side by Side Diff: fpdfsdk/include/fsdk_mgr.h

Issue 1395713002: Merge to XFA: Rename IFXJS_Runtime and IFXJS_Context to IJS_. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « fpdfsdk/include/fpdfxfa/fpdfxfa_doc.h ('k') | fpdfsdk/include/javascript/IJavaScript.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 FPDFSDK_INCLUDE_FSDK_MGR_H_ 7 #ifndef FPDFSDK_INCLUDE_FSDK_MGR_H_
8 #define FPDFSDK_INCLUDE_FSDK_MGR_H_ 8 #define FPDFSDK_INCLUDE_FSDK_MGR_H_
9 9
10 #include <map> 10 #include <map>
(...skipping 437 matching lines...) Expand 10 before | Expand all | Expand 10 after
448 FX_BOOL IsJSInitiated() const { return m_pInfo && m_pInfo->m_pJsPlatform; } 448 FX_BOOL IsJSInitiated() const { return m_pInfo && m_pInfo->m_pJsPlatform; }
449 void SetSDKDocument(CPDFSDK_Document* pFXDoc) { m_pSDKDoc = pFXDoc; } 449 void SetSDKDocument(CPDFSDK_Document* pFXDoc) { m_pSDKDoc = pFXDoc; }
450 CPDFSDK_Document* GetSDKDocument() const { return m_pSDKDoc; } 450 CPDFSDK_Document* GetSDKDocument() const { return m_pSDKDoc; }
451 CPDFXFA_Document* GetPDFXFADocument() const { return m_pXFADoc; } 451 CPDFXFA_Document* GetPDFXFADocument() const { return m_pXFADoc; }
452 CFX_ByteString GetAppName() const { return ""; } 452 CFX_ByteString GetAppName() const { return ""; }
453 IFX_SystemHandler* GetSysHandler() const { return m_pSysHandler; } 453 IFX_SystemHandler* GetSysHandler() const { return m_pSysHandler; }
454 FPDF_FORMFILLINFO* GetFormFillInfo() const { return m_pInfo; } 454 FPDF_FORMFILLINFO* GetFormFillInfo() const { return m_pInfo; }
455 455
456 CFFL_IFormFiller* GetIFormFiller(); // Creates if not present. 456 CFFL_IFormFiller* GetIFormFiller(); // Creates if not present.
457 CPDFSDK_AnnotHandlerMgr* GetAnnotHandlerMgr(); // Creates if not present. 457 CPDFSDK_AnnotHandlerMgr* GetAnnotHandlerMgr(); // Creates if not present.
458 IFXJS_Runtime* GetJSRuntime(); // Creates if not present. 458 IJS_Runtime* GetJSRuntime(); // Creates if not present.
459 CPDFSDK_ActionHandler* GetActionHander(); // Creates if not present. 459 CPDFSDK_ActionHandler* GetActionHander(); // Creates if not present.
460 460
461 private: 461 private:
462 CPDFSDK_AnnotHandlerMgr* m_pAnnotHandlerMgr; 462 CPDFSDK_AnnotHandlerMgr* m_pAnnotHandlerMgr;
463 CPDFSDK_ActionHandler* m_pActionHandler; 463 CPDFSDK_ActionHandler* m_pActionHandler;
464 nonstd::unique_ptr<IFXJS_Runtime> m_pJSRuntime; 464 nonstd::unique_ptr<IJS_Runtime> m_pJSRuntime;
465 FPDF_FORMFILLINFO* const m_pInfo; 465 FPDF_FORMFILLINFO* const m_pInfo;
466 CPDFSDK_Document* m_pSDKDoc; 466 CPDFSDK_Document* m_pSDKDoc;
467 CPDFXFA_Document* const m_pXFADoc; 467 CPDFXFA_Document* const m_pXFADoc;
468 CFFL_IFormFiller* m_pIFormFiller; 468 CFFL_IFormFiller* m_pIFormFiller;
469 IFX_SystemHandler* m_pSysHandler; 469 IFX_SystemHandler* m_pSysHandler;
470 }; 470 };
471 471
472 class CPDFSDK_Document { 472 class CPDFSDK_Document {
473 public: 473 public:
474 CPDFSDK_Document(CPDFXFA_Document* pDoc, CPDFDoc_Environment* pEnv); 474 CPDFSDK_Document(CPDFXFA_Document* pDoc, CPDFDoc_Environment* pEnv);
475 ~CPDFSDK_Document(); 475 ~CPDFSDK_Document();
476 476
477 CPDFSDK_InterForm* GetInterForm(); 477 CPDFSDK_InterForm* GetInterForm();
478 CPDFXFA_Document* GetDocument() { return m_pDoc; } 478 CPDFXFA_Document* GetDocument() { return m_pDoc; }
479 479
480 int GetPageViewCount() const { return m_pageMap.size(); } 480 int GetPageViewCount() const { return m_pageMap.size(); }
481 CPDFSDK_PageView* GetPageView(CPDFXFA_Page* pPDFXFAPage, 481 CPDFSDK_PageView* GetPageView(CPDFXFA_Page* pPDFXFAPage,
482 FX_BOOL ReNew = TRUE); 482 FX_BOOL ReNew = TRUE);
483 CPDFSDK_PageView* GetPageView(int nIndex); 483 CPDFSDK_PageView* GetPageView(int nIndex);
484 CPDFSDK_PageView* GetCurrentView(); 484 CPDFSDK_PageView* GetCurrentView();
485 void ReMovePageView(CPDFXFA_Page* pPDFPage); 485 void ReMovePageView(CPDFXFA_Page* pPDFPage);
486 void UpdateAllViews(CPDFSDK_PageView* pSender, CPDFSDK_Annot* pAnnot); 486 void UpdateAllViews(CPDFSDK_PageView* pSender, CPDFSDK_Annot* pAnnot);
487 487
488 CPDFSDK_Annot* GetFocusAnnot(); 488 CPDFSDK_Annot* GetFocusAnnot();
489 489
490 IFXJS_Runtime* GetJsRuntime(); 490 IJS_Runtime* GetJsRuntime();
491 491
492 FX_BOOL SetFocusAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag = 0); 492 FX_BOOL SetFocusAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag = 0);
493 FX_BOOL KillFocusAnnot(FX_UINT nFlag = 0); 493 FX_BOOL KillFocusAnnot(FX_UINT nFlag = 0);
494 494
495 FX_BOOL ExtractPages(const CFX_WordArray& arrExtraPages, 495 FX_BOOL ExtractPages(const CFX_WordArray& arrExtraPages,
496 CPDF_Document* pDstDoc); 496 CPDF_Document* pDstDoc);
497 FX_BOOL InsertPages(int nInsertAt, 497 FX_BOOL InsertPages(int nInsertAt,
498 const CPDF_Document* pSrcDoc, 498 const CPDF_Document* pSrcDoc,
499 const CFX_WordArray& arrSrcPages); 499 const CFX_WordArray& arrSrcPages);
500 FX_BOOL DeletePages(int nStart, int nCount); 500 FX_BOOL DeletePages(int nStart, int nCount);
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
670 } 670 }
671 671
672 if (nStartPos < m) 672 if (nStartPos < m)
673 QuickSort(nStartPos, m, bAscend, pCompare); 673 QuickSort(nStartPos, m, bAscend, pCompare);
674 if (nStopPos > m) 674 if (nStopPos > m)
675 QuickSort(m, nStopPos, bAscend, pCompare); 675 QuickSort(m, nStopPos, bAscend, pCompare);
676 } 676 }
677 }; 677 };
678 678
679 #endif // FPDFSDK_INCLUDE_FSDK_MGR_H_ 679 #endif // FPDFSDK_INCLUDE_FSDK_MGR_H_
OLDNEW
« no previous file with comments | « fpdfsdk/include/fpdfxfa/fpdfxfa_doc.h ('k') | fpdfsdk/include/javascript/IJavaScript.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698