diff --git a/client.h b/client.h index c916029e38..26c7c74be8 100644 --- a/client.h +++ b/client.h @@ -586,6 +586,7 @@ private: Window move_resize_grab_window; bool move_resize_has_keyboard_grab; bool unrestrictedMoveResize; + int moveResizeStartScreen; Position mode; QPoint moveOffset; diff --git a/geometry.cpp b/geometry.cpp index cd9d7a08f4..69eb5661ba 100644 --- a/geometry.cpp +++ b/geometry.cpp @@ -2580,6 +2580,7 @@ bool Client::startMoveResize() } moveResizeMode = true; + moveResizeStartScreen = screen(); workspace()->setClientIsMoving(this); initialMoveResizeGeom = moveResizeGeom = geometry(); checkUnrestrictedMoveResize(); @@ -2644,7 +2645,7 @@ void Client::finishMoveResize(bool cancel) setGeometry(initialMoveResizeGeom); else setGeometry(moveResizeGeom); - if (maximizeMode() != MaximizeRestore) + if (screen() != moveResizeStartScreen && maximizeMode() != MaximizeRestore) checkWorkspacePosition(); } #else