示例#1
0
文件: RoomForm.cs 项目: kduy410/QLKS
 protected internal static RoomForm Instance()
 {
     if (_instance == null)
     {
         _instance = new RoomForm();
     }
     return(_instance);
 }
示例#2
0
文件: HomeForm.cs 项目: kduy410/QLKS
 private void btnRoom_Click(object sender, EventArgs e)
 {
     if (!panel3.Controls.Contains(RoomForm.Instance()))
     {
         panel3.Controls.Add(RoomForm._instance);
         RoomForm._instance.Dock = DockStyle.Fill;
         RoomForm._instance.BringToFront();
         RoomForm._instance.Visible = true;
     }
     RoomForm._instance.BringToFront();
     RoomForm._instance.Visible = true;
 }