Getting the Field from a Field Editor
Getting the Field from a Field Editor
- Subject: Getting the Field from a Field Editor
- From: Daniel Todd Currie <email@hidden>
- Date: Sat, 11 Sep 2004 17:04:03 -0700
I subclassed NSTextView to get a certain behavior I need in the field
editor for my NSTextFields. What I would like to do now, is be able to
access the field that is currently being edited from inside the field
editor. The only way I've found so far is:
[[self nextResponder] nextResponder]
I don't like this way very much, it's really ugly. What I'd really
like is a -field method that is an accessor for some private instance
variable or something.
On that note, I could set such an instance variable using an accessor
method in the -windowWillReturnFieldEditor:toObject: delegate method.
I don't like this design much either though, it seems like I should be
able to do this internally to the NSTextView subclass. Is there
perhaps some message that NSTextView receives when it becomes a field
editor?
Is there something I am missing? TIA,
-- DTC
_______________________________________________
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