Get platform automatically when creating softwaretype.

This commit is contained in:
2017-12-29 01:34:02 +00:00
parent efc48f3e6a
commit efd1236999
3 changed files with 5 additions and 7 deletions

View File

@@ -117,7 +117,7 @@ namespace DiscImageChef.Core.Devices.Dumping
currentTry = new DumpHardwareType
{
Software = Metadata.Version.GetSoftwareType(platform),
Software = Metadata.Version.GetSoftwareType(),
Manufacturer = manufacturer,
Model = model,
Serial = serial
@@ -136,7 +136,7 @@ namespace DiscImageChef.Core.Devices.Dumping
};
currentTry = new DumpHardwareType
{
Software = Metadata.Version.GetSoftwareType(platform),
Software = Metadata.Version.GetSoftwareType(),
Manufacturer = manufacturer,
Model = model,
Serial = serial

View File

@@ -670,7 +670,7 @@ namespace DiscImageChef.Core.Devices.Dumping
sidecar.BlockMedia[0].DumpHardwareArray[0].Model = dev.Model;
sidecar.BlockMedia[0].DumpHardwareArray[0].Revision = dev.Revision;
sidecar.BlockMedia[0].DumpHardwareArray[0].Serial = dev.Serial;
sidecar.BlockMedia[0].DumpHardwareArray[0].Software = Version.GetSoftwareType(dev.PlatformId);
sidecar.BlockMedia[0].DumpHardwareArray[0].Software = Version.GetSoftwareType();
sidecar.BlockMedia[0].TapeInformation = partitions.ToArray();
if(!aborted)

View File

@@ -40,15 +40,13 @@ namespace DiscImageChef.Metadata
/// <summary>
/// Gets XML software type for the running version
/// </summary>
/// <param name="platform">Platform we are running in</param>
/// <returns>XML software type</returns>
public static SoftwareType GetSoftwareType(PlatformID platform)
public static SoftwareType GetSoftwareType()
{
// TODO: Platform should be get automatically
return new SoftwareType
{
Name = "DiscImageChef",
OperatingSystem = platform.ToString(),
OperatingSystem = DetectOS.GetRealPlatformID().ToString(),
Version = typeof(Version).Assembly.GetName().Version.ToString()
};
}