MCPcopy Create free account
hub / github.com/SFML/SFML / WindowImpl

Method WindowImpl

src/SFML/Window/WindowImpl.cpp:169–182  ·  view source on GitHub ↗

///////////////////////////////////////////////////////

Source from the content-addressed store, hash-verified

167
168////////////////////////////////////////////////////////////
169WindowImpl::WindowImpl() : m_joystickStatesImpl(std::make_unique<JoystickStatesImpl>())
170{
171 // Get the initial joystick states
172 JoystickManager::getInstance().update();
173 for (unsigned int i = 0; i < Joystick::Count; ++i)
174 {
175 m_joystickStatesImpl->states[i] = JoystickManager::getInstance().getState(i);
176 m_previousAxes[i].fill(0.f);
177 }
178
179 // Get the initial sensor states
180 for (Vector3f& vec : m_sensorValue)
181 vec = Vector3f(0, 0, 0);
182}
183
184
185////////////////////////////////////////////////////////////

Callers

nothing calls this directly

Calls 1

updateMethod · 0.45

Tested by

no test coverage detected