Hide settings rows whose key the aircraft cannot read

The Mavic Pro remote reports GIMBAL_CONTROL_SPEED_COEFFICIENT as supported but
fails every read, so "Gimbal dial speed" sat on "—" forever. The key bridge
now reports a failed seeding read, and the row hides like an unsupported one
until a value does arrive.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
tajniak81andClaude Opus 5.5 committed 2026-10-22 14:51:14 +02:00
1 parent a813648b75
commit e3917e6f25
4 files changed
+31 -2

No files matched your search

@@ -113,7 +113,11 @@ class KeyBridge(private val ctx: BridgeCtx) : SubBridge {
ctx.emit(mapOf("type" to "key", "id" to id, "value" to KeyValues.toDart(value)))
}
override fun onFailure(error: DJIError) = Unit
// Supported but unreadable (the Mavic Pro remote's gimbal dial
// speed): say so, or the row waits on "—" forever.
override fun onFailure(error: DJIError) {
ctx.emit(mapOf("type" to "key", "id" to id, "unreadable" to true))
}
})
result.success(id)
}