Re: Make an NSButton send a message on right click
Re: Make an NSButton send a message on right click
- Subject: Re: Make an NSButton send a message on right click
- From: Jens Alfke <email@hidden>
- Date: Fri, 23 Oct 2009 10:55:57 -0700
On Oct 22, 2009, at 5:28 PM, Alexander Golec wrote:
For the cells, I want to have a matrix of NSButtons, and I want each
button to respond differently to right clicks and left clicks. Would
I have to extend NSButton or something?
Yup. Subclass NSButton, override -mouseDown: and check whether the
event uses the right button. If so, do your thing; otherwise, call the
superclass method.
—Jens_______________________________________________
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