Merge branch 'dev' into windowsSettingtranslationWarning
23
.github/workflows/stale.yml
vendored
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
# For more information, see:
|
||||
# https://github.com/actions/stale
|
||||
name: Mark stale issues and pull requests
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '30 1 * * *'
|
||||
|
||||
jobs:
|
||||
stale:
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
issues: write
|
||||
pull-requests: write
|
||||
steps:
|
||||
- uses: actions/stale@v4
|
||||
with:
|
||||
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.'
|
||||
days-before-stale: 30
|
||||
days-before-close: 5
|
||||
days-before-pr-close: -1
|
||||
exempt-all-milestones: true
|
||||
close-issue-message: 'This issue was closed because it has been stale for 5 days with no activity. If you feel this issue still needs attention please feel free to reopen.'
|
||||
|
|
@ -2,6 +2,8 @@
|
|||
using Flow.Launcher.Infrastructure.Logger;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Net;
|
||||
using System.Net.Http;
|
||||
using System.Text.Json;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
|
|
@ -10,43 +12,43 @@ namespace Flow.Launcher.Core.ExternalPlugins
|
|||
{
|
||||
public static class PluginsManifest
|
||||
{
|
||||
static PluginsManifest()
|
||||
{
|
||||
UpdateTask = UpdateManifestAsync();
|
||||
}
|
||||
|
||||
public static List<UserPlugin> UserPlugins { get; private set; } = new List<UserPlugin>();
|
||||
|
||||
public static Task UpdateTask { get; private set; }
|
||||
private const string manifestFileUrl = "https://cdn.jsdelivr.net/gh/Flow-Launcher/Flow.Launcher.PluginsManifest@plugin_api_v2/plugins.json";
|
||||
|
||||
private static readonly SemaphoreSlim manifestUpdateLock = new(1);
|
||||
|
||||
public static Task UpdateManifestAsync()
|
||||
{
|
||||
if (manifestUpdateLock.CurrentCount == 0)
|
||||
{
|
||||
return UpdateTask;
|
||||
}
|
||||
private static string latestEtag = "";
|
||||
|
||||
return UpdateTask = DownloadManifestAsync();
|
||||
}
|
||||
public static List<UserPlugin> UserPlugins { get; private set; } = new List<UserPlugin>();
|
||||
|
||||
private static async Task DownloadManifestAsync()
|
||||
public static async Task UpdateManifestAsync(CancellationToken token = default)
|
||||
{
|
||||
try
|
||||
{
|
||||
await manifestUpdateLock.WaitAsync().ConfigureAwait(false);
|
||||
await manifestUpdateLock.WaitAsync(token).ConfigureAwait(false);
|
||||
|
||||
await using var jsonStream = await Http.GetStreamAsync("https://raw.githubusercontent.com/Flow-Launcher/Flow.Launcher.PluginsManifest/plugin_api_v2/plugins.json")
|
||||
.ConfigureAwait(false);
|
||||
var request = new HttpRequestMessage(HttpMethod.Get, manifestFileUrl);
|
||||
request.Headers.Add("If-None-Match", latestEtag);
|
||||
|
||||
UserPlugins = await JsonSerializer.DeserializeAsync<List<UserPlugin>>(jsonStream).ConfigureAwait(false);
|
||||
var response = await Http.SendAsync(request, token).ConfigureAwait(false);
|
||||
|
||||
if (response.StatusCode == HttpStatusCode.OK)
|
||||
{
|
||||
Log.Info($"|PluginsManifest.{nameof(UpdateManifestAsync)}|Fetched plugins from manifest repo");
|
||||
|
||||
var json = await response.Content.ReadAsStreamAsync(token).ConfigureAwait(false);
|
||||
|
||||
UserPlugins = await JsonSerializer.DeserializeAsync<List<UserPlugin>>(json, cancellationToken: token).ConfigureAwait(false);
|
||||
|
||||
latestEtag = response.Headers.ETag.Tag;
|
||||
}
|
||||
else if (response.StatusCode != HttpStatusCode.NotModified)
|
||||
{
|
||||
Log.Warn($"|PluginsManifest.{nameof(UpdateManifestAsync)}|Http response for manifest file was {response.StatusCode}");
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
Log.Exception("|PluginManagement.GetManifest|Encountered error trying to download plugins manifest", e);
|
||||
|
||||
UserPlugins = new List<UserPlugin>();
|
||||
Log.Exception($"|PluginsManifest.{nameof(UpdateManifestAsync)}|Http request failed", e);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net5.0-windows</TargetFramework>
|
||||
<TargetFramework>net6.0-windows</TargetFramework>
|
||||
<UseWpf>true</UseWpf>
|
||||
<UseWindowsForms>true</UseWindowsForms>
|
||||
<OutputType>Library</OutputType>
|
||||
|
|
@ -53,7 +53,7 @@
|
|||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Droplex" Version="1.4.0" />
|
||||
<PackageReference Include="Droplex" Version="1.4.1" />
|
||||
<PackageReference Include="FSharp.Core" Version="5.0.2" />
|
||||
<PackageReference Include="Microsoft.IO.RecyclableMemoryStream" Version="2.1.3" />
|
||||
<PackageReference Include="squirrel.windows" Version="1.5.2" />
|
||||
|
|
|
|||
|
|
@ -15,20 +15,6 @@ namespace Flow.Launcher.Core.Plugin
|
|||
|
||||
private readonly AssemblyName assemblyName;
|
||||
|
||||
private static readonly ConcurrentDictionary<string, byte> loadedAssembly;
|
||||
|
||||
static PluginAssemblyLoader()
|
||||
{
|
||||
var currentAssemblies = AppDomain.CurrentDomain.GetAssemblies();
|
||||
loadedAssembly = new ConcurrentDictionary<string, byte>(
|
||||
currentAssemblies.Select(x => new KeyValuePair<string, byte>(x.FullName, default)));
|
||||
|
||||
AppDomain.CurrentDomain.AssemblyLoad += (sender, args) =>
|
||||
{
|
||||
loadedAssembly[args.LoadedAssembly.FullName] = default;
|
||||
};
|
||||
}
|
||||
|
||||
internal PluginAssemblyLoader(string assemblyFilePath)
|
||||
{
|
||||
dependencyResolver = new AssemblyDependencyResolver(assemblyFilePath);
|
||||
|
|
@ -47,10 +33,9 @@ namespace Flow.Launcher.Core.Plugin
|
|||
// When resolving dependencies, ignore assembly depenedencies that already exits with Flow.Launcher
|
||||
// Otherwise duplicate assembly will be loaded and some weird behavior will occur, such as WinRT.Runtime.dll
|
||||
// will fail due to loading multiple versions in process, each with their own static instance of registration state
|
||||
if (assemblyPath == null || ExistsInReferencedPackage(assemblyName))
|
||||
return null;
|
||||
var existAssembly = Default.Assemblies.FirstOrDefault(x => x.FullName == assemblyName.FullName);
|
||||
|
||||
return LoadFromAssemblyPath(assemblyPath);
|
||||
return existAssembly ?? (assemblyPath == null ? null : LoadFromAssemblyPath(assemblyPath));
|
||||
}
|
||||
|
||||
internal Type FromAssemblyGetTypeOfInterface(Assembly assembly, Type type)
|
||||
|
|
@ -58,10 +43,5 @@ namespace Flow.Launcher.Core.Plugin
|
|||
var allTypes = assembly.ExportedTypes;
|
||||
return allTypes.First(o => o.IsClass && !o.IsAbstract && o.GetInterfaces().Any(t => t == type));
|
||||
}
|
||||
|
||||
internal bool ExistsInReferencedPackage(AssemblyName assemblyName)
|
||||
{
|
||||
return loadedAssembly.ContainsKey(assemblyName.FullName);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -19,6 +19,8 @@ namespace Flow.Launcher.Core.Resource
|
|||
public static Language Serbian = new Language("sr", "Srpski");
|
||||
public static Language Portuguese_Portugal = new Language("pt-pt", "Português");
|
||||
public static Language Portuguese_Brazil = new Language("pt-br", "Português (Brasil)");
|
||||
public static Language Spanish = new Language("es", "Spanish");
|
||||
public static Language Spanish_LatinAmerica = new Language("es-419", "Spanish (Latin America)");
|
||||
public static Language Italian = new Language("it", "Italiano");
|
||||
public static Language Norwegian_Bokmal = new Language("nb-NO", "Norsk Bokmål");
|
||||
public static Language Slovak = new Language("sk", "Slovenský");
|
||||
|
|
@ -43,6 +45,8 @@ namespace Flow.Launcher.Core.Resource
|
|||
Serbian,
|
||||
Portuguese_Portugal,
|
||||
Portuguese_Brazil,
|
||||
Spanish,
|
||||
Spanish_LatinAmerica,
|
||||
Italian,
|
||||
Norwegian_Bokmal,
|
||||
Slovak,
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net5.0-windows</TargetFramework>
|
||||
<TargetFramework>net6.0-windows</TargetFramework>
|
||||
<ProjectGuid>{4FD29318-A8AB-4D8F-AA47-60BC241B8DA3}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<UseWpf>true</UseWpf>
|
||||
|
|
|
|||
|
|
@ -153,5 +153,13 @@ namespace Flow.Launcher.Infrastructure.Http
|
|||
var response = await client.GetAsync(url, HttpCompletionOption.ResponseHeadersRead, token);
|
||||
return await response.Content.ReadAsStreamAsync();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Asynchrously send an HTTP request.
|
||||
/// </summary>
|
||||
public static async Task<HttpResponseMessage> SendAsync(HttpRequestMessage request, CancellationToken token = default)
|
||||
{
|
||||
return await client.SendAsync(request, HttpCompletionOption.ResponseHeadersRead, token);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ namespace Flow.Launcher.Infrastructure.Image
|
|||
// To delete the images from the data dictionary based on the resizing of the Usage Dictionary
|
||||
// Double Check to avoid concurrent remove
|
||||
if (Data.Count > permissibleFactor * MaxCached)
|
||||
foreach (var key in Data.OrderBy(x => x.Value.usage).Take(Data.Count - MaxCached).Select(x => x.Key).ToArray())
|
||||
foreach (var key in Data.OrderBy(x => x.Value.usage).Take(Data.Count - MaxCached).Select(x => x.Key))
|
||||
Data.TryRemove(key, out _);
|
||||
semaphore.Release();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net5.0-windows</TargetFramework>
|
||||
<TargetFramework>net6.0-windows</TargetFramework>
|
||||
<ProjectGuid>{8451ECDD-2EA4-4966-BB0A-7BBC40138E80}</ProjectGuid>
|
||||
<UseWPF>true</UseWPF>
|
||||
<OutputType>Library</OutputType>
|
||||
|
|
@ -14,10 +14,10 @@
|
|||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup>
|
||||
<Version>2.1.1</Version>
|
||||
<PackageVersion>2.1.1</PackageVersion>
|
||||
<AssemblyVersion>2.1.1</AssemblyVersion>
|
||||
<FileVersion>2.1.1</FileVersion>
|
||||
<Version>3.0.0</Version>
|
||||
<PackageVersion>3.0.0</PackageVersion>
|
||||
<AssemblyVersion>3.0.0</AssemblyVersion>
|
||||
<FileVersion>3.0.0</FileVersion>
|
||||
<PackageId>Flow.Launcher.Plugin</PackageId>
|
||||
<Authors>Flow-Launcher</Authors>
|
||||
<PackageLicenseExpression>MIT</PackageLicenseExpression>
|
||||
|
|
|
|||
|
|
@ -228,8 +228,27 @@ namespace Flow.Launcher.Plugin
|
|||
public void OpenDirectory(string DirectoryPath, string FileName = null);
|
||||
|
||||
/// <summary>
|
||||
/// Opens the url. The browser and mode used is based on what's configured in Flow's default browser settings.
|
||||
/// Opens the URL with the given Uri object.
|
||||
/// The browser and mode used is based on what's configured in Flow's default browser settings.
|
||||
/// </summary>
|
||||
public void OpenUrl(Uri url, bool? inPrivate = null);
|
||||
|
||||
/// <summary>
|
||||
/// Opens the URL with the given string.
|
||||
/// The browser and mode used is based on what's configured in Flow's default browser settings.
|
||||
/// Non-C# plugins should use this method.
|
||||
/// </summary>
|
||||
public void OpenUrl(string url, bool? inPrivate = null);
|
||||
|
||||
/// <summary>
|
||||
/// Opens the application URI with the given Uri object, e.g. obsidian://search-query-example
|
||||
/// </summary>
|
||||
public void OpenAppUri(Uri appUri);
|
||||
|
||||
/// <summary>
|
||||
/// Opens the application URI with the given string, e.g. obsidian://search-query-example
|
||||
/// Non-C# plugins should use this method
|
||||
/// </summary>
|
||||
public void OpenAppUri(string appUri);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,6 +29,13 @@ namespace Flow.Launcher.Plugin
|
|||
/// </summary>
|
||||
public string ActionKeywordAssigned { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// This holds the text which can be provided by plugin to be copied to the
|
||||
/// user's clipboard when Ctrl + C is pressed on a result. If the text is a file/directory path
|
||||
/// flow will copy the actual file/folder instead of just the path text.
|
||||
/// </summary>
|
||||
public string CopyText { get; set; } = string.Empty;
|
||||
|
||||
/// <summary>
|
||||
/// This holds the text which can be provided by plugin to help Flow autocomplete text
|
||||
/// for user on the plugin result. If autocomplete action for example is tab, pressing tab will have
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ namespace Flow.Launcher.Plugin.SharedCommands
|
|||
|
||||
try
|
||||
{
|
||||
Process.Start(psi);
|
||||
Process.Start(psi)?.Dispose();
|
||||
}
|
||||
catch (System.ComponentModel.Win32Exception)
|
||||
{
|
||||
|
|
@ -100,7 +100,7 @@ namespace Flow.Launcher.Plugin.SharedCommands
|
|||
psi.FileName = url;
|
||||
}
|
||||
|
||||
Process.Start(psi);
|
||||
Process.Start(psi)?.Dispose();
|
||||
}
|
||||
// This error may be thrown if browser path is incorrect
|
||||
catch (System.ComponentModel.Win32Exception)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net5.0-windows10.0.19041.0</TargetFramework>
|
||||
<TargetFramework>net6.0-windows10.0.19041.0</TargetFramework>
|
||||
<ProjectGuid>{FF742965-9A80-41A5-B042-D6C7D3A21708}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ namespace Flow.Launcher.Test.Plugins
|
|||
[TestCaseSource(typeof(JsonRPCPluginTest), nameof(ResponseModelsSource))]
|
||||
public async Task GivenModel_WhenSerializeWithDifferentNamingPolicy_ThenExpectSameResult_Async(JsonRPCQueryResponseModel reference)
|
||||
{
|
||||
var camelText = JsonSerializer.Serialize(reference, new() { PropertyNamingPolicy = JsonNamingPolicy.CamelCase });
|
||||
var camelText = JsonSerializer.Serialize(reference, new JsonSerializerOptions() { PropertyNamingPolicy = JsonNamingPolicy.CamelCase });
|
||||
|
||||
var pascalText = JsonSerializer.Serialize(reference);
|
||||
|
||||
|
|
|
|||
|
|
@ -153,7 +153,6 @@ namespace Flow.Launcher
|
|||
DispatcherUnhandledException += ErrorReporting.DispatcherUnhandledException;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// let exception throw as normal is better for Debug
|
||||
/// </summary>
|
||||
|
|
@ -179,4 +178,4 @@ namespace Flow.Launcher
|
|||
Current.MainWindow.Show();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<TargetFramework>net5.0-windows10.0.19041.0</TargetFramework>
|
||||
<TargetFramework>net6.0-windows10.0.19041.0</TargetFramework>
|
||||
<UseWPF>true</UseWPF>
|
||||
<UseWindowsForms>true</UseWindowsForms>
|
||||
<StartupObject>Flow.Launcher.App</StartupObject>
|
||||
|
|
@ -88,6 +88,7 @@
|
|||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="InputSimulator" Version="1.0.4" />
|
||||
<PackageReference Include="Microsoft.Toolkit.Uwp.Notifications" Version="7.1.2" />
|
||||
<PackageReference Include="ModernWpfUI" Version="0.9.4" />
|
||||
<PackageReference Include="NHotkey.Wpf" Version="2.1.0" />
|
||||
<PackageReference Include="NuGet.CommandLine" Version="5.4.0">
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ namespace Flow.Launcher.Helper
|
|||
|
||||
internal static void OnToggleHotkey(object sender, HotkeyEventArgs args)
|
||||
{
|
||||
if (!mainViewModel.GameModeStatus)
|
||||
if (!mainViewModel.ShouldIgnoreHotkeys() && !mainViewModel.GameModeStatus)
|
||||
mainViewModel.ToggleFlowLauncher();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
Before Width: | Height: | Size: 873 B After Width: | Height: | Size: 2.7 KiB |
|
Before Width: | Height: | Size: 774 B After Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 796 B After Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 44 KiB After Width: | Height: | Size: 2.8 KiB |
|
Before Width: | Height: | Size: 597 B After Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 1 KiB After Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 530 B After Width: | Height: | Size: 3.1 KiB |
|
Before Width: | Height: | Size: 752 B After Width: | Height: | Size: 2.5 KiB |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 4.7 KiB |
|
Before Width: | Height: | Size: 501 B After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 506 B After Width: | Height: | Size: 2.4 KiB |
|
Before Width: | Height: | Size: 290 B After Width: | Height: | Size: 339 B |
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 3.1 KiB |
|
Before Width: | Height: | Size: 468 B After Width: | Height: | Size: 2 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 634 B After Width: | Height: | Size: 687 B |
|
Before Width: | Height: | Size: 759 B After Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 674 B After Width: | Height: | Size: 2.2 KiB |
|
Before Width: | Height: | Size: 1 KiB After Width: | Height: | Size: 1.4 KiB |
|
Before Width: | Height: | Size: 792 B After Width: | Height: | Size: 752 B |
|
Before Width: | Height: | Size: 269 B After Width: | Height: | Size: 2.7 KiB |
|
Before Width: | Height: | Size: 436 B After Width: | Height: | Size: 2.6 KiB |
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 3.1 KiB |
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 3.1 KiB |
|
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 5.5 KiB |
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 4.4 KiB |
|
Before Width: | Height: | Size: 760 B After Width: | Height: | Size: 2.3 KiB |
|
Before Width: | Height: | Size: 470 B After Width: | Height: | Size: 2.8 KiB |
|
Before Width: | Height: | Size: 794 B After Width: | Height: | Size: 1.4 KiB |
|
|
@ -126,8 +126,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Opdater</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Annuler</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Denne opdatering vil genstarte Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Følgende filer bliver opdateret</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Følgende filer bliver opdateret</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Opdatereringsfiler</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Opdateringsbeskrivelse</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Opdateringsbeskrivelse</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
|
|||
|
|
@ -126,8 +126,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Aktualisieren</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Abbrechen</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Diese Aktualisierung wird Flow Launcher neu starten</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Folgende Dateien werden aktualisiert</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Folgende Dateien werden aktualisiert</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Aktualisiere Dateien</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Aktualisierungbeschreibung</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Aktualisierungbeschreibung</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
@ -18,6 +18,9 @@
|
|||
<system:String x:Key="copy">Copy</system:String>
|
||||
<system:String x:Key="cut">Cut</system:String>
|
||||
<system:String x:Key="paste">Paste</system:String>
|
||||
<system:String x:Key="fileTitle">File</system:String>
|
||||
<system:String x:Key="folderTitle">Folder</system:String>
|
||||
<system:String x:Key="textTitle">Text</system:String>
|
||||
<system:String x:Key="GameMode">Game Mode</system:String>
|
||||
<system:String x:Key="GameModeToolTip">Suspend the use of Hotkeys.</system:String>
|
||||
|
||||
|
|
@ -55,7 +58,7 @@
|
|||
<system:String x:Key="shadowEffectNotAllowed">Shadow effect is not allowed while current theme has blur effect enabled</system:String>
|
||||
|
||||
<!-- Setting Plugin -->
|
||||
<system:String x:Key="plugin">Plugins</system:String>
|
||||
<system:String x:Key="plugin">Plugin</system:String>
|
||||
<system:String x:Key="browserMorePlugins">Find more plugins</system:String>
|
||||
<system:String x:Key="enable">On</system:String>
|
||||
<system:String x:Key="disable">Off</system:String>
|
||||
|
|
@ -244,9 +247,9 @@
|
|||
<system:String x:Key="update_flowlauncher_fail">Update Failed</system:String>
|
||||
<system:String x:Key="update_flowlauncher_check_connection">Check your connection and try updating proxy settings to github-cloud.s3.amazonaws.com.</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">This upgrade will restart Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Following files will be updated</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Following files will be updated</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Update files</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Update description</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Update description</system:String>
|
||||
|
||||
<!-- Welcome Window -->
|
||||
<system:String x:Key="Skip">Skip</system:String>
|
||||
|
|
@ -281,7 +284,7 @@
|
|||
<system:String x:Key="RecommendShell">> ping 8.8.8.8</system:String>
|
||||
<system:String x:Key="RecommendShellDesc">Shell Command</system:String>
|
||||
<system:String x:Key="RecommendBluetooth">Bluetooth</system:String>
|
||||
<system:String x:Key="RecommendBluetoothDesc">Bluetooth in Windows Setting</system:String>
|
||||
<system:String x:Key="RecommendBluetoothDesc">Bluetooth in Windows Settings</system:String>
|
||||
<system:String x:Key="RecommendAcronyms">sn</system:String>
|
||||
<system:String x:Key="RecommendAcronymsDesc">Sticky Notes</system:String>
|
||||
|
||||
|
|
|
|||
|
|
@ -132,8 +132,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Mettre à jour</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Annuler</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Flow Launcher doit redémarrer pour installer cette mise à jour</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Les fichiers suivants seront mis à jour</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Les fichiers suivants seront mis à jour</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Fichiers mis à jour</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Description de la mise à jour</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Description de la mise à jour</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
|
|||
|
|
@ -135,8 +135,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Aggiorna</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Annulla</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Questo aggiornamento riavvierà Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">I seguenti file saranno aggiornati</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">I seguenti file saranno aggiornati</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">File aggiornati</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Descrizione aggiornamento</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Descrizione aggiornamento</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
@ -138,8 +138,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">アップデート</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">キャンセル</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">このアップデートでは、Flow Launcherの再起動が必要です</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">次のファイルがアップデートされます</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">次のファイルがアップデートされます</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">更新ファイル一覧</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">アップデートの詳細</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">アップデートの詳細</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
@ -241,9 +241,9 @@
|
|||
<system:String x:Key="update_flowlauncher_fail">업데이트 실패</system:String>
|
||||
<system:String x:Key="update_flowlauncher_check_connection">Check your connection and try updating proxy settings to github-cloud.s3.amazonaws.com.</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">업데이트를 위해 Flow Launcher를 재시작합니다.</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">아래 파일들이 업데이트됩니다.</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">아래 파일들이 업데이트됩니다.</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">업데이트 파일</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">업데이트 설명</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">업데이트 설명</system:String>
|
||||
|
||||
|
||||
<!-- Welcome Window -->
|
||||
|
|
|
|||
|
|
@ -135,8 +135,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Oppdater</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Avbryt</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Denne opgraderingen vil starte Flow Launcher på nytt</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Følgende filer vil bli oppdatert</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Følgende filer vil bli oppdatert</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Oppdateringsfiler</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Oppdateringsbeskrivelse</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Oppdateringsbeskrivelse</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
|
|||
|
|
@ -126,8 +126,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Update</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Annuleer</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Deze upgrade zal Flow Launcher opnieuw opstarten</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Volgende bestanden zullen worden geüpdatet</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Volgende bestanden zullen worden geüpdatet</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Update bestanden</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Update beschrijving</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Update beschrijving</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
|
|||
|
|
@ -126,8 +126,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Aktualizuj</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Anuluj</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Aby dokończyć proces aktualizacji Flow Launcher musi zostać zresetowany</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Następujące pliki zostaną zaktualizowane</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Następujące pliki zostaną zaktualizowane</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Aktualizuj pliki</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Opis aktualizacji</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Opis aktualizacji</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
@ -135,8 +135,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Atualizar</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Cancelar</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Essa atualização reiniciará o Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Os seguintes arquivos serão atualizados</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Os seguintes arquivos serão atualizados</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Atualizar arquivos</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Atualizar descrição</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Atualizar descrição</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
@ -244,9 +244,9 @@
|
|||
<system:String x:Key="update_flowlauncher_fail">Falha ao atualizar</system:String>
|
||||
<system:String x:Key="update_flowlauncher_check_connection">Verifique a sua ligação e as definições do proxy estabelecidas para github-cloud.s3.amazonaws.com</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Esta atualização irá reiniciar o Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Os seguintes ficheiros serão atualizados</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Os seguintes ficheiros serão atualizados</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Atualizar ficheiros</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Atualizar descrição</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Atualizar descrição</system:String>
|
||||
|
||||
<!-- Welcome Window -->
|
||||
<system:String x:Key="Skip">Ignorar</system:String>
|
||||
|
|
|
|||
|
|
@ -126,8 +126,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Обновить</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Отмена</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Это обновление перезапустит Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Следующие файлы будут обновлены</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Следующие файлы будут обновлены</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Обновить файлы</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Описание обновления</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Описание обновления</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
@ -242,9 +242,9 @@
|
|||
<system:String x:Key="update_flowlauncher_fail">Aktualizácia zlyhala</system:String>
|
||||
<system:String x:Key="update_flowlauncher_check_connection">Skontrolujte pripojenie a skúste aktualizovať nastavenia servera proxy k github-cloud.s3.amazonaws.com.</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Tento upgrade reštartuje Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Nasledujúce súbory budú aktualizované</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Nasledujúce súbory budú aktualizované</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Aktualizovať súbory</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Aktualizovať popis</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Aktualizovať popis</system:String>
|
||||
|
||||
<!-- Welcome Window -->
|
||||
<system:String x:Key="Skip">Preskočiť</system:String>
|
||||
|
|
|
|||
|
|
@ -135,8 +135,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Ažuriraj</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Otkaži</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Ova nadogradnja će ponovo pokrenuti Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Sledeće datoteke će biti ažurirane</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Sledeće datoteke će biti ažurirane</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Ažuriraj datoteke</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Opis ažuriranja</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Opis ažuriranja</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
@ -139,8 +139,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Güncelle</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">İptal</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Bu güncelleme Flow Launcher'u yeniden başlatacaktır</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Aşağıdaki dosyalar güncelleştirilecektir</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Aşağıdaki dosyalar güncelleştirilecektir</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Güncellenecek dosyalar</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Güncelleme açıklaması</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Güncelleme açıklaması</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
@ -126,8 +126,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">Оновити</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">Скасувати</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">Це оновлення перезавантажить Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">Ці файли будуть оновлені</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">Ці файли будуть оновлені</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">Оновити файли</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">Опис оновлення</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">Опис оновлення</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
@ -226,9 +226,9 @@
|
|||
<system:String x:Key="update_flowlauncher_fail">更新失败</system:String>
|
||||
<system:String x:Key="update_flowlauncher_check_connection">检查网络是否可以连接至github-cloud.s3.amazonaws.com.</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">此次更新需要重启Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">下列文件会被更新</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">下列文件会被更新</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">更新文件</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">更新日志</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">更新日志</system:String>
|
||||
|
||||
<!-- Welcome Window -->
|
||||
<system:String x:Key="Skip">跳过</system:String>
|
||||
|
|
|
|||
|
|
@ -126,8 +126,8 @@
|
|||
<system:String x:Key="update_flowlauncher_update">更新</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_cancel">取消</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_restart_flowlauncher_tip">此更新需要重新啟動 Flow Launcher</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_files">下列檔案會被更新</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_files">下列檔案會被更新</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_files">更新檔案</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_upadte_description">更新日誌</system:String>
|
||||
<system:String x:Key="update_flowlauncher_update_update_description">更新日誌</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
|
|||
|
|
@ -175,6 +175,9 @@
|
|||
Style="{DynamicResource QueryBoxStyle}"
|
||||
Text="{Binding QueryText, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
Visibility="Visible">
|
||||
<TextBox.CommandBindings>
|
||||
<CommandBinding Command="ApplicationCommands.Copy" Executed="OnCopy" />
|
||||
</TextBox.CommandBindings>
|
||||
<TextBox.ContextMenu>
|
||||
<ContextMenu>
|
||||
<MenuItem Command="ApplicationCommands.Cut" Header="{DynamicResource cut}" />
|
||||
|
|
|
|||
|
|
@ -18,6 +18,8 @@ using KeyEventArgs = System.Windows.Input.KeyEventArgs;
|
|||
using NotifyIcon = System.Windows.Forms.NotifyIcon;
|
||||
using Flow.Launcher.Infrastructure;
|
||||
using System.Windows.Media;
|
||||
using Flow.Launcher.Infrastructure.Hotkey;
|
||||
using Flow.Launcher.Plugin.SharedCommands;
|
||||
|
||||
namespace Flow.Launcher
|
||||
{
|
||||
|
|
@ -50,7 +52,18 @@ namespace Flow.Launcher
|
|||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
private void OnCopy(object sender, ExecutedRoutedEventArgs e)
|
||||
{
|
||||
if (QueryTextBox.SelectionLength == 0)
|
||||
{
|
||||
_viewModel.ResultCopy(string.Empty);
|
||||
|
||||
}
|
||||
else if (!string.IsNullOrEmpty(QueryTextBox.Text))
|
||||
{
|
||||
_viewModel.ResultCopy(QueryTextBox.SelectedText);
|
||||
}
|
||||
}
|
||||
private async void OnClosing(object sender, CancelEventArgs e)
|
||||
{
|
||||
_settings.WindowTop = Top;
|
||||
|
|
@ -59,6 +72,7 @@ namespace Flow.Launcher
|
|||
_viewModel.Save();
|
||||
e.Cancel = true;
|
||||
await PluginManager.DisposePluginsAsync();
|
||||
Notification.Uninstall();
|
||||
Environment.Exit(0);
|
||||
}
|
||||
|
||||
|
|
@ -498,6 +512,24 @@ namespace Flow.Launcher
|
|||
e.Handled = true;
|
||||
}
|
||||
break;
|
||||
case Key.Back:
|
||||
var specialKeyState = GlobalHotkey.CheckModifiers();
|
||||
if (specialKeyState.CtrlPressed)
|
||||
{
|
||||
if (_viewModel.SelectedIsFromQueryResults()
|
||||
&& QueryTextBox.CaretIndex == QueryTextBox.Text.Length)
|
||||
{
|
||||
var queryWithoutActionKeyword =
|
||||
QueryBuilder.Build(QueryTextBox.Text.Trim(), PluginManager.NonGlobalPlugins).Search;
|
||||
|
||||
if (FilesFolders.IsLocationPathString(queryWithoutActionKeyword))
|
||||
{
|
||||
_viewModel.BackspaceCommand.Execute(null);
|
||||
e.Handled = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
using Flow.Launcher.Infrastructure;
|
||||
using Microsoft.Toolkit.Uwp.Notifications;
|
||||
using System;
|
||||
using System.IO;
|
||||
using Windows.Data.Xml.Dom;
|
||||
|
|
@ -8,10 +9,17 @@ namespace Flow.Launcher
|
|||
{
|
||||
internal static class Notification
|
||||
{
|
||||
internal static bool legacy = Environment.OSVersion.Version.Build < 19041;
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Interoperability", "CA1416:Validate platform compatibility", Justification = "<Pending>")]
|
||||
internal static void Uninstall()
|
||||
{
|
||||
if (!legacy)
|
||||
ToastNotificationManagerCompat.Uninstall();
|
||||
}
|
||||
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Interoperability", "CA1416:Validate platform compatibility", Justification = "<Pending>")]
|
||||
public static void Show(string title, string subTitle, string iconPath)
|
||||
{
|
||||
var legacy = Environment.OSVersion.Version.Build < 19041;
|
||||
// Handle notification for win7/8/early win10
|
||||
if (legacy)
|
||||
{
|
||||
|
|
@ -24,13 +32,11 @@ namespace Flow.Launcher
|
|||
? Path.Combine(Constant.ProgramDirectory, "Images\\app.png")
|
||||
: iconPath;
|
||||
|
||||
var xml = $"<?xml version=\"1.0\"?><toast><visual><binding template=\"ToastImageAndText04\"><image id=\"1\" src=\"{Icon}\" alt=\"meziantou\"/><text id=\"1\">{title}</text>" +
|
||||
$"<text id=\"2\">{subTitle}</text></binding></visual></toast>";
|
||||
var toastXml = new XmlDocument();
|
||||
toastXml.LoadXml(xml);
|
||||
var toast = new ToastNotification(toastXml);
|
||||
ToastNotificationManager.CreateToastNotifier("Flow Launcher").Show(toast);
|
||||
|
||||
new ToastContentBuilder()
|
||||
.AddText(title, hintMaxLines: 1)
|
||||
.AddText(subTitle)
|
||||
.AddAppLogoOverride(new Uri(Icon))
|
||||
.Show();
|
||||
}
|
||||
|
||||
private static void LegacyShow(string title, string subTitle, string iconPath)
|
||||
|
|
|
|||
|
|
@ -1,13 +1,13 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
https://go.microsoft.com/fwlink/?LinkID=208121.
|
||||
https://go.microsoft.com/fwlink/?LinkID=208121.
|
||||
-->
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<PublishProtocol>FileSystem</PublishProtocol>
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Any CPU</Platform>
|
||||
<TargetFramework>net5.0-windows10.0.19041.0</TargetFramework>
|
||||
<TargetFramework>net6.0-windows10.0.19041.0</TargetFramework>
|
||||
<PublishDir>..\Output\Release\</PublishDir>
|
||||
<RuntimeIdentifier>win-x64</RuntimeIdentifier>
|
||||
<SelfContained>true</SelfContained>
|
||||
|
|
@ -15,4 +15,4 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
|||
<PublishReadyToRun>False</PublishReadyToRun>
|
||||
<PublishTrimmed>False</PublishTrimmed>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
</Project>
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
https://go.microsoft.com/fwlink/?LinkID=208121.
|
||||
-->
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
</Project>
|
||||
|
|
@ -209,21 +209,53 @@ namespace Flow.Launcher
|
|||
explorer.Start();
|
||||
}
|
||||
|
||||
public void OpenUrl(string url, bool? inPrivate = null)
|
||||
private void OpenUri(Uri uri, bool? inPrivate = null)
|
||||
{
|
||||
var browserInfo = _settingsVM.Settings.CustomBrowser;
|
||||
|
||||
var path = browserInfo.Path == "*" ? "" : browserInfo.Path;
|
||||
|
||||
if (browserInfo.OpenInTab)
|
||||
if (uri.Scheme == Uri.UriSchemeHttp || uri.Scheme == Uri.UriSchemeHttps)
|
||||
{
|
||||
url.OpenInBrowserTab(path, inPrivate ?? browserInfo.EnablePrivate, browserInfo.PrivateArg);
|
||||
var browserInfo = _settingsVM.Settings.CustomBrowser;
|
||||
|
||||
var path = browserInfo.Path == "*" ? "" : browserInfo.Path;
|
||||
|
||||
if (browserInfo.OpenInTab)
|
||||
{
|
||||
uri.AbsoluteUri.OpenInBrowserTab(path, inPrivate ?? browserInfo.EnablePrivate, browserInfo.PrivateArg);
|
||||
}
|
||||
else
|
||||
{
|
||||
uri.AbsoluteUri.OpenInBrowserWindow(path, inPrivate ?? browserInfo.EnablePrivate, browserInfo.PrivateArg);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
url.OpenInBrowserWindow(path, inPrivate ?? browserInfo.EnablePrivate, browserInfo.PrivateArg);
|
||||
}
|
||||
Process.Start(new ProcessStartInfo()
|
||||
{
|
||||
FileName = uri.AbsoluteUri,
|
||||
UseShellExecute = true
|
||||
})?.Dispose();
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
public void OpenUrl(string url, bool? inPrivate = null)
|
||||
{
|
||||
OpenUri(new Uri(url), inPrivate);
|
||||
}
|
||||
|
||||
public void OpenUrl(Uri url, bool? inPrivate = null)
|
||||
{
|
||||
OpenUri(url, inPrivate);
|
||||
}
|
||||
|
||||
public void OpenAppUri(string appUri)
|
||||
{
|
||||
OpenUri(new Uri(appUri));
|
||||
}
|
||||
|
||||
public void OpenAppUri(Uri appUri)
|
||||
{
|
||||
OpenUri(appUri);
|
||||
}
|
||||
|
||||
public event FlowLauncherGlobalKeyboardEventHandler GlobalKeyboardEvent;
|
||||
|
|
@ -254,4 +286,4 @@ namespace Flow.Launcher
|
|||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -2514,6 +2514,18 @@
|
|||
Margin="14,14,0,0"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Bottom"
|
||||
FontSize="12"
|
||||
Foreground="{DynamicResource Color15B}"
|
||||
TextWrapping="WrapWithOverflow">
|
||||
<Hyperlink NavigateUri="https://icons8.com" RequestNavigate="OnRequestNavigate">
|
||||
<Run Text="Icons by icons8.com" />
|
||||
</Hyperlink>
|
||||
</TextBlock>
|
||||
|
||||
<TextBlock
|
||||
Margin="14,4,0,0"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Bottom"
|
||||
DockPanel.Dock="Bottom"
|
||||
FontSize="12"
|
||||
Foreground="{DynamicResource Color15B}"
|
||||
|
|
|
|||
|
|
@ -1,15 +1,16 @@
|
|||
<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"
|
||||
xmlns:userSettings="clr-namespace:Flow.Launcher.Infrastructure.UserSettings;assembly=Flow.Launcher.Infrastructure">
|
||||
<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"
|
||||
xmlns:userSettings="clr-namespace:Flow.Launcher.Infrastructure.UserSettings;assembly=Flow.Launcher.Infrastructure">
|
||||
|
||||
<!-- Further font customisations are dynamically loaded in Theme.cs -->
|
||||
<!-- Further font customisations are dynamically loaded in Theme.cs -->
|
||||
<Style x:Key="BaseQueryBoxStyle" TargetType="{x:Type TextBox}">
|
||||
<Setter Property="BorderThickness" Value="0" />
|
||||
<Setter Property="FontSize" Value="28" />
|
||||
<Setter Property="FontWeight" Value="Regular" />
|
||||
<Setter Property="Margin" Value="16 7 0 7" />
|
||||
<Setter Property="Padding" Value="0 4 68 0" />
|
||||
<Setter Property="Margin" Value="16,7,0,7" />
|
||||
<Setter Property="Padding" Value="0,4,68,0" />
|
||||
<Setter Property="Background" Value="#2F2F2F" />
|
||||
<Setter Property="Height" Value="48" />
|
||||
<Setter Property="Foreground" Value="#E3E0E3" />
|
||||
|
|
@ -20,13 +21,22 @@
|
|||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type TextBox}">
|
||||
<Border x:Name="border" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" SnapsToDevicePixels="True">
|
||||
<ScrollViewer x:Name="PART_ContentHost" Focusable="false" HorizontalScrollBarVisibility="Hidden" VerticalScrollBarVisibility="Hidden"
|
||||
Background="{TemplateBinding Background}">
|
||||
<Border
|
||||
x:Name="border"
|
||||
Background="{TemplateBinding Background}"
|
||||
BorderBrush="{TemplateBinding BorderBrush}"
|
||||
BorderThickness="{TemplateBinding BorderThickness}"
|
||||
SnapsToDevicePixels="True">
|
||||
<ScrollViewer
|
||||
x:Name="PART_ContentHost"
|
||||
Background="{TemplateBinding Background}"
|
||||
Focusable="false"
|
||||
HorizontalScrollBarVisibility="Hidden"
|
||||
VerticalScrollBarVisibility="Hidden">
|
||||
<ScrollViewer.ContentTemplate>
|
||||
<DataTemplate>
|
||||
<Grid Background="{Binding Background, ElementName=PART_ContentHost}" RenderOptions.ClearTypeHint="Enabled">
|
||||
<ContentPresenter Content="{Binding Path=Content, ElementName=PART_ContentHost}"></ContentPresenter>
|
||||
<Grid Background="{Binding Background, ElementName=PART_ContentHost}">
|
||||
<ContentPresenter Content="{Binding Path=Content, ElementName=PART_ContentHost}" />
|
||||
</Grid>
|
||||
</DataTemplate>
|
||||
</ScrollViewer.ContentTemplate>
|
||||
|
|
@ -37,47 +47,47 @@
|
|||
</Setter>
|
||||
</Style>
|
||||
|
||||
<!-- Further font customisations are dynamically loaded in Theme.cs -->
|
||||
<Style x:Key="BaseQuerySuggestionBoxStyle" BasedOn="{StaticResource BaseQueryBoxStyle}" TargetType="{x:Type TextBox}">
|
||||
<!-- Further font customisations are dynamically loaded in Theme.cs -->
|
||||
<Style
|
||||
x:Key="BaseQuerySuggestionBoxStyle"
|
||||
BasedOn="{StaticResource BaseQueryBoxStyle}"
|
||||
TargetType="{x:Type TextBox}">
|
||||
<Setter Property="Foreground" Value="DarkGray" />
|
||||
<Setter Property="Height" Value="48" />
|
||||
<Setter Property="Margin" Value="16 7 0 7" />
|
||||
<Setter Property="Margin" Value="16,7,0,7" />
|
||||
<Setter Property="Background" Value="Transparent" />
|
||||
<Setter Property="Padding" Value="0 4 68 0" />
|
||||
<Setter Property="Padding" Value="0,4,68,0" />
|
||||
<Setter Property="HorizontalAlignment" Value="Stretch" />
|
||||
<Setter Property="VerticalAlignment" Value="Center" />
|
||||
</Style>
|
||||
|
||||
<Style x:Key="BaseWindowBorderStyle" TargetType="{x:Type Border}">
|
||||
<Setter Property="BorderThickness" Value="0" />
|
||||
<Setter Property="Background" Value="#2F2F2F"></Setter>
|
||||
<Setter Property="Padding" Value="0 0 0 0" />
|
||||
<Setter Property="Background" Value="#2F2F2F" />
|
||||
<Setter Property="Padding" Value="0,0,0,0" />
|
||||
<Setter Property="CornerRadius" Value="5" />
|
||||
</Style>
|
||||
<Style x:Key="BaseWindowStyle" TargetType="{x:Type Window}">
|
||||
<Setter Property="Width" Value="600" />
|
||||
<Setter Property="RenderOptions.ClearTypeHint" Value="Enabled"/>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="WindowRadius" TargetType="{x:Type Border}">
|
||||
<Setter Property="CornerRadius" Value="5" />
|
||||
</Style>
|
||||
|
||||
|
||||
<Style x:Key="BasePendingLineStyle" TargetType="{x:Type Line}">
|
||||
<Setter Property="Stroke" Value="Blue" />
|
||||
</Style>
|
||||
|
||||
|
||||
<!-- Item Style -->
|
||||
|
||||
<!-- Item Style -->
|
||||
<Style x:Key="BaseItemTitleStyle" TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Foreground" Value="#FFFFF8" />
|
||||
<Setter Property="FontSize" Value="16" />
|
||||
<Setter Property="FontWeight" Value="Medium" />
|
||||
<Setter Property="RenderOptions.ClearTypeHint" Value="Enabled"/>
|
||||
</Style>
|
||||
<Style x:Key="BaseItemSubTitleStyle" TargetType="{x:Type TextBlock}" >
|
||||
<Style x:Key="BaseItemSubTitleStyle" TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Foreground" Value="#D9D9D4" />
|
||||
<Setter Property="RenderOptions.ClearTypeHint" Value="Enabled"/>
|
||||
<Setter Property="FontSize" Value="13" />
|
||||
<Setter Property="FontWeight" Value="Normal" />
|
||||
<Style.Triggers>
|
||||
|
|
@ -89,9 +99,8 @@
|
|||
<Style x:Key="BaseItemNumberStyle" TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="VerticalAlignment" Value="Center" />
|
||||
<Setter Property="HorizontalAlignment" Value="Center" />
|
||||
<Setter Property="Margin" Value="3 0 0 0" />
|
||||
<Setter Property="Margin" Value="3,0,0,0" />
|
||||
<Setter Property="FontSize" Value="22" />
|
||||
<Setter Property="RenderOptions.ClearTypeHint" Value="Enabled"/>
|
||||
</Style>
|
||||
<Style x:Key="BaseGlyphStyle" TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Foreground" Value="#ffffff" />
|
||||
|
|
@ -99,34 +108,31 @@
|
|||
<Setter Property="HorizontalAlignment" Value="Center" />
|
||||
<Setter Property="Width" Value="25" />
|
||||
<Setter Property="Height" Value="25" />
|
||||
<Setter Property="FontSize" Value="25"/>
|
||||
<Setter Property="FontSize" Value="25" />
|
||||
</Style>
|
||||
<Style x:Key="BaseItemTitleSelectedStyle" TargetType="{x:Type TextBlock}" >
|
||||
<Style x:Key="BaseItemTitleSelectedStyle" TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Foreground" Value="#FFFFF8" />
|
||||
<Setter Property="FontSize" Value="16" />
|
||||
<Setter Property="FontWeight" Value="Normal" />
|
||||
<Setter Property="RenderOptions.ClearTypeHint" Value="Enabled"/>
|
||||
</Style>
|
||||
<Style x:Key="BaseItemSubTitleSelectedStyle" TargetType="{x:Type TextBlock}" >
|
||||
<Style x:Key="BaseItemSubTitleSelectedStyle" TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Foreground" Value="#D9D9D4" />
|
||||
<Setter Property="FontSize" Value="13" />
|
||||
<Setter Property="RenderOptions.ClearTypeHint" Value="Enabled"/>
|
||||
<Style.Triggers>
|
||||
<DataTrigger Binding="{Binding ElementName=SubTitle, UpdateSourceTrigger=PropertyChanged, Path=Text.Length}" Value="0">
|
||||
<Setter Property="Height" Value="0" />
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
<Style x:Key="BaseItemImageSelectedStyle" TargetType="{x:Type Image}" >
|
||||
</Style>
|
||||
<Style x:Key="BaseItemImageSelectedStyle" TargetType="{x:Type Image}" />
|
||||
|
||||
<Style x:Key="BaseListboxStyle" TargetType="{x:Type ListBox}">
|
||||
<Setter Property="BorderBrush" Value="Transparent"/>
|
||||
<Setter Property="Background" Value="Transparent"/>
|
||||
<Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Disabled"/>
|
||||
<Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto"/>
|
||||
<Setter Property="Margin" Value="0 0 0 0" />
|
||||
<Setter Property="Padding" Value="0 0 0 0" />
|
||||
<Setter Property="BorderBrush" Value="Transparent" />
|
||||
<Setter Property="Background" Value="Transparent" />
|
||||
<Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Disabled" />
|
||||
<Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto" />
|
||||
<Setter Property="Margin" Value="0,0,0,0" />
|
||||
<Setter Property="Padding" Value="0,0,0,0" />
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="ListBox">
|
||||
|
|
@ -135,12 +141,12 @@
|
|||
<Style TargetType="ScrollViewer">
|
||||
<Style.Triggers>
|
||||
<Trigger Property="ComputedVerticalScrollBarVisibility" Value="Visible">
|
||||
<Setter Property="Margin" Value="0 0 0 0" />
|
||||
<Setter Property="Padding" Value="0 0 0 0" />
|
||||
<Setter Property="Margin" Value="0,0,0,0" />
|
||||
<Setter Property="Padding" Value="0,0,0,0" />
|
||||
</Trigger>
|
||||
<Trigger Property="ComputedVerticalScrollBarVisibility" Value="Collapsed">
|
||||
<Setter Property="Margin" Value="0 0 0 0" />
|
||||
<Setter Property="Padding" Value="0 0 0 0" />
|
||||
<Setter Property="Margin" Value="0,0,0,0" />
|
||||
<Setter Property="Padding" Value="0,0,0,0" />
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
|
|
@ -152,7 +158,7 @@
|
|||
</Setter>
|
||||
</Style>
|
||||
|
||||
<!-- ScrollViewer Style -->
|
||||
<!-- ScrollViewer Style -->
|
||||
<ControlTemplate x:Key="ScrollViewerControlTemplate" TargetType="{x:Type ScrollViewer}">
|
||||
<Grid x:Name="Grid" Background="{TemplateBinding Background}">
|
||||
<Grid.ColumnDefinitions>
|
||||
|
|
@ -160,44 +166,50 @@
|
|||
<ColumnDefinition Width="Auto" />
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<!--content in the left of ScrollViewer, just default-->
|
||||
<ScrollContentPresenter x:Name="PART_ScrollContentPresenter"
|
||||
CanContentScroll="{TemplateBinding CanContentScroll}"
|
||||
CanHorizontallyScroll="False"
|
||||
CanVerticallyScroll="False"
|
||||
ContentTemplate="{TemplateBinding ContentTemplate}"
|
||||
Content="{TemplateBinding Content}"
|
||||
Grid.Column="0"
|
||||
Margin="0"
|
||||
Grid.Row="0" />
|
||||
<!-- content in the left of ScrollViewer, just default -->
|
||||
<ScrollContentPresenter
|
||||
x:Name="PART_ScrollContentPresenter"
|
||||
Grid.Row="0"
|
||||
Grid.Column="0"
|
||||
Margin="0"
|
||||
CanContentScroll="{TemplateBinding CanContentScroll}"
|
||||
CanHorizontallyScroll="False"
|
||||
CanVerticallyScroll="False"
|
||||
Content="{TemplateBinding Content}"
|
||||
ContentTemplate="{TemplateBinding ContentTemplate}" />
|
||||
|
||||
<!--Scrollbar in thr rigth of ScrollViewer-->
|
||||
<ScrollBar x:Name="PART_VerticalScrollBar"
|
||||
AutomationProperties.AutomationId="VerticalScrollBar"
|
||||
Cursor="Arrow"
|
||||
Grid.Column="0"
|
||||
HorizontalAlignment="Right"
|
||||
Margin="0 0 0 0"
|
||||
Maximum="{TemplateBinding ScrollableHeight}"
|
||||
Minimum="0"
|
||||
Grid.Row="0"
|
||||
Visibility="{TemplateBinding ComputedVerticalScrollBarVisibility}"
|
||||
Value="{Binding VerticalOffset, Mode=OneWay, RelativeSource={RelativeSource TemplatedParent}}"
|
||||
ViewportSize="{TemplateBinding ViewportHeight}"
|
||||
Style="{DynamicResource ScrollBarStyle}" />
|
||||
<!-- Scrollbar in thr rigth of ScrollViewer -->
|
||||
<ScrollBar
|
||||
x:Name="PART_VerticalScrollBar"
|
||||
Grid.Row="0"
|
||||
Grid.Column="0"
|
||||
Margin="0,0,0,0"
|
||||
HorizontalAlignment="Right"
|
||||
AutomationProperties.AutomationId="VerticalScrollBar"
|
||||
Cursor="Arrow"
|
||||
Maximum="{TemplateBinding ScrollableHeight}"
|
||||
Minimum="0"
|
||||
Style="{DynamicResource ScrollBarStyle}"
|
||||
ViewportSize="{TemplateBinding ViewportHeight}"
|
||||
Visibility="{TemplateBinding ComputedVerticalScrollBarVisibility}"
|
||||
Value="{Binding VerticalOffset, Mode=OneWay, RelativeSource={RelativeSource TemplatedParent}}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
|
||||
<!-- button style in the middle of the scrollbar -->
|
||||
<!-- button style in the middle of the scrollbar -->
|
||||
<Style x:Key="BaseThumbStyle" TargetType="{x:Type Thumb}">
|
||||
<Setter Property="SnapsToDevicePixels" Value="True"/>
|
||||
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
||||
<Setter Property="IsTabStop" Value="false"/>
|
||||
<Setter Property="Focusable" Value="false"/>
|
||||
<Setter Property="SnapsToDevicePixels" Value="True" />
|
||||
<Setter Property="OverridesDefaultStyle" Value="true" />
|
||||
<Setter Property="IsTabStop" Value="false" />
|
||||
<Setter Property="Focusable" Value="false" />
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type Thumb}">
|
||||
<Border CornerRadius="2" DockPanel.Dock="Right" Background="#898989" BorderBrush="Transparent" />
|
||||
<Border
|
||||
Background="#898989"
|
||||
BorderBrush="Transparent"
|
||||
CornerRadius="2"
|
||||
DockPanel.Dock="Right" />
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
|
|
@ -207,16 +219,19 @@
|
|||
<Setter Property="Stylus.IsPressAndHoldEnabled" Value="false" />
|
||||
<Setter Property="Stylus.IsFlicksEnabled" Value="false" />
|
||||
<Setter Property="Background" Value="Black" />
|
||||
<!-- must set min width -->
|
||||
<Setter Property="MinWidth" Value="0"/>
|
||||
<Setter Property="Width" Value="5"/>
|
||||
<!-- must set min width -->
|
||||
<Setter Property="MinWidth" Value="0" />
|
||||
<Setter Property="Width" Value="5" />
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type ScrollBar}">
|
||||
<DockPanel>
|
||||
<Track x:Name="PART_Track" IsDirectionReversed="true" DockPanel.Dock="Right">
|
||||
<Track
|
||||
x:Name="PART_Track"
|
||||
DockPanel.Dock="Right"
|
||||
IsDirectionReversed="true">
|
||||
<Track.Thumb>
|
||||
<Thumb Style="{DynamicResource ThumbStyle}"/>
|
||||
<Thumb Style="{DynamicResource ThumbStyle}" />
|
||||
</Track.Thumb>
|
||||
</Track>
|
||||
</DockPanel>
|
||||
|
|
@ -224,8 +239,7 @@
|
|||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
<Style x:Key="BaseSeparatorStyle" TargetType="Rectangle">
|
||||
</Style>
|
||||
<Style x:Key="BaseSeparatorStyle" TargetType="Rectangle" />
|
||||
<Style x:Key="HighlightStyle">
|
||||
<Setter Property="Inline.FontWeight" Value="Bold" />
|
||||
</Style>
|
||||
|
|
@ -249,12 +263,12 @@
|
|||
<Style x:Key="BaseSearchIconPosition" TargetType="{x:Type Canvas}">
|
||||
<Setter Property="Width" Value="32" />
|
||||
<Setter Property="Height" Value="32" />
|
||||
<Setter Property="Margin" Value="0 2 18 0" />
|
||||
<Setter Property="Margin" Value="0,2,18,0" />
|
||||
<Setter Property="Background" Value="Transparent" />
|
||||
<Setter Property="HorizontalAlignment" Value="Right" />
|
||||
</Style>
|
||||
|
||||
<!--for classic themes-->
|
||||
|
||||
<!-- for classic themes -->
|
||||
<Style x:Key="SearchIconStyle" TargetType="{x:Type Path}">
|
||||
<Setter Property="Fill" Value="#555555" />
|
||||
<Setter Property="Width" Value="32" />
|
||||
|
|
@ -263,19 +277,24 @@
|
|||
<Style x:Key="SearchIconPosition" TargetType="{x:Type Canvas}">
|
||||
<Setter Property="Width" Value="32" />
|
||||
<Setter Property="Height" Value="32" />
|
||||
<Setter Property="Margin" Value="0 2 18 0" />
|
||||
<Setter Property="Margin" Value="0,2,18,0" />
|
||||
<Setter Property="Background" Value="Transparent" />
|
||||
<Setter Property="HorizontalAlignment" Value="Right" />
|
||||
</Style>
|
||||
<Style x:Key="ItemHotkeyStyle" TargetType="{x:Type TextBlock}" BasedOn="{StaticResource BaseItemHotkeyStyle}">
|
||||
<Style
|
||||
x:Key="ItemHotkeyStyle"
|
||||
BasedOn="{StaticResource BaseItemHotkeyStyle}"
|
||||
TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="FontSize" Value="15" />
|
||||
<Setter Property="Foreground" Value="#8f8f8f" />
|
||||
<Setter Property="Opacity" Value="0.5" />
|
||||
</Style>
|
||||
<Style x:Key="ItemHotkeySelectedStyle" TargetType="{x:Type TextBlock}" BasedOn="{StaticResource BaseItemHotkeySelecetedStyle}">
|
||||
<Style
|
||||
x:Key="ItemHotkeySelectedStyle"
|
||||
BasedOn="{StaticResource BaseItemHotkeySelecetedStyle}"
|
||||
TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="FontSize" Value="15" />
|
||||
<Setter Property="Foreground" Value="#8f8f8f" />
|
||||
<Setter Property="Opacity" Value="0.5" />
|
||||
</Style>
|
||||
</ResourceDictionary>
|
||||
|
||||
|
|
@ -13,12 +13,14 @@ using Flow.Launcher.Infrastructure.Hotkey;
|
|||
using Flow.Launcher.Infrastructure.Storage;
|
||||
using Flow.Launcher.Infrastructure.UserSettings;
|
||||
using Flow.Launcher.Plugin;
|
||||
using Flow.Launcher.Plugin.SharedCommands;
|
||||
using Flow.Launcher.Storage;
|
||||
using Flow.Launcher.Infrastructure.Logger;
|
||||
using Microsoft.VisualStudio.Threading;
|
||||
using System.Threading.Channels;
|
||||
using ISavable = Flow.Launcher.Plugin.ISavable;
|
||||
|
||||
using System.IO;
|
||||
using System.Collections.Specialized;
|
||||
|
||||
namespace Flow.Launcher.ViewModel
|
||||
{
|
||||
|
|
@ -229,7 +231,7 @@ namespace Flow.Launcher.ViewModel
|
|||
AutocompleteQueryCommand = new RelayCommand(_ =>
|
||||
{
|
||||
var result = SelectedResults.SelectedItem?.Result;
|
||||
if (result != null) // SelectedItem returns null if selection is empty.
|
||||
if (result != null && SelectedIsFromQueryResults()) // SelectedItem returns null if selection is empty.
|
||||
{
|
||||
var autoCompleteText = result.Title;
|
||||
|
||||
|
|
@ -252,6 +254,18 @@ namespace Flow.Launcher.ViewModel
|
|||
}
|
||||
});
|
||||
|
||||
BackspaceCommand = new RelayCommand(index =>
|
||||
{
|
||||
var query = QueryBuilder.Build(QueryText.Trim(), PluginManager.NonGlobalPlugins);
|
||||
|
||||
// GetPreviousExistingDirectory does not require trailing '\', otherwise will return empty string
|
||||
var path = FilesFolders.GetPreviousExistingDirectory((_) => true, query.Search.TrimEnd('\\'));
|
||||
|
||||
var actionKeyword = string.IsNullOrEmpty(query.ActionKeyword) ? string.Empty : $"{query.ActionKeyword} ";
|
||||
|
||||
ChangeQueryText($"{actionKeyword}{path}");
|
||||
});
|
||||
|
||||
LoadContextMenuCommand = new RelayCommand(_ =>
|
||||
{
|
||||
if (SelectedIsFromQueryResults())
|
||||
|
|
@ -398,6 +412,7 @@ namespace Flow.Launcher.ViewModel
|
|||
public string PluginIconPath { get; set; } = null;
|
||||
|
||||
public ICommand EscCommand { get; set; }
|
||||
public ICommand BackspaceCommand { get; set; }
|
||||
public ICommand SelectNextItemCommand { get; set; }
|
||||
public ICommand SelectPrevItemCommand { get; set; }
|
||||
public ICommand SelectNextPageCommand { get; set; }
|
||||
|
|
@ -410,6 +425,9 @@ namespace Flow.Launcher.ViewModel
|
|||
public ICommand OpenSettingCommand { get; set; }
|
||||
public ICommand ReloadPluginDataCommand { get; set; }
|
||||
public ICommand ClearQueryCommand { get; private set; }
|
||||
|
||||
public ICommand CopyToClipboard { get; set; }
|
||||
|
||||
public ICommand AutocompleteQueryCommand { get; set; }
|
||||
|
||||
public string OpenResultCommandModifiers { get; private set; }
|
||||
|
|
@ -662,7 +680,7 @@ namespace Flow.Launcher.ViewModel
|
|||
Action = _ =>
|
||||
{
|
||||
_topMostRecord.Remove(result);
|
||||
App.API.ShowMsg("Success");
|
||||
App.API.ShowMsg(InternationalizationManager.Instance.GetTranslation("success"));
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
|
@ -706,7 +724,11 @@ namespace Flow.Launcher.ViewModel
|
|||
IcoPath = icon,
|
||||
SubTitle = subtitle,
|
||||
PluginDirectory = metadata.PluginDirectory,
|
||||
Action = _ => false
|
||||
Action = _ =>
|
||||
{
|
||||
App.API.OpenUrl(metadata.Website);
|
||||
return true;
|
||||
}
|
||||
};
|
||||
return menu;
|
||||
}
|
||||
|
|
@ -853,6 +875,52 @@ namespace Flow.Launcher.ViewModel
|
|||
Results.AddResults(resultsForUpdates, token);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// This is the global copy method for an individual result. If no text is passed,
|
||||
/// the method will work out what is to be copied based on the result, so plugin can offer the text
|
||||
/// to be copied via the result model. If the text is a directory/file path,
|
||||
/// then actual file/folder will be copied instead.
|
||||
/// The result's subtitle text is the default text to be copied
|
||||
/// </summary>
|
||||
public void ResultCopy(string stringToCopy)
|
||||
{
|
||||
if (string.IsNullOrEmpty(stringToCopy))
|
||||
{
|
||||
var result = Results.SelectedItem?.Result;
|
||||
if (result != null)
|
||||
{
|
||||
string copyText = string.IsNullOrEmpty(result.CopyText) ? result.SubTitle : result.CopyText;
|
||||
var isFile = File.Exists(copyText);
|
||||
var isFolder = Directory.Exists(copyText);
|
||||
if (isFile || isFolder)
|
||||
{
|
||||
var paths = new StringCollection();
|
||||
paths.Add(copyText);
|
||||
|
||||
Clipboard.SetFileDropList(paths);
|
||||
App.API.ShowMsg(
|
||||
App.API.GetTranslation("copy")
|
||||
+" "
|
||||
+ (isFile? App.API.GetTranslation("fileTitle") : App.API.GetTranslation("folderTitle")),
|
||||
App.API.GetTranslation("completedSuccessfully"));
|
||||
}
|
||||
else
|
||||
{
|
||||
Clipboard.SetDataObject(copyText.ToString());
|
||||
App.API.ShowMsg(
|
||||
App.API.GetTranslation("copy")
|
||||
+ " "
|
||||
+ App.API.GetTranslation("textTitle"),
|
||||
App.API.GetTranslation("completedSuccessfully"));
|
||||
}
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
Clipboard.SetDataObject(stringToCopy);
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
|
@ -7,11 +7,16 @@ using Flow.Launcher.Infrastructure.Logger;
|
|||
using Flow.Launcher.Infrastructure.UserSettings;
|
||||
using Flow.Launcher.Plugin;
|
||||
using System.IO;
|
||||
using System.Drawing.Text;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Flow.Launcher.ViewModel
|
||||
{
|
||||
public class ResultViewModel : BaseModel
|
||||
{
|
||||
private static PrivateFontCollection fontCollection = new();
|
||||
private static Dictionary<string, string> fonts = new();
|
||||
|
||||
public ResultViewModel(Result result, Settings settings)
|
||||
{
|
||||
if (result != null)
|
||||
|
|
@ -23,13 +28,29 @@ namespace Flow.Launcher.ViewModel
|
|||
// Checks if it's a system installed font, which does not require path to be provided.
|
||||
if (glyph.FontFamily.EndsWith(".ttf") || glyph.FontFamily.EndsWith(".otf"))
|
||||
{
|
||||
var fontPath = Result.Glyph.FontFamily;
|
||||
Glyph = Path.IsPathRooted(fontPath)
|
||||
? Result.Glyph
|
||||
: Result.Glyph with
|
||||
string fontFamilyPath = glyph.FontFamily;
|
||||
|
||||
if (!Path.IsPathRooted(fontFamilyPath))
|
||||
{
|
||||
fontFamilyPath = Path.Combine(Result.PluginDirectory, fontFamilyPath);
|
||||
}
|
||||
|
||||
if (fonts.ContainsKey(fontFamilyPath))
|
||||
{
|
||||
Glyph = glyph with
|
||||
{
|
||||
FontFamily = Path.Combine(Result.PluginDirectory, fontPath)
|
||||
FontFamily = fonts[fontFamilyPath]
|
||||
};
|
||||
}
|
||||
else
|
||||
{
|
||||
fontCollection.AddFontFile(fontFamilyPath);
|
||||
fonts[fontFamilyPath] = $"{Path.GetDirectoryName(fontFamilyPath)}/#{fontCollection.Families[^1].Name}";
|
||||
Glyph = glyph with
|
||||
{
|
||||
FontFamily = fonts[fontFamilyPath]
|
||||
};
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
|
|
@ -310,4 +310,4 @@ namespace Flow.Launcher.ViewModel
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -37,7 +37,8 @@ namespace Flow.Launcher.Plugin.BrowserBookmark
|
|||
return new();
|
||||
foreach (var folder in rootElement.EnumerateObject())
|
||||
{
|
||||
EnumerateFolderBookmark(folder.Value, bookmarks, source);
|
||||
if (folder.Value.ValueKind == JsonValueKind.Object)
|
||||
EnumerateFolderBookmark(folder.Value, bookmarks, source);
|
||||
}
|
||||
return bookmarks;
|
||||
}
|
||||
|
|
@ -64,4 +65,4 @@ namespace Flow.Launcher.Plugin.BrowserBookmark
|
|||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<OutputType>Library</OutputType>
|
||||
<TargetFramework>net5.0-windows</TargetFramework>
|
||||
<TargetFramework>net6.0-windows</TargetFramework>
|
||||
<UseWPF>true</UseWPF>
|
||||
<ProjectGuid>{9B130CC5-14FB-41FF-B310-0A95B6894C37}</ProjectGuid>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
|
|
|
|||
|
Before Width: | Height: | Size: 4.4 KiB After Width: | Height: | Size: 5.2 KiB |
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 3.2 KiB |
|
|
@ -4,7 +4,7 @@
|
|||
"Name": "Browser Bookmarks",
|
||||
"Description": "Search your browser bookmarks",
|
||||
"Author": "qianlifeng, Ioannis G.",
|
||||
"Version": "1.6.2",
|
||||
"Version": "1.6.3",
|
||||
"Language": "csharp",
|
||||
"Website": "https://github.com/Flow-Launcher/Flow.Launcher",
|
||||
"ExecuteFileName": "Flow.Launcher.Plugin.BrowserBookmark.dll",
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<OutputType>Library</OutputType>
|
||||
<TargetFramework>net5.0-windows</TargetFramework>
|
||||
<TargetFramework>net6.0-windows</TargetFramework>
|
||||
<ProjectGuid>{59BD9891-3837-438A-958D-ADC7F91F6F7E}</ProjectGuid>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>Flow.Launcher.Plugin.Caculator</RootNamespace>
|
||||
|
|
|
|||
|
Before Width: | Height: | Size: 597 B After Width: | Height: | Size: 3.2 KiB |
|
|
@ -6,7 +6,6 @@ using System.Text.RegularExpressions;
|
|||
using System.Windows;
|
||||
using System.Windows.Controls;
|
||||
using Mages.Core;
|
||||
using Flow.Launcher.Infrastructure.Storage;
|
||||
using Flow.Launcher.Plugin.Caculator.ViewModels;
|
||||
using Flow.Launcher.Plugin.Caculator.Views;
|
||||
|
||||
|
|
@ -25,6 +24,9 @@ namespace Flow.Launcher.Plugin.Caculator
|
|||
@")+$", RegexOptions.Compiled);
|
||||
private static readonly Regex RegBrackets = new Regex(@"[\(\)\[\]]", RegexOptions.Compiled);
|
||||
private static Engine MagesEngine;
|
||||
private const string comma = ",";
|
||||
private const string dot = ".";
|
||||
|
||||
private PluginInitContext Context { get; set; }
|
||||
|
||||
private static Settings _settings;
|
||||
|
|
@ -35,7 +37,7 @@ namespace Flow.Launcher.Plugin.Caculator
|
|||
Context = context;
|
||||
_settings = context.API.LoadSettingJsonStorage<Settings>();
|
||||
_viewModel = new SettingsViewModel(_settings);
|
||||
|
||||
|
||||
MagesEngine = new Engine(new Configuration
|
||||
{
|
||||
Scope = new Dictionary<string, object>
|
||||
|
|
@ -54,7 +56,19 @@ namespace Flow.Launcher.Plugin.Caculator
|
|||
|
||||
try
|
||||
{
|
||||
var expression = query.Search.Replace(",", ".");
|
||||
string expression;
|
||||
|
||||
switch (_settings.DecimalSeparator)
|
||||
{
|
||||
case DecimalSeparator.Comma:
|
||||
case DecimalSeparator.UseSystemLocale when CultureInfo.CurrentCulture.NumberFormat.NumberDecimalSeparator == ",":
|
||||
expression = query.Search.Replace(",", ".");
|
||||
break;
|
||||
default:
|
||||
expression = query.Search;
|
||||
break;
|
||||
}
|
||||
|
||||
var result = MagesEngine.Interpret(expression);
|
||||
|
||||
if (result?.ToString() == "NaN")
|
||||
|
|
@ -76,6 +90,7 @@ namespace Flow.Launcher.Plugin.Caculator
|
|||
IcoPath = "Images/calculator.png",
|
||||
Score = 300,
|
||||
SubTitle = Context.API.GetTranslation("flowlauncher_plugin_calculator_copy_number_to_clipboard"),
|
||||
CopyText = newResult,
|
||||
Action = c =>
|
||||
{
|
||||
try
|
||||
|
|
@ -119,6 +134,10 @@ namespace Flow.Launcher.Plugin.Caculator
|
|||
return false;
|
||||
}
|
||||
|
||||
if ((query.Search.Contains(dot) && GetDecimalSeparator() != dot) ||
|
||||
(query.Search.Contains(comma) && GetDecimalSeparator() != comma))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -142,8 +161,8 @@ namespace Flow.Launcher.Plugin.Caculator
|
|||
switch (_settings.DecimalSeparator)
|
||||
{
|
||||
case DecimalSeparator.UseSystemLocale: return systemDecimalSeperator;
|
||||
case DecimalSeparator.Dot: return ".";
|
||||
case DecimalSeparator.Comma: return ",";
|
||||
case DecimalSeparator.Dot: return dot;
|
||||
case DecimalSeparator.Comma: return comma;
|
||||
default: return systemDecimalSeperator;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,9 +1,4 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
|
||||
namespace Flow.Launcher.Plugin.Caculator
|
||||
{
|
||||
public class Settings
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
"Name": "Calculator",
|
||||
"Description": "Provide mathematical calculations.(Try 5*3-2 in Flow Launcher)",
|
||||
"Author": "cxfksword",
|
||||
"Version": "1.1.9",
|
||||
"Version": "1.1.10",
|
||||
"Language": "csharp",
|
||||
"Website": "https://github.com/Flow-Launcher/Flow.Launcher",
|
||||
"ExecuteFileName": "Flow.Launcher.Plugin.Caculator.dll",
|
||||
|
|
|
|||
|
|
@ -1,7 +0,0 @@
|
|||
<?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">
|
||||
|
||||
<system:String x:Key="flowlauncher_plugin_controlpanel_plugin_name">제어판</system:String>
|
||||
<system:String x:Key="flowlauncher_plugin_controlpanel_plugin_description">제어판 항목을 검색합니다.</system:String>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<OutputType>Library</OutputType>
|
||||
<TargetFramework>net5.0-windows</TargetFramework>
|
||||
<TargetFramework>net6.0-windows</TargetFramework>
|
||||
<UseWPF>true</UseWPF>
|
||||
<UseWindowsForms>true</UseWindowsForms>
|
||||
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
|
||||
|
|
|
|||
|
Before Width: | Height: | Size: 501 B After Width: | Height: | Size: 2.6 KiB |
|
Before Width: | Height: | Size: 19 KiB After Width: | Height: | Size: 2.4 KiB |
|
Before Width: | Height: | Size: 32 KiB After Width: | Height: | Size: 2.7 KiB |
|
Before Width: | Height: | Size: 290 B After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 468 B After Width: | Height: | Size: 2 KiB |
|
Before Width: | Height: | Size: 19 KiB After Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 43 KiB After Width: | Height: | Size: 2.4 KiB |
|
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 2.4 KiB |
|
Before Width: | Height: | Size: 64 KiB After Width: | Height: | Size: 3.3 KiB |
|
|
@ -89,6 +89,7 @@
|
|||
<Expander
|
||||
x:Name="expExcludedPaths"
|
||||
Margin="0,10,0,0"
|
||||
Collapsed="expExcludedPaths_Collapsed"
|
||||
Expanded="expExcludedPaths_Click"
|
||||
Header="{DynamicResource plugin_explorer_indexsearchexcludedpaths_header}">
|
||||
<ListView
|
||||
|
|
|
|||
|
|
@ -60,9 +60,7 @@ namespace Flow.Launcher.Plugin.Explorer.Views
|
|||
|
||||
lbxExcludedPaths.Items.SortDescriptions.Add(new SortDescription("Path", ListSortDirection.Ascending));
|
||||
|
||||
btnDelete.Visibility = Visibility.Hidden;
|
||||
btnEdit.Visibility = Visibility.Hidden;
|
||||
btnAdd.Visibility = Visibility.Hidden;
|
||||
SetButtonVisibilityToHidden();
|
||||
|
||||
if (expAccessLinks.IsExpanded || expExcludedPaths.IsExpanded || expActionKeywords.IsExpanded)
|
||||
{
|
||||
|
|
@ -123,8 +121,8 @@ namespace Flow.Launcher.Plugin.Explorer.Views
|
|||
|
||||
private void expActionKeywords_Collapsed(object sender, RoutedEventArgs e)
|
||||
{
|
||||
if (!expActionKeywords.IsExpanded)
|
||||
expActionKeywords.Height = double.NaN;
|
||||
expActionKeywords.Height = double.NaN;
|
||||
SetButtonVisibilityToHidden();
|
||||
}
|
||||
|
||||
private void expAccessLinks_Click(object sender, RoutedEventArgs e)
|
||||
|
|
@ -143,8 +141,8 @@ namespace Flow.Launcher.Plugin.Explorer.Views
|
|||
|
||||
private void expAccessLinks_Collapsed(object sender, RoutedEventArgs e)
|
||||
{
|
||||
if (!expAccessLinks.IsExpanded)
|
||||
expAccessLinks.Height = double.NaN;
|
||||
expAccessLinks.Height = double.NaN;
|
||||
SetButtonVisibilityToHidden();
|
||||
}
|
||||
|
||||
private void expExcludedPaths_Click(object sender, RoutedEventArgs e)
|
||||
|
|
@ -161,6 +159,11 @@ namespace Flow.Launcher.Plugin.Explorer.Views
|
|||
RefreshView();
|
||||
}
|
||||
|
||||
private void expExcludedPaths_Collapsed(object sender, RoutedEventArgs e)
|
||||
{
|
||||
SetButtonVisibilityToHidden();
|
||||
}
|
||||
|
||||
private void btnDelete_Click(object sender, RoutedEventArgs e)
|
||||
{
|
||||
var selectedRow = lbxAccessLinks.SelectedItem as AccessLink ?? lbxExcludedPaths.SelectedItem as AccessLink;
|
||||
|
|
@ -309,6 +312,13 @@ namespace Flow.Launcher.Plugin.Explorer.Views
|
|||
{
|
||||
viewModel.OpenWindowsIndexingOptions();
|
||||
}
|
||||
|
||||
public void SetButtonVisibilityToHidden()
|
||||
{
|
||||
btnDelete.Visibility = Visibility.Hidden;
|
||||
btnEdit.Visibility = Visibility.Hidden;
|
||||
btnAdd.Visibility = Visibility.Hidden;
|
||||
}
|
||||
}
|
||||
|
||||
public class ActionKeywordView
|
||||
|
|
|
|||