mirror of
https://github.com/osukey/osukey.git
synced 2025-08-05 07:33:55 +09:00
Merge https://github.com/ppy/osu into online-beatmap-set-overlay
This commit is contained in:
@ -87,7 +87,9 @@ namespace osu.Game.Beatmaps
|
||||
{
|
||||
if (track != null) return track;
|
||||
|
||||
track = GetTrack();
|
||||
// we want to ensure that we always have a track, even if it's a fake one.
|
||||
track = GetTrack() ?? new TrackVirtual();
|
||||
|
||||
applyRateAdjustments();
|
||||
return track;
|
||||
}
|
||||
@ -107,10 +109,17 @@ namespace osu.Game.Beatmaps
|
||||
|
||||
public virtual void Dispose()
|
||||
{
|
||||
track?.Dispose();
|
||||
track = null;
|
||||
background?.Dispose();
|
||||
background = null;
|
||||
}
|
||||
|
||||
public void DisposeTrack()
|
||||
{
|
||||
lock (trackLock)
|
||||
{
|
||||
track?.Dispose();
|
||||
track = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user