From 3272ca5b51e19f7f8a827b0f68400570a547fe60 Mon Sep 17 00:00:00 2001
From: 陈嘉乐 <cjl@hdlchina.com.cn>
Date: 星期二, 28 四月 2020 15:02:44 +0800
Subject: [PATCH] 2020-04-28-1

---
 ZigbeeApp/Shared/Phone/Device/CommonForm/DeviceIconSelectedIMGByLocal.cs |   21 ++++++++++++---------
 1 files changed, 12 insertions(+), 9 deletions(-)

diff --git a/ZigbeeApp/Shared/Phone/Device/CommonForm/DeviceIconSelectedIMGByLocal.cs b/ZigbeeApp/Shared/Phone/Device/CommonForm/DeviceIconSelectedIMGByLocal.cs
index 5ce4579..b965863 100755
--- a/ZigbeeApp/Shared/Phone/Device/CommonForm/DeviceIconSelectedIMGByLocal.cs
+++ b/ZigbeeApp/Shared/Phone/Device/CommonForm/DeviceIconSelectedIMGByLocal.cs
@@ -3,7 +3,7 @@
 
 namespace Shared.Phone.Device.CommonForm
 {
-    public class DeviceIconSelectedIMGByLocal:FrameLayout
+    public class DeviceIconSelectedIMGByLocal : FrameLayout
     {
         /// <summary>
         /// bodyFrameLayout
@@ -12,7 +12,7 @@
         /// <summary>
         /// action
         /// </summary>
-        public Action<string,string > action;
+        public Action<string, string> action;
         /// <summary>
         /// tempIcon
         /// </summary>
@@ -92,7 +92,7 @@
                 scrollView.AddChidren(itemView);
                 for (int i = 0; i < 4; i++)
                 {
-                    var icon = new FunctionIconButton(58+ i*(207+46), 58);
+                    var icon = new FunctionIconButton(58 + i * (207 + 46), 58);
                     icon.Init($"FunctionIcon/{k}Icon.png", $"FunctionIcon/{k}IconSelected.png");
                     itemView.AddChidren(icon);
                     k++;
@@ -107,13 +107,16 @@
                     icon.ImageBtn.MouseUpEventHandler += selectIcon;
                 }
             }
-
-            var confirmBtn = new CommonForm.CompleteButton(1472, 907, 127);
-            confirmBtn.SetTitle(R.MyInternationalizationString.Save);
-            bodyFrameLayout.AddChidren(confirmBtn);
-            confirmBtn.MouseUpEventHandler += (sender, e) =>
+
+            var btnConfirm = new UserCenter.BottomClickButton();
+            btnConfirm.TextID = R.MyInternationalizationString.Save;
+            bodyFrameLayout.AddChidren(btnConfirm);
+            btnConfirm.ButtonClickEvent += (sender, e) =>
             {
-                action(tempIcon.ImageBtn.UnSelectedImagePath, tempIcon.ImageBtn.SelectedImagePath);
+                if (tempIcon.ImageBtn != null)
+                {
+                    action(tempIcon.ImageBtn.UnSelectedImagePath, tempIcon.ImageBtn.SelectedImagePath);
+                }
                 RemoveFromParent();
             };
         }

--
Gitblit v1.8.0