1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 20:07:29 +08:00

Simplify interaction condition

This commit is contained in:
EVAST9919 2017-11-21 13:42:42 +03:00 committed by Dean Herbert
parent 94a974a397
commit 938c5feea4

View File

@ -146,7 +146,7 @@ namespace osu.Game.Overlays.Profile
protected override bool OnHover(InputState state)
{
if (ranks != null && ranks.Length > 1)
if (ranks?.Length > 1)
{
graph.UpdateBallPosition(state.Mouse.Position.X);
graph.ShowBall();
@ -156,7 +156,7 @@ namespace osu.Game.Overlays.Profile
protected override bool OnMouseMove(InputState state)
{
if (ranks != null && ranks.Length > 1)
if (ranks?.Length > 1)
graph.UpdateBallPosition(state.Mouse.Position.X);
return base.OnMouseMove(state);
@ -164,7 +164,7 @@ namespace osu.Game.Overlays.Profile
protected override void OnHoverLost(InputState state)
{
if (ranks != null && ranks.Length > 1)
if (ranks?.Length > 1)
{
graph.HideBall();
updateRankTexts();