mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
fix Linter errors
This commit is contained in:
parent
23eaffc04b
commit
02df861829
@ -64,8 +64,7 @@ auto waybar::modules::JACK::update() -> void {
|
||||
} else
|
||||
format = "DSP {load}%";
|
||||
|
||||
if (!label_.get_style_context()->has_class(state))
|
||||
label_.get_style_context()->add_class(state);
|
||||
if (!label_.get_style_context()->has_class(state)) label_.get_style_context()->add_class(state);
|
||||
state_ = state;
|
||||
|
||||
label_.set_markup(fmt::format(format, fmt::arg("load", std::round(load)),
|
||||
@ -76,10 +75,9 @@ auto waybar::modules::JACK::update() -> void {
|
||||
if (tooltipEnabled()) {
|
||||
std::string tooltip_format = "{bufsize}/{samplerate} {latency}ms";
|
||||
if (config_["tooltip-format"].isString()) tooltip_format = config_["tooltip-format"].asString();
|
||||
label_.set_tooltip_text(fmt::format(tooltip_format, fmt::arg("load", std::round(load)),
|
||||
fmt::arg("bufsize", bufsize_),
|
||||
fmt::arg("samplerate", samplerate_),
|
||||
fmt::arg("latency", fmt::format("{:.2f}", latency)),
|
||||
label_.set_tooltip_text(fmt::format(
|
||||
tooltip_format, fmt::arg("load", std::round(load)), fmt::arg("bufsize", bufsize_),
|
||||
fmt::arg("samplerate", samplerate_), fmt::arg("latency", fmt::format("{:.2f}", latency)),
|
||||
fmt::arg("xruns", xruns_)));
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user