SWING MouseMotionEvent事件处理
接口MouseMotionEvent指示组件中发生鼠标动作。这种低层次的事件所产生的一个组件对象时,拖动鼠标或移动。
类声明
以下是声明 java.awt.event.MouseMotionEvent类:
public class MouseMotionEvent extends InputEvent
接口方法
S.N. | 方法 & 描述 |
---|---|
1 |
void mouseDragged(MouseEvent e) Invoked when a mouse button is pressed on a component and then dragged. |
2 |
void mouseMoved(MouseEvent e) Invoked when the mouse cursor has been moved onto a component but no buttons have been pushed. |
方法继承
这个接口继承的方法从以下类别:
-
java.awt.event.InputEvent
-
java.awt.event.ComponentEvent
-
java.awt.AWTEvent
-
java.util.EventObject
-
java.lang.Object