IBAction 方法现在显示在文件所有者中
我有一个声明两个类的头文件。第二个看起来像
#import <MessageUI/MessageUI.h>
#import <MessageUI/MFMailComposeViewController.h>
@interface MailComposerViewController : UIViewController <MFMailComposeViewControllerDelegate>
- (IBAction)sendMail: (id)sender;
然后,在一个与我没有提到的第一个类的方法配合得很好的 xib 文件中,当我尝试从 TabBarButtonItem 中取出它时,我只是找不到 sendMail 方法 -not navigationBarButton- 并照常将其交给文件所有者。我尝试在方法的声明中删除 (id)sender 并将 IBAction 切换为 void,但没有成功。我只是想知道在同一标头中定义两个指向同一 xib 的类我做错了什么。
I have a header file that declares two classes. The second looks like
#import <MessageUI/MessageUI.h>
#import <MessageUI/MFMailComposeViewController.h>
@interface MailComposerViewController : UIViewController <MFMailComposeViewControllerDelegate>
- (IBAction)sendMail: (id)sender;
Then, in a xib file that is working just fine with the methods of the first class that i didn't mention, I just can't find the sendMail method when I try to pull It out from a TabBarButtonItem -not navigationBarButton- and give it to File's Owner as ususal. I tried to erase the (id)sender and switch IBAction for void in the declaration of the method, but non have worked. I'm just wondering what I'm doing wrong by defining two classes in the same header that point to the same xib.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论