windowrules: rewrite completely (#12269)
Reworks the window rule syntax completely --------- Co-authored-by: Mihai Fufezan <mihai@fufexan.net>
This commit is contained in:
parent
95ee08b340
commit
c2670e9ab9
93 changed files with 3574 additions and 2255 deletions
|
|
@ -1670,7 +1670,7 @@ void CHyprOpenGLImpl::renderTextureInternal(SP<CTexture> tex, const CBox& box, c
|
|||
}
|
||||
}
|
||||
|
||||
if (m_renderData.currentWindow && m_renderData.currentWindow->m_windowData.RGBX.valueOrDefault()) {
|
||||
if (m_renderData.currentWindow && m_renderData.currentWindow->m_ruleApplicator->RGBX().valueOrDefault()) {
|
||||
shader = &m_shaders->m_shRGBX;
|
||||
texType = TEXTURE_RGBX;
|
||||
}
|
||||
|
|
@ -2195,7 +2195,7 @@ void CHyprOpenGLImpl::preRender(PHLMONITOR pMonitor) {
|
|||
if (!pWindow)
|
||||
return false;
|
||||
|
||||
if (pWindow->m_windowData.noBlur.valueOrDefault())
|
||||
if (pWindow->m_ruleApplicator->noBlur().valueOrDefault())
|
||||
return false;
|
||||
|
||||
if (pWindow->m_wlSurface->small() && !pWindow->m_wlSurface->m_fillIgnoreSmall)
|
||||
|
|
@ -2239,7 +2239,7 @@ void CHyprOpenGLImpl::preRender(PHLMONITOR pMonitor) {
|
|||
for (auto const& m : g_pCompositor->m_monitors) {
|
||||
for (auto const& lsl : m->m_layerSurfaceLayers) {
|
||||
for (auto const& ls : lsl) {
|
||||
if (!ls->m_layerSurface || ls->m_xray != 1)
|
||||
if (!ls->m_layerSurface || ls->m_ruleApplicator->xray().valueOrDefault() != 1)
|
||||
continue;
|
||||
|
||||
// if (ls->layerSurface->surface->opaque && ls->alpha->value() >= 1.f)
|
||||
|
|
@ -2311,16 +2311,16 @@ bool CHyprOpenGLImpl::shouldUseNewBlurOptimizations(PHLLS pLayer, PHLWINDOW pWin
|
|||
if (!m_renderData.pCurrentMonData->blurFB.getTexture())
|
||||
return false;
|
||||
|
||||
if (pWindow && pWindow->m_windowData.xray.hasValue() && !pWindow->m_windowData.xray.valueOrDefault())
|
||||
if (pWindow && pWindow->m_ruleApplicator->xray().hasValue() && !pWindow->m_ruleApplicator->xray().valueOrDefault())
|
||||
return false;
|
||||
|
||||
if (pLayer && pLayer->m_xray == 0)
|
||||
if (pLayer && pLayer->m_ruleApplicator->xray().valueOrDefault() == 0)
|
||||
return false;
|
||||
|
||||
if ((*PBLURNEWOPTIMIZE && pWindow && !pWindow->m_isFloating && !pWindow->onSpecialWorkspace()) || *PBLURXRAY)
|
||||
return true;
|
||||
|
||||
if ((pLayer && pLayer->m_xray == 1) || (pWindow && pWindow->m_windowData.xray.valueOrDefault()))
|
||||
if ((pLayer && pLayer->m_ruleApplicator->xray().valueOrDefault() == 1) || (pWindow && pWindow->m_ruleApplicator->xray().valueOrDefault()))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
|
|
@ -2474,7 +2474,7 @@ void CHyprOpenGLImpl::renderBorder(const CBox& box, const CGradientValueData& gr
|
|||
|
||||
TRACY_GPU_ZONE("RenderBorder");
|
||||
|
||||
if (m_renderData.damage.empty() || (m_renderData.currentWindow && m_renderData.currentWindow->m_windowData.noBorder.valueOrDefault()))
|
||||
if (m_renderData.damage.empty())
|
||||
return;
|
||||
|
||||
CBox newBox = box;
|
||||
|
|
@ -2558,7 +2558,7 @@ void CHyprOpenGLImpl::renderBorder(const CBox& box, const CGradientValueData& gr
|
|||
|
||||
TRACY_GPU_ZONE("RenderBorder2");
|
||||
|
||||
if (m_renderData.damage.empty() || (m_renderData.currentWindow && m_renderData.currentWindow->m_windowData.noBorder.valueOrDefault()))
|
||||
if (m_renderData.damage.empty())
|
||||
return;
|
||||
|
||||
CBox newBox = box;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue