async Task <Page> INavigation.PopModalAsync(bool animated) { var modal = _modals.Last(); _modals.Remove(modal); modal.DescendantRemoved -= HandleChildRemoved; var controller = GetRenderer(modal) as UIViewController; if (_modals.Count >= 1 && controller != null) { await controller.DismissViewControllerAsync(animated); } else { await _renderer.DismissViewControllerAsync(animated); } modal.DisposeModalAndChildRenderers(); if (!IsModalPresentedFullScreen(modal)) { Page.GetCurrentPage()?.SendAppearing(); } return(modal); }
async Task <Page> INavigation.PopModalAsync(bool animated) { var modal = _modals.Last(); _modals.Remove(modal); modal.DescendantRemoved -= HandleChildRemoved; var controller = GetRenderer(modal) as UIViewController; if (_modals.Count >= 1 && controller != null) { await controller.DismissViewControllerAsync(animated); } else { await _renderer.DismissViewControllerAsync(animated); } modal.DisposeModalAndChildRenderers(); return(modal); }