Status Update
Comments
lp...@google.com <lp...@google.com>
dm...@gmail.com <dm...@gmail.com> #2
Thanks! This looks like a bug, thank you for reporting!
kl...@google.com <kl...@google.com> #3
Dragging up to 10% or between 50% and 90% will cause it to snap back to the start anchor.
Dragging between 10% and 50% or past 90% will cause it to snap to the end anchor.
kl...@google.com <kl...@google.com> #4
kl...@google.com <kl...@google.com>
m....@anfe.ma <m....@anfe.ma> #5
ap...@google.com <ap...@google.com> #6
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.compose.foundation:foundation:1.8.0-alpha04
androidx.compose.foundation:foundation-android:1.8.0-alpha04
androidx.compose.foundation:foundation-jvmstubs:1.8.0-alpha04
na...@google.com <na...@google.com> #7
Using the new version 1.8.0-alpha04
does not seem to resolve the issue for me. I tested with the same setting as the reported issue:
// it doesn't matter what you put here a the multiplier, the positionalThreshold is always 50%
positionalThreshold = { d -> d * 0.9f },
velocityThreshold = { Float.POSITIVE_INFINITY },
p....@anfe.ma <p....@anfe.ma> #8
Same. I've run this again on 1.8.0-alpha04. When using
positionalThreshold = { d -> d * 0.1f }
Dragging up to 10% or between 50% and 90% will cause it to snap back to the start anchor. Dragging between 10% and 50% or past 90% will cause it to snap to the end anchor.
I would expect It to only return if dragged less than or equal to 10% and snap to the end if dragged greater than 10%.
When using
positionalThreshold = { d -> d * 0.9f }
It acts as if the threshold has been set to 50%.
From what I can tell, nothing has changed about the behavior.
se...@squareup.com <se...@squareup.com> #9
Thanks, we will investigate and update this issue.
ek...@uber.com <ek...@uber.com> #10
kl...@google.com <kl...@google.com> #11
Project: platform/frameworks/support
Branch: androidx-main
Author: Jossi Wolf <
Link:
Update AnchoredDraggable target calculation logic
Expand for full commit details
Update AnchoredDraggable target calculation logic
There was a missed case when the velocity was negative.
Test: New tests with more parameter permutations
Fixes: 367660226
Bug: 376931805
Relnote: "Follow-up fix for an issue in AnchoredDraggable's target calculation where it could settle at the wrong anchor for specific swipes."
Change-Id: I23b8773d3a694aa3c8de6a8f34b9d7fb54cfe560
Files:
- M
compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/anchoredDraggable/AnchoredDraggableStateTest.kt
- M
compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/gestures/AnchoredDraggable.kt
Hash: 6a23aa4ee37ba171475e4155db0d24c90b358c7e
Date: Fri Nov 08 14:11:31 2024
pr...@google.com <pr...@google.com> #12
What is the fix version?
Description
Jetpack Compose version: 1.2.1
Jetpack Compose component(s) used: androidx.compose.material.TextField
Android Studio Build:Android Studio Chipmunk | 2021.2.1 Build #AI-212.5712.43.2112.8512546, built on April 28, 2022
Kotlin version: 1.7.0
Steps to Reproduce or Code Sample to Reproduce:
1.Run this snippet 2.The TextField is enabled and not readonly for 10 seconds, you can start typing 3.When the 10 seconds have elapsed, the TextField can still be written to using the Virtual Keyboard
Is this a normal behavior? Is there another way to prevent writing to the TextField?
Sample code: