From 17ef806444fee729d00b3ba5cb8c623b7fbb699b Mon Sep 17 00:00:00 2001 From: Vaxry Date: Tue, 17 Dec 2024 00:27:36 +0000 Subject: [PATCH] hyprbars: chase hyprland --- hyprbars/barDeco.cpp | 10 +++++----- hyprbars/barDeco.hpp | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/hyprbars/barDeco.cpp b/hyprbars/barDeco.cpp index cf0ed92..99dbf87 100644 --- a/hyprbars/barDeco.cpp +++ b/hyprbars/barDeco.cpp @@ -562,13 +562,13 @@ void CHyprBar::updateRules() { m_bTitleColorChanged = true; } -void CHyprBar::applyRule(const SWindowRule& r) { - auto arg = r.szRule.substr(r.szRule.find_first_of(' ') + 1); +void CHyprBar::applyRule(const SP& r) { + auto arg = r->szRule.substr(r->szRule.find_first_of(' ') + 1); - if (r.szRule == "plugin:hyprbars:nobar") + if (r->szRule == "plugin:hyprbars:nobar") m_bHidden = true; - else if (r.szRule.starts_with("plugin:hyprbars:bar_color")) + else if (r->szRule.starts_with("plugin:hyprbars:bar_color")) m_bForcedBarColor = CHyprColor(configStringToInt(arg).value_or(0)); - else if (r.szRule.starts_with("plugin:hyprbars:title_color")) + else if (r->szRule.starts_with("plugin:hyprbars:title_color")) m_bForcedTitleColor = CHyprColor(configStringToInt(arg).value_or(0)); } diff --git a/hyprbars/barDeco.hpp b/hyprbars/barDeco.hpp index b63407d..070b1b1 100644 --- a/hyprbars/barDeco.hpp +++ b/hyprbars/barDeco.hpp @@ -35,7 +35,7 @@ class CHyprBar : public IHyprWindowDecoration { PHLWINDOW getOwner(); void updateRules(); - void applyRule(const SWindowRule&); + void applyRule(const SP&); private: SBoxExtents m_seExtents;