From de04d362da3b8b31a2ddc2e2c2cc62ae9f4deb52 Mon Sep 17 00:00:00 2001 From: Vlad Zagorodniy Date: Mon, 14 Jan 2019 22:03:15 +0200 Subject: [PATCH] [kcmkwin/rules] Return absolute path of decoration color scheme Summary: We need to return the absolute path instead of base name so decoColorToCombo can return the correct index. Test Plan: * Go to System Settings > Window Management > Window Rules; * Create a new rule for Konsole to force the Oxygen color scheme, close the dialog, and click the Apply button; * Open the rules dialog (you don't have to modify anything), click OK button, then Apply button. Without this patch, Breeze color scheme will be forced after the last step. Reviewers: #kwin, davidedmundson Reviewed By: #kwin, davidedmundson Subscribers: graesslin, broulik, kwin Tags: #kwin Differential Revision: https://phabricator.kde.org/D17655 --- kcmkwin/kwinrules/ruleswidget.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kcmkwin/kwinrules/ruleswidget.cpp b/kcmkwin/kwinrules/ruleswidget.cpp index 9fb889374a..4228820ad2 100644 --- a/kcmkwin/kwinrules/ruleswidget.cpp +++ b/kcmkwin/kwinrules/ruleswidget.cpp @@ -629,7 +629,7 @@ Rules* RulesWidget::rules() const CHECKBOX_SET_RULE(below,); CHECKBOX_SET_RULE(noborder,); auto comboToDecocolor = [this](int index) -> QString { - return QFileInfo(decocolor->itemData(index).toString()).baseName(); + return decocolor->itemData(index).toString(); }; COMBOBOX_FORCE_RULE(decocolor, comboToDecocolor); CHECKBOX_SET_RULE(skiptaskbar,);