Add checkboxes for some fields we can filter on, and start tracking those valuse

This commit is contained in:
Tim Young 2018-09-21 11:23:30 -05:00
parent 6b8ab4907c
commit a63fec2a61

View File

@ -21,11 +21,27 @@ namespace EduNetworkBuilder
public string PuzzleName;
public bool isdone = false;
public string level = "";
public bool InRegressionMode = false;
public bool HasTest = false;
public bool PassedTest = false;
public bool FailedTest = false;
public override string ToString()
{
string donstr = "";
if (isdone) donstr = "* ";
return donstr + level + " " + this.Title;
if (InRegressionMode)
{
if (HasTest) donstr = "+ ";
else donstr = "- ";
if (PassedTest) donstr = "$ ";
if (FailedTest) donstr = "$ ";
return donstr + level + " " + this.Title;
}
else
{
if (isdone) donstr = "* ";
return donstr + level + " " + this.Title;
}
}
}
public partial class ListBoxWindow : Form
@ -130,16 +146,13 @@ namespace EduNetworkBuilder
foreach (string str in NB.GetPuzzleTags())
{
newCB = AddCheckBox(count, str);
if (str == SelectedTag || (SelectedTag == "ALL" && Regex.IsMatch(str, "Level")))
{
newCB.Checked = true; //The first level with an unsolved puzzle starts checked
}
else
{
newCB.Checked = false;
}
count++;
}
newCB = AddCheckBox(count++, "Test");
newCB = AddCheckBox(count++, "No Test");
newCB = AddCheckBox(count++, "Passed");
newCB = AddCheckBox(count++, "Failed");
panelCheckboxes.ResumeLayout();
btnOK.Text = NB.Translate("_Load");
btnAdd.Text = NB.Translate("_Cancel");