Skip to content

Only precompute the geometry restore when m_interactiveMoveResize.initialQuickTileMode is None

Vlad Zahorodnii requested to merge work/cherry-pick-1a1eaee1 into Plasma/6.0

If the user wants to move a tiled window but changes their mind and tiles the window back to the previous position, quickTileGeometryRestore() will return an error value beacause m_electricMaximizing is true and the m_electricGeometryRestore is the same as the geometry of the window in the last tiled mode.

Now the geometry restore of the tiled window is true when starting interactive move, so we no longer need to precompute it.

Changes for testQuickTilingPointerMove:

We need to attach a new image after the tiling window, so that updateElectricGeometryRestore can obtain the same framegeometry as the framegeometry obtained during actual runtime.

Now testQuickTilingPointerMove can detect the error:If the user wants to move a tiled window but changes their mind and tiles the window back to the previous position, quickTileGeometryRestore() will return an error value beacause m_electricMaximizing is true and the m_electricGeometryRestore is the same as the geometry of the window in the last tiled mode.

Signed-off-by: Jie Liu liujie01@kylinos.cn

(cherry picked from commit 1a1eaee1)

Merge request reports

Loading