From a0792de58add3dcd3783b1885a35df774f746797 Mon Sep 17 00:00:00 2001 From: Guillaume Meunier Date: Sun, 13 Oct 2024 13:09:26 +0200 Subject: [PATCH] Use the theme color for the selected encoder --- dashboard/settings.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dashboard/settings.cpp b/dashboard/settings.cpp index 4095cb88..50c1adf9 100644 --- a/dashboard/settings.cpp +++ b/dashboard/settings.cpp @@ -441,9 +441,11 @@ void settings::load_settings() selected_rectangle_changed(0); ui->partitionner->set_paint([&](QPainter & painter, QRect rect, const QVariant & data, int index, bool selected) { + QPalette palette = QApplication::palette(); + if (selected) { - painter.fillRect(rect.adjusted(1, 1, 0, 0), QColorConstants::Cyan); + painter.fillRect(rect.adjusted(1, 1, 0, 0), palette.color(QPalette::Highlight)); } auto [encoder_id, codec_id] = data.value>();