void Populate()
{
PropertyDescriptorCollection properties;
tree.SaveStatus ();
tree.Clear ();
tree.PropertySort = propertySort;
if (currentObject == null) {
properties = new PropertyDescriptorCollection (new PropertyDescriptor[0] {});
tree.Populate (properties, currentObject);
}
else {
foreach (object prov in propertyProviders) {
properties = selectedTab.GetProperties (prov);
tree.Populate (properties, prov);
}
}
tree.RestoreStatus ();
}