mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
Fix linting
This commit is contained in:
parent
88a1a702b4
commit
75990c2867
@ -296,8 +296,8 @@ auto waybar::modules::Wireplumber::update() -> void {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!tooltip_format.empty()) {
|
if (!tooltip_format.empty()) {
|
||||||
label_.set_tooltip_text(
|
label_.set_tooltip_text(fmt::format(fmt::runtime(tooltip_format),
|
||||||
fmt::format(fmt::runtime(tooltip_format), fmt::arg("node_name", node_name_),
|
fmt::arg("node_name", node_name_),
|
||||||
fmt::arg("volume", vol), fmt::arg("icon", getIcon(vol))));
|
fmt::arg("volume", vol), fmt::arg("icon", getIcon(vol))));
|
||||||
} else {
|
} else {
|
||||||
label_.set_tooltip_text(node_name_);
|
label_.set_tooltip_text(node_name_);
|
||||||
@ -337,14 +337,12 @@ bool waybar::modules::Wireplumber::handleScroll(GdkEventScroll *e) {
|
|||||||
if (dir == SCROLL_DIR::UP) {
|
if (dir == SCROLL_DIR::UP) {
|
||||||
if (volume_ < max_volume) {
|
if (volume_ < max_volume) {
|
||||||
new_vol = volume_ + step;
|
new_vol = volume_ + step;
|
||||||
if (new_vol > max_volume)
|
if (new_vol > max_volume) new_vol = max_volume;
|
||||||
new_vol = max_volume;
|
|
||||||
}
|
}
|
||||||
} else if (dir == SCROLL_DIR::DOWN) {
|
} else if (dir == SCROLL_DIR::DOWN) {
|
||||||
if (volume_ > 0) {
|
if (volume_ > 0) {
|
||||||
new_vol = volume_ - step;
|
new_vol = volume_ - step;
|
||||||
if (new_vol < 0)
|
if (new_vol < 0) new_vol = 0;
|
||||||
new_vol = 0;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (new_vol != volume_) {
|
if (new_vol != volume_) {
|
||||||
|
Loading…
Reference in New Issue
Block a user