コード例 #1
0
        public PlantedListViewModel(INavigation nav)
        {
            Title       = "Alive Plants!!";
            this.Plants = new ObservableRangeCollection <Plant>(GardenCenter.GetPlanted());

            this.nav = nav;
        }
コード例 #2
0
        void cilantro_Clicked(object sender, EventArgs args)
        {
            var cilantro = new Plant
            {
                Name         = "Cilantro",
                Quantity     = 1,
                WikipediaUrl = "https://en.wikipedia.org/wiki/Coriander"
            };

            GardenCenter.PlantThePlant(cilantro);
        }
コード例 #3
0
        void basil_Clicked(object sender, EventArgs args)
        {
            var basil = new Plant
            {
                Name         = "Basil",
                Quantity     = 1,
                WikipediaUrl = "https://en.wikipedia.org/wiki/Basil"
            };

            GardenCenter.PlantThePlant(basil);
        }
コード例 #4
0
        void zinnia_clicked(object sender, EventArgs args)
        {
            var zinnia = new Plant
            {
                Name         = "Zinnia",
                Quantity     = 1,
                WikipediaUrl = "https://en.wikipedia.org/wiki/Zinnia"
            };

            GardenCenter.PlantThePlant(zinnia);
        }
コード例 #5
0
        void marigold_clicked(object sender, EventArgs args)
        {
            var marigold = new Plant
            {
                Name         = "Marigold",
                Quantity     = 1,
                WikipediaUrl = "https://en.wikipedia.org/wiki/Tagetes_erecta"
            };

            GardenCenter.PlantThePlant(marigold);
        }
コード例 #6
0
        void daisy_clicked(object sender, EventArgs args)
        {
            var daisy = new Plant
            {
                Name         = "Daisy",
                Quantity     = 1,
                WikipediaUrl = "https://en.wikipedia.org/wiki/Bellis_perennis"
            };

            GardenCenter.PlantThePlant(daisy);
        }
コード例 #7
0
        void AddPepper(object sender, EventArgs args)
        {
            var jalapeno = new Plant
            {
                Name         = "Jalapeno Pepper",
                Quantity     = 1,
                WikipediaUrl = "https://en.wikipedia.org/wiki/Jalape%C3%B1o"
            };

            GardenCenter.PlantThePlant(jalapeno);
        }
コード例 #8
0
        void AddTomato(object sender, EventArgs args)
        {
            var tomato = new Plant
            {
                Name         = "Tomato",
                Quantity     = 1,
                WikipediaUrl = "https://en.wikipedia.org/wiki/Tomato"
            };

            GardenCenter.PlantThePlant(tomato);
        }
コード例 #9
0
        void AddEggplant(object sender, EventArgs args)
        {
            var eggplant = new Plant
            {
                Name         = "Eggplant",
                Quantity     = 1,
                WikipediaUrl = "https://en.wikipedia.org/wiki/Eggplant"
            };

            GardenCenter.PlantThePlant(eggplant);
        }
コード例 #10
0
        void AddKale(object sender, EventArgs args)
        {
            var kale = new Plant
            {
                Name         = "Kale",
                Quantity     = 1,
                WikipediaUrl = "https://en.wikipedia.org/wiki/Kale"
            };

            GardenCenter.PlantThePlant(kale);
        }
コード例 #11
0
        void AddSquash(object sender, EventArgs args)
        {
            var squash = new Plant
            {
                Name         = "Spaghetti Squash",
                Quantity     = 1,
                WikipediaUrl = "https://en.wikipedia.org/wiki/Spaghetti_squash"
            };

            GardenCenter.PlantThePlant(squash);
        }
コード例 #12
0
 public DeadPlantListViewModel()
 {
     DeadPlants = new ObservableRangeCollection <Plant>(GardenCenter.GetDead());
     Title      = "Here lie the dead plants";
 }