/
githubmirror
/
PowerToys
Обзор
Документация
Войти
/
githubmirror
/
PowerToys
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
src/modules/keyboardmanager/KeyboardManagerEditorUI/KeyboardManagerEditorUI.csproj
103 строки
5 KB
moooyo
[Keyboard Manager] Build the WinUI 3 editor self-contained to fix launch crash (0xC0000409) (#49524)
28 июл 2026, 11:00
Не верифицирован
28 июл 2026, 11:00
130a779
Код
Авторство
О чём код?
<Project Sdk="Microsoft.NET.Sdk"> <!-- Look at Directory.Build.props in root for common stuff as well --> <Import Project="$(RepoRoot)src\Common.Dotnet.CsWinRT.props" /> <Import Project="$(RepoRoot)src\Common.SelfContained.props" /> <PropertyGroup> <OutputType>WinExe</OutputType> <RootNamespace>KeyboardManagerEditorUI</RootNamespace> <ApplicationManifest>app.manifest</ApplicationManifest> <UseWinUI>true</UseWinUI> <EnablePreviewMsixTooling>true</EnablePreviewMsixTooling> <Nullable>enable</Nullable> <WindowsPackageType>None</WindowsPackageType> <AllowUnsafeBlocks>True</AllowUnsafeBlocks> <ApplicationIcon>Assets\KeyboardManagerEditor\Keyboard.ico</ApplicationIcon> <AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath> <AppendRuntimeIdentifierToOutputPath>false</AppendRuntimeIdentifierToOutputPath> <!-- Required alongside WindowsPackageType=None. Without it the Windows App SDK targets compile in the MddBootstrap auto-initializer, and this app binds to the machine-wide Microsoft.WindowsAppRuntime framework package instead of the app-local payload PowerToys ships in WinUI3Apps. Note that Common.SelfContained.props above sets the unrelated .NET <SelfContained> property. See #49399. --> <WindowsAppSDKSelfContained>true</WindowsAppSDKSelfContained> <AssemblyName>PowerToys.KeyboardManagerEditorUI</AssemblyName> <OutputPath>..\..\..\..\$(Platform)\$(Configuration)\WinUI3Apps</OutputPath> <!-- MRT from windows app sdk will search for a pri file with the same name of the module before defaulting to resources.pri --> <ProjectPriFileName>PowerToys.KeyboardManagerEditorUI.pri</ProjectPriFileName> </PropertyGroup> <PropertyGroup> <EnableDefaultXamlItems>true</EnableDefaultXamlItems> <EnableXamlJitOptimization>true</EnableXamlJitOptimization> </PropertyGroup> <ItemGroup> <None Remove="Assets\KeyboardManagerEditor\Keyboard.ico" /> <None Remove="Styles\Colors.xaml" /> </ItemGroup> <ItemGroup> <Page Remove="KeyboardManagerEditorXAML\App.xaml" /> </ItemGroup> <ItemGroup> <ApplicationDefinition Include="KeyboardManagerEditorXAML\App.xaml" /> </ItemGroup> <ItemGroup> <Manifest Include="$(ApplicationManifest)" /> </ItemGroup> <!-- Defining the "Msix" ProjectCapability here allows the Single-project MSIX Packaging Tools extension to be activated for this project even if the Windows App SDK Nuget package has not yet been restored. --> <ItemGroup Condition="'$(DisableMsixProjectCapabilityAddedByProject)'!='true' and '$(EnablePreviewMsixTooling)'=='true'"> <ProjectCapability Include="Msix" /> </ItemGroup> <ItemGroup> <PackageReference Include="CommunityToolkit.Common" /> <PackageReference Include="CommunityToolkit.WinUI.Controls.Primitives" /> <PackageReference Include="CommunityToolkit.WinUI.Converters" /> <PackageReference Include="Microsoft.Windows.SDK.BuildTools" /> <PackageReference Include="Microsoft.WindowsAppSDK" /> <PackageReference Include="WinUIEx" /> <!-- This line forces the WebView2 version used by Windows App SDK to be the one we expect from Directory.Packages.props . --> <PackageReference Include="Microsoft.Web.WebView2" /> </ItemGroup> <ItemGroup> <ProjectReference Include="..\..\..\common\ManagedCommon\ManagedCommon.csproj" /> <ProjectReference Include="..\..\..\settings-ui\Settings.UI.Library\Settings.UI.Library.csproj" /> <ProjectReference Include="..\..\..\common\Common.UI\Common.UI.csproj" /> <ProjectReference Include="..\..\..\common\Common.UI.Controls\Common.UI.Controls.csproj" /> <ProjectReference Include="..\KeyboardManagerEditorLibraryWrapper\KeyboardManagerEditorLibraryWrapper.vcxproj" /> </ItemGroup> <ItemGroup> <Content Include="Assets\KeyboardManagerEditor\Keyboard.ico"> <CopyToOutputDirectory>Always</CopyToOutputDirectory> </Content> <Content Update="Assets\KeyboardManagerEditor\Square150x150Logo.png"> <CopyToOutputDirectory>Always</CopyToOutputDirectory> </Content> </ItemGroup> <ItemGroup> <Page Update="Styles\Colors.xaml"> <Generator>MSBuild:Compile</Generator> </Page> </ItemGroup> <ItemGroup> <Page Update="Styles\Button.xaml"> <Generator>MSBuild:Compile</Generator> </Page> </ItemGroup> <!-- Defining the "HasPackageAndPublishMenuAddedByProject" property here allows the Solution Explorer "Package and Publish" context menu entry to be enabled for this project even if the Windows App SDK Nuget package has not yet been restored. --> <PropertyGroup Condition="'$(DisableHasPackageAndPublishMenuAddedByProject)'!='true' and '$(EnablePreviewMsixTooling)'=='true'"> <HasPackageAndPublishMenu>true</HasPackageAndPublishMenu> </PropertyGroup> </Project>