Community
Participate
Eclipse IDE
In all Motif versions of SWT, the method Table.getItem(Point) does not work correctly if the index of the top item of the table is anything other than zero. Thus it does not work correctly if the table is scrolled down. The method will almost always return null. The bug is in the line: int index = (point.y - getHeaderHeight ()) / itemHeight - topIndex; The final minus sign should be a plus sign. The line should instead read: int index = (point.y - getHeaderHeight ()) / itemHeight + topIndex; The method works correctly on Windows. I have not tried GTK.
Fixed > 0718 in the motif/photon Table and Tree. Thanks for investigating the cause; I've added you to the contributors list. This seems like a candidate fix for 3.1.1.
committed changes to the 3.1.1 stream as well