From d12a9a767594bb80d1b91351f6757ad830ed33bd Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Thu, 20 Apr 2017 16:28:45 +0900 Subject: [PATCH] Don't run AutoSize transforms when tooltip is already invisible. --- osu.Game/Graphics/Cursor/TooltipContainer.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/osu.Game/Graphics/Cursor/TooltipContainer.cs b/osu.Game/Graphics/Cursor/TooltipContainer.cs index cf68baa313..4b43ff14c9 100644 --- a/osu.Game/Graphics/Cursor/TooltipContainer.cs +++ b/osu.Game/Graphics/Cursor/TooltipContainer.cs @@ -98,7 +98,12 @@ namespace osu.Game.Graphics.Cursor text.Text = value; if (Alpha > 0) - background.FlashColour(Color4.Gray, 200, EasingTypes.Out); + { + AutoSizeDuration = 250; + background.FlashColour(OsuColour.Gray(0.4f), 1000, EasingTypes.OutQuint); + } + else + AutoSizeDuration = 0; } } @@ -108,7 +113,6 @@ namespace osu.Game.Graphics.Cursor public Tooltip() { - AutoSizeDuration = 250; AutoSizeEasing = EasingTypes.OutQuint; AutoSizeAxes = Axes.Both;