Show performance notifications only when mode changes

This commit is contained in:
seerge
2023-03-03 12:41:53 +01:00
parent 8f215dafab
commit 96c85f69fe
3 changed files with 18 additions and 3 deletions

View File

@@ -30,7 +30,7 @@ public class ASUSWmi
public const int PPT_CPUB0 = 0x001200B0;
public const int PPT_CPUB1 = 0x001200B1;
public const int PPT_CPUA2 = 0x001200A2;
public const int PPT_CPUA2 = 0x001200A2;
public const int PerformanceBalanced = 0;
public const int PerformanceTurbo = 1;

View File

@@ -497,7 +497,7 @@ namespace GHelper
break;
}
int oldMode = Program.config.getConfig("performance_mode");
Program.config.setConfig("performance_"+(int)SystemInformation.PowerStatus.PowerLineStatus, PerformanceMode);
Program.config.setConfig("performance_mode", PerformanceMode);
@@ -515,7 +515,7 @@ namespace GHelper
fans.ResetApplyLabel();
}
if (notify)
if (notify && (oldMode != PerformanceMode))
{
try
{

15
stop-asus-sv.bat Normal file
View File

@@ -0,0 +1,15 @@
sc STOP AsusAppService
sc STOP ASUSLinkNear
sc STOP ASUSLinkRemote
sc STOP ASUSSoftwareManager
sc STOP ASUSSwitch
sc STOP ASUSSystemAnalysis
sc STOP ASUSSystemDiagnosis
sc DELETE AsusAppService
sc DELETE ASUSLinkNear
sc DELETE ASUSLinkRemote
sc DELETE ASUSSoftwareManager
sc DELETE ASUSSwitch
sc DELETE ASUSSystemAnalysis
sc DELETE ASUSSystemDiagnosis