edit: rainbow_style.cpp

Signed-off-by: Collecting <collecting@noreply.localhost>
This commit is contained in:
Collecting
2025-12-23 19:35:19 +00:00
parent 78f1b94743
commit 2e0ab11551

View File

@@ -4,8 +4,8 @@
#include "citron/uisettings.h" #include "citron/uisettings.h"
#include "citron/theme.h" #include "citron/theme.h"
#include <QApplication> #include <QApplication>
#include <QPalette> #include <QColor>
#include <QWidget> #include <QTimer>
float RainbowStyle::s_hue = 0.0f; float RainbowStyle::s_hue = 0.0f;
@@ -16,10 +16,10 @@ RainbowStyle::RainbowStyle(QStyle* baseStyle) : QProxyStyle(baseStyle) {
} }
void RainbowStyle::UpdateHue() { void RainbowStyle::UpdateHue() {
if (UISettings::values.enable_rainbow_mode.GetValue()) { if (UISettings::values.enable_rainbow_mode.GetValue()) {
s_hue += 0.005f; s_hue += 0.005f;
if (s_hue > 1.0f) s_hue = 0.0f; if (s_hue > 1.0f) s_hue = 0.0f;
} }
} }
QColor RainbowStyle::GetCurrentHighlightColor() { QColor RainbowStyle::GetCurrentHighlightColor() {