Skip to content

Commit

Permalink
Merge pull request #2321 from Flow-Launcher/dev
Browse files Browse the repository at this point in the history
Release 1.16.2
  • Loading branch information
jjw24 authored Sep 25, 2023
2 parents 767ff20 + a8206df commit 12263fe
Show file tree
Hide file tree
Showing 58 changed files with 1,113 additions and 560 deletions.
6 changes: 6 additions & 0 deletions .github/actions/spelling/expect.txt
Original file line number Diff line number Diff line change
Expand Up @@ -103,3 +103,9 @@ Português
Português (Brasil)
Italiano
Slovenský
Droplex
Preinstalled
errormetadatafile
noresult
pluginsmanager
alreadyexists
371 changes: 371 additions & 0 deletions .github/workflows/default_plugins.yml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ internal class PythonEnvironment : AbstractPluginEnvironment

internal override string EnvPath => Path.Combine(DataLocation.PluginEnvironmentsPath, EnvName);

internal override string InstallPath => Path.Combine(EnvPath, "PythonEmbeddable-v3.8.9");
internal override string InstallPath => Path.Combine(EnvPath, "PythonEmbeddable-v3.11.4");

internal override string ExecutablePath => Path.Combine(InstallPath, "pythonw.exe");

Expand All @@ -30,8 +30,9 @@ internal override void InstallEnvironment()
{
FilesFolders.RemoveFolderIfExists(InstallPath);

// Python 3.8.9 is used for Windows 7 compatibility
DroplexPackage.Drop(App.python_3_8_9_embeddable, InstallPath).Wait();
// Python 3.11.4 is no longer Windows 7 compatible. If user is on Win 7 and
// uses Python plugin they need to custom install and use v3.8.9
DroplexPackage.Drop(App.python_3_11_4_embeddable, InstallPath).Wait();

PluginsSettingsFilePath = ExecutablePath;
}
Expand Down
4 changes: 2 additions & 2 deletions Flow.Launcher.Core/Flow.Launcher.Core.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Droplex" Version="1.6.0" />
<PackageReference Include="FSharp.Core" Version="7.0.300" />
<PackageReference Include="Droplex" Version="1.7.0" />
<PackageReference Include="FSharp.Core" Version="7.0.400" />
<PackageReference Include="Microsoft.IO.RecyclableMemoryStream" Version="2.3.2" />
<PackageReference Include="squirrel.windows" Version="1.5.2" NoWarn="NU1701" />
</ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.VisualStudio.Threading" Version="17.6.40" />
<PackageReference Include="Microsoft.VisualStudio.Threading" Version="17.7.30" />
<PackageReference Include="NLog" Version="4.7.10" />
<PackageReference Include="NLog.Schema" Version="4.7.10" />
<PackageReference Include="NLog.Web.AspNetCore" Version="4.13.0" />
Expand Down
2 changes: 1 addition & 1 deletion Flow.Launcher.Plugin/SharedCommands/FilesFolders.cs
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ public static string ReturnPreviousDirectoryIfIncompleteString(string path)
}

/// <summary>
/// Returns if <paramref name="parentPath"/> contains <paramref name="subPath"/>.
/// Returns if <paramref name="parentPath"/> contains <paramref name="subPath"/>. Equal paths are not considered to be contained by default.
/// From https://stackoverflow.com/a/66877016
/// </summary>
/// <param name="parentPath">Parent path</param>
Expand Down
14 changes: 7 additions & 7 deletions Flow.Launcher.Test/FilesFoldersTest.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using Flow.Launcher.Plugin.SharedCommands;
using Flow.Launcher.Plugin.SharedCommands;
using NUnit.Framework;

