mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 15:47:26 +08:00
Remove unnecessary text comparison
This commit is contained in:
parent
740898dffb
commit
6ebfafa9c3
@ -47,17 +47,7 @@ namespace osu.Game.Screens.Play.Break
|
||||
}
|
||||
};
|
||||
|
||||
Current.ValueChanged += currentValueChanged;
|
||||
}
|
||||
|
||||
private void currentValueChanged(ValueChangedEvent<T> e)
|
||||
{
|
||||
LocalisableString newText = Format(e.NewValue);
|
||||
|
||||
if (valueText.Text == newText)
|
||||
return;
|
||||
|
||||
valueText.Text = newText;
|
||||
Current.ValueChanged += text => valueText.Text = Format(text.NewValue);
|
||||
}
|
||||
|
||||
protected virtual LocalisableString Format(T count)
|
||||
|
Loading…
Reference in New Issue
Block a user