Re: Loading a .nib?
Re: Loading a .nib?
- Subject: Re: Loading a .nib?
- From: Brian Stern <email@hidden>
- Date: Fri, 2 May 2008 20:38:42 -0400
On May 2, 2008, at 7:33 PM, J. Todd Slack wrote:
Hi,
One question though.
When I use:
[NSBundle loadNibNamed:@"SettingsDialog" owner:self]; // the nib
name is SettingsDialog.nib
Xcode complains that this is the first time that self is used.
You probably want to create an instance of a NSWindowController
subclass and have it load the bundle.
Also, simply converting your .c to a .m doesn't turn your plugin into
a friendly Cocoa host. You probably need to call NSApplicationLoad(),
create an NSAutoReleasePool and wrap your objective-C code in a @try
block so exceptions don't propagate back through your C code and to
the host app.
Isn't there some sample code for building Cocoa iTunes plugins
available somewhere that will answer these questions for you?
--
Brian Stern
email@hidden
_______________________________________________
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