using ITNexusAgent.UI; namespace ITNexusAgent; // Läuft als User-Prozess (via schtasks), zeigt Consent-Dialog und sendet Antwort via TCP public static class ConsentModeRunner { public static void Run(string portStr, string secret) { if (!int.TryParse(portStr, out var port) || port <= 0) return; var app = new System.Windows.Application(); app.ShutdownMode = System.Windows.ShutdownMode.OnMainWindowClose; var win = new RdpConsentWindow(port, secret); win.Topmost = true; win.Show(); win.Activate(); app.Run(); } }