在滚动表视图时点按“返回”按钮时,应用程序崩溃 [英] App crashes when Back button tapped while scrolling table view
问题描述
我在导航视图中使用后退按钮显示模态表视图。后退按钮向模态视图的代理发送消息以关闭模态视图。如果我滚动表视图,然后点击导航栏上的后退按钮,同时表视图仍在滚动,应用程序崩溃与此消息:
I present a modal table view within a navigation view with a Back button. The back button sends a message to the modal view's delegate to dismiss the modal view. If I scroll the table view and then tap the Back button on the navigation bar while the table view is still scrolling, the app crashes with this message:
*** -[UILayoutContainerView setUseFastMode:]: message sent to deallocated instance 0xef74650
当我PO 0xef74650我得到这个:
When I PO 0xef74650 I get this:
(int) $1 = 251086416 [no Objective-C description available]
以前有人体验过吗?
推荐答案
我相信这是iOS 5.1中的一个错误,它会在解除模态即当前正在滚动。我收到用户的报告,我的应用程序崩溃,当我调查我有同样的错误。
I believe this is a bug in iOS 5.1 that occurs when animating the dismissing of a modal that is currently scrolling. I was getting reports from users that my app was crashing, and when I investigated I had the same error.
我创建了一个新的项目与最小的代码/意见并能够重现这次崩溃。我发现到目前为止唯一的解决方法是在关闭模态时禁用动画。我已向Apple提交错误报告。
I created a new project with the minimal amount of code/views and was able to reproduce this crash. The only workaround I've found so far is to disable animation when dismissing a modal. I've submitted a bug report to Apple.
这篇关于在滚动表视图时点按“返回”按钮时,应用程序崩溃的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!