https://kotlinlang.org logo
Title
t

theapache64

03/05/2022, 9:17 AM
How do i get release position from
PressInteraction.Release
? Currently it only provides
pressPosition
🤔
@Adam Powell any idea about this?
l

Louis Pullen-Freilich [G]

03/05/2022, 7:16 PM
What is your use case? It currently isn't provided so you would need to use your own gesture detector to manually see the release event and the position
Indication typically doesn't move with a press, and it stays in the same position until the press is released
t

theapache64

03/05/2022, 7:37 PM
I am trying to build a custom indicator which will draw something when released at the release point. I am doing this on top of a
Surface
with
role = Role.Button,
, because of this, the gesture detector won’t work. I think i need to go with the other bare minimum`Surface`
l

Louis Pullen-Freilich [G]

03/05/2022, 8:06 PM
If you wanted, you could make your own custom
PressInteraction
subclass that also has released information - this would allow you to still use indication for this system
z

Zach Klippenstein (he/him) [MOD]

03/08/2022, 12:53 AM
Indication typically doesn't move with a press, and it stays in the same position until the press is released
What is “typically” here? More than just Material? I've seen some TV UIs that move the indication along with a gesture too.