In this activity we use a mouse listener and a key listener.
You are asked to write an application which will display a window capable of detecting when the mouse pointer is over it.
The window should be a frame of dimensions 400 by 100, located at (100, 100), on which is placed a JTextField field. The frame title should be "Mouse sensor". When the program is first run the text field should show the message "Waiting for mouse activity".
A mouse listener is attached to the text field. If the mouse pointer moves over the text field (mouse entered) the listener should cause the message to change.
If the mouse pointer leaves the text field (mouse exited) the listener should recognise this.
A key listener is also attached to the text field. When Enter is pressed this listener should reset the message.