예제 #1
0
        public async Task PushModalAsync(Page modal, bool animated)
        {
            CurrentPageController?.SendDisappearing();
            UpdateAccessibilityImportance(CurrentPage, ImportantForAccessibility.NoHideDescendants, false);

            _navModel.PushModal(modal);

            Task presentModal = PresentModal(modal, animated);

            await presentModal;

            UpdateAccessibilityImportance(modal, ImportantForAccessibility.Auto, true);

            // Verify that the modal is still on the stack
            if (_navModel.CurrentPage == modal)
            {
                ((IPageController)modal).SendAppearing();
            }
        }
예제 #2
0
        async Task INavigation.PushModalAsync(Page modal, bool animated)
        {
            CurrentPageController?.SendDisappearing();

            _navModel.PushModal(modal);

            modal.Platform = this;

            await PresentModal(modal, animated);

            // Verify that the modal is still on the stack
            if (_navModel.CurrentPage == modal)
            {
                ((IPageController)modal).SendAppearing();
            }

            _toolbarTracker.Target = _navModel.Roots.Last();

            UpdateActionBar();
        }