Skip to content

Commit 0b19c46

Browse files
committed
Improvements after live (#2013)
1 parent cc770c8 commit 0b19c46

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

src/Controls/src/Core/NavigationProxy.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,8 @@ protected virtual Task OnPushAsync(Page page, bool animated)
212212
INavigation currentInner = Inner;
213213
if (currentInner is null)
214214
{
215-
throw new InvalidOperationException("Page must be wrapped into a navigation page to perform navigation");
215+
_pushStack.Value.Add(page);
216+
return Task.FromResult(page);
216217
}
217218
return currentInner.PushAsync(page, animated);
218219
}

src/Controls/src/Core/Window/Window.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -679,6 +679,11 @@ public NavigationImpl(Window owner)
679679
_owner = owner;
680680
}
681681

682+
protected override Task OnPushAsync(Page page, bool animated)
683+
{
684+
throw new InvalidOperationException("Page must be wrapped into a navigation page to perform navigation");
685+
}
686+
682687
protected override IReadOnlyList<Page> GetModalStack()
683688
{
684689
return _owner.ModalNavigationManager.ModalStack;

0 commit comments

Comments
 (0)