| | |
| | | using System; |
| | | using Shared; |
| | | using HDL_ON.Entity; |
| | | using System.Collections.Generic; |
| | | |
| | | namespace HDL_ON.UI |
| | | { |
| | |
| | | { |
| | | CloseTime = 3, |
| | | Text = Language.StringByID(StringId.RoomNameCannotBeEmpty), |
| | | Direction = AMPopTipDirection.None, |
| | | }.Show(bodyView); |
| | | return; |
| | | } |
| | | if(string.IsNullOrEmpty( room.floor)) |
| | | { |
| | | new Tip() |
| | | { |
| | | CloseTime = 3, |
| | | Text = Language.StringByID(StringId.PlsBindFloor), |
| | | Direction = AMPopTipDirection.None, |
| | | }.Show(bodyView); |
| | | return; |
| | |
| | | }; |
| | | EventHandler<MouseEventArgs> eventHandler = (sender, e) => |
| | | { |
| | | new PublicAssmebly().LoadDialog_EditParater(StringId.RoomName, room.name, callBack); |
| | | List<string> roomNameList = new List<string>(); |
| | | foreach(var rroom in DB_ResidenceData.residenceData.rooms) |
| | | { |
| | | roomNameList.Add(rroom.name); |
| | | } |
| | | if (pageTitleId == StringId.AddRoom) |
| | | { |
| | | new PublicAssmebly().LoadDialog_EditParater(StringId.RoomName, room.name, callBack, StringId.RoomNameCannotBeEmpty, StringId.AddingFailed_RoomAlreadyExists, roomNameList); |
| | | } |
| | | else |
| | | { |
| | | new PublicAssmebly().LoadDialog_EditParater(StringId.RoomName, room.name, callBack, StringId.RoomNameCannotBeEmpty, StringId.EidtFailed_RoomAlreadyExists, roomNameList); |
| | | } |
| | | }; |
| | | btnEditRoomNameIcon.MouseUpEventHandler = eventHandler; |
| | | roomNameRow.MouseUpEventHandler = eventHandler; |