mirror of
https://github.com/Artemis-RGB/Artemis
synced 2026-11-12 11:56:30 +00:00
Plugins - Added timeout for plugin enable
Plugins - Delete lock file even on exception, only leave it in place on crash Plugins - Added --ignore-plugin-lock startup argument UI - Renamed -autorun argument to --autorun
This commit is contained in:
1 parent
40eda4fc2b
commit
ac45c4d5d3
11 files changed
+56
-27
No files matched your search
@@ -1,6 +1,8 @@
|
||||
using System.IO;
|
||||
using System.Threading.Tasks;
|
||||
using Artemis.Core.Plugins.Abstract;
|
||||
using Artemis.Core.Services.Interfaces;
|
||||
using Microsoft.Win32;
|
||||
using RGB.NET.Core;
|
||||
using RGB.NET.Devices.Corsair;
|
||||
|
||||
@@ -22,6 +24,21 @@ namespace Artemis.Plugins.Devices.Corsair
|
||||
RGB.NET.Devices.Corsair.CorsairDeviceProvider.PossibleX64NativePaths.Add(Path.Combine(PluginInfo.Directory.FullName, "x64", "CUESDK.x64_2017.dll"));
|
||||
RGB.NET.Devices.Corsair.CorsairDeviceProvider.PossibleX86NativePaths.Add(Path.Combine(PluginInfo.Directory.FullName, "x86", "CUESDK_2017.dll"));
|
||||
_rgbService.AddDeviceProvider(RgbDeviceProvider);
|
||||
|
||||
SystemEvents.PowerModeChanged += SystemEventsOnPowerModeChanged;
|
||||
}
|
||||
|
||||
private void SystemEventsOnPowerModeChanged(object sender, PowerModeChangedEventArgs e)
|
||||
{
|
||||
// This may be required for some device providers
|
||||
// if (e.Mode == PowerModes.Resume)
|
||||
// {
|
||||
// Task.Run(async () =>
|
||||
// {
|
||||
// await Task.Delay(5000);
|
||||
// RGB.NET.Devices.Corsair.CorsairDeviceProvider.Instance.Initialize();
|
||||
// });
|
||||
// }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -31,6 +31,8 @@ namespace Artemis.Plugins.Modules.General
|
||||
|
||||
DataModel.IntsList[0] = _rand.Next();
|
||||
DataModel.IntsList[2] = _rand.Next();
|
||||
|
||||
base.Update(deltaTime);
|
||||
}
|
||||
|
||||
public override void EnablePlugin()
|
||||
|
||||
Reference in new issue
Block a user