Fix clang-format
This commit is contained in:
@@ -193,7 +193,8 @@ auto waybar::modules::Custom::update() -> void {
|
||||
auto str = fmt::format(fmt::runtime(format_), fmt::arg("text", text_), fmt::arg("alt", alt_),
|
||||
fmt::arg("icon", getIcon(percentage_, alt_)),
|
||||
fmt::arg("percentage", percentage_));
|
||||
if ((config_["hide-empty-text"].asBool() && text_.empty()) || (str.empty() && image_path_.empty() && image_name_.empty())) {
|
||||
if ((config_["hide-empty-text"].asBool() && text_.empty()) ||
|
||||
(str.empty() && image_path_.empty() && image_name_.empty())) {
|
||||
event_box_.hide();
|
||||
} else {
|
||||
label_.set_markup(str);
|
||||
@@ -241,7 +242,6 @@ auto waybar::modules::Custom::update() -> void {
|
||||
|
||||
image_.set_visible(!image_name_.empty() || !image_path_.empty());
|
||||
label_.set_visible(!str.empty());
|
||||
|
||||
}
|
||||
} catch (const fmt::format_error& e) {
|
||||
if (std::strcmp(e.what(), "cannot switch from manual to automatic argument indexing") != 0)
|
||||
@@ -251,9 +251,6 @@ auto waybar::modules::Custom::update() -> void {
|
||||
"mixing manual and automatic argument indexing is no longer supported; "
|
||||
"try replacing \"{}\" with \"{text}\" in your format specifier");
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
// Call parent update
|
||||
AIconLabel::update();
|
||||
|
||||
Reference in New Issue
Block a user