Re: NSBrowser with checkboxes?
Re: NSBrowser with checkboxes?
- Subject: Re: NSBrowser with checkboxes?
- From: Benjamin Stiglitz <email@hidden>
- Date: Thu, 13 Dec 2007 14:21:23 -0800
My current attempt at this is a subclass of NSBrowserCell which also
creates an NSButton. I've overridden the following methods to
dispatch calls to either the NSButton or super depending on the
coordinates:
I’ll assume you mean an NSButton cell.
What I can't get to work is the action message from the checkbox.
I've set the target and action for the embedded checkbox to send a
message to my window controller. I need this so that the window
controller can tell which checkbox was clicked and do something to
the item that cell represents. What happens is that my window
controller gets called, but the sender is the enclosing NSMatrix,
not the cell itself.
That’s the expected behavior for an NSControl; the control view, not
the cell, is used as the sender of the action message. The cell you
clicked on should be accessible as the key cell (-[NSMatrix keyCell]).
-Ben_______________________________________________
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