Update: Full E2EE + Scripts

This commit is contained in:
2026-03-21 04:45:49 -04:00
parent cc31c4024a
commit 8a771220e4
21 changed files with 940 additions and 207 deletions

View File

@@ -2,37 +2,30 @@
public partial class App : Application
{
private bool _openedSecondWindow;
public App()
{
InitializeComponent();
var username = Environment.GetCommandLineArgs()
.Skip(1)
.Chunk(2)
.Where(x => x.Length == 2 && x[0] == "--user")
.Select(x => x[1])
.FirstOrDefault();
if (string.IsNullOrWhiteSpace(username))
{
throw new Exception("Missing required --user argument. Example: --user Keeper317");
}
ClientSession.Username = username;
}
protected override Window CreateWindow(IActivationState? activationState)
{
var keeperWindow = new Window(new MainPage("Keeper317"))
return new Window(new MainPage(ClientSession.Username))
{
Title = "Relay Client - Keeper317"
Title = $"Relay Client - {ClientSession.Username}"
};
keeperWindow.Created += KeeperWindow_Created;
return keeperWindow;
}
private void KeeperWindow_Created(object? sender, EventArgs e)
{
if (_openedSecondWindow)
return;
_openedSecondWindow = false;
var kiraWindow = new Window(new MainPage("Ru_Kira"))
{
Title = "Relay Client - Ru_Kira"
};
Current?.OpenWindow(kiraWindow);
}
}