Dispose previous WorkingBeatmap on change

This commit is contained in:
Dean Herbert 2019-07-02 22:25:03 +09:00
parent 9e33fb35e9
commit f31d840c13
1 changed files with 2 additions and 0 deletions

View File

@ -296,6 +296,8 @@ private void beatmapChanged(ValueChangedEvent<WorkingBeatmap> beatmap)
if (nextBeatmap?.Track != null)
nextBeatmap.Track.Completed += currentTrackCompleted;
beatmap.OldValue?.Dispose();
nextBeatmap?.LoadBeatmapAsync();
}