gxc
2020-01-07 aed247d7fa4499665041864479fae82089eafe5f
ZigbeeApp/Shared/Phone/Device/Room/EditRoom.cs
@@ -251,7 +251,6 @@
            };
            bodyFrameLayout.AddChidren(backGround1);
            backGround = new ImageView()
            {
                Y = Application.GetRealHeight(60),
@@ -422,7 +421,7 @@
                if (OldIconPathType != 0)
                {
                    Shared.IO.FileUtils.DeleteFile(System.IO.Path.Combine(Config.Instance.FullPath, OldBackgroundImagePath));
                    HdlAutoBackupLogic.DeleteFile(System.IO.Path.Combine(Config.Instance.FullPath, OldBackgroundImagePath));
                    HdlAutoBackupLogic.DeleteFile(OldBackgroundImagePath);
                }
                if (IconPathType == 0)
                {
@@ -431,7 +430,7 @@
                else
                {
                    Shared.IO.FileUtils.WriteFileByBytes(System.IO.Path.Combine(Config.Instance.FullPath, fileName), backGround.ImageBytes);
                    HdlAutoBackupLogic.AddOrEditorFile(System.IO.Path.Combine(Config.Instance.FullPath, fileName));
                    HdlAutoBackupLogic.AddOrEditorFile(fileName);
                    room.BackgroundImage = fileName;
                }
                room.BackgroundImageType = IconPathType;
@@ -553,6 +552,10 @@
                //通过相机拍照裁剪
                CropImage.TakePicture((imagePath) =>
                {
                    if (string.IsNullOrEmpty(imagePath))
                    {
                        return;
                    }
                    if (IconPathType != 0)
                    {
                        Global.DeleteFilebyHomeId(backGround.ImagePath);
@@ -574,6 +577,10 @@
                //从相册选择图片裁剪
                CropImage.SelectPicture((imagePath) =>
                {
                    if (string.IsNullOrEmpty(imagePath))
                    {
                        return;
                    }
                    if (IconPathType != 0)
                    {
                        Global.DeleteFilebyHomeId(backGround.ImagePath);