finegrain decobutton reload so that it doesn't happen with every max/restore event

icc-effect-5.14.5
Thomas Lübking 2011-04-23 17:17:25 +02:00
parent 2133d56fb6
commit 65237d9c8c
1 changed files with 4 additions and 1 deletions

View File

@ -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);
}