Re: [Pyobjc-dev] pluginbuilder: must specify 'nibname' - why?
Brought to you by:
ronaldoussoren
From: Ronald O. <ron...@ma...> - 2004-05-30 19:46:29
|
On 30-mei-04, at 18:57, Martina Oefelein wrote: > Hi, > > I'm using pluginbuilder to build an AddressBook plugin. > > As my plugin doesn't have a nib file, I didn't specify a nibname in > the call to buildplugin. But pluginbuilder rejects this: "must specify > 'nibname' when building a plugin bundle". Why? because :-) pluginbuilder started it's live as a quick hack to create a plugin that needed a nib-file, I never got around to cleaning it up. I've only used the tool to create system preference panes. We haven't succeeded in creating Interface Builder palettes yet. Let us know how you fare with you're AddressBook plugin. > > It seems that it is satisfied with a dummy nibname, as long as it is > nonzero. nibname="" builds fine, but then AddressBook doesn't load my > plugin and writes this to the console: > MOAddressBookPlugin.bundle does not contain the correct ABActions.h > methods. > The reason is apparently that NSPrincipalClass is not set in this case: > if self.nibname: > self.plist.NSMainNibFile = self.nibname > if not hasattr(self.plist, "NSPrincipalClass"): > if self.principalClass is None: > raise bundlebuilder.BundleBuilderError, ( > "must specify 'principalClass' when building a > " > "plugin bundle") > self.plist.NSPrincipalClass = self.principalClass > > Shouldn't this be: > if self.nibname: > self.plist.NSMainNibFile = self.nibname > > if not hasattr(self.plist, "NSPrincipalClass"): > if self.principalClass is None: > raise bundlebuilder.BundleBuilderError, ( > "must specify 'principalClass' when building a " > "plugin bundle") > self.plist.NSPrincipalClass = self.principalClass I think you're right, this looks like a detab-gone-wrong :-( Ronald -- X|support bv http://www.xsupport.nl/ T: +31 610271479 F: +31 204416173 |