Queue: ModifyAtOrder() does not increment version
Leave that to the caller, allowing it to modify multiple items at a time.
This commit is contained in:
parent
4de3b6dc80
commit
03b57df630
@ -48,6 +48,7 @@ playlist::TagModified(Song &&song)
|
||||
current_song.ReplaceTag(std::move(*song.tag));
|
||||
|
||||
queue.ModifyAtOrder(current);
|
||||
queue.IncrementVersion();
|
||||
idle_add(IDLE_PLAYLIST);
|
||||
}
|
||||
|
||||
|
@ -83,8 +83,6 @@ queue::ModifyAtOrder(unsigned _order)
|
||||
|
||||
unsigned position = order[_order];
|
||||
items[position].version = version;
|
||||
|
||||
IncrementVersion();
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -241,7 +241,8 @@ struct queue {
|
||||
void IncrementVersion();
|
||||
|
||||
/**
|
||||
* Marks the specified song as "modified" and increments the version
|
||||
* Marks the specified song as "modified". Call
|
||||
* IncrementVersion() after all modifications have been made.
|
||||
* number.
|
||||
*/
|
||||
void ModifyAtOrder(unsigned order);
|
||||
|
Loading…
Reference in New Issue
Block a user