mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-21 18:52:36 +01:00
git-svn-id: https://subtitleedit.googlecode.com/svn/trunk@37 99eadd0c-20b8-1223-b5c4-2a2b2df33de2
This commit is contained in:
parent
50f2ac7701
commit
6ea087e091
@ -5010,13 +5010,13 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
if (!localNamesEtc.Contains(word) && !namesEtc.Contains(word))
|
||||
{
|
||||
wordsAdded++;
|
||||
localNamesEtc.Add(word);
|
||||
localNamesEtc.Sort();
|
||||
namesEtc.Add(word);
|
||||
}
|
||||
}
|
||||
|
||||
if (MessageBox.Show("Add new words: " + wordsAdded.ToString(), "", MessageBoxButtons.OKCancel) == System.Windows.Forms.DialogResult.OK)
|
||||
{
|
||||
namesEtc.Sort();
|
||||
var namesEtcDoc = new XmlDocument();
|
||||
if (File.Exists(globalNamesEtcFileName))
|
||||
namesEtcDoc.Load(globalNamesEtcFileName);
|
||||
@ -5027,13 +5027,13 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
if (de != null)
|
||||
{
|
||||
de.RemoveAll();
|
||||
foreach (var name in localNamesEtc)
|
||||
foreach (var name in namesEtc)
|
||||
{
|
||||
XmlNode node = namesEtcDoc.CreateElement("name");
|
||||
node.InnerText = name;
|
||||
de.AppendChild(node);
|
||||
}
|
||||
namesEtcDoc.Save(userNamesEtcXmlFileName);
|
||||
namesEtcDoc.Save(globalNamesEtcFileName);
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user