Iphone 我如何检测UIActionSheet何时被撤销?

Iphone 我如何检测UIActionSheet何时被撤销?,iphone,uiactionsheet,dismiss,Iphone,Uiactionsheet,Dismiss,我对iphonedev还很陌生,所以非常感谢您的帮助 我正在函数中创建操作表,并将其添加到当前视图中。我将工作表委托作为“自我”,不保留行动表。有没有像datePicker的didSelectRow这样的函数?像“DidDismissWithButtonIndex”之类的东西,或者让我在行动表关闭时检测到的东西 谢谢, MikeUIActionSheetDelegate方法–actionSheet:didDismissWithButtonIndex:就是您要寻找的。从: 操作表:didDismi

我对iphonedev还很陌生,所以非常感谢您的帮助

我正在函数中创建操作表,并将其添加到当前视图中。我将工作表委托作为“自我”,不保留行动表。有没有像datePicker的didSelectRow这样的函数?像“DidDismissWithButtonIndex”之类的东西,或者让我在行动表关闭时检测到的东西

谢谢,
Mike

UIActionSheetDelegate方法
–actionSheet:didDismissWithButtonIndex:
就是您要寻找的。从:

操作表:didDismissWithButtonIndex: 在行动表从屏幕上消失后发送给代表

- (void)actionSheet:(UIActionSheet *)actionSheet didDismissWithButtonIndex:(NSInteger)buttonIndex
参数
行动单
被驳回的行动单

按钮索引
单击的按钮的索引。按钮索引从
0
开始。如果这是取消按钮索引,则操作表正在取消。如果
-1
,则不设置取消按钮索引

讨论
此方法在动画结束且视图隐藏后调用


UIActionSheetDelegate方法
–actionSheet:didDismissWithButtonIndex:
就是您要寻找的。从:

操作表:didDismissWithButtonIndex: 在行动表从屏幕上消失后发送给代表

- (void)actionSheet:(UIActionSheet *)actionSheet didDismissWithButtonIndex:(NSInteger)buttonIndex
参数
行动单
被驳回的行动单

按钮索引
单击的按钮的索引。按钮索引从
0
开始。如果这是取消按钮索引,则操作表正在取消。如果
-1
,则不设置取消按钮索引

讨论
此方法在动画结束且视图隐藏后调用

使用isVisible属性

使用isVisible属性