デフォルトでは、パスはにロードされPKAddPassesViewController
ます。ビューでどのボタンが押されているかを知る方法はありますか?
//this method runs when user either click on the cancel or add button
-(void)addPassesViewControllerDidFinish: (PKAddPassesViewController*) controller
{
[self dismissViewControllerAnimated:YES completion:nil];
}
で押されたボタンのタイトルを取得したいPKAddPassesViewController
。タイトルにアクセスするために以下のコードを試しましたが、取得していnull
ます。
NSLog(@"Title of button %@",controller.navigationController.navigationItem.rightBarButtonItem.title);