And another thing I don't quite understand... ;-)
And another thing I don't quite understand... ;-)
- Subject: And another thing I don't quite understand... ;-)
- From: Matt Ridley <email@hidden>
- Date: Tue, 8 May 2001 15:48:02 +0100
Sorry, it's me once again. :-)
This again relates to an NSToolbar. For convenience, I'm storing
my NSToolbarItems in an NSMutableDictionary. My NSToolbar
delegate implements a method to return the list of default
toolbar items as an array. I'm having problems retrieving an
item from my NSMutableDictionary, to pass within the array.
Here's a simplified version of the code:
return [NSArray arrayWithObjects:
NSToolbarCustomizeToolbarItemIdentifier,
[toolItems objectForKey:@"Sample"], nil];
As you can see, I'm trying to return an array of three
NSToolbarItems: the default Customize item
(NSToolbarCustomizeToolbarItemIdentifier), the item I put into
my NSMutableDictionary (called "toolItems") and gave the key
"Sample", and nil.
The error returned leads me to believe that the Cocoa runtime is
trying to send a NSMutableDictionary-specific message to an
NSToolbarItem which of course doesn't handle the message. I'm
not sure how to proceed. Help appreciated!
Best,
-Matt
--
Matt Ridley
<
http://www.mattridley.com/>