From e1ac4ab0e68024e6289e0b11756962d662749b04 Mon Sep 17 00:00:00 2001
From: 陈嘉乐 <cjl@hdlchina.com.cn>
Date: 星期二, 16 三月 2021 17:15:23 +0800
Subject: [PATCH] Revert "Merge branch 'WJC' of http://172.16.1.23:6688/r/~wxr/HDL_APP_Project into WJC"

---
 HDL_ON/UI/UI2/FuntionControlView/Electrical/TuyaWeepRobotPage.cs |   84 ++++++++++++++++++------------------------
 1 files changed, 36 insertions(+), 48 deletions(-)

diff --git a/HDL_ON/UI/UI2/FuntionControlView/Electrical/TuyaWeepRobotPage.cs b/HDL_ON/UI/UI2/FuntionControlView/Electrical/TuyaWeepRobotPage.cs
index 2368509..f5028ec 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/Electrical/TuyaWeepRobotPage.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/Electrical/TuyaWeepRobotPage.cs
@@ -127,7 +127,7 @@
             //鍚稿姏璋冭妭
             this.btnSuctionIcon = new IconViewControl(28);
             btnSuctionIcon.Y = ImageControl.Bottom + Application.GetRealHeight(64);
-            //btnSuctionIcon.X = Application.GetRealWidth(33);
+            btnSuctionIcon.X = Application.GetRealWidth(33);
             btnSuctionIcon.UnSelectedImagePath = "FunctionIcon/Electrical/WeepRobot/Suction.png";
             btnSuctionIcon.SelectedImagePath = "FunctionIcon/Electrical/WeepRobot/SuctionSelect.png";
             FrameWhiteCentet1.AddChidren(btnSuctionIcon);
@@ -138,7 +138,7 @@
             };
             this.btnSuctionView = new NormalViewControl(80, 54, true);
             btnSuctionView.Y = btnSuctionIcon.Bottom + Application.GetRealHeight(10);
-            //btnSuctionView.X = btnSuctionIcon.X - (Application.GetRealWidth(80) - btnSuctionIcon.Width) / 2;
+            btnSuctionView.X = btnSuctionIcon.X - (Application.GetRealWidth(80) - btnSuctionIcon.Width) / 2;
             btnSuctionView.TextAlignment = TextAlignment.TopCenter;
             btnSuctionView.TextSize = CSS_FontSize.PromptFontSize_FirstLevel;
             btnSuctionView.Text = Language.StringByID(StringId.SuctionAdjustment);
@@ -149,8 +149,7 @@
             this.btnChargeIcon = new IconViewControl(28);
             btnChargeIcon.UnSelectedImagePath = "FunctionIcon/Electrical/WeepRobot/ChargeSelect.png";
             btnChargeIcon.Y = btnSuctionIcon.Y;
