[英]Crash when dismissing UIActionSheet
I am facing a mysterious crash issue when running our app (64 bit complaint) inside another app. 在另一个应用程序中运行我们的应用程序(64位投诉)时,我面临着一个神秘的崩溃问题。 The crash happens within
UIKit
after UIActionSheet
is dismissed. UIActionSheet
被关闭后,崩溃发生在UIKit
。
Below is the sequence of actions I am performing: 以下是我执行的操作顺序:
2014-07-14 14:26:57.404 AppleEasyPay[677:60b] -[__NSCFType _canBecomeKeyWindow]: unrecognized selector sent to instance 0x15c6abb70
- (void)showDeleteRequestConfirmation:(id)iSender {
self.actionSheet = [[UIActionSheet alloc] init];
self.actionSheet.destructiveButtonIndex = 0;
self.actionSheet.actionSheetStyle = UIActionSheetStyleBlackTranslucent;
[self.actionSheet addButtonWithTitle:MyLocalized(kDeleteButtonKey)];
[self.actionSheet addButtonWithTitle:MyLocalized(kCancelButtonKey)];
self.actionSheet.title = MyLocalized(kDeleteConfirmationMessageKey);
self.actionSheet.tag = kDeleteConfirmationActionSheet;
self.actionSheet.delegate = self;
[self.actionSheet showInView:self.tableView];
}
- (void)showCompleteRequestConfirmaton:(id)iSender {
if (self.totalQuantityScanned < self.totalQuantityToBeScanned) {
self.actionSheet = [[UIActionSheet alloc] init];
self.actionSheet.cancelButtonIndex = 1;
[self.actionSheet addButtonWithTitle:MyLocalized(kCompleteButtonKey)];
[self.actionSheet addButtonWithTitle:MyLocalized(kCancelButtonKey)];
self.actionSheet.title = MyLocalized(kCompleteRequestMessageKey);
self.actionSheet.tag = kCompleteConfirmationActionSheet;
self.actionSheet.delegate = self;
[self.actionSheet showInView:self.tableView];
} else {
[self completeRequest:iSender];
}
}
It was a mysteriously weird issue. 这是一个神秘而奇怪的问题。 I just put a strong property for my UIAlerView which I was showing on tap on my first action sheet and put that in the header file and it worked.
我只是为我的UIAlerView设置了一个强大的属性,将其显示在我的第一个操作表上,然后将其放在头文件中就可以了。 Putting the property in the extension was crashing it.
将属性放入扩展名会使它崩溃。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.