Explorar o código

Add version in all window titles (#935)

This add the AppVeyor build version (added in #927) in the console window title and in the GUI title (when you are on the games list or when an emulated game is closed).
Ac_K %!s(int64=6) %!d(string=hai) anos
pai
achega
949bb81a9e
Modificáronse 2 ficheiros con 4 adicións e 3 borrados
  1. 2 2
      Ryujinx/Program.cs
  2. 2 1
      Ryujinx/Ui/MainWindow.cs

+ 2 - 2
Ryujinx/Program.cs

@@ -22,10 +22,10 @@ namespace Ryujinx
                 EnableHighResolution = true
                 EnableHighResolution = true
             });
             });
 
 
-            Console.Title = "Ryujinx Console";
-
             Version = Assembly.GetEntryAssembly().GetCustomAttribute<AssemblyInformationalVersionAttribute>().InformationalVersion;
             Version = Assembly.GetEntryAssembly().GetCustomAttribute<AssemblyInformationalVersionAttribute>().InformationalVersion;
 
 
+            Console.Title = $"Ryujinx Console {Version}";
+
             string systemPath = Environment.GetEnvironmentVariable("Path", EnvironmentVariableTarget.Machine);
             string systemPath = Environment.GetEnvironmentVariable("Path", EnvironmentVariableTarget.Machine);
             Environment.SetEnvironmentVariable("Path", $"{Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "bin")};{systemPath}");
             Environment.SetEnvironmentVariable("Path", $"{Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "bin")};{systemPath}");
 
 

+ 2 - 1
Ryujinx/Ui/MainWindow.cs

@@ -118,6 +118,7 @@ namespace Ryujinx.Ui
             ApplyTheme();
             ApplyTheme();
 
 
             _mainWin.Icon            = new Gdk.Pixbuf(Assembly.GetExecutingAssembly(), "Ryujinx.Ui.assets.Icon.png");
             _mainWin.Icon            = new Gdk.Pixbuf(Assembly.GetExecutingAssembly(), "Ryujinx.Ui.assets.Icon.png");
+            _mainWin.Title           = $"Ryujinx {Program.Version}";
             _stopEmulation.Sensitive = false;
             _stopEmulation.Sensitive = false;
 
 
             if (ConfigurationState.Instance.Ui.GuiColumns.FavColumn)        _favToggle.Active        = true;
             if (ConfigurationState.Instance.Ui.GuiColumns.FavColumn)        _favToggle.Active        = true;
@@ -427,7 +428,7 @@ namespace Ryujinx.Ui
 
 
                 _gameTableWindow.Expand = true;
                 _gameTableWindow.Expand = true;
 
 
-                this.Window.Title = "Ryujinx";
+                this.Window.Title = $"Ryujinx {Program.Version}";
 
 
                 _emulationContext = null;
                 _emulationContext = null;
                 _gameLoaded       = false;
                 _gameLoaded       = false;