[Build] Upgraded NetAnalyzers to 7.0.1 (#24792)

* upgraded NetAnalyzers to 7.0.1

* fix spellcheck

* Microsoft.CodeAnalysis.NetAnalyzers 7.0.1

* rebase and fix
This commit is contained in:
Davide Giacometti
2023-03-16 15:51:31 +01:00
committed by GitHub
parent 5492b4ae62
commit 5cbe9dd911
61 changed files with 124 additions and 107 deletions

View File

@@ -62,7 +62,7 @@ namespace Community.PowerToys.Run.Plugin.UnitConverter
return new Result
{
ContextData = result,
Title = result.ToString(),
Title = result.ToString(null),
IcoPath = _icon_path,
Score = 300,
SubTitle = string.Format(CultureInfo.CurrentCulture, Properties.Resources.copy_to_clipboard, result.QuantityInfo.Name),

View File

@@ -6,7 +6,7 @@ using System.Text.RegularExpressions;
namespace Community.PowerToys.Run.Plugin.VSCodeWorkspaces
{
internal class SystemPath
internal sealed class SystemPath
{
private static readonly Regex WindowsPath = new Regex(@"^([a-zA-Z]:)", RegexOptions.Compiled);

View File

@@ -439,9 +439,9 @@ namespace Microsoft.Plugin.Program.Programs
paths.Add(path);
}
if (_scaleFactors.ContainsKey(Package.Version))
if (_scaleFactors.TryGetValue(Package.Version, out List<int> factors))
{
foreach (var factor in _scaleFactors[Package.Version])
foreach (var factor in factors)
{
if (highContrast)
{

View File

@@ -17,7 +17,7 @@ namespace Microsoft.PowerToys.Run.Plugin.System.Components
/// <summary>
/// This class represents the informations for a network connection/interface
/// </summary>
internal class NetworkConnectionProperties
internal sealed class NetworkConnectionProperties
{
/// <summary>
/// Gets the name of the adapter

View File

@@ -4,7 +4,7 @@
namespace Microsoft.PowerToys.Run.Plugin.System.Components
{
internal class SystemPluginContext
internal sealed class SystemPluginContext
{
/// <summary>
/// Gets or sets the type of the result

View File

@@ -9,7 +9,7 @@ namespace Microsoft.PowerToys.Run.Plugin.WindowsSettings
/// <summary>
/// A windows setting
/// </summary>
internal class WindowsSetting
internal sealed class WindowsSetting
{
/// <summary>
/// Initializes a new instance of the <see cref="WindowsSetting"/> class.

View File

@@ -10,7 +10,7 @@ namespace Microsoft.PowerToys.Run.Plugin.WindowsSettings
/// <summary>
/// A class that contain all possible windows settings
/// </summary>
internal class WindowsSettings
internal sealed class WindowsSettings
{
/// <summary>
/// Initializes a new instance of the <see cref="WindowsSettings"/> class with an empty settings list.