| | |
| | | Height = Application.GetMinRealAverage(444), |
| | | Gravity = Gravity.CenterHorizontal, |
| | | Radius = (uint)Application.GetRealHeight(CommonFormResouce.BigFormRadius), |
| | | ImagePath = room.BackgroundImageType==0? room.BackgroundImage: System.IO.Path.Combine(Config.Instance.FullPath, room.BackgroundImage) |
| | | ImagePath = room.BackgroundImageType == 0 ? room.BackgroundImage : System.IO.Path.Combine(Config.Instance.FullPath, room.BackgroundImage) |
| | | }; |
| | | bodyFrameLayout.AddChidren(backGround); |
| | | backGround.SetViewShadow(true); |
| | | if (room.BackgroundImageType != 0) |
| | | { |
| | | backGround.ImageBytes = Shared.IO.FileUtils.ReadFile(backGround.ImagePath); |
| | | } |
| | | backGround.MouseUpEventHandler += backGroundIMGHander; |
| | | |
| | | var infoFL = new FrameLayout |
| | |
| | | nameRow.SetTipTitle($"{Language.StringByID(R.MyInternationalizationString.RoomName)} :"); |
| | | nameRow.SetTitle(room.Name); |
| | | infoFL.AddChidren(nameRow); |
| | | if(room.IsLove) |
| | | { |
| | | nameRow.NameText.Enable = false; |
| | | } |
| | | |
| | | var floorRow = new DeviceInfoRow(308); |
| | | floorRow.Init(); |
| | |
| | | } |
| | | if (IconPathType == 0) |
| | | { |
| | | room.BackgroundImage = backGround.UnSelectedImagePath; |
| | | room.BackgroundImage = backGround.ImagePath; |
| | | } |
| | | else |
| | | { |
| | |
| | | { |
| | | IconPathType = 0; |
| | | backGround.ImageBytes = null; |
| | | backGround.UnSelectedImagePath = imgPath; |
| | | backGround.ImagePath = imgPath; |
| | | }; |
| | | }; |
| | | selectPhotographBtn.MouseUpEventHandler += (send, ee) => |
| | |
| | | { |
| | | if (IconPathType != 0) |
| | | { |
| | | Global.DeleteFilebyHomeId(backGround.UnSelectedImagePath); |
| | | Global.DeleteFilebyHomeId(backGround.ImagePath); |
| | | } |
| | | |
| | | IconPathType = 1; |
| | | backGround.ImageBytes = Shared.IO.FileUtils.ReadFile(imagePath); |
| | | backGround.UnSelectedImagePath = imagePath; |
| | | backGround.ImagePath = imagePath; |
| | | System.IO.File.Delete(imagePath); |
| | | |
| | | }, fileName, 2, 1); |
| | |
| | | { |
| | | if (IconPathType != 0) |
| | | { |
| | | Global.DeleteFilebyHomeId(backGround.UnSelectedImagePath); |
| | | Global.DeleteFilebyHomeId(backGround.ImagePath); |
| | | } |
| | | |
| | | IconPathType = 2; |
| | | backGround.ImageBytes = Shared.IO.FileUtils.ReadFile(imagePath); |
| | | backGround.UnSelectedImagePath = imagePath; |
| | | backGround.ImagePath = imagePath; |
| | | System.IO.File.Delete(imagePath); |
| | | |
| | | }, fileName, 2, 1); |