コード例 #1
0
        public override void Assign(RepositoryItem item)
        {
            BeginUpdate();
            try
            {
                base.Assign(item);
                var source = item as GenericGridLookUpEditRepositoryItem;
                if (source == null)
                {
                    return;
                }

                if (source.ListHandler != null)
                {
                    ListHandler = source.ListHandler;
                }
                if (source.OnSetDataSource != null)
                {
                    OnSetDataSource = source.OnSetDataSource;
                }
            }
            finally
            {
                EndUpdate();
            }
        }
コード例 #2
0
        public GenericGridLookUpEditRepositoryItem()
        {
            //Init ListHandler
            ListHandler = EmptyLookupListHandler.GetLookupHandler();

            //Setting Defaults
            DataSource       = ListHandler.LookupType;
            DisplayMember    = ListHandler.ValuePropertyName;
            ValueMember      = ListHandler.ValuePropertyName;
            PopupFormMinSize = new Size(400, 400);
            ImmediatePopup   = true;
            NullText         = string.Empty;
            BestFitMode      = BestFitMode.BestFitResizePopup;

            if (View != null)
            {
                View.BestFitMaxRowCount = BestFitMaxRowCountValue;
            }
        }