From 73a605528a200f8f0966d7d15a7464253e662f67 Mon Sep 17 00:00:00 2001 From: Hongtao Zhang Date: Wed, 29 Dec 2021 13:39:39 -0600 Subject: [PATCH] Update xml docs --- Flow.Launcher.Plugin/GlyphInfo.cs | 5 +++++ Flow.Launcher.Plugin/Result.cs | 31 ++++++++++++++++++++++--------- 2 files changed, 27 insertions(+), 9 deletions(-) diff --git a/Flow.Launcher.Plugin/GlyphInfo.cs b/Flow.Launcher.Plugin/GlyphInfo.cs index d24624d8f..730046e1d 100644 --- a/Flow.Launcher.Plugin/GlyphInfo.cs +++ b/Flow.Launcher.Plugin/GlyphInfo.cs @@ -7,5 +7,10 @@ using System.Windows.Media; namespace Flow.Launcher.Plugin { + /// + /// Text with FontFamily specified + /// + /// Font Family of this Glyph + /// Text/Unicode of the Glyph public record GlyphInfo(string FontFamily, string Glyph); } diff --git a/Flow.Launcher.Plugin/Result.cs b/Flow.Launcher.Plugin/Result.cs index 29f8198ab..4a0715c27 100644 --- a/Flow.Launcher.Plugin/Result.cs +++ b/Flow.Launcher.Plugin/Result.cs @@ -10,11 +10,11 @@ namespace Flow.Launcher.Plugin { private string _pluginDirectory; - + private string _icoPath; /// - /// Provides the title of the result. This is always required. + /// The title of the result. This is always required. /// public string Title { get; set; } @@ -36,6 +36,9 @@ namespace Flow.Launcher.Plugin /// public string AutoCompleteText { get; set; } + /// + /// Image Displayed on the result + /// public string IcoPath { get { return _icoPath; } @@ -60,16 +63,22 @@ namespace Flow.Launcher.Plugin public IconDelegate Icon; /// - /// Information for Glyph Icon + /// Information for Glyph Icon (Prioritized than IcoPath/Icon if user enable Glyph Icons) /// - public GlyphInfo Glyph { get; init; } + public GlyphInfo Glyph { get; init; } /// - /// return true to hide flowlauncher after select result + /// Delegate activated when result is been selected + /// + /// true to hide flowlauncher after select result + /// /// public Func Action { get; set; } + /// + /// Priority of the current result + /// public int Score { get; set; } /// @@ -83,9 +92,9 @@ namespace Flow.Launcher.Plugin public IList SubTitleHighlightData { get; set; } /// - /// Only results that originQuery match with current query will be displayed in the panel + /// Query information associated with the result /// - internal Query OriginQuery { get; set; } + public Query OriginQuery { get; set; } /// /// Plugin directory @@ -103,6 +112,7 @@ namespace Flow.Launcher.Plugin } } + /// public override bool Equals(object obj) { var r = obj as Result; @@ -116,6 +126,7 @@ namespace Flow.Launcher.Plugin return equality; } + /// public override int GetHashCode() { var hashcode = (Title?.GetHashCode() ?? 0) ^ @@ -123,15 +134,17 @@ namespace Flow.Launcher.Plugin return hashcode; } + /// public override string ToString() { return Title + SubTitle; } - public Result() { } - /// /// Additional data associate with this result + /// + /// As external information for ContextMenu + /// /// public object ContextData { get; set; }