Added option to show green eye in pair list.
This commit is contained in:
@@ -16,12 +16,8 @@ using LightlessSync.UI.Models;
|
||||
using LightlessSync.UI.Style;
|
||||
using LightlessSync.Utils;
|
||||
using LightlessSync.WebAPI;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Immutable;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using LightlessSync.UI;
|
||||
|
||||
namespace LightlessSync.UI.Components;
|
||||
|
||||
@@ -40,6 +36,7 @@ public class DrawUserPair
|
||||
private readonly ServerConfigurationManager _serverConfigurationManager;
|
||||
private readonly UiSharedService _uiSharedService;
|
||||
private readonly PlayerPerformanceConfigService _performanceConfigService;
|
||||
private readonly LightlessConfigService _configService;
|
||||
private readonly CharaDataManager _charaDataManager;
|
||||
private readonly PairLedger _pairLedger;
|
||||
private float _menuWidth = -1;
|
||||
@@ -59,6 +56,7 @@ public class DrawUserPair
|
||||
ServerConfigurationManager serverConfigurationManager,
|
||||
UiSharedService uiSharedService,
|
||||
PlayerPerformanceConfigService performanceConfigService,
|
||||
LightlessConfigService configService,
|
||||
CharaDataManager charaDataManager,
|
||||
PairLedger pairLedger)
|
||||
{
|
||||
@@ -75,6 +73,7 @@ public class DrawUserPair
|
||||
_serverConfigurationManager = serverConfigurationManager;
|
||||
_uiSharedService = uiSharedService;
|
||||
_performanceConfigService = performanceConfigService;
|
||||
_configService = configService;
|
||||
_charaDataManager = charaDataManager;
|
||||
_pairLedger = pairLedger;
|
||||
}
|
||||
@@ -230,6 +229,11 @@ public class DrawUserPair
|
||||
private void DrawLeftSide()
|
||||
{
|
||||
ImGui.AlignTextToFramePadding();
|
||||
|
||||
if (_pair == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (_pair.IsPaused)
|
||||
{
|
||||
@@ -246,7 +250,15 @@ public class DrawUserPair
|
||||
}
|
||||
else if (_pair.IsVisible)
|
||||
{
|
||||
_uiSharedService.IconText(FontAwesomeIcon.Eye, UIColors.Get("LightlessBlue"));
|
||||
if (_configService.Current.ShowVisiblePairsGreenEye)
|
||||
{
|
||||
_uiSharedService.IconText(FontAwesomeIcon.Eye, UIColors.Get("LightlessGreen"));
|
||||
}
|
||||
else
|
||||
{
|
||||
_uiSharedService.IconText(FontAwesomeIcon.Eye, UIColors.Get("LightlessBlue"));
|
||||
}
|
||||
|
||||
if (ImGui.IsItemHovered(ImGuiHoveredFlags.AllowWhenBlockedByActiveItem | ImGuiHoveredFlags.AllowWhenOverlapped | ImGuiHoveredFlags.AllowWhenDisabled))
|
||||
{
|
||||
_mediator.Publish(new PairFocusCharacterMessage(_pair));
|
||||
|
||||
@@ -161,6 +161,7 @@ public class DrawEntityFactory
|
||||
_serverConfigurationManager,
|
||||
_uiSharedService,
|
||||
_playerPerformanceConfigService,
|
||||
_configService,
|
||||
_charaDataManager,
|
||||
_pairLedger);
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
using Dalamud.Bindings.ImGui;
|
||||
using Dalamud.Game.Text;
|
||||
using Dalamud.Game.ClientState.Objects.Enums;
|
||||
using Dalamud.Game.Text;
|
||||
using Dalamud.Interface;
|
||||
using Dalamud.Interface.Colors;
|
||||
using Dalamud.Interface.Utility;
|
||||
@@ -19,6 +19,7 @@ using LightlessSync.PlayerData.Pairs;
|
||||
using LightlessSync.Services;
|
||||
using LightlessSync.Services.ActorTracking;
|
||||
using LightlessSync.Services.Mediator;
|
||||
using LightlessSync.Services.PairProcessing;
|
||||
using LightlessSync.Services.ServerConfiguration;
|
||||
using LightlessSync.UI.Services;
|
||||
using LightlessSync.UI.Style;
|
||||
@@ -38,7 +39,7 @@ using System.Net.Http.Json;
|
||||
using System.Numerics;
|
||||
using System.Text;
|
||||
using System.Text.Json;
|
||||
using LightlessSync.Services.PairProcessing;
|
||||
using static Penumbra.GameData.Files.ShpkFile;
|
||||
|
||||
namespace LightlessSync.UI;
|
||||
|
||||
@@ -1712,7 +1713,7 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
||||
var groupedSyncshells = _configService.Current.ShowGroupedSyncshellsInAll;
|
||||
var groupInVisible = _configService.Current.ShowSyncshellUsersInVisible;
|
||||
var syncshellOfflineSeparate = _configService.Current.ShowSyncshellOfflineUsersSeparately;
|
||||
|
||||
var greenVisiblePair = _configService.Current.ShowVisiblePairsGreenEye;
|
||||
|
||||
using (var behaviorTree = BeginGeneralTree("Behavior", UIColors.Get("LightlessPurple")))
|
||||
{
|
||||
@@ -2205,13 +2206,19 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
||||
_uiShared.DrawHelpText("If you set a note for a player it will be shown instead of the player name");
|
||||
if (!_configService.Current.ShowCharacterNameInsteadOfNotesForVisible) ImGui.EndDisabled();
|
||||
ImGui.Unindent();
|
||||
|
||||
|
||||
if (ImGui.Checkbox("Set visible pairs as focus targets when clicking the eye", ref useFocusTarget))
|
||||
{
|
||||
_configService.Current.UseFocusTarget = useFocusTarget;
|
||||
_configService.Save();
|
||||
}
|
||||
|
||||
if (ImGui.Checkbox("Set visible pairs icon to an green color", ref greenVisiblePair))
|
||||
{
|
||||
_configService.Current.ShowVisiblePairsGreenEye = greenVisiblePair;
|
||||
_configService.Save();
|
||||
}
|
||||
|
||||
UiSharedService.ColoredSeparator(UIColors.Get("LightlessPurple"), 1.5f);
|
||||
ImGui.TreePop();
|
||||
pairListTree.MarkContentEnd();
|
||||
|
||||
Reference in New Issue
Block a user