select minimum layer per screen
BUG: 261799 REVIEW: 104186
This commit is contained in:
parent
21b859e520
commit
dbea548a43
1 changed files with 15 additions and 12 deletions
27
layers.cpp
27
layers.cpp
|
@ -515,20 +515,23 @@ ClientList Workspace::constrainedStackingOrder()
|
||||||
kDebug(1212) << (void*)(*it) << *it << ":" << (*it)->layer();
|
kDebug(1212) << (void*)(*it) << *it << ":" << (*it)->layer();
|
||||||
#endif
|
#endif
|
||||||
// build the order from layers
|
// build the order from layers
|
||||||
QHash< Group*, Layer > minimum_layer;
|
QVector< QMap<Group*, Layer> > minimum_layer(numScreens());
|
||||||
for (ClientList::ConstIterator it = unconstrained_stacking_order.constBegin();
|
for (ClientList::ConstIterator it = unconstrained_stacking_order.constBegin(),
|
||||||
it != unconstrained_stacking_order.constEnd();
|
end = unconstrained_stacking_order.constEnd(); it != end; ++it) {
|
||||||
++it) {
|
|
||||||
Layer l = (*it)->layer();
|
Layer l = (*it)->layer();
|
||||||
// If a window is raised above some other window in the same window group
|
|
||||||
// which is in the ActiveLayer (i.e. it's fulscreened), make sure it stays
|
const int screen = (*it)->screen();
|
||||||
// above that window (see #95731).
|
QMap< Group*, Layer >::iterator mLayer = minimum_layer[screen].find((*it)->group());
|
||||||
if (minimum_layer.contains((*it)->group())
|
if (mLayer != minimum_layer[screen].end()) {
|
||||||
&& minimum_layer[(*it)->group()] == ActiveLayer
|
// If a window is raised above some other window in the same window group
|
||||||
&& (l == NormalLayer || l == AboveLayer)) {
|
// which is in the ActiveLayer (i.e. it's fulscreened), make sure it stays
|
||||||
l = minimum_layer[(*it)->group()];
|
// above that window (see #95731).
|
||||||
|
if (*mLayer == ActiveLayer && (l == NormalLayer || l == AboveLayer))
|
||||||
|
l = ActiveLayer;
|
||||||
|
*mLayer = l;
|
||||||
|
} else {
|
||||||
|
minimum_layer[screen].insertMulti((*it)->group(), l);
|
||||||
}
|
}
|
||||||
minimum_layer[(*it)->group()] = l;
|
|
||||||
layer[ l ].append(*it);
|
layer[ l ].append(*it);
|
||||||
}
|
}
|
||||||
ClientList stacking;
|
ClientList stacking;
|
||||||
|
|
Loading…
Reference in a new issue