[Editor] Avoid to have duplicated entries in the Annot array when saving an existing and modified annotation

This commit is contained in:
Calixte Denizet 2023-06-15 20:43:57 +02:00
parent 64520a0c63
commit 71479fdd21
4 changed files with 93 additions and 4 deletions

View file

@ -780,6 +780,11 @@ class PDFDocumentProxy {
return this._transport.getXRefPrevValue();
},
});
Object.defineProperty(this, "getAnnotArray", {
value: pageIndex => {
return this._transport.getAnnotArray(pageIndex);
},
});
}
}
@ -2405,6 +2410,13 @@ class WorkerTransport {
return this.messageHandler.sendWithPromise("GetXRefPrevValue", null);
},
});
Object.defineProperty(this, "getAnnotArray", {
value: pageIndex => {
return this.messageHandler.sendWithPromise("GetAnnotArray", {
pageIndex,
});
},
});
}
}