From 863889a34e60385de86f13c6c823bb0b9414b184 Mon Sep 17 00:00:00 2001 From: Jordan Woyak Date: Fri, 11 Oct 2024 18:50:32 -0500 Subject: [PATCH] DolphinQt/MappingIndicator: Use Settings::IsThemeDark instead of reimplementing it. --- Source/Core/DolphinQt/Config/Mapping/MappingIndicator.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Source/Core/DolphinQt/Config/Mapping/MappingIndicator.cpp b/Source/Core/DolphinQt/Config/Mapping/MappingIndicator.cpp index c60c732e37..e057c167f6 100644 --- a/Source/Core/DolphinQt/Config/Mapping/MappingIndicator.cpp +++ b/Source/Core/DolphinQt/Config/Mapping/MappingIndicator.cpp @@ -29,6 +29,7 @@ #include "DolphinQt/Config/Mapping/MappingWidget.h" #include "DolphinQt/QtUtils/ModalMessageBox.h" +#include "DolphinQt/Settings.h" namespace { @@ -96,7 +97,7 @@ QColor MappingIndicator::GetCenterColor() const QColor MappingIndicator::GetDeadZoneColor() const { - QColor color = GetBBoxBrush().color().valueF() > 0.5 ? Qt::black : Qt::white; + QColor color = Settings::Instance().IsThemeDark() ? Qt::white : Qt::black; color.setAlphaF(0.25); return color; } @@ -126,7 +127,7 @@ QColor MappingIndicator::GetAltTextColor() const void MappingIndicator::AdjustGateColor(QColor* color) { - if (GetBBoxBrush().color().valueF() < 0.5) + if (Settings::Instance().IsThemeDark()) color->setHsvF(color->hueF(), color->saturationF(), 1 - color->valueF()); }