Esempio n. 1
0
        public async void InitEquipment(FlexLayout flexlayout)
        {
            try
            {
                if (Globals.CurrentPage != Enums.ePage.Equipment)
                {
                    return;
                }

                if (flexlayout == null)
                {
                    return;
                }

                BindableLayout.SetItemsSource(flexlayout, null);
                BindableLayout.SetItemsSource(flexlayout, new List <EquipmentModel>()
                {
                    Equipment
                });
            }
            catch (Exception e)
            {
                Debug.WriteLine(e);
                await Message.DisplayAlertAsync(Title, e.Message, "Ok");
            }
        }
Esempio n. 2
0
        /// <summary>
        /// Initializes a new instance of <see cref="MaterialRadioButtonGroup"/>.
        /// </summary>
        public MaterialRadioButtonGroup()
        {
            BindableLayout.SetItemTemplate(this.selectionList, new DataTemplate(() =>
            {
                var radio = new MaterialRadioButton()
                {
                    FontFamily        = this.FontFamily,
                    FontSize          = this.FontSize,
                    HorizontalSpacing = this.HorizontalSpacing,
                    SelectedColor     = this.SelectedColor,
                    TextColor         = this.TextColor,
                    UnselectedColor   = this.UnselectedColor,
                    VerticalSpacing   = this.VerticalSpacing
                };

                radio.SetBinding(BaseMaterialSelectionControl.FontFamilyProperty, nameof(FontFamily));
                radio.SetBinding(BaseMaterialSelectionControl.FontSizeProperty, nameof(FontSize));
                radio.SetBinding(BaseMaterialSelectionControl.HorizontalSpacingProperty, nameof(HorizontalSpacing));
                radio.SetBinding(BaseMaterialSelectionControl.IsSelectedProperty, nameof(radio.IsSelected));
                radio.SetBinding(BaseMaterialSelectionControl.SelectedChangeCommandProperty, nameof(radio.SelectedChangeCommand));
                radio.SetBinding(BaseMaterialSelectionControl.TextProperty, nameof(radio.Text));
                radio.SetBinding(BaseMaterialSelectionControl.SelectedColorProperty, nameof(this.SelectedColor));
                radio.SetBinding(BaseMaterialSelectionControl.TextColorProperty, nameof(this.TextColor));
                radio.SetBinding(BaseMaterialSelectionControl.UnselectedColorProperty, nameof(this.UnselectedColor));
                radio.SetBinding(BaseMaterialSelectionControl.VerticalSpacingProperty, nameof(this.VerticalSpacing));

                return(radio);
            }));
        }
 public ShipmentTracking()
 {
     InitializeComponent();
     stepProgress.StatusChanged += Step_StatusChanged;
     ShipmentViewModel.PopulateShipmentDetails();
     BindableLayout.SetItemsSource(stepProgress, ShipmentViewModel.ShipmentInfoCollection);
 }
Esempio n. 4
0
        public NotesView()
        {
            InitializeComponent();

            _inProgressPaths = new List <InProgressPaint>();
            _completedPaths  = new List <CompletedPaint>();

            _colors = new List <string>
            {
                "#000000", "#ff0000", "#ff8000",
                "#ffbf00", "#ffff00", "#80ff00",
                "#00ff40", "#00ffff", "#00bfff",
                "#0080ff", "#0000ff", "#4000ff",
                "#8000ff", "#bf00ff", "#ff00ff",
                "#ff00bf", "#ff0080", "#ff0040",
                "#ff0000"
            };

            _color = SKColors.Black;
            _paint = new SKPaint
            {
                Style       = SKPaintStyle.Stroke,
                Color       = _color,
                StrokeWidth = 10,
                StrokeCap   = SKStrokeCap.Round,
                StrokeJoin  = SKStrokeJoin.Round
            };

            BindableLayout.SetItemsSource(ColorsLayout, _colors.Select(x => new ColorSource(Color.FromHex(x))));
        }
Esempio n. 5
0
        private async void GoToDetailDiary_Tapped(object sender, EventArgs e)
        {
            StackLayout          stack = sender as StackLayout;
            TapGestureRecognizer item  = stack.GestureRecognizers[0] as TapGestureRecognizer;
            Guid id = (Guid)item.CommandParameter;
            await viewModel.GetProjectDiary(id);

            lblTitle.Text       = viewModel.ProjectDiary.Title;
            lblDate.Text        = viewModel.ProjectDiary.Date.ToShortDateString();
            lblDescription.Text = viewModel.ProjectDiary.Description;

            GetPhotosDiary.Clear();
            if (!string.IsNullOrWhiteSpace(viewModel.ProjectDiary.Image))
            {
                string[] listImgDiary = viewModel.ProjectDiary.Image.Split(',');
                for (int i = 0; i < listImgDiary.Length; i++)
                {
                    Photo photo = new Photo();
                    photo.URL = Api_LinkProjectDiary + listImgDiary[i];
                    GetPhotosDiary.Add(photo);
                }
            }
            BindableLayout.SetItemsSource(stMediaDiary, GetPhotosDiary);

            await ModalDetailProjectDiary.Show();
        }
Esempio n. 6
0
        private static void ItemsSourcePropertyChanged(BindableObject bindable, object oldValue, object newValue)
        {
            var items   = newValue as ObservableCollection <Character>;
            var control = (CharacterCarousel)bindable;

            BindableLayout.SetItemsSource(control.listCharacter, items);
        }
Esempio n. 7
0
        public Anasayfa()
        {
            InitializeComponent();
            List <string> FırsatÜrünleriImages = new List <string>()
            {
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_nisan/ensuper-mob-min.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_mayis/philips-tv-kamp-7-mayis-mob-min.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_mayis/fiba-mob-3-min.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_mayis/super-fiyat-xr-acer-12-mayis-mob-min.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_mayis/super-fiyat-airpods-11-mayis-mob-min.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_mayis/super-fiyatlar-kea-12-mayis-mob-min.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_mayis/uclu-ffirin-kea-mob-12-mayis-min.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_mayis/yazici-banner-12-mayis-mob-min.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_mayis/lenovo-mob-12-mayis-min.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/ACER_nitro5_Vatan_700x380-mobbb.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_mayis/oppo-reno3-banner-mob-min.jpg",
                "https://cdn.vatanbilgisayar.com/Upload/BANNER//yeni-tasarim/anasayfa/2020_nisan/sss-mob-min.jpg"
            };

            Ürünler = new ÜrünModel(this);
            FırsatÜrünleriCarousel.ItemsSource = FırsatÜrünleriImages;
            ÖneÇıkanÜrünlerFLV.FlowItemsSource = Ürünler.GetItems(10);
            BindableLayout.SetItemsSource(EnÇokSatanlarSB, Ürünler.GetItems(15));
            FırsatÜrünleriCarousel.ItemsSource = FırsatÜrünleriImages;
            Device.StartTimer(TimeSpan.FromSeconds(1), () =>
            {
                Device.BeginInvokeOnMainThread(() =>
                                               DependencyService.Get <IToolbarItemBadgeService>().SetBadge(this, ToolbarItems.First(), $"{SepetIslemleri.GetSepetCounts()}", Color.Red, Color.White)
                                               );
                return(true); // True = Repeat again, False = Stop the timer
            });
            //ÖneÇıkanÜrünlerFLV.HeightRequest = Convert.ToDouble(ürünButonuModeli.Items.Count / ÖneÇıkanÜrünlerFLV.FlowColumnCount * 250);
        }
Esempio n. 8
0
        public DiagramPopupView(PercentageCategory category, string month)
        {
            InitializeComponent();
            this.title.Text = category.Name.ToString();
            this.value.Text = category.Value.ToString();
            this.img.Source = category.Image;

            ///

            var _transactionService = new TransactionService();
            var data = _transactionService.GetAll().Result;

            if (data.Count != 0)
            {
                lastID = data.First().Id;
            }
            LastTransactionsList = new ObservableCollection <Transaction>();
            data.ForEach(x => LastTransactionsList.Add(x));

            var outlay = from transaction in LastTransactionsList where (transaction.Category.Type == category.Type && transaction.Date.ToString("MMMM") == month) select transaction;

            OutputTransactions = new ObservableCollection <Transaction>();
            outlay.ToList().ForEach(x => OutputTransactions.Add(x));
            //lastTransactions.ItemsSource = OutputTransactions;

            BindableLayout.SetItemsSource(lastTransactions, OutputTransactions);
            ///
        }
Esempio n. 9
0
        public async void Init()
        {
            InitializeComponent();
            this.BindingContext = viewModel = new AddProjectPageViewModel();
            await CrossMedia.Current.Initialize();

            await viewModel.GetProjectDiary(_id);

            BindableLayout.SetItemsSource(ItemSourceDiary, viewModel.ProjectDiaryList);
            MessagingCenter.Subscribe <ModalDiaryContentView>(this, "OnClose", async(sender) =>
            {
                await ModalAddGhiNhan.Hide();
            });
            LookUpProjectType.OnSave += async(object sender, EventArgs e) => {
                Hide();
                Show();
            };
            LookUpProjectType.OnDelete += async(object sender, EventArgs e) => {
                Hide();
                viewModel.NumUtilitiChecked = 0;
            };
            LookUpUtilities.OnSave += async(object sender, EventArgs e) => {
                viewModel.NumUtilitiChecked = viewModel.TienIchDuAnSelecteIds.Count();
            };
            LookUpUtilities.OnDelete += async(object sender, EventArgs e) => {
                viewModel.NumUtilitiChecked = 0;
            };
        }
        private void SearchBar_TextChanged(object sender, TextChangedEventArgs e)
        {
            var viewModel      = new ItemInfoRepository();
            var accordionItems = viewModel.Info;

            if (string.IsNullOrEmpty(e.NewTextValue))
            {
                BindableLayout.SetItemsSource(Accordion, accordionItems);
                return;
            }

            var filteredSource = accordionItems.Where(x => (x.Name.ToLower()).StartsWith(e.NewTextValue.ToLower())).ToList <ItemInfo>();

            if (filteredSource.Count == 0)
            {
                List <Variety> listfilteredSource = null;
                for (int i = 0; i < accordionItems.Count; i++)
                {
                    var item = accordionItems[i];
                    listfilteredSource = item.Varieties.Where(x => (x.Name.ToLower()).StartsWith(e.NewTextValue.ToLower())).ToList <Variety>();
                    if (listfilteredSource.Count > 0)
                    {
                        var list = accordionItems.Where(x => x.Name.Contains(item.Name.ToString()));
                        item.Varieties = new System.Collections.ObjectModel.ObservableCollection <Variety>(listfilteredSource);
                        BindableLayout.SetItemsSource(Accordion, list);
                        if (!Accordion.Items[0].IsExpanded)
                        {
                            Accordion.Items[0].IsExpanded = true;
                        }
                        return;
                    }
                }
            }
            BindableLayout.SetItemsSource(Accordion, filteredSource);
        }
Esempio n. 11
0
        public void ItemTemplateFunction()
        {
            Func <object> loadTemplate = () => new BoxView();

            Bindable.ItemTemplate(loadTemplate);
            Assert.That(BindableLayout.GetItemTemplate(Bindable), Is.Not.Null);
        }
Esempio n. 12
0
        protected override void OnBindingContextChanged()
        {
            base.OnBindingContextChanged();
            usericon.Source = null;
            BindableLayout.SetItemsSource(Imagelayout, null);
            var item = BindingContext as MusicEventModel.friendEvent;

            if (item == null)
            {
                return;
            }
            usericon.Source = item.user.avatarUrl;
            if (item.pics.Count() > 0)
            {
                BindableLayout.SetItemsSource(Imagelayout, item.pics);
            }
            //if (item.Conent.isSong && item.pics.Count() > 0)
            //    foreach (var q in item.pics)
            //        Imagelayout.Children.Add(new CachedImage
            //        {
            //            Source = q.squareUrl,
            //            DownsampleToViewSize = true,
            //            HeightRequest = 90,
            //            WidthRequest = 90,
            //            LoadingPlaceholder = "CacheBG.jpg",
            //            Aspect = Aspect.AspectFill,
            //            Transformations = new List<FFImageLoading.Work.ITransformation>() { new RoundedTransformation() { CropHeightRatio = 90, CropWidthRatio = 90 } },
            //            Margin = new Thickness(0, 2, 0, 0),
            //            CacheKeyFactory = new Actions.CustomCacheKeyFactory(),
            //            FadeAnimationEnabled = false,
            //            FadeAnimationForCachedImages=false
            //        });
            base.OnBindingContextChanged();
            this.ForceUpdateSize();
        }
