Class InteractionState
- Namespace
- SharpConsoleUI.Core
- Assembly
- SharpConsoleUI.dll
Current mouse interaction state (drag or resize operation)
public record InteractionState : IEquatable<InteractionState>
- Inheritance
-
InteractionState
- Implements
- Inherited Members
Fields
None
No active interaction
public static readonly InteractionState None
Field Value
Properties
Drag
Current drag operation state (if dragging)
public DragState? Drag { get; init; }
Property Value
IsDragging
Whether a drag operation is in progress
public bool IsDragging { get; init; }
Property Value
IsResizing
Whether a resize operation is in progress
public bool IsResizing { get; init; }
Property Value
Resize
Current resize operation state (if resizing)
public ResizeState? Resize { get; init; }
Property Value
Methods
StartDrag(Window, Point, Point)
Creates a new dragging state
public static InteractionState StartDrag(Window window, Point mousePos, Point windowPos)
Parameters
Returns
StartResize(Window, ResizeDirection, Point, Size, Point)
Creates a new resizing state
public static InteractionState StartResize(Window window, ResizeDirection direction, Point mousePos, Size windowSize, Point windowPos)
Parameters
windowWindowdirectionResizeDirectionmousePosPointwindowSizeSizewindowPosPoint