mirror of
https://github.com/jkocon/g-helper.git
synced 2026-02-23 13:00:52 +01:00
Minor tweaks
This commit is contained in:
@@ -493,14 +493,18 @@ public class NativeMethods
|
|||||||
if (device.outputTechnology == DISPLAYCONFIG_VIDEO_OUTPUT_TECHNOLOGY.DISPLAYCONFIG_OUTPUT_TECHNOLOGY_INTERNAL)
|
if (device.outputTechnology == DISPLAYCONFIG_VIDEO_OUTPUT_TECHNOLOGY.DISPLAYCONFIG_OUTPUT_TECHNOLOGY_INTERNAL)
|
||||||
{
|
{
|
||||||
displayNum = count;
|
displayNum = count;
|
||||||
laptopScreen = device.monitorDevicePath;
|
|
||||||
}
|
}
|
||||||
count++;
|
count++;
|
||||||
//Debug.WriteLine(device.outputTechnology);
|
//Debug.WriteLine(device.outputTechnology);
|
||||||
//Debug.WriteLine(device.monitorFriendlyDeviceName);
|
//Debug.WriteLine(device.monitorFriendlyDeviceName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (Screen.AllScreens.Length != count)
|
||||||
|
{
|
||||||
|
Debug.WriteLine("Mismatch between enumerated and available screens");
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
count = 0;
|
count = 0;
|
||||||
foreach (var screen in Screen.AllScreens)
|
foreach (var screen in Screen.AllScreens)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -719,7 +719,7 @@ namespace GHelper
|
|||||||
|
|
||||||
if (Program.config.getConfigPerf("auto_apply_power") == 1)
|
if (Program.config.getConfigPerf("auto_apply_power") == 1)
|
||||||
{
|
{
|
||||||
var timer = new System.Timers.Timer(500);
|
var timer = new System.Timers.Timer(1000);
|
||||||
timer.Elapsed += delegate
|
timer.Elapsed += delegate
|
||||||
{
|
{
|
||||||
timer.Stop();
|
timer.Stop();
|
||||||
@@ -892,6 +892,7 @@ namespace GHelper
|
|||||||
Program.settingsForm.BeginInvoke(delegate
|
Program.settingsForm.BeginInvoke(delegate
|
||||||
{
|
{
|
||||||
InitGPUMode();
|
InitGPUMode();
|
||||||
|
Thread.Sleep(500);
|
||||||
AutoScreen(SystemInformation.PowerStatus.PowerLineStatus);
|
AutoScreen(SystemInformation.PowerStatus.PowerLineStatus);
|
||||||
});
|
});
|
||||||
}).Start();
|
}).Start();
|
||||||
|
|||||||
Reference in New Issue
Block a user