mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-22 16:18:08 +02:00
Support OpenAction dictionaries without Type
entries when parsing Print
actions (issue 11442)
The PDF generator didn't bother including the `Type` entry in the OpenAction dictionary, hence we skipped parsing the `Print` action.
This commit is contained in:
parent
1a708d8993
commit
70e3345cb4
1 changed files with 3 additions and 1 deletions
|
@ -625,7 +625,9 @@ class Catalog {
|
|||
|
||||
// Append OpenAction actions to the JavaScript array.
|
||||
const openActionDict = this.catDict.get('OpenAction');
|
||||
if (isDict(openActionDict, 'Action')) {
|
||||
if (isDict(openActionDict) &&
|
||||
(isName(openActionDict.get('Type'), 'Action') ||
|
||||
!openActionDict.has('Type'))) {
|
||||
const actionType = openActionDict.get('S');
|
||||
if (isName(actionType, 'Named')) {
|
||||
// The named Print action is not a part of the PDF 1.7 specification,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue