Mouse select support & Code refactoring

This commit is contained in:
qianlifeng
2014-01-26 21:18:01 +08:00
parent 36018fe570
commit c7dfaac61a
12 changed files with 106 additions and 89 deletions

View File

@@ -0,0 +1,31 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using WinAlfred.Helper;
using WinAlfred.Plugin;
namespace WinAlfred.Commands
{
internal static class CommandFactory
{
private static PluginCommand pluginCmd;
private static SystemCommand systemCmd;
public static void DispatchCommand(Query query, bool updateView = true)
{
//lazy init command instance.
if (pluginCmd == null)
{
pluginCmd = new PluginCommand();
}
if (systemCmd == null)
{
systemCmd = new SystemCommand();
}
systemCmd.Dispatch(query,updateView);
pluginCmd.Dispatch(query,updateView);
}
}
}