mirror of
https://github.com/ppy/osu.git
synced 2025-02-01 00:39:11 +08:00
Simplify show/hide logic
This commit is contained in:
parent
72107c27c9
commit
c479d0efa4
@ -139,10 +139,7 @@ namespace osu.Game.Overlays.Profile.Header
|
|||||||
anyInfoAdded |= tryAddInfo(FontAwesome.Solid.Link, websiteWithoutProtocol, user.Website);
|
anyInfoAdded |= tryAddInfo(FontAwesome.Solid.Link, websiteWithoutProtocol, user.Website);
|
||||||
|
|
||||||
// If no information was added to the bottomLinkContainer, hide it to avoid unwanted padding
|
// If no information was added to the bottomLinkContainer, hide it to avoid unwanted padding
|
||||||
if (anyInfoAdded)
|
bottomLinkContainer.Alpha = anyInfoAdded ? 1 : 0;
|
||||||
bottomLinkContainer.Show();
|
|
||||||
else
|
|
||||||
bottomLinkContainer.Hide();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void addSpacer(OsuTextFlowContainer textFlow) => textFlow.AddArbitraryDrawable(new Container { Width = 15 });
|
private void addSpacer(OsuTextFlowContainer textFlow) => textFlow.AddArbitraryDrawable(new Container { Width = 15 });
|
||||||
|
Loading…
Reference in New Issue
Block a user