Experimental: this API is experimental and might be changed or removed in the future.

IMouseEvent

interface in UnityEngine.Experimental.UIElements

切换到手册

描述

鼠标事件接口。

变量

altKey如果按下 Alt 键,则返回 true。
button表示按下的鼠标按钮的整数。0 为左侧,1 为右侧,2 为中间。
clickCount单击次数。
commandKey如果按下 Windows/Command 键,则返回 true。
ctrlKey如果按下 Control 键,则返回 true。
localMousePosition当前目标坐标系中的鼠标位置。
modifiers标志集,用于保存所按修改键(Alt、Control、Shift、Windows/Command)。
mouseDelta上次鼠标事件与这次鼠标事件之间的鼠标位置差别。
mousePosition面板坐标系中的鼠标位置。
shiftKey如果按下 Shift 键,则返回 true。