DSIK_FILEZILLA/sikFtpClient/ViewModel/MainViewModel.cs

53 lines
1.1 KiB
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Input;
namespace sikFtpClient.ViewModel
{
public class MainViewModel : BaseViewModel
{
private BaseViewModel viewModel;
public BaseViewModel ViewModel
{
get
{
return viewModel;
}
set
{
viewModel = value;
OnPropertyChanged();
}
}
public void ShowUpload()
{
ViewModel = new UploadViewModel();
}
RelayCommand showUploadCommand;
public ICommand ShowUploadCommand
{
get
{
if (showUploadCommand == null)
{
showUploadCommand = new RelayCommand(param => this.ShowUpload(),
param => true);
}
return showUploadCommand;
}
}
public MainViewModel()
{
ViewModel = new ConnectionViewModel();
}
}
}