private void QuestDeSelectButton_Click(object sender, EventArgs e) { int iTemp; var loopTo = QuestListBox.Items.Count - 1; for (iTemp = 0; iTemp <= loopTo; iTemp++) { QuestListBox.SetItemChecked(iTemp, false); } }
private void QuestsAddQuestBtn_Click(object sender, EventArgs e) { AddQuest NewQuestForm = new AddQuest(); DialogResult NewQuestResult = NewQuestForm.ShowDialog(); if (NewQuestResult == DialogResult.OK) { Program.questList[NewQuestForm.NewQuest.DaybreakID] = NewQuestForm.NewQuest; _ = QuestListBox.Items.Add(NewQuestForm.NewQuest); AllItemsPresentCheck(); dirties[3] = true; StatusStripDirtyIndicator.Text = FloppyString; } else if (NewQuestResult == DialogResult.Abort) { BadEnd(); throw NewQuestForm.ReturnedException; } NewQuestForm.Dispose(); QuestListBox.Refresh(); }