IfcDoc.CtlProperties.toolStripButtonTranslationInsert_Click C# (CSharp) Method

toolStripButtonTranslationInsert_Click() private method

private toolStripButtonTranslationInsert_Click ( object sender, EventArgs e ) : void
sender object
e EventArgs
return void
        private void toolStripButtonTranslationInsert_Click(object sender, EventArgs e)
        {
            using (FormSelectLocale form = new FormSelectLocale())
            {
                DialogResult res = form.ShowDialog(this);
                if (res == DialogResult.OK && form.SelectedLocale != null)
                {
                    DocLocalization docLocal = new DocLocalization();
                    docLocal.Locale = form.SelectedLocale.Name;
                    this.m_target.Localization.Add(docLocal);

                    ListViewItem lvi = new ListViewItem();
                    lvi.Tag = docLocal;
                    lvi.Text = docLocal.Locale;
                    lvi.SubItems.Add("");
                    lvi.SubItems.Add("");
                    this.listViewLocale.Items.Add(lvi);

                    this.listViewLocale.SelectedItems.Clear();
                    lvi.Selected = true;
                }
            }
        }
CtlProperties