Class FocusStateChangedEventArgs
- Namespace
- SharpConsoleUI.Core
- Assembly
- SharpConsoleUI.dll
Event arguments for focus state changes
public class FocusStateChangedEventArgs : EventArgs
- Inheritance
-
FocusStateChangedEventArgs
- Inherited Members
Constructors
FocusStateChangedEventArgs(FocusState, FocusState)
Initializes a new instance of the FocusStateChangedEventArgs class.
public FocusStateChangedEventArgs(FocusState previousState, FocusState newState)
Parameters
previousStateFocusStateThe previous focus state before the change.
newStateFocusStateThe new focus state after the change.
Properties
ControlChanged
Whether the focused control changed
public bool ControlChanged { get; }
Property Value
GainedFocusControl
The control that gained focus (if any)
public IInteractiveControl? GainedFocusControl { get; }
Property Value
LostFocusControl
The control that lost focus (if any)
public IInteractiveControl? LostFocusControl { get; }
Property Value
NewState
The new focus state
public FocusState NewState { get; }
Property Value
PreviousState
The previous focus state
public FocusState PreviousState { get; }
Property Value
WindowChanged
Whether the focused window changed
public bool WindowChanged { get; }