Esempio n. 1
0
 private void Button_Cancel(object sender, RoutedEventArgs e)
 {
     if (handler.isBlinking)
     {
         handler.switchLedBlink(false);
     }
     this.NavigationService.GoBack();
 }
Esempio n. 2
0
        internal AddToRoom(Context _ctx, Room _room, StationHandler _handler)
        {
            InitializeComponent();
            room    = _room;
            ctx     = _ctx;
            handler = _handler;
            Label_RoomName.Content = room.roomName;
            handler.switchLedBlink(true);

            //dimensiono graficamente la stanza
            if (GridRoom.Width > 100 || GridRoom.Height > 100)
            {
                GridRoom.Width     = room.size.X;
                GridRoom.Height    = room.size.Y;
                Canvas_Room.Width  = room.size.X;
                Canvas_Room.Height = room.size.Y;
            }
            else
            {
                GridRoom.Width     = room.size.X * 100;
                GridRoom.Height    = room.size.Y * 100;
                Canvas_Room.Width  = room.size.X * 100;
                Canvas_Room.Height = room.size.Y * 100;
            }

            ComputeRadius();             //calcolo raggio grafico
            LoadStations();
        }