/// <summary /> private void FlagCommandExecuted(object sender, ExecutedRoutedEventArgs e) { if (this.playerView != null && this.playerView.Visibility == System.Windows.Visibility.Visible) { PlayerViewModel item = this.playerView.SelectedItem; MarkedPlayers.Evaluate(item.PlayerData.Name); } else if (this.defenseView != null && this.defenseView.Visibility == System.Windows.Visibility.Visible) { Item_DST item = this.defenseView.dg.SelectedItem as Item_DST; MarkedPlayers.Evaluate(item.TeamName); } }
private void Refresh(IEnumerable<NFLTeam> teams) { lock (((ICollection)this.DefenseSpecialTeams).SyncRoot) { this.DefenseSpecialTeams.Clear(); foreach (NFLTeam team in teams) { Item_DST dst = new Item_DST(team); this.DefenseSpecialTeams.Add(dst); } } }
private void Refresh(IEnumerable <NFLTeam> teams) { lock (((ICollection)this.DefenseSpecialTeams).SyncRoot) { this.DefenseSpecialTeams.Clear(); foreach (NFLTeam team in teams) { Item_DST dst = new Item_DST(team); this.DefenseSpecialTeams.Add(dst); } } }