Uses of Class
java.awt.event.MouseEvent
-
Packages that use MouseEvent 软件包 描述 java.awt 包含用于创建用户界面和绘制图形和图像的所有类。java.awt.dnd 拖放是在许多图形用户界面系统中发现的直接操纵手势,其提供了在GUI中与表示元素逻辑相关联的两个实体之间传递信息的机制。java.awt.event 提供用于处理AWT组件触发的不同类型事件的接口和类。javax.swing 提供一组“轻量级”(全Java语言)组件,这些组件在所有平台上尽可能地工作。javax.swing.event 提供由Swing组件触发的事件。javax.swing.plaf 提供一个接口和许多抽象类,Swing使用它们来提供其可插入的外观功能。javax.swing.plaf.basic 提供根据Basic外观构建的用户界面对象。javax.swing.plaf.multi 提供组合两种或多种外观的用户界面对象。javax.swing.table 提供用于处理javax.swing.JTable
类和接口。javax.swing.text 提供处理可编辑和不可编辑文本组件的类和接口。javax.swing.text.html 提供类HTMLEditorKit
和用于创建HTML文本编辑器的支持类。 -
-
Uses of MouseEvent in java.awt
Methods in java.awt with parameters of type MouseEvent 变量和类型 方法 描述 void
AWTEventMulticaster. mouseClicked(MouseEvent e)
通过在侦听器-a和侦听器-b上调用mouseClicked方法处理mouseClicked事件。void
AWTEventMulticaster. mouseDragged(MouseEvent e)
通过在侦听器-a和侦听器-b上调用mouseDragged方法处理mouseDragged事件。void
AWTEventMulticaster. mouseEntered(MouseEvent e)
通过在侦听器-a和侦听器-b上调用mouseEntered方法处理mouseEntered事件。void
AWTEventMulticaster. mouseExited(MouseEvent e)
通过在侦听器-a和侦听器-b上调用mouseExited方法处理mouseExited事件。void
AWTEventMulticaster. mouseMoved(MouseEvent e)
通过在侦听器-a和侦听器-b上调用mouseMoved方法处理mouseMoved事件。void
AWTEventMulticaster. mousePressed(MouseEvent e)
通过在侦听器-a和侦听器-b上调用mousePressed方法处理mousePressed事件。void
AWTEventMulticaster. mouseReleased(MouseEvent e)
通过在侦听器-a和侦听器-b上调用mouseReleased方法处理mouseReleased事件。protected void
Component. processMouseEvent(MouseEvent e)
处理在此组件上发生的鼠标事件,方法是将它们分派给任何已注册的MouseListener
对象。protected void
Component. processMouseMotionEvent(MouseEvent e)
处理在此组件上发生的鼠标移动事件,方法是将它们分派给任何已注册的MouseMotionListener
对象。 -
Uses of MouseEvent in java.awt.dnd
Methods in java.awt.dnd with parameters of type MouseEvent 变量和类型 方法 描述 void
MouseDragGestureRecognizer. mouseClicked(MouseEvent e)
在组件上单击鼠标时调用。void
MouseDragGestureRecognizer. mouseDragged(MouseEvent e)
在组件上按下鼠标按钮时调用。void
MouseDragGestureRecognizer. mouseEntered(MouseEvent e)
鼠标进入组件时调用。void
MouseDragGestureRecognizer. mouseExited(MouseEvent e)
鼠标退出组件时调用。void
MouseDragGestureRecognizer. mouseMoved(MouseEvent e)
在组件上移动鼠标按钮时调用(没有按钮没有向下)。void
MouseDragGestureRecognizer. mousePressed(MouseEvent e)
在Component
上按下鼠标按钮时调用。void
MouseDragGestureRecognizer. mouseReleased(MouseEvent e)
在组件上释放鼠标按钮时调用。 -
Uses of MouseEvent in java.awt.event
Subclasses of MouseEvent in java.awt.event 变量和类型 类 描述 class
MouseWheelEvent
指示鼠标滚轮在组件中旋转的事件。Methods in java.awt.event with parameters of type MouseEvent 变量和类型 方法 描述 void
MouseListener. mouseClicked(MouseEvent e)
在组件上单击(按下并释放)鼠标按钮时调用。void
MouseAdapter. mouseDragged(MouseEvent e)
在组件上按下鼠标按钮然后拖动时调用。void
MouseMotionAdapter. mouseDragged(MouseEvent e)
在组件上按下鼠标按钮然后拖动时调用。void
MouseMotionListener. mouseDragged(MouseEvent e)
在组件上按下鼠标按钮然后拖动时调用。void
MouseListener. mouseEntered(MouseEvent e)
鼠标进入组件时调用。void
MouseListener. mouseExited(MouseEvent e)
鼠标退出组件时调用。void
MouseAdapter. mouseMoved(MouseEvent e)
将鼠标光标移动到组件但未按下任何按钮时调用。void
MouseMotionAdapter. mouseMoved(MouseEvent e)
在组件上移动鼠标按钮时调用(没有按钮没有向下)。void
MouseMotionListener. mouseMoved(MouseEvent e)
将鼠标光标移动到组件但未按下任何按钮时调用。void
MouseListener. mousePressed(MouseEvent e)
在组件上按下鼠标按钮时调用。void
MouseListener. mouseReleased(MouseEvent e)
在组件上释放鼠标按钮时调用。 -
Uses of MouseEvent in javax.swing
Methods in javax.swing that return MouseEvent 变量和类型 方法 描述 static MouseEvent
SwingUtilities. convertMouseEvent(Component source, MouseEvent sourceEvent, Component destination)
返回类似于sourceEvent
的MouseEvent,但其x和y成员已转换为destination
的坐标系。Methods in javax.swing with parameters of type MouseEvent 变量和类型 方法 描述 static MouseEvent
SwingUtilities. convertMouseEvent(Component source, MouseEvent sourceEvent, Component destination)
返回类似于sourceEvent
的MouseEvent,但其x和y成员已转换为destination
的坐标系。Point
JComponent. getPopupLocation(MouseEvent event)
返回在此组件的坐标系中显示弹出菜单的首选位置。Point
JComponent. getToolTipLocation(MouseEvent event)
返回此组件坐标系中的工具提示位置。String
JComponent. getToolTipText(MouseEvent event)
返回要用作 事件工具提示的字符串。String
JList. getToolTipText(MouseEvent event)
返回要用于给定事件的工具提示文本。String
JTabbedPane. getToolTipText(MouseEvent event)
返回由鼠标事件位置确定的组件的工具提示文本。String
JTable. getToolTipText(MouseEvent event)
覆盖JComponent
的getToolTipText
方法,以便在具有文本集的情况下允许使用渲染器的提示。String
JTree. getToolTipText(MouseEvent event)
覆盖JComponent
的getToolTipText
方法,以便在具有文本集的情况下允许使用渲染器的提示。static boolean
SwingUtilities. isLeftMouseButton(MouseEvent anEvent)
如果鼠标事件指定鼠标左键,则返回true。static boolean
SwingUtilities. isMiddleMouseButton(MouseEvent anEvent)
如果鼠标事件指定鼠标中键,则返回true。boolean
JPopupMenu. isPopupTrigger(MouseEvent e)
如果MouseEvent
被JPopupMenu
当前安装的UI视为弹出触发器,则返回true。static boolean
SwingUtilities. isRightMouseButton(MouseEvent anEvent)
如果鼠标事件指定鼠标右键,则返回true。void
ToolTipManager. mouseDragged(MouseEvent event)
按下并拖动鼠标时调用。void
ToolTipManager. mouseEntered(MouseEvent event)
当鼠标进入组件区域时调用。void
ToolTipManager. mouseExited(MouseEvent event)
当鼠标退出组件区域时调用。void
ToolTipManager. mouseMoved(MouseEvent event)
移动鼠标时调用。void
ToolTipManager. mousePressed(MouseEvent event)
按下鼠标时调用。protected void
JComponent. processMouseEvent(MouseEvent e)
处理在此组件上发生的鼠标事件,方法是将它们分派给任何已注册的MouseListener
对象,有关此方法的完整说明,请参阅Component.processMouseEvent(MouseEvent)
。void
JMenuBar. processMouseEvent(MouseEvent event, MenuElement[] path, MenuSelectionManager manager)
实施为MenuElement
- 什么都不做。void
JMenuItem. processMouseEvent(MouseEvent e, MenuElement[] path, MenuSelectionManager manager)
处理从MenuSelectionManager
转发的鼠标事件,并根据需要使用MenuSelectionManager
的API更改菜单选择。void
JPopupMenu. processMouseEvent(MouseEvent event, MenuElement[] path, MenuSelectionManager manager)
此方法需要符合MenuElement
接口,但未实现。void
MenuElement. processMouseEvent(MouseEvent event, MenuElement[] path, MenuSelectionManager manager)
处理鼠标事件。void
MenuSelectionManager. processMouseEvent(MouseEvent event)
当MenuElement从MouseListener接收事件时,它永远不应该直接处理事件。protected void
JComponent. processMouseMotionEvent(MouseEvent e)
处理鼠标移动事件,例如MouseEvent.MOUSE_DRAGGED。 -
Uses of MouseEvent in javax.swing.event
Subclasses of MouseEvent in javax.swing.event 变量和类型 类 描述 class
MenuDragMouseEvent
MenuDragMouseEvent用于通知感兴趣的各方菜单元素在拖动条件下已收到转发给它的MouseEvent。 -
Uses of MouseEvent in javax.swing.plaf
Methods in javax.swing.plaf with parameters of type MouseEvent 变量和类型 方法 描述 boolean
PopupMenuUI. isPopupTrigger(MouseEvent e)
返回给定的MouseEvent
是否为平台的弹出菜单触发事件protected void
LayerUI. processMouseEvent(MouseEvent e, JLayer<? extends V> l)
处理JLayer
或其任何子组件上发生的鼠标事件。protected void
LayerUI. processMouseMotionEvent(MouseEvent e, JLayer<? extends V> l)
处理JLayer
或其任何子组件上发生的鼠标移动事件。 -
Uses of MouseEvent in javax.swing.plaf.basic
Methods in javax.swing.plaf.basic that return MouseEvent 变量和类型 方法 描述 protected MouseEvent
BasicComboPopup. convertMouseEvent(MouseEvent e)
转换鼠标事件。Methods in javax.swing.plaf.basic with parameters of type MouseEvent 变量和类型 方法 描述 protected void
BasicSplitPaneDivider.DragController. completeDrag(MouseEvent e)
消息finishDraggingTo与鼠标事件的新位置。protected void
BasicSplitPaneDivider.DragController. continueDrag(MouseEvent e)
消息dragDividerTo具有鼠标事件的新位置。protected MouseEvent
BasicComboPopup. convertMouseEvent(MouseEvent e)
转换鼠标事件。protected void
BasicComboPopup. delegateFocus(MouseEvent e)
这是一种实用程序方法,可帮助事件处理程序找出弹出窗口时发送焦点的位置。protected boolean
BasicTreeUI. isMultiSelectEvent(MouseEvent event)
返回true
表示节点上的鼠标事件应从锚点中选择。protected boolean
BasicTreeUI. isToggleEvent(MouseEvent event)
返回true
表示应根据事件切换鼠标下的行。protected boolean
BasicTreeUI. isToggleSelectionEvent(MouseEvent event)
返回true
表示节点上的鼠标事件应切换仅鼠标下行的选择。void
BasicMenuUI.MouseInputHandler. mouseDragged(MouseEvent e)
在菜单上按下鼠标按钮然后拖动时调用。void
BasicScrollBarUI.TrackListener. mouseDragged(MouseEvent e)
将模型值设置为垂直滚动条的拇指顶部的位置,或者相对于轨道原点从左到右/从右到左滚动条的水平滚动条的左/右。void
BasicSliderUI.TrackListener. mouseDragged(MouseEvent e)
将模型值设置为拇指顶部/左侧相对于轨道原点的位置。void
BasicSplitPaneDivider.MouseHandler. mouseDragged(MouseEvent e)
如果dragger不为null,则使用continueDrag发送消息。void
BasicFileChooserUI.DoubleClickListener. mouseEntered(MouseEvent e)
用于表示文件的JList由子类创建,但在此类中监视选择。void
BasicMenuUI.MouseInputHandler. mouseEntered(MouseEvent e)
光标进入菜单时调用。void
BasicSplitPaneDivider.MouseHandler. mouseEntered(MouseEvent e)
鼠标进入组件时调用。void
BasicScrollBarUI.TrackListener. mouseExited(MouseEvent e)
鼠标退出滚动条时调用。void
BasicSplitPaneDivider.MouseHandler. mouseExited(MouseEvent e)
鼠标退出组件时调用。void
BasicSplitPaneDivider.MouseHandler. mouseMoved(MouseEvent e)
根据方向重置光标。void
BasicTreeUI.MouseHandler. mouseMoved(MouseEvent e)
在组件上移动鼠标按钮时调用(没有按钮没有向下)。void
BasicComboPopup.InvocationMouseHandler. mousePressed(MouseEvent e)
响应组合框上的鼠标按下事件。void
BasicMenuUI.MouseInputHandler. mousePressed(MouseEvent e)
在菜单上单击鼠标时调用。void
BasicScrollBarUI.TrackListener. mousePressed(MouseEvent e)
如果将鼠标按在“拇指”组件上方,则将滚动条值减少一页(“向上翻页”),否则将其增加一页。void
BasicSliderUI.TrackListener. mousePressed(MouseEvent e)
如果将鼠标按在“拇指”组件上方,则将滚动条值减少一页(“向上翻页”),否则将其增加一页。void
BasicSplitPaneDivider.MouseHandler. mousePressed(MouseEvent e)
通过创建DragController的相应实例来启动拖动会话。void
BasicTreeUI.MouseHandler. mousePressed(MouseEvent e)
在组件上按下鼠标按钮时调用。void
BasicComboPopup.InvocationMouseHandler. mouseReleased(MouseEvent e)
响应用户终止在组合框上开始的单击或拖动。void
BasicMenuUI.MouseInputHandler. mouseReleased(MouseEvent e)
在菜单上释放鼠标时调用。void
BasicSplitPaneDivider.MouseHandler. mouseReleased(MouseEvent e)
如果dragger不为null,则使用completeDrag进行消息传递。protected int
BasicSplitPaneDivider.DragController. positionForMouseEvent(MouseEvent e)
返回基于传入的MouseEvent将分隔符置于的新位置。protected int
BasicSplitPaneDivider.VerticalDragController. positionForMouseEvent(MouseEvent e)
返回基于传入的MouseEvent将分隔符置于的新位置。void
BasicCheckBoxMenuItemUI. processMouseEvent(JMenuItem item, MouseEvent e, MenuElement[] path, MenuSelectionManager manager)
发生鼠标事件时调用。void
BasicRadioButtonMenuItemUI. processMouseEvent(JMenuItem item, MouseEvent e, MenuElement[] path, MenuSelectionManager manager)
发生鼠标事件时调用。protected void
BasicTreeUI. selectPathForEvent(TreePath path, MouseEvent event)
消息传递以在特定行上基于MouseEvent
更新选择。protected boolean
BasicTreeUI. startEditing(TreePath path, MouseEvent event)
如果有cellEditor
并且shouldSelectCell
返回true
将开始编辑节点。protected void
BasicComboPopup. updateListBoxSelectionForEvent(MouseEvent anEvent, boolean shouldScroll)
事件侦听器使用的实用程序方法。Constructors in javax.swing.plaf.basic with parameters of type MouseEvent 构造器 描述 DragController(MouseEvent e)
构造一个DragController
的新实例。MouseInputHandler(Component source, Component destination, MouseEvent event)
构造一个MouseInputHandler
的新实例。VerticalDragController(MouseEvent e)
构造一个VerticalDragController
的新实例。 -
Uses of MouseEvent in javax.swing.plaf.multi
Methods in javax.swing.plaf.multi with parameters of type MouseEvent 变量和类型 方法 描述 boolean
MultiPopupMenuUI. isPopupTrigger(MouseEvent a)
在由此对象处理的每个UI上调用isPopupTrigger
方法。 -
Uses of MouseEvent in javax.swing.table
Methods in javax.swing.table with parameters of type MouseEvent 变量和类型 方法 描述 String
JTableHeader. getToolTipText(MouseEvent event)
如果有文本集,则允许使用渲染器的提示。 -
Uses of MouseEvent in javax.swing.text
Methods in javax.swing.text with parameters of type MouseEvent 变量和类型 方法 描述 String
JTextComponent. getToolTipText(MouseEvent event)
返回用作event
的工具提示的event
。void
DefaultCaret. mouseClicked(MouseEvent e)
单击鼠标时调用。void
DefaultCaret. mouseDragged(MouseEvent e)
根据鼠标指针的当前位置移动插入位置。void
DefaultCaret. mouseEntered(MouseEvent e)
鼠标进入某个区域时调用。void
DefaultCaret. mouseExited(MouseEvent e)
当鼠标退出某个区域时调用。void
DefaultCaret. mouseMoved(MouseEvent e)
移动鼠标时调用。void
DefaultCaret. mousePressed(MouseEvent e)
如果按下按钮1,则执行此操作以请求关注相关文本组件,并设置插入符号位置。void
DefaultCaret. mouseReleased(MouseEvent e)
释放鼠标时调用。protected void
DefaultCaret. moveCaret(MouseEvent e)
尝试使用viewToModel()从鼠标事件的坐标移动插入符的位置。protected void
DefaultCaret. positionCaret(MouseEvent e)
尝试使用viewToModel()从鼠标事件的坐标设置插入符的位置。 -
Uses of MouseEvent in javax.swing.text.html
Methods in javax.swing.text.html with parameters of type MouseEvent 变量和类型 方法 描述 void
HTMLEditorKit.LinkController. mouseClicked(MouseEvent e)
被称为鼠标点击事件。
-