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

Reorder tracks in the queue #105

Open
nt4f04uNd opened this issue May 5, 2023 · 0 comments
Open

Reorder tracks in the queue #105

nt4f04uNd opened this issue May 5, 2023 · 0 comments
Labels
bug Something isn't working enhancement New feature or request third party

Comments

@nt4f04uNd
Copy link
Owner

nt4f04uNd commented May 5, 2023

Suggestion

Currently this is not implemented, because we use itemExtent.

We must use it:

  • for scrollbar
  • for jumps when user closes the queue route

Otherwise it's just very laggy.

However, itemExtent is broken for ReordableList flutter/flutter#84901

So it poses a dilemma, where we can only use one or another.

Possible solutions:

1. (The most desirable option) Fix flutter/flutter#84901

I tried digging this, but it seems that the issue is deeply in the underlying SliverFixedExtentList, which lays all of its children with the fixed extent height. ReordableList inserts an empty box when moving a child, which in this protocol means that extra space will appear.

The solution could involve either

  1. trying to figure out why is this extra empty box even there and removing it
  2. adding a hook to SliverFixedExtentList to manipulate a height of a singular item (which seems extremely hard)

2. Try exploring the https://pub.dev/packages/great_list_view package

This is a cat in a bag option.

AFAIK this package uses techniques from native RecyclerView Android implementation, which allows for reordering, fast jumping to particular item, even if the list is not of fixed height, and other cool features.

But this is an unexplored third party dependency that could potentially become unmaintained, or just containt bugs we don't know of.

3. Hack it

Come up with some hack, for example: in selection the list is changed to ReordableList without itemExtent and then changed back to a regular one when selection ends.

@nt4f04uNd nt4f04uNd added enhancement New feature or request bug Something isn't working third party labels May 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request third party
Projects
None yet
Development

No branches or pull requests

1 participant