Simplify AbstractClient::applyWindowRules()

Trying to reconstrain the geometry after applying rules is unnecessary
because if the geometry is forced using a rule, resizeWithChecks()
should not change it; if the window is maximized or has entered fullscreen
mode, window gravity is irrelevant. If the window is shaded, this
resizeWithChecks() is not needed.

This change simplifies AbstractClient::applyWindowRules(), which allows
to split adjustedSize() to further simplify geometry handling.
This commit is contained in:
Vlad Zahorodnii 2021-10-14 20:32:41 +03:00
parent 3e77907d21
commit a195290600

View file

@ -892,10 +892,6 @@ void AbstractClient::applyWindowRules()
if (workspace()->mostRecentlyActivatedClient() == this
&& !client_rules->checkAcceptFocus(true))
workspace()->activateNextClient(this);
// Closeable
QSize s = adjustedSize();
if (s != size() && s.isValid())
resizeWithChecks(s);
// Autogrouping : Only checked on window manage
// AutogroupInForeground : Only checked on window manage
// AutogroupById : Only checked on window manage