| OLD | NEW | 
|---|
| 1 // Copyright (c) 2015 PDFium Authors. All rights reserved. | 1 // Copyright (c) 2015 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 #ifndef TESTING_EMBEDDER_TEST_H_ | 5 #ifndef TESTING_EMBEDDER_TEST_H_ | 
| 6 #define TESTING_EMBEDDER_TEST_H_ | 6 #define TESTING_EMBEDDER_TEST_H_ | 
| 7 | 7 | 
| 8 #include <map> | 8 #include <map> | 
| 9 #include <string> | 9 #include <string> | 
| 10 | 10 | 
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 75     delegate_ = delegate ? delegate : default_delegate_.get(); | 75     delegate_ = delegate ? delegate : default_delegate_.get(); | 
| 76   } | 76   } | 
| 77 | 77 | 
| 78   FPDF_DOCUMENT document() { return document_; } | 78   FPDF_DOCUMENT document() { return document_; } | 
| 79   FPDF_FORMHANDLE form_handle() { return form_handle_; } | 79   FPDF_FORMHANDLE form_handle() { return form_handle_; } | 
| 80 | 80 | 
| 81   // Open the document specified by |filename|, and create its form fill | 81   // Open the document specified by |filename|, and create its form fill | 
| 82   // environment, or return false on failure. | 82   // environment, or return false on failure. | 
| 83   // The filename is relative to the test data directory where we store all the | 83   // The filename is relative to the test data directory where we store all the | 
| 84   // test files. | 84   // test files. | 
| 85   virtual bool OpenDocument(const std::string& filename); | 85   virtual bool OpenDocument(const std::string& filename, | 
|  | 86                             bool must_linearize = false); | 
| 86 | 87 | 
| 87   // Perform JavaScript actions that are to run at document open time. | 88   // Perform JavaScript actions that are to run at document open time. | 
| 88   virtual void DoOpenActions(); | 89   virtual void DoOpenActions(); | 
| 89 | 90 | 
| 90   // Determine the page numbers present in the document. | 91   // Determine the page numbers present in the document. | 
| 91   virtual int GetFirstPageNum(); | 92   virtual int GetFirstPageNum(); | 
| 92   virtual int GetPageCount(); | 93   virtual int GetPageCount(); | 
| 93 | 94 | 
| 94   // Load a specific page of the open document. | 95   // Load a specific page of the open document. | 
| 95   virtual FPDF_PAGE LoadPage(int page_number); | 96   virtual FPDF_PAGE LoadPage(int page_number); | 
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 134   static int SetTimerTrampoline(FPDF_FORMFILLINFO* info, | 135   static int SetTimerTrampoline(FPDF_FORMFILLINFO* info, | 
| 135                                 int msecs, | 136                                 int msecs, | 
| 136                                 TimerCallback fn); | 137                                 TimerCallback fn); | 
| 137   static void KillTimerTrampoline(FPDF_FORMFILLINFO* info, int id); | 138   static void KillTimerTrampoline(FPDF_FORMFILLINFO* info, int id); | 
| 138   static FPDF_PAGE GetPageTrampoline(FPDF_FORMFILLINFO* info, | 139   static FPDF_PAGE GetPageTrampoline(FPDF_FORMFILLINFO* info, | 
| 139                                      FPDF_DOCUMENT document, | 140                                      FPDF_DOCUMENT document, | 
| 140                                      int page_index); | 141                                      int page_index); | 
| 141 }; | 142 }; | 
| 142 | 143 | 
| 143 #endif  // TESTING_EMBEDDER_TEST_H_ | 144 #endif  // TESTING_EMBEDDER_TEST_H_ | 
| OLD | NEW | 
|---|