Exemplo n.º 1
0
 public Form_BoxManage()
 {
     InitializeComponent();
     BoxManager.Instance.Load();
     RefreshList();
     Instance = this;
 }
Exemplo n.º 2
0
        /// <summary>
        /// 料盒管理
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void btnBoxManager_Click(object sender, EventArgs e)
        {
            Form_BoxManage frm = Form_BoxManage.Instance;

            if (frm == null || frm.IsDisposed)
            {
                frm = new Form_BoxManage();
                int SH = Screen.PrimaryScreen.Bounds.Height;
                int SW = Screen.PrimaryScreen.Bounds.Width;
                frm.Show();
                frm.Location = new Point((SW - frm.Size.Width) / 2, (SH - frm.Size.Height) / 2);
            }
            else
            {
                frm.Activate();
            }
        }