fix: release panel touch source after tab teardown

Release the panel touch source after child detach callbacks finish publishing button releases. Cover tab switching and whole-panel removal with ownership regressions.

Validation: 22 targeted JVM tests, debug APK build, session-asset check and runtime-input verification passed. Device validation remains pending.
This commit is contained in:
Delete228 committed 2026-10-24 13:43:09 +03:00
1 parent 884671a065
commit 5ee3ed07be
3 files changed
+59 -1

No files matched your search

@@ -151,7 +151,6 @@ class DeckControlsPanel(
private fun select(tab: Tab) {
if (pad != null) selectedWithPad = tab else selected = tab
deckSource.release()
pad?.releaseTouch(this)
for ((each, view) in tabViews) {
val on = each == tab
view.background = if (on) filled(CORNER_PILL, ACCENT) else null
@@ -169,6 +168,7 @@ class DeckControlsPanel(
}
}
content.removeAllViews()
pad?.releaseTouch(this)
topBar.visibility = if (tab == Tab.GAMEPAD) View.GONE else View.VISIBLE
content.addView(
when (tab) {