-            //btnChargeIcon.X = btnSuctionIcon.Right + Application.GetRealWidth(50);
-            btnChargeIcon.Gravity = Gravity.CenterHorizontal;
+            btnChargeIcon.X = btnSuctionIcon.Right + Application.GetRealWidth(50);
             FrameWhiteCentet1.AddChidren(btnChargeIcon);
             btnChargeIcon.ButtonClickEvent += (sender, e) =>
             {
@@ -165,10 +164,6 @@
             btnChargeView.TextID = StringId.Charge;
             FrameWhiteCentet1.AddChidren(btnChargeView);
 
-            //2021.03.09 鑸嶅純鎺夐潤闊冲姛鑳�
-            btnSuctionIcon.X = btnChargeIcon.X - btnSuctionIcon.IconSize - Application.GetRealWidth(50);
-            btnSuctionView.X = btnSuctionIcon.X - (Application.GetRealWidth(80) - btnSuctionIcon.Width) / 2;
-
             //澹伴煶鍥炬爣
             this.btnVoiceIcon = new IconViewControl(28);
             btnVoiceIcon.Y = btnSuctionIcon.Y;
@@ -176,7 +171,7 @@
             btnVoiceIcon.UnSelectedImagePath = "FunctionIcon/Electrical/WeepRobot/Voice.png";
             btnVoiceIcon.SelectedImagePath = "FunctionIcon/Electrical/WeepRobot/VoiceSelect.png";
             btnVoiceIcon.IsSelected = true;
-            //FrameWhiteCentet1.AddChidren(btnVoiceIcon);
+            FrameWhiteCentet1.AddChidren(btnVoiceIcon);
             btnVoiceIcon.ButtonClickEvent += (sender, e) =>
             {
                 //鍙戦�侀潤闊冲懡浠�
@@ -188,13 +183,12 @@
             btnVoiceView.TextAlignment = TextAlignment.TopCenter;
             btnVoiceView.TextSize = CSS_FontSize.PromptFontSize_FirstLevel;
             btnVoiceView.TextID = StringId.Mute;
-            //FrameWhiteCentet1.AddChidren(btnVoiceView);
+            FrameWhiteCentet1.AddChidren(btnVoiceView);
 
             //娓呮壂妯″紡鍥炬爣
             this.btnModeIcon = new IconViewControl(28);
             btnModeIcon.Y = btnSuctionIcon.Y;
-            //btnModeIcon.X = btnVoiceIcon.Right + Application.GetRealWidth(50);
-            btnModeIcon.X = btnChargeIcon.Right + Application.GetRealWidth(50);
+            btnModeIcon.X = btnVoiceIcon.Right + Application.GetRealWidth(50);
             btnModeIcon.UnSelectedImagePath = "FunctionIcon/Electrical/WeepRobot/Clean.png";
             FrameWhiteCentet1.AddChidren(btnModeIcon);
             btnModeIcon.ButtonClickEvent += (sender, e) =>
@@ -226,28 +220,26 @@
             btnTitleName.TextID = StringId.WeepRobot;
             FrameWhiteCentet2.AddChidren(btnTitleName);
 
-            //2021.03.09 鑸嶅純鑰楁潗绠$悊
             //鑰楁潗绠$悊
-            //var rowManment = new FrameRowControl();
-            //rowManment.Height = Application.GetRealHeight(50);
-            //rowManment.Width = FrameWhiteCentet2.Width;
-            //rowManment.Y = Application.GetRealHeight(75);
-            //FrameWhiteCentet2.AddChidren(rowManment);
-            //rowManment.AddLeftCaption(Language.StringByID(StringId.ConsumablesManagement), 200);
-            //rowManment.AddBottomLine();
-            //rowManment.AddRightArrow();
-            //rowManment.ButtonClickEvent += (sender, e) =>
-            //{
-            //    var form = new TuyaWeepRobotConsumablesMagPage();
-            //    form.AddForm(this.device, this.weepRobotData);
-            //};
+            var rowManment = new FrameRowControl();
+            rowManment.Height = Application.GetRealHeight(50);
+            rowManment.Width = FrameWhiteCentet2.Width;
+            rowManment.Y = Application.GetRealHeight(75);
+            FrameWhiteCentet2.AddChidren(rowManment);
+            rowManment.AddLeftCaption(Language.StringByID(StringId.ConsumablesManagement), 200);
+            rowManment.AddBottomLine();
+            rowManment.AddRightArrow();
+            rowManment.ButtonClickEvent += (sender, e) =>
+            {
+                var form = new TuyaWeepRobotConsumablesMagPage();
+                form.AddForm(this.device, this.weepRobotData);
+            };
 
             //鍘嗗彶璁板綍
             var rowHistory = new FrameRowControl();
             rowHistory.Height = Application.GetRealHeight(50);
             rowHistory.Width = FrameWhiteCentet2.Width;
-            //rowHistory.Y = rowManment.Bottom;
-            rowHistory.Y = Application.GetRealHeight(75);
+            rowHistory.Y = rowManment.Bottom;
             FrameWhiteCentet2.AddChidren(rowHistory);
             rowHistory.AddLeftCaption(Language.StringByID(StringId.HistoryLog), 200);
             rowHistory.AddBottomLine();
@@ -335,15 +327,12 @@
             };
             frameBack.Show();
 
-            //2021.03.09 鑸嶅純闅忔満娓呮壂
             //鑿滃崟鎺т欢(娓呮壂妯″紡)
-            //var menuContr = new DialogTitleMenuControl(4, Language.StringByID(StringId.CleanMode));
-            var menuContr = new DialogTitleMenuControl(3, Language.StringByID(StringId.CleanMode));
+            var menuContr = new DialogTitleMenuControl(4, Language.StringByID(StringId.CleanMode));
             menuContr.X = Application.GetRealWidth(210);
             menuContr.Y = Application.GetRealHeight(197);
             menuContr.Width = Application.GetRealWidth(160);
-            //menuContr.Height = Application.GetRealHeight(243);
-            menuContr.Height = Application.GetRealHeight(203);
+            menuContr.Height = Application.GetRealHeight(243);
             dialogBody.AddChidren(menuContr);
 
             //鑷姩娓呮壂
@@ -356,13 +345,13 @@
             });
 
             //闅忔満娓呮壂
-            //iconPath = this.weepRobotData.Mode == "random" ? "FunctionIcon/Electrical/WeepRobot/FixedPointModeSelect.png" : "FunctionIcon/Electrical/WeepRobot/FixedPointMode.png";
-            //menuContr.AddRowMenu(Language.StringByID(StringId.RandomClean), iconPath, this.weepRobotData.Mode == "random", () =>
-            //{
-            //    frameBack.Close();
-            //    //鍙戦�佹ā寮忓懡浠�
-            //    this.SendComand("mode", "random");
-            //});
+            iconPath = this.weepRobotData.Mode == "random" ? "FunctionIcon/Electrical/WeepRobot/FixedPointModeSelect.png" : "FunctionIcon/Electrical/WeepRobot/FixedPointMode.png";
+            menuContr.AddRowMenu(Language.StringByID(StringId.RandomClean), iconPath, this.weepRobotData.Mode == "random", () =>
+            {
+                frameBack.Close();
+                //鍙戦�佹ā寮忓懡浠�
+                this.SendComand("mode", "random");
+            });
 
             //铻烘棆娓呮壂
             iconPath = this.weepRobotData.Mode == "spiral" ? "FunctionIcon/Electrical/WeepRobot/AreaModeSelect.png" : "FunctionIcon/Electrical/WeepRobot/AreaMode.png";
@@ -531,14 +520,13 @@
                 this.btnModeIcon.SelectedImagePath = "FunctionIcon/Electrical/WeepRobot/AutoModeSelect.png";
                 this.btnModeView.TextID = StringId.AutoClean;
             }
-            //2021.03.09 鑸嶅純闅忔満娓呮壂
-            //else if (this.weepRobotData.Mode == "smart")
-            //{
-            //    //闅忔満娓呮壂
-            //    this.btnModeIcon.UnSelectedImagePath = "FunctionIcon/Electrical/WeepRobot/FixedPointMode.png";
-            //    this.btnModeIcon.SelectedImagePath = "FunctionIcon/Electrical/WeepRobot/FixedPointModeSelect.png";
-            //    this.btnModeView.TextID = StringId.RandomClean;
-            //}
+            else if (this.weepRobotData.Mode == "smart")
+            {
+                //闅忔満娓呮壂
+                this.btnModeIcon.UnSelectedImagePath = "FunctionIcon/Electrical/WeepRobot/FixedPointMode.png";
+                this.btnModeIcon.SelectedImagePath = "FunctionIcon/Electrical/WeepRobot/FixedPointModeSelect.png";
+                this.btnModeView.TextID = StringId.RandomClean;
+            }
             else if (this.weepRobotData.Mode == "wall_follow")
             {
                 //娌垮娓呮壂

--
Gitblit v1.8.0