private void AddVault() { if (!Vaults.Contains(this)) { Vaults.Add(this); } }
private void RefreshVaults() { Vaults.Clear(); foreach (VaultIndex curVaultIndex in VaultIndexFile.Instance.Indexes) { Vaults.Add(curVaultIndex); } NotifyPropertyChanged("IsEmpty"); NotifyPropertyChanged("ShowVaultListTip"); }
public void SetParameter(String key, Object parameter) { App.AppLogger.Logger.Log(devoctomy.DFramework.Logging.Interfaces.LoggerMessageType.Information | devoctomy.DFramework.Logging.Interfaces.LoggerMessageType.VerboseMed, "VaultListViewModel SetParameter '{0}'.", key); switch (key) { case "Vaults": { Vaults.Clear(); ObservableCollection <VaultIndex> vaultIndexes = (ObservableCollection <VaultIndex>)parameter; foreach (VaultIndex curVaultIndex in vaultIndexes) { Vaults.Add(curVaultIndex); } NotifyPropertyChanged("IsEmpty"); NotifyPropertyChanged("ShowVaultListTip"); break; } } }