Re: Select NSTextField mouse event
Re: Select NSTextField mouse event
- Subject: Re: Select NSTextField mouse event
- From: Jerry Krinock <email@hidden>
- Date: Wed, 3 Feb 2010 09:03:20 -0800
On 2010 Feb 03, at 00:34, padmakumar wrote:
> In my Cocoa based application, I am having a user editable NSTextField.
> I need to know when the user selects the NSTextField using mouse.
> I tried the delegate method controlTextDidChange, but the problem is user need to enter an character to get this delegate invoked.
> My requirement was when ever user selects the NSTextField, I need to know that.
Maybe knowing when it becomes First Responder would work. NSTextField inherits from NSResponder. From documentation:
-[NSResponder becomeFirstResponder]
Notifies the receiver that it’s about to become first responder in its NSWindow.
- (BOOL)becomeFirstResponder
Discussion
The default implementation returns YES, accepting first responder status. Subclasses can override this method to update state or perform some action such as....
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden