Added setting of last sort to user sort on user sort.
This commit is contained in:
parent
78b60dba02
commit
faecea8ca7
1 changed files with 8 additions and 0 deletions
|
@ -97,6 +97,14 @@ class PlaylistView(QTreeWidget):
|
|||
if user_sort:
|
||||
track.setText(4, str(i)) # 4 = user sort index
|
||||
|
||||
if user_sort:
|
||||
if not self.playlist.sorting[4][0] == 4: # set last sort to user sort
|
||||
del self.playlist.sorting[0]
|
||||
|
||||
self.playlist.sorting.append((4, True))
|
||||
|
||||
self.header.setSortIndicator(4, Qt.SortOrder.AscendingOrder)
|
||||
|
||||
self.playlist.sync(self, user_sort) # sync playlist to this view
|
||||
|
||||
def dropEvent(self, event: QDropEvent):
|
||||
|
|
Loading…
Add table
Reference in a new issue