I would like to capture mouse enter/exit events for a SWT Table cell.
I've seen, and implemented, examples that capture mouse hover and mouse
move events, but this doesn't quite do what I need.
My goal is change the color on another control when a user moves the mouse
over a particular table cell. E.g., in pseudocode:
public void handleEvent(Event event)
{
switch (event.type)
{
case SWT.MouseEnter:
TableItem item = tableViewer.getTable().getItem(new Point(event.x,
event.y));
if (item == myItem)
{
widget.redraw(red);
Display.getCurrent().update();
}
else
{
widget.redraw(black);
Display.getCurrent().update();
...
}
Could anyone suggest a way for me to accomplish this?