コード例 #1
0
        public override void ViewWillAppear(bool animated)
        {
            base.ViewWillAppear(animated);

            var viewModel = ServiceContainer.Resolve <DetailsViewModel>();

            if (viewModel.Place.Reviews == null || viewModel.Place.Reviews.Count == 0)
            {
                var warnginView = WarningMessageView.GetView("no_reviews".LocalizedString("If place have no reviews"), this);
                View = warnginView;
                return;
            }

            reviews = viewModel.Place.Reviews;

                        #if !DEBUG
            Xamarin.Insights.Track("AppNav", new Dictionary <string, string> {
                { "page", "reviews" },
                { "name", viewModel.Place.Name },
            });
                        #endif
        }
コード例 #2
0
        public override void ViewWillAppear(bool animated)
        {
            base.ViewWillAppear(animated);

            var viewModel = ServiceContainer.Resolve <DetailsViewModel>();

            if (viewModel.Place.Photos != null && viewModel.Place.Photos.Count != 0)
            {
                photos = viewModel.Place.Photos;
            }
            else
            {
                var warningView = WarningMessageView.GetView("no_photos".LocalizedString("If place have no photos"), this);
                View = warningView;
            }

                        #if !DEBUG
            Xamarin.Insights.Track("AppNav", new Dictionary <string, string> {
                { "page", "photos" },
                { "name", viewModel.Place.Name },
            });
                        #endif
        }