minor fixes and renamings for intro landing page
This commit is contained in:
@@ -22,9 +22,10 @@ namespace MareSynchronos
|
||||
get => string.IsNullOrEmpty(_apiUri) ? ApiController.MainServiceUri : _apiUri;
|
||||
set => _apiUri = value;
|
||||
}
|
||||
public bool UseCustomService { get; set; }
|
||||
public bool InitialScanComplete { get; set; }
|
||||
public bool AcceptedAgreement { get; set; }
|
||||
|
||||
public bool UseCustomService { get; set; } = false;
|
||||
public bool InitialScanComplete { get; set; } = false;
|
||||
public bool AcceptedAgreement { get; set; } = false;
|
||||
private int _maxParallelScan = 10;
|
||||
public int MaxParallelScan
|
||||
{
|
||||
|
||||
@@ -55,7 +55,7 @@ namespace MareSynchronos.Managers
|
||||
public void StartInitialScan()
|
||||
{
|
||||
_scanCancellationTokenSource = new CancellationTokenSource();
|
||||
_scanTask = StartFileScan(_scanCancellationTokenSource.Token);
|
||||
_scanTask = Task.Run(() => StartFileScan(_scanCancellationTokenSource.Token));
|
||||
}
|
||||
|
||||
private async Task StartFileScan(CancellationToken ct)
|
||||
@@ -172,12 +172,12 @@ namespace MareSynchronos.Managers
|
||||
_timerStopWatch?.Stop();
|
||||
if (_scanTask?.IsCompleted ?? false)
|
||||
{
|
||||
PluginLog.Warning("Scanning task is still running, not reinitiating.");
|
||||
PluginLog.Warning("Scanning task is still running, not re-initiating.");
|
||||
return;
|
||||
}
|
||||
|
||||
PluginLog.Debug("Initiating periodic scan for mod changes");
|
||||
_scanTask = StartFileScan(_scanCancellationTokenSource!.Token);
|
||||
Task.Run(() => _scanTask = StartFileScan(_scanCancellationTokenSource!.Token));
|
||||
_timerStopWatch = Stopwatch.StartNew();
|
||||
};
|
||||
|
||||
|
||||
@@ -100,6 +100,8 @@ namespace MareSynchronos
|
||||
{
|
||||
PluginLog.Debug("Client login");
|
||||
|
||||
_pluginInterface.UiBuilder.Draw += Draw;
|
||||
|
||||
if (!_configuration.HasValidSetup)
|
||||
{
|
||||
_introUi.IsOpen = true;
|
||||
@@ -108,7 +110,6 @@ namespace MareSynchronos
|
||||
else
|
||||
{
|
||||
_introUi.IsOpen = false;
|
||||
_pluginInterface.UiBuilder.Draw += Draw;
|
||||
}
|
||||
|
||||
Task.Run(async () =>
|
||||
|
||||
@@ -63,6 +63,10 @@ namespace MareSynchronos.UI
|
||||
"Note that you will have to have Penumbra as well as Glamourer installed to use this plugin.");
|
||||
UIShared.TextWrapped("We will have to setup a few things first before you can start using this plugin. Click on next to continue.");
|
||||
|
||||
ImGui.PushStyleColor(ImGuiCol.Text, ImGuiColors.DalamudYellow);
|
||||
UIShared.TextWrapped("Note: Any modifications you have applied through anything but Penumbra cannot be shared and your character state on other clients " +
|
||||
"might look broken because of this. If you want to use this plugin you will have to move your mods to Penumbra.");
|
||||
ImGui.PopStyleColor();
|
||||
if (!_uiShared.DrawOtherPluginState()) return;
|
||||
ImGui.Separator();
|
||||
if (ImGui.Button("Next##toAgreement"))
|
||||
|
||||
@@ -68,6 +68,7 @@ namespace MareSynchronos.UI
|
||||
{
|
||||
ImGui.Text("Scan not started");
|
||||
}
|
||||
else
|
||||
{
|
||||
ImGui.Text("Next scan in " + _fileCacheManager.TimeToNextScan.ToString(@"mm\:ss") + " minutes");
|
||||
}
|
||||
|
||||
@@ -109,12 +109,11 @@ namespace MareSynchronos.WebAPI
|
||||
{
|
||||
if (message is HttpClientHandler clientHandler)
|
||||
clientHandler.ServerCertificateCustomValidationCallback +=
|
||||
(sender, certificate, chain, sslPolicyErrors) => true;
|
||||
(_, _, _, _) => true;
|
||||
return message;
|
||||
};
|
||||
#endif
|
||||
}).Build();
|
||||
PluginLog.Debug("Heartbeat service built to: " + ApiUri);
|
||||
|
||||
await _heartbeatHub.StartAsync(cts.Token);
|
||||
UID = await _heartbeatHub!.InvokeAsync<string>("Heartbeat");
|
||||
@@ -125,9 +124,9 @@ namespace MareSynchronos.WebAPI
|
||||
await LoadInitialData();
|
||||
Connected?.Invoke(this, EventArgs.Empty);
|
||||
}
|
||||
catch (Exception ex)
|
||||
catch
|
||||
{
|
||||
PluginLog.Error(ex, "Error during Heartbeat initialization");
|
||||
//PluginLog.Error(ex, "Error during Heartbeat initialization");
|
||||
}
|
||||
|
||||
_heartbeatHub.Closed += OnHeartbeatHubOnClosed;
|
||||
|
||||
Reference in New Issue
Block a user