class
Eagle::MouseButtonEvent
- Eagle::MouseButtonEvent
- Eagle::Event
- Reference
- Object
Overview
A mouse button went down or up. #position is in window coordinates, and #clicks is
2 for a double-click.
Defined in:
eagle/core/events.crConstructors
-
.new(button : Eagle::MouseButton, pressed : Bool, position : Eagle::Vec2, clicks : Int32 = 1)
Creates a mouse button event.
Instance Method Summary
-
#button : MouseButton
Which mouse button.
-
#clicks : Int32
1 for a single click, 2 for a double-click.
-
#position : Vec2
Mouse position in window coordinates.
-
#pressed? : Bool
True for a press, false for a release.
-
#released? : Bool
True when the button was released.
Instance methods inherited from class Eagle::Event
handled=(handled : Bool)
handled=,
handled? : Bool
handled?
Constructor Detail
def self.new(button : Eagle::MouseButton, pressed : Bool, position : Eagle::Vec2, clicks : Int32 = 1)
#
Creates a mouse button event.