mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-10 02:05:37 +02:00
Introduce a "thumbnailrendered" event to simplify cleanup after thumbnail rendering (PR 12613 follow-up)
The way that the cleanup was implemented in PR 12613 has always bothered me slightly, since the `isPageCached`-method that I introduced there always felt quite out-of-place in the `IPDFLinkService`-implementations. By introducing a new "thumbnailrendered" event, similar to the existing "pagerendered" one, we're able to move the cleanup handling into the `PDFViewer`-class instead.
This commit is contained in:
parent
6d8810b55c
commit
bc8523ac29
6 changed files with 31 additions and 47 deletions
|
@ -533,6 +533,7 @@ const PDFViewerApplication = {
|
|||
if (appConfig.sidebar?.thumbnailView) {
|
||||
this.pdfThumbnailViewer = new PDFThumbnailViewer({
|
||||
container: appConfig.sidebar.thumbnailView,
|
||||
eventBus,
|
||||
renderingQueue: pdfRenderingQueue,
|
||||
linkService: pdfLinkService,
|
||||
l10n: this.l10n,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue