Compare commits

...

27 Commits

Author SHA1 Message Date
Jeremy Sinclair
9fad5d023a [Deps] Update packages to .NET 9 Preview 5 2024-06-22 12:10:25 -04:00
Jeremy Sinclair
59553fa817 Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-06-22 12:00:56 -04:00
Jeremy Sinclair
bc91e0ce5a Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-06-22 12:00:23 -04:00
Jeremy Sinclair
e062627722 Set ManagedCommon, ManagedTelemetry, and Interop to be .NET 8 for CmdNotFound 2024-05-03 11:44:15 -04:00
Jeremy Sinclair
313152440d [Deps] Downgraded System.Management.Automation 2024-05-03 11:43:11 -04:00
Jeremy Sinclair
f8e7f6d919 Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-05-03 11:25:45 -04:00
Jeremy Sinclair
d1ad7ed7d7 [Hosts] Retarget TFM to .NET 9 2024-05-01 11:12:58 -04:00
Jeremy Sinclair
cae44b5514 [RegistryPreview] Retarget TFM to .NET 9 2024-05-01 11:12:27 -04:00
Jeremy Sinclair
da6f4fb53b [FancyZones] Retarget TFM to .NET 9 2024-05-01 11:12:11 -04:00
Jeremy Sinclair
ce2dd9ac69 [EnvironmentVariables] Retarget TFM to .NET 9 2024-05-01 11:11:53 -04:00
Jeremy Sinclair
f8c0263040 Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-05-01 11:06:12 -04:00
Jeremy Sinclair
c25a194a8c Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-04-30 12:55:20 -04:00
Jeremy Sinclair
db3522532e [Analyzers] Resolve the rest of CA2263 across solution 2024-04-24 12:33:23 -04:00
Jeremy Sinclair
058ee87885 Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-04-24 12:13:59 -04:00
Jeremy Sinclair
8c5f15f7ed [Analyzers][Settings] Resolve CA2263 2024-04-17 03:22:36 -04:00
Jeremy Sinclair
9d3ad1a4e6 [Deps] Update packages to .NET 9 Preview 3 2024-04-17 01:32:00 -04:00
Jeremy Sinclair
9438aa82b4 Merge branch 'dev/snickler/net9-upgrade' of https://github.com/microsoft/powertoys into dev/snickler/net9-upgrade 2024-04-17 01:26:03 -04:00
Jeremy Sinclair
ab199c0aca Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-04-17 01:24:58 -04:00
Jeremy Sinclair
c3a9d5f823 [Deps] Update DSC Schema Generator to target .NET 9 2024-04-07 18:16:51 -04:00
Jeremy Sinclair
4a2df22b31 Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-04-07 18:10:31 -04:00
Jeremy Sinclair
fefa2210f1 Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-03-27 14:03:25 -04:00
Jeremy Sinclair
7c602c789c Fix Directory.Build.props 2024-03-27 14:03:18 -04:00
Jeremy Sinclair
c64aa14963 Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-03-15 14:27:00 -04:00
Jeremy Sinclair
a7d91f012d [Deps] Updated packages to .NET 9 P2 2024-03-15 14:26:50 -04:00
Jeremy Sinclair
8d793a2761 Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-03-13 12:46:15 -04:00
Jeremy Sinclair
b872e1ca02 Merge remote-tracking branch 'origin/main' into dev/snickler/net9-upgrade 2024-02-17 17:19:04 -05:00
Jeremy Sinclair
5fa5a73b52 .NET 9 P1 changes 2024-02-13 17:13:18 -05:00
146 changed files with 515 additions and 184 deletions

View File

@@ -22,7 +22,7 @@
</PropertyGroup>
<PropertyGroup Condition="'$(MSBuildProjectExtension)' == '.csproj'">
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup>

View File

@@ -27,23 +27,24 @@
<PackageVersion Include="LazyCache" Version="2.4.0" />
<PackageVersion Include="Mages" Version="2.0.2" />
<PackageVersion Include="Markdig.Signed" Version="0.34.0" />
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="8.0.0" />
<PackageVersion Include="Microsoft.Data.Sqlite" Version="8.0.0" />
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="9.0.0-preview.24165.2" />
<PackageVersion Include="Microsoft.Data.Sqlite" Version="9.0.0-preview.5.24306.3" />
<PackageVersion Include="Microsoft.DotNet.UpgradeAssistant.Extensions.Default.Analyzers" Version="0.4.336902" />
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Logging" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Hosting" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.Hosting.WindowsServices" Version="8.0.0" />
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="Microsoft.Extensions.Logging" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="Microsoft.Extensions.Hosting" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="Microsoft.Extensions.Hosting.WindowsServices" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageVersion Include="Microsoft.Extensions.ObjectPool" Version="9.0.0-preview.5.24306.11" />
<PackageVersion Include="Microsoft.Toolkit.Uwp.Notifications" Version="7.1.2" />
<PackageVersion Include="Microsoft.Web.WebView2" Version="1.0.2365.46" />
<!-- Package Microsoft.Win32.SystemEvents added as a hack for being able to exclude the runtime assets so they don't conflict with 8.0.1. This is a dependency of System.Drawing.Common but the 8.0.1 version wasn't published to nuget. -->
<PackageVersion Include="Microsoft.Win32.SystemEvents" Version="8.0.0" />
<PackageVersion Include="Microsoft.Windows.Compatibility" Version="8.0.1" />
<PackageVersion Include="Microsoft.Win32.SystemEvents" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="Microsoft.Windows.Compatibility" Version="9.0.0-preview.5.24306.8" />
<PackageVersion Include="Microsoft.Windows.CsWin32" Version="0.2.46-beta" />
<!-- CsWinRT version needs to be set to have a WinRT.Runtime.dll at the same version contained inside the NET SDK we're currently building on CI. -->
<PackageVersion Include="Microsoft.Windows.CsWinRT" Version="2.0.4" />
<PackageVersion Include="Microsoft.Windows.CsWinRT" Version="2.0.7" />
<PackageVersion Include="Microsoft.Windows.SDK.BuildTools" Version="10.0.22621.2428" />
<PackageVersion Include="Microsoft.Windows.SDK.Contracts" Version="10.0.19041.1" />
<PackageVersion Include="Microsoft.WindowsAppSDK" Version="1.5.240428000" />
@@ -64,27 +65,27 @@
<PackageVersion Include="StreamJsonRpc" Version="2.14.24" />
<PackageVersion Include="StyleCop.Analyzers" Version="1.2.0-beta.556" />
<!-- Package System.CodeDom added as a hack for being able to exclude the runtime assets so they don't conflict with 8.0.1. This is a dependency of System.Management but the 8.0.1 version wasn't published to nuget. -->
<PackageVersion Include="System.CodeDom" Version="8.0.0" />
<PackageVersion Include="System.CodeDom" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="System.CommandLine" Version="2.0.0-beta4.22272.1" />
<PackageVersion Include="System.ComponentModel.Composition" Version="8.0.0" />
<PackageVersion Include="System.Configuration.ConfigurationManager" Version="8.0.0" />
<PackageVersion Include="System.Data.OleDb" Version="8.0.0" />
<PackageVersion Include="System.ComponentModel.Composition" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="System.Configuration.ConfigurationManager" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="System.Data.OleDb" Version="9.0.0-preview.5.24306.7" />
<!-- Package System.Data.SqlClient added to force it as a dependency of Microsoft.Windows.Compatibility to the latest version available at this time. -->
<PackageVersion Include="System.Data.SqlClient" Version="4.8.6" />
<!-- Package System.Diagnostics.EventLog added as a hack for being able to exclude the runtime assets so they don't conflict with 8.0.1. This is a dependency of System.Data.OleDb but the 8.0.1 version wasn't published to nuget. -->
<PackageVersion Include="System.Diagnostics.EventLog" Version="8.0.0" />
<PackageVersion Include="System.Diagnostics.EventLog" Version="9.0.0-preview.5.24306.7" />
<!-- Package System.Diagnostics.PerformanceCounter added as a hack for being able to exclude the runtime assets so they don't conflict with 8.0.1. This is a dependency of System.Data.OleDb but the 8.0.1 version wasn't published to nuget. -->
<PackageVersion Include="System.Diagnostics.PerformanceCounter" Version="8.0.0" />
<PackageVersion Include="System.Drawing.Common" Version="8.0.6" />
<PackageVersion Include="System.Diagnostics.PerformanceCounter" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="System.Drawing.Common" Version="9.0.0-preview.5.24306.5" />
<PackageVersion Include="System.IO.Abstractions" Version="17.2.3" />
<PackageVersion Include="System.IO.Abstractions.TestingHelpers" Version="17.2.3" />
<PackageVersion Include="System.Management" Version="8.0.0" />
<PackageVersion Include="System.Management" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="System.Reactive" Version="6.0.0-preview.9" />
<PackageVersion Include="System.Runtime.Caching" Version="8.0.0" />
<PackageVersion Include="System.Runtime.Caching" Version="9.0.0-preview.5.24306.7" />
<!-- Package System.Security.Cryptography.ProtectedData added as a hack for being able to exclude the runtime assets so they don't conflict with 8.0.1. This is a dependency of System.Data.OleDb but the 8.0.1 version wasn't published to nuget. -->
<PackageVersion Include="System.Security.Cryptography.ProtectedData" Version="8.0.0" />
<PackageVersion Include="System.ServiceProcess.ServiceController" Version="8.0.0" />
<PackageVersion Include="System.Text.Encoding.CodePages" Version="8.0.0" />
<PackageVersion Include="System.Security.Cryptography.ProtectedData" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="System.ServiceProcess.ServiceController" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="System.Text.Encoding.CodePages" Version="9.0.0-preview.5.24306.7" />
<PackageVersion Include="UnicodeInformation" Version="2.6.0" />
<PackageVersion Include="UnitsNet" Version="5.50.0" />
<PackageVersion Include="UTF.Unknown" Version="2.5.1" />
@@ -98,4 +99,4 @@
<PackageVersion Include="Microsoft.VariantAssignment.Client" Version="2.4.17140001" />
<PackageVersion Include="Microsoft.VariantAssignment.Contract" Version="3.0.16990001" />
</ItemGroup>
</Project>
</Project>

