mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
20 lines
413 B
C#
20 lines
413 B
C#
using Aaru.Commands;
|
|
using Spectre.Console.Cli;
|
|
|
|
namespace Aaru;
|
|
|
|
public class PausingInterceptor : ICommandInterceptor
|
|
{
|
|
#region ICommandInterceptor Members
|
|
|
|
public void Intercept(CommandContext context, CommandSettings settings)
|
|
{
|
|
if(settings is not BaseSettings global) return;
|
|
|
|
if(global is not { Pause: true }) return;
|
|
|
|
MainClass.PauseBeforeExiting = true;
|
|
}
|
|
|
|
#endregion
|
|
} |