mirror of
https://github.com/Ellpeck/Illumilib.git
synced 2024-11-16 18:13:12 +01:00
fixed a rare exception when lighting systems dispose
This commit is contained in:
parent
f640d05fa5
commit
614facddaf
2 changed files with 10 additions and 2 deletions
|
@ -20,7 +20,11 @@ namespace Illumilib.System {
|
|||
public override void Dispose() {
|
||||
base.Dispose();
|
||||
this.ClearBitmap();
|
||||
LogitechGsdk.LogiLedShutdown();
|
||||
try {
|
||||
LogitechGsdk.LogiLedShutdown();
|
||||
} catch {
|
||||
// ignored
|
||||
}
|
||||
}
|
||||
|
||||
public override void SetAllLighting(float r, float g, float b) {
|
||||
|
|
|
@ -22,7 +22,11 @@ namespace Illumilib.System {
|
|||
|
||||
public override void Dispose() {
|
||||
base.Dispose();
|
||||
this.chroma?.UninitializeAsync();
|
||||
try {
|
||||
this.chroma?.UninitializeAsync();
|
||||
} catch {
|
||||
// ignored
|
||||
}
|
||||
this.effectOutdated = true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue