Re: Need clarification on categories
Re: Need clarification on categories
- Subject: Re: Need clarification on categories
- From: Ondra Cada <email@hidden>
- Date: Tue, 19 Mar 2002 21:01:30 +0100
On Tuesday, March 19, 2002, at 06:32 , Bill Cheeseman wrote:
The reason I'm suffering feelings of doubt is that the method I'm trying
to
implement in a category is a delegate method, and it doesn't get called
when
I think it should. Specifically, the NSControl class reference document
says
the controlDidBeginEditing: delegate method will be called whenever a
text-based field is edited in any control that implements the method. But
First, its "controlTextDidBeginEditing:" -- if you used
"controlDidBeginEditing:", don't be surprised it's not called ;)
Second, not in the control. In its delegate:
controlTextDidBeginEditing:
- (void)controlTextDidBeginEditing:(NSNotification *)aNotification
Sent by the default notification center to the delegate and all observers
of the notification when...
So, even if you added the proper controlTextDidBeginEditing: _TO THE
CONTROL_, it would not be called.
Put the method into the delegate (uless you use *REALLY* weird delegates,
you won't need even categories for that), and see how nicely it works ;)
---
Ondra Cada
OCSoftware: email@hidden
http://www.ocs.cz
2K Development: email@hidden
http://www.2kdevelopment.cz
private email@hidden
http://www.ocs.cz/oc
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.