Fix nullref due to screens now being removed from parent

This commit is contained in:
smoogipoo 2019-01-31 15:02:07 +09:00
parent b90207fa54
commit bdaff27575
1 changed files with 2 additions and 1 deletions

View File

@ -164,11 +164,12 @@ protected override bool OnHover(HoverEvent e)
protected override void OnHoverLost(HoverLostEvent e)
{
if (GetContainingInputManager().HoveredDrawables.Contains(visualSettings))
if (GetContainingInputManager()?.HoveredDrawables.Contains(visualSettings) == true)
{
// show user setting preview
UpdateBackgroundElements();
}
base.OnHoverLost(e);
}