Add x86 target
This commit is contained in:
@@ -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>
|
||||
|
||||
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user