Commit d67cb9f
committed
fix: disable duplex when N-up reduces output to a single sheet
isDuplexDisabled only looked at the source page count
(previewPageCount <= 1), so selecting N-up that collapses the document
to one printed sheet left duplex enabled — e.g. a 4-page document with
4-up yields a single sheet but duplex still showed as selectable.
Compute the effective sheet count as ceil(printed source pages / nup)
and disable duplex when it drops to 1. The existing auto-correct effect
already keys off isDuplexDisabled, so selecting such an N-up value also
flips the selection back to single-sided, and raising nup again (2 sheets)
re-enables the buttons.1 parent 3433753 commit d67cb9f
1 file changed
Lines changed: 11 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
361 | 361 | | |
362 | 362 | | |
363 | 363 | | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
364 | 374 | | |
365 | | - | |
366 | | - | |
| 375 | + | |
367 | 376 | | |
368 | 377 | | |
369 | 378 | | |
| |||
0 commit comments