示例#1
0
        private void AddGuildToChecking(object sender, RoutedEventArgs e)
        {
            var guildName = CheckingGuildNameTextBox.Text;

            if (string.IsNullOrEmpty(guildName))
            {
                MessageBox.Show("Введите значение");
                return;
            }

            var newGuild = _explorer.GetGuild(Region.EU, SelectedGuildCheckingServerName, guildName);

            GuildsForChecking.Add(newGuild);
        }
示例#2
0
        private void OnWindowClosing(object sender, CancelEventArgs e)
        {
            if (BannedGuilds.Any())
            {
                WriteObjects(BannedGuildsFileName, BannedGuilds.ToList());
            }

            if (BannedPlayers.Any())
            {
                WriteObjects(BannedPlayersFileName, BannedPlayers.ToList());
            }

            if (GuildsForChecking.Any())
            {
                WriteObjects(GuildsForCheckingFileName, GuildsForChecking.ToList());
            }
        }
示例#3
0
 private void RemoveGuildToChecking(object sender, RoutedEventArgs e)
 {
     GuildsForChecking.Remove(SelectedGuildForChecking);
 }