Don't read the installer config to get a version string

This commit is contained in:
Alex Barney 2019-12-27 12:04:28 -07:00
parent 4042a5a43b
commit 6012011a57

View file

@ -40,21 +40,8 @@ namespace Ryujinx.Ui
_discordLogo.Pixbuf = new Gdk.Pixbuf(Assembly.GetExecutingAssembly(), "Ryujinx.Ui.assets.DiscordLogo.png", 30 , 30 );
_twitterLogo.Pixbuf = new Gdk.Pixbuf(Assembly.GetExecutingAssembly(), "Ryujinx.Ui.assets.TwitterLogo.png", 30 , 30 );
try
{
IJsonFormatterResolver resolver = CompositeResolver.Create(new[] { StandardResolver.AllowPrivateSnakeCase });
using (Stream stream = File.OpenRead(System.IO.Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "Ryujinx", "Installer", "Config", "Config.json")))
{
AboutInformation = JsonSerializer.Deserialize<AboutInfo>(stream, resolver);
}
_versionText.Text = $"Version {AboutInformation.InstallVersion} - {AboutInformation.InstallBranch} ({AboutInformation.InstallCommit})";
}
catch
{
_versionText.Text = "Unknown Version";
}
// todo: Get version string
_versionText.Text = "Unknown Version";
}
private static void OpenUrl(string url)