Move finishMoveResize(bool) to AbstractClient
This commit is contained in:
parent
1c40e809ea
commit
ba53407b52
3 changed files with 4 additions and 2 deletions
|
@ -696,6 +696,7 @@ protected:
|
|||
* Sets an appropriate cursor shape for the logical mouse position.
|
||||
*/
|
||||
void updateCursor();
|
||||
void finishMoveResize(bool cancel);
|
||||
/**
|
||||
* Leaves the move resize mode.
|
||||
*
|
||||
|
|
1
client.h
1
client.h
|
@ -544,7 +544,6 @@ private:
|
|||
void getSyncCounter();
|
||||
void sendSyncRequest();
|
||||
bool startMoveResize();
|
||||
void finishMoveResize(bool cancel);
|
||||
void leaveMoveResize() override;
|
||||
void handleMoveResize(int x, int y, int x_root, int y_root);
|
||||
void handleMoveResize(const QPoint &local, const QPoint &global);
|
||||
|
|
|
@ -2666,7 +2666,7 @@ bool Client::startMoveResize()
|
|||
return true;
|
||||
}
|
||||
|
||||
void Client::finishMoveResize(bool cancel)
|
||||
void AbstractClient::finishMoveResize(bool cancel)
|
||||
{
|
||||
const bool wasResize = isResize(); // store across leaveMoveResize
|
||||
leaveMoveResize();
|
||||
|
@ -2697,6 +2697,7 @@ void Client::finishMoveResize(bool cancel)
|
|||
setQuickTileMode(electricBorderMode());
|
||||
setElectricBorderMaximizing(false);
|
||||
} else if (!cancel) {
|
||||
QRect geom_restore = geometryRestore();
|
||||
if (!(maximizeMode() & MaximizeHorizontal)) {
|
||||
geom_restore.setX(geometry().x());
|
||||
geom_restore.setWidth(geometry().width());
|
||||
|
@ -2705,6 +2706,7 @@ void Client::finishMoveResize(bool cancel)
|
|||
geom_restore.setY(geometry().y());
|
||||
geom_restore.setHeight(geometry().height());
|
||||
}
|
||||
setGeometryRestore(geom_restore);
|
||||
}
|
||||
// FRAME update();
|
||||
|
||||
|
|
Loading…
Reference in a new issue