mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-12-05 20:45:43 +00:00
* Add RedMagic Air Triggers to the session's controller settings Controller > Device settings gets a "Redmagic Air Triggers" panel on RedMagic phones whose Game Space exposes its trigger provider. The toggle switches the shoulder triggers to plain F7/F8 keys through Game Space's exported TgkDataProvider (no permission, no trigger panel or markers), and each trigger presses a button of the active touch layout: LT and RT by default, or any button picked in the dropdowns, saved per layout. The triggers go back to their earlier state when the toggle is off, the session pauses or ends, or the app is killed mid-session (the next session start closes what this app opened). A distribute state another app turned on is left alone. * Show Air Trigger presses on screen and light the triggers A trigger now presses its button through the on-screen controls when that button is shown, so it shows as pressed and shares a toggle button's state with touches. A hidden button still gets the trigger's own input source. Game Space lights the triggers only from its own trigger view, through ColorfulLightManager, which apps cannot call. DroidDeck sends the same requestColorfulLight to the ColorfulLightService binder: the shoulder scene while the triggers are on, and the press/release lights the user's RedMagic lighting settings ask for. * Set the trigger light effect so the Air Trigger LEDs turn on RedMagic's light service writes no trigger light until a shoulder effect has been set, and only Game Space's own trigger view sets one. After entering the shoulder light scene, send the effect the user picked in RedMagic's lighting settings (selection in lighting_shoulder_config_json). * Cancel forced Air Trigger releases and close the triggers while paused A trigger press that DroidDeck ends itself (focus loss, the triggers closing, another button chosen mid-press) now cancels the button like a cancelled touch, so a command button such as the keyboard does not run. A toggle latched while its button was hidden is handed to the visible button on the next trigger press instead of staying held underneath it. The triggers also close while the session is paused and reopen when it resumes. * Keep an Air Trigger hold when a touch on the same button is cancelled A cancelled touch stream cleared every press of the button, including the Air Trigger still holding it, so the button let go while the trigger stayed down. Touch cancels now end only the finger presses. Releasing all input still clears the button completely. * Release Air Trigger-only button holds when all input is released Releasing all input only cancelled buttons a finger owned. A button held only by an Air Trigger kept its pressed state after its output was released, so it stayed lit and a finger on it did nothing until the trigger was lifted. A full release now cancels every button.