mirror of
https://github.com/ppy/osu.git
synced 2025-02-21 10:42:54 +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:
commit
26d1c4322d
@ -43,10 +43,20 @@ namespace osu.Game.Rulesets.UI
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected override void Dispose(bool isDisposing)
|
||||||
|
{
|
||||||
|
base.Dispose(isDisposing);
|
||||||
|
unbindStartTimeMap();
|
||||||
|
}
|
||||||
|
|
||||||
public virtual void Clear(bool disposeChildren = true)
|
public virtual void Clear(bool disposeChildren = true)
|
||||||
{
|
{
|
||||||
ClearInternal(disposeChildren);
|
ClearInternal(disposeChildren);
|
||||||
|
unbindStartTimeMap();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void unbindStartTimeMap()
|
||||||
|
{
|
||||||
foreach (var kvp in startTimeMap)
|
foreach (var kvp in startTimeMap)
|
||||||
kvp.Value.bindable.UnbindAll();
|
kvp.Value.bindable.UnbindAll();
|
||||||
startTimeMap.Clear();
|
startTimeMap.Clear();
|
||||||
|
Loading…
Reference in New Issue
Block a user