fix program suffixes
This commit is contained in:
bao-qian 2016-04-24 18:34:49 +01:00
parent 07fe141f8a
commit d416a77866
3 changed files with 3 additions and 4 deletions

View File

@ -10,7 +10,8 @@ namespace Wox.Plugin.Program
public string Type { get; set; }
public int BonusPoints { get; set; }
public bool Enabled { get; set; }
public string[] Suffixes { get; set; }
// happlebao todo: temp hack for program suffixes
public string[] Suffixes { get; set; } = {"bat", "appref-ms", "exe", "lnk"};
public const char SuffixSeperator = ';';
public int MaxDepth { get; set; }
public Dictionary<string, string> Meta { get; set; }

View File

@ -107,8 +107,6 @@ namespace Wox.Plugin.Program
{
sources.AddRange(_settings.ProgramSources);
}
// happlebao todo: temp hack for program suffixes
sources.AsParallel().ForAll(s => { s.Suffixes = _settings.ProgramSuffixes; });
_sources = sources.AsParallel()
.Where(s => s.Enabled && SourceTypes.ContainsKey(s.Type))

View File

@ -12,7 +12,7 @@ namespace Wox.Plugin.Program
var text = value as string[];
if (text != null)
{
return string.Join("", text);
return string.Join(";", text);
}
else
{