using Common.WPF;
//using WPF.Helpers;
using WPF.Model;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
namespace WPF.ViewModel
{
public class MainViewModel : ModifyViewModel
{
public MainViewModel() : base()
{
//Items = new ObservableCollection<ItemViewModel>();
//System.Windows.Data.BindingOperations.EnableCollectionSynchronization(Items, _lock);
//CreatePanel = new CreatingViewModel(this);
//IsAllDataHide = true;
EnumTheorems = Enum.GetValues(typeof(EnumTheorem)).Cast<EnumTheorem>().ToList();
SelectedTheorem = EnumTheorems.First();
//AddItemCommand = new RelayCommand<ItemViewModel>(OnAddItem, item => Items.FirstOrDefault(e => e.Value == item.Value) == null);
//RemoveItemCommand = new RelayCommand<ItemViewModel>(OnRemoveItem, item => !item.Readonly);
//OpenFileCommand = new RelayCommand(OnOpenFile);
//SwitchDataVisibleCommand = new RelayCommand(OnSwitchDataVisible);
//ClearSearchCommand = new RelayCommand(OnClearSearch);
}
#region Поля и свойства
public List<EnumTheorem> EnumTheorems { get; }
private EnumTheorem _selectedTheorem;
public EnumTheorem SelectedTheorem
{
set
{
_selectedTheorem = value;
OnPropertyChanged(()=> SelectedTheorem);
// do smth
}
get => _selectedTheorem;
}
#endregion
#region Методы и команды
public void OnLoad()
{
//LoadData(App.DataFilePath);
//LoadDataAsync(App.DataFilePath, true);
}
#endregion
}
}