问题
When handling inApp purchase (using Parse.com) in an iOS app, the user clicks BUY and waits for the iTunes login (or enter password) prompt to come up. During the waiting time, I display and activityView to ask the user to wait. Then when the prompt shows up, I need to clean this activityView. What is the call back function I need to put the code into? Is there something like loginPromptDidAppear? From which I could clean off the activityView.
回答1:
As the prompt is issued by iOS, not your app, you will get a call to the applicationWillResignActive
method in your app delegate, just as you would if a phone call is received.
You should be able to track your app operation (i.e. purchase initiated) and react accordingly when your app resigns active state.
来源:https://stackoverflow.com/questions/28871920/call-back-at-itunes-login-prompt-appearance