I'm using UIPrintInteractionController
presenting it from rect.
UIPrintInteractionController *controller = [UIPrintInteractionController sharedPrintController];
// than set printing settings
...
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad)
[controller presentFromRect:rect inView:view animated:YES completionHandler:completionHandler];
Than I set number of pages (>1) and select a printer. Before devices rotation I call
[controller dismissAnimated:animated];
according to Xcode documentation: You should dismiss the printing options when they are presented in a sheet or animated from a rectangle and the user changes the orientation of the device.
When I present UIPrintInteractionController
after rotation, the number of printing copies is set back to 1 (as in initial view), whereas printer remains selected.
Ivar _copies of UIPrintInfo is private, so I can't get it and store during rotation.
How can I restore the number of printing pages after rotation?
dismissAnimated:
method ofUIPrintInteractionController
class. "You should dismiss the printing options when they are presented in a sheet or animated from a rectangle and the user changes the orientation of the device." and "You should then present the printing options again once the new orientation takes effect." – LaundressUIPrintInteractionController
class. – Laundress