Class ClosingEventArgs
- Namespace
- SharpConsoleUI
- Assembly
- SharpConsoleUI.dll
Provides data for the window closing event, allowing cancellation of the close operation.
public class ClosingEventArgs : EventArgs
- Inheritance
-
ClosingEventArgs
- Inherited Members
Constructors
ClosingEventArgs(bool)
Initializes a new instance of the ClosingEventArgs class.
public ClosingEventArgs(bool force = false)
Parameters
forceboolWhether this is a forced close that cannot be cancelled.
Properties
Allow
Gets or sets a value indicating whether the window close operation should be allowed. Set to false to cancel the close operation. Ignored when Force is true.
public bool Allow { get; set; }
Property Value
Force
Gets a value indicating whether this is a forced close. When true, the close cannot be cancelled (Allow is ignored). Handlers can use this to perform cleanup knowing the window will close.
public bool Force { get; }