private FrmWizConfigurationCluster(Core core, Peak current) : this() { this._core = core; this._chart = new ChartHelperForPeaks(null, core, this.panel1); this._ecbFilter = DataSet.ForObsFilter(core).CreateComboBox(this._lstFilters, this._btnEditFilters, EditableComboBox.EFlags.IncludeAll); this._ecbSource = DataSet.ForMatrixProviders(core).CreateComboBox(this._lstSource, this._btnSource, EditableComboBox.EFlags.IncludeNone); this._ecbSeedPeak = DataSet.ForPeaks(core).CreateComboBox(this._lstSeedPeak, this._btnSeedPeak, EditableComboBox.EFlags.None); this._ecbSeedGroup = DataSet.ForGroups(core).CreateComboBox(this._lstGroups, this._btnGroups, EditableComboBox.EFlags.None); this._lstGroups.Items.AddRange(NamedItem.GetRange(core.Groups, z => z.DisplayName).ToArray()); this._lstGroups.SelectedIndex = 0; this._ecbPeakFilter = DataSet.ForPeakFilter(core).CreateComboBox(this._lstPeakFilter, this._btnPeakFilter, EditableComboBox.EFlags.IncludeAll); this._ecbDistance = DataSet.ForMetricAlgorithms(core).CreateComboBox(this._lstDistanceMeasure, this._btnDistanceMeasure, EditableComboBox.EFlags.None); this._lstDistanceMeasure.SelectedIndexChanged += this._lstDistanceMeasure_SelectedIndexChanged; this._ecbSeedPeak.SelectedItem = current; this._wizard = CtlWizard.BindNew(this, this.tabControl1, CtlWizardOptions.DEFAULT | CtlWizardOptions.DialogResultCancel | CtlWizardOptions.HandleBasicChanges); this._wizard.OkClicked += this.wizard_OkClicked; this._wizard.TitleHelpText = Resx.Manual.DKMeansPlusPlus; this._wizard.PermitAdvance += this.ValidatePage; this._wizard.Revalidate(); }
private void UpdateItemsNoPreserve() { this.ComboBox.Items.Clear(); // Null ("all" or "none") item if (this._includeNull != ENullItemName.NoNullItem) { this._none = new NamedItem <object>(ReflectionHelper.GetDefault(this._config.DataType), this._includeNull.ToUiString()); this.ComboBox.Items.Add(this._none); } // Regular items NamedItem <object>[] source = NamedItem.GetRange <object>(this._config.UntypedGetList(true).Cast <object>(), this._config.UntypedName).ToArray(); Array.Sort <NamedItem <object> >(source); // For Julie this.ComboBox.Items.AddRange(source); // Edit button item if (_button != null) { this.ComboBox.Items.Add(new NamedItem <object>(new SpecialEditItem())); } }