mirror of
https://github.com/mozilla/pdf.js.git
synced 2026-08-03 12:57:20 +02:00
Compare commits
4 Commits
d71fe9025d
...
813d1949ba
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
813d1949ba | ||
|
|
a1acf4fc9f | ||
|
|
9ca13c9a23 | ||
|
|
09c9f7f2fe |
@ -1860,7 +1860,6 @@ class Font {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// removing duplicate entries
|
// removing duplicate entries
|
||||||
mappings.sort((a, b) => a.charCode - b.charCode);
|
|
||||||
const finalMappings = [],
|
const finalMappings = [],
|
||||||
seenCharCodes = new Set();
|
seenCharCodes = new Set();
|
||||||
for (const map of mappings) {
|
for (const map of mappings) {
|
||||||
@ -1876,7 +1875,7 @@ class Font {
|
|||||||
return {
|
return {
|
||||||
platformId: potentialTable.platformId,
|
platformId: potentialTable.platformId,
|
||||||
encodingId: potentialTable.encodingId,
|
encodingId: potentialTable.encodingId,
|
||||||
mappings: finalMappings,
|
mappings: finalMappings.sort((a, b) => a.charCode - b.charCode),
|
||||||
hasShortCmap,
|
hasShortCmap,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -134,9 +134,6 @@ class IdManager {
|
|||||||
|
|
||||||
constructor() {
|
constructor() {
|
||||||
if (typeof PDFJSDev !== "undefined" && PDFJSDev.test("TESTING")) {
|
if (typeof PDFJSDev !== "undefined" && PDFJSDev.test("TESTING")) {
|
||||||
Object.defineProperty(this, "reset", {
|
|
||||||
value: () => (this.#id = 0),
|
|
||||||
});
|
|
||||||
Object.defineProperty(this, "getNextId", {
|
Object.defineProperty(this, "getNextId", {
|
||||||
value: () => this.#id,
|
value: () => this.#id,
|
||||||
});
|
});
|
||||||
@ -1067,13 +1064,6 @@ class AnnotationEditorUIManager {
|
|||||||
commentManager?.setSidebarUiManager(this);
|
commentManager?.setSidebarUiManager(this);
|
||||||
|
|
||||||
if (typeof PDFJSDev !== "undefined" && PDFJSDev.test("TESTING")) {
|
if (typeof PDFJSDev !== "undefined" && PDFJSDev.test("TESTING")) {
|
||||||
Object.defineProperty(this, "reset", {
|
|
||||||
value: () => {
|
|
||||||
this.selectAll();
|
|
||||||
this.delete();
|
|
||||||
this.#idManager.reset();
|
|
||||||
},
|
|
||||||
});
|
|
||||||
Object.defineProperty(this, "getNextEditorId", {
|
Object.defineProperty(this, "getNextEditorId", {
|
||||||
value: () => this.#idManager.getNextId(),
|
value: () => this.#idManager.getNextId(),
|
||||||
});
|
});
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user