fix(input): discard queued chords on disconnect (#1632)

This commit is contained in:
Kurt Himebauch authored and GitHub committed 2026-10-26 15:31:51 -04:00
1 parent 13eb291ba8
commit b3561bf658
2 files changed
+65 -3

No files matched your search

@@ -692,7 +692,9 @@ public final class PadBridge {
slotJoyCons.set(slot * 2 + side, id);
slotJoyCons.set(slot * 2 + 1 - side, owner.getId());
if (slot == firstPlayerSlot()) releaseBackPaddles();
if (slot == 0) clearBackQamWrites();
stateFor(slot).clear();
if (slot == 0) publish();
Log.i(TAG, "\"" + device.getName() + "\" (id " + id + ") joins \"" + owner.getName() + "\" as player " + (slot + 1));
return slot;
}
@@ -727,6 +729,7 @@ public final class PadBridge {
}
private void leave(int slot, int id) {
if (slot == 0) clearBackQamWrites();
if (partners[slot] == NO_CONTROLLER) {
free(slot);
return;