View File

@@ -3,6 +3,7 @@
<packageSources>
<clear />
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
</packageSources>
<packageSourceMapping>
<packageSource key="nuget.org">

View File

@@ -25,6 +25,9 @@ csharp_style_expression_bodied_local_functions = false:silent
csharp_style_throw_expression = true:suggestion
csharp_indent_labels = one_less_than_current
csharp_style_prefer_null_check_over_type_check = true:suggestion
csharp_using_directive_placement = outside_namespace:silent
csharp_style_prefer_top_level_statements = true:silent
csharp_style_prefer_primary_constructors = true:suggestion
[*.{cs,vb}]
#### Naming styles ####
@@ -96,4 +99,5 @@ end_of_line = crlf
dotnet_diagnostic.IDE0065.severity = none
# IDE0009: Add this or Me qualification
dotnet_diagnostic.IDE0009.severity = none
dotnet_diagnostic.IDE0009.severity = none
dotnet_diagnostic.CA1859.severity = none

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ImplicitUsings>enable</ImplicitUsings>
@@ -25,5 +25,4 @@
<Compile Remove=".\$(MockDirectory)\Client\*.cs" />
<Compile Remove=".\$(MockDirectory)\Contract\*.cs" />
</ItemGroup>
</Project>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<RuntimeIdentifiers>win-x64;win-arm64</RuntimeIdentifiers>
<UseWPF>true</UseWPF>
<AssemblyName>PowerToys.Common.UI</AssemblyName>
@@ -16,5 +16,12 @@
<ProjectReference Include="..\ManagedCommon\ManagedCommon.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Update="Microsoft.CodeAnalysis.NetAnalyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
</Project>

View File

@@ -132,7 +132,7 @@ namespace Common.UI
else
{
string baseColor = ControlzEx.Theming.WindowsThemeHelper.GetWindowsBaseColor();
ChangeTheme((Theme)Enum.Parse(typeof(Theme), baseColor));
ChangeTheme(Enum.Parse<Theme>(baseColor));
}
}
else if (theme == Theme.HighContrastOne)

View File

@@ -3,7 +3,7 @@
<Import Project="..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<RuntimeIdentifiers>win-x64;win-arm64</RuntimeIdentifiers>
<Version>$(Version).0</Version>
<Authors>Microsoft Corporation</Authors>
@@ -44,4 +44,11 @@
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>
<ItemGroup>
<PackageReference Update="Microsoft.CodeAnalysis.NetAnalyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
</Project>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ImplicitUsings>enable</ImplicitUsings>
@@ -27,4 +27,11 @@
</ProjectReference>
</ItemGroup>
<ItemGroup>
<PackageReference Update="Microsoft.CodeAnalysis.NetAnalyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
</Project>

View File

@@ -37,4 +37,11 @@
<Generator>PublicResXFileCodeGenerator</Generator>
</EmbeddedResource>
</ItemGroup>
<ItemGroup>
<PackageReference Update="Microsoft.CodeAnalysis.NetAnalyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
</Project>

View File

@@ -50,7 +50,7 @@ namespace ManagedCommon
internal static int Size
{
get { return Marshal.SizeOf(typeof(INPUT)); }
get { return Marshal.SizeOf<INPUT>(); }
}
}

View File

@@ -15,4 +15,11 @@
<Compile Include="..\..\Telemetry\TelemetryBase.cs" Link="TelemetryBase.cs" />
</ItemGroup>
<ItemGroup>
<PackageReference Update="Microsoft.CodeAnalysis.NetAnalyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
</Project>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<IsPackable>false</IsPackable>
<RuntimeIdentifiers>win-x64;win-arm64</RuntimeIdentifiers>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\Version.props" />
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<RootNamespace>PowerToys.Settings.DSC.Schema</RootNamespace>
<ApplicationManifest>app.manifest</ApplicationManifest>
<RuntimeIdentifiers>win-x64;win-arm64</RuntimeIdentifiers>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<OutputType>WinExe</OutputType>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<RootNamespace>EnvironmentVariables</RootNamespace>

View File

@@ -3,7 +3,7 @@
<PropertyGroup>
<OutputType>Library</OutputType>
<TargetFramework>net8.0-windows10.0.20348</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348</TargetFramework>
<RootNamespace>EnvironmentVariablesUILib</RootNamespace>
<UseWinUI>true</UseWinUI>
<EnablePreviewMsixTooling>true</EnablePreviewMsixTooling>

View File

@@ -31,7 +31,7 @@
<Keyword>Win32Proj</Keyword>
<ProjectGuid>{c604b37e-9d0e-4484-8778-e8b31b0e1b3a}</ProjectGuid>
<RootNamespace>FileLocksmithLibInterop</RootNamespace>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<OutDir>..\..\..\..\$(Platform)\$(Configuration)\WinUI3Apps\</OutDir>
<TargetName>PowerToys.FileLocksmithLib.Interop</TargetName>
</PropertyGroup>

View File

@@ -5,7 +5,7 @@
<AssemblyTitle>PowerToys.FileLocksmith</AssemblyTitle>
<AssemblyDescription>PowerToys File Locksmith</AssemblyDescription>
<OutputType>WinExe</OutputType>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<OutputPath>..\..\..\..\$(Platform)\$(Configuration)\WinUI3Apps</OutputPath>

View File

@@ -5,7 +5,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<PublishProtocol>FileSystem</PublishProtocol>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<PublishDir>$(PowerToysRoot)\$(Platform)\$(Configuration)\WinUI3Apps</PublishDir>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<RuntimeIdentifiers>win-x64;win-arm64</RuntimeIdentifiers>

View File

@@ -3,7 +3,7 @@
<PropertyGroup>
<OutputType>WinExe</OutputType>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<RootNamespace>Hosts</RootNamespace>

View File

@@ -3,7 +3,7 @@
<PropertyGroup>
<OutputType>Library</OutputType>
<TargetFramework>net8.0-windows10.0.20348</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348</TargetFramework>
<RootNamespace>HostsUILib</RootNamespace>
<UseWinUI>true</UseWinUI>
<EnablePreviewMsixTooling>true</EnablePreviewMsixTooling>

View File

@@ -5,7 +5,7 @@
<AssemblyTitle>PowerToys.MeasureTool</AssemblyTitle>
<AssemblyDescription>PowerToys MeasureTool</AssemblyDescription>
<OutputType>WinExe</OutputType>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<OutputPath>..\..\..\..\$(Platform)\$(Configuration)\WinUI3Apps</OutputPath>
<RootNamespace>PowerToys.MeasureToolUI</RootNamespace>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectGuid>{D9C5DE64-6849-4278-91AD-9660AECF2876}</ProjectGuid>

View File

@@ -44,7 +44,7 @@ internal static partial class Core
}
public static int Size =>
Marshal.SizeOf(typeof(CRECT));
Marshal.SizeOf<CRECT>();
public override string ToString()
{

View File

@@ -45,7 +45,7 @@ internal static partial class Core
}
public static int Size =>
Marshal.SizeOf(typeof(POINT));
Marshal.SizeOf<POINT>();
public override string ToString()
{

View File

@@ -44,7 +44,7 @@ internal static partial class Core
}
public static int Size =>
Marshal.SizeOf(typeof(RECT));
Marshal.SizeOf<RECT>();
public override string ToString()
{

View File

@@ -34,6 +34,6 @@ internal static partial class User32
}
public static int Size =>
Marshal.SizeOf(typeof(MONITORINFO));
Marshal.SizeOf<MONITORINFO>();
}
}

View File

@@ -30,7 +30,7 @@ internal static partial class User32
}
public static int Size =>
Marshal.SizeOf(typeof(INPUT));
Marshal.SizeOf<INPUT>();
[StructLayout(LayoutKind.Explicit)]
public readonly struct DUMMYUNIONNAME

View File

@@ -32,7 +32,7 @@
<OutputType>WinExe</OutputType>
<RootNamespace>MouseJumpUI</RootNamespace>
<AssemblyName>PowerToys.MouseJumpUI</AssemblyName>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>

View File

