Esempio n. 1
0
        private async void OnProductTapped(Object sender, EventArgs e)
        {
            var selectedItem = (Product)((ProductGridItemTemplate)sender).BindingContext;
            var productView  = new ProductItemViewPage()
            {
                BindingContext = selectedItem
            };

            await Navigation.PushAsync(productView);
        }
Esempio n. 2
0
        public ProductsCarouselPage()
        {
            InitializeComponent();

            var productsList = SampleData.Products;

            for (var i = 0; i < productsList.Count; i++)
            {
                var item = new ProductItemViewPage();
                item.BindingContext = productsList [i];
                Children.Add(item);
            }
        }