split waybar into multiple files
This commit is contained in:
parent
53c7532351
commit
7cff7f09c3
29 changed files with 953 additions and 617 deletions
|
|
@ -1,22 +0,0 @@
|
|||
diff --git a/src/modules/wireplumber.cpp b/src/modules/wireplumber.cpp
|
||||
index a43ad29b..d04edd18 100644
|
||||
--- a/src/modules/wireplumber.cpp
|
||||
+++ b/src/modules/wireplumber.cpp
|
||||
@@ -436,7 +437,7 @@ auto waybar::modules::Wireplumber::update() -> void {
|
||||
label_.get_style_context()->remove_class("source-muted");
|
||||
}
|
||||
|
||||
- int vol = round(volume_ * 100.0);
|
||||
+ double vol = 60 * std::log10(volume_); // % to dB
|
||||
int source_vol = round(source_volume_ * 100.0);
|
||||
|
||||
// Get the state and apply state-specific format if available
|
||||
@@ -450,7 +451,7 @@ auto waybar::modules::Wireplumber::update() -> void {
|
||||
}
|
||||
|
||||
// Prepare source format string (similar to PulseAudio)
|
||||
- std::string format_source = "{volume}%";
|
||||
+ std::string format_source = "{volume}dB";
|
||||
if (source_muted_) {
|
||||
if (config_["format-source-muted"].isString()) {
|
||||
format_source = config_["format-source-muted"].asString();
|
||||
Loading…
Add table
Add a link
Reference in a new issue