mirror of https://github.com/ppy/osu
Fix pixels poking out of the top edge of editor setup screen
This commit is contained in:
parent
edf29e405b
commit
0319177c5c
|
@ -25,7 +25,7 @@ private void load()
|
|||
{
|
||||
AddRange(new Drawable[]
|
||||
{
|
||||
sections = new SectionsContainer<SetupSection>
|
||||
sections = new SetupScreenSectionsContainer
|
||||
{
|
||||
FixedHeader = header,
|
||||
RelativeSizeAxes = Axes.Both,
|
||||
|
@ -40,5 +40,19 @@ private void load()
|
|||
},
|
||||
});
|
||||
}
|
||||
|
||||
private class SetupScreenSectionsContainer : SectionsContainer<SetupSection>
|
||||
{
|
||||
protected override UserTrackingScrollContainer CreateScrollContainer()
|
||||
{
|
||||
var scrollContainer = base.CreateScrollContainer();
|
||||
|
||||
// Workaround for masking issues (see https://github.com/ppy/osu-framework/issues/1675#issuecomment-910023157)
|
||||
// Note that this actually causes the full scroll range to be reduced by 2px at the bottom, but it's not really noticeable.
|
||||
scrollContainer.Margin = new MarginPadding { Top = 2 };
|
||||
|
||||
return scrollContainer;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue