mirror of
https://github.com/microsoft/PowerToys.git
synced 2024-12-15 20:19:17 +08:00
8aee2858ea
1. completed rewrite the action keyword setting logic. 2. Fix setting for multiple action keywords in #352 3. Fix setting for Web Search plugin
39 lines
886 B
C#
39 lines
886 B
C#
namespace Wox.Plugin
|
|
{
|
|
public class PluginPair
|
|
{
|
|
public IPlugin Plugin { get; internal set; }
|
|
public PluginMetadata Metadata { get; internal set; }
|
|
|
|
internal long InitTime { get; set; }
|
|
|
|
internal long AvgQueryTime { get; set; }
|
|
|
|
internal int QueryCount { get; set; }
|
|
|
|
public override string ToString()
|
|
{
|
|
return Metadata.Name;
|
|
}
|
|
|
|
public override bool Equals(object obj)
|
|
{
|
|
PluginPair r = obj as PluginPair;
|
|
if (r != null)
|
|
{
|
|
return string.Equals(r.Metadata.ID, Metadata.ID);
|
|
}
|
|
else
|
|
{
|
|
return false;
|
|
}
|
|
}
|
|
|
|
public override int GetHashCode()
|
|
{
|
|
var hashcode = Metadata.ID?.GetHashCode() ?? 0;
|
|
return hashcode;
|
|
}
|
|
}
|
|
}
|