mirror of
https://github.com/ppy/osu
synced 2025-03-11 05:49:12 +00:00
Show last step on back button as well
This commit is contained in:
parent
37ae39f5fe
commit
a078440012
@ -133,7 +133,7 @@ namespace osu.Game.Overlays
|
|||||||
{
|
{
|
||||||
BackButton = new DangerousTriangleButton
|
BackButton = new DangerousTriangleButton
|
||||||
{
|
{
|
||||||
Width = 200,
|
Width = 300,
|
||||||
Text = CommonStrings.Back,
|
Text = CommonStrings.Back,
|
||||||
Action = showPreviousStep,
|
Action = showPreviousStep,
|
||||||
Enabled = { Value = false },
|
Enabled = { Value = false },
|
||||||
@ -307,12 +307,22 @@ namespace osu.Game.Overlays
|
|||||||
if (currentStepIndex == null)
|
if (currentStepIndex == null)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (currentStepIndex == 0)
|
bool isFirstStep = currentStepIndex == 0;
|
||||||
|
bool isLastStep = currentStepIndex == steps.Length - 1;
|
||||||
|
|
||||||
|
if (isFirstStep)
|
||||||
|
{
|
||||||
|
BackButton.Text = CommonStrings.Back;
|
||||||
NextButton.Text = FirstRunSetupOverlayStrings.GetStarted;
|
NextButton.Text = FirstRunSetupOverlayStrings.GetStarted;
|
||||||
else if (currentStepIndex < steps.Length - 1)
|
}
|
||||||
NextButton.Text = new TranslatableString(@"_", @"{0} ({1})", CommonStrings.Next, steps[currentStepIndex.Value + 1].Description);
|
|
||||||
else
|
else
|
||||||
NextButton.Text = CommonStrings.Finish;
|
{
|
||||||
|
BackButton.Text = new TranslatableString(@"_", @"{0} ({1})", CommonStrings.Back, steps[currentStepIndex.Value - 1].Description);
|
||||||
|
|
||||||
|
NextButton.Text = isLastStep
|
||||||
|
? CommonStrings.Finish
|
||||||
|
: new TranslatableString(@"_", @"{0} ({1})", CommonStrings.Next, steps[currentStepIndex.Value + 1].Description);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private class FirstRunStep
|
private class FirstRunStep
|
||||||
|
Loading…
Reference in New Issue
Block a user