private void listViewLocale_SelectedIndexChanged(object sender, EventArgs e)
{
if (this.listViewLocale.SelectedItems.Count > 1)
{
this.textBoxGeneralName.Enabled = true;
this.textBoxGeneralName.Text = "";
this.textBoxGeneralDescription.Text = "";
this.comboBoxLocaleCategory.SelectedIndex = -1;
this.textBoxLocaleURL.Text = "";
}
if (this.listViewLocale.SelectedItems.Count == 1)
{
DocLocalization docLocal = (DocLocalization)this.listViewLocale.SelectedItems[0].Tag;
this.textBoxGeneralName.Enabled = true;
this.textBoxGeneralName.Text = docLocal.Name;
this.textBoxGeneralDescription.Text = docLocal.Documentation;
this.comboBoxLocaleCategory.SelectedIndex = (int)docLocal.Category;
this.textBoxLocaleURL.Text = docLocal.URL;
this.comboBoxLocaleCategory.Enabled = true;
this.textBoxLocaleURL.Enabled = true;
}
else
{
this.textBoxGeneralName.Enabled = false;
this.textBoxGeneralName.Text = this.m_target.Name;
this.textBoxGeneralDescription.Text = this.m_target.Documentation;
this.comboBoxLocaleCategory.Enabled = false;
this.textBoxLocaleURL.Enabled = false;
this.comboBoxLocaleCategory.SelectedIndex = -1;
this.textBoxLocaleURL.Text = "";
}
this.toolStripButtonTranslationRemove.Enabled = (this.listViewLocale.SelectedItems.Count > 0);
}