mirror of
https://github.com/ppy/osu.git
synced 2025-01-19 15:02:54 +08:00
Add button to settings to show lazer upgrade guide
This commit is contained in:
parent
f434d4d60f
commit
91bde14fb3
@ -1,12 +1,11 @@
|
||||
// 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.
|
||||
|
||||
#nullable disable
|
||||
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Localisation;
|
||||
using osu.Game.Graphics;
|
||||
using osu.Game.Localisation;
|
||||
using osu.Game.Overlays.Settings.Sections.General;
|
||||
|
||||
@ -15,7 +14,10 @@ namespace osu.Game.Overlays.Settings.Sections
|
||||
public partial class GeneralSection : SettingsSection
|
||||
{
|
||||
[Resolved(CanBeNull = true)]
|
||||
private FirstRunSetupOverlay firstRunSetupOverlay { get; set; }
|
||||
private FirstRunSetupOverlay? firstRunSetupOverlay { get; set; }
|
||||
|
||||
[Resolved(CanBeNull = true)]
|
||||
private OsuGame? game { get; set; }
|
||||
|
||||
public override LocalisableString Header => GeneralSettingsStrings.GeneralSectionHeader;
|
||||
|
||||
@ -24,15 +26,24 @@ namespace osu.Game.Overlays.Settings.Sections
|
||||
Icon = FontAwesome.Solid.Cog
|
||||
};
|
||||
|
||||
public GeneralSection()
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(OsuColour colours)
|
||||
{
|
||||
Children = new Drawable[]
|
||||
{
|
||||
new SettingsButton
|
||||
{
|
||||
Text = GeneralSettingsStrings.RunSetupWizard,
|
||||
TooltipText = FirstRunSetupOverlayStrings.FirstRunSetupDescription,
|
||||
Action = () => firstRunSetupOverlay?.Show(),
|
||||
},
|
||||
new SettingsButton
|
||||
{
|
||||
Text = "Learn more about lazer",
|
||||
TooltipText = "Check out the feature comparison and FAQ",
|
||||
BackgroundColour = colours.YellowDark,
|
||||
Action = () => game?.ShowWiki(@"Help_centre/Upgrading_to_lazer")
|
||||
},
|
||||
new LanguageSettings(),
|
||||
new UpdateSettings(),
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user