mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-26 01:58:06 +02:00
Let the two annotation factories use static methods
This corresponds to how other factories are implemented.
This commit is contained in:
parent
af10f8b586
commit
4f02857394
4 changed files with 48 additions and 53 deletions
|
@ -316,10 +316,9 @@ var Page = (function PageClosure() {
|
|||
get annotations() {
|
||||
var annotations = [];
|
||||
var annotationRefs = this.getInheritedPageProp('Annots') || [];
|
||||
var annotationFactory = new AnnotationFactory();
|
||||
for (var i = 0, n = annotationRefs.length; i < n; ++i) {
|
||||
var annotationRef = annotationRefs[i];
|
||||
var annotation = annotationFactory.create(this.xref, annotationRef,
|
||||
var annotation = AnnotationFactory.create(this.xref, annotationRef,
|
||||
this.pdfManager,
|
||||
this.idFactory);
|
||||
if (annotation) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue