Exemplo n.º 1
0
        public void AddModule(IJFModule_CmprTrigger module, string moduleName)
        {
            if (null == module)
            {
                return;
            }
            if (_lstModules.Contains(module))
            {
                return;
            }

            if (null == moduleName)
            {
                moduleName = "CmprTrig";
            }
            TabPage tp = new TabPage();

            tabCtrl.TabPages.Add(tp);
            UcCmprTrig uc = new UcCmprTrig();

            uc.Dock    = DockStyle.Fill;
            uc.Parent  = tp;
            uc.Visible = true;
            uc.SetCmprTigger(module, null, null);
            tp.Text = moduleName;
            tp.Name = moduleName;
            tp.Controls.Add(uc);
            _lstModules.Add(module);
        }
Exemplo n.º 2
0
        public void UpdateModleStatus()
        {
            if (InvokeRequired)
            {
                Invoke(new Action(UpdateModleStatus));
                return;
            }
            if (_lstModules.Count == 0)
            {
                return;
            }
            if (tabCtrl.SelectedIndex < 0)
            {
                return;
            }
            UcCmprTrig uc = tabCtrl.TabPages[tabCtrl.SelectedIndex].Controls[0] as UcCmprTrig;

            uc.UpdateSrc2UI();
        }