public ObservationDetailsPage(Models.SummaryObservation summaryObservation)
        {
            if (Device.RuntimePlatform == Device.Android)
            {
                NavigationPage.SetHasNavigationBar(this, false);
            }

            this.summaryObservation = summaryObservation;
            InitializeComponent();
        }
Exemple #2
0
        private Controls.ContentPresenter BuildObservationPresenter(DataTemplate template, Models.SummaryObservation observation)
        {
            Controls.ContentPresenter presenter = new Controls.ContentPresenter()
            {
                BindingContext = observation,
            };
            presenter.ItemTemplate = template;
            TapGestureRecognizer tapGestureRecognizer = new TapGestureRecognizer();

            // TODO: Change device tapped to go somewhere else?
            tapGestureRecognizer.Tapped += Observation_Tapped;
            presenter.GestureRecognizers.Add(tapGestureRecognizer);
            return(presenter);
        }