Files
SpotiFLAC-Mobile/lib
zarzet be5a3bd4ae feat(selection): slide a held finger over songs to select them
After a long press selects a song, the finger can slide over more songs
to select them, as in a photo gallery. Sliding back releases the songs it
had passed but nothing selected before, and the list scrolls while the
finger rests near its top or bottom edge.

A row keeps its own long press and hands the pointer to a
DragSelectController, which follows it on the global pointer route: the
won long press already keeps the list from scrolling, and the route
outlives a row that is rebuilt or scrolled away. Rows register with
DragSelectItem so the controller can find the one nearest the finger,
which also works in a grid. A held row that is kept alive off screen has
no place on it and is skipped.

Library Songs keeps the hold and drag onto a playlist: the first hold,
and a hold on a selected song, drag as before. Once selecting, a hold on
any other song selects it (still with the range from the song selected
last) and slides; a slide replaces that range with the songs it passes.
LibraryPlaylistDragSource takes an enabled flag for that, and the card
gets the long press whenever the drag source does not.

Singles, the folder view, album, playlist, mix and Library playlist
pages slide from the first hold through SelectionModeMixin.holdToSelect.
In selection mode a long press there now selects the row; the folder
view and Library playlist rows toggled it before. Desktop is unchanged.
2026-11-21 02:50:39 +07:00
..