Table of Contents

Event IsRunningChanging

Namespace
Terminal.Gui.ViewBase
Assembly
Terminal.Gui.dll

Raised when IsRunning is changing (e.g., when Begin(IRunnable) or End(RunnableSessionToken) is called). Can be canceled by setting CancelEventArgs<T>.Cancel to true.

public event EventHandler<CancelEventArgs<bool>>? IsRunningChanging

Returns

EventHandler<CancelEventArgs<bool>>
Raised when is changing (e.g., when or is called). Can be canceled by setting CancelEventArgs<T>.Cancel to true.
Implements

Remarks

Subscribe to this event to participate in the runnable lifecycle before state changes occur. When NewValue is false (stopping), this is the ideal place to extract Result before views are disposed and to optionally cancel the stop operation (e.g., prompt to save changes).

This event follows the Terminal.Gui Cancellable Work Pattern (CWP).