2015-02-02 12 views
8

Sto lavorando sulla mia interfaccia utente, cercando di navigare i miei dati attraverso un insieme di NSSplitViewControllers nidificati, NSTabViewControllers, eccChe cos'è CGSUpdateManager e perché si lamenta?

Ad un certo punto o un altro ottengo questi avvertimenti di errore. Non ho idea da dove vengano e dove neanche a guardare. L'app sembra funzionare correttamente.

Che cos'è CGSUpdateManager e perché si lamenta?

void CGSUpdateManager::log() const: conn 0xdbbb token 0x2ffffffffffdc78 Backtrace (at 5543.57): 
void CGSUpdateManager::log() const: 0 CoreGraphics      0x00007fff85db9215 CGSBacktraceCreate + 59 
void CGSUpdateManager::log() const: 1 CoreGraphics      0x00007fff85dd8688 _ZN16CGSUpdateManager14disable_updateEv + 84 
void CGSUpdateManager::log() const: 2 AppKit        0x00007fff897f3de5 -[NSWindow disableScreenUpdatesUntilFlush] + 127 
void CGSUpdateManager::log() const: 3 AppKit        0x00007fff897b3250 -[NSView _gainedLayerTreeHostAncestor] + 385 
void CGSUpdateManager::log() const: 4 AppKit        0x00007fff897b30ae -[NSView _recursiveGainedLayerTreeHostAncestor] + 27 
void CGSUpdateManager::log() const: 5 AppKit        0x00007fff897b767a -[NSScroller _recursiveGainedLayerTreeHostAncestor] + 103 
void CGSUpdateManager::log() const: 6 AppKit        0x00007fff89a1ea56 -[NSScroller _setSurfaceBacked:] + 213 
void CGSUpdateManager::log() const: 7 AppKit        0x00007fff8998424f -[NSScrollView setScrollerStyle:] + 304 
void CGSUpdateManager::log() const: 8 AppKit        0x00007fff8a01bf27 +[NSScrollerImpPair _updateAllScrollerImpPairsForNewRecommendedScrollerStyle:] + 426 
void CGSUpdateManager::log() const: 9 CoreFoundation       0x00007fff914b5cbc __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 12 
void CGSUpdateManager::log() const: 10 CoreFoundation      0x00007fff913a71b4 _CFXNotificationPost + 3140 
void CGSUpdateManager::log() const: 11 Foundation       0x00007fff917feea1 -[NSNotificationCenter postNotificationName:object:userInfo:] + 66 
void CGSUpdateManager::log() const: 12 CoreFoundation      0x00007fff9141754c __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 12 
void CGSUpdateManager::log() const: 13 CoreFoundation      0x00007fff91409655 __CFRunLoopDoBlocks + 341 
void CGSUpdateManager::log() const: 14 CoreFoundation      0x00007fff91409196 __CFRunLoopRun + 1814 
void CGSUpdateManager::log() const: 15 CoreFoundation      0x00007fff91408838 CFRunLoopRunSpecific + 296 
void CGSUpdateManager::log() const: 16 HIToolbox       0x00007fff8f30743f RunCurrentEventLoopInMode + 235 
void CGSUpdateManager::log() const: 17 HIToolbox        0x00007fff8f3071ba ReceiveNextEventCommon + 431 
void CGSUpdateManager::log() const: 18 HIToolbox       0x00007fff8f306ffb _BlockUntilNextEventMatchingListInModeWithFilter + 71 
void CGSUpdateManager::log() const: 19 AppKit        0x00007fff897376d1 _DPSNextEvent + 964 
void CGSUpdateManager::log() const: 20 AppKit        0x00007fff89736e80 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 194 
void CGSUpdateManager::log() const: 21 AppKit        0x00007fff8972ae23 -[NSApplication run] + 594 
void CGSUpdateManager::log() const: 22 AppKit        0x00007fff897162d4 NSApplicationMain + 1832 
void CGSUpdateManager::log() const: 23 Well        0x0000000100019422 top_level_code + 34 
void CGSUpdateManager::log() const: 24 Well        0x000000010001945a main + 42 
void CGSUpdateManager::log() const: 25 libdyld.dylib      0x00007fff85b7b5c9 start + 1 
+0

La stessa cosa qui. Ho trovato che la mia app ha iniziato a lanciare questi messaggi da quando ho eseguito l'aggiornamento a Yosemite. Non ho idea di dove guardare. A parte questo, tutto sembra funzionare bene. Quale versione di OS X stai usando? – insys

+0

Yosemite 10.10.1 – user965972

+0

insys, chiama super. Fatto in una risposta per la prosperità. – user965972

risposta

0

Assicurati di chiamare super-in viewDidLoad, viewWillAppear e viewWillDisappear.

+1

questi super metodi sono specifici per uikit. la domanda è chiaramente appkit. – johndpope

+0

La maggior parte di questi sono definiti in NSViewController. – user965972

1

Ho iniziato a vedere lo stesso problema quando sono passato a El Capitan.

fine ho rintracciato giù a qualcosa di profondo nella mia base di codice che non ha causato un problema prima ... ho avuto una chiamata randagio a:

[NSGraphicsContext restoreCurrentContext]; 

Questo è stato un problema prima ... fare sicuro di bilanciare queste chiamate ... specialmente in funzioni che ritornano presto!

[NSGraphicsContext saveCurrentContext]; 
[NSGraphicsContext restoreCurrentContext]; 

in modo simile per CGContextSaveGState (CTX); CGContextRestoreGState()

Problemi correlati