• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Select NSTextField mouse event
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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

References: 
 >Select NSTextField mouse event (From: padmakumar <email@hidden>)

  • Prev by Date: Re: Multithread communication
  • Next by Date: Re: Multithread communication
  • Previous by thread: Select NSTextField mouse event
  • Next by thread: Re: another responder chain docs bug (validateUserInterfaceItem:)
  • Index(es):
    • Date
    • Thread