private void MoveFavoriteAliasesGroup(GroupConfigurationElement configGroup) { IGroup group = FavoritesFactory.GetOrAddNewGroup(this.persistence, configGroup.Name); List <string> favoriteNames = configGroup.FavoriteAliases.GetFavoriteNames(); List <IFavorite> groupFavorites = favoriteNames.Select(favoriteName => persistence.Favorites[favoriteName]) .Where(favorite => favorite != null).ToList(); group.AddFavorites(groupFavorites); }
private void AddFavoritesToGroup(IGroup group) { using (var frmAddConnection = new AddConnectionForm(this.persistence, this.favoriteIcons)) { if (frmAddConnection.ShowDialog() == DialogResult.OK) { group.AddFavorites(frmAddConnection.SelectedFavorites); this.LoadSelectedGroupFavorites(); this.persistence.SaveAndFinishDelayedUpdate(); } } }
private void AddFavoritesToGroup(IGroup group) { using (var frmAddConnection = new AddConnectionForm(this.persistence)) { if (frmAddConnection.ShowDialog() == DialogResult.OK) { group.AddFavorites(frmAddConnection.SelectedFavorites); this.LoadSelectedGroupFavorites(); this.persistence.SaveAndFinishDelayedUpdate(); } } }