How to find the position of an NSCell?
How to find the position of an NSCell?
- Subject: How to find the position of an NSCell?
- From: Kai-Mikael Jää-Aro <email@hidden>
- Date: Wed, 4 Jul 2007 13:51:19 +0200
I am constructing a hierarchical tool palette and thought the best
way to do this would be through using a (subclass of) NSPanel
containing an NSMatrix with NSButtonCell objects.
Now, when the user presses one of the NSButtonCells I want to open a
new NSPanel with the sub-choices for that button right below the
pressed button but I believe that in order to position the NSPanel I
will have to know the position of the button and I can't figure out
any better method for finding that position than letting the button
have a back reference to its containing view and its position in that
view and then ask the view for the screen coordinates when needed.
Or, is there a more direct method?
--
Kai-Mikael Jää-Aro <email@hidden>
Telestream AB Tel: +46 70 202 6494
Rådmansgatan 49 Skype: kaimikaeljaaaro
SE-113 60 Stockholm AIM: email@hidden
Sweden
_______________________________________________
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