public void SetCurrentObject(object lastComponent, object [] propertyProviders)
 {
     if (lastComponent != null)
     {
         var selection = new PropertyPadItem(lastComponent, propertyProviders);
         if (currentSelectedObject != selection)
         {
             propertyEditorPanel.SelectedItems.Clear();
             propertyEditorPanel.SelectedItems.Add(selection);
             currentSelectedObject = selection;
         }
     }
 }
Exemple #2
0
        public PropertyPadObjectEditor(PropertyPadItem propertyItem)
        {
            this.propertyItem = propertyItem;
            foreach (object propertyProvider in propertyItem.Providers)
            {
                var props = GetProperties(propertyProvider, null);

                for (int i = 0; i < props.Count; i++)
                {
                    var prop = props [i] as PropertyDescriptor;
                    if (prop.IsBrowsable)
                    {
                        properties.Add(CreatePropertyInfo(prop, propertyProvider));
                    }
                }
            }
        }