Re: NSDrawer not always sending -drawerDidOpen: to delegate
Re: NSDrawer not always sending -drawerDidOpen: to delegate
- Subject: Re: NSDrawer not always sending -drawerDidOpen: to delegate
- From: Jerry Krinock <email@hidden>
- Date: Sun, 17 Feb 2013 19:05:39 -0800
OK, so while the drawer was in the broken state again, with the delegate wired in the nib, I poked it with the debugger again and found that, in order to fix it, I must first set the drawer's delegate to nil before setting it back to the window controller. That is, this did not work:
(lldb) expr (void)[$1 setDelegate:$4]
but this did:
(lldb) expr (void)[$1 setDelegate:nil] ; (void)[$1 setDelegate:$4]
Then, without doing anything to fix it but leaving the delegate wired up in the nib only, I scripted the app to launch 500 times with some random delays to open the window and the troublesome drawer and ran the script overnight. Result: all 500 good. Then I added a new "fix", which is to do the "But this did" above, in code, 1.0 seconds after -awakeFromNib, and that passed 100 times.
So I've applied two credible fixes for this non-reproducible problem. I hope it's fixed; need to move on. Thanks again, Kyle.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden