Fix installer nav buttons not being translated

This commit is contained in:
pizzaboxer 2024-10-08 10:02:36 +01:00
parent d297c5a354
commit c4918322fd
No known key found for this signature in database
GPG Key ID: 59D4A1DBAD0F2BA8
6 changed files with 18 additions and 3 deletions

View File

@ -483,6 +483,15 @@ namespace Bloxstrap.Resources {
}
}
/// <summary>
/// Looks up a localized string similar to Install.
/// </summary>
public static string Common_Navigation_Install {
get {
return ResourceManager.GetString("Common.Navigation.Install", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Next.
/// </summary>

View File

@ -1221,4 +1221,8 @@ Would you like to enable test mode?</value>
<data name="About.Translators.Description" xml:space="preserve">
<value>All of Bloxstrap's translations are crowdsourced through [Crowdin]({0}). Everyone listed here are people who generously volunteered their time and effort to help localise Bloxstrap. A massive thank you to everyone here!</value>
</data>
<data name="Common.Navigation.Install" xml:space="preserve">
<value>Install</value>
<comment>The word "Install" is being used as a verb in this instance, like the other navigation button texts of "Next" and "Back"</comment>
</data>
</root>

View File

@ -7,8 +7,10 @@
xmlns:ui="http://schemas.lepo.co/wpfui/2022/xaml"
xmlns:base="clr-namespace:Bloxstrap.UI.Elements.Base"
xmlns:resources="clr-namespace:Bloxstrap.Resources"
xmlns:dmodels="clr-namespace:Bloxstrap.UI.ViewModels.Installer"
xmlns:local="clr-namespace:Bloxstrap.UI.Elements.Installer"
mc:Ignorable="d"
d:DataContext="{d:DesignInstance dmodels:MainWindowViewModel, IsDesignTimeCreatable=True}"
Title="{x:Static resources:Strings.Installer_Title}"
Height="540" Width="840" MinWidth="840"
Background="{ui:ThemeResource ApplicationBackgroundBrush}"

View File

@ -28,7 +28,7 @@ namespace Bloxstrap.UI.Elements.Installer.Pages
{
if (Window.GetWindow(this) is MainWindow window)
{
window.SetNextButtonText("Next");
window.SetNextButtonText(Strings.Common_Navigation_Next);
window.SetButtonEnabled("back", false);
}
}

View File

@ -29,7 +29,7 @@ namespace Bloxstrap.UI.Elements.Installer.Pages
{
if (Window.GetWindow(this) is MainWindow window)
{
window.SetNextButtonText("Install");
window.SetNextButtonText(Strings.Common_Navigation_Install);
window.NextPageCallback += NextPageCallback;
}
}

View File

@ -25,7 +25,7 @@ namespace Bloxstrap.UI.Elements.Installer.Pages
private void UiPage_Loaded(object sender, RoutedEventArgs e)
{
if (Window.GetWindow(this) is MainWindow window)
window.SetNextButtonText("Next");
window.SetNextButtonText(Strings.Common_Navigation_Next);
_viewModel.DoChecks();
}