public ProjectMetadataScreen() { Logger.WriteEvent("ProjectMetadataScreen constructor"); InitializeComponent(); // position the Description and Vernacular label correctly var rowHeight = _tableLayout.GetRowHeights()[0]; _tableLayout.RowStyles[2].SizeType = SizeType.Absolute; _tableLayout.RowStyles[2].Height = rowHeight; _tableLayout.RowStyles[4].SizeType = SizeType.Absolute; _tableLayout.RowStyles[4].Height = rowHeight; // continent list var continentList = ListConstructor.GetClosedList(ListType.Continents, true, ListConstructor.RemoveUnknown.RemoveAll); _continent.DataSource = continentList; _continent.DisplayMember = "Text"; _continent.ValueMember = "Value"; SizeContinentComboBox(_continent); // Data-binding doesn't work correctly for country because it is an open list. // Items populated in HandleStringsLocalized. _countryList = ListConstructor.GetList(ListType.Countries, false, Localize, ListConstructor.RemoveUnknown.RemoveAll); _linkHelp.Click += (s, e) => Program.ShowHelpTopic("/User_Interface/Tabs/About_This_Project_User_Interface_terms.htm"); }
public void GetClosedList_RemoveAll_ReturnNone() { var countries = ListConstructor.GetClosedList(ListType.Countries, true, ListConstructor.RemoveUnknown.RemoveAll); Assert.IsNull(countries.FindByText("Unknown")); Assert.IsNull(countries.FindByText("Unspecified")); Assert.IsNull(countries.FindByText("Undefined")); }