laatzen/Common/Ui/Common.UI/ViewModels/MainWindowVM.cs
2024-11-13 15:50:04 +01:00

30 lines
747 B
C#

namespace Common.UI.ViewModels
{
using Common.UI.Infrastructure;
using System;
using System.Windows.Input;
internal class MainWindowVM : BaseViewModel<MainWindowVM>
{
public MainWindowVM()
{
this.SetSourceCommand = new Command<string>(this.SetSourceCommandHandler);
this.SetSourceCommandHandler("EregisterManuelProgramming.xaml");
}
private Uri source;
public Uri Source
{
get => this.source;
set => this.Set(vm => vm.source = value);
}
public ICommand SetSourceCommand { get; }
private void SetSourceCommandHandler(string url)
=> this.Source = new Uri(url, UriKind.Relative);
}
}