mirror of
https://github.com/microsoft/PowerToys.git
synced 2024-12-04 20:21:18 +08:00
Spelling: ... src/modules/launcher (#3694)
This commit is contained in:
parent
c674fe1f04
commit
71e528139c
@ -70,7 +70,7 @@ public:
|
||||
}
|
||||
|
||||
// Return array of the names of all events that this powertoy listens for, with
|
||||
// nullptr as the last element of the array. Nullptr can also be retured for empty
|
||||
// nullptr as the last element of the array. Nullptr can also be returned for empty
|
||||
// list.
|
||||
virtual const wchar_t** get_events() override {
|
||||
static const wchar_t* events[] = { nullptr };
|
||||
|
@ -221,7 +221,7 @@ namespace Microsoft.Plugin.Folder
|
||||
throw;
|
||||
}
|
||||
|
||||
// Intial ordering, this order can be updated later by UpdateResultView.MainViewModel based on history of user selection.
|
||||
// Initial ordering, this order can be updated later by UpdateResultView.MainViewModel based on history of user selection.
|
||||
return results.Concat(folderList.OrderBy(x => x.Title)).Concat(fileList.OrderBy(x => x.Title)).ToList();
|
||||
}
|
||||
|
||||
|
@ -207,7 +207,7 @@ namespace Microsoft.Plugin.Program
|
||||
|
||||
void InitializeTimer()
|
||||
{
|
||||
//multiple file writes occur on install / unistall. Adding a delay before actually indexing.
|
||||
//multiple file writes occur on install / uninstall. Adding a delay before actually indexing.
|
||||
var delayInterval = 5000;
|
||||
_timer = new System.Timers.Timer(delayInterval);
|
||||
_timer.Enabled = true;
|
||||
|
@ -28,7 +28,7 @@ namespace Microsoft.Plugin.Program.Views.Commands
|
||||
Main._settings
|
||||
.DisabledProgramSources
|
||||
.Where(t1 => !Main._settings
|
||||
.ProgramSources // program sourcces added above already, so exlcude
|
||||
.ProgramSources // program sources added above already, so exclude
|
||||
.Any(x => t1.UniqueIdentifier == x.UniqueIdentifier))
|
||||
.Select(x => x)
|
||||
.ToList()
|
||||
|
@ -14,7 +14,7 @@ namespace Microsoft.Plugin.WindowWalker.Components
|
||||
{
|
||||
/// <summary>
|
||||
/// Finds the best match (the one with the most
|
||||
/// number of letters adjecent to each other) and
|
||||
/// number of letters adjacent to each other) and
|
||||
/// returns the index location of each of the letters
|
||||
/// of the matches
|
||||
/// </summary>
|
||||
@ -67,7 +67,7 @@ namespace Microsoft.Plugin.WindowWalker.Components
|
||||
/// Gets all the possible matches to the search string with in the text
|
||||
/// </summary>
|
||||
/// <param name="matches"> a table showing the matches as generated by
|
||||
/// a two dimentional array with the first dimention the text and the second
|
||||
/// a two dimensional array with the first dimension the text and the second
|
||||
/// one the search string and each cell marked as an intersection between the two</param>
|
||||
/// <returns>a list of the possible combinations that match the search text</returns>
|
||||
public static List<List<int>> GetAllMatchIndexes(bool[,] matches)
|
||||
|
@ -7,7 +7,7 @@ using System;
|
||||
namespace Microsoft.Plugin.WindowWalker.Components
|
||||
{
|
||||
/// <summary>
|
||||
/// Class containg methods to control the live preview
|
||||
/// Class containing methods to control the live preview
|
||||
/// </summary>
|
||||
internal class LivePreview
|
||||
{
|
||||
|
@ -85,7 +85,7 @@ namespace Microsoft.Plugin.WindowWalker.Components
|
||||
/// <param name="hwnd">The handle to the current window being enumerated</param>
|
||||
/// <param name="lParam">Value being passed from the caller (we don't use this but might come in handy
|
||||
/// in the future</param>
|
||||
/// <returns>true to make sure to contiue enumeration</returns>
|
||||
/// <returns>true to make sure to continue enumeration</returns>
|
||||
public bool WindowEnumerationCallBack(IntPtr hwnd, IntPtr lParam)
|
||||
{
|
||||
Window newWindow = new Window(hwnd);
|
||||
|
@ -302,7 +302,7 @@ namespace Microsoft.Plugin.WindowWalker.Components
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Switches dekstop focus to the window
|
||||
/// Switches desktop focus to the window
|
||||
/// </summary>
|
||||
public void SwitchToWindow()
|
||||
{
|
||||
|
@ -84,7 +84,7 @@ namespace PowerLauncher
|
||||
// load plugin before change language, because plugin language also needs be changed
|
||||
InternationalizationManager.Instance.Settings = _settings;
|
||||
InternationalizationManager.Instance.ChangeLanguage(_settings.Language);
|
||||
// main windows needs initialized before theme change because of blur settigns
|
||||
// main windows needs initialized before theme change because of blur settings
|
||||
ThemeManager.Instance.Settings = _settings;
|
||||
ThemeManager.Instance.ChangeTheme(_settings.Theme);
|
||||
|
||||
@ -102,7 +102,7 @@ namespace PowerLauncher
|
||||
PowerToysTelemetry.Log.WriteEvent(new LauncherBootEvent() { BootTimeMs = bootTime.ElapsedMilliseconds });
|
||||
|
||||
//[Conditional("RELEASE")]
|
||||
// check udpate every 5 hours
|
||||
// check update every 5 hours
|
||||
|
||||
// check updates on startup
|
||||
});
|
||||
|
@ -85,7 +85,7 @@
|
||||
Margin="{TemplateBinding Padding}"
|
||||
Grid.Row="0" />
|
||||
|
||||
<!--Scrollbar in thr rigth of ScrollViewer-->
|
||||
<!--Scrollbar in the right of ScrollViewer-->
|
||||
<ScrollBar x:Name="PART_VerticalScrollBar"
|
||||
AutomationProperties.AutomationId="VerticalScrollBar"
|
||||
Cursor="Arrow"
|
||||
|
@ -1,6 +1,6 @@
|
||||
|
||||
/* We basically follow the Json-RPC 2.0 spec (http://www.jsonrpc.org/specification) to invoke methods between Wox and other plugins,
|
||||
* like python or other self-execute program. But, we added addtional infos (proxy and so on) into rpc request. Also, we didn't use the
|
||||
* like python or other self-execute program. But, we added additional infos (proxy and so on) into rpc request. Also, we didn't use the
|
||||
* "id" and "jsonrpc" in the request, since it's not so useful in our request model.
|
||||
*
|
||||
* When execute a query:
|
||||
|
@ -31,7 +31,7 @@ namespace Wox.Core.Plugin
|
||||
|
||||
private static void ParsePluginConfigs(IEnumerable<string> directories)
|
||||
{
|
||||
// todo use linq when diable plugin is implmented since parallel.foreach + list is not thread saft
|
||||
// todo use linq when diable plugin is implemented since parallel.foreach + list is not thread saft
|
||||
foreach (var directory in directories)
|
||||
{
|
||||
if (File.Exists(Path.Combine(directory, "NeedDelete.txt")))
|
||||
|
@ -74,8 +74,8 @@ namespace Wox.Core.Plugin
|
||||
UnZip(path, newPluginPath, true);
|
||||
Directory.Delete(tempFoler, true);
|
||||
|
||||
//exsiting plugins may be has loaded by application,
|
||||
//if we try to delelte those kind of plugins, we will get a error that indicate the
|
||||
//existing plugins could be loaded by the application,
|
||||
//if we try to delete those kind of plugins, we will get a error that indicate the
|
||||
//file is been used now.
|
||||
//current solution is to restart wox. Ugly.
|
||||
//if (MainWindow.Initialized)
|
||||
@ -148,7 +148,7 @@ namespace Wox.Core.Plugin
|
||||
/// </summary>
|
||||
/// <param name="zipedFile">The ziped file.</param>
|
||||
/// <param name="strDirectory">The STR directory.</param>
|
||||
/// <param name="overWrite">overwirte</param>
|
||||
/// <param name="overWrite">overwrite</param>
|
||||
private static void UnZip(string zipedFile, string strDirectory, bool overWrite)
|
||||
{
|
||||
if (strDirectory == "")
|
||||
|
@ -29,7 +29,7 @@ namespace Wox.Core.Plugin
|
||||
|
||||
public static IPublicAPI API { private set; get; }
|
||||
|
||||
// todo happlebao, this should not be public, the indicator function should be embeded
|
||||
// todo happlebao, this should not be public, the indicator function should be embedded
|
||||
public static PluginsSettings Settings;
|
||||
private static List<PluginMetadata> _metadatas;
|
||||
private static readonly string[] Directories = { Constant.PreinstalledDirectory, Constant.PluginsDirectory };
|
||||
|
@ -213,7 +213,7 @@ namespace Wox.Core.Resource
|
||||
public void SetBlurForWindow()
|
||||
{
|
||||
|
||||
// Exception of FindResource can't be cathed if global exception handle is set
|
||||
// Exception of FindResource can't be caught if global exception handle is set
|
||||
if (Environment.OSVersion.Version >= new Version(6, 2))
|
||||
{
|
||||
var resource = Application.Current.TryFindResource("ThemeBlurEnabled");
|
||||
|
@ -106,12 +106,12 @@ namespace Wox.Infrastructure
|
||||
return pinyin;
|
||||
}
|
||||
|
||||
/// <summmary>
|
||||
/// <summary>
|
||||
/// replace chinese character with pinyin, non chinese character won't be modified
|
||||
/// Because we don't have words dictionary, so we can only return all possiblie pinyin combination
|
||||
/// Because we don't have words dictionary, so we can only return all possibly pinyin combination
|
||||
/// e.g. 音乐 will return yinyue and yinle
|
||||
/// <param name="characters"> should be word or sentence, instead of single character. e.g. 微软 </param>
|
||||
/// </summmary>
|
||||
/// </summary>
|
||||
public string[][] PinyinCombination(string characters)
|
||||
{
|
||||
if (!_settings.ShouldUsePinyin || string.IsNullOrEmpty(characters))
|
||||
|
@ -9,7 +9,7 @@ using Wox.Infrastructure.Logger;
|
||||
namespace Wox.Infrastructure.Storage
|
||||
{
|
||||
/// <summary>
|
||||
/// Stroage object using binary data
|
||||
/// Storage object using binary data
|
||||
/// Normally, it has better performance, but not readable
|
||||
/// </summary>
|
||||
public class BinaryStorage<T>
|
||||
|
@ -2,7 +2,7 @@
|
||||
{
|
||||
/// <summary>
|
||||
/// Save plugin settings/cache,
|
||||
/// todo should be merged into a abstract class intead of seperate interface
|
||||
/// todo should be merged into a abstract class instead of separate interface
|
||||
/// </summary>
|
||||
public interface ISavable
|
||||
{
|
||||
|
@ -6,7 +6,7 @@ namespace Wox.Infrastructure.Storage
|
||||
{
|
||||
public PluginJsonStorage()
|
||||
{
|
||||
// C# releated, add python releated below
|
||||
// C# related, add python related below
|
||||
var dataType = typeof(T);
|
||||
var assemblyName = typeof(T).Assembly.GetName().Name;
|
||||
DirectoryPath = Path.Combine(Constant.DataDirectory, DirectoryName, Constant.Plugins, assemblyName);
|
||||
|
@ -304,13 +304,13 @@ namespace Wox.Infrastructure
|
||||
public class MatchOption
|
||||
{
|
||||
/// <summary>
|
||||
/// prefix of match char, use for hightlight
|
||||
/// prefix of match char, use for highlight
|
||||
/// </summary>
|
||||
[Obsolete("this is never used")]
|
||||
public string Prefix { get; set; } = "";
|
||||
|
||||
/// <summary>
|
||||
/// suffix of match char, use for hightlight
|
||||
/// suffix of match char, use for highlight
|
||||
/// </summary>
|
||||
[Obsolete("this is never used")]
|
||||
public string Suffix { get; set; } = "";
|
||||
|
@ -64,7 +64,7 @@ namespace Wox.Plugin
|
||||
|
||||
/// <summary>
|
||||
/// Reloads any Plugins that have the
|
||||
/// IReloadable implemented. It refeshes
|
||||
/// IReloadable implemented. It refreshes
|
||||
/// Plugin's in memory data with new content
|
||||
/// added by user.
|
||||
/// </summary>
|
||||
|
@ -43,7 +43,7 @@ namespace Wox.Plugin
|
||||
/// </summary>
|
||||
public const string TermSeperater = " ";
|
||||
/// <summary>
|
||||
/// User can set multiple action keywords seperated by ';'
|
||||
/// User can set multiple action keywords separated by ';'
|
||||
/// </summary>
|
||||
public const string ActionKeywordSeperater = ";";
|
||||
|
||||
|
@ -62,7 +62,7 @@ namespace Wox.Plugin
|
||||
public IList<int> SubTitleHighlightData { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Only resulsts that originQuery match with curren query will be displayed in the panel
|
||||
/// Only results that originQuery match with current query will be displayed in the panel
|
||||
/// </summary>
|
||||
internal Query OriginQuery { get; set; }
|
||||
|
||||
|
@ -73,7 +73,7 @@ namespace Wox
|
||||
// load plugin before change language, because plugin language also needs be changed
|
||||
InternationalizationManager.Instance.Settings = _settings;
|
||||
InternationalizationManager.Instance.ChangeLanguage(_settings.Language);
|
||||
// main windows needs initialized before theme change because of blur settigns
|
||||
// main windows needs initialized before theme change because of blur settings
|
||||
ThemeManager.Instance.Settings = _settings;
|
||||
ThemeManager.Instance.ChangeTheme(_settings.Theme);
|
||||
|
||||
|
@ -18,7 +18,7 @@ namespace Wox.Helper
|
||||
/// <summary>
|
||||
/// Drops a standard shadow to a WPF Window, even if the window isborderless. Only works with DWM (Vista and Seven).
|
||||
/// This method is much more efficient than setting AllowsTransparency to true and using the DropShadow effect,
|
||||
/// as AllowsTransparency involves a huge permormance issue (hardware acceleration is turned off for all the window).
|
||||
/// as AllowsTransparency involves a huge performance issue (hardware acceleration is turned off for all the window).
|
||||
/// </summary>
|
||||
/// <param name="window">Window to which the shadow will be applied</param>
|
||||
public static void DropShadowToWindow(Window window)
|
||||
|
@ -14,7 +14,7 @@ using System.Windows;
|
||||
using System.Windows.Threading;
|
||||
|
||||
// http://blogs.microsoft.co.il/arik/2010/05/28/wpf-single-instance-application/
|
||||
// modified to allow single instace restart
|
||||
// modified to allow single instance restart
|
||||
namespace Wox.Helper
|
||||
{
|
||||
internal enum WM
|
||||
@ -284,7 +284,7 @@ namespace Wox.Helper
|
||||
{
|
||||
|
||||
// The application was clickonce deployed
|
||||
// Clickonce deployed apps cannot recieve traditional commandline arguments
|
||||
// Clickonce deployed apps cannot receive traditional commandline arguments
|
||||
// As a workaround commandline arguments can be written to a shared location before
|
||||
// the app is launched and the app can obtain its commandline arguments from the
|
||||
// shared location
|
||||
@ -335,7 +335,7 @@ namespace Wox.Helper
|
||||
// Do an asynchronous call to ActivateFirstInstance function
|
||||
Application.Current.Dispatcher.Invoke(ActivateFirstInstance);
|
||||
}
|
||||
// Disconect client
|
||||
// Disconnect client
|
||||
pipeServer.Disconnect();
|
||||
}
|
||||
}
|
||||
|
@ -85,7 +85,7 @@
|
||||
Margin="{TemplateBinding Padding}"
|
||||
Grid.Row="0" />
|
||||
|
||||
<!--Scrollbar in thr rigth of ScrollViewer-->
|
||||
<!--Scrollbar in the right of ScrollViewer-->
|
||||
<ScrollBar x:Name="PART_VerticalScrollBar"
|
||||
AutomationProperties.AutomationId="VerticalScrollBar"
|
||||
Cursor="Arrow"
|
||||
|
@ -251,7 +251,7 @@ namespace Wox.ViewModel
|
||||
/// <summary>
|
||||
/// we need move cursor to end when we manually changed query
|
||||
/// but we don't want to move cursor to end when query is updated from TextBox.
|
||||
/// Also we don't want to force the results to change unless explicity told to.
|
||||
/// Also we don't want to force the results to change unless explicitly told to.
|
||||
/// </summary>
|
||||
/// <param name="queryText"></param>
|
||||
/// <param name="requery">Optional Parameter that if true, will automatically execute a query against the updated text</param>
|
||||
|
@ -222,7 +222,7 @@ namespace Wox.ViewModel
|
||||
/// <summary>
|
||||
/// Triggers the action on the selected context button
|
||||
/// </summary>
|
||||
/// <returns>False if there is nothing selected, oherwise true</returns>
|
||||
/// <returns>False if there is nothing selected, otherwise true</returns>
|
||||
public bool ExecuteSelectedContextButton()
|
||||
{
|
||||
if (HasSelectedContextButton())
|
||||
|
Loading…
Reference in New Issue
Block a user