mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
Update enum handling, part 1
This commit is contained in:
@@ -212,7 +212,7 @@ namespace SabreTools.DatFiles.Formats
|
||||
bool containsItems = false;
|
||||
Machine machine = new()
|
||||
{
|
||||
MachineType = (resource ? MachineType.Bios : MachineType.NULL),
|
||||
MachineType = (resource ? MachineType.Bios : MachineType.None),
|
||||
};
|
||||
|
||||
// If there's no subtree to the header, skip it
|
||||
@@ -276,7 +276,10 @@ namespace SabreTools.DatFiles.Formats
|
||||
string itemKey = cmpr.InternalName;
|
||||
|
||||
// Create the proper DatItem based on the type
|
||||
ItemType itemType = itemKey.AsItemType() ?? ItemType.Rom;
|
||||
ItemType itemType = itemKey.AsItemType();
|
||||
if (itemType == ItemType.NULL)
|
||||
itemType = ItemType.Rom;
|
||||
|
||||
DatItem item = DatItem.Create(itemType);
|
||||
|
||||
// Then populate it with information
|
||||
|
||||
Reference in New Issue
Block a user