mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-26 01:58:06 +02:00
Add support for radios printing
This commit is contained in:
parent
eb4d6a0652
commit
538017f7a7
3 changed files with 150 additions and 40 deletions
|
@ -1078,16 +1078,19 @@ class ButtonWidgetAnnotation extends WidgetAnnotation {
|
|||
if (!isDict(appearanceStates)) {
|
||||
return;
|
||||
}
|
||||
const normalAppearanceState = appearanceStates.get("N");
|
||||
if (!isDict(normalAppearanceState)) {
|
||||
const normalAppearance = appearanceStates.get("N");
|
||||
if (!isDict(normalAppearance)) {
|
||||
return;
|
||||
}
|
||||
for (const key of normalAppearanceState.getKeys()) {
|
||||
for (const key of normalAppearance.getKeys()) {
|
||||
if (key !== "Off") {
|
||||
this.data.buttonValue = key;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
this.checkedAppearance = normalAppearance.get(this.data.buttonValue);
|
||||
this.uncheckedAppearance = normalAppearance.get("Off") || null;
|
||||
}
|
||||
|
||||
_processPushButton(params) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue