Rename Cleaner.Clean to Normalize

This commit is contained in:
Matt Nadareski
2025-02-19 13:51:00 -05:00
parent 4066516c7b
commit a18b6c1e61
3 changed files with 11 additions and 11 deletions

View File

@@ -15,11 +15,6 @@ namespace SabreTools.DatTools
{
#region Fields
/// <summary>
/// Clean all names to WoD standards
/// </summary>
public bool Clean { get; set; }
/// <summary>
/// Deduplicate items using the given method
/// </summary>
@@ -35,6 +30,11 @@ namespace SabreTools.DatTools
/// </summary>
public bool KeepEmptyGames { get; set; }
/// <summary>
/// Normalize all names to WoD standards
/// </summary>
public bool Normalize { get; set; }
/// <summary>
/// Enable "One Rom, One Region (1G1R)" mode
/// </summary>
@@ -226,8 +226,8 @@ namespace SabreTools.DatTools
datItemName = TextHelper.RemoveUnicodeCharacters(datItemName);
}
// If we're in cleaning mode, sanitize machine name and description
if (Clean)
// If we're in normalization mode, sanitize machine name and description
if (Normalize)
{
machineName = TextHelper.NormalizeCharacters(machineName);
machineDesc = TextHelper.NormalizeCharacters(machineDesc);
@@ -283,8 +283,8 @@ namespace SabreTools.DatTools
datItemName = TextHelper.RemoveUnicodeCharacters(datItemName);
}
// If we're in cleaning mode, sanitize machine name and description
if (Clean)
// If we're in normalization mode, sanitize machine name and description
if (Normalize)
{
machineName = TextHelper.NormalizeCharacters(machineName);
machineDesc = TextHelper.NormalizeCharacters(machineDesc);

View File

@@ -34,7 +34,7 @@ namespace SabreTools.Test
// Setup cleaner
var cleaner = new Cleaner
{
Clean = true,
Normalize = true,
};
// Setup DatItem

View File

@@ -2158,7 +2158,7 @@ Some special strings that can be used:
{
Cleaner cleaner = new()
{
Clean = GetBoolean(features, CleanValue),
Normalize = GetBoolean(features, CleanValue),
DedupeRoms = GetDedupeType(features),
DescriptionAsName = GetBoolean(features, DescriptionAsNameValue),
KeepEmptyGames = GetBoolean(features, KeepEmptyGamesValue),