コード例 #1
0
        public MainPage()
        {
            this.InitializeComponent();
            CurrentTripList = new TripList();
            CurrentTripList.Add(new TripViewModel(new Trip(-1)
            {
                Name = "New trip",
                Icon = "\uE109"
            }));

            DataContext = CurrentTripList;
        }
コード例 #2
0
        private void GetData()
        {
            var polen = new Trip(1, "Polen", "#008a02", DateTime.Now, DateTime.Now.AddDays(5));

            TripList.Add(polen);
            var frankrijk = new Trip(2, "Frankrijk", "#d8e305", DateTime.Now, DateTime.Now.AddDays(6));

            TripList.Add(frankrijk);
            var wallonie = new Trip(3, "Wallonie", "#e30505", DateTime.Now, DateTime.Now.AddDays(7));

            TripList.Add(wallonie);
            var zweden = new Trip(4, "Zweden", "#63bef7", DateTime.Now, DateTime.Now.AddDays(5));

            TripList.Add(zweden);
            var singapore = new Trip(5, "Singapore", "#ba0ba6", DateTime.Now, DateTime.Now.AddDays(5));

            TripList.Add(singapore);
            GotDataNotSuccesfull = false;
        }
コード例 #3
0
 public void Add(Trip newTrip)
 {
     TripList.Add(newTrip);
 }