Button.cpp 490 B

12345678910111213141516171819202122232425262728
  1. /*
  2. * Author: Patrick-Christopher Mattulat
  3. * Company: Lynar Studios
  4. * E-Mail: webmaster@lynarstudios.com
  5. * Created: 2024-05-16
  6. * Changed: 2024-05-17
  7. *
  8. * */
  9. #include "Button.hpp"
  10. using ls::std::event::EventListener;
  11. using test::event::Button;
  12. Button::Button() : EventListener()
  13. {}
  14. Button::~Button() noexcept = default;
  15. bool Button::isClicked() const
  16. {
  17. return this->clicked;
  18. }
  19. void Button::onClickEvent()
  20. {
  21. this->clicked = !this->clicked;
  22. }