[DllImport("advapi32.dll", SetLastError=true)]
static extern int ReleasePowerRequirement(int hPowerReq);
Do you know one? Please contribute it!
You can get hPowerReq by calling SetPowerRequirement.
Please add some!
int backlightHandle;
public KeepBacklightAlive()
{
backlightHandle = NativeMethods.SetPowerRequirement("BKL1:", DevicePowerState.D0, 1, null, 0);
}
public void StopKeepingBacklightAlive()
{
NativeMethods.ReleasePowerRequirement(backlightHandle);
}