From 973aa09f8bfbb24f630698329a51343b5e604d36 Mon Sep 17 00:00:00 2001 From: Kuruyia <8174691+Kuruyia@users.noreply.github.com> Date: Fri, 3 Feb 2023 18:18:44 +0100 Subject: [PATCH] refactor(backlight): fix linter --- src/modules/backlight.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/modules/backlight.cpp b/src/modules/backlight.cpp index 7aa5889d..a46b2968 100644 --- a/src/modules/backlight.cpp +++ b/src/modules/backlight.cpp @@ -325,16 +325,18 @@ bool waybar::modules::Backlight::handleScroll(GdkEventScroll *e) { int new_value = best->get_actual(); if (dir == SCROLL_DIR::UP) { - new_value += abs_step; + new_value += abs_step; } else if (dir == SCROLL_DIR::DOWN) { - new_value -= abs_step; + new_value -= abs_step; } // Clamp the value new_value = std::clamp(new_value, 0, best->get_max()); // Set the new value - auto call_args = Glib::VariantContainerBase(g_variant_new("(ssu)", "backlight", std::string(best->name()).c_str(), new_value)); + auto call_args = Glib::VariantContainerBase( + g_variant_new("(ssu)", "backlight", std::string(best->name()).c_str(), new_value)); + login_proxy_->call_sync("SetBrightness", call_args); return true;