Infralution Support Forum Index Infralution Support
Support groups for Infralution products
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Get Hovered item

 
Post new topic   Reply to topic    Infralution Support Forum Index -> Virtual Tree Support
View previous topic :: View next topic  
Author Message
Hvid
Guest





PostPosted: Fri Jun 30, 2006 8:35 am    Post subject: Get Hovered item Reply with quote

Hi.

I've attachead a System.Windows.Forms.ToolTip component to my TreeListView.

The size of this tooltip is defined by the object the hovered node is databinded against.

Therefore, I need some way of getting access to the node that is hovered excactly when the Popup method of my ToolTip is raised. Only this way can I correctly calculate the size of my ToolTip and display it in the correct size.

Is there any way of getting the currently hovered node in the TreeView? I'm guessing that you're already calling Show on the ToolTip when this happens.

Rgds.
Jesper
Back to top
Guest






PostPosted: Fri Jun 30, 2006 8:38 am    Post subject: Reply with quote

*Note

I'm using the 3.0.0.0 version of the VirtualTree. I have no idea why my brain wanted me to enter TreeListView instead. Smile
Back to top
Infralution



Joined: 28 Feb 2005
Posts: 5027

PostPosted: Sat Jul 01, 2006 12:36 am    Post subject: Reply with quote

Try calling VirtualTree.GetWidget(x, y) where x and y are the current mouse position. If you are over a cell this will return a CellWidget. From there you can get the Row the cell is assocatied with. Row.Item gives you the item the row is bound to or CellWidget.CellData.Value gives you the value the cell is bound to.
_________________
Infralution Support
Back to top
View user's profile Send private message Visit poster's website
Hvid
Guest





PostPosted: Thu Jul 06, 2006 8:51 am    Post subject: Reply with quote

That did the trick Smile

Thanks a lot for your help.
Back to top
Display posts from previous:   
Post new topic   Reply to topic    Infralution Support Forum Index -> Virtual Tree Support All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group