mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 17:47:29 +08:00
Give OptionsOverlay an offset to make up for toolbar possibly being present.
This commit is contained in:
parent
d9bd3717d0
commit
a5dcae859c
@ -6,6 +6,7 @@ using System.Linq;
|
||||
using OpenTK;
|
||||
using OpenTK.Graphics;
|
||||
using OpenTK.Input;
|
||||
using osu.Framework;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.Primitives;
|
||||
@ -72,6 +73,7 @@ namespace osu.Game.Overlays
|
||||
AutoSizeAxes = Axes.Y,
|
||||
RelativeSizeAxes = Axes.X,
|
||||
Direction = FlowDirection.VerticalOnly,
|
||||
|
||||
Children = new Drawable[]
|
||||
{
|
||||
new SpriteText
|
||||
@ -112,6 +114,13 @@ namespace osu.Game.Overlays
|
||||
};
|
||||
}
|
||||
|
||||
protected override void Load(BaseGame game)
|
||||
{
|
||||
base.Load(game);
|
||||
|
||||
scrollContainer.Padding = new MarginPadding { Top = (game as OsuGame)?.Toolbar.DrawHeight ?? 0 };
|
||||
}
|
||||
|
||||
protected override bool OnMouseDown(InputState state, MouseDownEventArgs args) => true;
|
||||
|
||||
protected override bool OnKeyDown(InputState state, KeyDownEventArgs args)
|
||||
|
Loading…
Reference in New Issue
Block a user