1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-20 15:18:08 +02:00

Call AnnotationLayer.setDimensions as part of the render/update-methods (PR 15036 follow-up)

Rather than forcing the user to *manually* call `setDimensions`, which is also breaking any existing third-party code, it seems that we can simply let the `AnnotationLayer.{render, update}`-methods handle that internally.

As far as I can tell, based on testing manually in the viewer *and* running the browser-tests, everything still appears to work correctly with this patch.
This commit is contained in:
Jonas Jenwald 2022-07-04 09:07:10 +02:00
parent ca8b112e8c
commit 552ee9decd
3 changed files with 9 additions and 10 deletions

View file

@ -231,7 +231,6 @@ class Rasterize {
renderForms,
annotationCanvasMap: annotationImageMap,
};
AnnotationLayer.setDimensions(div, annotationViewport);
AnnotationLayer.render(parameters);
// Inline SVG images from text annotations.