forgot we are now using ChoiceSetting.ChoiceSettingValue as Value for ChoiceSetting

This commit is contained in:
Michael Becker 2022-01-16 13:27:31 -05:00
parent 2aecf3357b
commit eabb9efeb8
No known key found for this signature in database
GPG Key ID: 98C333A81F18C22C

View File

@ -342,7 +342,7 @@ namespace UniversalEditor.UserInterface
}
else if (eo is ChoiceSetting)
{
object choice = (eo as ChoiceSetting).GetValue();
ChoiceSetting.ChoiceSettingValue choice = (ChoiceSetting.ChoiceSettingValue) (eo as ChoiceSetting).GetValue();
if (choice != null)
{
Type[] interfaces = pi.PropertyType.GetInterfaces();
@ -357,7 +357,7 @@ namespace UniversalEditor.UserInterface
}
if (convertible)
{
pi.SetValue(obj, Convert.ChangeType(choice, pi.PropertyType), null);
pi.SetValue(obj, Convert.ChangeType(choice.Value, pi.PropertyType), null);
}
else
{