Make sure we don't try to reference the hotKeyButton if not created.

This commit is contained in:
Lars Brubaker 2017-03-09 10:31:01 -08:00
parent 8c1c999818
commit 9cfe610f84

View file

@ -89,7 +89,8 @@ namespace MatterHackers.MatterControl
this.KeyDown += (sender, e) =>
{
if (!hotKeyButton.Checked)
if (hotKeyButton == null ||
!hotKeyButton.Checked)
{
return;
}