From f3e65daca7978b21b5888f49b1bf35e1a6e5d4fd Mon Sep 17 00:00:00 2001
From: 黄学彪 <hxb@hdlchina.com.cn>
Date: 星期一, 13 七月 2020 12:33:31 +0800
Subject: [PATCH] 新版本

---
 ZigbeeApp/Shared/Phone/Category/AddOrEditorSceneForm.cs |   15 ++++++++++++---
 1 files changed, 12 insertions(+), 3 deletions(-)

diff --git a/ZigbeeApp/Shared/Phone/Category/AddOrEditorSceneForm.cs b/ZigbeeApp/Shared/Phone/Category/AddOrEditorSceneForm.cs
index 4ff409d..9655afe 100755
--- a/ZigbeeApp/Shared/Phone/Category/AddOrEditorSceneForm.cs
+++ b/ZigbeeApp/Shared/Phone/Category/AddOrEditorSceneForm.cs
@@ -676,7 +676,7 @@
             //閭d釜鐗规畩鐨勬帶浠�
             this.frameBottomTemp = new FrameLayout();
             frameBottomTemp.Height = bodyFrameLayout.Height - btnTemp.Yaxis + Application.GetRealHeight(23);
-            this.listBodyControl.AddChidrenFrame(frameBottomTemp);
+            this.listBodyControl.AddChidren(frameBottomTemp);
         }
 
         #endregion
@@ -823,7 +823,7 @@
             this.editorScene.Save();
 
             //鏂板缓鍦烘櫙,涓婚〉闇�瑕侀噸鏂板埛鏂�
-            UserView.UserPage.Instance.RefreshForm = true;
+            UserView.UserPage.Instance.RefreshAllForm = true;
 
             HdlThreadLogic.Current.RunMain(() =>
             {
@@ -864,6 +864,15 @@
                 //鍙樻洿鎴块棿
                 HdlSceneLogic.Current.ChangedSceneRoom(this.editorScene, this.nowRoomId);
             }
+            else
+            {
+                //绉婚櫎鍑烘埧闂�
+                var room = HdlRoomLogic.Current.GetRoomBySceneId(this.editorScene.Id);
+                if (room != null)
+                {
+                    HdlSceneLogic.Current.DeleteSceneFromRoom(room, this.editorScene);
+                }
+            }
 
             //鍥剧墖鏀瑰彉浜�
             if (isScenePictrueChanged == true)
@@ -893,7 +902,7 @@
             this.editorScene.Save();
 
             //缂栬緫鍦烘櫙,涓婚〉闇�瑕侀噸鏂板埛鏂�
-            UserView.UserPage.Instance.RefreshForm = true;
+            UserView.UserPage.Instance.RefreshAllForm = true;
 
             HdlThreadLogic.Current.RunMain(() =>
             {

--
Gitblit v1.8.0