mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 06:12:56 +08:00
Use EqualityComparer<T> to avoid boxing and casting when comparing.
This commit is contained in:
parent
1d51e6af2a
commit
1cddc4eb5b
@ -57,7 +57,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
}
|
||||
protected set
|
||||
{
|
||||
if (displayedCount.Equals(value))
|
||||
if (EqualityComparer<T>.Default.Equals(displayedCount, value))
|
||||
return;
|
||||
displayedCount = value;
|
||||
DisplayedCountSpriteText.Text = FormatCount(value);
|
||||
|
Loading…
Reference in New Issue
Block a user