Mare 0.9 (#65)
* add jwt expiry * start of 0.9 api impl * some stuff idk * some more impl * some cleanup * remove grouppair, add configuration, rework some pair drawing stuff * do some stuff * rework some ui * I don't even know anymore * add cancellationtoken * token bla * ui fixes etc * probably individual adding/removing now working fully as expected * add working report popup * I guess it's more syncshell shit or so * popup shit idk * work out most of the syncshell bullshit I guess * delete some old crap * are we actually getting closer to the end * update pair info stuff * more fixes/adjustments, idk * refactor some things * some rework * some more cleanup * cleanup * make menu buttons w i d e * better icon text buttons * add all syncshell folder and ordering fixes --------- Co-authored-by: rootdarkarchon <root.darkarchon@outlook.com>
This commit is contained in:
@@ -1,17 +1,17 @@
|
||||
using Dalamud.Plugin;
|
||||
using Dalamud.Interface.ImGuiFileDialog;
|
||||
using Dalamud.Interface.ImGuiFileDialog;
|
||||
using Dalamud.Interface.Windowing;
|
||||
using MareSynchronos.UI;
|
||||
using Dalamud.Plugin;
|
||||
using MareSynchronos.MareConfiguration;
|
||||
using MareSynchronos.Services.Mediator;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using MareSynchronos.PlayerData.Pairs;
|
||||
using MareSynchronos.Services.Mediator;
|
||||
using MareSynchronos.UI;
|
||||
using Microsoft.Extensions.Logging;
|
||||
|
||||
namespace MareSynchronos.Services;
|
||||
|
||||
public sealed class UiService : DisposableMediatorSubscriberBase
|
||||
{
|
||||
private readonly List<WindowMediatorSubscriberBase> _createdWindows = new();
|
||||
private readonly List<WindowMediatorSubscriberBase> _createdWindows = [];
|
||||
private readonly DalamudPluginInterface _dalamudPluginInterface;
|
||||
private readonly FileDialogManager _fileDialogManager;
|
||||
private readonly ILogger<UiService> _logger;
|
||||
@@ -42,8 +42,8 @@ public sealed class UiService : DisposableMediatorSubscriberBase
|
||||
|
||||
Mediator.Subscribe<ProfileOpenStandaloneMessage>(this, (msg) =>
|
||||
{
|
||||
if (!_createdWindows.Any(p => p is StandaloneProfileUi
|
||||
&& string.Equals(((StandaloneProfileUi)p).Pair.UserData.AliasOrUID, msg.Pair.UserData.AliasOrUID, StringComparison.Ordinal)))
|
||||
if (!_createdWindows.Exists(p => p is StandaloneProfileUi ui
|
||||
&& string.Equals(ui.Pair.UserData.AliasOrUID, msg.Pair.UserData.AliasOrUID, StringComparison.Ordinal)))
|
||||
{
|
||||
var window = standaloneProfileUiFactory(msg.Pair);
|
||||
_createdWindows.Add(window);
|
||||
@@ -59,14 +59,6 @@ public sealed class UiService : DisposableMediatorSubscriberBase
|
||||
});
|
||||
}
|
||||
|
||||
public void ToggleUi()
|
||||
{
|
||||
if (_mareConfigService.Current.HasValidSetup())
|
||||
Mediator.Publish(new UiToggleMessage(typeof(SettingsUi)));
|
||||
else
|
||||
Mediator.Publish(new UiToggleMessage(typeof(IntroUi)));
|
||||
}
|
||||
|
||||
public void ToggleMainUi()
|
||||
{
|
||||
if (_mareConfigService.Current.HasValidSetup())
|
||||
@@ -75,6 +67,14 @@ public sealed class UiService : DisposableMediatorSubscriberBase
|
||||
Mediator.Publish(new UiToggleMessage(typeof(IntroUi)));
|
||||
}
|
||||
|
||||
public void ToggleUi()
|
||||
{
|
||||
if (_mareConfigService.Current.HasValidSetup())
|
||||
Mediator.Publish(new UiToggleMessage(typeof(SettingsUi)));
|
||||
else
|
||||
Mediator.Publish(new UiToggleMessage(typeof(IntroUi)));
|
||||
}
|
||||
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
base.Dispose(disposing);
|
||||
|
||||
Reference in New Issue
Block a user