Merge pull request #4973 from cebem1nt/group-ref-fix

Group ref fix
This commit is contained in:
Alexis Rouillard
2026-04-07 12:38:44 +02:00
committed by GitHub
2 changed files with 6 additions and 1 deletions
+1 -1
View File
@@ -541,7 +541,7 @@ void waybar::Bar::getModules(const Factory& factory, const std::string& pos,
auto vertical = (group != nullptr ? group->getBox().get_orientation() auto vertical = (group != nullptr ? group->getBox().get_orientation()
: box_.get_orientation()) == Gtk::ORIENTATION_VERTICAL; : box_.get_orientation()) == Gtk::ORIENTATION_VERTICAL;
auto group_config = config[ref]; const Json::Value& group_config = config[ref];
if (group_config["modules"].isNull()) { if (group_config["modules"].isNull()) {
spdlog::warn("Group definition '{}' has not been found, group will be hidden", ref); spdlog::warn("Group definition '{}' has not been found, group will be hidden", ref);
} }
+5
View File
@@ -114,6 +114,11 @@ void Workspaces::doUpdate() {
button.show(); button.show();
else else
button.hide(); button.hide();
} else if (config_["hide-empty"].asBool()) {
if (ws["active_window_id"].isNull() && !ws["is_focused"].asBool())
button.hide();
else
button.show();
} else { } else {
button.show(); button.show();
} }