Multiple tracks inserted at incorrect location #297

Open
opened 2025-09-28 15:46:39 +01:00 by kae · 0 comments
Owner

With a row selected, inserting one track is fine. Immediately inserting another puts that track below the selection.

We maintain a self.selected_rows cache in playlistmodel. It would be better to dynamically ascertain the selected row(s) each time:

sel = view.selectionModel()
indexes = sel.selectedRows()          # or selectedIndexes()
rows = [ix.row() for ix in indexes]   # current, correct rows

The playlistmodel/playlist instantiation happens in musicmuster._open_playlist()

With a row selected, inserting one track is fine. Immediately inserting another puts that track below the selection. We maintain a `self.selected_rows` cache in playlistmodel. It would be better to dynamically ascertain the selected row(s) each time: ``` sel = view.selectionModel() indexes = sel.selectedRows() # or selectedIndexes() rows = [ix.row() for ix in indexes] # current, correct rows ``` The playlistmodel/playlist instantiation happens in `musicmuster._open_playlist()`
kae added the
bug
label 2025-09-28 15:46:40 +01:00
kae added the
V5
label 2025-10-01 12:04:39 +01:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: kae/musicmuster#297
No description provided.