public override object EditValue( System.ComponentModel.ITypeDescriptorContext context, System.IServiceProvider provider, object value) { if (provider != null) { IWindowsFormsEditorService editorService = provider.GetService( typeof(IWindowsFormsEditorService)) as IWindowsFormsEditorService; if (editorService != null) { Progress ctrl = (Progress)context.Instance; ProgressValueDropDown selectionControl = new ProgressValueDropDown( (int)value, ctrl.Maximum, editorService); editorService.DropDownControl(selectionControl); value = selectionControl.Value; } } return(value); }
public override object EditValue( System.ComponentModel.ITypeDescriptorContext context, System.IServiceProvider provider, object value) { if (provider != null) { IWindowsFormsEditorService editorService = provider.GetService( typeof(IWindowsFormsEditorService)) as IWindowsFormsEditorService; if (editorService != null) { Progress ctrl = (Progress)context.Instance; ProgressValueDropDown selectionControl = new ProgressValueDropDown( (int)value, ctrl.Maximum, editorService); editorService.DropDownControl(selectionControl); value = selectionControl.Value; } } return value; }