diff options
author | Jeremy Huang <[email protected]> | 2023-09-15 14:13:23 -0700 |
---|---|---|
committer | GitHub <[email protected]> | 2023-09-15 22:13:23 +0100 |
commit | cc630c90b5d743b380ff2da741881796ec79e997 (patch) | |
tree | b60dfa4e8d40b1a7e6076760659123a257a41fd7 /src/layout/MasterLayout.cpp | |
parent | b9b38424b0c431ddb43109e029893765a7422a32 (diff) | |
download | Hyprland-cc630c90b5d743b380ff2da741881796ec79e997.tar.gz Hyprland-cc630c90b5d743b380ff2da741881796ec79e997.zip |
master: partially revert 0e64dd2e and fix the animation (#3327)
Diffstat (limited to 'src/layout/MasterLayout.cpp')
-rw-r--r-- | src/layout/MasterLayout.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/layout/MasterLayout.cpp b/src/layout/MasterLayout.cpp index a4ab9d8a..d1b65e59 100644 --- a/src/layout/MasterLayout.cpp +++ b/src/layout/MasterLayout.cpp @@ -636,7 +636,7 @@ void CHyprMasterLayout::applyNodeDataToWindow(SMasterNodeData* pNode) { g_pXWaylandManager->setWindowSize(PWINDOW, calcSize); } - if (!*PANIMATE) { + if (m_bForceWarps && !*PANIMATE) { g_pHyprRenderer->damageWindow(PWINDOW); PWINDOW->m_vRealPosition.warp(); @@ -691,6 +691,8 @@ void CHyprMasterLayout::resizeActiveWindow(const Vector2D& pixResize, eRectCorne if (getNodesOnWorkspace(PWINDOW->m_iWorkspaceID) == 1 && !centered) return; + m_bForceWarps = true; + switch (orientation) { case ORIENTATION_LEFT: delta = pixResize.x / PMONITOR->vecSize.x; break; case ORIENTATION_RIGHT: delta = -pixResize.x / PMONITOR->vecSize.x; break; @@ -788,6 +790,8 @@ void CHyprMasterLayout::resizeActiveWindow(const Vector2D& pixResize, eRectCorne } recalculateMonitor(PMONITOR->ID); + + m_bForceWarps = false; } void CHyprMasterLayout::fullscreenRequestForWindow(CWindow* pWindow, eFullscreenMode fullscreenMode, bool on) { |