Exemple #1
0
        private void FMain_FormClosed(object sender, FormClosedEventArgs e)
        {
            if (ExitZero)
            {
                return;
            }
            Form protocol = ProtocolST.Instance(this);

            if (protocol != null)
            {
                ProtocolPar pp = ParAll.ST.Protocol;
                pp.IsFile    = ProtocolST.IsFile;
                pp.IsSave    = ProtocolST.IsSave;
                pp.IsVisible = protocol.Visible;
                L_WindowLPars.CurrentWins.SaveFormRect(protocol);
                protocol.Close();
            }
            uManage1.Dispose();
            uLine1.Save();
            uWork1.Dispose();
            L_WindowLPars.CurrentWins.SaveFormRect(this);
            ParAll.ST.Some.Splitter1 = uSplitter1.Top;
            ParAll.ST.Some.Splitter2 = uSplitter2.Top;
            ParAll.ST.Some.Splitter3 = uSplitter3.Top;
            if (fPrevTube != null)
            {
                fPrevTube.Dispose();
            }
        }
Exemple #2
0
 private void FParAll_Load(object sender, EventArgs e)
 {
     if (!DesignMode)
     {
         if (User.current.Group == EGroup.Master)
         {
             ToolStripMenuItem pr = FileItem.DropDownItems.Add("Протокол") as ToolStripMenuItem;
             pr.Click += new EventHandler(pr_Click);
         }
         else
         {
             propertyGrid2.ContextMenuStrip = null;
         }
         ProtocolPar pp       = ParAll.ST.Protocol;
         Form        protocol = ProtocolST.Instance(this, pp.Period, pp.IsFile, pp.IsSave);
         if (protocol != null)
         {
             ParAll.ST.Wins.LoadFormRect(protocol);
             if (pp.IsVisible)
             {
                 protocol.Show();
             }
         }
     }
 }
Exemple #3
0
        private void FMain_Load(object sender, EventArgs e)
        {
            if (DesignMode)
            {
                return;
            }
            L_WindowLPars.CurrentWins = ParAll.ST.Wins;
            if (IsParams())
            {
                using (FParAll f = new FParAll())
                {
                    if (f.Login())
                    {
                        f.ShowDialog();
                    }
                }
                ParAll.ST.Save();
                ExitZero = true;
                Environment.Exit(0);
                return;
            }

            L_WindowLPars.CurrentWins.LoadFormRect(this);
            ProtocolPar pp       = ParAll.ST.Protocol;
            Form        protocol = ProtocolST.Instance(this, pp.Period, pp.IsFile, pp.IsSave);

            if (protocol != null)
            {
                L_WindowLPars.CurrentWins.LoadFormRect(protocol);
                if (pp.IsVisible)
                {
                    protocol.Show();
                }
            }
            uSplitter1.Init(uThick1, uCross1);
            uSplitter2.Init(uCross1, uLine1);
            uSplitter3.Init(uLine1, uSum1);
            RResize0();
            RResize();
            uSplitter1.RLoad(ParAll.ST.Some.Splitter1);
            uSplitter2.RLoad(ParAll.ST.Some.Splitter2);
            uSplitter3.RLoad(ParAll.ST.Some.Splitter3);
            uWork1.Init(OnExec, uCross1, uLine1);
            uThick1.Init();
            uCross1.Init(EUnit.Cross);
            uLine1.Init(EUnit.Line);
            uSum1.Init();
            uManage1.Init();
            uLine1.OnRecalc = ReCalc;
            if (IsTest())
            {
                bTest.Visible = true;
            }
            uManage1.DrawStatist();
        }
Exemple #4
0
        private void FParAll_FormClosed(object sender, FormClosedEventArgs e)
        {
            ProtocolPar pp       = ParAll.ST.Protocol;
            Form        protocol = ProtocolST.Instance(this);

            if (protocol != null)
            {
                pp.IsFile    = ProtocolST.IsFile;
                pp.IsSave    = ProtocolST.IsSave;
                pp.IsVisible = protocol.Visible;
                ParAll.ST.Wins.SaveFormRect(protocol);
                protocol.Close();
            }
        }