From 65237d9c8ced9ff70d7d7044f0ce171320b2fc7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20L=C3=BCbking?= Date: Sat, 23 Apr 2011 17:17:25 +0200 Subject: [PATCH] finegrain decobutton reload so that it doesn't happen with every max/restore event --- client.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/client.cpp b/client.cpp index 31eaa442bc..ee2fef0674 100644 --- a/client.cpp +++ b/client.cpp @@ -2163,7 +2163,10 @@ void Client::updateAllowedActions(bool force) return; // TODO: This could be delayed and compressed - It's only for pagers etc. anyway info->setAllowedActions(allowed_actions); - if (decoration) + + // ONLY if relevant features have changed (and the window didn't just get/loose moveresize for maximization state changes) + const unsigned long relevant = ~(NET::ActionMove|NET::ActionResize); + if (decoration && (allowed_actions & relevant) != (old_allowed_actions & relevant)) decoration->reset(KDecoration::SettingButtons); }