Table of Contents

Class ActivatableLifetimeBase

Namespace
Avalonia.Controls.ApplicationLifetimes
Assembly
Avalonia.Controls.dll
[PrivateApi]
public abstract class ActivatableLifetimeBase : IActivatableLifetime
Inheritance
ActivatableLifetimeBase
Implements
Inherited Members

Constructors

ActivatableLifetimeBase()

protected ActivatableLifetimeBase()

Methods

OnActivated(ActivatedEventArgs)

protected void OnActivated(ActivatedEventArgs eventArgs)

Parameters

eventArgs ActivatedEventArgs

OnActivated(ActivationKind)

protected void OnActivated(ActivationKind kind)

Parameters

kind ActivationKind

OnDeactivated(ActivatedEventArgs)

protected void OnDeactivated(ActivatedEventArgs eventArgs)

Parameters

eventArgs ActivatedEventArgs

OnDeactivated(ActivationKind)

protected void OnDeactivated(ActivationKind kind)

Parameters

kind ActivationKind

TryEnterBackground()

Tells the application that it should attempt to enter its background state. For example on OSX this would be [NSApp hide]

public virtual bool TryEnterBackground()

Returns

bool

true if it was possible and the platform supports this. false otherwise

TryLeaveBackground()

Tells the application that it should attempt to leave its background state. For example on OSX this would be [NSApp unhide]

public virtual bool TryLeaveBackground()

Returns

bool

true if it was possible and the platform supports this. false otherwise

Events

Activated

An event that is raised when the application is Activated for various reasons as described by the ActivationKind enumeration.

public event EventHandler<ActivatedEventArgs>? Activated

Event Type

EventHandler<ActivatedEventArgs>

Deactivated

An event that is raised when the application is Deactivated for various reasons as described by the ActivationKind enumeration.

public event EventHandler<ActivatedEventArgs>? Deactivated

Event Type

EventHandler<ActivatedEventArgs>