Esempio n. 13
0
 public MainPage()
 {
     InitializeComponent();
     source = new List <CardType>
     {
         CardType.Invoice,
         CardType.Transaction,
         CardType.Bonus
     };
     list = new List <Models.MenuItem> {
         new Models.MenuItem
         {
             Icon = "ic_invite.png",
             Text = "Indicar" + System.Environment.NewLine + "amigos"
         },
         new Models.MenuItem
         {
             Icon = "ic_deposit.png",
             Text = "Depositar"
         },
         new Models.MenuItem
         {
             Icon = "ic_transfer_sent.png",
             Text = "Transferir"
         },
         new Models.MenuItem
         {
             Icon = "ic_payment.png",
             Text = "Pagar"
         },
     };
     cv.ItemsSource = source;
     BindableLayout.SetItemsSource(flex, list);
 }
Esempio n. 14
0
        public void LayoutIsGarbageCollectedAfterItsRemoved()
        {
            var layout = new StackLayout
            {
                IsPlatformEnabled = true,
            };

            var itemsSource = new ObservableCollection <int>(Enumerable.Range(0, 10));

            BindableLayout.SetItemsSource(layout, itemsSource);

            var pageRoot = new Grid();

            pageRoot.Children.Add(layout);
            var page = new ContentPage()
            {
                Content = pageRoot
            };

            var weakReference = new WeakReference(layout);

            pageRoot.Children.Remove(layout);
            layout = null;

            GC.Collect();
            GC.WaitForPendingFinalizers();

            Assert.IsFalse(weakReference.IsAlive);
        }
Esempio n. 15
0
        public CarouselLayoutPage()
        {
            InitializeComponent();

            _carouselView.ItemsSource = CreateItems(100);
            BindableLayout.SetItemsSource(_bindableCarouselLayout, CreateItems(10));
        }
Esempio n. 16
0
        public async void Init()
        {
            ListViewThanhLy.ItemTemplate = new DataTemplate(typeof(Cells.LiquidationCells.LiquidationViewCell));
            MessagingCenter.Subscribe <AddLiquidationPage>(this, "OnSaveItem", (sender) => viewModel.RefreshCommand.Execute(null));
            MessagingCenter.Subscribe <LiquidationDetailPage, Guid>(this, "OnDeleted", (sender, liquidationId) =>
            {
                if (this.viewModel.Data.Any(x => x.Id == liquidationId))
                {
                    var removeItem = this.viewModel.Data.Single(x => x.Id == liquidationId);
                    this.viewModel.Data.Remove(removeItem);
                }
            });
            Categories = DependencyService.Get <IServices.ILiquidation.ILiquidationCategoryService>().GetLiquidations();
            BindableLayout.SetItemsSource(CategoriesStackLayout, Categories);
            ListViewThanhLy.ItemTapped += async(sender, e) =>
            {
                var item = e.Item as Liquidation;

                if (isMyListPage)
                {
                    await Navigation.PushAsync(new AddLiquidationPage(item.Id));
                }
                else
                {
                    await Navigation.PushAsync(new LiquidationDetailPage(item.Id));
                }
            };

            InitCategoriesLayout();
            await viewModel.LoadData();

            loadingPopup.IsVisible = false;
        }
        public RadialGradientBrushExplorerPage()
        {
            InitializeComponent();
            BindingContext = this;

            gradientStops = new GradientStopCollection();
            BindableLayout.SetItemsSource(gradientsStackLayout, gradientStops);
        }
        public RadialGradientExplorerGallery()
        {
            InitializeComponent();
            BindingContext = this;

            _gradientStops = new GradientStopCollection();
            BindableLayout.SetItemsSource(GradientsLayout, _gradientStops);
        }
        public BindableLayoutPage()
        {
            InitializeComponent();

            MakeUserList();

            BindableLayout.SetItemsSource(FlexLayoutContainer, UserList);
        }
