MouseTrackListener interface.
Classes that wish to deal with MouseEvents which
occur as the mouse pointer passes (or hovers) over controls can
extend this class and override only the methods which they are
interested in.
An alternative to this class are the static helper methods
MouseTrackListener#mouseEnterAdapter(java.,
MouseTrackListener#mouseExitAdapter(java.
and
MouseTrackListener#mouseHoverAdapter(java.,
which accept a lambda expression or a method reference that implements the event consumer.
MouseTrackListener, MouseEvent, Sample code and further information
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | mouseEnter(MouseEvent
an event containing information about the mouse enter e)Implements org. |
| public void | mouseExit(MouseEvent
an event containing information about the mouse exit e)Implements org. |
| public void | mouseHover(MouseEvent
an event containing information about the hover e)Implements org. |
| MouseTrackAdapter | back to summary |
|---|---|
| public MouseTrackAdapter() | |
| mouseEnter | back to summary |
|---|---|
| public void mouseEnter(MouseEvent e) Implements org. Sent when the mouse pointer passes into the area of the screen covered by a control. The default behavior is to do nothing.
| |
| mouseExit | back to summary |
|---|---|
| public void mouseExit(MouseEvent e) Implements org. Sent when the mouse pointer passes out of the area of the screen covered by a control. The default behavior is to do nothing.
| |
| mouseHover | back to summary |
|---|---|
| public void mouseHover(MouseEvent e) Implements org. Sent when the mouse pointer hovers (that is, stops moving for an (operating system specified) period of time) over a control. The default behavior is to do nothing.
| |