gpt4 book ai didi

objective-c - CoreAnimation : warning, 删除了未提交 CATransaction 的线程;

转载 作者:行者123 更新时间:2023-12-03 17:35:09 27 4
gpt4 key购买 nike

我不知道我在看什么。我试图将问题追溯到某种动画,但我不知道问题出在哪里。我怎样才能找到它的来源?

CoreAnimation: warning, deleted thread with uncommitted CATransaction; created by:
0 QuartzCore 0x00007fff923ecb95 _ZN2CA11Transaction4pushEv + 219
1 QuartzCore 0x00007fff923ec76d _ZN2CA11Transaction15ensure_implicitEv + 273
2 QuartzCore 0x00007fff923ec60a _ZN2CA11Transaction9set_valueEj12_CAValueTypePKv + 40
3 QuartzCore 0x00007fff923ec59e +[CATransaction setDisableActions:] + 38
4 AppKit 0x00007fff8a7fff6e -[NSScrollerImp _updateLayerGeometry] + 67
5 AppKit 0x00007fff8a7ff54d -[NSScroller(NSInternal2) _replaceScrollerImp] + 368
6 AppKit 0x00007fff8a897828 -[NSScroller initWithCoder:] + 305
7 Foundation 0x00007fff89e92a09 _decodeObjectBinary + 2741
8 Foundation 0x00007fff89e91db4 _decodeObject + 226
9 AppKit 0x00007fff8a719760 -[NSView initWithCoder:] + 1103
10 AppKit 0x00007fff8a71afad -[NSControl initWithCoder:] + 50
11 AppKit 0x00007fff8a89772d -[NSScroller initWithCoder:] + 54
12 Foundation 0x00007fff89e92a09 _decodeObjectBinary + 2741
13 Foundation 0x00007fff89e91db4 _decodeObject + 226
14 AppKit 0x00007fff8a719760 -[NSView initWithCoder:] + 1103
15 AppKit 0x00007fff8ae115ee -[NSCollectionView initWithCoder:] + 114
CoreAnimation: warning, deleted thread with uncommitted CATransaction; created by:
0 QuartzCore 0x00007fff923ecb95 _ZN2CA11Transaction4pushEv + 219
1 QuartzCore 0x00007fff923ec76d _ZN2CA11Transaction15ensure_implicitEv + 273
2 QuartzCore 0x00007fff923f38ab _ZN2CA5Layer13thread_flags_EPNS_11TransactionE + 37
3 QuartzCore 0x00007fff923f37e3 _ZN2CA5Layer4markEPNS_11TransactionEjj + 79
4 QuartzCore 0x00007fff923f374a _ZN2CA5Layer25set_needs_display_in_rectERK6CGRect + 392
5 AppKit 0x00007fff8a8ff47d -[_NSViewBackingLayer setNeedsDisplayInRect:] + 206
6 QuartzCore 0x00007fff923f359f -[CALayer setNeedsDisplay] + 62
7 AppKit 0x00007fff8a8ff3a9 -[_NSViewBackingLayer setNeedsDisplay] + 73
8 AppKit 0x00007fff8a900bc8 -[NSView(NSInternal) _setLayerNeedsDisplayInViewRect:] + 566
9 AppKit 0x00007fff8a73caad -[NSView setNeedsDisplayInRect:] + 809
10 AppKit 0x00007fff8a73c672 -[NSView setNeedsDisplay:] + 79
11 AppKit 0x00007fff8a755648 -[NSButtonCell setTitle:] + 131
12 myOSXApp 0x00000001000087cb -[MyWindowController updateOutlineNodeCount:] + 187
13 CoreFoundation 0x00007fff8d5be47a _CFXNotificationPost + 2554
14 Foundation 0x00007fff89e8c846 -[NSNotificationCenter postNotificationName:object:userInfo:] + 64
15 myOSXApp 0x00000001000104f9 -[IconViewModel setChecked:] + 153

最佳答案

回溯显示您的应用程序的哪些代码导致了问题。

myOSXApp                          0x00000001000087cb -[MyWindowController updateOutlineNodeCount:] + 187 
myOSXApp 0x00000001000104f9 -[IconViewModel setChecked:] + 153

我假设您从非主线程的不同线程发布通知。如果没有更多背景,这很难说……

请注意,线程和通知不能很好地混合。

您似乎在 setChecked: 中发布了一条通知:并且此代码未在主线程上运行。

关于objective-c - CoreAnimation : warning, 删除了未提交 CATransaction 的线程;,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13555452/

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