New topic: How to convert (x,y) to (row,column) in ListBox?
<http://forums.realsoftware.com/viewtopic.php?t=27616> Page 1 of 1 [ 1 post ] Previous topic | Next topic Author Message Bessie Post subject: How to convert (x,y) to (row,column) in ListBox?Posted: Sat Apr 18, 2009 6:03 am Joined: Tue Mar 17, 2009 8:53 am Posts: 335 I'm implementing ListBox.ConstructContextualMenu. I get given x and y, the pixel coordinates of the mouse pointer, presumably relative to the ListBox. However, what I want to know is, what cell got clicked on, so that I can dynamically put the right things in the context menu, and then copy the cell's CellTag property into the MenuItem's Tag property. Since the handler for ContextualMenuAction gives you only the MenuItem, then presumably the correct way to figure out what what cell was clicked on at ContextualMenuAction-time is to examine MenuItem.Tag, assuming that you filled it in during ConstructContextualMenu-time? Am I going about this the right way, or am I missing something? _________________ No thanks, I don't want to buy any plugins. Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 1 post ] -- Over 900 classes with 18000 functions in one REALbasic plug-in. The Monkeybread Software Realbasic Plugin v8.1. <http://www.monkeybreadsoftware.de/realbasic/plugins.shtml> [email protected]
