1
0
mirror of https://github.com/ppy/osu.git synced 2026-05-19 10:00:42 +08:00

Add OsuButton with sane defaults

This commit is contained in:
Drew DeVault
2016-11-02 22:27:39 -04:00
Unverified
parent 2aa85a4b18
commit 6c0cef894e
5 changed files with 33 additions and 2 deletions
@@ -0,0 +1,15 @@
using System;
using OpenTK.Graphics;
using osu.Framework.Graphics.UserInterface;
namespace osu.Game.Graphics.UserInterface
{
public class OsuButton : Button
{
public OsuButton()
{
Height = 25;
Colour = new Color4(14, 132, 165, 255);
}
}
}
@@ -0,0 +1,12 @@
using System;
namespace osu.Game.Overlays.Options
{
public class GraphicsOptions : OptionsSection
{
public GraphicsOptions()
{
Header = "Graphics";
}
}
}
+2 -1
View File
@@ -5,6 +5,7 @@ using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Sprites;
using osu.Framework.Graphics.UserInterface;
using osu.Game.Graphics.UserInterface;
using osu.Game.Online.API;
namespace osu.Game.Overlays.Options
@@ -53,7 +54,7 @@ namespace osu.Game.Overlays.Options
new TextBox { Height = 20, RelativeSizeAxes = Axes.X },
new SpriteText { Text = "Password" },
new TextBox { Height = 20, RelativeSizeAxes = Axes.X },
new Button
new OsuButton
{
RelativeSizeAxes = Axes.X,
Text = "Log in",
+2 -1
View File
@@ -4,6 +4,7 @@ using osu.Framework.Graphics;
using osu.Framework.Graphics.Sprites;
using osu.Framework.Graphics.UserInterface;
using osu.Framework.Platform;
using osu.Game.Graphics.UserInterface;
namespace osu.Game.Overlays.Options
{
@@ -16,7 +17,7 @@ namespace osu.Game.Overlays.Options
{
new SpriteText { Text = "TODO: Dropdown" },
new SpriteText { Text = "Your osu! is up to date" }, // TODO: map this to reality
new Button
new OsuButton
{
RelativeSizeAxes = Axes.X,
Text = "Open osu! folder",
+2
View File
@@ -200,6 +200,8 @@
<Compile Include="Overlays\Options\GeneralOptions.cs" />
<Compile Include="Overlays\Options\LanguageOptions.cs" />
<Compile Include="Overlays\Options\UpdateOptions.cs" />
<Compile Include="Overlays\Options\GraphicsOptions.cs" />
<Compile Include="Graphics\UserInterface\OsuButton.cs" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="$(SolutionDir)\osu-framework\osu.Framework\osu.Framework.csproj">