[Playlist Queue] Save queue state change to disk

Save queue state changes to disk, rather than leaving it for later.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
main
Christopher Snowhill 2022-07-29 01:41:49 -07:00
parent e0c1e338e4
commit ff1afdb63c
1 changed files with 8 additions and 0 deletions

View File

@ -1625,6 +1625,8 @@ static void *playlistControllerContext = &playlistControllerContext;
[queueList removeAllObjects];
[self commitPersistentStore];
// Refresh entire row to refresh tooltips
unsigned long columns = [[self.tableView tableColumns] count];
[self.tableView reloadDataForRowIndexes:refreshSet columnIndexes:[NSIndexSet indexSetWithIndexesInRange:NSMakeRange(0, columns)]];
@ -1661,6 +1663,8 @@ static void *playlistControllerContext = &playlistControllerContext;
cur.queuePosition = i++;
}
[self commitPersistentStore];
// Refresh entire row to refresh tooltips
unsigned long columns = [[self.tableView tableColumns] count];
[self.tableView reloadDataForRowIndexes:refreshSet columnIndexes:[NSIndexSet indexSetWithIndexesInRange:NSMakeRange(0, columns)]];
@ -1687,6 +1691,8 @@ static void *playlistControllerContext = &playlistControllerContext;
cur.queuePosition = i++;
}
[self commitPersistentStore];
// Refresh entire row to refresh tooltips
unsigned long columns = [[self.tableView tableColumns] count];
[self.tableView reloadDataForRowIndexes:refreshSet columnIndexes:[NSIndexSet indexSetWithIndexesInRange:NSMakeRange(0, columns)]];
@ -1711,6 +1717,8 @@ static void *playlistControllerContext = &playlistControllerContext;
cur.queuePosition = i++;
}
[self commitPersistentStore];
// Refresh entire row to refresh tooltips
unsigned long columns = [[self.tableView tableColumns] count];
[self.tableView reloadDataForRowIndexes:refreshSet columnIndexes:[NSIndexSet indexSetWithIndexesInRange:NSMakeRange(0, columns)]];