Merge pull request #2 from microsoft/master

Update with latest changes
This commit is contained in:
Den Delimarsky
2021-04-20 07:28:00 -07:00
committed by GitHub
150 changed files with 2706 additions and 2193 deletions

View File

@@ -9,7 +9,8 @@ namespace Microsoft.PowerToys.Settings.UI.Library
{
public class FZConfigProperties
{
public static readonly HotkeySettings DefaultHotkeyValue = new HotkeySettings(true, false, false, false, 0xc0);
// in reality, this file needs to be kept in sync currently with src\modules\fancyzones\lib\Settings.h
public static readonly HotkeySettings DefaultHotkeyValue = new HotkeySettings(true, false, false, true, 0xc0);
public FZConfigProperties()
{

View File

@@ -45,7 +45,7 @@
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="System.IO.Abstractions" Version="12.2.5" />
<PackageReference Include="System.Text.Json" Version="5.0.1" />
<PackageReference Include="System.Text.Json" Version="5.0.2" />
<PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers">
<Version>3.3.0</Version>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>

View File

@@ -29,8 +29,10 @@ namespace Microsoft.PowerToys.Settings.UI.Library.ViewModels
private const string EditShortcutActionName = "EditShortcut";
private const string EditShortcutActionValue = "Open Edit Shortcut Window";
private const string JsonFileType = ".json";
private const string ProfileFileMutexName = "PowerToys.KeyboardManager.ConfigMutex";
private const int ProfileFileMutexWaitTimeoutMilliseconds = 1000;
private static string ConfigFileMutexName => interop.Constants.KeyboardManagerConfigFileMutexName();
private const int ConfigFileMutexWaitTimeoutMilliseconds = 1000;
public KeyboardManagerSettings Settings { get; set; }
@@ -203,9 +205,9 @@ namespace Microsoft.PowerToys.Settings.UI.Library.ViewModels
try
{
using (var profileFileMutex = Mutex.OpenExisting(ProfileFileMutexName))
using (var profileFileMutex = Mutex.OpenExisting(ConfigFileMutexName))
{
if (profileFileMutex.WaitOne(ProfileFileMutexWaitTimeoutMilliseconds))
if (profileFileMutex.WaitOne(ConfigFileMutexWaitTimeoutMilliseconds))
{
// update the UI element here.
try