summaryrefslogtreecommitdiff
path: root/src/Window.cpp
diff options
context:
space:
mode:
authorvaxerski <43317083+vaxerski@users.noreply.github.com>2022-07-16 12:44:45 +0200
committervaxerski <43317083+vaxerski@users.noreply.github.com>2022-07-16 12:44:45 +0200
commit48e5bd96bc71f94f774eb92b00ef560b2f911c73 (patch)
tree3d703572b5c7b68068c712f90ed10238846dd714 /src/Window.cpp
parentb2650928eac06e3181ad07efe6ec55b2550f89b8 (diff)
Added shadow colors animations and inactive col
Diffstat (limited to 'src/Window.cpp')
-rw-r--r--src/Window.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/Window.cpp b/src/Window.cpp
index 8c8cd147..5568d082 100644
--- a/src/Window.cpp
+++ b/src/Window.cpp
@@ -8,6 +8,7 @@ CWindow::CWindow() {
m_cRealBorderColor.create(AVARTYPE_COLOR, &g_pConfigManager->getConfigValuePtr("animations:borders_speed")->floatValue, &g_pConfigManager->getConfigValuePtr("animations:borders")->intValue, &g_pConfigManager->getConfigValuePtr("animations:borders_curve")->strValue, (void*)this, AVARDAMAGE_BORDER);
m_fAlpha.create(AVARTYPE_FLOAT, &g_pConfigManager->getConfigValuePtr("animations:fadein_speed")->floatValue, &g_pConfigManager->getConfigValuePtr("animations:fadein")->intValue, &g_pConfigManager->getConfigValuePtr("animations:fadein_curve")->strValue, (void*)this, AVARDAMAGE_ENTIRE);
m_fActiveInactiveAlpha.create(AVARTYPE_FLOAT, &g_pConfigManager->getConfigValuePtr("animations:fadein_speed")->floatValue, &g_pConfigManager->getConfigValuePtr("animations:fadein")->intValue, &g_pConfigManager->getConfigValuePtr("animations:fadein_curve")->strValue, (void*)this, AVARDAMAGE_ENTIRE);
+ m_cRealShadowColor.create(AVARTYPE_COLOR, &g_pConfigManager->getConfigValuePtr("animations:borders_speed")->floatValue, &g_pConfigManager->getConfigValuePtr("animations:borders")->intValue, &g_pConfigManager->getConfigValuePtr("animations:borders_curve")->strValue, (void*)this, AVARDAMAGE_SHADOW);
m_dWindowDecorations.emplace_back(std::make_unique<CHyprDropShadowDecoration>(this)); // put the shadow so it's the first deco (has to be rendered first)
}
@@ -103,3 +104,12 @@ pid_t CWindow::getPID() {
return PID;
}
+
+IHyprWindowDecoration* CWindow::getDecorationByType(eDecorationType type) {
+ for (auto& wd : m_dWindowDecorations) {
+ if (wd->getDecorationType() == type)
+ return wd.get();
+ }
+
+ return nullptr;
+} \ No newline at end of file