Esempio n. 1
0
        public OutputPropertiesForm(TestCase testcase, OutputPropertiesMap output)
        {
            InitializeComponent();
            DialogResult  = DialogResult.Cancel;
            this.testcase = testcase;

            this.output = new OutputPropertiesMap();

            foreach (var kv in output)
            {
                this.output.Add(kv.Key, kv.Value);
            }

            FillList();
        }
Esempio n. 2
0
        public override object EditValue(System.ComponentModel.ITypeDescriptorContext context, IServiceProvider provider, object value)
        {
            TestCase testcase = context.Instance as TestCase;

            if (value == null)
            {
                value = new OutputPropertiesMap();
            }

            OutputPropertiesMap output = value as OutputPropertiesMap;

            if (testcase != null)
            {
                OutputPropertiesForm form = new OutputPropertiesForm(testcase, output);

                if (form.ShowDialog() == DialogResult.OK)
                {
                    return(form.Output);
                }
            }

            return(output);
        }