Use ClickableText for navigating to builds; Fix typo

This commit is contained in:
HoutarouOreki 2018-07-22 05:34:55 +02:00
parent 80808bddbf
commit c5bdfb8857
2 changed files with 11 additions and 10 deletions

View File

@ -66,7 +66,7 @@ namespace osu.Game.Overlays.Changelog
});
Add(changelogContentGroup = new ChangelogContentGroup(build, false)
{
BuildRequested = () => ShowBuild(build),
BuildRequested = () => showBuild(build),
});
changelogContentGroup.GenerateText(build.ChangelogEntries);
}
@ -82,20 +82,26 @@ namespace osu.Game.Overlays.Changelog
};
}
/// <summary>
/// Doesn't send back that the build has changed
/// </summary>
public void ShowBuild(APIChangelog changelog)
{
fetchAndShowChangelogBuild(changelog);
CurrentBuild = changelog;
}
public void ShowListing() => fetchAndShowChangelog();
/// <summary>
/// Sends back that the build has changed
/// </summary>
private void showBuild(APIChangelog changelog)
{
ShowBuild(changelog);
OnBuildChanged();
}
public void ShowListing() => fetchAndShowChangelog();
private void showNext()
{
if (CurrentBuild.Versions.Next != null)

View File

@ -149,18 +149,13 @@ namespace osu.Game.Overlays.Changelog
TextSize = 20, // web: 18,
Font = @"Exo2.0-Medium",
},
new SpriteText
new ClickableText
{
Text = build.DisplayVersion,
TextSize = 20, // web: 18,
Font = @"Exo2.0-Light",
Colour = StreamColour.FromStreamName(build.UpdateStream.Name),
},
new ClickableText
{
Text = " ok ",
TextSize = 20,
Action = BuildRequested,
Action = () => BuildRequested(),
},
}
},