Udostępnij za pośrednictwem


PendingFocusHelper Class

Definition

Microsoft internal use only. Helper to send focus to the FrameworkElement immediately or delay focusing until the FrameworkElement is loaded.

public ref class PendingFocusHelper abstract sealed
public ref class PendingFocusHelper abstract sealed
class PendingFocusHelper abstract sealed
public static class PendingFocusHelper
type PendingFocusHelper = class
Public Class PendingFocusHelper
Inheritance
PendingFocusHelper

Fields

FocusPriority

Microsoft internal use only.

Methods

SetFocusOnLoad(FrameworkElement, Action<FrameworkElement>)

Either sends focus to the FrameworkElement immediately using Focus, or delays focusing the FrameworkElement until it is loaded. The last element pending focus on Loaded will be focused, and all previous FrameworkElements will not be focused.

If UIElement.MoveFocus fails to move focus into the element, focus will be cleared by invoking Keyboard.ClearFocus to clear WPF focus, and by using SetFocus to focus the HWND of HwndSource containing the element.

Applies to