mirror of
https://github.com/osukey/osukey.git
synced 2025-08-07 00:23:59 +09:00
Merge pull request #21616 from Joehuu/changelog-build-masking
Fix changelog single build dates disappearing before being off screen
This commit is contained in:
@ -68,11 +68,15 @@ namespace osu.Game.Overlays.Changelog
|
|||||||
Anchor = Anchor.TopCentre,
|
Anchor = Anchor.TopCentre,
|
||||||
Origin = Anchor.TopCentre,
|
Origin = Anchor.TopCentre,
|
||||||
AutoSizeAxes = Axes.Both,
|
AutoSizeAxes = Axes.Both,
|
||||||
Direction = FillDirection.Horizontal,
|
Direction = FillDirection.Vertical,
|
||||||
Margin = new MarginPadding { Top = 20 },
|
Margin = new MarginPadding { Top = 20 },
|
||||||
Children = new Drawable[]
|
Child = new FillFlowContainer
|
||||||
{
|
{
|
||||||
new OsuHoverContainer
|
Anchor = Anchor.TopCentre,
|
||||||
|
Origin = Anchor.TopCentre,
|
||||||
|
AutoSizeAxes = Axes.Both,
|
||||||
|
Direction = FillDirection.Horizontal,
|
||||||
|
Child = new OsuHoverContainer
|
||||||
{
|
{
|
||||||
Anchor = Anchor.Centre,
|
Anchor = Anchor.Centre,
|
||||||
Origin = Anchor.Centre,
|
Origin = Anchor.Centre,
|
||||||
|
@ -4,7 +4,6 @@
|
|||||||
#nullable disable
|
#nullable disable
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Linq;
|
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
using osu.Framework.Extensions.Color4Extensions;
|
using osu.Framework.Extensions.Color4Extensions;
|
||||||
@ -104,27 +103,29 @@ namespace osu.Game.Overlays.Changelog
|
|||||||
{
|
{
|
||||||
var fill = base.CreateHeader();
|
var fill = base.CreateHeader();
|
||||||
|
|
||||||
foreach (var existing in fill.Children.OfType<OsuHoverContainer>())
|
var nestedFill = (FillFlowContainer)fill.Child;
|
||||||
|
|
||||||
|
var buildDisplay = (OsuHoverContainer)nestedFill.Child;
|
||||||
|
|
||||||
|
buildDisplay.Scale = new Vector2(1.25f);
|
||||||
|
buildDisplay.Action = null;
|
||||||
|
|
||||||
|
fill.Add(date = new OsuSpriteText
|
||||||
{
|
{
|
||||||
existing.Scale = new Vector2(1.25f);
|
Anchor = Anchor.TopCentre,
|
||||||
existing.Action = null;
|
Origin = Anchor.TopCentre,
|
||||||
|
Text = Build.CreatedAt.Date.ToString("dd MMMM yyyy"),
|
||||||
|
Font = OsuFont.GetFont(weight: FontWeight.Regular, size: 14),
|
||||||
|
Margin = new MarginPadding { Top = 5 },
|
||||||
|
Scale = new Vector2(1.25f),
|
||||||
|
});
|
||||||
|
|
||||||
existing.Add(date = new OsuSpriteText
|
nestedFill.Insert(-1, new NavigationIconButton(Build.Versions?.Previous)
|
||||||
{
|
|
||||||
Text = Build.CreatedAt.Date.ToString("dd MMMM yyyy"),
|
|
||||||
Font = OsuFont.GetFont(weight: FontWeight.Regular, size: 14),
|
|
||||||
Anchor = Anchor.BottomCentre,
|
|
||||||
Origin = Anchor.TopCentre,
|
|
||||||
Margin = new MarginPadding { Top = 5 },
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
fill.Insert(-1, new NavigationIconButton(Build.Versions?.Previous)
|
|
||||||
{
|
{
|
||||||
Icon = FontAwesome.Solid.ChevronLeft,
|
Icon = FontAwesome.Solid.ChevronLeft,
|
||||||
SelectBuild = b => SelectBuild(b)
|
SelectBuild = b => SelectBuild(b)
|
||||||
});
|
});
|
||||||
fill.Insert(1, new NavigationIconButton(Build.Versions?.Next)
|
nestedFill.Insert(1, new NavigationIconButton(Build.Versions?.Next)
|
||||||
{
|
{
|
||||||
Icon = FontAwesome.Solid.ChevronRight,
|
Icon = FontAwesome.Solid.ChevronRight,
|
||||||
SelectBuild = b => SelectBuild(b)
|
SelectBuild = b => SelectBuild(b)
|
||||||
|
Reference in New Issue
Block a user