spark list selected item coordinates
I have a list with custom item renderers. What I would like is when one of the list items is selected to position another control OUTSIDE the list to the sa开发者_运维知识库me vertical position as the selected item. Thoughts?
USe the itemClick event to get a reference to the itemRenderer that was clicked; and from there you can get the X and Y properties.
In a Spark List, you can probably do something using the click event, although the itemRenderer is note explicitly exposed; but I think the target property may give you a hook to the itemRenderer.
If all else fails, you could have your custom itemRenderer dispatch it's own event which includes the global X and Y positions.
This thread has some code samples that demonstrate how to do something like this: http://forums.adobe.com/message/2539545#2539545
精彩评论