Unable to delete email sheet called from UIDocumentInteractionController in iOS 8

I have a very simple test application that contains only the following code attached to UIButton :

 - (IBAction)buttonUp:(id)sender { // Build file path NSString* filePath = [[NSBundle mainBundle] pathForResource:@"testfile" ofType:@"txt"]; NSURL *url = [NSURL fileURLWithPath:filePath]; m_interactionController = [UIDocumentInteractionController interactionControllerWithURL:url]; [m_interactionController presentOptionsMenuFromRect:CGRectMake(200, 200, 100, 100) inView:[self view] animated:YES]; } 

This collection works without problems and works under iOS 7 (on the 4th generation iPad: A1458), this code works fine.

The problem is that in iOS 8 Beta 5, if the user selects β€œMail” from the UIDocumentInteractionController , then the displayed email sheet can never be fired. Clicking Submit does send the mail, but the email sheet continues to display. Clicking on β€œCancel” and choosing to delete or save the draft have no effect.

The problem occurs when a test application is created using Xcode 5.1.1. However, if the application is built using Xcode 6 GM, then the problem does not occur, and the code works fine.

Is there something wrong with the code above?

+6
source share
1 answer

For us, the problem did not arise in the final version of iOS 8.

I sent it to Radar and it was closed as a duplicate (with the status of the duplicate, which is "Open"), so it was supposedly a bug in the preliminary versions of iOS 8.

0
source

Source: https://habr.com/ru/post/974649/


All Articles