preserve actual geom_restore on QuickTileMaximize

BUG: 342981
REVIEW: 122118

The geometry of the window when entering QTM is
a technical detail (caused by the maximizing action
of moving the window to the upper edge) and thus
does not qualify as geometry the window should be
restored to (using a deoc button, shortcut etc.)
icc-effect-5.14.5
Thomas Lübking 2015-01-17 23:55:38 +01:00
parent 55d29bd310
commit f82a6a545c
1 changed files with 2 additions and 0 deletions

View File

@ -3134,6 +3134,7 @@ void Client::setQuickTileMode(QuickTileMode mode, bool keyboard)
if (maximizeMode() == MaximizeFull) {
setMaximize(false, false);
} else {
QRect prev_geom_restore = geom_restore; // setMaximize() would set moveResizeGeom as geom_restore
setMaximize(true, true);
QRect clientArea = workspace()->clientArea(MaximizeArea, this);
if (geometry().top() != clientArea.top()) {
@ -3142,6 +3143,7 @@ void Client::setQuickTileMode(QuickTileMode mode, bool keyboard)
setGeometry(r);
}
quick_tile_mode = QuickTileMaximize;
geom_restore = prev_geom_restore;
}
emit quickTileModeChanged();
return;