Python plugin loader bug fix.

This commit is contained in:
qianlifeng
2014-07-11 18:36:39 +08:00
parent f1ce98eb07
commit e8f3a30a72
52 changed files with 5 additions and 4 deletions

1
.gitignore vendored
View File

@@ -1,4 +1,5 @@
*.pyd *.pyd
*.pyc
# Build Folders (you can keep bin if you'd like, to store dlls and pdbs) # Build Folders (you can keep bin if you'd like, to store dlls and pdbs)
[Bb]in/ [Bb]in/

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -10,12 +10,12 @@ namespace Wox.PluginLoader
{ {
public virtual List<PluginPair> LoadPlugin(List<PluginMetadata> pluginMetadatas) public virtual List<PluginPair> LoadPlugin(List<PluginMetadata> pluginMetadatas)
{ {
T pluginWrapper = new T(); string supportedLanguage = new T().SupportedLanguage;
List<PluginMetadata> metadatas = pluginMetadatas.Where(o => pluginWrapper.SupportedLanguage.ToUpper() == o.Language.ToUpper()).ToList(); List<PluginMetadata> metadatas = pluginMetadatas.Where(o => supportedLanguage.ToUpper() == o.Language.ToUpper()).ToList();
return metadatas.Select(metadata => new PluginPair() return metadatas.Select(metadata => new PluginPair()
{ {
Plugin = pluginWrapper, Plugin = new T(),
Metadata = metadata Metadata = metadata
}).ToList(); }).ToList();
} }

View File

@@ -22,7 +22,7 @@
<ColumnDefinition Width="32"></ColumnDefinition> <ColumnDefinition Width="32"></ColumnDefinition>
<ColumnDefinition/> <ColumnDefinition/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<Image x:Name="imgIco" Width="32" Height="32" HorizontalAlignment="Left" > <Image x:Name="imgIco" Width="32" Height="32" HorizontalAlignment="Left">
<Image.Resources> <Image.Resources>
<converters:ImagePathConverter x:Key="ImageConverter"/> <converters:ImagePathConverter x:Key="ImageConverter"/>
</Image.Resources> </Image.Resources>