IBOutlet getting messed up in the runtime
IBOutlet getting messed up in the runtime
- Subject: IBOutlet getting messed up in the runtime
- From: Benjámin Salánki <email@hidden>
- Date: Thu, 05 Nov 2009 11:42:52 +0100
Hey there, great minds of Cocoaland!
I am having a bit of a problem with my Project and I'm starting to go
crazy while trying to solve it.
What I am trying to accomplish is a Mail plugin for Mac OS X 10.6. All
is working fine now, thanks to some method swizzling code and some
sleepless nights.
I managed to inject my preferences pane into the preferences window of
mail, but here comes the problem. My preferences object loads the nib
containing the view that I plan on adding to the preferences window
using
[NSBundle loadNibNamed:[self preferencesNibName] owner:self];
where preferencesNibName obviously returns the nib in my bundle. Now
this nib contains basically four NSTextFields and an NSButton.
IBOutlets are set up and connected.
The first time I try to open Mail's Preferences, all goes as expected.
The second time however I bring mail down crashing. Going through logs
I figured out, that one of the NSTextFields is giving me the
headaches. When I try to do
[(NSTextField*)afield setStringValue:@"some string loaded from
prefs"];
all hell breaks loose. And the strange thing is that I get different
messages on the console practically every time I run the thing.
Sometimes the log states that my ivar afield is seen by the runtime as
a CFDictionary, other times it's IMAPMailboxSyncEngine. Sometimes it
crashes without even saying a word.
Seems to me something is messed up pretty bad. I tried trashing the
text field in IB and creating a new one, renaming the ivar in Xcode,
but to no avail. All other text fields work fine, except this one
little bugger.
Anything obvious I am missing here?
Thanks in advance,
Ben Salanki
_______________________________________________
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