I've got some NSToolbar code, which seems to have suddenly stopped
working on Leopard only.
- (void) setupToolbar
{
NSLog(@"Setting up toolbar");
// [self removeObsoleteToolbarIdentifiers];
NSToolbar *toolbar = [[MMICleanerToolbar alloc]
initWithIdentifier:@"CleanerToolbar"];
[toolbar setAllowsUserCustomization:YES];
[toolbar setAutosavesConfiguration:YES];
[toolbar setDelegate:self];
NSLog(@"Setting toolbar %@ for window %@", toolbar,
mMainCleanerWindow);
[mMainCleanerWindow setToolbar:toolbar];
// release it as well? TODO
NSLog(@"Set up toolbar");
}
MMICleanerToolbar is a subclass of NSToolbar, but actually doesn't
implement any methods, so it's an NSToolbar for all intents and
purposes.
On Tiger, I can see the delegates -toolbarDefaultItemIdentifiers:
method get called, followed by the NSToolbarItem calls, after the
setToolbar: method.
On Leopard (10.5.2/9C31) [latest security update not installed yet],
the delegate methods aren't getting called, and I get an empty
toolbar, which looks to be slightly less tall than the standard
toolbar with small items.
I rolled back over a few revisions of my app, and they all seem to be
affected, so it doesn't seem like I've broken anything recently. The
first user report I got for this was today (in fact I got two).
As I workaround, I'm checking [[toolbar items] count], after
setToolbar: and manually inserting the default item set if the
toolbar is empty.
_______________________________________________
Cocoa-dev mailing list ([email protected])
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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com
This email sent to [EMAIL PROTECTED]