don't place windows with invalid geometry
if a window has a size of 0x0, doesn't have its final place yet, so it can't be reliably placed centered yet
This commit is contained in:
parent
811beb94e0
commit
ada29cfc9a
1 changed files with 4 additions and 0 deletions
|
@ -458,6 +458,10 @@ void Placement::placeCentered(AbstractClient* c, const QRect& area, Policy /*nex
|
|||
{
|
||||
Q_ASSERT(area.isValid());
|
||||
|
||||
if (!c->frameGeometry().isValid()) {
|
||||
return;
|
||||
}
|
||||
|
||||
const int xp = area.left() + (area.width() - c->width()) / 2;
|
||||
const int yp = area.top() + (area.height() - c->height()) / 2;
|
||||
|
||||
|
|
Loading…
Reference in a new issue