CUGL 2.3
Cornell University Game Library
No Matches
Public Member Functions | Public Attributes | List of all members
cugl::MouseEvent Class Reference

#include <CUMouse.h>

Public Member Functions

 MouseEvent ()
 MouseEvent (Uint32 state, const Vec2 point, const Timestamp &stamp)

Public Attributes

Timestamp timestamp
ButtonState buttons
Vec2 position

Detailed Description

This simple class is a struct to hold mouse event information

Constructor & Destructor Documentation

◆ MouseEvent() [1/2]

cugl::MouseEvent::MouseEvent ( )

Constructs a new mouse event with the default values

◆ MouseEvent() [2/2]

cugl::MouseEvent::MouseEvent ( Uint32  state,
const Vec2  point,
const Timestamp stamp 

Constructs a new mouse event with the given values

stateThe state of the button set
pointThe current mouse position
stampThe timestamp for the event

Member Data Documentation

◆ buttons

ButtonState cugl::MouseEvent::buttons

The current button set; meaning depends on the event

◆ position

Vec2 cugl::MouseEvent::position

The current mouse position in screen coordinates

◆ timestamp

Timestamp cugl::MouseEvent::timestamp

The time of the mouse event

The documentation for this class was generated from the following file: