| | |
| | | { |
| | | Gravity = Gravity.CenterHorizontal, |
| | | Width = Application.GetRealWidth(343), |
| | | Height = Application.GetRealHeight(184), |
| | | Height = Application.GetRealWidth(192),//2020-12-01 房间图片比例改回16:9 |
| | | Radius = (uint)Application.GetRealWidth(12), |
| | | Tag = room.sid, |
| | | }; |
| | |
| | | var roomViewbg = new ImageView() |
| | | { |
| | | Width = Application.GetRealWidth(343), |
| | | Height = Application.GetRealHeight(184), |
| | | ImagePath = room.backgroundImage, |
| | | Height = Application.GetRealWidth(192),//2020-12-01 房间图片比例改回16:9 |
| | | //ImagePath = room.backgroundImage, |
| | | Radius = (uint)Application.GetRealWidth(12), |
| | | }; |
| | | roomView.AddChidren(roomViewbg); |
| | | |
| | | //2020-12-03 修改图片加载方法 |
| | | ImageUtlis.Current.LoadLocalOrNetworkImages(room.backgroundImage, roomViewbg); |
| | | |
| | | var roomViewbgColor = new Button() |
| | | { |
| | |
| | | var btnAllClose = new Button() |
| | | { |
| | | X = Application.GetRealWidth(282), |
| | | Y = Application.GetRealHeight(126), |
| | | Y = Application.GetRealWidth(126), |
| | | Width = Application.GetMinRealAverage(58), |
| | | Height = Application.GetMinRealAverage(58), |
| | | UnSelectedImagePath = "Classification/Room/AllCloseIcon.png", |
| | |
| | | |
| | | var btn = new Button() |
| | | { |
| | | Height = Application.GetRealHeight(20), |
| | | Height = Application.GetRealWidth(20), |
| | | }; |
| | | roomListView.AddChidren(btn); |
| | | |
| | | roomViewbgColor.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | Action<Room > ReloadRoomName = (obj) => { |
| | | btnFloorAndRoomName.Text = obj.floorName + obj.name; |
| | | Action ReloadRoomName = () => { |
| | | btnFloorAndRoomName.Text = room.floorName + room.name; |
| | | }; |
| | | |
| | | var view = new RoomPage(room, ReloadRoomName); |
| | | //房间删除事件 |
| | | Action deleteAction = () => { |
| | | roomView.RemoveFromParent(); |
| | | }; |
| | | |
| | | var view = new RoomPage(room, ReloadRoomName, deleteAction); |
| | | MainPage.BasePageView.AddChidren(view); |
| | | view.LoadPage(); |
| | | MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |