Added the old system of WQPD back. added more options of it.
This commit is contained in:
@@ -66,6 +66,7 @@ public class LightlessConfig : ILightlessConfiguration
|
|||||||
public bool ShowTransferBars { get; set; } = true;
|
public bool ShowTransferBars { get; set; } = true;
|
||||||
public bool ShowTransferWindow { get; set; } = false;
|
public bool ShowTransferWindow { get; set; } = false;
|
||||||
public bool ShowPlayerLinesTransferWindow { get; set; } = true;
|
public bool ShowPlayerLinesTransferWindow { get; set; } = true;
|
||||||
|
public bool ShowPlayerSpeedBarsTransferWindow { get; set; } = true;
|
||||||
public bool UseNotificationsForDownloads { get; set; } = true;
|
public bool UseNotificationsForDownloads { get; set; } = true;
|
||||||
public bool ShowUploading { get; set; } = true;
|
public bool ShowUploading { get; set; } = true;
|
||||||
public bool ShowUploadingBigText { get; set; } = true;
|
public bool ShowUploadingBigText { get; set; } = true;
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
using Dalamud.Bindings.ImGui;
|
using Dalamud.Bindings.ImGui;
|
||||||
using Dalamud.Interface.Colors;
|
using Dalamud.Interface.Colors;
|
||||||
using LightlessSync.LightlessConfiguration;
|
using LightlessSync.LightlessConfiguration;
|
||||||
using LightlessSync.LightlessConfiguration.Models;
|
using LightlessSync.LightlessConfiguration.Models;
|
||||||
@@ -153,6 +153,12 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (_configService.Current.ShowTransferBars)
|
if (_configService.Current.ShowTransferBars)
|
||||||
|
{
|
||||||
|
DrawTransferBar();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void DrawTransferBar()
|
||||||
{
|
{
|
||||||
const int dlBarBorder = 3;
|
const int dlBarBorder = 3;
|
||||||
const float rounding = 6f;
|
const float rounding = 6f;
|
||||||
@@ -163,14 +169,14 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
var transferKey = transfer.Key;
|
var transferKey = transfer.Key;
|
||||||
var rawPos = _dalamudUtilService.WorldToScreen(transferKey.GetGameObject());
|
var rawPos = _dalamudUtilService.WorldToScreen(transferKey.GetGameObject());
|
||||||
|
|
||||||
//If RawPos is zero, remove it from smoothed dictionary
|
// If RawPos is zero, remove it from smoothed dictionary
|
||||||
if (rawPos == Vector2.Zero)
|
if (rawPos == Vector2.Zero)
|
||||||
{
|
{
|
||||||
_smoothed.Remove(transferKey);
|
_smoothed.Remove(transferKey);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
//Smoothing out the movement and fix jitter around the position.
|
// Smoothing out the movement and fix jitter around the position.
|
||||||
Vector2 screenPos = _smoothed.TryGetValue(transferKey, out var lastPos)
|
Vector2 screenPos = _smoothed.TryGetValue(transferKey, out var lastPos)
|
||||||
? (rawPos - lastPos).Length() < 4f ? lastPos : rawPos
|
? (rawPos - lastPos).Length() < 4f ? lastPos : rawPos
|
||||||
: rawPos;
|
: rawPos;
|
||||||
@@ -179,6 +185,56 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
var totalBytes = transfer.Value.Sum(c => c.Value.TotalBytes);
|
var totalBytes = transfer.Value.Sum(c => c.Value.TotalBytes);
|
||||||
var transferredBytes = transfer.Value.Sum(c => c.Value.TransferredBytes);
|
var transferredBytes = transfer.Value.Sum(c => c.Value.TransferredBytes);
|
||||||
|
|
||||||
|
// Per-player state counts
|
||||||
|
var dlSlot = 0;
|
||||||
|
var dlQueue = 0;
|
||||||
|
var dlProg = 0;
|
||||||
|
var dlDecomp = 0;
|
||||||
|
|
||||||
|
foreach (var entry in transfer.Value)
|
||||||
|
{
|
||||||
|
var fileStatus = entry.Value;
|
||||||
|
switch (fileStatus.DownloadStatus)
|
||||||
|
{
|
||||||
|
case DownloadStatus.WaitingForSlot:
|
||||||
|
dlSlot++;
|
||||||
|
break;
|
||||||
|
case DownloadStatus.WaitingForQueue:
|
||||||
|
dlQueue++;
|
||||||
|
break;
|
||||||
|
case DownloadStatus.Downloading:
|
||||||
|
dlProg++;
|
||||||
|
break;
|
||||||
|
case DownloadStatus.Decompressing:
|
||||||
|
dlDecomp++;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
string statusText;
|
||||||
|
if (dlProg > 0)
|
||||||
|
{
|
||||||
|
statusText = "Downloading";
|
||||||
|
}
|
||||||
|
else if (dlDecomp > 0 || (totalBytes > 0 && transferredBytes >= totalBytes))
|
||||||
|
{
|
||||||
|
statusText = "Decompressing";
|
||||||
|
}
|
||||||
|
else if (dlQueue > 0)
|
||||||
|
{
|
||||||
|
statusText = "Waiting for queue";
|
||||||
|
}
|
||||||
|
else if (dlSlot > 0)
|
||||||
|
{
|
||||||
|
statusText = "Waiting for slot";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
statusText = "Waiting";
|
||||||
|
}
|
||||||
|
|
||||||
|
var hasValidSize = totalBytes > 0;
|
||||||
|
|
||||||
var maxDlText = $"{UiSharedService.ByteToString(totalBytes, addSuffix: false)}/{UiSharedService.ByteToString(totalBytes)}";
|
var maxDlText = $"{UiSharedService.ByteToString(totalBytes, addSuffix: false)}/{UiSharedService.ByteToString(totalBytes)}";
|
||||||
var textSize = _configService.Current.TransferBarsShowText
|
var textSize = _configService.Current.TransferBarsShowText
|
||||||
? ImGui.CalcTextSize(maxDlText)
|
? ImGui.CalcTextSize(maxDlText)
|
||||||
@@ -202,22 +258,93 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
|
|
||||||
var drawList = ImGui.GetBackgroundDrawList();
|
var drawList = ImGui.GetBackgroundDrawList();
|
||||||
|
|
||||||
//Shadow, background, border, bar background
|
drawList.AddRectFilled(
|
||||||
drawList.AddRectFilled(outerStart + shadowOffset, outerEnd + shadowOffset, UiSharedService.Color(0, 0, 0, 100 / 2), rounding + 2);
|
outerStart + shadowOffset,
|
||||||
drawList.AddRectFilled(outerStart, outerEnd, UiSharedService.Color(0, 0, 0, 100), rounding + 2);
|
outerEnd + shadowOffset,
|
||||||
drawList.AddRectFilled(borderStart, borderEnd, UiSharedService.Color(ImGuiColors.DalamudGrey), rounding);
|
UiSharedService.Color(0, 0, 0, 100 / 2),
|
||||||
drawList.AddRectFilled(dlBarStart, dlBarEnd, UiSharedService.Color(0, 0, 0, 100), rounding);
|
rounding + 2
|
||||||
|
);
|
||||||
|
drawList.AddRectFilled(
|
||||||
|
outerStart,
|
||||||
|
outerEnd,
|
||||||
|
UiSharedService.Color(0, 0, 0, 100),
|
||||||
|
rounding + 2
|
||||||
|
);
|
||||||
|
drawList.AddRectFilled(
|
||||||
|
borderStart,
|
||||||
|
borderEnd,
|
||||||
|
UiSharedService.Color(ImGuiColors.DalamudGrey),
|
||||||
|
rounding
|
||||||
|
);
|
||||||
|
drawList.AddRectFilled(
|
||||||
|
dlBarStart,
|
||||||
|
dlBarEnd,
|
||||||
|
UiSharedService.Color(0, 0, 0, 100),
|
||||||
|
rounding
|
||||||
|
);
|
||||||
|
|
||||||
var dlProgressPercent = transferredBytes / (double)totalBytes;
|
bool showFill = false;
|
||||||
var progressEndX = dlBarStart.X + (float)(dlProgressPercent * dlBarWidth);
|
double fillPercent = 0.0;
|
||||||
|
|
||||||
|
if (hasValidSize)
|
||||||
|
{
|
||||||
|
if (dlProg > 0)
|
||||||
|
{
|
||||||
|
fillPercent = transferredBytes / (double)totalBytes;
|
||||||
|
showFill = true;
|
||||||
|
}
|
||||||
|
else if (dlDecomp > 0 || transferredBytes >= totalBytes)
|
||||||
|
{
|
||||||
|
fillPercent = 1.0;
|
||||||
|
showFill = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (showFill)
|
||||||
|
{
|
||||||
|
if (fillPercent < 0) fillPercent = 0;
|
||||||
|
if (fillPercent > 1) fillPercent = 1;
|
||||||
|
|
||||||
|
var progressEndX = dlBarStart.X + (float)(fillPercent * dlBarWidth);
|
||||||
var progressEnd = new Vector2(progressEndX, dlBarEnd.Y);
|
var progressEnd = new Vector2(progressEndX, dlBarEnd.Y);
|
||||||
|
|
||||||
drawList.AddRectFilled(dlBarStart, progressEnd, UiSharedService.Color(UIColors.Get("LightlessPurple")), rounding);
|
drawList.AddRectFilled(
|
||||||
|
dlBarStart,
|
||||||
|
progressEnd,
|
||||||
|
UiSharedService.Color(UIColors.Get("LightlessPurple")),
|
||||||
|
rounding
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
if (_configService.Current.TransferBarsShowText)
|
if (_configService.Current.TransferBarsShowText)
|
||||||
{
|
{
|
||||||
var downloadText = $"{UiSharedService.ByteToString(transferredBytes, addSuffix: false)}/{UiSharedService.ByteToString(totalBytes)}";
|
string downloadText;
|
||||||
UiSharedService.DrawOutlinedFont(drawList, downloadText, screenPos with { X = screenPos.X - textSize.X / 2f - 1, Y = screenPos.Y - textSize.Y / 2f - 1 },
|
|
||||||
|
if (dlProg > 0 && hasValidSize)
|
||||||
|
{
|
||||||
|
downloadText =
|
||||||
|
$"{statusText} {UiSharedService.ByteToString(transferredBytes, addSuffix: false)}/{UiSharedService.ByteToString(totalBytes)}";
|
||||||
|
}
|
||||||
|
else if ((dlDecomp > 0 || transferredBytes >= totalBytes) && hasValidSize)
|
||||||
|
{
|
||||||
|
downloadText = "Decompressing";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Waiting states
|
||||||
|
downloadText = statusText;
|
||||||
|
}
|
||||||
|
|
||||||
|
var actualTextSize = ImGui.CalcTextSize(downloadText);
|
||||||
|
|
||||||
|
UiSharedService.DrawOutlinedFont(
|
||||||
|
drawList,
|
||||||
|
downloadText,
|
||||||
|
screenPos with
|
||||||
|
{
|
||||||
|
X = screenPos.X - actualTextSize.X / 2f - 1,
|
||||||
|
Y = screenPos.Y - actualTextSize.Y / 2f - 1
|
||||||
|
},
|
||||||
UiSharedService.Color(ImGuiColors.DalamudGrey),
|
UiSharedService.Color(ImGuiColors.DalamudGrey),
|
||||||
UiSharedService.Color(0, 0, 0, 100),
|
UiSharedService.Color(0, 0, 0, 100),
|
||||||
1
|
1
|
||||||
@@ -253,11 +380,10 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
private void DrawDownloadSummaryBox()
|
private void DrawDownloadSummaryBox()
|
||||||
{
|
{
|
||||||
if (!_currentDownloads.Any())
|
if (_currentDownloads.IsEmpty)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
const float padding = 6f;
|
const float padding = 6f;
|
||||||
@@ -271,10 +397,24 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
long totalBytes = 0;
|
long totalBytes = 0;
|
||||||
long transferredBytes = 0;
|
long transferredBytes = 0;
|
||||||
|
|
||||||
// (Name, files done, files total, bytes done, bytes total, speed)
|
var totalDlSlot = 0;
|
||||||
var perPlayer = new List<(string Name, int TransferredFiles, int TotalFiles, long TransferredBytes, long TotalBytes, double SpeedBytesPerSecond)>();
|
var totalDlQueue = 0;
|
||||||
|
var totalDlProg = 0;
|
||||||
|
var totalDlDecomp = 0;
|
||||||
|
|
||||||
foreach (var transfer in _currentDownloads.ToList())
|
var perPlayer = new List<(
|
||||||
|
string Name,
|
||||||
|
int TransferredFiles,
|
||||||
|
int TotalFiles,
|
||||||
|
long TransferredBytes,
|
||||||
|
long TotalBytes,
|
||||||
|
double SpeedBytesPerSecond,
|
||||||
|
int DlSlot,
|
||||||
|
int DlQueue,
|
||||||
|
int DlProg,
|
||||||
|
int DlDecomp)>();
|
||||||
|
|
||||||
|
foreach (var transfer in _currentDownloads)
|
||||||
{
|
{
|
||||||
var handler = transfer.Key;
|
var handler = transfer.Key;
|
||||||
var statuses = transfer.Value.Values;
|
var statuses = transfer.Value.Values;
|
||||||
@@ -289,6 +429,36 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
totalBytes += playerTotalBytes;
|
totalBytes += playerTotalBytes;
|
||||||
transferredBytes += playerTransferredBytes;
|
transferredBytes += playerTransferredBytes;
|
||||||
|
|
||||||
|
// per-player W/Q/P/D
|
||||||
|
var playerDlSlot = 0;
|
||||||
|
var playerDlQueue = 0;
|
||||||
|
var playerDlProg = 0;
|
||||||
|
var playerDlDecomp = 0;
|
||||||
|
|
||||||
|
foreach (var entry in transfer.Value)
|
||||||
|
{
|
||||||
|
var fileStatus = entry.Value;
|
||||||
|
switch (fileStatus.DownloadStatus)
|
||||||
|
{
|
||||||
|
case DownloadStatus.WaitingForSlot:
|
||||||
|
playerDlSlot++;
|
||||||
|
totalDlSlot++;
|
||||||
|
break;
|
||||||
|
case DownloadStatus.WaitingForQueue:
|
||||||
|
playerDlQueue++;
|
||||||
|
totalDlQueue++;
|
||||||
|
break;
|
||||||
|
case DownloadStatus.Downloading:
|
||||||
|
playerDlProg++;
|
||||||
|
totalDlProg++;
|
||||||
|
break;
|
||||||
|
case DownloadStatus.Decompressing:
|
||||||
|
playerDlDecomp++;
|
||||||
|
totalDlDecomp++;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
double speed = 0;
|
double speed = 0;
|
||||||
if (playerTotalBytes > 0)
|
if (playerTotalBytes > 0)
|
||||||
{
|
{
|
||||||
@@ -307,7 +477,11 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
playerTotalFiles,
|
playerTotalFiles,
|
||||||
playerTransferredBytes,
|
playerTransferredBytes,
|
||||||
playerTotalBytes,
|
playerTotalBytes,
|
||||||
speed
|
speed,
|
||||||
|
playerDlSlot,
|
||||||
|
playerDlQueue,
|
||||||
|
playerDlProg,
|
||||||
|
playerDlDecomp
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -321,7 +495,7 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
if (totalFiles == 0 || totalBytes == 0)
|
if (totalFiles == 0 || totalBytes == 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
// max speed for scale (clamped)
|
// max speed for per-player bar scale (clamped)
|
||||||
double maxSpeed = perPlayer.Count > 0 ? perPlayer.Max(p => p.SpeedBytesPerSecond) : 0;
|
double maxSpeed = perPlayer.Count > 0 ? perPlayer.Max(p => p.SpeedBytesPerSecond) : 0;
|
||||||
if (maxSpeed <= 0)
|
if (maxSpeed <= 0)
|
||||||
maxSpeed = 1;
|
maxSpeed = 1;
|
||||||
@@ -330,8 +504,11 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
var windowPos = ImGui.GetWindowPos();
|
var windowPos = ImGui.GetWindowPos();
|
||||||
|
|
||||||
// Overall texts
|
// Overall texts
|
||||||
var headerText = $"Downloading {transferredFiles}/{totalFiles} files";
|
var headerText =
|
||||||
var bytesText = $"{UiSharedService.ByteToString(transferredBytes, addSuffix: false)}/{UiSharedService.ByteToString(totalBytes)}";
|
$"Downloading {transferredFiles}/{totalFiles} files [W:{totalDlSlot}/Q:{totalDlQueue}/P:{totalDlProg}/D:{totalDlDecomp}]";
|
||||||
|
|
||||||
|
var bytesText =
|
||||||
|
$"{UiSharedService.ByteToString(transferredBytes, addSuffix: false)}/{UiSharedService.ByteToString(totalBytes)}";
|
||||||
|
|
||||||
var totalSpeed = perPlayer.Sum(p => p.SpeedBytesPerSecond);
|
var totalSpeed = perPlayer.Sum(p => p.SpeedBytesPerSecond);
|
||||||
var speedText = totalSpeed > 0
|
var speedText = totalSpeed > 0
|
||||||
@@ -346,20 +523,18 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
if (bytesSize.X > contentWidth) contentWidth = bytesSize.X;
|
if (bytesSize.X > contentWidth) contentWidth = bytesSize.X;
|
||||||
if (totalSpeedSize.X > contentWidth) contentWidth = totalSpeedSize.X;
|
if (totalSpeedSize.X > contentWidth) contentWidth = totalSpeedSize.X;
|
||||||
|
|
||||||
|
if (_configService.Current.ShowPlayerLinesTransferWindow)
|
||||||
|
{
|
||||||
foreach (var p in perPlayer)
|
foreach (var p in perPlayer)
|
||||||
{
|
{
|
||||||
var playerSpeedText = p.SpeedBytesPerSecond > 0
|
var line =
|
||||||
? $"{UiSharedService.ByteToString((long)p.SpeedBytesPerSecond)}/s"
|
$"{p.Name} [W:{p.DlSlot}/Q:{p.DlQueue}/P:{p.DlProg}/D:{p.DlDecomp}] {p.TransferredFiles}/{p.TotalFiles}";
|
||||||
: "-";
|
|
||||||
|
|
||||||
var line = $"{p.Name}: {p.TransferredFiles}/{p.TotalFiles} " +
|
|
||||||
$"({UiSharedService.ByteToString(p.TransferredBytes, addSuffix: false)}/{UiSharedService.ByteToString(p.TotalBytes)}) " +
|
|
||||||
$"@ {playerSpeedText}";
|
|
||||||
|
|
||||||
var lineSize = ImGui.CalcTextSize(line);
|
var lineSize = ImGui.CalcTextSize(line);
|
||||||
if (lineSize.X > contentWidth)
|
if (lineSize.X > contentWidth)
|
||||||
contentWidth = lineSize.X;
|
contentWidth = lineSize.X;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
var lineHeight = ImGui.GetTextLineHeight();
|
var lineHeight = ImGui.GetTextLineHeight();
|
||||||
var globalBarHeight = lineHeight * 0.8f;
|
var globalBarHeight = lineHeight * 0.8f;
|
||||||
@@ -370,6 +545,7 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
if (boxWidth < minBoxWidth)
|
if (boxWidth < minBoxWidth)
|
||||||
boxWidth = minBoxWidth;
|
boxWidth = minBoxWidth;
|
||||||
|
|
||||||
|
// Box height
|
||||||
float boxHeight = 0;
|
float boxHeight = 0;
|
||||||
boxHeight += padding;
|
boxHeight += padding;
|
||||||
boxHeight += globalBarHeight;
|
boxHeight += globalBarHeight;
|
||||||
@@ -379,7 +555,19 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
boxHeight += lineHeight + spacingY;
|
boxHeight += lineHeight + spacingY;
|
||||||
boxHeight += lineHeight * 1.4f + spacingY;
|
boxHeight += lineHeight * 1.4f + spacingY;
|
||||||
|
|
||||||
boxHeight += perPlayer.Count * (lineHeight + perPlayerBarHeight + spacingY * 2);
|
if (_configService.Current.ShowPlayerLinesTransferWindow)
|
||||||
|
{
|
||||||
|
foreach (var p in perPlayer)
|
||||||
|
{
|
||||||
|
boxHeight += lineHeight + spacingY;
|
||||||
|
|
||||||
|
if (_configService.Current.ShowPlayerSpeedBarsTransferWindow && p.DlProg > 0)
|
||||||
|
{
|
||||||
|
boxHeight += perPlayerBarHeight + spacingY;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
boxHeight += padding;
|
boxHeight += padding;
|
||||||
|
|
||||||
var boxMin = windowPos;
|
var boxMin = windowPos;
|
||||||
@@ -399,25 +587,50 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
if (progress > 1f) progress = 1f;
|
if (progress > 1f) progress = 1f;
|
||||||
|
|
||||||
drawList.AddRectFilled(barMin, barMax, UiSharedService.Color(40, 40, 40, _transferBoxTransparency), 3f);
|
drawList.AddRectFilled(barMin, barMax, UiSharedService.Color(40, 40, 40, _transferBoxTransparency), 3f);
|
||||||
drawList.AddRectFilled(barMin, new Vector2(barMin.X + (barMax.X - barMin.X) * progress, barMax.Y), UiSharedService.Color(UIColors.Get("LightlessPurple")), 3f);
|
drawList.AddRectFilled(
|
||||||
|
barMin,
|
||||||
|
new Vector2(barMin.X + (barMax.X - barMin.X) * progress, barMax.Y),
|
||||||
|
UiSharedService.Color(UIColors.Get("LightlessPurple")),
|
||||||
|
3f
|
||||||
|
);
|
||||||
|
|
||||||
cursor.Y = barMax.Y + padding;
|
cursor.Y = barMax.Y + padding;
|
||||||
|
|
||||||
// Header
|
// Header
|
||||||
UiSharedService.DrawOutlinedFont(drawList, headerText, cursor, UiSharedService.Color(ImGuiColors.DalamudWhite), UiSharedService.Color(0, 0, 0, _transferBoxTransparency), 1);
|
UiSharedService.DrawOutlinedFont(
|
||||||
|
drawList,
|
||||||
|
headerText,
|
||||||
|
cursor,
|
||||||
|
UiSharedService.Color(ImGuiColors.DalamudWhite),
|
||||||
|
UiSharedService.Color(0, 0, 0, _transferBoxTransparency),
|
||||||
|
1
|
||||||
|
);
|
||||||
cursor.Y += lineHeight + spacingY;
|
cursor.Y += lineHeight + spacingY;
|
||||||
|
|
||||||
// Bytes
|
// Bytes
|
||||||
UiSharedService.DrawOutlinedFont(drawList, bytesText, cursor, UiSharedService.Color(ImGuiColors.DalamudWhite), UiSharedService.Color(0, 0, 0, _transferBoxTransparency), 1);
|
UiSharedService.DrawOutlinedFont(
|
||||||
|
drawList,
|
||||||
|
bytesText,
|
||||||
|
cursor,
|
||||||
|
UiSharedService.Color(ImGuiColors.DalamudWhite),
|
||||||
|
UiSharedService.Color(0, 0, 0, _transferBoxTransparency),
|
||||||
|
1
|
||||||
|
);
|
||||||
cursor.Y += lineHeight + spacingY;
|
cursor.Y += lineHeight + spacingY;
|
||||||
|
|
||||||
// Total speed WIP
|
// Total speed
|
||||||
UiSharedService.DrawOutlinedFont(drawList, speedText, cursor, UiSharedService.Color(UIColors.Get("LightlessPurple")), UiSharedService.Color(0, 0, 0, _transferBoxTransparency), 1);
|
UiSharedService.DrawOutlinedFont(
|
||||||
|
drawList,
|
||||||
|
speedText,
|
||||||
|
cursor,
|
||||||
|
UiSharedService.Color(UIColors.Get("LightlessPurple")),
|
||||||
|
UiSharedService.Color(0, 0, 0, _transferBoxTransparency),
|
||||||
|
1
|
||||||
|
);
|
||||||
cursor.Y += lineHeight * 1.4f + spacingY;
|
cursor.Y += lineHeight * 1.4f + spacingY;
|
||||||
|
|
||||||
if (_configService.Current.ShowPlayerLinesTransferWindow)
|
if (_configService.Current.ShowPlayerLinesTransferWindow)
|
||||||
{
|
{
|
||||||
// Per-player lines
|
|
||||||
var orderedPlayers = perPlayer.OrderByDescending(p => p.TotalBytes).ToList();
|
var orderedPlayers = perPlayer.OrderByDescending(p => p.TotalBytes).ToList();
|
||||||
|
|
||||||
foreach (var p in orderedPlayers)
|
foreach (var p in orderedPlayers)
|
||||||
@@ -426,13 +639,31 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
? $"{UiSharedService.ByteToString((long)p.SpeedBytesPerSecond)}/s"
|
? $"{UiSharedService.ByteToString((long)p.SpeedBytesPerSecond)}/s"
|
||||||
: "-";
|
: "-";
|
||||||
|
|
||||||
var line = $"{p.Name}: {p.TransferredFiles}/{p.TotalFiles} " +
|
var labelLine =
|
||||||
|
$"{p.Name} [W:{p.DlSlot}/Q:{p.DlQueue}/P:{p.DlProg}/D:{p.DlDecomp}] {p.TransferredFiles}/{p.TotalFiles}";
|
||||||
|
|
||||||
|
if (!_configService.Current.ShowPlayerSpeedBarsTransferWindow || p.DlProg <= 0)
|
||||||
|
{
|
||||||
|
var fullLine =
|
||||||
|
$"{labelLine} " +
|
||||||
$"({UiSharedService.ByteToString(p.TransferredBytes, addSuffix: false)}/{UiSharedService.ByteToString(p.TotalBytes)}) " +
|
$"({UiSharedService.ByteToString(p.TransferredBytes, addSuffix: false)}/{UiSharedService.ByteToString(p.TotalBytes)}) " +
|
||||||
$"@ {playerSpeedText}";
|
$"@ {playerSpeedText}";
|
||||||
|
|
||||||
UiSharedService.DrawOutlinedFont(
|
UiSharedService.DrawOutlinedFont(
|
||||||
drawList,
|
drawList,
|
||||||
line,
|
fullLine,
|
||||||
|
cursor,
|
||||||
|
UiSharedService.Color(255, 255, 255, _transferBoxTransparency),
|
||||||
|
UiSharedService.Color(0, 0, 0, _transferBoxTransparency),
|
||||||
|
1
|
||||||
|
);
|
||||||
|
cursor.Y += lineHeight + spacingY;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
UiSharedService.DrawOutlinedFont(
|
||||||
|
drawList,
|
||||||
|
labelLine,
|
||||||
cursor,
|
cursor,
|
||||||
UiSharedService.Color(255, 255, 255, _transferBoxTransparency),
|
UiSharedService.Color(255, 255, 255, _transferBoxTransparency),
|
||||||
UiSharedService.Color(0, 0, 0, _transferBoxTransparency),
|
UiSharedService.Color(0, 0, 0, _transferBoxTransparency),
|
||||||
@@ -467,7 +698,26 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
3f
|
3f
|
||||||
);
|
);
|
||||||
|
|
||||||
cursor.Y += perPlayerBarHeight + spacingY * 2;
|
var barText =
|
||||||
|
$"{UiSharedService.ByteToString(p.TransferredBytes, addSuffix: false)}/{UiSharedService.ByteToString(p.TotalBytes)} @ {playerSpeedText}";
|
||||||
|
|
||||||
|
var barTextSize = ImGui.CalcTextSize(barText);
|
||||||
|
|
||||||
|
var barTextPos = new Vector2(
|
||||||
|
barBgMin.X + ((barBgMax.X - barBgMin.X) - barTextSize.X) / 2f - 1,
|
||||||
|
barBgMin.Y + ((perPlayerBarHeight - barTextSize.Y) / 2f) - 1
|
||||||
|
);
|
||||||
|
|
||||||
|
UiSharedService.DrawOutlinedFont(
|
||||||
|
drawList,
|
||||||
|
barText,
|
||||||
|
barTextPos,
|
||||||
|
UiSharedService.Color(255, 255, 255, _transferBoxTransparency),
|
||||||
|
UiSharedService.Color(0, 0, 0, _transferBoxTransparency),
|
||||||
|
1
|
||||||
|
);
|
||||||
|
|
||||||
|
cursor.Y += perPlayerBarHeight + spacingY;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -65,7 +65,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
private readonly UiSharedService _uiShared;
|
private readonly UiSharedService _uiShared;
|
||||||
private readonly IProgress<(int, int, FileCacheEntity)> _validationProgress;
|
private readonly IProgress<(int, int, FileCacheEntity)> _validationProgress;
|
||||||
private readonly NameplateService _nameplateService;
|
private readonly NameplateService _nameplateService;
|
||||||
private readonly NameplateHandler _nameplateHandler;
|
|
||||||
private (int, int, FileCacheEntity) _currentProgress;
|
private (int, int, FileCacheEntity) _currentProgress;
|
||||||
private bool _deleteAccountPopupModalShown = false;
|
private bool _deleteAccountPopupModalShown = false;
|
||||||
private bool _deleteFilesPopupModalShown = false;
|
private bool _deleteFilesPopupModalShown = false;
|
||||||
@@ -170,7 +169,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
IpcManager ipcManager, CacheMonitor cacheMonitor,
|
IpcManager ipcManager, CacheMonitor cacheMonitor,
|
||||||
DalamudUtilService dalamudUtilService, HttpClient httpClient,
|
DalamudUtilService dalamudUtilService, HttpClient httpClient,
|
||||||
NameplateService nameplateService,
|
NameplateService nameplateService,
|
||||||
NameplateHandler nameplateHandler,
|
|
||||||
ActorObjectService actorObjectService) : base(logger, mediator, "Lightless Sync Settings",
|
ActorObjectService actorObjectService) : base(logger, mediator, "Lightless Sync Settings",
|
||||||
performanceCollector)
|
performanceCollector)
|
||||||
{
|
{
|
||||||
@@ -192,7 +190,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
_fileCompactor = fileCompactor;
|
_fileCompactor = fileCompactor;
|
||||||
_uiShared = uiShared;
|
_uiShared = uiShared;
|
||||||
_nameplateService = nameplateService;
|
_nameplateService = nameplateService;
|
||||||
_nameplateHandler = nameplateHandler;
|
|
||||||
_actorObjectService = actorObjectService;
|
_actorObjectService = actorObjectService;
|
||||||
AllowClickthrough = false;
|
AllowClickthrough = false;
|
||||||
AllowPinning = true;
|
AllowPinning = true;
|
||||||
@@ -887,12 +884,30 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
}
|
}
|
||||||
bool showPlayerLinesTransferWindow = _configService.Current.ShowPlayerLinesTransferWindow;
|
bool showPlayerLinesTransferWindow = _configService.Current.ShowPlayerLinesTransferWindow;
|
||||||
|
|
||||||
if (ImGui.Checkbox("Toggle the Player Lines in the Transfer Window", ref showPlayerLinesTransferWindow))
|
if (ImGui.Checkbox("Toggle the player lines in the Transfer Window", ref showPlayerLinesTransferWindow))
|
||||||
{
|
{
|
||||||
_configService.Current.ShowPlayerLinesTransferWindow = showPlayerLinesTransferWindow;
|
_configService.Current.ShowPlayerLinesTransferWindow = showPlayerLinesTransferWindow;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!showPlayerLinesTransferWindow)
|
||||||
|
{
|
||||||
|
_configService.Current.ShowPlayerSpeedBarsTransferWindow = false;
|
||||||
|
ImGui.BeginDisabled();
|
||||||
|
}
|
||||||
|
|
||||||
|
bool showPlayerSpeedBarsTransferWindow = _configService.Current.ShowPlayerSpeedBarsTransferWindow;
|
||||||
|
if (ImGui.Checkbox("Toggle the download bars in player lines in the Transfer Window", ref showPlayerSpeedBarsTransferWindow))
|
||||||
|
{
|
||||||
|
_configService.Current.ShowPlayerSpeedBarsTransferWindow = showPlayerSpeedBarsTransferWindow;
|
||||||
|
_configService.Save();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!showPlayerLinesTransferWindow)
|
||||||
|
{
|
||||||
|
ImGui.EndDisabled();
|
||||||
|
}
|
||||||
|
|
||||||
ImGui.Unindent();
|
ImGui.Unindent();
|
||||||
if (!_configService.Current.ShowTransferWindow) ImGui.EndDisabled();
|
if (!_configService.Current.ShowTransferWindow) ImGui.EndDisabled();
|
||||||
|
|
||||||
@@ -1928,8 +1943,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderLabelOffsetX = (short)offsetX;
|
_configService.Current.LightfinderLabelOffsetX = (short)offsetX;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1937,8 +1950,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderLabelOffsetX = 0;
|
_configService.Current.LightfinderLabelOffsetX = 0;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1953,8 +1964,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderLabelOffsetY = (short)offsetY;
|
_configService.Current.LightfinderLabelOffsetY = (short)offsetY;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1962,8 +1971,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderLabelOffsetY = 0;
|
_configService.Current.LightfinderLabelOffsetY = 0;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1975,8 +1982,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderLabelScale = labelScale;
|
_configService.Current.LightfinderLabelScale = labelScale;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1984,8 +1989,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderLabelScale = 1.0f;
|
_configService.Current.LightfinderLabelScale = 1.0f;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1999,8 +2002,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderAutoAlign = autoAlign;
|
_configService.Current.LightfinderAutoAlign = autoAlign;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2032,7 +2033,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LabelAlignment = option;
|
_configService.Current.LabelAlignment = option;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2053,8 +2053,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderLabelShowOwn = showOwn;
|
_configService.Current.LightfinderLabelShowOwn = showOwn;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2065,8 +2063,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderLabelShowPaired = showPaired;
|
_configService.Current.LightfinderLabelShowPaired = showPaired;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2077,8 +2073,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderLabelShowHidden = showHidden;
|
_configService.Current.LightfinderLabelShowHidden = showHidden;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
}
|
}
|
||||||
_uiShared.DrawHelpText("Toggles Lightfinder label when no nameplate(s) is visible.");
|
_uiShared.DrawHelpText("Toggles Lightfinder label when no nameplate(s) is visible.");
|
||||||
@@ -2091,13 +2085,11 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
{
|
{
|
||||||
_configService.Current.LightfinderLabelUseIcon = useIcon;
|
_configService.Current.LightfinderLabelUseIcon = useIcon;
|
||||||
_configService.Save();
|
_configService.Save();
|
||||||
_nameplateHandler.ClearNameplateCaches();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
_nameplateService.RequestRedraw();
|
||||||
|
|
||||||
if (useIcon)
|
if (useIcon)
|
||||||
{
|
{
|
||||||
RefreshLightfinderIconState();
|
// redo
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -2110,78 +2102,7 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
|
|
||||||
if (useIcon)
|
if (useIcon)
|
||||||
{
|
{
|
||||||
if (!_lightfinderIconInputInitialized)
|
//redo
|
||||||
{
|
|
||||||
RefreshLightfinderIconState();
|
|
||||||
}
|
|
||||||
|
|
||||||
var currentPresetLabel = _lightfinderIconPresetIndex >= 0
|
|
||||||
? $"{GetLightfinderPresetGlyph(_lightfinderIconPresetIndex)} {LightfinderIconPresets[_lightfinderIconPresetIndex].Label}"
|
|
||||||
: "Custom";
|
|
||||||
|
|
||||||
if (ImGui.BeginCombo("Preset Icon", currentPresetLabel))
|
|
||||||
{
|
|
||||||
for (int i = 0; i < LightfinderIconPresets.Length; i++)
|
|
||||||
{
|
|
||||||
var optionGlyph = GetLightfinderPresetGlyph(i);
|
|
||||||
var preview = $"{optionGlyph} {LightfinderIconPresets[i].Label}";
|
|
||||||
var selected = i == _lightfinderIconPresetIndex;
|
|
||||||
if (ImGui.Selectable(preview, selected))
|
|
||||||
{
|
|
||||||
_lightfinderIconInput = NameplateHandler.ToIconEditorString(optionGlyph);
|
|
||||||
_lightfinderIconPresetIndex = i;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (ImGui.Selectable("Custom", _lightfinderIconPresetIndex == -1))
|
|
||||||
{
|
|
||||||
_lightfinderIconPresetIndex = -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
ImGui.EndCombo();
|
|
||||||
}
|
|
||||||
|
|
||||||
var editorBuffer = _lightfinderIconInput;
|
|
||||||
if (ImGui.InputText("Icon Glyph", ref editorBuffer, 16))
|
|
||||||
{
|
|
||||||
_lightfinderIconInput = editorBuffer;
|
|
||||||
_lightfinderIconPresetIndex = -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (ImGui.Button("Apply Icon"))
|
|
||||||
{
|
|
||||||
var normalized = NameplateHandler.NormalizeIconGlyph(_lightfinderIconInput);
|
|
||||||
ApplyLightfinderIcon(normalized, _lightfinderIconPresetIndex);
|
|
||||||
}
|
|
||||||
|
|
||||||
ImGui.SameLine();
|
|
||||||
if (ImGui.Button("Reset Icon"))
|
|
||||||
{
|
|
||||||
var defaultGlyph = NameplateHandler.NormalizeIconGlyph(null);
|
|
||||||
var defaultIndex = -1;
|
|
||||||
for (int i = 0; i < LightfinderIconPresets.Length; i++)
|
|
||||||
{
|
|
||||||
if (string.Equals(GetLightfinderPresetGlyph(i), defaultGlyph, StringComparison.Ordinal))
|
|
||||||
{
|
|
||||||
defaultIndex = i;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (defaultIndex < 0)
|
|
||||||
{
|
|
||||||
defaultIndex = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
ApplyLightfinderIcon(GetLightfinderPresetGlyph(defaultIndex), defaultIndex);
|
|
||||||
}
|
|
||||||
|
|
||||||
var previewGlyph = NameplateHandler.NormalizeIconGlyph(_lightfinderIconInput);
|
|
||||||
ImGui.SameLine();
|
|
||||||
ImGui.AlignTextToFramePadding();
|
|
||||||
ImGui.Text($"Preview: {previewGlyph}");
|
|
||||||
_uiShared.DrawHelpText(
|
|
||||||
"Enter a hex code (e.g. E0BB), pick a preset, or paste an icon character directly.");
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -3852,40 +3773,6 @@ public class SettingsUi : WindowMediatorSubscriberBase
|
|||||||
return (true, failedConversions.Count != 0, sb.ToString());
|
return (true, failedConversions.Count != 0, sb.ToString());
|
||||||
}
|
}
|
||||||
|
|
||||||
private static string GetLightfinderPresetGlyph(int index)
|
|
||||||
{
|
|
||||||
return NameplateHandler.NormalizeIconGlyph(
|
|
||||||
SeIconCharExtensions.ToIconString(LightfinderIconPresets[index].Icon));
|
|
||||||
}
|
|
||||||
|
|
||||||
private void RefreshLightfinderIconState()
|
|
||||||
{
|
|
||||||
var normalized = NameplateHandler.NormalizeIconGlyph(_configService.Current.LightfinderLabelIconGlyph);
|
|
||||||
_lightfinderIconInput = NameplateHandler.ToIconEditorString(normalized);
|
|
||||||
_lightfinderIconInputInitialized = true;
|
|
||||||
|
|
||||||
_lightfinderIconPresetIndex = -1;
|
|
||||||
for (int i = 0; i < LightfinderIconPresets.Length; i++)
|
|
||||||
{
|
|
||||||
if (string.Equals(GetLightfinderPresetGlyph(i), normalized, StringComparison.Ordinal))
|
|
||||||
{
|
|
||||||
_lightfinderIconPresetIndex = i;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private void ApplyLightfinderIcon(string normalizedGlyph, int presetIndex)
|
|
||||||
{
|
|
||||||
_configService.Current.LightfinderLabelIconGlyph = normalizedGlyph;
|
|
||||||
_configService.Save();
|
|
||||||
_nameplateHandler.FlagRefresh();
|
|
||||||
_nameplateService.RequestRedraw();
|
|
||||||
_lightfinderIconInput = NameplateHandler.ToIconEditorString(normalizedGlyph);
|
|
||||||
_lightfinderIconPresetIndex = presetIndex;
|
|
||||||
_lightfinderIconInputInitialized = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void DrawSettingsContent()
|
private void DrawSettingsContent()
|
||||||
{
|
{
|
||||||
if (_apiController.ServerState is ServerState.Connected)
|
if (_apiController.ServerState is ServerState.Connected)
|
||||||
|
|||||||
Reference in New Issue
Block a user