Skip to content

Commit

Permalink
🔧 Fix: Merge pull request #64 from Crequency/dev=main
Browse files Browse the repository at this point in the history
[Pull Request] 修复了拖动调色板滑块造成的意外错误
  • Loading branch information
Dynesshely authored Aug 12, 2022
2 parents d51834f + 2ff9d98 commit f1e80c5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
3 changes: 2 additions & 1 deletion KitX Dashboard/Helper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ public static void SaveConfig()

new Thread(() =>
{

BasicHelper.IO.FileHelper.WriteIn(ConfigFilePath,
JsonSerializer.Serialize(Program.GlobalConfig, options));
}).Start();
Expand Down Expand Up @@ -196,7 +197,7 @@ public static void InitEnvironment()
{
#region 检查 Catrol.Algorithm 库环境并安装环境
if (!Algorithm.Interop.Environment.CheckEnvironment())
new System.Threading.Thread(() =>
new Thread(() =>
{
Algorithm.Interop.Environment.InstallEnvironment();
}).Start();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,11 +86,7 @@ private void InitCommands()
internal Color2 ThemeColor
{
get => new((Application.Current.Resources["ThemePrimaryAccent"] as SolidColorBrush).Color);
set
{
nowColor = value;
SaveChanges();
}
set => nowColor = value;
}

/// <summary>
Expand Down Expand Up @@ -303,6 +299,7 @@ private void ColorConfirmed(object _)
var c = nowColor;
Application.Current.Resources["ThemePrimaryAccent"] =
new SolidColorBrush(new Color(c.A, c.R, c.G, c.B));
SaveChanges();
}

private void MicaOpacityConfirmed(object _) => SaveChanges();
Expand Down

0 comments on commit f1e80c5

Please sign in to comment.