protected override T SelectOverride(EditorCollection <T> editors, PropertyInfo property) { if (property.PropertyType.IsEnum) { return(editors.FirstOrDefault(x => x.Key.TargetType == typeof(Enum))?.Template); } return(default);
protected override T SelectOverride(EditorCollection <T> editors, PropertyInfo property) { var match = editors.FirstOrDefault(x => HasSameTypeAndName(property, x)); return(match?.Template); }
protected override T SelectOverride(EditorCollection <T> editors, PropertyInfo property) { var editorKey = editors.FirstOrDefault(x => x.Key.TargetType == property.PropertyType && !x.Key.Properties.Any()); return(editorKey?.Template); }