Commit Graph

28 Commits

Author SHA1 Message Date
Jonas Bark
0958a1cb0f fix potential crash 2026-02-07 09:56:35 +01:00
Jonas Bark
ad23d184d4 Android: simulate additional actions for local connection method (Left, Down, Right, Up, Down, Select, Back, Home, Recent Apps), allowing you to navigate in the trainer app, if supported 2026-01-17 13:52:27 +01:00
copilot-swe-agent[bot]
2c0364a4bd Add Android global actions support
Co-authored-by: jonasbark <1151304+jonasbark@users.noreply.github.com>
2026-01-17 12:06:48 +00:00
Jonas Bark
115a762c22 fix detection for hardware buttons when BikeControl is in foreground, change notification icon 2026-01-16 12:38:10 +01:00
Jonas Bark
d0f3bb7fa1 fix implementation 2026-01-12 18:42:54 +01:00
copilot-swe-agent[bot]
9d0b88d4fc Address code review feedback: memory leak and thread safety
- Store keymap update subscription to allow cancellation on re-init
- Fix List<String?> to List<String> in setHandledKeys signature
- Use ConcurrentHashMap.newKeySet() for thread-safe handledKeys access
- Clear and update the set instead of replacing it

Co-authored-by: jonasbark <1151304+jonasbark@users.noreply.github.com>
2026-01-12 16:52:22 +00:00
copilot-swe-agent[bot]
bbed6211d7 Change approach: Use keymap-based filtering for HID key events
- Add setHandledKeys API to pass list of keys with keymaps to Android side
- Android AccessibilityService checks if key is in handled keys set before swallowing
- Dart side updates handled keys list whenever keymap changes
- Remove hardcoded media/volume key filtering
- This allows keyboards to work for typing while still capturing mapped keys

Co-authored-by: jonasbark <1151304+jonasbark@users.noreply.github.com>
2026-01-12 16:49:19 +00:00
copilot-swe-agent[bot]
355e3ca3ec Fix Android accessibility service to only intercept media/volume keys
- Add isMediaOrVolumeKey() helper to filter key events by key code
- Only swallow media and volume keys (play/pause, next, volume up/down, etc.)
- Let all other keys (typing keys, navigation, etc.) pass through to the system
- This fixes Bluetooth keyboard interference when BikeControl is running

Co-authored-by: jonasbark <1151304+jonasbark@users.noreply.github.com>
2026-01-12 16:36:18 +00:00
Jonas Bark
0839322142 fix hid device functionality when accessibility service is active 2025-12-05 19:48:34 +01:00
Jonas Bark
d62591c376 status widget for accessibility service 2025-11-23 20:57:52 +00:00
Jonas Bark
835c305024 detect media key source - don't handle it when coming from phone #110 2025-11-08 22:31:12 +01:00
Jonas Bark
d6c198b0bd allow to ignore HID device input 2025-11-04 10:05:52 +01:00
Jonas Bark
743702f583 support HID key events on Android #110 2025-11-04 09:53:52 +01:00
Jonas Bark
7337f3ee75 Android: fix touches for very old Android versions 2025-10-19 08:55:15 +02:00
Jonas Bark
b4f592a10b fix delayed clicks in some apps 2025-10-02 21:05:15 +02:00
Jonas Bark
bda8111ed1 fix crashes on some Android devices 2025-09-27 12:18:50 +02:00
Jonas Bark
de19176b18 allow long touches / keyboard presses (fixes #61) 2025-09-08 14:01:28 +02:00
copilot-swe-agent[bot]
16d905e2b5 Refactor action method parameters from isPressed/isRepeated to isKeyDown/isKeyUp
Co-authored-by: jonasbark <1151304+jonasbark@users.noreply.github.com>
2025-09-07 10:18:20 +00:00
Jonas Bark
458c5f5286 Android: better approximation of button placement for freeform windows 2025-04-07 15:21:45 +02:00
Jonas Bark
07ff604042 Zwift Ride: add buttonPowerDown to shift gears
Zwift Play: Fix buttonShift assignment
Android: fix Media next button
2025-03-31 20:20:47 +02:00
Jonas Bark
86b6345d89 try to resolve https://github.com/jonasbark/swiftcontrol/issues/3#issuecomment-2763361122 2025-03-29 14:37:07 +01:00
Jonas Bark
296543f95e resolve https://github.com/jonasbark/swiftcontrol/issues/2 2025-03-29 12:53:27 +01:00
Jonas Bark
50fda1d9eb control media (Android only for now), add menu 2025-03-28 15:24:25 +01:00
Jonas Bark
5ed4865562 fix android window foreground issue 2025-03-27 19:57:34 +01:00
Jonas Bark
9c46cf67ca Android works 2025-03-27 18:17:25 +01:00
Jonas Bark
73bf894cd0 foreground notification on Android 2025-03-27 17:44:27 +01:00
Jonas Bark
c46253a77f accessibility implementation #2 2025-03-27 16:38:01 +01:00
Jonas Bark
e60c6a4707 accessibility implementation #1 2025-03-27 16:15:53 +01:00