mirror of
https://github.com/ppy/osu.git
synced 2025-02-08 20:23:21 +08:00
Update all tournament buttons to use new design
This commit is contained in:
parent
0284fa1fc1
commit
b712b19539
@ -13,12 +13,8 @@ using osu.Framework.Graphics.Shapes;
|
|||||||
using osu.Game.Graphics;
|
using osu.Game.Graphics;
|
||||||
using osu.Game.Online.API;
|
using osu.Game.Online.API;
|
||||||
using osu.Game.Overlays.Settings;
|
using osu.Game.Overlays.Settings;
|
||||||
using osu.Game.Tournament.Components;
|
|
||||||
using osu.Game.Tournament.Models;
|
using osu.Game.Tournament.Models;
|
||||||
using osu.Game.Tournament.Screens.Drawings.Components;
|
using osu.Game.Tournament.Screens.Drawings.Components;
|
||||||
using osu.Game.Tournament.Screens.Gameplay.Components;
|
|
||||||
using osu.Game.Tournament.Screens.Ladder.Components;
|
|
||||||
using osu.Game.Tournament.Screens.TeamIntro;
|
|
||||||
using osu.Game.Users;
|
using osu.Game.Users;
|
||||||
using osuTK;
|
using osuTK;
|
||||||
|
|
||||||
|
@ -13,7 +13,6 @@ using osu.Framework.Graphics.Shapes;
|
|||||||
using osu.Game.Graphics.UserInterface;
|
using osu.Game.Graphics.UserInterface;
|
||||||
using osu.Game.Graphics;
|
using osu.Game.Graphics;
|
||||||
using osu.Game.Graphics.Containers;
|
using osu.Game.Graphics.Containers;
|
||||||
using osu.Game.Overlays.Settings;
|
|
||||||
using osu.Game.Tournament.Components;
|
using osu.Game.Tournament.Components;
|
||||||
using osuTK;
|
using osuTK;
|
||||||
|
|
||||||
@ -42,7 +41,7 @@ namespace osu.Game.Tournament.Screens.Editors
|
|||||||
}
|
}
|
||||||
|
|
||||||
[BackgroundDependencyLoader]
|
[BackgroundDependencyLoader]
|
||||||
private void load()
|
private void load(OsuColour colours)
|
||||||
{
|
{
|
||||||
AddRangeInternal(new Drawable[]
|
AddRangeInternal(new Drawable[]
|
||||||
{
|
{
|
||||||
@ -75,9 +74,10 @@ namespace osu.Game.Tournament.Screens.Editors
|
|||||||
Text = "Add new",
|
Text = "Add new",
|
||||||
Action = () => Storage.Add(new TModel())
|
Action = () => Storage.Add(new TModel())
|
||||||
},
|
},
|
||||||
new DangerousSettingsButton
|
new TourneyButton
|
||||||
{
|
{
|
||||||
RelativeSizeAxes = Axes.X,
|
RelativeSizeAxes = Axes.X,
|
||||||
|
BackgroundColour = colours.Pink3,
|
||||||
Text = "Clear all",
|
Text = "Clear all",
|
||||||
Action = Storage.Clear
|
Action = Storage.Clear
|
||||||
},
|
},
|
||||||
|
@ -252,14 +252,13 @@ namespace osu.Game.Tournament
|
|||||||
|
|
||||||
if (shortcutKey != null)
|
if (shortcutKey != null)
|
||||||
{
|
{
|
||||||
Add(new Container
|
Add(new CircularContainer
|
||||||
{
|
{
|
||||||
Anchor = Anchor.CentreLeft,
|
Anchor = Anchor.CentreLeft,
|
||||||
Origin = Anchor.CentreLeft,
|
Origin = Anchor.CentreLeft,
|
||||||
Size = new Vector2(24),
|
Size = new Vector2(24),
|
||||||
Margin = new MarginPadding(5),
|
Margin = new MarginPadding(5),
|
||||||
Masking = true,
|
Masking = true,
|
||||||
CornerRadius = 4,
|
|
||||||
Alpha = 0.5f,
|
Alpha = 0.5f,
|
||||||
Blending = BlendingParameters.Additive,
|
Blending = BlendingParameters.Additive,
|
||||||
Children = new Drawable[]
|
Children = new Drawable[]
|
||||||
|
@ -1,18 +1,21 @@
|
|||||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||||
// See the LICENCE file in the repository root for full licence text.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
|
using osu.Framework.Allocation;
|
||||||
|
using osu.Framework.Graphics;
|
||||||
using osu.Framework.Graphics.Shapes;
|
using osu.Framework.Graphics.Shapes;
|
||||||
using osu.Game.Graphics.UserInterface;
|
using osu.Game.Overlays.Settings;
|
||||||
|
|
||||||
namespace osu.Game.Tournament
|
namespace osu.Game.Tournament
|
||||||
{
|
{
|
||||||
public partial class TourneyButton : OsuButton
|
public partial class TourneyButton : SettingsButton
|
||||||
{
|
{
|
||||||
public new Box Background => base.Background;
|
public new Box Background => base.Background;
|
||||||
|
|
||||||
public TourneyButton()
|
[BackgroundDependencyLoader]
|
||||||
: base(null)
|
private void load()
|
||||||
{
|
{
|
||||||
|
Padding = new MarginPadding();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user