mirror of https://github.com/ppy/osu
Fix incorrect event unbind logic
This commit is contained in:
parent
52db7b36fc
commit
edcbd4de6d
|
@ -40,10 +40,12 @@ protected override void LoadComplete()
|
|||
if (gameplayClockContainer != null)
|
||||
gameplayClockContainer.OnSeek += Clear;
|
||||
|
||||
// Scheduled as meter implementations are likely going to change/add drawables when reacting to this.
|
||||
processor.NewJudgement += j => Schedule(() => OnNewJudgement(j));
|
||||
processor.NewJudgement += processorNewJudgement;
|
||||
}
|
||||
|
||||
// Scheduled as meter implementations are likely going to change/add drawables when reacting to this.
|
||||
private void processorNewJudgement(JudgementResult j) => Schedule(() => OnNewJudgement(j));
|
||||
|
||||
/// <summary>
|
||||
/// Fired when a new judgement arrives.
|
||||
/// </summary>
|
||||
|
@ -89,7 +91,7 @@ protected override void Dispose(bool isDisposing)
|
|||
base.Dispose(isDisposing);
|
||||
|
||||
if (processor != null)
|
||||
processor.NewJudgement -= OnNewJudgement;
|
||||
processor.NewJudgement -= processorNewJudgement;
|
||||
|
||||
if (gameplayClockContainer != null)
|
||||
gameplayClockContainer.OnSeek -= Clear;
|
||||
|
|
Loading…
Reference in New Issue