From 09b78e18967a7a0db14fa85848efbc9529ef0c4d Mon Sep 17 00:00:00 2001 From: cake Date: Thu, 11 Dec 2025 05:41:53 +0100 Subject: [PATCH] Fixed push color in main tab as well. --- LightlessSync/UI/SyncshellAdminUI.cs | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/LightlessSync/UI/SyncshellAdminUI.cs b/LightlessSync/UI/SyncshellAdminUI.cs index 5830e1f..3db3682 100644 --- a/LightlessSync/UI/SyncshellAdminUI.cs +++ b/LightlessSync/UI/SyncshellAdminUI.cs @@ -211,24 +211,24 @@ public class SyncshellAdminUI : WindowMediatorSubscriberBase var accentHover = accent.WithAlpha(0.90f); var accentActive = accent; - ImGui.PushStyleColor(ImGuiCol.Tab, baseTab); - ImGui.PushStyleColor(ImGuiCol.TabHovered, accentHover); - ImGui.PushStyleColor(ImGuiCol.TabActive, accentActive); - ImGui.PushStyleColor(ImGuiCol.TabUnfocused, baseTabDim); - ImGui.PushStyleColor(ImGuiCol.TabUnfocusedActive, accentActive.WithAlpha(0.80f)); - - using (var tabbar = ImRaii.TabBar("syncshell_tab_" + GroupFullInfo.GID)) + using (ImRaii.PushColor(ImGuiCol.Tab, baseTab)) + using (ImRaii.PushColor(ImGuiCol.TabHovered, accentHover)) + using (ImRaii.PushColor(ImGuiCol.TabActive, accentActive)) + using (ImRaii.PushColor(ImGuiCol.TabUnfocused, baseTabDim)) + using (ImRaii.PushColor(ImGuiCol.TabUnfocusedActive, accentActive.WithAlpha(0.80f))) { - if (tabbar) + using (var tabbar = ImRaii.TabBar("syncshell_tab_" + GroupFullInfo.GID)) { - DrawInvites(perm); - DrawManagement(); - DrawPermission(perm); - DrawProfile(); + if (tabbar) + { + DrawInvites(perm); + DrawManagement(); + DrawPermission(perm); + DrawProfile(); + } } } - ImGui.PopStyleColor(5); ImGui.PopStyleVar(3); ImGuiHelpers.ScaledDummy(2f);