viewmodel ins wpf gepackt, build failed
This commit is contained in:
25
DaSaSo.Wpf/ViewModel/State/Navigation/SewerMainNavigator.cs
Normal file
25
DaSaSo.Wpf/ViewModel/State/Navigation/SewerMainNavigator.cs
Normal file
@@ -0,0 +1,25 @@
|
||||
using DaSaSo.Wpf.ViewModel.Interface;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DaSaSo.Wpf.ViewModel.State.Navigation
|
||||
{
|
||||
public class SewerMainNavigator : ISewerMainNavigator
|
||||
{
|
||||
private BaseViewModel _currentViewModel;
|
||||
public BaseViewModel CurrentViewModel
|
||||
{
|
||||
get => _currentViewModel;
|
||||
set
|
||||
{
|
||||
_currentViewModel?.Dispose();
|
||||
_currentViewModel = value;
|
||||
StateChanged?.Invoke();
|
||||
}
|
||||
}
|
||||
public event Action StateChanged;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user