public override void Initialize(object owner, object value) { this.OwnerElement = (RadElement)(owner as PropertyGridItemElement); PropertyGridUITypeEditorElement editorElement = this.EditorElement as PropertyGridUITypeEditorElement; PropertyGridItem data = ((PropertyGridItemElementBase)this.OwnerElement).Data as PropertyGridItem; editorElement.EditedType = data.PropertyType; editorElement.Editor = (UITypeEditor)data.PropertyDescriptor.GetEditor(typeof(UITypeEditor)); editorElement.Converter = data.TypeConverter; editorElement.Text = value != null?value.ToString() : string.Empty; this.Value = value; this.originalValue = value; }
public PropertyGridUITypeEditor(PropertyGridUITypeEditorElement editor) { this.editor = editor; }
public PropertyGridUITypeEditor() { this.editor = this.CreateEditorElement() as PropertyGridUITypeEditorElement; }