gpt4 book ai didi

ios - -[id gestureRecognizer :shouldRecognizeSimultaneouslyWithGestureRecognizer] both recognizers are nil in debugger

转载 作者:可可西里 更新时间:2023-11-01 05:56:04 35 4
gpt4 key购买 nike

我有一个方法

- (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer
{
NSLog(@"%@\n%@", gestureRecognizer, otherGestureRecognizer);
return YES;
}

记录正常:

2013-04-12 21:36:20.126 Project[2504:907] <UITapGestureRecognizer: 0x1e5c25b0; state = Ended; view = <UIView 0x1e5c5cc0>; target= <(action=toggleControls, target=<PictureViewController 0x1e5c0ab0>)>; must-fail-for = {
<UIScrollViewPanGestureRecognizer: 0x1e5c53a0; state = Failed; delaysTouchesEnded = NO; view = <ZoomScroll 0x1e5c4790>; target= <(action=handlePan:, target=<ZoomScroll 0x1e5c4790>)>>,
<UIScrollViewPinchGestureRecognizer: 0x1e5c5bb0; state = Failed; delaysTouchesEnded = NO; view = <ZoomScroll 0x1e5c4790>; target= <(action=handlePinch:, target=<ZoomScroll 0x1e5c4790>)>>
}>
<UIScrollViewPagingSwipeGestureRecognizer: 0x1f0bb4f0; state = Failed; view = <UIScrollView 0x1f0bb010>; target= <(action=_handleSwipe:, target=<UIScrollView 0x1f0bb010>)>; must-fail-for = {
<UIScrollViewPanGestureRecognizer: 0x1f0bb340; state = Failed; delaysTouchesEnded = NO; view = <UIScrollView 0x1f0bb010>; target= <(action=handlePan:, target=<UIScrollView 0x1f0bb010>)>>
}>

但在调试控制台中它们都是nil

(lldb) po gestureRecognizer
$1 = 0x00000000 <nil>
(lldb) po otherGestureRecognizer
$2 = 0x00000000 <nil>

这是怎么回事?我能以某种方式解决这个问题吗?

最佳答案

这是 XCode/lldb 的一个已知错误,尚未解决。如果你没有运行 xcode 5-dp,你可以返回到 gdb,它应该可以工作。

Xcode 4.3 发布说明:“使用 LLDB 调试器时,断点中的某些调试器命令和日志表达式会失败,因为 Xcode 在执行调试器命令或评估日志表达式时使用了错误的帧。如果您知道哪个线程调试器命令或日志表达式必须相对运行,在有问题的断点操作之前添加一个断点操作,将当前帧设置为适当的帧。10426977"

我的引用:Debugger lldb says my object is nil when is not ?

关于ios - -[id<UIGestureRecognizerDelegate> gestureRecognizer :shouldRecognizeSimultaneouslyWithGestureRecognizer] both recognizers are nil in debugger,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15977568/

35 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com