I have a JTable in a JScrollPane. When the user is at the top of the table, eg. row 0 is displayed and above it the table header tableHeader.contains(p);
is true
.
When the user scroll down and say row 10 is now the top row, if the mouse is over the table header and the table header changes its look due to that, tableHeader.contains(p);
is false
in all cases.
How can I detect that the mouse cursor is over the header when the top row is not row 0?