Add x86 target

This commit is contained in:
PhyxionNL
2025-10-01 12:03:50 +02:00
parent 2eb3105252
commit 4093b276c6
5 changed files with 29 additions and 4 deletions
@@ -18,7 +18,7 @@
<LangVersion>latest</LangVersion>
<PackageIcon>packageicon.png</PackageIcon>
<GenerateResourceUsePreserializedResources>true</GenerateResourceUsePreserializedResources>
<Platforms>x64</Platforms>
<Platforms>x64;x86</Platforms>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)'=='Debug'">
<OutputPath>..\bin\Debug\</OutputPath>
+11
View File
@@ -29,6 +29,17 @@ public class PawnIo
{
Version = version;
}
else
{
using RegistryKey registryKey = RegistryKey.OpenBaseKey(RegistryHive.LocalMachine, RegistryView.Registry64);
using RegistryKey subKeyWow64 = registryKey.OpenSubKey(@"SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\PawnIO");
if (Version.TryParse(subKeyWow64?.GetValue("DisplayVersion") as string, out version))
{
Version = version;
}
}
}
private PawnIo(SafeFileHandle handle) => _handle = handle;