* UIDropDown: 解决下拉控件关闭报错

This commit is contained in:
Sunny 2022-06-21 18:00:55 +08:00
parent 2d92b91bcd
commit ac4fef073e

View File

@ -160,7 +160,17 @@ namespace Sunny.UI
return itemForm;
}
set => itemForm = value;
set
{
itemForm = value;
if (itemForm != null)
{
itemForm.ValueChanged += ItemForm_ValueChanged;
itemForm.VisibleChanged += ItemForm_VisibleChanged;
itemForm.Closed += ItemForm_Closed;
}
}
}
private void ItemForm_Closed(object sender, ToolStripDropDownClosedEventArgs e)