public virtual void FillValues(List <BOF.ComboChooserBase.ComboItem> items)
        {
            List <BOF.ComboChooserBase.ComboItem> lst = (List <BOF.ComboChooserBase.ComboItem>)base.DataSource;
            bool equal = (lst != null && items != null && lst.Count == items.Count);

            if (equal)
            {
                for (int i = 0; i < items.Count; i++)
                {
                    BOF.ComboChooserBase.ComboItem item_old = lst[i];
                    BOF.ComboChooserBase.ComboItem item_new = items[i];
                    equal &= (item_old.Key == item_new.Key);
                }
            }
            if (!equal)
            {
                BOF.ComboChooserBase.ComboItem oldValue = this.SelectedItem as BOF.ComboChooserBase.ComboItem;
                base.DataSource    = items;
                base.ValueMember   = "Value";
                base.DisplayMember = "Key";

                if (oldValue != null)
                {
                    int ind = items.FindIndex(delegate(BOF.ComboChooserBase.ComboItem item)
                    {
                        return(oldValue.Key == item.Key);
                    });
                    if (ind >= 0)
                    {
                        this.SelectedIndex = ind;
                    }
                }
            }
        }
        public virtual void FillValues(List <BOF.ComboChooserBase.ComboItem> items, object value)
        {
            event_disabled = true;
            List <BOF.ComboChooserBase.ComboItem> lst = (List <BOF.ComboChooserBase.ComboItem>)base.DataSource;
            bool equal = (lst != null && items != null && lst.Count == items.Count);

            if (equal)
            {
                for (int i = 0; i < items.Count; i++)
                {
                    BOF.ComboChooserBase.ComboItem item_old = lst[i];
                    BOF.ComboChooserBase.ComboItem item_new = items[i];
                    equal &= (item_old.Key == item_new.Key);
                }
            }
            if (!equal)
            {
                base.DataSource    = items;
                base.ValueMember   = "Value";
                base.DisplayMember = "Key";
            }
            event_disabled = false;
            Value          = value;
        }