move AboutInfo struct to another file
This commit is contained in:
parent
535ec44f84
commit
36a09f343a
2 changed files with 12 additions and 10 deletions
9
Ryujinx/Ui/AboutInfo.cs
Normal file
9
Ryujinx/Ui/AboutInfo.cs
Normal file
|
@ -0,0 +1,9 @@
|
|||
namespace Ryujinx.UI
|
||||
{
|
||||
public struct AboutInfo
|
||||
{
|
||||
public string InstallVersion;
|
||||
public string InstallCommit;
|
||||
public string InstallBranch;
|
||||
}
|
||||
}
|
|
@ -12,14 +12,7 @@ namespace Ryujinx.UI
|
|||
{
|
||||
public class AboutWindow : Window
|
||||
{
|
||||
private struct Info
|
||||
{
|
||||
public string InstallVersion;
|
||||
public string InstallCommit;
|
||||
public string InstallBranch;
|
||||
}
|
||||
|
||||
private static Info Information { get; set; }
|
||||
private static AboutInfo AboutInformation { get; set; }
|
||||
|
||||
#pragma warning disable CS0649
|
||||
#pragma warning disable IDE0044
|
||||
|
@ -52,10 +45,10 @@ namespace Ryujinx.UI
|
|||
|
||||
using (Stream stream = File.OpenRead(System.IO.Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "RyuFS", "Installer", "Config", "Config.json")))
|
||||
{
|
||||
Information = JsonSerializer.Deserialize<Info>(stream, resolver);
|
||||
AboutInformation = JsonSerializer.Deserialize<AboutInfo>(stream, resolver);
|
||||
}
|
||||
|
||||
_versionText.Text = $"Version {Information.InstallVersion} - {Information.InstallBranch} ({Information.InstallCommit})";
|
||||
_versionText.Text = $"Version {AboutInformation.InstallVersion} - {AboutInformation.InstallBranch} ({AboutInformation.InstallCommit})";
|
||||
}
|
||||
catch
|
||||
{
|
||||
|
|
Loading…
Add table
Reference in a new issue