mirror of
https://github.com/jkocon/g-helper.git
synced 2026-02-23 13:00:52 +01:00
Slash lightning tweaks
This commit is contained in:
@@ -19,6 +19,7 @@ namespace GHelper.AnimeMatrix
|
||||
public SlashDevice? deviceSlash;
|
||||
|
||||
public static bool lidClose = false;
|
||||
private static bool _wakeUp = false;
|
||||
|
||||
double[]? AudioValues;
|
||||
WasapiCapture? AudioDevice;
|
||||
@@ -91,15 +92,21 @@ namespace GHelper.AnimeMatrix
|
||||
return;
|
||||
}
|
||||
|
||||
if (wakeUp) deviceSlash.WakeUp();
|
||||
if (wakeUp) _wakeUp = true;
|
||||
|
||||
if (brightness == 0 || (auto && SystemInformation.PowerStatus.PowerLineStatus != PowerLineStatus.Online) || (lid && lidClose))
|
||||
{
|
||||
//deviceSlash.Init();
|
||||
deviceSlash.Init();
|
||||
deviceSlash.SetOptions(false, 0, 0);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (_wakeUp)
|
||||
{
|
||||
deviceSlash.WakeUp();
|
||||
_wakeUp = false;
|
||||
}
|
||||
|
||||
deviceSlash.Init();
|
||||
deviceSlash.SetMode((SlashMode)running);
|
||||
deviceSlash.SetOptions(true, brightness, inteval);
|
||||
|
||||
Reference in New Issue
Block a user