mirror of
https://github.com/jkocon/g-helper.git
synced 2026-02-23 13:00:52 +01:00
Optimus check
This commit is contained in:
@@ -1688,7 +1688,20 @@ namespace GHelper
|
||||
|
||||
int status = 1;
|
||||
|
||||
if (eco == 1) HardwareControl.KillGPUApps();
|
||||
if (eco == 1)
|
||||
{
|
||||
if (NvidiaSmi.GetDisplayActiveStatus())
|
||||
{
|
||||
DialogResult dialogResult = MessageBox.Show(Properties.Strings.EnableOptimusText, Properties.Strings.EnableOptimusTitle, MessageBoxButtons.YesNo);
|
||||
if (dialogResult == DialogResult.No)
|
||||
{
|
||||
InitGPUMode();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
HardwareControl.KillGPUApps();
|
||||
}
|
||||
|
||||
Logger.WriteLine($"Running eco command {eco}");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user