Add and use ItemDictionary class

This commit is contained in:
Matt Nadareski
2020-07-26 22:34:45 -07:00
parent efc90457e5
commit 4f28ae7f61
22 changed files with 879 additions and 812 deletions

View File

@@ -758,9 +758,9 @@ namespace SabreTools.Library.DatFiles
string lastgame = null;
// Use a sorted list of games to output
foreach (string key in SortedKeys)
foreach (string key in Items.SortedKeys)
{
List<DatItem> roms = this[key];
List<DatItem> roms = Items[key];
// Resolve the names in the block
roms = DatItem.ResolveNames(roms);
@@ -837,7 +837,7 @@ namespace SabreTools.Library.DatFiles
xtw.WriteStartElement("configuration");
xtw.WriteElementString("datName", DatHeader.Name);
xtw.WriteElementString("datVersion", DatStats.Count.ToString());
xtw.WriteElementString("datVersion", Items.Statistics.Count.ToString());
xtw.WriteElementString("system", "none");
xtw.WriteElementString("screenshotsWidth", "240");
xtw.WriteElementString("screenshotsHeight", "160");