From 29afd62e9c9129d526b955140b6eb61b47136683 Mon Sep 17 00:00:00 2001 From: Vlad Zahorodnii Date: Thu, 20 Aug 2020 22:41:58 +0300 Subject: [PATCH] Evaluate window rules only if they are supported There is no point for evaluating window rules for popups and internal clients. --- workspace.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/workspace.cpp b/workspace.cpp index ec1e8a4773..f9fe03655f 100644 --- a/workspace.cpp +++ b/workspace.cpp @@ -910,12 +910,11 @@ void Workspace::slotReconfigure() updateToolWindows(true); RuleBook::self()->load(); - for (auto it = m_allClients.begin(); - it != m_allClients.end(); - ++it) { - (*it)->setupWindowRules(true); - (*it)->applyWindowRules(); - RuleBook::self()->discardUsed(*it, false); + for (AbstractClient *client : m_allClients) { + if (client->supportsWindowRules()) { + client->evaluateWindowRules(); + RuleBook::self()->discardUsed(client, false); + } } if (borderlessMaximizedWindows != options->borderlessMaximizedWindows() &&