mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2024-12-24 15:41:49 +01:00
Make sure to perform null check before invoking event handler
This commit is contained in:
parent
2cf33e1bba
commit
9fd97ee467
@ -160,7 +160,7 @@ namespace DS4Windows
|
||||
if (Byte.TryParse(WindowsEnumerator.WindowText(EditWindows[3].hWnd), out red))
|
||||
if (Byte.TryParse(WindowsEnumerator.WindowText(EditWindows[4].hWnd), out green))
|
||||
if (Byte.TryParse(WindowsEnumerator.WindowText(EditWindows[5].hWnd), out blue))
|
||||
OnUpdateColor(Color.FromArgb(red, green, blue), EventArgs.Empty);
|
||||
OnUpdateColor?.Invoke(Color.FromArgb(red, green, blue), EventArgs.Empty);
|
||||
}
|
||||
}
|
||||
// Always call the base class hook procedure.
|
||||
|
Loading…
Reference in New Issue
Block a user