Esempio n. 20
0
 public Themes()
 {
     InitializeComponent();
     stepProgress.StatusChanged += Step_StatusChanged;
     ShipmentViewModel.PopulateShipmentDetails();
     BindableLayout.SetItemsSource(stepProgress, ShipmentViewModel.ShipmentInfoCollection);
     this.PropertyChanged += Themes_PropertyChanged;
 }
        async void SetAvailableBusiness(string organizations)
        {
            try
            {
                var client       = new HttpClient();
                var endpointCall = await client.GetAsync(Constant.AvailableBusinessList);

                if (endpointCall.IsSuccessStatusCode)
                {
                    var contentString = await endpointCall.Content.ReadAsStringAsync();

                    var data = JsonConvert.DeserializeObject <Business>(contentString);

                    foreach (Models.Item item in data.result.result)
                    {
                        if (organizations != null && organizations != "" && organizations != "NULL")
                        {
                            if (organizations.Contains(item.business_uid))
                            {
                                item.businessSelected = true;
                                businessSelected.Add(item.business_uid);
                            }
                            else
                            {
                                item.businessSelected = false;
                            }
                        }
                        else
                        {
                            item.businessSelected = false;
                        }

                        businesSource.Add(item);
                    }

                    if (businesSource.Count == 0)
                    {
                        organizationMessageLabel.IsVisible = true;
                        organizationMessageLabel.Text      = "The are zero organization to select at the moment.";
                    }
                    else
                    {
                        organizationMessageLabel.IsVisible = false;
                    }

                    BindableLayout.SetItemsSource(organizationView, businesSource);
                }
                else
                {
                    organizationMessageLabel.IsVisible = true;
                    organizationMessageLabel.Text      = "Our system seems to experience a problem. We were not able to retrieve the organizations. Our engineers are working diligently to resolve this issue. ";
                }
            }
            catch (Exception issueGettingBusiness)
            {
                Debug.WriteLine("issueGettingBusiness: " + issueGettingBusiness.Message);
            }
        }
        private void ToggleContainer(object sender, EventArgs e)
        {
            var layout = (((Grid)((Grid)sender).Parent).Children[1] as StackLayout);
            var list   = BindableLayout.GetItemsSource(layout) as List <CustomFormQuestion>;

            if (list?.Count > 0)
            {
                (((Grid)((Grid)sender).Parent).Children[1] as StackLayout).IsVisible = !(((Grid)((Grid)sender).Parent).Children[1] as StackLayout).IsVisible;
                if ((((Grid)((Grid)sender).Parent).Children[1] as StackLayout).IsVisible)
                {
                    ((Grid)sender).BackgroundColor = Color.Black;
                    (((Grid)sender).Children[0] as Label).TextColor = Color.FromHex("#fff");
                }
            }
            var parent1 = ((Grid)sender).Parent as Grid;
            var parent2 = parent1.Parent as Frame;
            var parent3 = parent2.Parent as StackLayout;
            var parent4 = parent3.Parent as FlexLayout;

            CurrentQuestion = QuestiontextLabel.Text;
            var list1     = BindableLayout.GetItemsSource(parent4) as List <Answer>;
            var parameter = (e as TappedEventArgs)?.Parameter as Answer;

            list1.First(a => a.ResponseText.ToLower() == parameter.ResponseText.ToLower()).Selected = true;
            list1.Where(a => a.ResponseText.ToLower() != parameter.ResponseText.ToLower()).ForEach(a => a.Selected = false);
            BindableLayout.SetItemsSource(parent4, list1);
            var childrens = parent4.Children;

            foreach (var item in childrens)
            {
                var child      = item as StackLayout;
                var nextChild  = child.Children[0] as Frame;
                var nextChild1 = nextChild.Content as Grid;
                var nextChild2 = nextChild1.Children[0] as Grid;
                var nextChild3 = nextChild2.Children[0] as Label;
                if (nextChild3.Text?.ToLower() != parameter.ResponseText.ToLower())
                {
                    nextChild3.TextColor       = Color.Black;
                    nextChild2.BackgroundColor = Color.Transparent;
                    (nextChild1.Children[1] as StackLayout).IsVisible = false;
                    foreach (var view in (nextChild1.Children[1] as StackLayout).Children)
                    {
                        var stack = view as StackLayout;
                        foreach (var view1 in stack.Children)
                        {
                            var grid   = view1 as Grid;
                            var stack1 = grid.Children[0] as StackLayout;
                            foreach (var view2 in stack1.Children)
                            {
                                var button = view2 as Button;
                                button.BackgroundColor = Color.FromHex("#fff");
                                button.TextColor       = Color.FromHex("#000");
                            }
                        }
                    }
                }
            }
        }
