Prevents throw exception if Border is null.

This commit is contained in:
BDisp
2023-08-15 11:20:19 +01:00
parent 4ad63df10e
commit 977f907cb4

View File

@@ -284,7 +284,7 @@ namespace Terminal.Gui {
/// <inheritdoc/>
public override void OnCanFocusChanged ()
{
if (Border.Child != null) {
if (Border?.Child != null) {
Border.Child.CanFocus = CanFocus;
}
base.OnCanFocusChanged ();