mirror of
https://github.com/osukey/osukey.git
synced 2025-08-02 14:17:06 +09:00
Only hide UpdateableAvatar/Flag immediately
This commit is contained in:
@ -3,6 +3,7 @@
|
||||
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.Transforms;
|
||||
|
||||
namespace osu.Game.Users.Drawables
|
||||
{
|
||||
@ -23,17 +24,14 @@ namespace osu.Game.Users.Drawables
|
||||
/// </summary>
|
||||
public bool ShowPlaceholderOnNull = true;
|
||||
|
||||
public UpdateableFlag(Country country = null, bool transformImmediately = false)
|
||||
public UpdateableFlag(Country country = null, bool hideImmediately = false)
|
||||
{
|
||||
TransformImmediately = hideImmediately;
|
||||
Country = country;
|
||||
|
||||
if (transformImmediately)
|
||||
{
|
||||
TransformDuration = 0;
|
||||
TransformImmediately = true;
|
||||
}
|
||||
}
|
||||
|
||||
protected override TransformSequence<Drawable> ApplyHideTransforms(Drawable drawable) => TransformImmediately ? drawable?.FadeOut() : base.ApplyHideTransforms(drawable);
|
||||
|
||||
protected override Drawable CreateDrawable(Country country)
|
||||
{
|
||||
if (country == null && !ShowPlaceholderOnNull)
|
||||
|
Reference in New Issue
Block a user