mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-07 11:46:30 +02:00
@@ -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()
|
||||
{
|
||||
|
||||
@@ -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>
|
||||
|
||||
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user