x11window: partially revert 3a28c02f
In some cases it can cause rather than fix problems with maximization
This commit is contained in:
parent
f6d14f1b44
commit
580396e377
1 changed files with 4 additions and 4 deletions
|
@ -4487,23 +4487,23 @@ void X11Window::maximize(MaximizeMode mode)
|
|||
if (closeHeight) {
|
||||
bool tryBottom = titlePos == Qt::BottomEdge;
|
||||
if ((overHeight && titlePos == Qt::TopEdge) || screenArea.top() == clientArea.top()) {
|
||||
r.moveTop(clientArea.top());
|
||||
r.setTop(clientArea.top());
|
||||
} else {
|
||||
tryBottom = true;
|
||||
}
|
||||
if (tryBottom && (overHeight || screenArea.bottom() == clientArea.bottom())) {
|
||||
r.moveBottom(clientArea.bottom());
|
||||
r.setBottom(clientArea.bottom());
|
||||
}
|
||||
}
|
||||
if (closeWidth) {
|
||||
bool tryLeft = titlePos == Qt::LeftEdge;
|
||||
if ((overWidth && titlePos == Qt::RightEdge) || screenArea.right() == clientArea.right()) {
|
||||
r.moveRight(clientArea.right());
|
||||
r.setRight(clientArea.right());
|
||||
} else {
|
||||
tryLeft = true;
|
||||
}
|
||||
if (tryLeft && (overWidth || screenArea.left() == clientArea.left())) {
|
||||
r.moveLeft(clientArea.left());
|
||||
r.setLeft(clientArea.left());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue