Skip to content

Commit

Permalink
allow 0ms and force
Browse files Browse the repository at this point in the history
  • Loading branch information
bvr-yr committed Mar 10, 2024
1 parent dcf75cc commit 898fd5c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/renderer/widgets/Label.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ void CLabel::onTimerUpdate() {
void CLabel::plantTimer() {
if (label.updateEveryMs != 0)
labelTimer = g_pHyprlock->addTimer(std::chrono::milliseconds((int)label.updateEveryMs), onTimer, this, label.allowForceUpdate);
else if (label.updateEveryMs == 0 && label.allowForceUpdate)
labelTimer = g_pHyprlock->addTimer(std::chrono::hours(1), onTimer, this, true);
}

CLabel::CLabel(const Vector2D& viewport_, const std::unordered_map<std::string, std::any>& props, const std::string& output) :
Expand Down

0 comments on commit 898fd5c

Please sign in to comment.