1
0
mirror of https://github.com/TomHarte/CLK.git synced 2026-04-26 19:17:52 +00:00

Adds service requests. The microcontroller now appears to consume keyboard events.

This commit is contained in:
Thomas Harte
2021-02-15 20:33:10 -05:00
parent 2a45e7a8d4
commit e16d5f33d1
5 changed files with 40 additions and 7 deletions
+3
View File
@@ -132,6 +132,8 @@ bool Keyboard::set_key_pressed(Key key, bool is_pressed) {
}
#undef SetModifierBit
// Ensure service occurs.
post_service_request();
return true;
}
@@ -144,6 +146,7 @@ void Keyboard::clear_all_keys() {
pressed_keys_[key] = false;
}
}
if(!pending_events_.empty()) post_service_request();
// Mark all modifiers as released.
modifiers_ |= 0xfff8;