Esempio n. 23
0
        private void SetCoffeeSource()
        {
            if (!(FindByName("CoffeeList") is StackLayout coffeeListStackLayout))
            {
                return;
            }

            BindableLayout.SetItemsSource(coffeeListStackLayout, GetMyCoffeeList());
        }
        public DynamicShadows()
        {
            InitializeComponent();

            InitNewShade();
            ColorEntry.TextChanged += ColorEntryTextChanged;
            BindableLayout.SetItemsSource(StackLayout, ShadeInfos);
            ColorEntryTextChanged(ColorEntry, new TextChangedEventArgs("", ColorEntry.Text));
        }
        public Issue6932_emptyviewstring()
        {
#if APP
            InitializeComponent();
            BindingContext = _viewModel;

            BindableLayout.SetEmptyView(TheStack, _viewModel.EmptyViewStringDescription);
#endif
        }
Esempio n. 26
0
        public CalendarView()
        {
            InitializeComponent();

            _monthContainer = new MonthContainer(DateTime.Today);
            BindableLayout.SetItemsSource(CalendarDaysContainer, _monthContainer.Days);
            BindableLayout.SetItemsSource(CalendarDaysOfWeekContainer, _monthContainer.DaysOfWeek);
            MonthName.Text = _monthContainer.GetName();
        }
Esempio n. 27
0
        private static void OnEventsChanged(BindableObject bindable, object oldValue, object newValue)
        {
            CalendarDayView thisctrl = (CalendarDayView)bindable;

            if (thisctrl != null && oldValue != newValue)
            {
                ObservableCollection <ICalendarEvent> lst = (ObservableCollection <ICalendarEvent>)newValue;
                BindableLayout.SetItemsSource(thisctrl.flexLayout, lst);
            }
        }
Esempio n. 28
0
        public TestPopupView()
        {
            InitializeComponent();
            List <string> sts = new List <string>();

            for (int i = 0; i < 7; i++)
            {
                sts.Add($"第{i+1}项");
            }
            BindableLayout.SetItemsSource(test, sts);
        }
Esempio n. 29
0
 public altkategori(List <kitaplar> kitap, List <kitaplar> kitap2)
 {
     InitializeComponent();
     BindableLayout.SetItemsSource(liste1, kitap);
     BindableLayout.SetItemsSource(liste2, kitap2);
     yeni  = new List <kitaplar>();
     yeni2 = new List <kitaplar>();
     yeni  = kitap;
     yeni2 = kitap2;
     this.BindingContext = this;
 }
Esempio n. 30
0
        public PersonBindableLayout()
        {
            /* NOTE: All these versions of DataTemplate work.  I'm just leaving these here for example reasons. */

            var personList = (List <Person>)GetValue(BindableLayout.ItemsSourceProperty);

            BindableLayout.SetItemsSource(this, personList);
            BindableLayout.SetItemTemplate(this, new DataTemplate(typeof(PersonView)));

            //BindableLayout.SetItemTemplate(this, new DataTemplate(() => new PersonView()));
            //BindableLayout.SetItemTemplate(this, new DataTemplate(() => { return new PersonView(); }));
        }