1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-15 16:22:55 +08:00

Avoid loading overlay headers until first open

Also switches them to use non-atlased target as they won't benefit much
from atlasing.
This commit is contained in:
Dean Herbert 2022-11-17 23:55:40 +09:00
parent f67e8ce523
commit 73e4827d36

View File

@ -18,7 +18,7 @@ namespace osu.Game.Overlays
Height = 80; Height = 80;
RelativeSizeAxes = Axes.X; RelativeSizeAxes = Axes.X;
Masking = true; Masking = true;
InternalChild = new Background(textureName); InternalChild = new DelayedLoadWrapper(() => new Background(textureName));
} }
private class Background : Sprite private class Background : Sprite
@ -36,10 +36,16 @@ namespace osu.Game.Overlays
} }
[BackgroundDependencyLoader] [BackgroundDependencyLoader]
private void load(TextureStore textures) private void load(LargeTextureStore textures)
{ {
Texture = textures.Get(textureName); Texture = textures.Get(textureName);
} }
protected override void LoadComplete()
{
base.LoadComplete();
this.FadeInFromZero(500, Easing.OutQuint);
}
} }
} }
} }