public sealed record RunicHostedServiceRequest : IEquatable<RunicHostedServiceRequest> A window service a guest application uses for one of its windows, or files the user dropped onto it. Only the members of its RunicHostedServiceRequest.Kind are set.
Remarks
Experimental; see docs/experimental.md.
Properties
ClipboardFormats
public DesktopClipboardFormats ClipboardFormats { get; init; } The format a RunicHostedServiceKind.ClipboardRead reads (DesktopClipboardFormats.None when it reads which formats the clipboard has), or the formats a RunicHostedServiceKind.ClipboardWrite writes.
IsAllowedByDefault
public bool IsAllowedByDefault { get; } Whether the host's default rules allow it. A clipboard read only while the user works in RunicHostedServiceRequest.Window: it is active (has the keyboard focus), and not because of the guest's own request (RunicHostedServiceRequest.IsGuestActivated). A clipboard write likewise, or within a second after such an activation ended. Opening a link only for an http, https or mailto URI, and a file only for a path the user gave the guest through the host (an open or folder dialog's selection or a drop) that is still the same file, each only while the user works in the window. The monitors and a drop always.
IsGuestActivated
public bool IsGuestActivated { get; } Whether RunicHostedServiceRequest.Window is active because of the guest's own request, and the user has not worked in it since: it became active within two seconds after any request of the guest that can activate one of its windows, such as opening, presenting, showing, hiding, minimizing or maximizing a window, entering or leaving full screen, closing one of its windows, which activates its owner, or the end of one of its dialogs or context menus, also one the user answered, or while one of them shows. The user's own later activation of the window, a choice in its native menu bar, a choice in a context menu shown while the user worked in the window, and a drop onto it end it; a shortcut of its menus does not, since a key the guest's page leaves unhandled runs it. A guest that takes the focus this way cannot use it to read the clipboard, write it or open files and links by default.
Remarks
The host does not see the user's input in the guest's page, so a guest's window the user works in stays guest-activated until one of these happens. A policy that trusts a guest can allow its requests anyway.
Operation
public DesktopFileOperation Operation { get; init; } What a RunicHostedServiceKind.Launch of a file does with it.
Path
public string? Path { get; init; } The absolute path of a RunicHostedServiceKind.Launch of a file; null for a link.
Remarks
The host opens it with the rules of IDesktopFileLauncher.LaunchAsync.
Paths
public ImmutableArray<string> Paths { get; init; } The absolute paths of a RunicHostedServiceKind.FileDrop, as the platform reported them.
Uri
public Uri? Uri { get; init; } The link of a RunicHostedServiceKind.Launch; null for a file.
Remarks
The host opens it with the rules of IDesktopFileLauncher.LaunchUriAsync.