mirror of
https://github.com/Maassoft/ColorControl.git
synced 2026-10-18 23:07:15 -05:00
21 lines
558 B
C#
21 lines
558 B
C#
using ColorControl.Shared.Contracts;
|
|
using ColorControl.UI;
|
|
using ColorControl.UI.Services;
|
|
using System.Diagnostics;
|
|
|
|
var arguments = args;
|
|
|
|
if (Debugger.IsAttached)
|
|
{
|
|
var rpcServer = new RpcUiClientService(null);
|
|
var options = new RpcUiClientOptions
|
|
{
|
|
Timeout = 10000
|
|
};
|
|
|
|
var config = await rpcServer.CallWithOptionsAsync<Config>("OptionsService", "GetConfig", options);
|
|
arguments = ["", config.UseDarkMode.ToString(), config.UiPort.ToString(), config.UiAllowRemoteConnections.ToString()];
|
|
}
|
|
|
|
await Blazor.Start(arguments);
|