DesktopPresentationPreflight record

Namespace Runic.Desktop in Runic.Desktop 0.23.0

public sealed record DesktopPresentationPreflight : IEquatable<DesktopPresentationPreflight>

Inherits or implements IEquatable.

Describes whether a requested presentation can be opened without changing its declared fallback policy.

Parameters

RequestedBrowser

The requested DesktopWindowOptions.Browser.

PresentationPolicy

The requested DesktopWindowOptions.PresentationPolicy.

Preferred

The first presentation the window tries.

Fallback

The first fallback, or null when the request declares none.

Constructors

DesktopPresentationPreflight

public DesktopPresentationPreflight(BrowserKind RequestedBrowser, DesktopPresentationPolicy PresentationPolicy, DesktopPresentationAvailability Preferred, DesktopPresentationAvailability? Fallback)

Describes whether a requested presentation can be opened without changing its declared fallback policy.

Parameters

RequestedBrowser

The requested DesktopWindowOptions.Browser.

PresentationPolicy

The requested DesktopWindowOptions.PresentationPolicy.

Preferred

The first presentation the window tries.

Fallback

The first fallback, or null when the request declares none.

Properties

Diagnostics

public IReadOnlyList<DesktopDiagnostic> Diagnostics { get; }

Gets every missing prerequisite of the preferred presentation and its declared fallbacks when no declared presentation path is available, the preferred presentation's first; empty when one is available.

Fallback

public DesktopPresentationAvailability? Fallback { get; init; }

The first fallback, or null when the request declares none.

Fallbacks

public IReadOnlyList<DesktopPresentationAvailability> Fallbacks { get; init; }

Gets every declared fallback in the order the window tries them (DesktopWindowOptions.Fallbacks, or the one browser of DesktopPresentationPolicy.EmbeddedThenBrowser); by default DesktopPresentationPreflight.Fallback alone, or empty.

IsAvailable

public bool IsAvailable { get; }

Gets whether the declared policy has an available presentation path.

IsPreferredAvailable

public bool IsPreferredAvailable { get; }

Gets whether the preferred presentation is available without fallback.

OptionDiagnostics

public IReadOnlyList<DesktopDiagnostic> OptionDiagnostics { get; init; }

Gets one diagnostic per requested window option or permission grant that the preferred presentation, or its declared fallback, rejects (DesktopDiagnosticSeverity.Error) or ignores (DesktopDiagnosticSeverity.Warning). DesktopDiagnostic.Option names the option.

Preferred

public DesktopPresentationAvailability Preferred { get; init; }

The first presentation the window tries.

PresentationPolicy

public DesktopPresentationPolicy PresentationPolicy { get; init; }

RequestedBrowser

public BrowserKind RequestedBrowser { get; init; }

WouldFallBack

public bool WouldFallBack { get; }

Gets whether opening the request would use one of its declared fallbacks.