Beispiel #1
0
 protected virtual void OnRoomChange(Room newRoom)
 {
     if (RoomChanged != null)
     {
         RoomChanged(this, new RoomChangeEventArgs(newRoom, RoomChangeEventType.HasChanged));
     }
 }
Beispiel #2
0
 protected virtual void RoomWillChange(Room newRoom)
 {
     if (RoomChanged != null)
     {
         RoomChanged(this, new RoomChangeEventArgs(newRoom, RoomChangeEventType.WillChange));
     }
 }
Beispiel #3
0
 public UIController(uint id, BasicTriList device, Room defaultRoom)
     : this(id, device)
 {
     if (defaultRoom != null)
     {
         _room                    = defaultRoom;
         _defaultRoom             = defaultRoom;
         _room.RoomDetailsChange += new RoomDetailsChangeEventHandler(Room_RoomDetailsChange);
         _room.SourceChange      += new RoomSourceChangeEventHandler(Room_SourceChange);
     }
 }
Beispiel #4
0
 void Room_SourceChange(Room room, RoomSourceChangeEventArgs args)
 {
     try
     {
         if (Room == room)
         {
             OnSourceChange(args.PreviousSource, args.NewSource);
         }
     }
     catch (Exception e)
     {
         ErrorLog.Exception(string.Format("Error in {0}.Room_SourceChange(UXLib.Models.Room room, RoomSourceChangeEventArgs args)",
                                          GetType().Name), e);
     }
 }
Beispiel #5
0
 public RoomChangeEventArgs(Room newRoom, RoomChangeEventType eventType)
 {
     NewRoom   = newRoom;
     EventType = eventType;
 }
Beispiel #6
0
 void Room_RoomDetailsChange(Room room, RoomDetailsChangeEventArgs args)
 {
     OnRoomDetailsChange();
 }