MCPcopy Create free account
hub / github.com/IppClub/Dora-SSR / clearChanges

Method clearChanges

Source/Input/Keyboard.cpp:180–192  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

178}
179
180void Keyboard::clearChanges() {
181 if (!_changedKeys.empty()) {
182 for (auto symKey : _changedKeys) {
183 if ((symKey & SDLK_SCANCODE_MASK) != 0) {
184 uint32_t code = s_cast<uint32_t>(symKey) & ~SDLK_SCANCODE_MASK;
185 _oldCodeStates[code] = _newCodeStates[code];
186 } else {
187 _oldKeyStates[symKey] = _newKeyStates[symKey];
188 }
189 }
190 _changedKeys.clear();
191 }
192}
193
194void Keyboard::attachIME(const KeyboardHandler& handler) {
195 if (_imeHandler) {

Callers 1

doLogicMethod · 0.45

Calls 2

clearMethod · 0.65
emptyMethod · 0.45

Tested by

no test coverage detected