namespace WPFluent.Abstractions;
///
/// Provides a base class for navigation-aware components.
///
public abstract class NavigationAware : INavigationAware
{
///
/// Handles the event that is fired before the component is navigated from.
///
// ReSharper disable once MemberCanBeProtected.Global
public virtual void OnNavigatedFrom()
{
}
///
public virtual Task OnNavigatedFromAsync()
{
OnNavigatedFrom();
return Task.CompletedTask;
}
///
/// Handles the event that is fired after the component is navigated to.
///
// ReSharper disable once MemberCanBeProtected.Global
public virtual void OnNavigatedTo()
{
}
///
public virtual Task OnNavigatedToAsync()
{
OnNavigatedTo();
return Task.CompletedTask;
}
}