Skip to content
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

[Bug]: Preview picture in custom picker is waaay too slow #5789

Open
mnalis opened this issue Aug 23, 2024 · 2 comments
Open

[Bug]: Preview picture in custom picker is waaay too slow #5789

mnalis opened this issue Aug 23, 2024 · 2 comments
Labels

Comments

@mnalis
Copy link
Contributor

mnalis commented Aug 23, 2024

Summary

Not only is picture preview in Custom Picker lacking in zoom (see #5701), it is also annoying slow to display the picture.

Perhaps we could just call external default gallery/image viewer app (via intent) to display that picture on long-press?
That would be much faster, fix the related zoom bug, give user the choice, and probably reduce the code.

(Or at least use some reasonable library / implementation instead of whatever is being used currently.)

Steps to reproduce

  1. Open Commons app
  2. choose + to add picture, and choose 3rd option (Custom selector)
  3. long press on some picture to preview it

Expected behaviour

Picture displays immediately (on this class of hardware!), just like it does in any other picture viewer (stock gallery, Fossify Gallery, Ghost Commander viewer...) i.e. under 0.1 seconds

Actual behaviour

spinner appears and spins for more than 2 seconds before picture is shown. That is more than 20 times (2000% !) slower than normal!

Device name

Samsung Galaxy S23+

Android version

Android 14 (OneUI 6.1)

Commons app version

5.0.2 (latest F-droid)

Device logs

No response

Screen-shots

Video showing how slow Commons app is when displaying image, compared to e.g. Fossify Gallery (which also is able to do much bigger zoom):

small_Screen_Recording_20240823_061656_Gallery.mp4

To add the insult to the injury, the viewer code does fancy fade-in effect, thus making picture display intentionally slower by some 0.2 seconds or so more...

Would you like to work on the issue?

None

@rohit9625
Copy link
Contributor

I am working on migrating the custom picker to Jetpack Compose and it'll solve this and more related problems.

@mnalis
Copy link
Contributor Author

mnalis commented Aug 23, 2024

That sounds great @rohit9625; please do link it here when when you have some draft PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants