From b81f19613f306267ee0f448d2f23caef74afef79 Mon Sep 17 00:00:00 2001 From: Bruno Macabeus Date: Mon, 11 Jan 2021 15:03:37 +0000 Subject: [PATCH] ui: disable "Simulate Wake-up" when no game is running (#1863) --- Ryujinx/Ui/MainWindow.cs | 10 +++++++--- Ryujinx/Ui/MainWindow.glade | 2 +- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/Ryujinx/Ui/MainWindow.cs b/Ryujinx/Ui/MainWindow.cs index 58cd64014..c197ad127 100644 --- a/Ryujinx/Ui/MainWindow.cs +++ b/Ryujinx/Ui/MainWindow.cs @@ -62,6 +62,7 @@ namespace Ryujinx.Ui [GUI] Box _footerBox; [GUI] Box _statusBar; [GUI] MenuItem _stopEmulation; + [GUI] MenuItem _simulateWakeUpMessage; [GUI] MenuItem _fullScreen; [GUI] CheckMenuItem _startFullScreen; [GUI] CheckMenuItem _favToggle; @@ -140,7 +141,8 @@ namespace Ryujinx.Ui _startFullScreen.Active = true; } - _stopEmulation.Sensitive = false; + _stopEmulation.Sensitive = false; + _simulateWakeUpMessage.Sensitive = false; if (ConfigurationState.Instance.Ui.GuiColumns.FavColumn) _favToggle.Active = true; if (ConfigurationState.Instance.Ui.GuiColumns.IconColumn) _iconToggle.Active = true; @@ -527,8 +529,9 @@ namespace Ryujinx.Ui windowThread.Start(); #endif - _gameLoaded = true; - _stopEmulation.Sensitive = true; + _gameLoaded = true; + _stopEmulation.Sensitive = true; + _simulateWakeUpMessage.Sensitive = true; _firmwareInstallFile.Sensitive = false; _firmwareInstallDirectory.Sensitive = false; @@ -622,6 +625,7 @@ namespace Ryujinx.Ui Task.Run(HandleRelaunch); _stopEmulation.Sensitive = false; + _simulateWakeUpMessage.Sensitive = false; _firmwareInstallFile.Sensitive = true; _firmwareInstallDirectory.Sensitive = true; }); diff --git a/Ryujinx/Ui/MainWindow.glade b/Ryujinx/Ui/MainWindow.glade index c9218a55e..6cefe08aa 100644 --- a/Ryujinx/Ui/MainWindow.glade +++ b/Ryujinx/Ui/MainWindow.glade @@ -138,7 +138,7 @@ - + True False Simulate a Wake-up Message