-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Drag and drop releases randomly on large items #57
Comments
What's the version of compose in your project and which version of this library are you using? |
It's your demo project:
|
It seems that the main thing is the size (or maybe zoom(display item size maximization)) |
Hmm I'll take a look. I thought it was solved already |
Sorry last issue that I opened just did not have time at that moment to provide more information. My bad. |
Hey, did you managed to reproduce the issues? Any update? |
It's a busy week. I'll try to take a deeper look soon. It's not immediately obvious in the code what's wrong. |
We got the same issue.
Debugged it a big, it seems like in fun Modifier.draggable for some reason the DisposableEffect is called and then everything is getting cleared. Maybe some behavior changes in the new compose version? Did you maybe get some insights @Calvin-LL? |
So the problem is the dragging item's actual position on the list can't be moved off screen. Once it's moved off screen, LazyColumn disposes it. I had something in the stroller to make sure a dragging item is never scrolled off screen but I'm not sure why it's not working. I'll have to wait till I have a free day to take a deeper look. Feel free to dig into it and see if you can solve it. |
Hello, any updates on this issue? |
I think I finally figured out what's wrong with it but I've been too busy to dig into it 😢 |
@Calvin-LL don't want to push you or something, but do you know when will you have some time to dig more into it? |
I think this weekend hopefully. Ask me again next week if I haven't. |
Hello, @Calvin-LL any updates? |
Having the same issue with scrolling the Large item to the top. Any updates on this Calvin? |
Thank y'all for reminding me. Took a deep look today and I think I have a fix. Will polish and push an update tomorrow. |
v2.4.2 is out. Sorry for the wait. It took me the whole day. |
It works better now, however, it's not completely fixed. Not sure, if there is a workaround you can do, since it's something google should fix. |
There's a limit to what it can handle with large items. Lazy Layouts only compose items that are on the screen, and this library offsets them to achieve dragging. If the items are so big that only one is rendered on screen, and the dragging item's original location is no longer on screen, then the item will disappear under your finger. |
So this issue post compose update to 1.7.0.
When trying to drag large items somehow it releases automaticly and drops randomly.
In video I use:
I used other resolutions for testing and the same bug appears.
Screen_recording_20241106_080151.webm
Screen_recording_20241106_080015.webm
The text was updated successfully, but these errors were encountered: