Skip to content

Commit

Permalink
Fix : Unable to PrintToPrinter in IOS15 katzer#281
Browse files Browse the repository at this point in the history
  • Loading branch information
dimer47 committed Jul 15, 2022
1 parent 672d804 commit 506e5bb
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/ios/APPPrinter.m
Original file line number Diff line number Diff line change
Expand Up @@ -173,9 +173,12 @@ - (void) printContent:(NSString *)content
withSettings:(NSDictionary *)settings
{
__block id item;
__block UIPrintInteractionController* ctrl;

UIPrintInteractionController* ctrl =
[UIPrintInteractionController sharedPrintControllerWithSettings:settings];
dispatch_sync(dispatch_get_main_queue(), ^{
ctrl =
[UIPrintInteractionController sharedPrintControllerWithSettings:settings];
});

ctrl.delegate = self;

Expand Down

0 comments on commit 506e5bb

Please sign in to comment.