namespace Flow.Launcher.Test
Expand Down Expand Up @@ -33,21 +33,21 @@ public class FilesFoldersTest
[TestCase(@"c:\foo", @"c:\foo\..\bar\baz", false)]
[TestCase(@"c:\bar", @"c:\foo\..\bar\baz", true)]
[TestCase(@"c:\barr", @"c:\foo\..\bar\baz", false)]
// Equality
[TestCase(@"c:\foo", @"c:\foo", false)]
[TestCase(@"c:\foo\", @"c:\foo", false)]
[TestCase(@"c:\foo", @"c:\foo\", false)]
public void GivenTwoPaths_WhenCheckPathContains_ThenShouldBeExpectedResult(string parentPath, string path, bool expectedResult)
{
Assert.AreEqual(expectedResult, FilesFolders.PathContains(parentPath, path));
}

// Equality
[TestCase(@"c:\foo", @"c:\foo", false)]
[TestCase(@"c:\foo\", @"c:\foo", false)]
[TestCase(@"c:\foo", @"c:\foo\", false)]
[TestCase(@"c:\foo", @"c:\foo", true)]
[TestCase(@"c:\foo\", @"c:\foo", true)]
[TestCase(@"c:\foo", @"c:\foo\", true)]
public void GivenTwoPathsAreTheSame_WhenCheckPathContains_ThenShouldBeTrue(string parentPath, string path, bool expectedResult)
public void GivenTwoPathsAreTheSame_WhenCheckPathContains_ThenShouldBeExpectedResult(string parentPath, string path, bool expectedResult)
{
Assert.AreEqual(expectedResult, FilesFolders.PathContains(parentPath, path, true));
Assert.AreEqual(expectedResult, FilesFolders.PathContains(parentPath, path, allowEqual: expectedResult));
}
}
}
2 changes: 1 addition & 1 deletion Flow.Launcher.Test/Flow.Launcher.Test.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.7.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.7.2" />
</ItemGroup>

</Project>
34 changes: 34 additions & 0 deletions Flow.Launcher/Converters/BoolToVisibilityConverter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,38 @@ public object Convert(object value, System.Type targetType, object parameter, Cu

public object ConvertBack(object value, System.Type targetType, object parameter, CultureInfo culture) => throw new System.InvalidOperationException();
}

public class SplitterConverter : IValueConverter
/* Prevents the dragging part of the preview area from working when preview is turned off. */
{
public object Convert(object value, System.Type targetType, object parameter, CultureInfo culture)
{
if (parameter != null)
{
if (value is true)
{
return 0;
}

else
{
return 5;
}
}
else
{
if (value is true)
{
return 5;
}

else
{
return 0;
}
}
}

public object ConvertBack(object value, System.Type targetType, object parameter, CultureInfo culture) => throw new System.InvalidOperationException();
}
}
6 changes: 6 additions & 0 deletions Flow.Launcher/CustomShortcutSetting.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,12 @@
Text="{DynamicResource customeQueryShortcutTips}"
TextAlignment="Left"
TextWrapping="WrapWithOverflow" />
<TextBlock
Margin="0,20,0,0"
FontSize="14"
Text="{DynamicResource customeQueryShortcutGuide}"
TextAlignment="Left"
TextWrapping="WrapWithOverflow" />
<Image
Width="478"
Margin="0,20,0,0"
Expand Down
7 changes: 3 additions & 4 deletions Flow.Launcher/Helper/HotKeyMapper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,9 @@ internal static void SetHotkey(HotkeyModel hotkey, EventHandler<HotkeyEventArgs>
}
catch (Exception)
{
string errorMsg =
string.Format(InternationalizationManager.Instance.GetTranslation("registerHotkeyFailed"),
hotkeyStr);
MessageBox.Show(errorMsg);
string errorMsg = string.Format(InternationalizationManager.Instance.GetTranslation("registerHotkeyFailed"), hotkeyStr);
string errorMsgTitle = InternationalizationManager.Instance.GetTranslation("MessageBoxTitle");
MessageBox.Show(errorMsg,errorMsgTitle);
}
}

Expand Down
Binary file modified Flow.Launcher/Images/illustration_02.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 6 additions & 1 deletion Flow.Launcher/Languages/ar.xaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<?xml version="1.0"?>
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:system="clr-namespace:System;assembly=mscorlib">
<!-- MainWindow -->
<system:String x:Key="registerHotkeyFailed">Failed to register hotkey: {0}</system:String>
<system:String x:Key="registerHotkeyFailed">Failed to register hotkey &quot;{0}&quot;. The hotkey may be in use by another program. Change to a different hotkey, or exit another program.</system:String>
<system:String x:Key="MessageBoxTitle">Flow Launcher</system:String>
<system:String x:Key="couldnotStartCmd">Could not start {0}</system:String>
<system:String x:Key="invalidFlowLauncherPluginFileFormat">Invalid Flow Launcher plugin file format</system:String>
<system:String x:Key="setAsTopMostInThisQuery">Set as topmost in this query</system:String>
Expand Down Expand Up @@ -287,6 +288,10 @@
<!-- Custom Query Shortcut Dialog -->
<system:String x:Key="customeQueryShortcutTitle">Custom Query Shortcut</system:String>
<system:String x:Key="customeQueryShortcutTips">Enter a shortcut that automatically expands to the specified query.</system:String>
<system:String x:Key="customeQueryShortcutGuide" xml:space="preserve">A shortcut is expanded when it exactly matches the query.

If you add an '@' prefix while inputting a shortcut, it matches any position in the query. Builtin shortcuts match any position in a query.
</system:String>
<system:String x:Key="duplicateShortcut">Shortcut already exists, please enter a new Shortcut or edit the existing one.</system:String>
<system:String x:Key="emptyShortcut">Shortcut and/or its expansion is empty.</system:String>

Expand Down
7 changes: 6 additions & 1 deletion Flow.Launcher/Languages/cs.xaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<?xml version="1.0"?>
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:system="clr-namespace:System;assembly=mscorlib">
<!-- MainWindow -->
<system:String x:Key="registerHotkeyFailed">Nepodařilo se zaregistrovat zkratku: {0}</system:String>
<system:String x:Key="registerHotkeyFailed">Nepodařilo se zaregistrovat hotkey &quot;{0}&quot;. Klávesová zkratka může být používána jiným programem. Změňte na jinou klávesu nebo ukončíte jiný program.</system:String>
<system:String x:Key="MessageBoxTitle">Flow Launcher</system:String>
<system:String x:Key="couldnotStartCmd">Nepodařilo se spustit {0}</system:String>
<system:String x:Key="invalidFlowLauncherPluginFileFormat">Neplatný typ souboru pluginu aplikace Flow Launcher</system:String>
<system:String x:Key="setAsTopMostInThisQuery">Připnout jako první výsledek tohoto hledání</system:String>
Expand Down Expand Up @@ -287,6 +288,10 @@
<!-- Custom Query Shortcut Dialog -->
<system:String x:Key="customeQueryShortcutTitle">Vlastní klávesová zkratka pro zadávání dotazů</system:String>
<system:String x:Key="customeQueryShortcutTips">Zadejte zkratku, která automaticky vloží konkrétní dotaz.</system:String>
<system:String x:Key="customeQueryShortcutGuide" xml:space="preserve">Zkratka se rozbalí, pokud přesně odpovídá dotazu.

Pokud před zkratku při zadávání přidáte znak &quot;@&quot;, bude odpovídat libovolné pozici v dotazu. Vestavěné zkratky odpovídají libovolné pozici v dotazu.
</system:String>
<system:String x:Key="duplicateShortcut">Zkratka již existuje, zadejte novou zkratku nebo upravte stávající.</system:String>
<system:String x:Key="emptyShortcut">Zkratka a/nebo její plné znění je prázdné.</system:String>

Expand Down
7 changes: 6 additions & 1 deletion Flow.Launcher/Languages/da.xaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<?xml version="1.0"?>
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:system="clr-namespace:System;assembly=mscorlib">
<!-- MainWindow -->
<system:String x:Key="registerHotkeyFailed">Kunne ikke registrere genvejstast: {0}</system:String>
<system:String x:Key="registerHotkeyFailed">Failed to register hotkey &quot;{0}&quot;. The hotkey may be in use by another program. Change to a different hotkey, or exit another program.</system:String>
<system:String x:Key="MessageBoxTitle">Flow Launcher</system:String>
<system:String x:Key="couldnotStartCmd">Kunne ikke starte {0}</system:String>
<system:String x:Key="invalidFlowLauncherPluginFileFormat">Ugyldigt Flow Launcher plugin filformat</system:String>
<system:String x:Key="setAsTopMostInThisQuery">Sæt øverst i denne søgning</system:String>
Expand Down Expand Up @@ -287,6 +288,10 @@
<!-- Custom Query Shortcut Dialog -->
<system:String x:Key="customeQueryShortcutTitle">Custom Query Shortcut</system:String>
<system:String x:Key="customeQueryShortcutTips">Enter a shortcut that automatically expands to the specified query.</system:String>
<system:String x:Key="customeQueryShortcutGuide" xml:space="preserve">A shortcut is expanded when it exactly matches the query.

If you add an '@' prefix while inputting a shortcut, it matches any position in the query. Builtin shortcuts match any position in a query.
</system:String>
<system:String x:Key="duplicateShortcut">Shortcut already exists, please enter a new Shortcut or edit the existing one.</system:String>
<system:String x:Key="emptyShortcut">Shortcut and/or its expansion is empty.</system:String>

Expand Down
Loading

0 comments on commit 12263fe

Please sign in to comment.