@@ -70,7 +70,7 @@ namespace MouseWithoutBorders.Class
{
if (Setting.Values.DrawMouse)
{
ci.cbSize = Marshal.SizeOf(typeof(NativeMethods.CURSORINFO));
ci.cbSize = Marshal.SizeOf<NativeMethods.CURSORINFO>();
_ = NativeMethods.GetCursorInfo(out ci);
// The cursor is hidden or suppressed.q

View File

@@ -85,7 +85,7 @@ namespace MouseWithoutBorders.Class
_ = f.Read(buf, 0, buf.Length);
Marshal.Copy(buf, 0, p, buf.Length);
bitmapFileHeader = (BITMAPFILEHEADER)Marshal.PtrToStructure(p, typeof(BITMAPFILEHEADER));
bitmapFileHeader = Marshal.PtrToStructure<BITMAPFILEHEADER>(p);
Marshal.FreeHGlobal(p);
BITMAPINFOHEADER bitmapInfoHeader;
@@ -100,7 +100,7 @@ namespace MouseWithoutBorders.Class
_ = f.Read(buf, 0, buf.Length);
Marshal.Copy(buf, 0, p, buf.Length);
bitmapInfoHeader = (BITMAPINFOHEADER)Marshal.PtrToStructure(p, typeof(BITMAPINFOHEADER));
bitmapInfoHeader = Marshal.PtrToStructure<BITMAPINFOHEADER>(p);
Marshal.FreeHGlobal(p);
if (bitmapFileHeader.BfType != 0x4D42 || bitmapFileHeader.BfSize != fs || bitmapFileHeader.BfOffBits != BITMAP_FILE_HEADER_SIZE + BITMAP_INFO_HEADER_SIZE ||

View File

@@ -858,7 +858,7 @@ namespace MouseWithoutBorders.Class
public MEMORYSTATUSEX()
{
dwLength = (uint)Marshal.SizeOf(typeof(MEMORYSTATUSEX));
dwLength = (uint)Marshal.SizeOf<MEMORYSTATUSEX>();
}
}

View File

@@ -437,7 +437,7 @@ namespace MouseWithoutBorders
// Simulate input to help bring to the foreground, as it doesn't seem to work in every case otherwise.
NativeMethods.INPUT input = new NativeMethods.INPUT { type = (int)NativeMethods.InputType.INPUT_MOUSE, mi = { } };
NativeMethods.INPUT[] inputs = new NativeMethods.INPUT[] { input };
_ = NativeMethods.SendInput(1, inputs, Marshal.SizeOf(typeof(NativeMethods.INPUT)));
_ = NativeMethods.SendInput(1, inputs, Marshal.SizeOf<NativeMethods.INPUT>());
m.Result = SetForeGround() ? new IntPtr(1) : IntPtr.Zero;
break;

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<OutputType>WinExe</OutputType>

View File

@@ -781,7 +781,7 @@ namespace MouseWithoutBorders
public MEMORYSTATUSEX()
{
this.dwLength = (uint)Marshal.SizeOf(typeof(NativeMethods.MEMORYSTATUSEX));
this.dwLength = (uint)Marshal.SizeOf<MEMORYSTATUSEX>();
}
}

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<OutputType>WinExe</OutputType>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ImplicitUsings>true</ImplicitUsings>

View File

@@ -127,7 +127,7 @@ public static class OSInterop
[StructLayout(LayoutKind.Sequential, Pack = 4, CharSet = CharSet.Auto)]
public class MONITORINFOEX
{
public int CbSize { get; set; } = Marshal.SizeOf(typeof(MONITORINFOEX));
public int CbSize { get; set; } = Marshal.SizeOf<MONITORINFOEX>();
public RECT RcMonitor { get; set; }

View File

@@ -98,7 +98,7 @@ internal sealed class GlobalKeyboardHook : IDisposable
var wparamTyped = wParam.ToInt32();
if (Enum.IsDefined(typeof(KeyboardState), wparamTyped))
{
object? o = Marshal.PtrToStructure(lParam, typeof(LowLevelKeyboardInputEvent));
object? o = Marshal.PtrToStructure<LowLevelKeyboardInputEvent>(lParam);
if (o is not null)
{
LowLevelKeyboardInputEvent p = (LowLevelKeyboardInputEvent)o;

View File

@@ -28,7 +28,7 @@
<PackageIcon>PowerOCRLogo.png</PackageIcon>
<RootNamespace>PowerOCR</RootNamespace>
<AssemblyName>PowerToys.PowerOCR</AssemblyName>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectTypeGuids>{2150E333-8FDC-42A3-9474-1A3956D46DE8}</ProjectTypeGuids>
@@ -77,4 +77,11 @@
<SubType>Designer</SubType>
</EmbeddedResource>
</ItemGroup>
<ItemGroup>
<PackageReference Update="Microsoft.CodeAnalysis.NetAnalyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
</Project>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<OutputType>WinExe</OutputType>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<RuntimeIdentifiers>win-x64;win-arm64</RuntimeIdentifiers>

View File

@@ -0,0 +1,18 @@
// Copyright (c) Microsoft Corporation
// The Microsoft Corporation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System.Text.Json.Serialization;
using Awake.Core.Models;
using Microsoft.PowerToys.Settings.UI.Library;
namespace Awake.Core
{
[JsonSourceGenerationOptions(WriteIndented = true)]
[JsonSerializable(typeof(AwakeSettings))]
[JsonSerializable(typeof(SystemPowerCapabilities))]
internal sealed partial class SourceGenerationContext : JsonSerializerContext
{
}
}

View File

@@ -30,7 +30,7 @@ namespace Awake.Core
public bool PreFilterMessage(ref Message m)
{
var trayCommandsSize = Enum.GetNames(typeof(TrayCommands)).Length;
var trayCommandsSize = Enum.GetNames<TrayCommands>().Length;
switch (m.Msg)
{

View File

@@ -25,7 +25,7 @@
<OutputType>WinExe</OutputType>
<RootNamespace>ColorPicker</RootNamespace>
<AssemblyName>PowerToys.ColorPickerUI</AssemblyName>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>

View File

@@ -98,7 +98,7 @@ namespace ColorPicker.Keyboard
var wparamTyped = wParam.ToInt32();
if (Enum.IsDefined(typeof(KeyboardState), wparamTyped))
{
object o = Marshal.PtrToStructure(lParam, typeof(LowLevelKeyboardInputEvent));
object o = Marshal.PtrToStructure<LowLevelKeyboardInputEvent>(lParam);
LowLevelKeyboardInputEvent p = (LowLevelKeyboardInputEvent)o;
var eventArguments = new GlobalKeyboardHookEventArgs(p, (KeyboardState)wparamTyped);

View File

@@ -121,7 +121,7 @@ namespace ColorPicker.Mouse
{
if (nCode >= 0)
{
MSLLHOOKSTRUCT mouseHookStruct = (MSLLHOOKSTRUCT)Marshal.PtrToStructure(lParam, typeof(MSLLHOOKSTRUCT));
MSLLHOOKSTRUCT mouseHookStruct = Marshal.PtrToStructure<MSLLHOOKSTRUCT>(lParam);
if (wParam.ToInt32() == WM_LBUTTONDOWN)
{
if (MouseDown != null)

View File

@@ -133,7 +133,7 @@ namespace ColorPicker
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Auto, Pack = 4)]
internal class MonitorInfoEx
{
public int cbSize = Marshal.SizeOf(typeof(MonitorInfoEx));
public int cbSize = Marshal.SizeOf<MonitorInfoEx>();
public Rect rcMonitor;
public Rect rcWork;
public int dwFlags;

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectGuid>{090CD7B7-3B0C-4D1D-BC98-83EB5D799BC1}</ProjectGuid>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<RuntimeIdentifiers>win-x64;win-arm64</RuntimeIdentifiers>
<Version>$(Version).0</Version>
<Authors>Microsoft Corporation</Authors>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectGuid>{FE38FC07-1C05-4B57-ADA3-2FE2F53C6A52}</ProjectGuid>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectGuid>{3A9A791E-94A9-49F8-8401-C11CE288D5FB}</ProjectGuid>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ImplicitUsings>enable</ImplicitUsings>

View File

@@ -25,7 +25,7 @@
<PropertyGroup>
<ProjectGuid>{5CCC8468-DEC8-4D36-99D4-5C891BEBD481}</ProjectGuid>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>

View File

@@ -11,7 +11,7 @@ namespace FancyZonesEditor.Models
{
public class DefaultLayoutsModel : INotifyPropertyChanged
{
private static int Count { get; } = Enum.GetValues(typeof(MonitorConfigurationType)).Length;
private static int Count { get; } = Enum.GetValues<MonitorConfigurationType>().Length;
public Dictionary<MonitorConfigurationType, LayoutModel> Layouts { get; } = new Dictionary<MonitorConfigurationType, LayoutModel>(Count);

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectGuid>{E0CC7526-D85E-43AC-844F-D5DF0D2F5AB8}</ProjectGuid>

View File

@@ -24,7 +24,7 @@
<OutputType>WinExe</OutputType>
<RootNamespace>ImageResizer</RootNamespace>
<AssemblyName>PowerToys.ImageResizer</AssemblyName>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>

View File

@@ -19,7 +19,7 @@ namespace ImageResizer.Properties
continue;
}
var result = (T)JsonSerializer.Deserialize(ref reader, typeof(T), options);
var result = JsonSerializer.Deserialize<T>(ref reader, options);
reader.Read();
return result;
}
@@ -37,7 +37,7 @@ namespace ImageResizer.Properties
writer.WriteStartObject();
writer.WritePropertyName("value");
JsonSerializer.Serialize(writer, value, typeof(T), options);
JsonSerializer.Serialize(writer, value, options);
writer.WriteEndObject();
}

View File

@@ -57,9 +57,9 @@ namespace ImageResizer.ViewModels
public Settings Settings { get; }
public IEnumerable<ResizeFit> ResizeFitValues => Enum.GetValues(typeof(ResizeFit)).Cast<ResizeFit>();
public IEnumerable<ResizeFit> ResizeFitValues => Enum.GetValues<ResizeFit>().Cast<ResizeFit>();
public IEnumerable<ResizeUnit> ResizeUnitValues => Enum.GetValues(typeof(ResizeUnit)).Cast<ResizeUnit>();
public IEnumerable<ResizeUnit> ResizeUnitValues => Enum.GetValues<ResizeUnit>().Cast<ResizeUnit>();
public ICommand ResizeCommand { get; }

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<IsPackable>false</IsPackable>
</PropertyGroup>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{BB23A474-5058-4F75-8FA3-5FE3DE53CDF4}</ProjectGuid>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Community.PowerToys.Run.Plugin.UnitConverter</RootNamespace>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{4D971245-7A70-41D5-BAA0-DDB5684CAF51}</ProjectGuid>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Community.PowerToys.Run.Plugin.VSCodeWorkspaces</RootNamespace>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<Nullable>enable</Nullable>
<IsPackable>false</IsPackable>
</PropertyGroup>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{D095BE44-1F2E-463E-A494-121892A75EA2}</ProjectGuid>
<UseWPF>true</UseWPF>
<Version>$(Version).0</Version>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{9F94B303-5E21-4364-9362-64426F8DB932}</ProjectGuid>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Community.PowerToys.Run.Plugin.WebSearch</RootNamespace>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<IsPackable>false</IsPackable>
<RootNamespace>Microsoft.Plugin.Folder.UnitTests</RootNamespace>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{787B8AA6-CA93-4C84-96FE-DF31110AD1C4}</ProjectGuid>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Microsoft.Plugin.Folder</RootNamespace>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{F8B870EB-D5F5-45BA-9CF7-A5C459818820}</ProjectGuid>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Microsoft.Plugin.Indexer</RootNamespace>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<IsPackable>false</IsPackable>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectGuid>{FDB3555B-58EF-4AE6-B5F1-904719637AB4}</ProjectGuid>

View File

@@ -319,7 +319,7 @@ namespace Microsoft.Plugin.Program.Utils
public static AppExecutionAliasMetadata FromPersistedRepresentationIntPtr(IntPtr reparseDataBufferPtr, AppExecutionAliasReparseTagBufferLayoutVersion version)
{
var dataOffset = Marshal.SizeOf(typeof(AppExecutionAliasReparseTagHeader));
var dataOffset = Marshal.SizeOf<AppExecutionAliasReparseTagHeader>();
IntPtr dataBufferPtr = reparseDataBufferPtr + dataOffset;
string packageFullName = null;

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{C21BFF9C-2C99-4B5F-B7C9-A5E6DDDB37B0}</ProjectGuid>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Microsoft.Plugin.Shell</RootNamespace>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<IsPackable>false</IsPackable>
<RootNamespace>Microsoft.Plugin.Uri.UnitTests</RootNamespace>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{03276a39-d4e9-417c-8ffd-200b0ee5e871}</ProjectGuid>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Microsoft.Plugin.Uri</RootNamespace>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<IsPackable>false</IsPackable>
<RootNamespace>Microsoft.Plugin.WindowWalker.UnitTests</RootNamespace>
</PropertyGroup>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{74F1B9ED-F59C-4FE7-B473-7B453E30837E}</ProjectGuid>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Microsoft.Plugin.WindowWalker</RootNamespace>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<IsPackable>false</IsPackable>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.Calculator.UnitTests</RootNamespace>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{59BD9891-3837-438A-958D-ADC7F91F6F7E}</ProjectGuid>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.Calculator</RootNamespace>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<ProjectGuid>{212AD910-8488-4036-BE20-326931B75FB2}</ProjectGuid>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.OneNote</RootNamespace>
<AssemblyName>Microsoft.PowerToys.Run.Plugin.OneNote</AssemblyName>
<ImplicitUsings>enable</ImplicitUsings>

View File

@@ -3,7 +3,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.PowerToys</RootNamespace>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<Nullable>enable</Nullable>
<IsPackable>false</IsPackable>
</PropertyGroup>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.Registry</RootNamespace>
<AssemblyName>Microsoft.PowerToys.Run.Plugin.Registry</AssemblyName>
<Version>$(Version).0</Version>

View File

@@ -3,7 +3,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.Service</RootNamespace>
<AssemblyName>Microsoft.PowerToys.Run.Plugin.Service</AssemblyName>
<Version>$(Version).0</Version>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<IsPackable>false</IsPackable>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.System.UnitTests</RootNamespace>
</PropertyGroup>

View File

@@ -3,7 +3,7 @@
<PropertyGroup>
<OutputType>Library</OutputType>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.System</RootNamespace>
<AssemblyName>Microsoft.PowerToys.Run.Plugin.System</AssemblyName>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<IsPackable>false</IsPackable>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.TimeDate.UnitTests</RootNamespace>
</PropertyGroup>

View File

@@ -3,7 +3,7 @@
<PropertyGroup>
<OutputType>Library</OutputType>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.TimeDate</RootNamespace>
<AssemblyName>Microsoft.PowerToys.Run.Plugin.TimeDate</AssemblyName>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{5043CECE-E6A7-4867-9CBE-02D27D83747A}</ProjectGuid>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.WindowsSettings</RootNamespace>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>

View File

@@ -3,7 +3,7 @@
<Import Project="..\..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<RootNamespace>Microsoft.PowerToys.Run.Plugin.WindowsTerminal</RootNamespace>

View File

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<Version>$(Version).0</Version>

View File

@@ -87,7 +87,7 @@ namespace PowerLauncher.Helper
for (int i = 0; i < numArgs; i++)
{
IntPtr currArg = Marshal.ReadIntPtr(argv, i * Marshal.SizeOf(typeof(IntPtr)));
IntPtr currArg = Marshal.ReadIntPtr(argv, i * Marshal.SizeOf<nint>());
result[i] = Marshal.PtrToStringUni(currArg);
}

View File

@@ -50,7 +50,7 @@ namespace PowerLauncher.Helper
public static int Size
{
get { return Marshal.SizeOf(typeof(INPUT)); }
get { return Marshal.SizeOf<INPUT>(); }
}
}

View File

@@ -3,7 +3,7 @@
<PropertyGroup>
<AssemblyTitle>PowerToys.Run</AssemblyTitle>
<OutputType>WinExe</OutputType>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<UseWPF>true</UseWPF>

View File

@@ -5,7 +5,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<PublishProtocol>FileSystem</PublishProtocol>
<TargetFramework>net8.0-windows10.0.20348.0</TargetFramework>
<TargetFramework>net9.0-windows10.0.20348.0</TargetFramework>
<TargetPlatformMinVersion>10.0.19041.0</TargetPlatformMinVersion>
<SupportedOSPlatformVersion>10.0.19041.0</SupportedOSPlatformVersion>
<PublishDir>$(PowerToysRoot)\$(Platform)\$(Configuration)</PublishDir>

View File

@@ -120,7 +120,7 @@ namespace Wox.Infrastructure.Hotkey
{
try
{
CharKey = (Key)Enum.Parse(typeof(Key), charKey);
CharKey = Enum.Parse<Key>(charKey);
}
catch (ArgumentException)
{

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{4FD29318-A8AB-4D8F-AA47-60BC241B8DA3}</ProjectGuid>
<OutputType>Library</OutputType>
<UseWpf>true</UseWpf>

View File

@@ -2,7 +2,7 @@
<Import Project="..\..\..\Version.props" />
<PropertyGroup>
<TargetFramework>net8.0-windows</TargetFramework>
<TargetFramework>net9.0-windows</TargetFramework>
<ProjectGuid>{8451ECDD-2EA4-4966-BB0A-7BBC40138E80}</ProjectGuid>
<UseWPF>true</UseWPF>
<OutputType>Library</OutputType>

View File

@@ -41,7 +41,7 @@ namespace Wox.Test
{
var listToReturn = new List<int>();
Enum.GetValues(typeof(StringMatcher.SearchPrecisionScore))
Enum.GetValues<StringMatcher.SearchPrecisionScore>()
.Cast<StringMatcher.SearchPrecisionScore>()
.ToList()
.ForEach(x => listToReturn.Add((int)x));

Some files were not shown because too many files have changed in this diff Show More