mirror of
https://github.com/jonasbark/swiftcontrol.git
synced 2026-12-06 07:54:00 +01:00
Three things the first cut of right-side-only got wrong on a real phone. The left puck was held back by a setting rather than ignored, so it kept its entry in the device list and the active scan handed it straight back — an orphan stuck on "connecting" that never could. Filtering it out of controllerDevices fixed the onboarding list and missed the home chain, which also draws from offlineControllers. That is the argument against inventing a second mechanism: ignoring is the one the scan filter, the remembered-device loader and the device list all already honour, so using it takes the puck out of every list at once. The dedicated gate and the isExcludedBySetup filter are gone with it. Ignoring has to cover the remembered stand-in too, not just a live device — the chain lists both side by side, and the card in the report was a stand-in. It also has to be undoable, or picking "unlock with Zwift" after right-side-only silently still yields one controller. Removing the ignored entry is not enough on its own: the scanner dedupes against its cached advert, and performScanning() returns immediately while a scan is already running, so the puck only came back on the next launch. It now restarts the scan. Both lists showed "Zwift Click" for both pucks: `name` is the raw BLE advertised name, identical for the two. They use displayName, which carries the translated left/right suffix. Finally, the chain sat 24px in from each screen edge on mobile — Overview's scroll view pads it by 12 and HomePage added 12 of its own, before each card's padding on top. Desktop keeps its inset; there the chain sits in a centred max-width box with no padding of its own. Known sharp edge, left deliberately: un-ignoring the left puck by hand while still in right-side-only mode brings both up live, and the right side's handshake cancels the left's restart timer. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>