- ProcessFailed: only BrowserProcessExited (teardown) and RenderProcessExited (about:blank, recreate on the next Open) fail the panel, as WebView2's docs describe the kinds; GPU, utility, sandbox, PPAPI and frame-only renderer exits are logged only. RenderProcessUnresponsive fails it at 3 reports within 30 s. The handler acts on the panel being served now. - Fail decides "ignored" under the lock first and hides the panel only when the failure is live: a late failure for a superseded handle no longer hides the newer panel. - The panel thread's finally restarts the thread when an Open is still queued and the host is not shutting down; _threadDone goes false only after StartStaThread returns. - Show takes the foreground only when a window of this process (or of this panel's WebView2 browser process) holds it, never while the foreground is null. The visibility rule counts the browser process (CoreWebView2.BrowserProcessId) as ours, so the page's own dialogs do not hide the panel. - ClipboardRead is allowed only for an allowlisted origin. NavigationStarting and NewWindowRequested fail closed on an exception. - WebPanelApiRules: the ABI glue's pure parts (refusals, GetState Size check, state write), tested in WebPanelTests with WebPanelNativeArgs. WebPanelApi.LiveHandle and the browser pid in Describe for Task 4. - Harness: GpuProcessCrashKeepsPanel and LateFailureForSupersededHandle (both RED before the fix), UnloadWhileVisibleCollected reports UNVERIFIED when the window was not visible, the game-side key count is informational. EngineSettingsTests: WebPanel default-on round trip and setter case. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
52 lines
3 KiB
XML
52 lines
3 KiB
XML
<Project Sdk="Microsoft.NET.Sdk">
|
|
|
|
<!--
|
|
The web panel host under test, as the CoreCLR engine compiles it: src\RynthCore.Engine\WebPanel\*.cs
|
|
(host, Win32 interop, policies, layout store, ABI argument reader) and the ABI structs from
|
|
Plugins\PluginContract.cs, plus a stub environment (PayloadEntry.cs). tools\WebPanelHarness loads this
|
|
DLL into a collectible AssemblyLoadContext that mirrors the shim's EngineLoadContext, drives it, and
|
|
checks the context unloads. Not a test project on its own (no "Test" in the name: Run-AllTests skips it).
|
|
-->
|
|
<PropertyGroup>
|
|
<TargetFramework>net10.0-windows</TargetFramework>
|
|
<PlatformTarget>x86</PlatformTarget>
|
|
<RuntimeIdentifier>win-x86</RuntimeIdentifier>
|
|
<SelfContained>false</SelfContained>
|
|
<OutputType>Library</OutputType>
|
|
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
|
<Nullable>enable</Nullable>
|
|
<InvariantGlobalization>true</InvariantGlobalization>
|
|
<RootNamespace>RynthCore.Engine.WebPanel</RootNamespace>
|
|
<AssemblyName>WebPanelHarness.Payload</AssemblyName>
|
|
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
|
|
<WebView2UseWinRT>false</WebView2UseWinRT>
|
|
<WebView2LoaderPreference>Dynamic</WebView2LoaderPreference>
|
|
<GenerateDependencyFile>false</GenerateDependencyFile>
|
|
<NoWarn>$(NoWarn);CS0649;CS0169</NoWarn>
|
|
</PropertyGroup>
|
|
|
|
<ItemGroup>
|
|
<PackageReference Include="Microsoft.Web.WebView2" Version="1.0.2903.40" />
|
|
</ItemGroup>
|
|
|
|
<ItemGroup>
|
|
<Compile Include="..\..\src\RynthCore.Engine\Plugins\PluginContract.cs" Link="Engine\PluginContract.cs" />
|
|
<Compile Include="..\..\src\RynthCore.Engine\WebPanel\WebPanelUrlPolicy.cs" Link="Engine\WebPanelUrlPolicy.cs" />
|
|
<Compile Include="..\..\src\RynthCore.Engine\WebPanel\WebPanelWindowPolicy.cs" Link="Engine\WebPanelWindowPolicy.cs" />
|
|
<Compile Include="..\..\src\RynthCore.Engine\WebPanel\WebPanelProfile.cs" Link="Engine\WebPanelProfile.cs" />
|
|
<Compile Include="..\..\src\RynthCore.Engine\WebPanel\WebPanelNativeArgs.cs" Link="Engine\WebPanelNativeArgs.cs" />
|
|
<Compile Include="..\..\src\RynthCore.Engine\WebPanel\WebPanelApiRules.cs" Link="Engine\WebPanelApiRules.cs" />
|
|
<Compile Include="..\..\src\RynthCore.Engine\WebPanel\WebPanelLayoutStore.cs" Link="Engine\WebPanelLayoutStore.cs" />
|
|
<Compile Include="..\..\src\RynthCore.Engine\WebPanel\IWebPanelEnvironment.cs" Link="Engine\IWebPanelEnvironment.cs" />
|
|
<Compile Include="..\..\src\RynthCore.Engine\WebPanel\WebPanelNative.cs" Link="Engine\WebPanelNative.cs" />
|
|
<Compile Include="..\..\src\RynthCore.Engine\WebPanel\WebPanelHost.cs" Link="Engine\WebPanelHost.cs" />
|
|
</ItemGroup>
|
|
|
|
<!-- As the engine: no WinForms/WPF controls (RynthCore.Engine.csproj DropWebView2UiAssemblies). -->
|
|
<Target Name="DropWebView2UiAssemblies" BeforeTargets="ResolveAssemblyReferences">
|
|
<ItemGroup>
|
|
<Reference Remove="@(Reference)" Condition="'%(Filename)' == 'Microsoft.Web.WebView2.WinForms' Or '%(Filename)' == 'Microsoft.Web.WebView2.Wpf'" />
|
|
</ItemGroup>
|
|
</Target>
|
|
|
|
</Project>
|