From 5161bbe660a5dce00034ed4cec77f12a59d71a06 Mon Sep 17 00:00:00 2001 From: Jack251970 <1160210343@qq.com> Date: Wed, 23 Jul 2025 09:33:14 +0800 Subject: [PATCH 1/2] Remove unused comments & blank line --- .../Views/CalculatorSettings.xaml.cs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Plugins/Flow.Launcher.Plugin.Calculator/Views/CalculatorSettings.xaml.cs b/Plugins/Flow.Launcher.Plugin.Calculator/Views/CalculatorSettings.xaml.cs index 117a19b25..d0d79cd72 100644 --- a/Plugins/Flow.Launcher.Plugin.Calculator/Views/CalculatorSettings.xaml.cs +++ b/Plugins/Flow.Launcher.Plugin.Calculator/Views/CalculatorSettings.xaml.cs @@ -1,11 +1,8 @@ -using System.Windows.Controls; +using System.Windows.Controls; using Flow.Launcher.Plugin.Calculator.ViewModels; namespace Flow.Launcher.Plugin.Calculator.Views { - /// - /// Interaction logic for CalculatorSettings.xaml - /// public partial class CalculatorSettings : UserControl { private readonly SettingsViewModel _viewModel; @@ -19,5 +16,4 @@ namespace Flow.Launcher.Plugin.Calculator.Views InitializeComponent(); } } - } From 5ff8a5b1d59dd95ae8c0a79decb2714ee38e9cf8 Mon Sep 17 00:00:00 2001 From: Jack Ye <1160210343@qq.com> Date: Wed, 23 Jul 2025 09:59:09 +0800 Subject: [PATCH 2/2] Use compiled regex Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- Plugins/Flow.Launcher.Plugin.Calculator/Main.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Plugins/Flow.Launcher.Plugin.Calculator/Main.cs b/Plugins/Flow.Launcher.Plugin.Calculator/Main.cs index 2894c2159..b972394a4 100644 --- a/Plugins/Flow.Launcher.Plugin.Calculator/Main.cs +++ b/Plugins/Flow.Launcher.Plugin.Calculator/Main.cs @@ -24,7 +24,7 @@ namespace Flow.Launcher.Plugin.Calculator @"[ei]|[0-9]|0x[\da-fA-F]+|[\+\%\-\*\/\^\., ""]|[\(\)\|\!\[\]]" + @")+$", RegexOptions.Compiled); private static readonly Regex RegBrackets = new Regex(@"[\(\)\[\]]", RegexOptions.Compiled); - private static readonly Regex ThousandGroupRegex = new Regex(@"\B(?=(\d{3})+(?!\d))"); + private static readonly Regex ThousandGroupRegex = new Regex(@"\B(?=(\d{3})+(?!\d))", RegexOptions.Compiled); private static readonly Regex NumberRegex = new Regex(@"[\d\.,]+", RegexOptions.Compiled); private static Engine MagesEngine;