diff options
| author | vaxerski <43317083+vaxerski@users.noreply.github.com> | 2023-02-25 17:39:26 +0000 |
|---|---|---|
| committer | vaxerski <43317083+vaxerski@users.noreply.github.com> | 2023-02-25 17:39:26 +0000 |
| commit | cf566b59ce980790bc60dac8adf4df9ec8bcf9f9 (patch) | |
| tree | f6bbcfebc80d0ca8643c17fc2d47e6f717d18a00 /src/config/ConfigManager.cpp | |
| parent | 1089e858b49975a4b9f6e49d377726ee4f164f96 (diff) | |
allow blurls by address
Diffstat (limited to 'src/config/ConfigManager.cpp')
| -rw-r--r-- | src/config/ConfigManager.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/config/ConfigManager.cpp b/src/config/ConfigManager.cpp index 018eb420..35023b8e 100644 --- a/src/config/ConfigManager.cpp +++ b/src/config/ConfigManager.cpp @@ -929,10 +929,20 @@ void CConfigManager::handleWindowRuleV2(const std::string& command, const std::s } void CConfigManager::updateBlurredLS(const std::string& name, const bool forceBlur) { + const bool BYADDRESS = name.find("address:") == 0; + std::string matchName = name; + + if (BYADDRESS) { + matchName = matchName.substr(9); + } + for (auto& m : g_pCompositor->m_vMonitors) { for (auto& lsl : m->m_aLayerSurfaceLayers) { for (auto& ls : lsl) { - if (ls->szNamespace == name) + if (BYADDRESS) { + if (getFormat("0x%x", ls.get()) == matchName) + ls->forceBlur = forceBlur; + } else if (ls->szNamespace == matchName) ls->forceBlur = forceBlur; } } |
