Skip to main content

TakesFocusFromNativeControl Property

Gets or sets a value indicating whether the popup, on show, transfers focus from any focused native control to Avalonia. The default is true.

Definition

Namespace: Avalonia.Controls.Primitives
Assembly: Avalonia.Controls (in Avalonia.Controls.dll)

public bool TakesFocusFromNativeControl { get; set; }

Property Value

Boolean

Remarks

This property only applies to advanced native control embedding scenarios. By default, if a popup is shown when a native control is focused, focus is transferred back to Avalonia in order for the popup to receive input. If this property is set to false, then the shown popup will not receive input until it receives an interaction which explicitly focuses the popup, such as a mouse click.

See Also

Reference

Popup Class
Avalonia.Controls.Primitives Namespace