[wayland] Introduce better placement checks for ShellClient
Similar to what we have in Client::manage we should not always invoke the Placement algorithm. E.g. an initially fullscreened window should not get placed. This needs to be extended for more checks similar to Client::manage and might indicate that we also need a ShellClient::manage. REVIEW: 125469
This commit is contained in:
parent
0bf64446cd
commit
b587926803
1 changed files with 8 additions and 1 deletions
|
@ -375,7 +375,14 @@ void Workspace::init()
|
|||
[this] (ShellClient *c) {
|
||||
if (!c->isInternal()) {
|
||||
QRect area = clientArea(PlacementArea, Screens::self()->current(), c->desktop());
|
||||
if (!c->isInitialPositionSet()) {
|
||||
bool placementDone = false;
|
||||
if (c->isInitialPositionSet()) {
|
||||
placementDone = true;
|
||||
}
|
||||
if (c->isFullScreen()) {
|
||||
placementDone = true;
|
||||
}
|
||||
if (!placementDone) {
|
||||
Placement::self()->place(c, area);
|
||||
}
|
||||
m_allClients.append(c);
|
||||
|
|
Loading…
Reference in a new issue