From bc134531552b7429e55337fdfb1734a3e8701551 Mon Sep 17 00:00:00 2001 From: Aleksei Bavshin Date: Wed, 15 Sep 2021 22:39:51 +0700 Subject: [PATCH] feat(swaybar-ipc): handle mode update --- src/modules/sway/bar.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/modules/sway/bar.cpp b/src/modules/sway/bar.cpp index 762353c..3179221 100644 --- a/src/modules/sway/bar.cpp +++ b/src/modules/sway/bar.cpp @@ -81,7 +81,8 @@ void BarIpcClient::onIpcEvent(const struct Ipc::ipc_response& res) { void BarIpcClient::onConfigUpdate(const swaybar_config& config) { spdlog::info("config update: {} {} {}", config.id, config.mode, config.position); - // TODO: pass config to bars + bar_config_ = config; + bar_.setMode(bar_config_.mode); } void BarIpcClient::onVisibilityUpdate(bool visible_by_modifier) {