All but the button Create Tournament Wired up

This commit is contained in:
2020-04-06 22:21:02 +02:00
parent af9ee4113d
commit d6f251c822
4 changed files with 26 additions and 9 deletions

View File

@ -205,6 +205,7 @@
this.removeSelectedPrizeButton.TabIndex = 23;
this.removeSelectedPrizeButton.Text = "Remove Selected";
this.removeSelectedPrizeButton.UseVisualStyleBackColor = true;
this.removeSelectedPrizeButton.Click += new System.EventHandler(this.removeSelectedPrizeButton_Click);
//
// prizesLabel
//
@ -240,6 +241,7 @@
this.createTournamentButton.TabIndex = 24;
this.createTournamentButton.Text = "Create Tournament";
this.createTournamentButton.UseVisualStyleBackColor = true;
this.createTournamentButton.Click += new System.EventHandler(this.createTournamentButton_Click);
//
// CreateTournamentForm
//

View File

@ -80,16 +80,31 @@ namespace TrackerUI
private void removeSelectedPlayerButton_Click(object sender, EventArgs e)
{
TeamModel t = (TeamModel)tournamentTeamsListBox.SelectedItem;
if (t != null)
{
selectedTeams.Remove(t);
availableTeams.Add(t);
//PersonModel p = (PersonModel)teamMembersListBox.SelectedItem;
WireUpLists();
}
//if (p != null)
//{
// selectedTeamMembers.Remove(p);
// availableTeamMembers.Add(p);
}
private void removeSelectedPrizeButton_Click(object sender, EventArgs e)
{
PrizeModel p = (PrizeModel)prizesListBox.SelectedItem;
if (p != null)
{
selectedPrizes.Remove(p);
WireUpLists();
}
}
private void createTournamentButton_Click(object sender, EventArgs e)
{
// WireUpLists();
//}
}
}
}

View File

@ -19,7 +19,7 @@ namespace TrackerUI
Application.SetCompatibleTextRenderingDefault(false);
// Initialize the database connections
GlobalConfig.InitializeConnections(DatabaseType.Sql);
GlobalConfig.InitializeConnections(DatabaseType.TextFile);
Application.Run(new CreateTournamentForm());
//Application.Run(new TournamentDashboardForm());