领胜LDS 键盘AOI检测项目
wells.liu
2020-07-13 27ec4a74d3ed9aa8ce1ee8e5d0955596c67cb996
src/Bro.UI.Config/MainFrm.cs
@@ -74,10 +74,10 @@
            //});
            m_deserializeMenuFrm = new DeserializeDockContent(GetMenuFromPersistString);
            LoadLayoutFromXML(m_deserializeMenuFrm);
            m_deserializeDeviceRunFrm = new DeserializeDockContent(GetAllFormPersistString);
            _allMenuLoadDoneHandle.Set();
            //LoadLayoutFromXML(m_deserializeMenuFrm);
            //_allMenuLoadDoneHandle.Set();
            Text = SettingHelper.GetProgramDescription();
            string iconPath = SettingHelper.GetProgramIcon();
@@ -157,14 +157,20 @@
                CloseAllDeviceFrm();
                LoadDevices();
                foreach (var dock in dockPanelMain.Contents)
                try
                {
                    MenuFrmBase m = dock as MenuFrmBase;
                    if (m != null && m.Id != frmId)
                    foreach (var dock in dockPanelMain.Contents)
                    {
                        m.DownloadProcess(process);
                        MenuFrmBase m = dock as MenuFrmBase;
                        if (m != null && m.Id != frmId)
                        {
                            m.DownloadProcess(process);
                        }
                    }
                }
                catch (Exception ex)
                {
                }
            });
        }
@@ -254,13 +260,16 @@
        private void MainFrm_Load(object sender, EventArgs e)
        {
            LoadLayoutFromXML(m_deserializeMenuFrm);
            _allMenuLoadDoneHandle.Set();
            AdvancedPwdFrm.OnLoginOK = OnLoginOK;
            SpinWait wait = new SpinWait();
            while (_process == null)
            {
                wait.SpinOnce();
            }
            //SpinWait wait = new SpinWait();
            //while (_process == null)
            //{
            //    wait.SpinOnce();
            //}
            LoadLayoutFromXML(m_deserializeDeviceRunFrm);
        }
@@ -542,10 +551,10 @@
                dockFrm.Text = desc[2];
                if (_process != null)
                {
                    dockFrm.DownloadProcess(_process);
                }
                //if (_process != null)
                //{
                //    dockFrm.DownloadProcess(_process);
                //}
                dockFrm.SetLoginStatus(IsLogin);
@@ -580,10 +589,10 @@
                dockFrm.Text = desc[2];
                if (_process != null)
                {
                    dockFrm.DownloadProcess(_process);
                }
                //if (_process != null)
                //{
                //    dockFrm.DownloadProcess(_process);
                //}
                dockFrm.SetLoginStatus(IsLogin);