mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-25 17:48:07 +02:00
Use the link service for getting and setting page information
This removes the dependency on a `PDFViewer` instance from the find controller, which makes it more similar to other components and makes it easier to unit test with a mock link service. Finally, we remove the search capabilities from the SVG example since it doesn't work there because there is no separate text layer.
This commit is contained in:
parent
e293c12afc
commit
e0c811f2ed
5 changed files with 21 additions and 24 deletions
|
@ -46,7 +46,7 @@ pdfLinkService.setViewer(pdfViewer);
|
|||
|
||||
// (Optionally) enable find controller.
|
||||
var pdfFindController = new pdfjsViewer.PDFFindController({
|
||||
pdfViewer: pdfViewer,
|
||||
linkService: pdfLinkService,
|
||||
});
|
||||
pdfViewer.setFindController(pdfFindController);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue