NSTokenField ignoring field editor change?
NSTokenField ignoring field editor change?
- Subject: NSTokenField ignoring field editor change?
- From: Nick Zitzmann <email@hidden>
- Date: Thu, 7 Jul 2005 09:41:29 -0600
I searched the archives already and didn't see anything...
I'm trying to use NSTokenField and change its field editor to a
custom field editor. I've done this in the usual way, by adding a
method like this to the NSWindow delegate object:
- (id)windowWillReturnFieldEditor:(NSWindow *)sender toObject:(id)
anObject
{
if ([anObject isKindOfClass:[NSTextField class]])
{
return myFieldEditor;
}
return nil;
}
In my view I have both an NSTextField and an NSTokenField. I can
verify that this method is being called for both objects, and that
myFieldEditor is being returned when anObject is set to the
NSTokenField. But despite this, the NSTokenField is using a plain old
NSTextView as its field editor instead of the one I want it to use,
while the NSTextField is using the custom field editor as it should.
So what, if anything, am I doing wrong? If nothing, then how do I
force this particular NSTokenField to use the custom field editor?
Nick Zitzmann
<http://www.chronosnet.com/>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden