Skip to content

Conversation

@imgde
Copy link

@imgde imgde commented May 22, 2025

This Draft Adds Drag&Drop Queue Control, closing #37 & #595

Current Issues/Limitations:

  • Logging still included, overcomplicated way of checking if the event is valid (since the drag&drop is Android-global)
  • No autoscroll when hitting lower/upper 20% of the screen (you need a second finger to scroll inside the queue)
  • The drop field is small since i didn't want to introduce z layers or alter the design of the list
  • The song queue entries (in the queue) are thinner than before (same reason as above) -> smaller clickable area and uglier onClick
  • the drag&drop is only implemented for the playing queue -> can easily be implemented everywhere else, i just didn't bother
  • the drag doesn't have a clear preview (the preview is only the drag icon, not the whole song entry)
  • moving the currently playing song calls symphony.radio.play, pausing the music for ~0.5s

Fixed Problems:

  • The drag&drop source detectTapGestures interferes with the SongCard Card onClick -> temporarily added Card onClick to Song title/author (could be fixed by using detectTapGestures for both, or limiting the detectTapGestures into its own space with a SongCard shadow) -> moved the drag area out of the onClick
  • uses ExperimentalFoundationApi -> dragAndDrop features aren't Experimental since compose-foundation 1.8
  • Drag&dropping the currently playing song will change the currently playing song -> fixed in second commit
  • Unclear where the drop will land -> moved the drop zones between the queue entries

@zyrouge
Copy link
Owner

zyrouge commented May 22, 2025

Can you clarify on "Drag&dropping the currently playing song will change the currently playing song"?

@imgde
Copy link
Author

imgde commented May 22, 2025

If you are currently playing a song in the queue and move it somewhere else, the next song in the queue will start playing instead of the currently playing song still playing.

This is because this code touches the queue, but not the currently playing song.
According //TODOs are set everywhere

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants