From f1d2c2f2eb7598da7e7a76eba390a5bb53073d58 Mon Sep 17 00:00:00 2001 From: ponzischeme89 Date: Mon, 24 Aug 2026 07:29:23 +1200 Subject: [PATCH] 0.3.14 --- .../main/java/com/ponzischeme89/memby/ui/HomeScreen.kt | 1 + .../memby/ui/components/FocusScaleContainer.kt | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/com/ponzischeme89/memby/ui/HomeScreen.kt b/app/src/main/java/com/ponzischeme89/memby/ui/HomeScreen.kt index 8c9fbcf..562e25d 100644 --- a/app/src/main/java/com/ponzischeme89/memby/ui/HomeScreen.kt +++ b/app/src/main/java/com/ponzischeme89/memby/ui/HomeScreen.kt @@ -186,6 +186,7 @@ private val HomeLazyListPrefetchStrategy = LazyListPrefetchStrategy( nestedPrefetchItemCount = 1, ) +@OptIn(ExperimentalFoundationApi::class) private val LazyListStateMapSaver: Saver, Any> = listSaver( save = { states -> states.flatMap { (key, state) -> diff --git a/app/src/main/java/com/ponzischeme89/memby/ui/components/FocusScaleContainer.kt b/app/src/main/java/com/ponzischeme89/memby/ui/components/FocusScaleContainer.kt index 3905688..1b18a2f 100644 --- a/app/src/main/java/com/ponzischeme89/memby/ui/components/FocusScaleContainer.kt +++ b/app/src/main/java/com/ponzischeme89/memby/ui/components/FocusScaleContainer.kt @@ -12,7 +12,6 @@ import androidx.compose.foundation.background import androidx.compose.foundation.border import androidx.compose.foundation.clickable import androidx.compose.foundation.focusGroup -import androidx.compose.foundation.focusable import androidx.compose.foundation.Image import androidx.compose.foundation.layout.Arrangement import androidx.compose.foundation.layout.Box @@ -160,7 +159,13 @@ fun FocusScaleContainer( focused = it.isFocused if (it.isFocused) onFocused() } - .focusable() + // No explicit .focusable() here: remoteLongPress() always ends in + // Modifier.clickable(), which already installs its own focus target. Stacking + // a second one ahead of it split this element into two focus nodes — a + // FocusRequester (the hero's entry/return targets, the voice-search button) + // resolves to the outer bare node, which has no key handling, so a single OK + // press did nothing and the ring never lit until a touch/click forced real + // focus onto clickable's own inner node. // The hold, the swallowed repeats and the cancel-on-focus-loss are // [Modifier.remoteLongPress]'s — shared with the rail's user item, so the length // of press that opens a menu is the same wherever a menu can be opened.