Skip to content

Commit 63b2a07

Browse files
committed
load unmanaged dll from dependencyResolver as well
1 parent 5c7141d commit 63b2a07

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

Flow.Launcher.Core/Plugin/PluginAssemblyLoader.cs

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,22 @@ protected override Assembly Load(AssemblyName assemblyName)
3434

3535
return existAssembly ?? (assemblyPath == null ? null : LoadFromAssemblyPath(assemblyPath));
3636
}
37+
38+
protected override IntPtr LoadUnmanagedDll(string unmanagedDllName)
39+
{
40+
var path = dependencyResolver.ResolveUnmanagedDllToPath(unmanagedDllName);
41+
if (!string.IsNullOrEmpty(path))
42+
{
43+
return LoadUnmanagedDllFromPath(path);
44+
}
45+
46+
return IntPtr.Zero;
47+
}
3748

3849
internal Type FromAssemblyGetTypeOfInterface(Assembly assembly, Type type)
3950
{
4051
var allTypes = assembly.ExportedTypes;
4152
return allTypes.First(o => o.IsClass && !o.IsAbstract && o.GetInterfaces().Any(t => t == type));
4253
}
4354
}
44-
}
55+
}

Plugins/Flow.Launcher.Plugin.BrowserBookmark/Flow.Launcher.Plugin.BrowserBookmark.csproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
1313
<AppendRuntimeIdentifierToOutputPath>false</AppendRuntimeIdentifierToOutputPath>
1414
<UseWindowsForms>true</UseWindowsForms>
15-
<RuntimeIdentifier>win-x64</RuntimeIdentifier>
1615
</PropertyGroup>
1716

1817
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">

0 commit comments

Comments
 (0)