Move layer updating for setActive back to AbstractClient
AbstractClient now also supports mainClients, so we can do the fullscreen window check on setActive in a general way. This ensures that we do get proper stacking changes for activating fullscreen shell clients.
This commit is contained in:
parent
b587926803
commit
b5255de4b6
2 changed files with 9 additions and 9 deletions
|
@ -180,6 +180,15 @@ void AbstractClient::setActive(bool act)
|
||||||
if (!m_active && shadeMode() == ShadeActivated)
|
if (!m_active && shadeMode() == ShadeActivated)
|
||||||
setShade(ShadeNormal);
|
setShade(ShadeNormal);
|
||||||
|
|
||||||
|
StackingUpdatesBlocker blocker(workspace());
|
||||||
|
workspace()->updateClientLayer(this); // active windows may get different layer
|
||||||
|
auto mainclients = mainClients();
|
||||||
|
for (auto it = mainclients.constBegin();
|
||||||
|
it != mainclients.constEnd();
|
||||||
|
++it)
|
||||||
|
if ((*it)->isFullScreen()) // fullscreens go high even if their transient is active
|
||||||
|
workspace()->updateClientLayer(*it);
|
||||||
|
|
||||||
doSetActive();
|
doSetActive();
|
||||||
emit activeChanged();
|
emit activeChanged();
|
||||||
updateMouseGrab();
|
updateMouseGrab();
|
||||||
|
|
|
@ -788,15 +788,6 @@ xcb_timestamp_t Client::userTime() const
|
||||||
|
|
||||||
void Client::doSetActive()
|
void Client::doSetActive()
|
||||||
{
|
{
|
||||||
StackingUpdatesBlocker blocker(workspace());
|
|
||||||
workspace()->updateClientLayer(this); // active windows may get different layer
|
|
||||||
auto mainclients = mainClients();
|
|
||||||
for (auto it = mainclients.constBegin();
|
|
||||||
it != mainclients.constEnd();
|
|
||||||
++it)
|
|
||||||
if ((*it)->isFullScreen()) // fullscreens go high even if their transient is active
|
|
||||||
workspace()->updateClientLayer(*it);
|
|
||||||
|
|
||||||
updateUrgency(); // demand attention again if it's still urgent
|
updateUrgency(); // demand attention again if it's still urgent
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue