更新客户端渲染,更新了壳
This commit is contained in:
@@ -0,0 +1,39 @@
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file, You can obtain one at https://opensource.org/licenses/MIT.
|
||||
// Copyright (C) Leszek Pomianowski and WPF UI Contributors.
|
||||
// All Rights Reserved.
|
||||
|
||||
using Wpf.Ui.Abstractions.Controls;
|
||||
|
||||
namespace Wpf.Ui.Demo.Mvvm.ViewModels;
|
||||
|
||||
public abstract class ViewModel : ObservableObject, INavigationAware
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public virtual Task OnNavigatedToAsync()
|
||||
{
|
||||
OnNavigatedTo();
|
||||
|
||||
return Task.CompletedTask;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Handles the event that is fired after the component is navigated to.
|
||||
/// </summary>
|
||||
// ReSharper disable once MemberCanBeProtected.Global
|
||||
public virtual void OnNavigatedTo() { }
|
||||
|
||||
/// <inheritdoc />
|
||||
public virtual Task OnNavigatedFromAsync()
|
||||
{
|
||||
OnNavigatedFrom();
|
||||
|
||||
return Task.CompletedTask;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Handles the event that is fired before the component is navigated from.
|
||||
/// </summary>
|
||||
// ReSharper disable once MemberCanBeProtected.Global
|
||||
public virtual void OnNavigatedFrom() { }
|
||||
}
|
||||
Reference in New Issue
Block a user