Esempio n. 1
0
        /// <inheritdoc />
        public async Task PopToRootAsync(BaseNavigationViewModel vm, bool animate)
        {
            var navPage = InstantiateView(vm) as Page;

            var root = FormsNavigation.NavigationStack.First();

            FormsNavigation.InsertPageBefore(navPage, root);
            await FormsNavigation.PopToRootAsync(animate);
        }
        public async Task PopToRootAsync()
        {
            switch (Device.RuntimePlatform)
            {
            // TODO Test if still need
            case Device.UWP:
                // Fix for Windows and Windows Phone
                while (NavigationStackDepth > 1)
                {
                    await FormsNavigation.PopAsync(false);
                }

                break;

            default:
                await FormsNavigation.PopToRootAsync(false);

                break;
            }

            PrintNavigationStackDepth("PopToRootAsync");
        }
Esempio n. 3
0
 public async Task PopToRootAsync()
 {
     await FormsNavigation.PopToRootAsync(true);
 }
Esempio n. 4
0
 public async Task PopToRootAsync(bool animate)
 {
     await FormsNavigation.PopToRootAsync(animate);
 }
Esempio n. 5
0
 public Task PopToRootAsync(bool animated = true) => FormsNavigation.PopToRootAsync(animated);