public PropertyDescriptorCollection GetProperties(Attribute[] attributes) { return(WebClientValueCollection.GetWebClientProperties(this, _propertyNames, attributes)); //PropertyDescriptorCollection ps = TypeDescriptor.GetProperties(this, attributes,true); //List<PropertyDescriptor> lst = new List<PropertyDescriptor>(); //foreach (PropertyDescriptor p in ps) //{ // if (_propertyNames.Contains(p.Name)) // { // lst.Add(p); // } //} //WebClientValueCollection.AddPropertyDescs(lst, _customValues); //return new PropertyDescriptorCollection(lst.ToArray()); }
public PropertyDescriptorCollection GetProperties(Attribute[] attributes) { PropertyDescriptorCollection pl = WebClientValueCollection.GetWebClientProperties(this, _propertyNames, attributes); PropertyDescriptorCollection lst = TypeDescriptor.GetProperties(_listBox, true); foreach (PropertyDescriptor p in lst) { if (_listpropertyNames.Contains(p.Name)) { Attribute[] attrs; if (p.Attributes != null) { attrs = new Attribute[p.Attributes.Count]; p.Attributes.CopyTo(attrs, 0); } else { attrs = new Attribute[] { }; } pl.Add(new PropertyDescriptorListBox(this, p, attrs)); } } return(pl); }
public PropertyDescriptorCollection GetProperties(Attribute[] attributes) { return(WebClientValueCollection.GetWebClientProperties(this, _propertyNames, attributes)); }