NRE::Event::ButtonEvent Class Reference

Manage a button event. More...

#include <NRE_ButtonEvent.hpp>

Public Member Functions

 ButtonEvent ()=delete
 
 ButtonEvent (ButtonCode c, Math::Point2D< unsigned int > const &pos)
 
 ButtonEvent (ButtonEvent const &e)=default
 
 ButtonEvent (ButtonEvent &&e)=default
 
 ~ButtonEvent ()=default
 
ButtonCode getCode () const
 
Math::Point2D< unsigned int > const & getPosition () const
 
bool isCode (ButtonCode c) const
 
ButtonEventoperator= (ButtonEvent const &e)=default
 
ButtonEventoperator= (ButtonEvent &&e)=default
 
bool operator== (ButtonEvent const &e) const
 

Detailed Description

Manage a button event.

Constructor & Destructor Documentation

NRE::Event::ButtonEvent::ButtonEvent ( )
delete

Default constructor

NRE::Event::ButtonEvent::ButtonEvent ( ButtonCode  c,
Math::Point2D< unsigned int > const &  pos 
)

Construct the event

Parameters
cthe button code
posthe curosr position
NRE::Event::ButtonEvent::ButtonEvent ( ButtonEvent const &  e)
default

Copy e into this

Parameters
ethe button event to copy
NRE::Event::ButtonEvent::ButtonEvent ( ButtonEvent &&  e)
default

Move e into this

Parameters
ethe button event to move
NRE::Event::ButtonEvent::~ButtonEvent ( )
default

ButtonEvent Deconstructor

Member Function Documentation

ButtonCode NRE::Event::ButtonEvent::getCode ( ) const
inline
Returns
the button's code
Math::Point2D<unsigned int> const& NRE::Event::ButtonEvent::getPosition ( ) const
inline
Returns
the cursor position
bool NRE::Event::ButtonEvent::isCode ( ButtonCode  c) const
inline

Compare the event code to the given one

Parameters
ca button code
Returns
the test's result
ButtonEvent& NRE::Event::ButtonEvent::operator= ( ButtonEvent const &  e)
default

Copy e into this

Parameters
ethe object to copy into this
Returns
the reference of himself
ButtonEvent& NRE::Event::ButtonEvent::operator= ( ButtonEvent &&  e)
default

Copy e into this

Parameters
ethe object to copy into this
Returns
the reference of himself
bool NRE::Event::ButtonEvent::operator== ( ButtonEvent const &  e) const

Equality test between this and an object

Parameters
ethe other object
Returns
the test result

The documentation for this class was generated from the following file:
  • /mnt/c/Users/abell/Documents/GitHub/NRE-System/src/System/Event/Event/Button/NRE_ButtonEvent.hpp