Rubymotion を使用して iOS アプリを作成しています。メール コンポーザーでビルドを使用していますが、キャンセル デリゲート メソッドの作成に問題があります。
Objective C では次のようになります。
-(void)mailComposeController:(MFMailComposeViewController *)controller didFinishWithResult:(MFMailComposeResult)result error:(NSError *)error{
[controller dismissModalViewControllerAnimated:YES];
}
これはRubyで開始した方法ですが、間違っています:
def MFMailComposeViewController(didFinishWithResult:lambda{ |error|
self.dismissModalViewControllerAnimated(true)
})
Objective C から Ruby に変換するには助けが必要です。