Browse Source

PropertyGrid: fixed issue where an ExpandableObject would only show properties of a base class or interface.

import/raw
brianlagunas_cp 15 years ago
parent
commit
4c7af54f3a
  1. 5
      Main/Source/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/PropertyGrid/Implementation/PropertyItem.cs

5
Main/Source/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/PropertyGrid/Implementation/PropertyItem.cs

@ -385,12 +385,15 @@ namespace Microsoft.Windows.Controls.PropertyGrid
private void GetChildProperties() private void GetChildProperties()
{ {
PropertyDescriptorCollection descriptors = PropertyDescriptor.GetChildProperties(); if (Value == null)
return;
var propertyItems = new List<PropertyItem>(); var propertyItems = new List<PropertyItem>();
try try
{ {
PropertyDescriptorCollection descriptors = PropertyGridUtilities.GetPropertyDescriptors(Value);
foreach (PropertyDescriptor descriptor in descriptors) foreach (PropertyDescriptor descriptor in descriptors)
{ {
if (descriptor.IsBrowsable) if (descriptor.IsBrowsable)

Loading…
Cancel
Save