MCPcopy Create free account
hub / github.com/Hopson97/HopsonCraft / input

Method input

Source/GUI/Button.cpp:20–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18 }
19
20 void Button::input(const sf::Event& e)
21 {
22 if (touchingMouse(m_quad))
23 {
24 m_quad.setFillColor(sf::Color::Blue);
25 }
26 else
27 {
28 m_quad.setFillColor(sf::Color::White);
29 }
30
31 if(clicked(m_quad, e))
32 {
33 m_function();
34 }
35 }
36
37 void Button::update()
38 { }

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected