//============================================================================* // PopulateSourceCombo() //============================================================================* private void PopulateSourceCombo() { m_fPopulating = true; //----------------------------------------------------------------------------* // Clear the SourceCombo items //----------------------------------------------------------------------------* SourceCombo.Items.Clear(); //----------------------------------------------------------------------------* // Get the source list info & populate the Source Combo //----------------------------------------------------------------------------* List <string> SourceList = m_DataFiles.GetTransactionSourceList(m_Transaction.TransactionType); string strLastSource = m_DataFiles.GetLastTransactionSource(m_Transaction.TransactionType); int nSelectIndex = -1; foreach (string strSource in SourceList) { int nIndex = SourceCombo.Items.Add(strSource); if (m_Transaction.Source == strLastSource) { nSelectIndex = nIndex; } } //----------------------------------------------------------------------------* // Set the selected item //----------------------------------------------------------------------------* if (String.IsNullOrEmpty(m_Transaction.Source)) { SourceCombo.Text = ""; } else { if (nSelectIndex == -1 && SourceCombo.FindString(m_Transaction.Source) == -1) { nSelectIndex = SourceCombo.Items.Add(m_Transaction.Source); } if (nSelectIndex >= 0) { SourceCombo.SelectedIndex = nSelectIndex; } } m_fPopulating = false; }
//============================================================================* // PopulateSourceCombo() //============================================================================* public void PopulateSourceCombo() { m_fPopulating = true; SourceCombo.Items.Clear(); foreach (cTool Tool in m_DataFiles.ToolList) { if (!String.IsNullOrEmpty(Tool.Source)) { if (SourceCombo.FindStringExact(Tool.Source) < 0) { SourceCombo.Items.Add(Tool.Source); } } } m_fPopulating = false; }
private void SceneCombo_TextBox_Clicked(object sender, EventArgs e) { RefreshScenes(); SourceCombo.HideSuggestionListBox(); }
private void SourceComboSetup() { SourceCombo.HideSuggestionListBox(); }
private void SourceComboSetup() { RefreshSources(); SourceCombo.HideSuggestionListBox(); }
private void SceneCombo_AutoTextBox_Clicked(object sender, EventArgs e) { SourceCombo.HideSuggestionListBox(); }
private void SceneCombo_TextChanged(object sender, EventArgs e) { RefreshSources(); SourceCombo.HideSuggestionListBox(); SourceCombo.autoTextBox.Text = ""; }