public final class MousePressedEvent extends Object implements IInputEvent, AutoCloseable
IInputEvent
that represents a mouse pressed.
This class contains the location, the mouse button and the modifiers if any.
Constructor and Description |
---|
MousePressedEvent(Coordinate location,
ModifierKeys modifierKeys,
MouseButton mouseButton)
Creates an event representing a mouse button being pressed.
|
Modifier and Type | Method and Description |
---|---|
void |
close() |
protected void |
finalize() |
Coordinate |
getLocation() |
ModifierKeys |
getModifierKeys() |
MouseButton |
getMouseButton() |
public MousePressedEvent(@NotNull Coordinate location, @NotNull ModifierKeys modifierKeys, @NotNull MouseButton mouseButton)
location
- The mouse location, defined in device independent pixels.modifierKeys
- The modifiers of the event.mouseButton
- The mouse button of the event.public void close()
close
in interface AutoCloseable
@NotNull public Coordinate getLocation()
@NotNull public ModifierKeys getModifierKeys()
@NotNull public MouseButton getMouseButton()