Fix activity bleeding

This commit is contained in:
jpirnay
2026-04-13 10:54:21 +02:00
parent d2d923a233
commit 783c0c1e9b
2 changed files with 34 additions and 1 deletions
+6
View File
@@ -62,6 +62,12 @@ class ActivityManager {
// This variable must only be set by the main loop, to avoid race conditions
bool requestedUpdate = false;
// When true, input events are consumed (discarded) until all buttons are released
// and no press/release events remain. Armed automatically on activity transitions
// (push / pop / replace) so that the button used to leave one activity cannot bleed
// into the next one.
bool drainInput = false;
public:
explicit ActivityManager(GfxRenderer& renderer, MappedInputManager& mappedInput)
: renderer(renderer), mappedInput(mappedInput), renderingMutex(xSemaphoreCreateMutex()) {