示例#1
0
        /// <summary>
        /// 显示窗体
        /// </summary>
        /// <param name="title"></param>
        /// <param name="xtraForm"></param>
        private void ShowForm(string title)
        {
            splashScreenManager.ShowWaitForm();
            Cursor currentCursor = Cursor.Current;

            Cursor.Current = Cursors.WaitCursor;

            XtraFormBase xtraForm = null;

            switch (title)
            {
            case "搜索":
                Cursor.Current = currentCursor;
                splashScreenManager.CloseWaitForm();
                searchForm.StartPosition = FormStartPosition.CenterParent;
                searchForm.ShowDialog();
                return;

            case "整板结果":
                xtraForm = new ShowDetailNew();
                break;

            case "整板统计":
                xtraForm = new Statistical();
                break;
                //case "我是测试2":
                //    xtraForm = new ShowDetail2();
                //    break;
            }
            try
            {
                XtraMdiTabPage tabPage = GetTabPage(title);
                if (tabPage != null)
                {
                    xtraTabbedMdiManager1.SelectedPage = tabPage;
                }
                else if (xtraForm != null)
                {
                    xForms.Add(title, xtraForm);
                    xtraForm.Text      = title;
                    xtraForm.MdiParent = this;
                    xtraForm.Show();
                }
            }
            finally { Cursor.Current = currentCursor; splashScreenManager.CloseWaitForm(); }
        }
示例#2
0
 public void XtraFormReset(XtraFormBase formBase)
 {
     xtraFormBase = formBase;
 }