From d9c7da60b52b608ba20c2c50d1f4134266ac61c0 Mon Sep 17 00:00:00 2001 From: DucDangAnh Date: Wed, 8 Jul 2020 16:37:07 +0700 Subject: [PATCH] AIParkingApplicationForm - Fix build. --- .../AIParkingApplicationForm.cs | 23 ++----------------- 1 file changed, 2 insertions(+), 21 deletions(-) diff --git a/AIParkingApplication/AIParkingApplicationForm.cs b/AIParkingApplication/AIParkingApplicationForm.cs index df87a30..acfb9ab 100644 --- a/AIParkingApplication/AIParkingApplicationForm.cs +++ b/AIParkingApplication/AIParkingApplicationForm.cs @@ -36,12 +36,12 @@ namespace AIParkingApplication MessageBox.Show("Cấu hình API Plate Recognize lỗi!", "Cấu hình API Engine lỗi!", MessageBoxButtons.OK, MessageBoxIcon.Error); return; } - laneIn = new LaneIn(1, this.configOnWeb.CameraData1.StreamUrl, this.configOnWeb.CameraData2.StreamUrl, c3Device, this.apiController, engineApiController, true, false, true); + laneIn = new LaneIn(1, this.configOnWeb.CameraData1.Id.ToString(), this.configOnWeb.CameraData1.StreamUrl, this.configOnWeb.CameraData2.StreamUrl, c3Device, this.apiController, engineApiController, true, false, true); laneIn.BorderStyle = BorderStyle.FixedSingle; laneIn.Location = new System.Drawing.Point(sidebar.Location.X + sidebar.Width + 20, menuStrip.Height); Controls.Add(laneIn); - laneOut = new LaneOut(2, this.configOnWeb.CameraData3.StreamUrl, this.configOnWeb.CameraData4.StreamUrl, c3Device, this.apiController, engineApiController, true, false, true); + laneOut = new LaneOut(2, this.configOnWeb.CameraData3.Id.ToString(), this.configOnWeb.CameraData3.StreamUrl, this.configOnWeb.CameraData4.StreamUrl, c3Device, this.apiController, engineApiController, true, false, true); laneOut.BorderStyle = BorderStyle.FixedSingle; laneOut.Location = new System.Drawing.Point(laneIn.Location.X + laneIn.Width + 20, menuStrip.Height); Controls.Add(laneOut); @@ -62,25 +62,6 @@ namespace AIParkingApplication private void toolStripMenuItemSwitchLaneInIn_Click(object sender, EventArgs e) { - laneIn.Stop(); - laneOut.Stop(); - laneIn.Hide(); - laneOut.Hide(); - LaneIn laneIn1, laneIn2; - laneIn1 = new LaneIn(1, this.configOnWeb.CameraData1.StreamUrl, this.configOnWeb.CameraData2.StreamUrl, c3Device, this.apiController, engineApiController, true, false, true); - laneIn1.BorderStyle = BorderStyle.FixedSingle; - laneIn1.Location = new System.Drawing.Point(sidebar.Location.X + sidebar.Width + 20, menuStrip.Height); - Controls.Add(laneIn1); - - laneIn2 = new LaneIn(2, this.configOnWeb.CameraData1.StreamUrl, this.configOnWeb.CameraData2.StreamUrl, c3Device, this.apiController, engineApiController, true, false, true); - laneIn2.BorderStyle = BorderStyle.FixedSingle; - laneIn2.Location = new System.Drawing.Point(laneIn1.Location.X + laneIn1.Width + 20, menuStrip.Height); - Controls.Add(laneIn2); - - laneIn1.Start(); - laneIn2.Start(); - this.MinimumSize = new System.Drawing.Size(500, 768); - this.Width = 500; } private void AIParkingApplicationForm_FormClosing(object sender, FormClosingEventArgs e)