mirror of
https://github.com/Ellpeck/Illumilib.git
synced 2024-12-26 01:29:24 +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() {
|
public override void Dispose() {
|
||||||
base.Dispose();
|
base.Dispose();
|
||||||
this.ClearBitmap();
|
this.ClearBitmap();
|
||||||
|
try {
|
||||||
LogitechGsdk.LogiLedShutdown();
|
LogitechGsdk.LogiLedShutdown();
|
||||||
|
} catch {
|
||||||
|
// ignored
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void SetAllLighting(float r, float g, float b) {
|
public override void SetAllLighting(float r, float g, float b) {
|
||||||
|
|
|
@ -22,7 +22,11 @@ namespace Illumilib.System {
|
||||||
|
|
||||||
public override void Dispose() {
|
public override void Dispose() {
|
||||||
base.Dispose();
|
base.Dispose();
|
||||||
|
try {
|
||||||
this.chroma?.UninitializeAsync();
|
this.chroma?.UninitializeAsync();
|
||||||
|
} catch {
|
||||||
|
// ignored
|
||||||
|
}
|
||||||
this.effectOutdated = true;
|
this.effectOutdated = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue