public DataViewModel() { SearchCommand = new CancellableCommand((p, t) => Search((string)p), _=> Core.DataContainer!=null); }
public ServerSettingsViewModel() { DeleteCommand = new Command(_ => Delete(), _ => _SelectedSettings != null); NewCommand = new Command(_ => New()); CommandTest = new CancellableCommand((p, t) => Test(t), p => !string.IsNullOrWhiteSpace(_Url) && _GeneratorModel != null && _GeneratorModel.IsConfigured); CommandTestCancel = new Command(_ => CommandTest.Cancell()); CommandTest.IsEnabled = false; }