using System; using System.Collections.Generic; namespace Wox.Plugin { /// /// Public APIs that plugin can use /// public interface IPublicAPI { /// /// Push result to query box /// /// /// /// [Obsolete("This method will be removed in Wox 1.3")] void PushResults(Query query, PluginMetadata plugin, List results); /// /// Change Wox query /// /// query text /// /// force requery By default, Wox will not fire query if your query is same with existing one. /// Set this to true to force Wox requerying /// void ChangeQuery(string query, bool requery = false); /// /// Just change the query text, this won't raise search /// /// [Obsolete] void ChangeQueryText(string query, bool selectAll = false); /// /// Close Wox /// [Obsolete] void CloseApp(); /// /// Restart Wox /// void RestarApp(); /// /// Hide Wox /// [Obsolete] void HideApp(); /// /// Show Wox /// [Obsolete] void ShowApp(); /// /// Save all Wox settings /// void SaveAppAllSettings(); /// /// Reloads any Plugins that have the /// IReloadable implemented. It refeshes /// Plugin's in memory data with new content /// added by user. /// void ReloadAllPluginData(); /// /// Check for new Wox update /// void CheckForNewUpdate(); /// /// Show message box /// /// Message title /// Message subtitle /// Message icon path (relative path to your plugin folder) void ShowMsg(string title, string subTitle = "", string iconPath = "", bool useMainWindowAsOwner = true); /// /// Open setting dialog /// void OpenSettingDialog(); /// /// Show loading animation /// [Obsolete("automatically start")] void StartLoadingBar(); /// /// Stop loading animation /// [Obsolete("automatically stop")] void StopLoadingBar(); /// /// Install Wox plugin /// /// Plugin path (ends with .wox) void InstallPlugin(string path); /// /// Get translation of current language /// You need to implement IPluginI18n if you want to support multiple languages for your plugin /// /// /// string GetTranslation(string key); /// /// Get all loaded plugins /// /// List GetAllPlugins(); /// /// Fired after global keyboard events /// if you want to hook something like Ctrl+R, you should use this event /// event WoxGlobalKeyboardEventHandler GlobalKeyboardEvent; } }