private void StartNavigation(PageGroupItem item, object vm, int?stateId)
        {
            var navigator = item.CreateNavigator(vm);

            // ページ群内ナビゲーションがキャンセルじゃなくて、明示的終了した時には NavigateBack を呼ぶ。
            _current = new NavigationState(navigator, vm, stateId, NavigateBackAsync);

            CurrentPageKey = item.Key;
        }
        public void Add(PageGroupItem item)
        {
            if (StartPageKey == null)
            {
                StartPageKey = item.Key;
            }

            item.Navigator = this;
            _table.Add(item.Key, item);
        }
        private async Task NavigateAsync(PageGroupItem item, bool pushHistory)
        {
            var vm = item.CreateViewModel();

            await NavigateAsync(item, vm, null, pushHistory);
        }
        private async Task NavigateAsync(PageGroupItem item, object vm, int?stateId, bool pushHistory)
        {
            await CloseAsync(pushHistory);

            StartNavigation(item, vm, stateId);
        }
 internal Task NavigateAsync(PageGroupItem item)
 {
     return(NavigateAsync(item, true));
 }