This repository has been archived on 2026-01-20. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
SessionZero-Client/SessionZero/AppManager.cs
2025-11-29 16:49:14 -06:00

37 lines
1016 B
C#

using Cogwheel;
using SessionZero.Cogwheel;
namespace SessionZero;
public static class AppManager
{
public static MainWindow MainWindow { get; set; }
public static ICogwheelConsole SzConsole { get; } = new SessionZeroConsole();
public static CommandsManager CommandsManager { get; } = new();
public static ConsoleControl ConsoleControl { get; } = new();
public static AppSettings Settings { get; } = new();
public static void ShowConsole()
{
MainWindow.ToggleConsole(true);
}
public static void HideConsole()
{
MainWindow.ToggleConsole(false);
}
// -- Global Commands -- //
[Command(Name = "page", Description = "Change the current page to the given value, if it exists")]
public static void ChangePage(string pageName)
{
MainWindow.ChangePage(pageName);
}
[Command(Name = "test")]
private static void Test()
{
COGWHEEL.LogWarning($"Trim size is: {ConsoleControl.OutputTrimSize}");
}
}