Add framework for reported disc type

This commit is contained in:
Matt Nadareski
2022-10-19 12:34:40 -07:00
parent 6ad2505bf8
commit 0903855d5c
6 changed files with 10 additions and 0 deletions

View File

@@ -161,6 +161,7 @@
- Disable XGD layerbreak reporting
- Disable XGD1 PVD reporting
- Put Redump limitations behind existing flag
- Add framework for reported disc type
### 2.3 (2022-02-05)
- Start overhauling Redump information pulling, again

View File

@@ -86,6 +86,7 @@ namespace MPF.Core.Data
public const string DumpingDriveManufacturer = "Manufacturer";
public const string DumpingDriveModel = "Model";
public const string DumpingDriveFirmware = "Firmware";
public const string ReportedDiscType = "Reported Disc Type";
public const string PVDField = "Primary Volume Descriptor (PVD)";
public const string DATField = "DAT";
public const string SizeField = "Size";

View File

@@ -842,6 +842,7 @@ namespace MPF.Library
AddIfExists(output, Template.DumpingDriveManufacturer, info.DumpingInfo.Manufacturer, 1);
AddIfExists(output, Template.DumpingDriveModel, info.DumpingInfo.Model, 1);
AddIfExists(output, Template.DumpingDriveFirmware, info.DumpingInfo.Firmware, 1);
AddIfExists(output, Template.ReportedDiscType, info.DumpingInfo.ReportedDiscType, 1);
// Make sure there aren't any instances of two blank lines in a row
string last = null;

View File

@@ -163,6 +163,7 @@ namespace MPF.Test.RedumpLib
Manufacturer = "ATAPI",
Model = "Optical Drive",
Firmware = "1.23",
ReportedDiscType = "CD-R",
},
Artifacts = new Dictionary<string, string>()

View File

@@ -405,6 +405,7 @@ namespace MPF.UI.ViewModels
Manufacturer = "ATAPI",
Model = "Optical Drive",
Firmware = "1.23",
ReportedDiscType = "CD-R",
},
Artifacts = new Dictionary<string, string>()

View File

@@ -542,6 +542,10 @@ namespace RedumpLib.Data
[JsonProperty(PropertyName = "d_drive_firmware", Required = Required.AllowNull)]
public string Firmware { get; set; }
// Name not defined by Redump
[JsonProperty(PropertyName = "d_reported_disc_type", Required = Required.AllowNull)]
public string ReportedDiscType { get; set; }
public object Clone()
{
return new DumpingInfoSection
@@ -550,6 +554,7 @@ namespace RedumpLib.Data
Manufacturer = this.Manufacturer,
Model = this.Model,
Firmware = this.Firmware,
ReportedDiscType = this.ReportedDiscType,
};
}
}