1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-16 05:52:55 +08:00

Merge pull request #10200 from peppy/fix-hit-object-container-unbinding

Fix HitObjectContainer not correctly unbinding from startTime fast enough
This commit is contained in:
Dean Herbert 2020-09-23 21:17:31 +09:00 committed by GitHub
commit 26d1c4322d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -43,10 +43,20 @@ namespace osu.Game.Rulesets.UI
return true;
}
protected override void Dispose(bool isDisposing)
{
base.Dispose(isDisposing);
unbindStartTimeMap();
}
public virtual void Clear(bool disposeChildren = true)
{
ClearInternal(disposeChildren);
unbindStartTimeMap();
}
private void unbindStartTimeMap()
{
foreach (var kvp in startTimeMap)
kvp.Value.bindable.UnbindAll();
startTimeMap.Clear();