Ejemplo n.º 1
0
        public void AddView(IView view)
        {
            var layoutControl = new LayoutControl();
            var xtraTabPage   = new XtraTabPage();

            xtraTabPage.FillWith(layoutControl);
            xtraTabControl.TabPages.Add(xtraTabPage);
            xtraTabPage.Text = view.Caption;
            AddViewToGroup(layoutControl.Root, view);

            AddEmptyPlaceHolder(layoutControl);
        }
        public static void InitializeFrom(this XtraTabPage page, IView viewToAdd)
        {
            var control = viewToAdd as Control;

            if (control == null)
            {
                return;
            }
            page.FillWith(viewToAdd);
            page.Text  = viewToAdd.Caption;
            page.Image = viewToAdd.ApplicationIcon.ToImage(UIConstants.ICON_SIZE_TAB);
        }