mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Merge pull request #890 from onesounds/RemovePathHighlight
Remove Subtitle Highlight
This commit is contained in:
commit
c2d992d49e
6 changed files with 10 additions and 24 deletions
|
|
@ -14,10 +14,10 @@
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<Version>2.1.0</Version>
|
<Version>2.1.1</Version>
|
||||||
<PackageVersion>2.1.0</PackageVersion>
|
<PackageVersion>2.1.1</PackageVersion>
|
||||||
<AssemblyVersion>2.1.0</AssemblyVersion>
|
<AssemblyVersion>2.1.1</AssemblyVersion>
|
||||||
<FileVersion>2.1.0</FileVersion>
|
<FileVersion>2.1.1</FileVersion>
|
||||||
<PackageId>Flow.Launcher.Plugin</PackageId>
|
<PackageId>Flow.Launcher.Plugin</PackageId>
|
||||||
<Authors>Flow-Launcher</Authors>
|
<Authors>Flow-Launcher</Authors>
|
||||||
<PackageLicenseExpression>MIT</PackageLicenseExpression>
|
<PackageLicenseExpression>MIT</PackageLicenseExpression>
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Windows.Media;
|
using System.Windows.Media;
|
||||||
|
|
@ -77,9 +77,7 @@ namespace Flow.Launcher.Plugin
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public IList<int> TitleHighlightData { get; set; }
|
public IList<int> TitleHighlightData { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
[Obsolete("Deprecated as of Flow Launcher v1.9.1. Subtitle highlighting is no longer offered")]
|
||||||
/// A list of indexes for the characters to be highlighted in SubTitle
|
|
||||||
/// </summary>
|
|
||||||
public IList<int> SubTitleHighlightData { get; set; }
|
public IList<int> SubTitleHighlightData { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -110,8 +108,7 @@ namespace Flow.Launcher.Plugin
|
||||||
var equality = string.Equals(r?.Title, Title) &&
|
var equality = string.Equals(r?.Title, Title) &&
|
||||||
string.Equals(r?.SubTitle, SubTitle) &&
|
string.Equals(r?.SubTitle, SubTitle) &&
|
||||||
string.Equals(r?.IcoPath, IcoPath) &&
|
string.Equals(r?.IcoPath, IcoPath) &&
|
||||||
TitleHighlightData == r.TitleHighlightData &&
|
TitleHighlightData == r.TitleHighlightData;
|
||||||
SubTitleHighlightData == r.SubTitleHighlightData;
|
|
||||||
|
|
||||||
return equality;
|
return equality;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -133,12 +133,7 @@
|
||||||
Style="{DynamicResource ItemSubTitleStyle}"
|
Style="{DynamicResource ItemSubTitleStyle}"
|
||||||
Text="{Binding Result.SubTitle}"
|
Text="{Binding Result.SubTitle}"
|
||||||
ToolTip="{Binding ShowSubTitleToolTip}">
|
ToolTip="{Binding ShowSubTitleToolTip}">
|
||||||
<vm:ResultsViewModel.FormattedText>
|
|
||||||
<MultiBinding Converter="{StaticResource HighlightTextConverter}">
|
|
||||||
<Binding Path="Result.SubTitle" />
|
|
||||||
<Binding Path="Result.SubTitleHighlightData" />
|
|
||||||
</MultiBinding>
|
|
||||||
</vm:ResultsViewModel.FormattedText>
|
|
||||||
</TextBlock>
|
</TextBlock>
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
|
||||||
|
|
@ -66,14 +66,9 @@ namespace Flow.Launcher.Plugin.Sys
|
||||||
if (score > 0)
|
if (score > 0)
|
||||||
{
|
{
|
||||||
c.Score = score;
|
c.Score = score;
|
||||||
|
|
||||||
if (score == titleMatch.Score)
|
if (score == titleMatch.Score)
|
||||||
{
|
|
||||||
c.TitleHighlightData = titleMatch.MatchData;
|
c.TitleHighlightData = titleMatch.MatchData;
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
c.SubTitleHighlightData = subTitleMatch.MatchData;
|
|
||||||
}
|
|
||||||
|
|
||||||
results.Add(c);
|
results.Add(c);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
"Name": "System Commands",
|
"Name": "System Commands",
|
||||||
"Description": "Provide System related commands. e.g. shutdown,lock, setting etc.",
|
"Description": "Provide System related commands. e.g. shutdown,lock, setting etc.",
|
||||||
"Author": "qianlifeng",
|
"Author": "qianlifeng",
|
||||||
"Version": "1.6.0",
|
"Version": "1.6.1",
|
||||||
"Language": "csharp",
|
"Language": "csharp",
|
||||||
"Website": "https://github.com/Flow-Launcher/Flow.Launcher",
|
"Website": "https://github.com/Flow-Launcher/Flow.Launcher",
|
||||||
"ExecuteFileName": "Flow.Launcher.Plugin.Sys.dll",
|
"ExecuteFileName": "Flow.Launcher.Plugin.Sys.dll",
|
||||||
|
|
|
||||||
|
|
@ -54,7 +54,6 @@ namespace Flow.Launcher.Plugin.WindowsSettings.Helper
|
||||||
if (areaMatch.IsSearchPrecisionScoreMet())
|
if (areaMatch.IsSearchPrecisionScoreMet())
|
||||||
{
|
{
|
||||||
var settingResult = NewSettingResult(areaMatch.Score + midScore, entry.Type);
|
var settingResult = NewSettingResult(areaMatch.Score + midScore, entry.Type);
|
||||||
settingResult.SubTitleHighlightData = areaMatch.MatchData.Select(x => x + 6).ToList();
|
|
||||||
result = settingResult;
|
result = settingResult;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue