private void extButtonFilter_Click(object sender, EventArgs e) { ExtendedControls.CheckedIconListBoxSelectionForm bodyfilter; bodyfilter = new CheckedIconListBoxSelectionForm(); bodyfilter.AddAllNone(); foreach (var x in Enum.GetNames(typeof(EDPlanet))) { bodyfilter.AddStandardOption(x.ToString(), x.ToString().Replace("_", " ")); } foreach (var x in Enum.GetNames(typeof(EDStar))) { bodyfilter.AddStandardOption(x.ToString(), Bodies.StarName(x.ParseEnum <EDStar>())); } // these are filter types for items which are either do not have scandata or are not stars/bodies. Only Belts/Barycentre are displayed.. scans of rings/beltculsters are not displayed bodyfilter.AddStandardOption("star", "Star"); bodyfilter.AddStandardOption("body", "Body"); bodyfilter.AddStandardOption("barycentre", "Barycentre"); bodyfilter.AddStandardOption("belt", "Belt"); bodyfilter.Closing = (s, o) => { bodyfilters = s.Split(';'); SQLiteDBClass.PutSettingString(DbSave + "BodyFilters", string.Join(";", bodyfilters)); DrawSystem(); }; bodyfilter.Show(string.Join(";", bodyfilters), extButtonFilter, this.FindForm()); }
private void extButton6_Click(object sender, EventArgs e) { CheckedIconListBoxSelectionForm f = new CheckedIconListBoxSelectionForm(); var imglist = new Image[] { Properties.Resources.edlogo24, Properties.Resources.Logo8bpp48, Properties.Resources.galaxy_white, Properties.Resources.Logo8bpp48rot, Properties.Resources.galaxy_red, }; for (int i = 0; i < 50; i++) { f.AddStandardOption("T" + i.ToString(), "Tx" + i.ToString(), imglist[i % imglist.Length]); } f.CloseOnDeactivate = false; f.CloseOnChange = true; f.CheckedChanged += F_CheckedChanged; f.Show("", extButton5, this, 300, applytheme: true); }
private void CLBSF(float size, bool group) { CheckedIconListBoxSelectionForm f = new CheckedIconListBoxSelectionForm(); var imglist = new Image[] { Properties.Resources.edlogo24, Properties.Resources.Logo8bpp48, Properties.Resources.galaxy_white, Properties.Resources.Logo8bpp48rot, Properties.Resources.galaxy_red, }; for (int i = 0; i < 50; i++) { f.AddStandardOption("T" + i.ToString(), "Tx" + i.ToString(), imglist[i % imglist.Length]); } if (group) { f.AddGroupOption("T1;T2;T3;T4;", "G1-4"); f.AddGroupOption("T5;T6;T7;T8;", "G5-8"); } //f.CloseOnDeactivate = false; f.CheckedChanged += F_CheckedChanged; theme.FontSize = size; f.Show("", extButton5, this, 300, applytheme: true); }