1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-13 15:53:51 +08:00

Fix masking issues with certain aspect ratio displays

This commit is contained in:
Dean Herbert 2020-10-13 17:33:35 +09:00
parent 4160feb3da
commit f3b937e358
2 changed files with 5 additions and 3 deletions

View File

@ -845,7 +845,9 @@ namespace osu.Game.Screens.Select
float itemDrawY = posInScroll.Y - visibleUpperBound;
float dist = Math.Abs(1f - itemDrawY / visibleHalfHeight);
item.X = offsetX(dist, visibleHalfHeight) - (parent?.X ?? 0);
// adjusting the item's overall X position can cause it to become masked away when
// child items (difficulties) are still visible.
item.Header.X = offsetX(dist, visibleHalfHeight) - (parent?.X ?? 0);
// We are applying a multiplicative alpha (which is internally done by nesting an
// additional container and setting that container's alpha) such that we can

View File

@ -173,7 +173,7 @@ namespace osu.Game.Screens.Select.Carousel
{
base.Selected();
Header.MoveToX(-50, 500, Easing.OutExpo);
MovementContainer.MoveToX(-50, 500, Easing.OutExpo);
background.Colour = ColourInfo.GradientVertical(
new Color4(20, 43, 51, 255),
@ -186,7 +186,7 @@ namespace osu.Game.Screens.Select.Carousel
{
base.Deselected();
Header.MoveToX(0, 500, Easing.OutExpo);
MovementContainer.MoveToX(0, 500, Easing.OutExpo);
background.Colour = new Color4(20, 43, 51, 255);
triangles.Colour = OsuColour.Gray(0.5f);