public override object EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value)
        {
            bool cancel;
            var  newValue = CustomEditors.Edit(context.Instance, context.PropertyDescriptor.Name, value, out cancel);

            if (cancel)
            {
                return(value);
            }
            else
            {
                return(newValue);
            }
        }
Example #2
0
 protected override object AddObject(object[] currentItems, out bool cancel)
 {
     return(CustomEditors.Edit(Context.Instance, Properties.GROUPBYCOLUMNS, currentItems, out cancel));
 }
        protected override object CreateInstance(Type itemType)
        {
            var newColumn = CustomEditors.Edit(Context.Instance, Properties.GROUPBYCOLUMNS, (Context.Instance as Column).GroupByColumns, out bool cancel) as Column;

            return(newColumn);
        }
 protected override object AddObject(out bool cancel)
 {
     return(CustomEditors.Edit(Context.Instance, Properties.GROUPBYCOLUMNS, (Context.Instance as Column).GroupByColumns, out cancel));
 }