mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-23 01:25:58 +01:00
resize transition fixes + default transitions to false
This commit is contained in:
parent
f755351511
commit
efbc3f8194
2 changed files with 25 additions and 24 deletions
|
@ -105,7 +105,7 @@ void CConfigManager::setDefaultVars() {
|
||||||
configValues["master:no_gaps_when_only"].intValue = 0;
|
configValues["master:no_gaps_when_only"].intValue = 0;
|
||||||
|
|
||||||
configValues["animations:enabled"].intValue = 1;
|
configValues["animations:enabled"].intValue = 1;
|
||||||
configValues["animations:use_resize_transitions"].intValue = 1;
|
configValues["animations:use_resize_transitions"].intValue = 0;
|
||||||
configValues["animations:speed"].floatValue = 7.f;
|
configValues["animations:speed"].floatValue = 7.f;
|
||||||
configValues["animations:curve"].strValue = "default";
|
configValues["animations:curve"].strValue = "default";
|
||||||
configValues["animations:windows_style"].strValue = STRVAL_EMPTY;
|
configValues["animations:windows_style"].strValue = STRVAL_EMPTY;
|
||||||
|
|
|
@ -261,6 +261,7 @@ void CHyprRenderer::renderWindow(CWindow* pWindow, CMonitor* pMonitor, timespec*
|
||||||
|
|
||||||
// clip box for animated offsets
|
// clip box for animated offsets
|
||||||
Vector2D offset;
|
Vector2D offset;
|
||||||
|
if (!ignorePosition) {
|
||||||
if (PWORKSPACE->m_vRenderOffset.vec().x != 0) {
|
if (PWORKSPACE->m_vRenderOffset.vec().x != 0) {
|
||||||
const auto PWSMON = g_pCompositor->getMonitorFromID(PWORKSPACE->m_iMonitorID);
|
const auto PWSMON = g_pCompositor->getMonitorFromID(PWORKSPACE->m_iMonitorID);
|
||||||
const auto PROGRESS = PWORKSPACE->m_vRenderOffset.vec().x / PWSMON->vecSize.x;
|
const auto PROGRESS = PWORKSPACE->m_vRenderOffset.vec().x / PWSMON->vecSize.x;
|
||||||
|
@ -285,9 +286,9 @@ void CHyprRenderer::renderWindow(CWindow* pWindow, CMonitor* pMonitor, timespec*
|
||||||
|
|
||||||
renderdata.x += offset.x;
|
renderdata.x += offset.x;
|
||||||
renderdata.y += offset.y;
|
renderdata.y += offset.y;
|
||||||
|
}
|
||||||
|
|
||||||
// render window decorations first, if not fullscreen full
|
// render window decorations first, if not fullscreen full
|
||||||
|
|
||||||
if (mode == RENDER_PASS_ALL || mode == RENDER_PASS_MAIN) {
|
if (mode == RENDER_PASS_ALL || mode == RENDER_PASS_MAIN) {
|
||||||
if (!pWindow->m_bIsFullscreen || PWORKSPACE->m_efFullscreenMode != FULLSCREEN_FULL) for (auto& wd : pWindow->m_dWindowDecorations)
|
if (!pWindow->m_bIsFullscreen || PWORKSPACE->m_efFullscreenMode != FULLSCREEN_FULL) for (auto& wd : pWindow->m_dWindowDecorations)
|
||||||
wd->draw(pMonitor, renderdata.alpha * renderdata.fadeAlpha / 255.f, offset);
|
wd->draw(pMonitor, renderdata.alpha * renderdata.fadeAlpha / 255.f, offset);
|
||||||
|
@ -298,7 +299,7 @@ void CHyprRenderer::renderWindow(CWindow* pWindow, CMonitor* pMonitor, timespec*
|
||||||
const auto PFB = g_pHyprOpenGL->m_mWindowResizeFramebuffers.find(pWindow);
|
const auto PFB = g_pHyprOpenGL->m_mWindowResizeFramebuffers.find(pWindow);
|
||||||
|
|
||||||
if (PFB != g_pHyprOpenGL->m_mWindowResizeFramebuffers.end() && PFB->second.isAllocated()) {
|
if (PFB != g_pHyprOpenGL->m_mWindowResizeFramebuffers.end() && PFB->second.isAllocated()) {
|
||||||
wlr_box box = {renderdata.x, renderdata.y, renderdata.w, renderdata.h};
|
wlr_box box = {renderdata.x - pMonitor->vecPosition.x, renderdata.y - pMonitor->vecPosition.y, renderdata.w, renderdata.h};
|
||||||
|
|
||||||
// adjust UV (remove when I figure out how to change the size of the fb)
|
// adjust UV (remove when I figure out how to change the size of the fb)
|
||||||
g_pHyprOpenGL->m_RenderData.primarySurfaceUVTopLeft = {0, 0};
|
g_pHyprOpenGL->m_RenderData.primarySurfaceUVTopLeft = {0, 0};
|
||||||
|
|
Loading…
Reference in a new issue