T1C: window dance compat

This commit is contained in:
vaxerski 2022-10-20 22:38:49 +01:00
parent 6df6aea1ba
commit ce5f025428
3 changed files with 6 additions and 1 deletions

View file

@ -26,6 +26,7 @@ struct SWindowAdditionalConfigData {
bool forceNoAnims = false; bool forceNoAnims = false;
bool forceNoBorder = false; bool forceNoBorder = false;
bool forceNoShadow = false; bool forceNoShadow = false;
bool windowDanceCompat = false;
}; };
class CWindow { class CWindow {

View file

@ -761,6 +761,7 @@ bool windowRuleValid(const std::string& RULE) {
&& RULE != "fullscreen" && RULE != "fullscreen"
&& RULE != "pin" && RULE != "pin"
&& RULE != "noanim" && RULE != "noanim"
&& RULE != "windowdance"
&& RULE.find("animation") != 0 && RULE.find("animation") != 0
&& RULE.find("rounding") != 0 && RULE.find("rounding") != 0
&& RULE.find("workspace") != 0); && RULE.find("workspace") != 0);

View file

@ -169,6 +169,8 @@ void Events::listener_mapWindow(void* owner, void* data) {
requestsFullscreen = true; requestsFullscreen = true;
} else if (r.szRule == "opaque") { } else if (r.szRule == "opaque") {
PWINDOW->m_sAdditionalConfigData.forceOpaque = true; PWINDOW->m_sAdditionalConfigData.forceOpaque = true;
} else if (r.szRule == "windowdance") {
PWINDOW->m_sAdditionalConfigData.windowDanceCompat = true;
} else if (r.szRule == "forceinput") { } else if (r.szRule == "forceinput") {
PWINDOW->m_sAdditionalConfigData.forceAllowsInput = true; PWINDOW->m_sAdditionalConfigData.forceAllowsInput = true;
} else if (r.szRule == "pin") { } else if (r.szRule == "pin") {
@ -737,7 +739,8 @@ void Events::listener_configureX11(void* owner, void* data) {
PWINDOW->m_bCreatedOverFullscreen = true; PWINDOW->m_bCreatedOverFullscreen = true;
g_pInputManager->refocus(); if (!PWINDOW->m_sAdditionalConfigData.windowDanceCompat)
g_pInputManager->refocus();
g_pHyprRenderer->damageWindow(PWINDOW); g_pHyprRenderer->damageWindow(PWINDOW);