The attached code will set focus to grid cell on right-click of that cell. The xyToCell method converts mouse position to grid row, col.
gridExample.py (1.44 KB)
···
----- Original Message ----- From: "Milen Dzhumerov" <gamehack@1nsp1r3d.co.uk>
To: <wxPython-users@lists.wxwidgets.org>
Sent: Monday, January 24, 2005 2:32 PM
Subject: [wxPython-users] wxGrid
Hi list,
I've done pretty much my app I'm only doing some finishing touches. And today I encountered a problem with wxGrid. When I use the right click event and click some other cell it doesn't focus the right clicked cell and GetGridCursorRow() gives me the focused cell on init. If I use the left click event when I click another cell it doesn't get the focus... so is there a way I can get the col/row coordinates when I'm just right-clicking on a cell?
Thank you very much,
gamehack---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org