【发布时间】:2022-01-04 09:41:15
【问题描述】:
我在WIN-UI-3 中创建了一个应用程序,我正在尝试在win-ui-3 中获取UWP 生命周期hooks/events。尽管如此,我在其中找不到任何生命周期hooks/events。
这是我的.csprod 文件的样子:
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>WinExe</OutputType>
<TargetFramework>net5.0-windows10.0.19041.0</TargetFramework>
<TargetPlatformMinVersion>10.0.17763.0</TargetPlatformMinVersion>
<RootNamespace>App3</RootNamespace>
<ApplicationManifest>app.manifest</ApplicationManifest>
<Platforms>x86;x64;arm64</Platforms>
<RuntimeIdentifiers>win10-x86;win10-x64;win10-arm64</RuntimeIdentifiers>
<UseWinUI>true</UseWinUI>
</PropertyGroup>
<!-- Workaround for https://github.com/dotnet/sdk/issues/17890 -->
<PropertyGroup>
<NoWarn>CA1416, $(NoWarn)</NoWarn>
</PropertyGroup>
<ItemGroup>
<Manifest Include="$(ApplicationManifest)" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.ProjectReunion" Version="0.8.0" />
</ItemGroup>
</Project>
我实际上正在尝试创建一个活动监控应用程序,比如 hubstuff,但我不知道我是否走在正确的道路上。
【问题讨论】:
-
您能否澄清一下您正在寻找哪些钩子/事件,有什么例子吗? (也是从 Reunion 0.8 升级到 WindowsAppSdk 1.0 的时候了)